Entrance of a level
This commit is contained in:
@@ -191,6 +191,10 @@ impl Updatable for Character {
|
||||
self.speed.x *= physics::GROUND_FRICTION.x;
|
||||
self.speed += accel * duration + force * 64.0;
|
||||
|
||||
if self.speed.y > physics::MAXIMUM_VERTICAL_SPEED {
|
||||
self.speed.y = physics::MAXIMUM_VERTICAL_SPEED;
|
||||
}
|
||||
|
||||
// Compute position
|
||||
self.position += self.speed * duration;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user