1.0.7 • Published 8 years ago

vector-3 v1.0.7

Weekly downloads
49
License
MIT
Repository
github
Last release
8 years ago

npm version

Vector3

Vector3 JavaScript library

Doc

constructor

	new Vector3(x, y, z);
	// or
	new Vector(otherVector);

add

	vector.add(x, y, z);
	// or
	vector.add(otherVector);

substract

	vector.substract(x, y, z);
	// or
	vector.substract(otherVector);

multiply

	vector.multiply(x, y, z);
	// or
	vector.multiply(otherVector);

multiplyBy

	vector.multiplyBy(number);

divide

	vector.divide(x, y, z);
	// or
	vector.divide(otherVector);

divideBy

	vector.divideBy(number);

length

	vector.length();

dot

	vector.dot(otherVector);

cross

	vector.cross(otherVector);

normalize

	vector.normalize();

angle

	vector.angle(otherVector);

equal

	vector.equal(otherVector);

rotate

	vector.rotate(x, y, z);
	// or
	vector.rotate(otherVector);

clone

	vector.clone(otherVector);
1.0.7

8 years ago

1.0.6

8 years ago

1.0.5

8 years ago

1.0.4

8 years ago

1.0.3

8 years ago

1.0.2

8 years ago

1.0.1

8 years ago

1.0.0

8 years ago