The event is "unthrottled", which means that it is called for every single attack. It's therefore useful for micromanagement of droids when they are engaged in battle or come under attack. If you do not require droid micromanagement, use eventAttacked() instead as it puts less strain on the CPU and is less likely to cause game lag. |
This event is called when your droids or structures are attacked. |
This event is useful for retreating damaged units, or repairing damage buildings, after an enemy attacks them.
Warzone 3.2 and above.
function eventAttackedUnthrottled(victim, attacker) { // do stuff } |
Parameter | Type | Mandatory | Description | Game version |
---|---|---|---|---|
victim | ![]() | Which of my things did the enemy attack? | 3.2 | |
attacker | ![]() | What did the enemy use to attack me? | 3.2 |
Warzone does not process the event handler's return value.
See eventAttacked() for examples.