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

Package class diagram package PlayerScore
java.lang.Object
  extended by cz.cuni.amis.pogamut.base.communication.messages.InfoMessage
      extended by cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.PlayerScore
All Implemented Interfaces:
cz.cuni.amis.pogamut.base.communication.translator.event.IWorldChangeEvent, cz.cuni.amis.pogamut.base.communication.worldview.event.IWorldEvent, cz.cuni.amis.utils.listener.Event

public class PlayerScore
extends cz.cuni.amis.pogamut.base.communication.messages.InfoMessage
implements cz.cuni.amis.pogamut.base.communication.worldview.event.IWorldEvent, cz.cuni.amis.pogamut.base.communication.translator.event.IWorldChangeEvent

Definition of the event PLS.

Complete message documentation: Synchronous message. Contains the info about player score.


Field Summary
protected  int Deaths
          Number of players deaths.
protected  cz.cuni.amis.pogamut.unreal.communication.messages.UnrealId Id
          Unique Id of the player.
protected  double lastSeenTime
          When was the last time we've received info about this object.
static String PROTOTYPE
          Example how the message looks like - used during parser tests.
protected  int Score
          Number of player frags (how many times the player killed other players) or number of victory points (player frags + some special measurement that can differ from game type to game type).
protected  long SimTime
           
 
Constructor Summary
PlayerScore()
          Parameter-less contructor for the message.
PlayerScore(double lastSeenTime, cz.cuni.amis.pogamut.unreal.communication.messages.UnrealId Id, int Score, int Deaths)
          Creates new instance of the message PlayerScore.
PlayerScore(PlayerScore original)
          Cloning constructor from the full message.
 
Method Summary
 int getDeaths()
          Number of players deaths.
 cz.cuni.amis.pogamut.unreal.communication.messages.UnrealId getId()
          Unique Id of the player.
 double getLastSeenTime()
          When was the last time we've received info about this object.
 int getScore()
          Number of player frags (how many times the player killed other players) or number of victory points (player frags + some special measurement that can differ from game type to game type).
 long getSimTime()
          Simulation time in MILLI SECONDS !!!
protected  void setSimTime(long SimTime)
          Used by Yylex to slip correct time of the object or programmatically.
 String toHtmlString()
           
 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

SimTime

protected long SimTime

lastSeenTime

protected double lastSeenTime
When was the last time we've received info about this object.


Id

protected cz.cuni.amis.pogamut.unreal.communication.messages.UnrealId Id
Unique Id of the player.


Score

protected int Score
Number of player frags (how many times the player killed other players) or number of victory points (player frags + some special measurement that can differ from game type to game type).


Deaths

protected int Deaths
Number of players deaths.

Constructor Detail

PlayerScore

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


PlayerScore

public PlayerScore(double lastSeenTime,
                   cz.cuni.amis.pogamut.unreal.communication.messages.UnrealId Id,
                   int Score,
                   int Deaths)
Creates new instance of the message PlayerScore. Synchronous message. Contains the info about player score. Corresponding GameBots message is PLS.

Parameters:
lastSeenTime - When was the last time we've received info about this object.
Id - Unique Id of the player.
Score - Number of player frags (how many times the player killed other players) or number of victory points (player frags + some special measurement that can differ from game type to game type).
Deaths - Number of players deaths.

PlayerScore

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

Parameters:
original -
Method Detail

getSimTime

public long getSimTime()
Simulation time in MILLI SECONDS !!!

Specified by:
getSimTime in interface cz.cuni.amis.pogamut.base.communication.translator.event.IWorldChangeEvent
Specified by:
getSimTime in interface cz.cuni.amis.pogamut.base.communication.worldview.event.IWorldEvent

setSimTime

protected void setSimTime(long SimTime)
Used by Yylex to slip correct time of the object or programmatically.


getLastSeenTime

public double getLastSeenTime()
When was the last time we've received info about this object.


getId

public cz.cuni.amis.pogamut.unreal.communication.messages.UnrealId getId()
Unique Id of the player.


getScore

public int getScore()
Number of player frags (how many times the player killed other players) or number of victory points (player frags + some special measurement that can differ from game type to game type).


getDeaths

public int getDeaths()
Number of players deaths.


toString

public String toString()
Overrides:
toString in class cz.cuni.amis.pogamut.base.communication.messages.InfoMessage

toHtmlString

public String toHtmlString()


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