Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / Sparky's collision and gravity

Author
Message
xix psycho xix
16
Years of Service
User Offline
Joined: 15th Sep 2008
Location:
Posted: 28th Jan 2009 16:40 Edited at: 28th Jan 2009 19:13
I wrote a class to handle gravity and help me with collision. im not sure how to reposition myself in the map based on collision though. Here is the code for my class:



Simple. Now here is my main program:



I am using a map that i made with fps creator. Now, the problem is that i keep moving through the level walls for some reason. when i initially fall on top of the level, im fine, but after i'm done falling and begin to move around, i somehow go through the level. can anyone help me modify this to take care of that problem? Or, if anyone can help me in creating collision, i really need it. i have no idea how to simulate an object being solid. i want to be able to stop players from going through walls and such as well, but i dont know how to do it with fps creator maps. actually, i dont know how to do it with any map

Login to post a reply

Server time is: 2024-11-25 13:45:18
Your offset time is: 2024-11-25 13:45:18