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.

Author
Message
ZestyPro
14
Years of Service
User Offline
Joined: 27th Aug 2011
Location: The Grid
Posted: 22nd Sep 2011 03:26
OK so in a first person game i'm trying to figure out how to move around without changing the y axis but also have gravity working. any suggestions?

Haha!
WLGfx
18
Years of Service
User Offline
Joined: 1st Nov 2007
Location: NW United Kingdom
Posted: 22nd Sep 2011 03:32
Usually you would apply gravity on each update to the y axis. Using Sparkys collision, after checking the collision the y axis would be put back right unless there was nothing underneath the object.

There's a few examples throughout the forums using this and in the code snippets forum...

Warning! May contain Nuts!
ZestyPro
14
Years of Service
User Offline
Joined: 27th Aug 2011
Location: The Grid
Posted: 22nd Sep 2011 03:33 Edited at: 22nd Sep 2011 03:34
thank you. i never thought of checking for objects underneath the player. thanks again

Haha!
WLGfx
18
Years of Service
User Offline
Joined: 1st Nov 2007
Location: NW United Kingdom
Posted: 22nd Sep 2011 03:43
Hope you find what you need. Good luck... Any probs just ask...

Warning! May contain Nuts!

Login to post a reply

Server time is: 2026-07-10 20:57:54
Your offset time is: 2026-07-10 20:57:54