Platformer Game
Velocity
forever
move (velocity) steps
wait (vtime) seconds
How would you add in a vertical velocity?
[This means only changes y coordinate.]
Gravity
Add a variable: vertical velocity
If touching floor color
-- set vertical velocity to 0
else
-- change vertical velocity by gravity
Glitches to Discuss
Jumping
How do you jump?
Slowing Down: Friction or Skid Stop
Ways to slow down:
Issues with #1: negative velocity doesn't work.
Game Requirements