Home » Previous Subjects » Spring 2014 – Game Design » Ball Roller, Adding Jump

Ball Roller, Adding Jump

Last week, we ran into some problems trying to add jump capability to our ball.  This week, we corrected the problem by creating a reference to the velocity of the ball’s body.  We were then able to change the y property of the reference, and reapply it to the body.  This solved the jumping problem.

 

After that, we added a OnCollisionStay event handler, and created a boolean flag for determining when the ball was in the middle of a jump.  We were then able to prevent jumping unless the ball was on the ground.

 

We also talked about X,Y,Z in 3d space, and how we’re going to make the camera follow the ball on Wednesday.

 

To make sure everyone is up-to-date and caught up, here is the project so far.

BallRoller

Leave a Reply

Your email address will not be published. Required fields are marked *