From b5c3f635128845baa6fdc738df44c5fe88b3db82 Mon Sep 17 00:00:00 2001 From: Aki Date: Wed, 28 Jun 2017 21:18:09 +0200 Subject: Fixed animation bug for Player on walking combination --- not/Player.lua | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/not/Player.lua b/not/Player.lua index 5d108ce..34f57eb 100644 --- a/not/Player.lua +++ b/not/Player.lua @@ -134,10 +134,11 @@ function Player:controlreleased (set, action, key) end -- Walking if (action == "left" or action == "right") then - self.isWalking = false - if not (self:isControlDown("left") or self:isControlDown("right")) and - self.current == self.animations.walk then - self:setAnimation("default") + if not (self:isControlDown("left") or self:isControlDown("right")) then + self.isWalking = false + if self.current == self.animations.walk then + self:setAnimation("default") + end end end end -- cgit v1.1