Skip to content

Commit e52ecb7

Browse files
committed
fix(render): ignore time scale
1 parent f3a45bb commit e52ecb7

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

src/lib/player/objects/EndingUI.ts

+1-2
Original file line numberDiff line numberDiff line change
@@ -120,8 +120,7 @@ export class EndingUI extends GameObjects.Container {
120120
update() {
121121
if (
122122
this._render &&
123-
this._scene.game.getTime() - this._started >
124-
(this._loopsToRender * 192e3) / 7 / this._scene.tweens.timeScale
123+
this._scene.game.getTime() - this._started > (this._loopsToRender * 192e3) / 7
125124
) {
126125
EventBus.emit('render-stop');
127126
this._render = false;

src/lib/player/scenes/Game.ts

+5-1
Original file line numberDiff line numberDiff line change
@@ -587,7 +587,7 @@ export class Game extends Scene {
587587
this.sound,
588588
() => this._status === GameStatus.FINISHED || this.end(),
589589
);
590-
this.timeScale = this._data.preferences.timeScale;
590+
if (!this._render) this.timeScale = this._data.preferences.timeScale;
591591
}
592592

593593
createBackground() {
@@ -993,6 +993,10 @@ export class Game extends Scene {
993993
return this._render;
994994
}
995995

996+
public get mediaOptions() {
997+
return this._data.mediaOptions;
998+
}
999+
9961000
public get objects() {
9971001
return this._objects;
9981002
}

0 commit comments

Comments
 (0)