Jump Game [WIP] (with source)

This is the current game I am working on. (Its currently unnamed)

http://i1005.photobucket.com/albums/af179/SmallishSteve/jumpgamepic.png



This game is a puzzle platformer, quite similar to portal.





download the full project here:

http://dl.dropbox.com/u/68197828/Jump%20Game.zip

This is my first proper game, so the programming might not be very clean, but I included the source for the benifit of poeple like me new to jme.



plain exe here:

http://dl.dropbox.com/u/68197828/Jump%20game/dist/JumpGame-Windows.zip

These links are from my dropbox, so will be updated.



Stuff to do:

-Add more levels. (Only 3 so far)

-redo “gun” thing, put on gui instead

-add features

I wanted to add a trampoline type thing(like the blue stuff in portal 2) so the Y velocity is reversed when you hit it.

I cant see any way to do it though…do I need to make a custom CharacterControl?



any suggestions/help/ideas much appreciated.

3 Likes

Cool, thanks for sharing. You could modify walkDirection for the movement, so don’t directly correlate input and walkDirection but make it only affect the walkDirection by a fraction. The rest would be outside influences like trampolines, wind etc.

Hey,



I downloaded your project, but on the first level I can’t get through it. Probally something related to put gun on gui, I didn’t understand what you said about that.



For making a trampoline, I imagine that you need some things:

Add a CollisionListener, so you know when the character collides with the trampoline (you need to be sure he’s colliding with the right stuff)

When stuff collides, instead of applying speed to the character, you could try to apply a force in the opposite direction of the movement speed. That way you don’t need to handle the calculations of the parable.



To apply a force, I think in jME you could use a RigidBodyControl. You can add two controls to the same object, but you need to somehow manage the control to one apply the force, and the other waits for the other to finish his stuff. You can re-use the CharacterControl when his position in the Y axis starts to decrease.