From d5b216d9d6d2b8cb93106e8f8ca351089d05b41d Mon Sep 17 00:00:00 2001 From: Nivesh Rajbhandari Date: Wed, 22 Feb 2012 11:52:31 -0800 Subject: Integrating canvas-2d and WebGL drawing fixes. Also adding back WebGL materials. Signed-off-by: Nivesh Rajbhandari --- js/helper-classes/RDGE/src/core/script/runtime.js | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'js/helper-classes/RDGE/src/core/script/runtime.js') diff --git a/js/helper-classes/RDGE/src/core/script/runtime.js b/js/helper-classes/RDGE/src/core/script/runtime.js index 18b9b223..3d824faf 100755 --- a/js/helper-classes/RDGE/src/core/script/runtime.js +++ b/js/helper-classes/RDGE/src/core/script/runtime.js @@ -206,11 +206,15 @@ RDGETask = (function() { self.lastTime = self.currTime; } - this.start = function() { - this.running = true; - this.currTime = new Date().getTime(); - this.lastTime = this.currTime; - tasks[this.id](); + this.start = function() + { + if (!this.running) + { + this.running = true; + this.currTime = new Date().getTime(); + this.lastTime = this.currTime; + tasks[this.id](); + } } this.stop = function() { -- cgit v1.2.3