Don't loop as hell when FPS is zero
This commit is contained in:
parent
9b3b501764
commit
153f7341fe
@ -246,9 +246,13 @@ Torque.modules.layer = function (torque) {
|
||||
this.options.scrub_move(this)
|
||||
}
|
||||
if (this.running) {
|
||||
if ( this.options.fps ) {
|
||||
var ms = pause + 1000 * 1 / this.options.fps;
|
||||
//console.log("play timeout: " + ms + " ms (pause:" + pause + ", fps:" + this.options.fps + ")");
|
||||
setTimeout(function () {
|
||||
this.play()
|
||||
}.bind(this), pause + 1000 * 1 / this.options.fps);
|
||||
}.bind(this), ms);
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user