[lua] Ported fix for #1119

This commit is contained in:
badlogic 2018-06-07 16:57:31 +02:00
parent 0f219a2eb0
commit 0f7b813c38

View File

@ -345,6 +345,9 @@ function AnimationState:updateMixingFrom (to, delta)
local finished = self:updateMixingFrom(from, delta)
from.animationLast = from.nextAnimationLast
from.trackLast = from.nextTrackLast
-- Require mixTime > 0 to ensure the mixing from entry was applied at least once.
if (to.mixTime > 0 and (to.mixTime >= to.mixDuration or to.timeScale == 0)) then
-- Require totalAlpha == 0 to ensure mixing is complete, unless mixDuration == 0 (the transition is a single frame).
@ -355,9 +358,7 @@ function AnimationState:updateMixingFrom (to, delta)
end
return finished
end
from.animationLast = from.nextAnimationLast
from.trackLast = from.nextTrackLast
from.trackTime = from.trackTime + delta * from.timeScale
to.mixTime = to.mixTime + delta * to.timeScale
return false;