← Previous | Next →
getCombatTarget
Description
Retrieves the NPC's current melee combat target and stores the target entity in a global variable.
Name | Type | Possibilities |
getCombatTarget | behaviour | 2 |
Parameters
# | Name | Type | Mandatory | Description | Multiple |
1 | target | Entity | Yes | The global variable name where the combat target entity will be stored. | No |
Outputs
# | Description |
1 | The combat target was found and stored in the global variable. |
2 | No combat target was found. |
Example
NPC
name Fighter
model g_m_y_ballaorig_01
position -1020.72 4839.78 258.30 0.0
interaction
nothing
behaviour
getCombatTarget combatTarget