Skip to content

Commit 483ac0c

Browse files
authored
Merge pull request rpgtkoolmv#190 from rpgtkoolmv/fix_ua_change
Fix rendering stopped when changed user agent mobile safari to another.
2 parents 2492297 + 638e45b commit 483ac0c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

js/rpg_managers/SceneManager.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -228,8 +228,9 @@ SceneManager.updateMain = function() {
228228
this.updateScene();
229229
} else {
230230
var newTime = this._getTimeInMsWithoutMobileSafari();
231+
if (this._currentTime === undefined) { this._currentTime = newTime; }
231232
var fTime = (newTime - this._currentTime) / 1000;
232-
if (fTime > 0.25) fTime = 0.25;
233+
if (fTime > 0.25) { fTime = 0.25; }
233234
this._currentTime = newTime;
234235
this._accumulator += fTime;
235236
while (this._accumulator >= this._deltaTime) {

0 commit comments

Comments
 (0)