|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface GameInterface
This interface is used as a wrapper around the model, for the sake of the View.
Nested Class Summary | |
---|---|
static interface |
GameInterface.PlayerInfo
Contains player information relevant to the View |
static class |
GameInterface.Side
Sides of the field |
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(GameInterface.Side s)
Position of a team's flag |
java.awt.geom.RectangularShape |
jail(GameInterface.Side side)
The size of each jail (in metres) |
java.util.Collection<GameInterface.PlayerInfo> |
playerInfo(GameInterface.Side s)
Position, orientation for all players on a team |
double |
playerRadius()
The radius of each player (in metres) |
int |
score(GameInterface.Side s)
What's the given team's score? |
java.lang.String |
statusMessage()
A status message: any information the Model would like to convey |
java.awt.Color |
teamColor(GameInterface.Side s)
What is the given team's colour? |
boolean |
teamsConnected()
Have both teams connected (and identified their 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(GameInterface.Side side)
double playerRadius()
double treeRadius()
java.lang.String statusMessage()
boolean teamsConnected()
int clock()
java.awt.Color teamColor(GameInterface.Side s)
int score(GameInterface.Side s)
java.util.Collection<java.awt.geom.Point2D> trees()
java.awt.geom.Point2D flagPosition(GameInterface.Side s)
java.util.Collection<GameInterface.PlayerInfo> playerInfo(GameInterface.Side s)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |