implementation.gridpuzzle
Class GameGrid
java.lang.Object
implementation.gridpuzzle.GameGrid
public class GameGrid
- extends java.lang.Object
- Author:
- Eden_06
Methods inherited from class java.lang.Object |
clone, getClass, notify, notifyAll, wait, wait, wait |
GameGrid
public GameGrid(int width,
int height)
GameGrid
public GameGrid(GameGrid game)
distance
public static int distance(int x1,
int y1,
int x2,
int y2)
get
public int get(int x,
int y)
set
public void set(int x,
int y,
int value)
isLegal
public boolean isLegal()
highestNumber
public int highestNumber()
getWidth
public int getWidth()
getHeight
public int getHeight()
positionOf
public java.awt.Point positionOf(int value)
move
public boolean move(int x,
int y)
movements
public java.util.List<java.awt.Point> movements()
randomize
public void randomize()
initialize
public void initialize()
comparable
public boolean comparable(GameGrid g)
equals
public boolean equals(GameGrid g)
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in class java.lang.Object
finalize
protected void finalize()
throws java.lang.Throwable
- Overrides:
finalize
in class java.lang.Object
- Throws:
java.lang.Throwable
hashCode
public int hashCode()
- Overrides:
hashCode
in class java.lang.Object
toArray
protected int[] toArray()
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object