Skip to content

Commit 719ebcd

Browse files
committed
Small fix for elapsed values.
1 parent a74a181 commit 719ebcd

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

src/time/Time.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -410,7 +410,7 @@ Phaser.Time.prototype = {
410410
* @return {number} The number of seconds that have elapsed since the game was started.
411411
*/
412412
totalElapsedSeconds: function() {
413-
return (this.now - this._started) * 0.001;
413+
return (this.time - this._started) * 0.001;
414414
},
415415

416416
/**
@@ -421,7 +421,7 @@ Phaser.Time.prototype = {
421421
* @return {number} The difference between the given time and now.
422422
*/
423423
elapsedSince: function (since) {
424-
return this.now - since;
424+
return this.time - since;
425425
},
426426

427427
/**
@@ -432,7 +432,7 @@ Phaser.Time.prototype = {
432432
* @return {number} Duration between given time and now (in seconds).
433433
*/
434434
elapsedSecondsSince: function (since) {
435-
return (this.now - since) * 0.001;
435+
return (this.time - since) * 0.001;
436436
},
437437

438438
/**

0 commit comments

Comments
 (0)