com.springrts.ai.event
Class EnemyDamagedAIEvent

java.lang.Object
  extended by Structure
      extended by com.springrts.ai.AIEvent
          extended by com.springrts.ai.event.EnemyDamagedAIEvent

public final class EnemyDamagedAIEvent
extends AIEvent

This AI event is sent when an enemy unit was damaged. It contains the attacked unit, the attacking unit, the ammount of damage and the direction from where the damage was inflickted. In case of a laser weapon, the direction will point directly from the attacker to the attacked unit, while with artillery it will rather be from somewhere up in the sky to the attacked unit. attacker may be 0, which means no attacker was directly involved. See also the enemy-destroyed event.


Field Summary
 int attacker
           
 float damage
           
 AIFloat3 dir
           
 int enemy
           
 boolean paralyzer
           
static int TOPIC
           
 int weaponDefId
           
 
Constructor Summary
EnemyDamagedAIEvent(Pointer memory)
           
 
Method Summary
 int getTopic()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TOPIC

public static final int TOPIC
See Also:
Constant Field Values

enemy

public int enemy

attacker

public int attacker

damage

public float damage

dir

public AIFloat3 dir

weaponDefId

public int weaponDefId

paralyzer

public boolean paralyzer
Constructor Detail

EnemyDamagedAIEvent

public EnemyDamagedAIEvent(Pointer memory)
Method Detail

getTopic

public int getTopic()
Specified by:
getTopic in class AIEvent