|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.jscience.computing.game.AbstractGame
org.jscience.computing.game.mine.MineSweeper
public class MineSweeper
An implementation of the game Mine Sweeper
| Constructor Summary | |
|---|---|
MineSweeper()
calls this(30, 16, 99, System.currentTimeMillis()) |
|
MineSweeper(int width,
int height,
int numberOfMines,
long randomSeed)
Creates a new MineSweeper object. |
|
MineSweeper(int width,
int height,
int numberOfMines,
java.util.Random random)
Creates a new MineSweeper object. |
|
| Method Summary | |
|---|---|
java.lang.Object |
clone()
DOCUMENT ME! |
boolean |
equals(java.lang.Object obj)
DOCUMENT ME! |
int |
getHeight()
DOCUMENT ME! |
int |
getWidth()
DOCUMENT ME! |
int[] |
getWinner()
DOCUMENT ME! |
int |
hashCode()
DOCUMENT ME! |
boolean |
isOpen(int column,
int row)
DOCUMENT ME! |
protected GameMove[] |
listLegalMoves()
DOCUMENT ME! |
int |
nextPlayer()
DOCUMENT ME! |
protected boolean |
popMove()
always returns false |
protected boolean |
pushMove(GameMove move)
DOCUMENT ME! |
java.lang.String |
toString()
DOCUMENT ME! |
| Methods inherited from class org.jscience.computing.game.AbstractGame |
|---|
clearRedoList, gameOver, getGameName, getLastMove, getLastPlayer, getLegalMoves, getLegalMoves, getMoveHistory, getNumberOfRedoMoves, getRedoList, getResult, isLegalMove, isWinner, loadFromFile, makeMove, numberOfMoves, numberOfPlayers, redoMove, resetLegalMoves, resetLists, saveToFile, spawnChild, undoLastMove, undoMoves |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public MineSweeper()
this(30, 16, 99, System.currentTimeMillis())
public MineSweeper(int width,
int height,
int numberOfMines,
long randomSeed)
width - DOCUMENT ME!height - DOCUMENT ME!numberOfMines - DOCUMENT ME!randomSeed - DOCUMENT ME!
public MineSweeper(int width,
int height,
int numberOfMines,
java.util.Random random)
width - DOCUMENT ME!height - DOCUMENT ME!numberOfMines - DOCUMENT ME!random - DOCUMENT ME!| Method Detail |
|---|
public java.lang.Object clone()
throws java.lang.CloneNotSupportedException
clone in interface GamePlayclone in class AbstractGamejava.lang.CloneNotSupportedException - DOCUMENT ME!AbstractGame.spawnChild(GameMove)public boolean equals(java.lang.Object obj)
equals in class java.lang.Objectobj - DOCUMENT ME!
public int hashCode()
hashCode in class java.lang.Objectprotected GameMove[] listLegalMoves()
listLegalMoves in class AbstractGameprotected boolean pushMove(GameMove move)
pushMove in class AbstractGamemove - DOCUMENT ME!
protected boolean popMove()
popMove in class AbstractGamepublic int nextPlayer()
public int[] getWinner()
public int getWidth()
public int getHeight()
public boolean isOpen(int column,
int row)
column - DOCUMENT ME!row - DOCUMENT ME!
public java.lang.String toString()
toString in class AbstractGame
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||