Add .add() to Vector
This commit is contained in:
@ -45,6 +45,12 @@ public class Vector {
|
||||
return new Vector(x + v.x, y + v.y, z + v.z);
|
||||
}
|
||||
|
||||
public void add(Vector v) {
|
||||
this.x += v.x;
|
||||
this.y += v.y;
|
||||
this.z += v.z;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the product of this vector and 'd'.
|
||||
*/
|
||||
|
Reference in New Issue
Block a user