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.

Newcomers DBPro Corner / variable jump heights help please

Author
Message
mususama
15
Years of Service
User Offline
Joined: 7th Jun 2009
Location:
Posted: 15th Jun 2009 23:32
hi everyone i just started making my first game its a 3rd person action/adventure type thing and just wanted to know if it is possible to make a jump command so if u press a key eg. spacebar the character would jump to a certain height but if u hold the spacebar then release it would jump heigher depending on how long u held it, kind of like the spiderman 2 jump system. i know its a big ask but could somebody get me started on the code as i dont know much about jumping and gravity and what not....
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 16th Jun 2009 16:55
"Gimme teh codez" posts like this one are frowned upon on this forum. Coders are expected to put forth at least some effort to come up with a solution to whatever problem they are facing. Making video games is very enjoyable, but it takes effort and a willingness to learn.

That said, I did take the time to put together something basic for you this time.


The 'player' jumps in proportion to how long the spacebar is held down. Exit by pressing the ENTER key.

Good luck to you,

LBFN


So many games to code......so little time.

Login to post a reply

Server time is: 2024-11-24 06:06:11
Your offset time is: 2024-11-24 06:06:11