Difference between revisions of "UT CombatStart"

From Dragon Age Toolset Wiki
Jump to: navigation, search
(Created page with '{{dafunction |name = UT_CombatStart |brief = Gets two creature to start combat. |param1type = object |param1name = oAttacker |param1desc = The attacking creature or the creature ...')
 
Line 35: Line 35:
 
<!-- This section contains examples transcluded from the snippet library. -->
 
<!-- This section contains examples transcluded from the snippet library. -->
  
<!-- == See also == -->
+
== See also ==
 
<!-- This section contains links to articles, functions or constant groups. -->
 
<!-- This section contains links to articles, functions or constant groups. -->
 +
 +
[[UT_CombatStop]]

Revision as of 19:36, 10 February 2010

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