@esotericsoftware/spine-canvas 4.2.79 → 4.2.81
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -4075,11 +4075,13 @@ var spine = (() => {
|
|
|
4075
4075
|
if (!last) {
|
|
4076
4076
|
this.setCurrent(trackIndex, entry, true);
|
|
4077
4077
|
this.queue.drain();
|
|
4078
|
+
if (delay < 0)
|
|
4079
|
+
delay = 0;
|
|
4078
4080
|
} else {
|
|
4079
4081
|
last.next = entry;
|
|
4080
4082
|
entry.previous = last;
|
|
4081
4083
|
if (delay <= 0)
|
|
4082
|
-
delay
|
|
4084
|
+
delay = Math.max(delay + last.getTrackComplete() - entry.mixDuration, 0);
|
|
4083
4085
|
}
|
|
4084
4086
|
entry.delay = delay;
|
|
4085
4087
|
return entry;
|
|
@@ -4118,7 +4120,7 @@ var spine = (() => {
|
|
|
4118
4120
|
addEmptyAnimation(trackIndex, mixDuration = 0, delay = 0) {
|
|
4119
4121
|
let entry = this.addAnimationWith(trackIndex, _AnimationState.emptyAnimation(), false, delay);
|
|
4120
4122
|
if (delay <= 0)
|
|
4121
|
-
entry.delay
|
|
4123
|
+
entry.delay = Math.max(entry.delay + entry.mixDuration - mixDuration, 0);
|
|
4122
4124
|
entry.mixDuration = mixDuration;
|
|
4123
4125
|
entry.trackEnd = mixDuration;
|
|
4124
4126
|
return entry;
|
|
@@ -4402,8 +4404,12 @@ var spine = (() => {
|
|
|
4402
4404
|
}
|
|
4403
4405
|
setMixDurationWithDelay(mixDuration, delay) {
|
|
4404
4406
|
this._mixDuration = mixDuration;
|
|
4405
|
-
if (
|
|
4406
|
-
|
|
4407
|
+
if (delay <= 0) {
|
|
4408
|
+
if (this.previous != null)
|
|
4409
|
+
delay = Math.max(delay + this.previous.getTrackComplete() - mixDuration, 0);
|
|
4410
|
+
else
|
|
4411
|
+
delay = 0;
|
|
4412
|
+
}
|
|
4407
4413
|
this.delay = delay;
|
|
4408
4414
|
}
|
|
4409
4415
|
/** Controls how properties keyed in the animation are mixed with lower tracks. Defaults to {@link MixBlend#replace}, which
|