Want to contribute? Fork me on Codeberg.org!
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.
Chess/src/BoardCoordinate.java

13 lines
333 B

2 years ago
public class BoardCoordinate extends Coordinate {
public BoardCoordinate(int x, int y) {
super(x, y);
}
@Override
public boolean equals(Object obj) {
if (obj == this) return true;
if (!(obj instanceof BoardCoordinate other)) return false;
return other.x == x && other.y == y;
}
}