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

Package class diagram package IncomingProjectileSharedImpl
java.lang.Object
  extended by cz.cuni.amis.pogamut.base.communication.messages.InfoMessage
      extended by cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.IncomingProjectileShared
          extended by cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.IncomingProjectileSharedImpl
All Implemented Interfaces:
IWorldObject, ILocated, ISharedWorldObject, Cloneable

public class IncomingProjectileSharedImpl
extends IncomingProjectileShared

Implementation of the shared part of the GameBots2004 message PRJ.

Complete message documentation: Both asynchronous and synchronous message. Incoming projectile that we can see.


Nested Class Summary
static class IncomingProjectileSharedImpl.IncomingProjectileSharedUpdate
           
 
Field Summary
protected  UnrealId Id
          Unique Id of the projectile.
protected  DoubleProperty myDamageRadius
          If the projectile has splash damage, how big it is – in ut units.
protected  Vector3dProperty myDirection
          Which direction projectile is heading to -> orientation vector.
protected  LocationProperty myLocation
          Current location of the projectile.
protected  LocationProperty myOrigin
          Possition of the origin, when combined with direction can define the line of fire.
protected  DoubleProperty mySpeed
          Current speed of the projectile.
protected  StringProperty myType
          The class of the projectile (so you know what is flying against you).
protected  VelocityProperty myVelocity
          Current velocity vector of the projectile.
protected  HashMap<PropertyId,ISharedProperty> propertyMap
           
 
Fields inherited from class cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.IncomingProjectileShared
DamageRadiusPropertyToken, DirectionPropertyToken, LocationPropertyToken, OriginPropertyToken, SharedPropertyTokens, SimTime, SpeedPropertyToken, TypePropertyToken, VelocityPropertyToken
 
Constructor Summary
IncomingProjectileSharedImpl(IncomingProjectileSharedImpl source)
           
IncomingProjectileSharedImpl(WorldObjectId objectId, Collection<ISharedProperty> properties)
           
 
Method Summary
 IncomingProjectileSharedImpl clone()
           
 double getDamageRadius()
          If the projectile has splash damage, how big it is – in ut units.
 javax.vecmath.Vector3d getDirection()
          Which direction projectile is heading to -> orientation vector.
 UnrealId getId()
          Unique Id of the projectile.
 Location getLocation()
          Current location of the projectile.
 Location getOrigin()
          Possition of the origin, when combined with direction can define the line of fire.
 Map<PropertyId,ISharedProperty> getProperties()
           
 ISharedProperty getProperty(PropertyId id)
           
 double getSpeed()
          Current speed of the projectile.
 String getType()
          The class of the projectile (so you know what is flying against you).
 Velocity getVelocity()
          Current velocity vector of the projectile.
 void setSimTime(long SimTime)
          Used by Yylex to slip correct time of the object or programmatically.
 String toHtmlString()
           
 String toString()
           
 
Methods inherited from class cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.IncomingProjectileShared
getCompositeClass, getSimTime
 
Methods inherited from class cz.cuni.amis.pogamut.base.communication.messages.InfoMessage
toJsonLiteral
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

propertyMap

protected HashMap<PropertyId,ISharedProperty> propertyMap

Id

protected UnrealId Id
Unique Id of the projectile.


myDirection

protected Vector3dProperty myDirection
Which direction projectile is heading to -> orientation vector.


myLocation

protected LocationProperty myLocation
Current location of the projectile.


myVelocity

protected VelocityProperty myVelocity
Current velocity vector of the projectile.


mySpeed

protected DoubleProperty mySpeed
Current speed of the projectile.


myOrigin

protected LocationProperty myOrigin
Possition of the origin, when combined with direction can define the line of fire.


myDamageRadius

protected DoubleProperty myDamageRadius
If the projectile has splash damage, how big it is – in ut units.


myType

protected StringProperty myType
The class of the projectile (so you know what is flying against you).

Constructor Detail

IncomingProjectileSharedImpl

public IncomingProjectileSharedImpl(IncomingProjectileSharedImpl source)

IncomingProjectileSharedImpl

public IncomingProjectileSharedImpl(WorldObjectId objectId,
                                    Collection<ISharedProperty> properties)
Method Detail

setSimTime

public void setSimTime(long SimTime)
Description copied from class: IncomingProjectileShared
Used by Yylex to slip correct time of the object or programmatically.

Overrides:
setSimTime in class IncomingProjectileShared

clone

public IncomingProjectileSharedImpl clone()
Specified by:
clone in interface ISharedWorldObject
Specified by:
clone in class IncomingProjectileShared

getProperty

public ISharedProperty getProperty(PropertyId id)

getProperties

public Map<PropertyId,ISharedProperty> getProperties()

getId

public UnrealId getId()
Unique Id of the projectile.

Specified by:
getId in interface IWorldObject
Specified by:
getId in class IncomingProjectileShared

getDirection

public javax.vecmath.Vector3d getDirection()
Which direction projectile is heading to -> orientation vector.

Specified by:
getDirection in class IncomingProjectileShared

getLocation

public Location getLocation()
Current location of the projectile.

Specified by:
getLocation in interface ILocated
Specified by:
getLocation in class IncomingProjectileShared

getVelocity

public Velocity getVelocity()
Current velocity vector of the projectile.

Specified by:
getVelocity in class IncomingProjectileShared

getSpeed

public double getSpeed()
Current speed of the projectile.

Specified by:
getSpeed in class IncomingProjectileShared

getOrigin

public Location getOrigin()
Possition of the origin, when combined with direction can define the line of fire.

Specified by:
getOrigin in class IncomingProjectileShared

getDamageRadius

public double getDamageRadius()
If the projectile has splash damage, how big it is – in ut units.

Specified by:
getDamageRadius in class IncomingProjectileShared

getType

public String getType()
The class of the projectile (so you know what is flying against you).

Specified by:
getType in class IncomingProjectileShared

toString

public String toString()
Overrides:
toString in class IncomingProjectileShared

toHtmlString

public String toHtmlString()
Overrides:
toHtmlString in class IncomingProjectileShared


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