core/assets: don't set as true the restart argument when not passed
This commit is contained in:
parent
c4a4caf2ac
commit
38b0a732c5
|
@ -76,9 +76,8 @@ end
|
|||
function Animator:changeAnimation(name, restart)
|
||||
self.currentAnimation = name
|
||||
self.animationData = self.sprite.data.animations[self.currentAnimation]
|
||||
local restart = restart or true
|
||||
|
||||
if (restart) then
|
||||
if (restart == true) then
|
||||
self.frame = self.animationData.startAt
|
||||
self.frameTimer = 0
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue