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

java.lang.Object
  extended by cz.cuni.amis.pogamut.base.communication.messages.CommandMessage
      extended by cz.cuni.amis.pogamut.ut2004.communication.messages.gbcommands.Shoot

public class Shoot
extends CommandMessage

Representation of the GameBots2004 command SHOOT. Start firing your weapon (until receives STOPSHOOT command, or run out of ammo or die).


Field Summary
protected  java.lang.Boolean Alt
          If you send True to this you will alt fire instead of normal fire.
protected  Location Location
          Location you want to shoot at.
static java.lang.String PROTOTYPE
          Example how the message looks like - used during parser tests.
protected  UnrealId Target
          The unique Id of your target.
 
Constructor Summary
Shoot()
          Creates new instance of command Shoot.
Shoot(Location Location, UnrealId Target, java.lang.Boolean Alt)
          Creates new instance of command Shoot.
Shoot(Shoot original)
          Cloning constructor.
 
Method Summary
 Location getLocation()
          Location you want to shoot at.
 UnrealId getTarget()
          The unique Id of your target.
 java.lang.Boolean isAlt()
          If you send True to this you will alt fire instead of normal fire.
 Shoot setAlt(java.lang.Boolean Alt)
          If you send True to this you will alt fire instead of normal fire.
 Shoot setLocation(Location Location)
          Location you want to shoot at.
 Shoot setTarget(UnrealId Target)
          The unique Id of your target.
 java.lang.String toHtmlString()
           
 java.lang.String toMessage()
           
 java.lang.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 java.lang.String PROTOTYPE
Example how the message looks like - used during parser tests.

See Also:
Constant Field Values

Location

protected Location Location
Location you want to shoot at.


Target

protected UnrealId Target
The unique Id of your target. If you specify a target, and it is visible to you, the server will provide aim correction and target leading for you. If not you just shoot at the location specified.


Alt

protected java.lang.Boolean Alt
If you send True to this you will alt fire instead of normal fire. For normal fire you don't need to send this argument at all.

Constructor Detail

Shoot

public Shoot(Location Location,
             UnrealId Target,
             java.lang.Boolean Alt)
Creates new instance of command Shoot. Start firing your weapon (until receives STOPSHOOT command, or run out of ammo or die). Corresponding GameBots message for this command is SHOOT.

Parameters:
Location - Location you want to shoot at.
Target - The unique Id of your target. If you specify a target, and it is visible to you, the server will provide aim correction and target leading for you. If not you just shoot at the location specified.
Alt - If you send True to this you will alt fire instead of normal fire. For normal fire you don't need to send this argument at all.

Shoot

public Shoot()
Creates new instance of command Shoot. Start firing your weapon (until receives STOPSHOOT command, or run out of ammo or die). Corresponding GameBots message for this command is SHOOT.

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


Shoot

public Shoot(Shoot original)
Cloning constructor.

Parameters:
original -
Method Detail

getLocation

public Location getLocation()
Location you want to shoot at.


setLocation

public Shoot setLocation(Location Location)
Location you want to shoot at.


getTarget

public UnrealId getTarget()
The unique Id of your target. If you specify a target, and it is visible to you, the server will provide aim correction and target leading for you. If not you just shoot at the location specified.


setTarget

public Shoot setTarget(UnrealId Target)
The unique Id of your target. If you specify a target, and it is visible to you, the server will provide aim correction and target leading for you. If not you just shoot at the location specified.


isAlt

public java.lang.Boolean isAlt()
If you send True to this you will alt fire instead of normal fire. For normal fire you don't need to send this argument at all.


setAlt

public Shoot setAlt(java.lang.Boolean Alt)
If you send True to this you will alt fire instead of normal fire. For normal fire you don't need to send this argument at all.


toString

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

toHtmlString

public java.lang.String toHtmlString()

toMessage

public java.lang.String toMessage()