examples/gameplay: apply friction

This commit is contained in:
Kazhnuz 2019-04-28 09:31:37 +02:00
parent c43317bfe2
commit 7f8234b7f7
1 changed files with 2 additions and 1 deletions

View File

@ -7,7 +7,8 @@ function Player:new(world, x, y)
end
function Player:update(dt)
self.xsp, self.ysp = 0, 0
self.xfrc, self.yfrc = 480*3, 480*3
if self.keys["up"].isDown then
self.ysp = -120
end