cz.cuni.amis.pogamut.ut2004.communication.messages.gbcommands
Class GameConfiguration

Package class diagram package GameConfiguration
java.lang.Object
  extended by cz.cuni.amis.pogamut.base.communication.messages.CommandMessage
      extended by cz.cuni.amis.pogamut.ut2004.communication.messages.gbcommands.GameConfiguration

public class GameConfiguration
extends CommandMessage

Representation of the GameBots2004 command CONFGAME. Configures various attributes of the game.


Field Summary
protected  String GameMessage
          Message that will be displayed in the middle of the HUD.
protected  Double GameMessageTime
          Time the displayed message will stay on the HUD.
static String PROTOTYPE
          Example how the message looks like - used during parser tests.
protected  Boolean Restart
          When set to true, the game state will be restarted (all scores reset to 0 and all players and bots will be restarted).
 
Constructor Summary
GameConfiguration()
          Creates new instance of command GameConfiguration.
GameConfiguration(Boolean Restart, String GameMessage, Double GameMessageTime)
          Creates new instance of command GameConfiguration.
GameConfiguration(GameConfiguration original)
          Cloning constructor.
 
Method Summary
 String getGameMessage()
          Message that will be displayed in the middle of the HUD.
 Double getGameMessageTime()
          Time the displayed message will stay on the HUD.
 Boolean isRestart()
          When set to true, the game state will be restarted (all scores reset to 0 and all players and bots will be restarted).
 GameConfiguration setGameMessage(String GameMessage)
          Message that will be displayed in the middle of the HUD.
 GameConfiguration setGameMessageTime(Double GameMessageTime)
          Time the displayed message will stay on the HUD.
 GameConfiguration setRestart(Boolean Restart)
          When set to true, the game state will be restarted (all scores reset to 0 and all players and bots will be restarted).
 String toHtmlString()
           
 String toMessage()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

PROTOTYPE

public static final String PROTOTYPE
Example how the message looks like - used during parser tests.

See Also:
Constant Field Values

Restart

protected Boolean Restart
When set to true, the game state will be restarted (all scores reset to 0 and all players and bots will be restarted). This does not affect Unreal native bots! Note that the restart is then announced by GameRestarted message and when finished another GameRestarted message is sent to mark the end.


GameMessage

protected String GameMessage
Message that will be displayed in the middle of the HUD.


GameMessageTime

protected Double GameMessageTime
Time the displayed message will stay on the HUD.

Constructor Detail

GameConfiguration

public GameConfiguration(Boolean Restart,
                         String GameMessage,
                         Double GameMessageTime)
Creates new instance of command GameConfiguration. Configures various attributes of the game. Corresponding GameBots message for this command is CONFGAME.

Parameters:
Restart - When set to true, the game state will be restarted (all scores reset to 0 and all players and bots will be restarted). This does not affect Unreal native bots! Note that the restart is then announced by GameRestarted message and when finished another GameRestarted message is sent to mark the end.
GameMessage - Message that will be displayed in the middle of the HUD.
GameMessageTime - Time the displayed message will stay on the HUD.

GameConfiguration

public GameConfiguration()
Creates new instance of command GameConfiguration. Configures various attributes of the game. Corresponding GameBots message for this command is CONFGAME.

WARNING: this is empty-command constructor, you have to use setters to fill it up with data that should be sent to GameBots2004!


GameConfiguration

public GameConfiguration(GameConfiguration original)
Cloning constructor.

Parameters:
original -
Method Detail

isRestart

public Boolean isRestart()
When set to true, the game state will be restarted (all scores reset to 0 and all players and bots will be restarted). This does not affect Unreal native bots! Note that the restart is then announced by GameRestarted message and when finished another GameRestarted message is sent to mark the end.


setRestart

public GameConfiguration setRestart(Boolean Restart)
When set to true, the game state will be restarted (all scores reset to 0 and all players and bots will be restarted). This does not affect Unreal native bots! Note that the restart is then announced by GameRestarted message and when finished another GameRestarted message is sent to mark the end.


getGameMessage

public String getGameMessage()
Message that will be displayed in the middle of the HUD.


setGameMessage

public GameConfiguration setGameMessage(String GameMessage)
Message that will be displayed in the middle of the HUD.


getGameMessageTime

public Double getGameMessageTime()
Time the displayed message will stay on the HUD.


setGameMessageTime

public GameConfiguration setGameMessageTime(Double GameMessageTime)
Time the displayed message will stay on the HUD.


toString

public String toString()
Overrides:
toString in class CommandMessage

toHtmlString

public String toHtmlString()

toMessage

public String toMessage()


Copyright © 2014 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All Rights Reserved.