Sign in to follow this  

Collision Detection for Platforms

This topic is 4197 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

With my current game i'm working on I've been trying to implement a system for collision detection. Its coming along decently but i'm having some issues trying to get jumping up onto something to work properly. What I've implemented is a system of vectors protruding out of the character. I have a total of four vectors coming out of each object. vectors The way it works is each frame I check to see if a certain vector is within another object, if so a collision occurs. Well I thought this was pretty straight forward for landing on an object, I would just determine if my vecGravity vector is within an object and push it back up. Well it doesn't seem to be working. Is my basic theory wrong for this, or is there a better way to go about this. Reason I'm using vectors instead of Rect's is I figured that by doing this it would create a better more realistic physics within the program. Also I would be able to implement other nifty things like sliding down slopes and such. Thanks for your time. Slyprid

Share this post


Link to post
Share on other sites
I finally got it to work. I had the right idea, but found out some of my numbers were not coming out right after fixing those the world is full of gravity now. Now to apply it to other objects. :D

Slyprid

Share this post


Link to post
Share on other sites

This topic is 4197 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this