|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.sf.freecol.client.control.PreGameController
public final class PreGameController
The controller that will be used before the game starts.
| Field Summary | |
|---|---|
private FreeColClient |
freeColClient
|
private GUI |
gui
|
private static java.util.logging.Logger |
logger
|
| Constructor Summary | |
|---|---|
PreGameController(FreeColClient freeColClient,
GUI gui)
The constructor to use. |
|
| Method Summary | |
|---|---|
private void |
addPlayerResources(java.lang.String nationId)
Add player-specific resources to the resource manager. |
void |
chat(java.lang.String message)
Sends a chat message. |
void |
requestLaunch()
Requests the game to be started. |
void |
sendGameOptions()
Sends the GameOptions to the server. |
void |
sendMapGeneratorOptions()
Sends the MapGeneratorOptions to the server. |
void |
setAvailable(Nation nation,
NationOptions.NationState state)
|
void |
setNation(Nation nation)
Sets this client's player's nation. |
void |
setNationType(NationType nationType)
Sets this client's player's nation type. |
void |
setReady(boolean ready)
Sets this client to be (or not be) ready to start the game. |
void |
startGame()
Starts the game. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private static final java.util.logging.Logger logger
private FreeColClient freeColClient
private GUI gui
| Constructor Detail |
|---|
public PreGameController(FreeColClient freeColClient,
GUI gui)
freeColClient - The main controller.| Method Detail |
|---|
public void setReady(boolean ready)
ready - Indicates wether or not this client is ready
to start the game.public void setNation(Nation nation)
nation - Which nation this player wishes to set.public void setNationType(NationType nationType)
nationType - Which nation this player wishes to set.
public void setAvailable(Nation nation,
NationOptions.NationState state)
public void requestLaunch()
public void chat(java.lang.String message)
message - The text of the message.public void sendGameOptions()
GameOptions to the server.
This method should be called after updating that object.
public void sendMapGeneratorOptions()
MapGeneratorOptions to the server.
This method should be called after updating that object.
private void addPlayerResources(java.lang.String nationId)
nationId - The player nation identifier.public void startGame()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||