Barotrauma Client Doc
Barotrauma.CombatAction Class Reference
Inheritance diagram for Barotrauma.CombatAction:
Barotrauma.EventAction

Public Member Functions

 CombatAction (ScriptedEvent parentEvent, ContentXElement element)
 
override void Update (float deltaTime)
 
override bool IsFinished (ref string goTo)
 Has the action finished. More...
 
override void Reset ()
 
override string ToDebugString ()
 Rich test to display in debugdraw More...
 
- Public Member Functions inherited from Barotrauma.EventAction
 EventAction (ScriptedEvent parentEvent, ContentXElement element)
 
virtual bool SetGoToTarget (string goTo)
 
virtual bool CanBeFinished ()
 
virtual IEnumerable< EventActionGetSubActions ()
 

Properties

AIObjectiveCombat.CombatMode CombatMode [get, set]
 
bool IsInstigator [get, set]
 
AIObjectiveCombat.CombatMode GuardReaction [get, set]
 
AIObjectiveCombat.CombatMode WitnessReaction [get, set]
 
Identifier NPCTag [get, set]
 
Identifier EnemyTag [get, set]
 
float CoolDown [get, set]
 

Additional Inherited Members

- Static Public Member Functions inherited from Barotrauma.EventAction
static EventAction Instantiate (ScriptedEvent scriptedEvent, ContentXElement element)
 
- Public Attributes inherited from Barotrauma.EventAction
readonly ScriptedEvent ParentEvent
 
- Protected Member Functions inherited from Barotrauma.EventAction
void ApplyTagsToHulls (Entity entity, Identifier hullTag, Identifier linkedHullTag)
 

Detailed Description

Definition at line 8 of file CombatAction.cs.

Constructor & Destructor Documentation

◆ CombatAction()

Barotrauma.CombatAction.CombatAction ( ScriptedEvent  parentEvent,
ContentXElement  element 
)

Definition at line 36 of file CombatAction.cs.

Member Function Documentation

◆ IsFinished()

override bool Barotrauma.CombatAction.IsFinished ( ref string  goToLabel)
virtual

Has the action finished.

Parameters
goToLabelIf null or empty, the event moves to the next action. Otherwise it moves to the specified label.
Returns

Implements Barotrauma.EventAction.

Definition at line 75 of file CombatAction.cs.

◆ Reset()

override void Barotrauma.CombatAction.Reset ( )
virtual

Implements Barotrauma.EventAction.

Definition at line 80 of file CombatAction.cs.

◆ ToDebugString()

override string Barotrauma.CombatAction.ToDebugString ( )
virtual

Rich test to display in debugdraw

public override string ToDebugString()
{
return $"{ToolBox.GetDebugSymbol(isFinished)} SomeAction -> "(someInfo: {info.ColorizeObject()})";
}
override string ToDebugString()
Rich test to display in debugdraw
Definition: CombatAction.cs:97
Returns

Reimplemented from Barotrauma.EventAction.

Definition at line 97 of file CombatAction.cs.

◆ Update()

override void Barotrauma.CombatAction.Update ( float  deltaTime)
virtual

Reimplemented from Barotrauma.EventAction.

Definition at line 38 of file CombatAction.cs.

Property Documentation

◆ CombatMode

AIObjectiveCombat.CombatMode Barotrauma.CombatAction.CombatMode
getset

Definition at line 11 of file CombatAction.cs.

◆ CoolDown

float Barotrauma.CombatAction.CoolDown
getset

Definition at line 29 of file CombatAction.cs.

◆ EnemyTag

Identifier Barotrauma.CombatAction.EnemyTag
getset

Definition at line 26 of file CombatAction.cs.

◆ GuardReaction

AIObjectiveCombat.CombatMode Barotrauma.CombatAction.GuardReaction
getset

Definition at line 17 of file CombatAction.cs.

◆ IsInstigator

bool Barotrauma.CombatAction.IsInstigator
getset

Definition at line 14 of file CombatAction.cs.

◆ NPCTag

Identifier Barotrauma.CombatAction.NPCTag
getset

Definition at line 23 of file CombatAction.cs.

◆ WitnessReaction

AIObjectiveCombat.CombatMode Barotrauma.CombatAction.WitnessReaction
getset

Definition at line 20 of file CombatAction.cs.