Entrance of a level

This commit is contained in:
2018-10-06 21:28:26 +02:00
parent 5c54974159
commit 93d1678955
4 changed files with 27 additions and 2 deletions
+4
View File
@@ -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;