Browse Source

Added divideSelf to Vector3.

Mr.doob 14 years ago
parent
commit
1a96d32bd9
1 changed files with 10 additions and 0 deletions
  1. 10 0
      src/core/Vector3.js

+ 10 - 0
src/core/Vector3.js

@@ -136,6 +136,16 @@ THREE.Vector3.prototype = {
 
 	},
 
+	divideSelf: function ( v ) {
+
+		this.x /= v.x;
+		this.y /= v.y;
+		this.z /= v.z;
+
+		return this;
+
+	},
+
 	divideScalar: function ( s ) {
 
 		this.x /= s;