This commit is contained in:
parent
47862d4d89
commit
c51f744f8f
1 changed files with 0 additions and 42 deletions
|
|
@ -1,42 +0,0 @@
|
|||
package ei.engine.math;
|
||||
|
||||
public class Vector2I {
|
||||
private int x;
|
||||
private int y;
|
||||
|
||||
public Vector2I(int x, int y){
|
||||
this.x = x;
|
||||
this.y = y;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the X value
|
||||
*
|
||||
* @return the x value in the vector
|
||||
*/
|
||||
public int getX(){
|
||||
return x;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the Y value
|
||||
*
|
||||
* @return the y value in the vector
|
||||
*/
|
||||
public int getY(){
|
||||
return y;
|
||||
}
|
||||
|
||||
/**
|
||||
* Add to the vectro
|
||||
* @param i The amount to add
|
||||
*/
|
||||
public void add(int i){
|
||||
x += i;
|
||||
y += i;
|
||||
}
|
||||
|
||||
public String toString(){
|
||||
return "Vector2I["+x+","+y+"]";
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue