Fix not returning to setup pose when multiple mixing from entries end at same time

#1024
This commit is contained in:
Nathan Sweet 2017-10-28 00:20:33 +02:00
parent 1514b4acbb
commit 882f49f5a9

View File

@ -244,9 +244,10 @@ public class AnimationState {
if (from.mixingFrom != null) applyMixingFrom(from, skeleton, currentPose);
float mix;
if (to.mixDuration == 0) // Single frame mix to undo mixingFrom changes.
if (to.mixDuration == 0) { // Single frame mix to undo mixingFrom changes.
mix = 1;
else {
currentPose = MixPose.setup;
} else {
mix = to.mixTime / to.mixDuration;
if (mix > 1) mix = 1;
}