cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages
Class BombInfoMessage.BombInfoSharedMessage

java.lang.Object
  extended by cz.cuni.amis.pogamut.base.communication.messages.InfoMessage
      extended by cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.BombInfoShared
          extended by cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.BombInfoMessage.BombInfoSharedMessage
All Implemented Interfaces:
IWorldObject, ISharedWorldObject, java.lang.Cloneable
Enclosing class:
BombInfoMessage

public class BombInfoMessage.BombInfoSharedMessage
extends BombInfoShared

Implementation of the shared part of the GameBots2004 message BOM, used to facade BOMMessage.

Complete message documentation: Synchronous message. BombInfo contains all info about the bomb in the BotBombingRun game mode. Is not sent in other game types.


Field Summary
protected  UnrealIdProperty myHolder
          Id of player/bot holding the bomb.
protected  IntegerProperty myHolderTeam
          The team of the current holder (if any).
protected  LocationProperty myLocation
          An absolute location of the bomb (Sent if we can actually see the flag).
protected  StringProperty myState
          Represents the state the bomb is in.
protected  VelocityProperty myVelocity
          Current velocity of the bomb.
protected  java.util.HashMap<PropertyId,ISharedProperty> propertyMap
           
 
Fields inherited from class cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.BombInfoShared
HolderPropertyToken, HolderTeamPropertyToken, LocationPropertyToken, SharedPropertyTokens, SimTime, StatePropertyToken, VelocityPropertyToken
 
Constructor Summary
BombInfoMessage.BombInfoSharedMessage()
           
 
Method Summary
 BombInfoMessage.BombInfoSharedMessage clone()
           
 UnrealId getHolder()
          Id of player/bot holding the bomb.
 java.lang.Integer getHolderTeam()
          The team of the current holder (if any).
 UnrealId getId()
          An unique Id for this bomb, assigned by the game.
 Location getLocation()
          An absolute location of the bomb (Sent if we can actually see the flag).
 java.util.Map<PropertyId,ISharedProperty> getProperties()
           
 ISharedProperty getProperty(PropertyId id)
           
 java.lang.String getState()
          Represents the state the bomb is in.
 Velocity getVelocity()
          Current velocity of the bomb.
 java.lang.String toHtmlString()
           
 java.lang.String toString()
           
 
Methods inherited from class cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.BombInfoShared
getCompositeClass, getSimTime, setSimTime
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

propertyMap

protected java.util.HashMap<PropertyId,ISharedProperty> propertyMap

myVelocity

protected VelocityProperty myVelocity
Current velocity of the bomb. TODO not sure if this actually does smthing


myLocation

protected LocationProperty myLocation
An absolute location of the bomb (Sent if we can actually see the flag).


myHolder

protected UnrealIdProperty myHolder
Id of player/bot holding the bomb. (Sent if we can actually see the bomb and the bomb is being carried, or if the bomb is being carried by us).


myHolderTeam

protected IntegerProperty myHolderTeam
The team of the current holder (if any).


myState

protected StringProperty myState
Represents the state the bomb is in. Can be "Held", "Dropped" or "Home".

Constructor Detail

BombInfoMessage.BombInfoSharedMessage

public BombInfoMessage.BombInfoSharedMessage()
Method Detail

clone

public BombInfoMessage.BombInfoSharedMessage clone()
Specified by:
clone in interface ISharedWorldObject
Specified by:
clone in class BombInfoShared

getProperty

public ISharedProperty getProperty(PropertyId id)

getProperties

public java.util.Map<PropertyId,ISharedProperty> getProperties()

getId

public UnrealId getId()
An unique Id for this bomb, assigned by the game.

Specified by:
getId in interface IWorldObject
Specified by:
getId in class BombInfoShared
Returns:

getVelocity

public Velocity getVelocity()
Current velocity of the bomb. TODO not sure if this actually does smthing

Specified by:
getVelocity in class BombInfoShared

getLocation

public Location getLocation()
An absolute location of the bomb (Sent if we can actually see the flag).

Specified by:
getLocation in class BombInfoShared

getHolder

public UnrealId getHolder()
Id of player/bot holding the bomb. (Sent if we can actually see the bomb and the bomb is being carried, or if the bomb is being carried by us).

Specified by:
getHolder in class BombInfoShared

getHolderTeam

public java.lang.Integer getHolderTeam()
The team of the current holder (if any).

Specified by:
getHolderTeam in class BombInfoShared

getState

public java.lang.String getState()
Represents the state the bomb is in. Can be "Held", "Dropped" or "Home".

Specified by:
getState in class BombInfoShared

toString

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

toHtmlString

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