|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface GameViewInterface
This interface is used as a wrapper around the model, for the View's sake. Note: You may return null from trees(), flagPosition() and playerInfo() (e.g. if the teams haven't connected yet).
Nested Class Summary | |
---|---|
static interface |
GameViewInterface.PlayerInfo
Contains player information relevant to the View |
Method Summary | |
---|---|
int |
clock()
How long the game has been going on (in seconds) |
java.awt.geom.RectangularShape |
fieldSize()
The size of the field (in metres) |
java.awt.geom.Point2D |
flagPosition(Side s)
Position of a team's flag |
java.awt.geom.RectangularShape |
jail(Side side)
The size of each jail (in metres) |
java.util.Collection<GameViewInterface.PlayerInfo> |
playerInfo(Side s)
Position, orientation for all players on a team |
double |
playerRadius()
The radius of each player (in metres) |
int |
score(Side s)
What's the given team's score? |
java.lang.String |
statusMessage()
A status message: any information the Model would like to convey |
TeamColor |
teamColor(Side s)
What is the given team's colour? |
double |
treeRadius()
The radius of each tree (in metres) |
java.util.Collection<java.awt.geom.Point2D> |
trees()
Positions of all trees |
Method Detail |
---|
java.awt.geom.RectangularShape fieldSize()
java.awt.geom.RectangularShape jail(Side side)
double playerRadius()
double treeRadius()
java.lang.String statusMessage()
int clock()
TeamColor teamColor(Side s)
int score(Side s)
java.util.Collection<java.awt.geom.Point2D> trees()
java.awt.geom.Point2D flagPosition(Side s)
java.util.Collection<GameViewInterface.PlayerInfo> playerInfo(Side s)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |