RespondToShout(object, int, object)

Sets NPC to respond to numerous alerts sent by PC or other NPCs.

void RespondToShout(
    object oShouter,
    int nShoutIndex,
    object oIntruder = OBJECT_INVALID
);

Parameters

oShouter

Object which something has occurred to.

nShoutIndex

Consistent reaction requested.

oIntruder

Placeable who disturbed oShouter. (Default: OBJECT_INVALID)


Description

Allows the listener to react in a manner consistent with the given shout but only to one combat shout per round.

The intruder object is for cases where a placeable needs to pass a GetLastOpenedBy object or a AttackMyAttacker needs to make his attacker the enemy of everyone.



Requirements

#include "nw_i0_generic"


Version

1.22

See Also

functions: GetLastHostileActor
categories: Core AI Functions
events: OnDisturbed Event | OnPhysicalAttacked Event | OnSpellCastAt Event | OnUnlock Event


 author: Jody Fletcher, editor: Tom Cassiotis, Mistress