AiParams.allowBeingTargeted 4
If enabled, enemies will target this soldier whenever they see him. If disabled, the soldier will be completly ignored by enemies.
Toghether with allowCheckForEnemies, this function is helpful to script systems like Civilian or Non combatant medics.
Return value
Return Type | Description |
---|---|
void | This function doesn't return anything |
Parameters
Parameter | Type | Description |
---|---|---|
1 | bool | Enable or disable the feature |
Examples
myself().getAiParams().allowBeingTargeted(false) -- prevents enemy from targeting this unit