cz.cuni.amis.pogamut.udk.communication.messages.gbcommands
Class ChangeAttribute

Package class diagram package ChangeAttribute
java.lang.Object
  extended by cz.cuni.amis.pogamut.base.communication.messages.CommandMessage
      extended by cz.cuni.amis.pogamut.udk.communication.messages.gbcommands.ChangeAttribute

public class ChangeAttribute
extends CommandMessage

Will change the specified attribute of the bot. This command can be issued also by bot on the bot itself (in this case Id attribute is not parsed). Issuing by bot is allowed just when the game has allowed cheating (bAllowCheats = True in GameBotsUDK.ini file). Corresponding GameBots command is CHATTR.


Field Summary
protected  int Health
          Sets the bot health.
protected  UnrealId Id
          Id of the target bot.
 
Constructor Summary
ChangeAttribute()
          Creates new instance of command ChangeAttribute.
ChangeAttribute(ChangeAttribute original)
          Cloning constructor.
ChangeAttribute(UnrealId Id, int Health)
          Creates new instance of command ChangeAttribute.
 
Method Summary
 int getHealth()
          Sets the bot health.
 UnrealId getId()
          Id of the target bot.
 ChangeAttribute setHealth(int Health)
          Sets the bot health.
 ChangeAttribute setId(UnrealId Id)
          Id of the target bot.
 String toHtmlString()
           
 String toMessage()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

Id

protected UnrealId Id
Id of the target bot. Not used if sent as a command for the bot.


Health

protected int Health
Sets the bot health.

Constructor Detail

ChangeAttribute

public ChangeAttribute(UnrealId Id,
                       int Health)
Creates new instance of command ChangeAttribute. Will change the specified attribute of the bot. This command can be issued also by bot on the bot itself (in this case Id attribute is not parsed). Issuing by bot is allowed just when the game has allowed cheating (bAllowCheats = True in GameBotsUDK.ini file). Corresponding GameBots message for this command is CHATTR.

Parameters:
Id - Id of the target bot. Not used if sent as a command for the bot.
Health - Sets the bot health.

ChangeAttribute

public ChangeAttribute()
Creates new instance of command ChangeAttribute. Will change the specified attribute of the bot. This command can be issued also by bot on the bot itself (in this case Id attribute is not parsed). Issuing by bot is allowed just when the game has allowed cheating (bAllowCheats = True in GameBotsUDK.ini file). Corresponding GameBots message for this command is CHATTR.

WARNING: this is empty-command constructor, you have to use setters to fill it up!


ChangeAttribute

public ChangeAttribute(ChangeAttribute original)
Cloning constructor.

Method Detail

getId

public UnrealId getId()
Id of the target bot. Not used if sent as a command for the bot.


setId

public ChangeAttribute setId(UnrealId Id)
Id of the target bot. Not used if sent as a command for the bot.


getHealth

public int getHealth()
Sets the bot health.


setHealth

public ChangeAttribute setHealth(int Health)
Sets the bot health.


toString

public String toString()
Overrides:
toString in class CommandMessage

toHtmlString

public String toHtmlString()

toMessage

public String toMessage()


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