cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages
Class GameInfoMessage

java.lang.Object
  extended by cz.cuni.amis.pogamut.base.communication.messages.InfoMessage
      extended by cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.GameInfo
          extended by cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.GameInfoMessage
All Implemented Interfaces:
IWorldChangeEvent, IWorldObjectUpdatedEvent, IWorldEvent, IWorldObject, ICompositeWorldObject, Event

public class GameInfoMessage
extends GameInfo
implements IWorldObjectUpdatedEvent

Implementation of the GameBots2004 message NFO contains also its Local/Shared/Static subpart class definitions..

Complete message documentation: Asynchronous message. Sent as response to READY command. Information about the game. What type of game is it going to be, number of teams, maximum size of teams etc.


Nested Class Summary
 class GameInfoMessage.GameInfoLocalMessage
          Implementation of the local part of the GameBots2004 message NFO, used to facade NFOMessage.
 class GameInfoMessage.GameInfoSharedMessage
          Implementation of the shared part of the GameBots2004 message NFO, used to facade NFOMessage.
 class GameInfoMessage.GameInfoStaticMessage
          Implementation of the static part of the GameBots2004 message NFO, used to facade NFOMessage.
 
Nested classes/interfaces inherited from class cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.GameInfo
GameInfo.GameInfoUpdate
 
Field Summary
protected  Location BlueBaseLocation
          Location of the base spawning the blue flag (team 1) (BotCTFGame).
protected  boolean BotsPaused
          If the game is paused just for bots - human controlled players can normally move.
protected  Location DisperserLocation
          Sent only in BotScenario game type.
protected  double DisperserRadius
          Sent only in BotScenario game type.
protected  double FactoryAdrenalineCount
          Sent only in BotScenario game type.
protected  Location FactoryLocation
          Sent only in BotScenario game type.
protected  double FactoryRadius
          Sent only in BotScenario game type.
protected  java.lang.String FactorySpawnType
          Sent only in BotScenario game type.
protected  Location FirstDomPointLocation
          Location of the first dom point (BotDoubleDomination).
protected  int FragLimit
          Number of kills needed to win game (BotDeathMatch only).
protected  boolean GamePaused
          If the game is paused - nobody can move.
protected  java.lang.String Gametype
          What you are playing (BotDeathMatch, BotTeamGame, BotCTFGame,BotDoubleDomination).
protected  long GoalTeamScore
          Number of points a team needs to win the game (BotTeamGame, BotCTFGame, BotDoubleDomination).
protected  java.lang.String Level
          Name of map in game.
protected  int MaxTeams
          Max number of teams.
protected  int MaxTeamSize
          Max number of players per side (BotTeamGame, BotCTFGame, BotDoubleDomination).
protected  Location RedBaseLocation
          Location of the base spawning the red flag (team 0) (BotCTFGame).
protected  Location SecondDomPointLocation
          Location of the second dom point (BotDoubleDomination).
protected  ITeamId TeamId
           
protected  double TimeLimit
          Maximum time game will last (if tied at end may goe to "sudden death overtime" - depends on the game type).
protected  boolean WeaponStay
          If true respawned weapons will stay on the ground after picked up (but bot cannot pickup same weapon twice).
 
Fields inherited from class cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.GameInfo
GameInfoId, PROTOTYPE, SimTime
 
Constructor Summary
GameInfoMessage()
          Parameter-less contructor for the message.
GameInfoMessage(GameInfoMessage original)
          Cloning constructor from the full message.
GameInfoMessage(java.lang.String Gametype, java.lang.String Level, boolean WeaponStay, double TimeLimit, int FragLimit, long GoalTeamScore, int MaxTeams, int MaxTeamSize, Location RedBaseLocation, Location BlueBaseLocation, Location FirstDomPointLocation, Location SecondDomPointLocation, boolean GamePaused, boolean BotsPaused, Location FactoryLocation, double FactoryRadius, Location DisperserLocation, double DisperserRadius, double FactoryAdrenalineCount, java.lang.String FactorySpawnType)
          Creates new instance of the message GameInfo.
 
Method Summary
 Location getBlueBaseLocation()
          Location of the base spawning the blue flag (team 1) (BotCTFGame).
 Location getDisperserLocation()
          Sent only in BotScenario game type.
 double getDisperserRadius()
          Sent only in BotScenario game type.
 double getFactoryAdrenalineCount()
          Sent only in BotScenario game type.
 Location getFactoryLocation()
          Sent only in BotScenario game type.
 double getFactoryRadius()
          Sent only in BotScenario game type.
 java.lang.String getFactorySpawnType()
          Sent only in BotScenario game type.
 Location getFirstDomPointLocation()
          Location of the first dom point (BotDoubleDomination).
 int getFragLimit()
          Number of kills needed to win game (BotDeathMatch only).
 java.lang.String getGametype()
          What you are playing (BotDeathMatch, BotTeamGame, BotCTFGame,BotDoubleDomination).
 long getGoalTeamScore()
          Number of points a team needs to win the game (BotTeamGame, BotCTFGame, BotDoubleDomination).
 UnrealId getId()
          Returns an id of the object that is unique among all world objects.
 java.lang.String getLevel()
          Name of map in game.
 GameInfoLocal getLocal()
           
 int getMaxTeams()
          Max number of teams.
 int getMaxTeamSize()
          Max number of players per side (BotTeamGame, BotCTFGame, BotDoubleDomination).
 Location getRedBaseLocation()
          Location of the base spawning the red flag (team 0) (BotCTFGame).
 Location getSecondDomPointLocation()
          Location of the second dom point (BotDoubleDomination).
 GameInfoShared getShared()
           
 GameInfoStatic getStatic()
           
 ITeamId getTeamId()
           
 double getTimeLimit()
          Maximum time game will last (if tied at end may goe to "sudden death overtime" - depends on the game type).
 boolean isBotsPaused()
          If the game is paused just for bots - human controlled players can normally move.
 boolean isGamePaused()
          If the game is paused - nobody can move.
 boolean isWeaponStay()
          If true respawned weapons will stay on the ground after picked up (but bot cannot pickup same weapon twice).
protected  void setTeamId(ITeamId TeamId)
          Used by Yylex to slip corretn TeamId.
 java.lang.String toHtmlString()
           
 java.lang.String toString()
           
 IWorldObjectUpdateResult<IWorldObject> update(IWorldObject object)
           
 
Methods inherited from class cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.GameInfo
getSimTime, setSimTime
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface cz.cuni.amis.pogamut.base.communication.translator.event.IWorldChangeEvent
getSimTime
 

Field Detail

TeamId

protected ITeamId TeamId

Gametype

protected java.lang.String Gametype
What you are playing (BotDeathMatch, BotTeamGame, BotCTFGame,BotDoubleDomination).


Level

protected java.lang.String Level
Name of map in game.


WeaponStay

protected boolean WeaponStay
If true respawned weapons will stay on the ground after picked up (but bot cannot pickup same weapon twice).


TimeLimit

protected double TimeLimit
Maximum time game will last (if tied at end may goe to "sudden death overtime" - depends on the game type).


FragLimit

protected int FragLimit
Number of kills needed to win game (BotDeathMatch only).


GoalTeamScore

protected long GoalTeamScore
Number of points a team needs to win the game (BotTeamGame, BotCTFGame, BotDoubleDomination).


MaxTeams

protected int MaxTeams
Max number of teams. Valid team range will be 0 to (MaxTeams - 1) (BotTeamGame, BotCTFGame, BotDoubleDomination). Usually there will be two teams - 0 and 1.


MaxTeamSize

protected int MaxTeamSize
Max number of players per side (BotTeamGame, BotCTFGame, BotDoubleDomination).


RedBaseLocation

protected Location RedBaseLocation
Location of the base spawning the red flag (team 0) (BotCTFGame).


BlueBaseLocation

protected Location BlueBaseLocation
Location of the base spawning the blue flag (team 1) (BotCTFGame).


FirstDomPointLocation

protected Location FirstDomPointLocation
Location of the first dom point (BotDoubleDomination).


SecondDomPointLocation

protected Location SecondDomPointLocation
Location of the second dom point (BotDoubleDomination).


GamePaused

protected boolean GamePaused
If the game is paused - nobody can move.


BotsPaused

protected boolean BotsPaused
If the game is paused just for bots - human controlled players can normally move.


FactoryLocation

protected Location FactoryLocation
Sent only in BotScenario game type. Location of the factory.


FactoryRadius

protected double FactoryRadius
Sent only in BotScenario game type. Radius of the factory.


DisperserLocation

protected Location DisperserLocation
Sent only in BotScenario game type. Location of the goal point where UDamagePack should be taken.


DisperserRadius

protected double DisperserRadius
Sent only in BotScenario game type. Radius of the disperser point.


FactoryAdrenalineCount

protected double FactoryAdrenalineCount
Sent only in BotScenario game type. How much adrenaline we need to activate the factory.


FactorySpawnType

protected java.lang.String FactorySpawnType
Sent only in BotScenario game type. Pickup class our factory spawns when used properly. Item will be spawned at the bot's location.

Constructor Detail

GameInfoMessage

public GameInfoMessage()
Parameter-less contructor for the message.


GameInfoMessage

public GameInfoMessage(java.lang.String Gametype,
                       java.lang.String Level,
                       boolean WeaponStay,
                       double TimeLimit,
                       int FragLimit,
                       long GoalTeamScore,
                       int MaxTeams,
                       int MaxTeamSize,
                       Location RedBaseLocation,
                       Location BlueBaseLocation,
                       Location FirstDomPointLocation,
                       Location SecondDomPointLocation,
                       boolean GamePaused,
                       boolean BotsPaused,
                       Location FactoryLocation,
                       double FactoryRadius,
                       Location DisperserLocation,
                       double DisperserRadius,
                       double FactoryAdrenalineCount,
                       java.lang.String FactorySpawnType)
Creates new instance of the message GameInfo. Asynchronous message. Sent as response to READY command. Information about the game. What type of game is it going to be, number of teams, maximum size of teams etc. Corresponding GameBots message is NFO.

Parameters:
Gametype - What you are playing (BotDeathMatch, BotTeamGame, BotCTFGame,BotDoubleDomination).
Level - Name of map in game.
WeaponStay - If true respawned weapons will stay on the ground after picked up (but bot cannot pickup same weapon twice).
TimeLimit - Maximum time game will last (if tied at end may goe to "sudden death overtime" - depends on the game type).
FragLimit - Number of kills needed to win game (BotDeathMatch only).
GoalTeamScore - Number of points a team needs to win the game (BotTeamGame, BotCTFGame, BotDoubleDomination).
MaxTeams - Max number of teams. Valid team range will be 0 to (MaxTeams - 1) (BotTeamGame, BotCTFGame, BotDoubleDomination). Usually there will be two teams - 0 and 1.
MaxTeamSize - Max number of players per side (BotTeamGame, BotCTFGame, BotDoubleDomination).
RedBaseLocation - Location of the base spawning the red flag (team 0) (BotCTFGame).
BlueBaseLocation - Location of the base spawning the blue flag (team 1) (BotCTFGame).
FirstDomPointLocation - Location of the first dom point (BotDoubleDomination).
SecondDomPointLocation - Location of the second dom point (BotDoubleDomination).
GamePaused - If the game is paused - nobody can move.
BotsPaused - If the game is paused just for bots - human controlled players can normally move.
FactoryLocation - Sent only in BotScenario game type. Location of the factory.
FactoryRadius - Sent only in BotScenario game type. Radius of the factory.
DisperserLocation - Sent only in BotScenario game type. Location of the goal point where UDamagePack should be taken.
DisperserRadius - Sent only in BotScenario game type. Radius of the disperser point.
FactoryAdrenalineCount - Sent only in BotScenario game type. How much adrenaline we need to activate the factory.
FactorySpawnType - Sent only in BotScenario game type. Pickup class our factory spawns when used properly. Item will be spawned at the bot's location.

GameInfoMessage

public GameInfoMessage(GameInfoMessage original)
Cloning constructor from the full message.

Parameters:
original -
Method Detail

getId

public UnrealId getId()
Description copied from interface: IWorldObject
Returns an id of the object that is unique among all world objects.

Specified by:
getId in interface IWorldObjectUpdatedEvent
Specified by:
getId in interface IWorldObject
Overrides:
getId in class GameInfo
Returns:

setTeamId

protected void setTeamId(ITeamId TeamId)
Used by Yylex to slip corretn TeamId.


getTeamId

public ITeamId getTeamId()

getGametype

public java.lang.String getGametype()
Description copied from class: GameInfo
What you are playing (BotDeathMatch, BotTeamGame, BotCTFGame,BotDoubleDomination).

Specified by:
getGametype in class GameInfo

getLevel

public java.lang.String getLevel()
Description copied from class: GameInfo
Name of map in game.

Specified by:
getLevel in class GameInfo

isWeaponStay

public boolean isWeaponStay()
Description copied from class: GameInfo
If true respawned weapons will stay on the ground after picked up (but bot cannot pickup same weapon twice).

Specified by:
isWeaponStay in class GameInfo

getTimeLimit

public double getTimeLimit()
Description copied from class: GameInfo
Maximum time game will last (if tied at end may goe to "sudden death overtime" - depends on the game type).

Specified by:
getTimeLimit in class GameInfo

getFragLimit

public int getFragLimit()
Description copied from class: GameInfo
Number of kills needed to win game (BotDeathMatch only).

Specified by:
getFragLimit in class GameInfo

getGoalTeamScore

public long getGoalTeamScore()
Description copied from class: GameInfo
Number of points a team needs to win the game (BotTeamGame, BotCTFGame, BotDoubleDomination).

Specified by:
getGoalTeamScore in class GameInfo

getMaxTeams

public int getMaxTeams()
Description copied from class: GameInfo
Max number of teams. Valid team range will be 0 to (MaxTeams - 1) (BotTeamGame, BotCTFGame, BotDoubleDomination). Usually there will be two teams - 0 and 1.

Specified by:
getMaxTeams in class GameInfo

getMaxTeamSize

public int getMaxTeamSize()
Description copied from class: GameInfo
Max number of players per side (BotTeamGame, BotCTFGame, BotDoubleDomination).

Specified by:
getMaxTeamSize in class GameInfo

getRedBaseLocation

public Location getRedBaseLocation()
Description copied from class: GameInfo
Location of the base spawning the red flag (team 0) (BotCTFGame).

Specified by:
getRedBaseLocation in class GameInfo

getBlueBaseLocation

public Location getBlueBaseLocation()
Description copied from class: GameInfo
Location of the base spawning the blue flag (team 1) (BotCTFGame).

Specified by:
getBlueBaseLocation in class GameInfo

getFirstDomPointLocation

public Location getFirstDomPointLocation()
Description copied from class: GameInfo
Location of the first dom point (BotDoubleDomination).

Specified by:
getFirstDomPointLocation in class GameInfo

getSecondDomPointLocation

public Location getSecondDomPointLocation()
Description copied from class: GameInfo
Location of the second dom point (BotDoubleDomination).

Specified by:
getSecondDomPointLocation in class GameInfo

isGamePaused

public boolean isGamePaused()
Description copied from class: GameInfo
If the game is paused - nobody can move.

Specified by:
isGamePaused in class GameInfo

isBotsPaused

public boolean isBotsPaused()
Description copied from class: GameInfo
If the game is paused just for bots - human controlled players can normally move.

Specified by:
isBotsPaused in class GameInfo

getFactoryLocation

public Location getFactoryLocation()
Description copied from class: GameInfo
Sent only in BotScenario game type. Location of the factory.

Specified by:
getFactoryLocation in class GameInfo

getFactoryRadius

public double getFactoryRadius()
Description copied from class: GameInfo
Sent only in BotScenario game type. Radius of the factory.

Specified by:
getFactoryRadius in class GameInfo

getDisperserLocation

public Location getDisperserLocation()
Description copied from class: GameInfo
Sent only in BotScenario game type. Location of the goal point where UDamagePack should be taken.

Specified by:
getDisperserLocation in class GameInfo

getDisperserRadius

public double getDisperserRadius()
Description copied from class: GameInfo
Sent only in BotScenario game type. Radius of the disperser point.

Specified by:
getDisperserRadius in class GameInfo

getFactoryAdrenalineCount

public double getFactoryAdrenalineCount()
Description copied from class: GameInfo
Sent only in BotScenario game type. How much adrenaline we need to activate the factory.

Specified by:
getFactoryAdrenalineCount in class GameInfo

getFactorySpawnType

public java.lang.String getFactorySpawnType()
Description copied from class: GameInfo
Sent only in BotScenario game type. Pickup class our factory spawns when used properly. Item will be spawned at the bot's location.

Specified by:
getFactorySpawnType in class GameInfo

getLocal

public GameInfoLocal getLocal()
Specified by:
getLocal in interface ICompositeWorldObject

getShared

public GameInfoShared getShared()
Specified by:
getShared in interface ICompositeWorldObject

getStatic

public GameInfoStatic getStatic()
Specified by:
getStatic in interface ICompositeWorldObject

update

public IWorldObjectUpdateResult<IWorldObject> update(IWorldObject object)
Specified by:
update in interface IWorldObjectUpdatedEvent

toString

public java.lang.String toString()
Overrides:
toString in class GameInfo

toHtmlString

public java.lang.String toHtmlString()
Overrides:
toHtmlString in class GameInfo