Browse Source

add time scale

SUNAG 9 years ago
parent
commit
42a9faa124
1 changed files with 2 additions and 1 deletions
  1. 2 1
      examples/js/materials/nodes/utils/TimeNode.js

+ 2 - 1
examples/js/materials/nodes/utils/TimeNode.js

@@ -7,6 +7,7 @@ THREE.TimeNode = function( value ) {
 	THREE.FloatNode.call( this, value );
 
 	this.requestUpdate = true;
+	this.scale = 1;
 
 };
 
@@ -15,6 +16,6 @@ THREE.TimeNode.prototype.constructor = THREE.TimeNode;
 
 THREE.TimeNode.prototype.updateAnimation = function( delta ) {
 
-	this.number += delta;
+	this.number += delta * this.scale;
 
 };