excalibur 0.32.0-alpha.1560 → 0.32.0-alpha.1562
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.
- package/CHANGELOG.md +1 -0
- package/build/dist/Util/Clock.d.ts +1 -0
- package/build/dist/excalibur.development.js +14 -7
- package/build/dist/excalibur.js +14 -7
- package/build/dist/excalibur.min.development.js +3 -3
- package/build/dist/excalibur.min.js +3 -3
- package/build/esm/excalibur.development.js +14 -7
- package/build/esm/excalibur.js +14 -7
- package/build/esm/excalibur.min.development.js +9 -6
- package/build/esm/excalibur.min.js +9 -6
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -38,6 +38,7 @@ This project adheres to [Semantic Versioning](http://semver.org/).
|
|
|
38
38
|
|
|
39
39
|
### Fixed
|
|
40
40
|
|
|
41
|
+
- Fixed issue where clearSchedule during a scheduled callback could cause a cb to be skipped
|
|
41
42
|
- Fixed issue where the Loader could run twice even if already loaded when included in the scene loader.
|
|
42
43
|
- Fixed issue where pixel ratio was accidentally doubled during load if the loader was included in the scene loader.
|
|
43
44
|
- Fixed issue where Slide trasition did not work properly when DisplayMode was FitScreenAndFill
|
|
@@ -63,6 +63,7 @@ export declare abstract class Clock {
|
|
|
63
63
|
* @returns A unique identifier that can be used to clear the scheduled callback with {@apilink clearSchedule}
|
|
64
64
|
*/
|
|
65
65
|
schedule(cb: (elapsed: number) => any, timeoutMs?: number, timing?: ScheduledCallbackTiming): ScheduleId;
|
|
66
|
+
private _idsToRemove;
|
|
66
67
|
/**
|
|
67
68
|
* Clears a scheduled callback using the ID returned from {@apilink schedule}
|
|
68
69
|
* @param id The ID of the scheduled callback to clear
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! excalibur - 0.32.0-alpha.
|
|
1
|
+
/*! excalibur - 0.32.0-alpha.1562+c143e37 - 2025-11-23
|
|
2
2
|
https://github.com/excaliburjs/Excalibur
|
|
3
3
|
Copyright (c) 2025 Excalibur.js <https://github.com/excaliburjs/Excalibur/graphs/contributors>
|
|
4
4
|
Licensed BSD-2-Clause
|
|
@@ -29173,6 +29173,7 @@ If you want to do custom drawing, use Actor.graphics, or any onPreDraw or onPost
|
|
|
29173
29173
|
this._scheduledCbs = [];
|
|
29174
29174
|
this._totalElapsed = 0;
|
|
29175
29175
|
this._nextScheduleId = 0;
|
|
29176
|
+
this._idsToRemove = [];
|
|
29176
29177
|
var _a, _b, _c;
|
|
29177
29178
|
this._options = options;
|
|
29178
29179
|
this.tick = options.tick;
|
|
@@ -29234,10 +29235,7 @@ If you want to do custom drawing, use Actor.graphics, or any onPreDraw or onPost
|
|
|
29234
29235
|
* @param id The ID of the scheduled callback to clear
|
|
29235
29236
|
*/
|
|
29236
29237
|
clearSchedule(id) {
|
|
29237
|
-
|
|
29238
|
-
if (index !== -1) {
|
|
29239
|
-
this._scheduledCbs.splice(index, 1);
|
|
29240
|
-
}
|
|
29238
|
+
this._idsToRemove.push(id);
|
|
29241
29239
|
}
|
|
29242
29240
|
/**
|
|
29243
29241
|
* Called internally to trigger scheduled callbacks in the clock
|
|
@@ -29246,12 +29244,21 @@ If you want to do custom drawing, use Actor.graphics, or any onPreDraw or onPost
|
|
|
29246
29244
|
*/
|
|
29247
29245
|
__runScheduledCbs(timing = "preframe") {
|
|
29248
29246
|
for (let i = this._scheduledCbs.length - 1; i > -1; i--) {
|
|
29249
|
-
const [
|
|
29247
|
+
const [scheduleId, callback, scheduledTime, callbackTiming] = this._scheduledCbs[i];
|
|
29248
|
+
if (this._idsToRemove.includes(scheduleId)) {
|
|
29249
|
+
continue;
|
|
29250
|
+
}
|
|
29250
29251
|
if (timing === callbackTiming && scheduledTime <= this._totalElapsed) {
|
|
29251
29252
|
callback(this._elapsed);
|
|
29252
29253
|
this._scheduledCbs.splice(i, 1);
|
|
29253
29254
|
}
|
|
29254
29255
|
}
|
|
29256
|
+
for (const id of this._idsToRemove) {
|
|
29257
|
+
const index = this._scheduledCbs.findIndex(([scheduleId]) => scheduleId === id);
|
|
29258
|
+
if (index !== -1) {
|
|
29259
|
+
this._scheduledCbs.splice(index, 1);
|
|
29260
|
+
}
|
|
29261
|
+
}
|
|
29255
29262
|
}
|
|
29256
29263
|
update(overrideUpdateMs) {
|
|
29257
29264
|
try {
|
|
@@ -33036,7 +33043,7 @@ Read more about this issue at https://excaliburjs.com/docs/performance`
|
|
|
33036
33043
|
this._count += count;
|
|
33037
33044
|
}
|
|
33038
33045
|
}
|
|
33039
|
-
const EX_VERSION = "0.32.0-alpha.
|
|
33046
|
+
const EX_VERSION = "0.32.0-alpha.1562+c143e37";
|
|
33040
33047
|
polyfill();
|
|
33041
33048
|
exports2.ActionCompleteEvent = ActionCompleteEvent;
|
|
33042
33049
|
exports2.ActionContext = ActionContext;
|
package/build/dist/excalibur.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! excalibur - 0.32.0-alpha.
|
|
1
|
+
/*! excalibur - 0.32.0-alpha.1562+c143e37 - 2025-11-23
|
|
2
2
|
https://github.com/excaliburjs/Excalibur
|
|
3
3
|
Copyright (c) 2025 Excalibur.js <https://github.com/excaliburjs/Excalibur/graphs/contributors>
|
|
4
4
|
Licensed BSD-2-Clause
|
|
@@ -29173,6 +29173,7 @@ If you want to do custom drawing, use Actor.graphics, or any onPreDraw or onPost
|
|
|
29173
29173
|
this._scheduledCbs = [];
|
|
29174
29174
|
this._totalElapsed = 0;
|
|
29175
29175
|
this._nextScheduleId = 0;
|
|
29176
|
+
this._idsToRemove = [];
|
|
29176
29177
|
var _a, _b, _c;
|
|
29177
29178
|
this._options = options;
|
|
29178
29179
|
this.tick = options.tick;
|
|
@@ -29234,10 +29235,7 @@ If you want to do custom drawing, use Actor.graphics, or any onPreDraw or onPost
|
|
|
29234
29235
|
* @param id The ID of the scheduled callback to clear
|
|
29235
29236
|
*/
|
|
29236
29237
|
clearSchedule(id) {
|
|
29237
|
-
|
|
29238
|
-
if (index !== -1) {
|
|
29239
|
-
this._scheduledCbs.splice(index, 1);
|
|
29240
|
-
}
|
|
29238
|
+
this._idsToRemove.push(id);
|
|
29241
29239
|
}
|
|
29242
29240
|
/**
|
|
29243
29241
|
* Called internally to trigger scheduled callbacks in the clock
|
|
@@ -29246,12 +29244,21 @@ If you want to do custom drawing, use Actor.graphics, or any onPreDraw or onPost
|
|
|
29246
29244
|
*/
|
|
29247
29245
|
__runScheduledCbs(timing = "preframe") {
|
|
29248
29246
|
for (let i = this._scheduledCbs.length - 1; i > -1; i--) {
|
|
29249
|
-
const [
|
|
29247
|
+
const [scheduleId, callback, scheduledTime, callbackTiming] = this._scheduledCbs[i];
|
|
29248
|
+
if (this._idsToRemove.includes(scheduleId)) {
|
|
29249
|
+
continue;
|
|
29250
|
+
}
|
|
29250
29251
|
if (timing === callbackTiming && scheduledTime <= this._totalElapsed) {
|
|
29251
29252
|
callback(this._elapsed);
|
|
29252
29253
|
this._scheduledCbs.splice(i, 1);
|
|
29253
29254
|
}
|
|
29254
29255
|
}
|
|
29256
|
+
for (const id of this._idsToRemove) {
|
|
29257
|
+
const index = this._scheduledCbs.findIndex(([scheduleId]) => scheduleId === id);
|
|
29258
|
+
if (index !== -1) {
|
|
29259
|
+
this._scheduledCbs.splice(index, 1);
|
|
29260
|
+
}
|
|
29261
|
+
}
|
|
29255
29262
|
}
|
|
29256
29263
|
update(overrideUpdateMs) {
|
|
29257
29264
|
try {
|
|
@@ -33036,7 +33043,7 @@ Read more about this issue at https://excaliburjs.com/docs/performance`
|
|
|
33036
33043
|
this._count += count;
|
|
33037
33044
|
}
|
|
33038
33045
|
}
|
|
33039
|
-
const EX_VERSION = "0.32.0-alpha.
|
|
33046
|
+
const EX_VERSION = "0.32.0-alpha.1562+c143e37";
|
|
33040
33047
|
polyfill();
|
|
33041
33048
|
exports2.ActionCompleteEvent = ActionCompleteEvent;
|
|
33042
33049
|
exports2.ActionContext = ActionContext;
|