Skip to main content

Execute_ClearAggroTargetingMe

Description

Clears aggro that other characters hold toward BaseObject. This is the reverse direction of ClearAggro, which only ever touches aggro BaseObject itself holds, so the two do not overlap.

Every holder is reached because the sweep walks all aggro sources rather than a counterpart the script names. That is the point of this command: flipping ClearAggro's BaseObject to the other side only reaches the one character the script happens to know about, which breaks as soon as more than one character is pursuing BaseObject.

S1 empty removes every entry aimed at BaseObject. S1 as an AggroReason removes only that reason from those entries, leaving an entry alive when it still holds another reason - use it to stop one kind of pursuit without wiping aggro that has nothing to do with it.

What this does and does not stop: once an entry is gone no new chase toward BaseObject is started and no arrival fires, so the arrest or attack that would have landed does not. A chase already on its way is not cancelled though - the pursuer walks out its current path and ends there. Do not reach for this expecting a pursuer to halt on the spot. A holder left with no aggro at all walks back to where its pursuit began.

Parameters

ParameterDescription
BaseObjectThe character being targeted, whose incoming aggro is cleared
NonBaseObjectNot used - every holder is swept, not just the counterpart
S1NAME_None: remove every entry aimed at BaseObject. Else: AggroReason to remove
F1Not used - this always clears fully rather than decreasing

Examples

DescriptionBaseObjectCommandS1
Stop everyone from pursuing SelfSelfClearAggroTargetingMe
Stop every police arrest pursuit aimed at the arrested targetTargetClearAggroTargetingMeAggro_Police_Arrest
Stop everyone attacking Self, keeping other pursuit reasonsSelfClearAggroTargetingMeAttackedByOther