UT CombatStart

From Dragon Age Toolset Wiki
Jump to: navigation, search

Gets two creature to start combat.

void UT_CombatStart(
object oAttacker,
object oTarget,
int bTargetSelectionOverride = FALSE,
int nOverridePermanent = FALSE
);
Parameters:
oAttacker
The attacking creature or the creature who initiates combat. This will not matter most of the time unless we are using the bTargetSelectionOverride parameter.
oTarget
The target creature or the creature who is being attacked. This will not matter most of the time unless we are using the bTargetSelectionOverride parameter.
bTargetSelectionOverride
if TRUE this will override the default target selection for the attacker for the first few rounds
nOverridePermanent
if TRUE the attacker will not leave the specified target until it is dead and will force the attacker to target the specified target. Otherwise they will just turn hostile and the AI system will decide who attacks who.
Returns:

Nothing.

Source:

Core Resources.utility_h

Description

This function starts combat by turning 2 creatures hostile towards each other. It is assumed that the perception system will trigger combat once both sides are hostile. This function will switch the creature's group to be the 'hostile' group if it's current group is 'non-hostile' No other groups will be switched – for these cases the function will just set the 2 groups hostile.


See also

UT_CombatStop