mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-03-26 22:49:01 +08:00
[runtimes] Back ported fix for #1119 to 3.6.
This commit is contained in:
parent
cab8127626
commit
681584056b
Binary file not shown.
@ -130,6 +130,9 @@ package spine.animation {
|
|||||||
|
|
||||||
var finished : Boolean = updateMixingFrom(from, delta);
|
var finished : Boolean = 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.
|
// Require mixTime > 0 to ensure the mixing from entry was applied at least once.
|
||||||
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
||||||
// Require totalAlpha == 0 to ensure mixing is complete, unless mixDuration == 0 (the transition is a single frame).
|
// Require totalAlpha == 0 to ensure mixing is complete, unless mixDuration == 0 (the transition is a single frame).
|
||||||
@ -141,8 +144,6 @@ package spine.animation {
|
|||||||
return finished;
|
return finished;
|
||||||
}
|
}
|
||||||
|
|
||||||
from.animationLast = from.nextAnimationLast;
|
|
||||||
from.trackLast = from.nextTrackLast;
|
|
||||||
from.trackTime += delta * from.timeScale;
|
from.trackTime += delta * from.timeScale;
|
||||||
to.mixTime += delta * to.timeScale;
|
to.mixTime += delta * to.timeScale;
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
@ -325,6 +325,9 @@ int /*boolean*/ _spAnimationState_updateMixingFrom (spAnimationState* self, spTr
|
|||||||
|
|
||||||
finished = _spAnimationState_updateMixingFrom(self, from, delta);
|
finished = _spAnimationState_updateMixingFrom(self, from, delta);
|
||||||
|
|
||||||
|
from->animationLast = from->nextAnimationLast;
|
||||||
|
from->trackLast = from->nextTrackLast;
|
||||||
|
|
||||||
/* Require mixTime > 0 to ensure the mixing from entry was applied at least once. */
|
/* Require mixTime > 0 to ensure the mixing from entry was applied at least once. */
|
||||||
if (to->mixTime > 0 && (to->mixTime >= to->mixDuration || to->timeScale == 0)) {
|
if (to->mixTime > 0 && (to->mixTime >= to->mixDuration || to->timeScale == 0)) {
|
||||||
/* Require totalAlpha == 0 to ensure mixing is complete, unless mixDuration == 0 (the transition is a single frame). */
|
/* Require totalAlpha == 0 to ensure mixing is complete, unless mixDuration == 0 (the transition is a single frame). */
|
||||||
@ -336,8 +339,6 @@ int /*boolean*/ _spAnimationState_updateMixingFrom (spAnimationState* self, spTr
|
|||||||
return finished;
|
return finished;
|
||||||
}
|
}
|
||||||
|
|
||||||
from->animationLast = from->nextAnimationLast;
|
|
||||||
from->trackLast = from->nextTrackLast;
|
|
||||||
from->trackTime += delta * from->timeScale;
|
from->trackTime += delta * from->timeScale;
|
||||||
to->mixTime += delta * to->timeScale;
|
to->mixTime += delta * to->timeScale;
|
||||||
return 0;
|
return 0;
|
||||||
|
|||||||
@ -166,6 +166,9 @@ public class AnimationState {
|
|||||||
|
|
||||||
boolean finished = updateMixingFrom(from, delta);
|
boolean finished = 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.
|
// Require mixTime > 0 to ensure the mixing from entry was applied at least once.
|
||||||
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
||||||
// Require totalAlpha == 0 to ensure mixing is complete, unless mixDuration == 0 (the transition is a single frame).
|
// Require totalAlpha == 0 to ensure mixing is complete, unless mixDuration == 0 (the transition is a single frame).
|
||||||
@ -177,8 +180,6 @@ public class AnimationState {
|
|||||||
return finished;
|
return finished;
|
||||||
}
|
}
|
||||||
|
|
||||||
from.animationLast = from.nextAnimationLast;
|
|
||||||
from.trackLast = from.nextTrackLast;
|
|
||||||
from.trackTime += delta * from.timeScale;
|
from.trackTime += delta * from.timeScale;
|
||||||
to.mixTime += delta * to.timeScale;
|
to.mixTime += delta * to.timeScale;
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
@ -342,7 +342,10 @@ function AnimationState:updateMixingFrom (to, delta)
|
|||||||
local from = to.mixingFrom
|
local from = to.mixingFrom
|
||||||
if from == nil then return true end
|
if from == nil then return true end
|
||||||
|
|
||||||
local finished = self:updateMixingFrom(from, 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.
|
-- 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
|
if (to.mixTime > 0 and (to.mixTime >= to.mixDuration or to.timeScale == 0)) then
|
||||||
@ -355,8 +358,6 @@ function AnimationState:updateMixingFrom (to, delta)
|
|||||||
return finished
|
return finished
|
||||||
end
|
end
|
||||||
|
|
||||||
from.animationLast = from.nextAnimationLast
|
|
||||||
from.trackLast = from.nextTrackLast
|
|
||||||
from.trackTime = from.trackTime + delta * from.timeScale
|
from.trackTime = from.trackTime + delta * from.timeScale
|
||||||
to.mixTime = to.mixTime + delta * to.timeScale
|
to.mixTime = to.mixTime + delta * to.timeScale
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
Binary file not shown.
Binary file not shown.
@ -1211,6 +1211,8 @@ var spine;
|
|||||||
if (from == null)
|
if (from == null)
|
||||||
return true;
|
return true;
|
||||||
var finished = this.updateMixingFrom(from, delta);
|
var finished = this.updateMixingFrom(from, delta);
|
||||||
|
from.animationLast = from.nextAnimationLast;
|
||||||
|
from.trackLast = from.nextTrackLast;
|
||||||
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
||||||
if (from.totalAlpha == 0 || to.mixDuration == 0) {
|
if (from.totalAlpha == 0 || to.mixDuration == 0) {
|
||||||
to.mixingFrom = from.mixingFrom;
|
to.mixingFrom = from.mixingFrom;
|
||||||
@ -1219,8 +1221,6 @@ var spine;
|
|||||||
}
|
}
|
||||||
return finished;
|
return finished;
|
||||||
}
|
}
|
||||||
from.animationLast = from.nextAnimationLast;
|
|
||||||
from.trackLast = from.nextTrackLast;
|
|
||||||
from.trackTime += delta * from.timeScale;
|
from.trackTime += delta * from.timeScale;
|
||||||
to.mixTime += delta * to.timeScale;
|
to.mixTime += delta * to.timeScale;
|
||||||
return false;
|
return false;
|
||||||
@ -9907,7 +9907,7 @@ var spine;
|
|||||||
else {
|
else {
|
||||||
for (var i = 0; i < config.atlasPages.length; i++) {
|
for (var i = 0; i < config.atlasPages.length; i++) {
|
||||||
if (config.atlasPagesContent && config.atlasPagesContent[i]) {
|
if (config.atlasPagesContent && config.atlasPagesContent[i]) {
|
||||||
assets.loadTextureData(config.atlasPages[i], config.atlasPagesContent[0]);
|
assets.loadTextureData(config.atlasPages[i], config.atlasPagesContent[i]);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
assets.loadTexture(config.atlasPages[i]);
|
assets.loadTexture(config.atlasPages[i]);
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@ -1211,6 +1211,8 @@ var spine;
|
|||||||
if (from == null)
|
if (from == null)
|
||||||
return true;
|
return true;
|
||||||
var finished = this.updateMixingFrom(from, delta);
|
var finished = this.updateMixingFrom(from, delta);
|
||||||
|
from.animationLast = from.nextAnimationLast;
|
||||||
|
from.trackLast = from.nextTrackLast;
|
||||||
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
||||||
if (from.totalAlpha == 0 || to.mixDuration == 0) {
|
if (from.totalAlpha == 0 || to.mixDuration == 0) {
|
||||||
to.mixingFrom = from.mixingFrom;
|
to.mixingFrom = from.mixingFrom;
|
||||||
@ -1219,8 +1221,6 @@ var spine;
|
|||||||
}
|
}
|
||||||
return finished;
|
return finished;
|
||||||
}
|
}
|
||||||
from.animationLast = from.nextAnimationLast;
|
|
||||||
from.trackLast = from.nextTrackLast;
|
|
||||||
from.trackTime += delta * from.timeScale;
|
from.trackTime += delta * from.timeScale;
|
||||||
to.mixTime += delta * to.timeScale;
|
to.mixTime += delta * to.timeScale;
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@ -1211,6 +1211,8 @@ var spine;
|
|||||||
if (from == null)
|
if (from == null)
|
||||||
return true;
|
return true;
|
||||||
var finished = this.updateMixingFrom(from, delta);
|
var finished = this.updateMixingFrom(from, delta);
|
||||||
|
from.animationLast = from.nextAnimationLast;
|
||||||
|
from.trackLast = from.nextTrackLast;
|
||||||
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
||||||
if (from.totalAlpha == 0 || to.mixDuration == 0) {
|
if (from.totalAlpha == 0 || to.mixDuration == 0) {
|
||||||
to.mixingFrom = from.mixingFrom;
|
to.mixingFrom = from.mixingFrom;
|
||||||
@ -1219,8 +1221,6 @@ var spine;
|
|||||||
}
|
}
|
||||||
return finished;
|
return finished;
|
||||||
}
|
}
|
||||||
from.animationLast = from.nextAnimationLast;
|
|
||||||
from.trackLast = from.nextTrackLast;
|
|
||||||
from.trackTime += delta * from.timeScale;
|
from.trackTime += delta * from.timeScale;
|
||||||
to.mixTime += delta * to.timeScale;
|
to.mixTime += delta * to.timeScale;
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@ -1211,6 +1211,8 @@ var spine;
|
|||||||
if (from == null)
|
if (from == null)
|
||||||
return true;
|
return true;
|
||||||
var finished = this.updateMixingFrom(from, delta);
|
var finished = this.updateMixingFrom(from, delta);
|
||||||
|
from.animationLast = from.nextAnimationLast;
|
||||||
|
from.trackLast = from.nextTrackLast;
|
||||||
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
||||||
if (from.totalAlpha == 0 || to.mixDuration == 0) {
|
if (from.totalAlpha == 0 || to.mixDuration == 0) {
|
||||||
to.mixingFrom = from.mixingFrom;
|
to.mixingFrom = from.mixingFrom;
|
||||||
@ -1219,8 +1221,6 @@ var spine;
|
|||||||
}
|
}
|
||||||
return finished;
|
return finished;
|
||||||
}
|
}
|
||||||
from.animationLast = from.nextAnimationLast;
|
|
||||||
from.trackLast = from.nextTrackLast;
|
|
||||||
from.trackTime += delta * from.timeScale;
|
from.trackTime += delta * from.timeScale;
|
||||||
to.mixTime += delta * to.timeScale;
|
to.mixTime += delta * to.timeScale;
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@ -1211,6 +1211,8 @@ var spine;
|
|||||||
if (from == null)
|
if (from == null)
|
||||||
return true;
|
return true;
|
||||||
var finished = this.updateMixingFrom(from, delta);
|
var finished = this.updateMixingFrom(from, delta);
|
||||||
|
from.animationLast = from.nextAnimationLast;
|
||||||
|
from.trackLast = from.nextTrackLast;
|
||||||
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
||||||
if (from.totalAlpha == 0 || to.mixDuration == 0) {
|
if (from.totalAlpha == 0 || to.mixDuration == 0) {
|
||||||
to.mixingFrom = from.mixingFrom;
|
to.mixingFrom = from.mixingFrom;
|
||||||
@ -1219,8 +1221,6 @@ var spine;
|
|||||||
}
|
}
|
||||||
return finished;
|
return finished;
|
||||||
}
|
}
|
||||||
from.animationLast = from.nextAnimationLast;
|
|
||||||
from.trackLast = from.nextTrackLast;
|
|
||||||
from.trackTime += delta * from.timeScale;
|
from.trackTime += delta * from.timeScale;
|
||||||
to.mixTime += delta * to.timeScale;
|
to.mixTime += delta * to.timeScale;
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@ -1211,6 +1211,8 @@ var spine;
|
|||||||
if (from == null)
|
if (from == null)
|
||||||
return true;
|
return true;
|
||||||
var finished = this.updateMixingFrom(from, delta);
|
var finished = this.updateMixingFrom(from, delta);
|
||||||
|
from.animationLast = from.nextAnimationLast;
|
||||||
|
from.trackLast = from.nextTrackLast;
|
||||||
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
||||||
if (from.totalAlpha == 0 || to.mixDuration == 0) {
|
if (from.totalAlpha == 0 || to.mixDuration == 0) {
|
||||||
to.mixingFrom = from.mixingFrom;
|
to.mixingFrom = from.mixingFrom;
|
||||||
@ -1219,8 +1221,6 @@ var spine;
|
|||||||
}
|
}
|
||||||
return finished;
|
return finished;
|
||||||
}
|
}
|
||||||
from.animationLast = from.nextAnimationLast;
|
|
||||||
from.trackLast = from.nextTrackLast;
|
|
||||||
from.trackTime += delta * from.timeScale;
|
from.trackTime += delta * from.timeScale;
|
||||||
to.mixTime += delta * to.timeScale;
|
to.mixTime += delta * to.timeScale;
|
||||||
return false;
|
return false;
|
||||||
@ -9244,7 +9244,7 @@ var spine;
|
|||||||
else {
|
else {
|
||||||
for (var i = 0; i < config.atlasPages.length; i++) {
|
for (var i = 0; i < config.atlasPages.length; i++) {
|
||||||
if (config.atlasPagesContent && config.atlasPagesContent[i]) {
|
if (config.atlasPagesContent && config.atlasPagesContent[i]) {
|
||||||
assets.loadTextureData(config.atlasPages[i], config.atlasPagesContent[0]);
|
assets.loadTextureData(config.atlasPages[i], config.atlasPagesContent[i]);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
assets.loadTexture(config.atlasPages[i]);
|
assets.loadTexture(config.atlasPages[i]);
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@ -114,6 +114,9 @@ module spine {
|
|||||||
|
|
||||||
let finished = this.updateMixingFrom(from, delta);
|
let finished = this.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.
|
// Require mixTime > 0 to ensure the mixing from entry was applied at least once.
|
||||||
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
if (to.mixTime > 0 && (to.mixTime >= to.mixDuration || to.timeScale == 0)) {
|
||||||
// Require totalAlpha == 0 to ensure mixing is complete, unless mixDuration == 0 (the transition is a single frame).
|
// Require totalAlpha == 0 to ensure mixing is complete, unless mixDuration == 0 (the transition is a single frame).
|
||||||
@ -125,8 +128,6 @@ module spine {
|
|||||||
return finished;
|
return finished;
|
||||||
}
|
}
|
||||||
|
|
||||||
from.animationLast = from.nextAnimationLast;
|
|
||||||
from.trackLast = from.nextTrackLast;
|
|
||||||
from.trackTime += delta * from.timeScale;
|
from.trackTime += delta * from.timeScale;
|
||||||
to.mixTime += delta * to.timeScale;
|
to.mixTime += delta * to.timeScale;
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user