12345678910111213141516171819202122232425262728293031323334353637383940414243444546 |
- package pathgame.algorithm;
- public class Coord {
- private int x, y;
- private boolean isBoatTile = false;
- public Coord(int x, int y) {
- this.x = x;
- this.y = y;
- }
- public Coord(int x, int y, boolean isBoatTile) {
- this.x = x;
- this.y = y;
- this.isBoatTile = isBoatTile;
- }
- public int getX() {
- return x;
- }
- public int getY() {
- return y;
- }
- public void changeX(int x) {
- this.x += x;
- }
- public void changeY(int y) {
- this.y += y;
- }
- public void setCoord(int x, int y) {
- this.x = x;
- this.y = y;
- }
- public boolean isBoatTile() {
- return isBoatTile;
- }
- public void setBoatTile(boolean isBoatTile) {
- this.isBoatTile = isBoatTile;
- }
- }
|