diff --git a/lib/game.lua b/lib/game.lua index 88c2c86..fec3457 100644 --- a/lib/game.lua +++ b/lib/game.lua @@ -167,8 +167,10 @@ function Game:toggle_tracks() return true end function Game:update_distance(dt) - local d = (dt * self.distance_rate) - self.distance = self.distance + d + if not self.dead then + local d = (dt * self.distance_rate) + self.distance = self.distance + d + end end function Game:update_background_speed(dt) --