提交 67b55a6f 编写于 作者: M Mr.doob

More space/tabs clean up.

上级 189148ed
......@@ -62,33 +62,33 @@ THREE.Vector4.prototype = {
},
setComponent: function ( index, value ) {
setComponent: function ( index, value ) {
switch( index ) {
switch ( index ) {
case 0: this.x = value; break;
case 1: this.y = value; break;
case 2: this.z = value; break;
case 3: this.w = value; break;
default: throw new Error( "index is out of range: " + index );
case 0: this.x = value; break;
case 1: this.y = value; break;
case 2: this.z = value; break;
case 3: this.w = value; break;
default: throw new Error( "index is out of range: " + index );
}
}
},
},
getComponent: function ( index ) {
getComponent: function ( index ) {
switch( index ) {
switch ( index ) {
case 0: return this.x;
case 1: return this.y;
case 2: return this.z;
case 3: return this.w;
default: throw new Error( "index is out of range: " + index );
case 0: return this.x;
case 1: return this.y;
case 2: return this.z;
case 3: return this.w;
default: throw new Error( "index is out of range: " + index );
}
}
},
},
copy: function ( v ) {
......@@ -336,14 +336,14 @@ THREE.Vector4.prototype = {
setLength: function ( l ) {
var oldLength = this.length();
if ( oldLength !== 0 && l !== oldLength ) {
if ( oldLength !== 0 && l !== oldLength ) {
this.multiplyScalar( l / oldLength );
}
return this;
},
lerpSelf: function ( v, alpha ) {
......@@ -521,4 +521,4 @@ THREE.Vector4.prototype = {
}
};
\ No newline at end of file
};
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册