|
| void | HandleNonAllowed () |
| |
| virtual float | GetPriority () |
| |
| void | SyncRemovedObjectives< T1, T2 > (Dictionary< T1, T2 > dictionary, IEnumerable< T1 > collection) |
| | Checks if the subobjectives in the given collection are removed from the subobjectives. And if so, removes it also from the dictionary. More...
|
| |
| bool | TryAddSubObjective< T > (ref T objective, Func< T > constructor, Action onCompleted=null, Action onAbandon=null) |
| | Checks if the objective already is created and added in subobjectives. If not, creates it. Handles objectives that cannot be completed. If the objective has been removed form the subobjectives, a null value is assigned to the reference. Returns true if the objective was created and successfully added. More...
|
| |
| virtual void | OnCompleted () |
| |
| virtual void | OnAbandon () |
| |
| abstract void | Act (float deltaTime) |
| |
| abstract bool | CheckObjectiveSpecific () |
| |
| bool | CanEquip (Item item, bool allowWearing) |
| |
|
| virtual float | Devotion [get] |
| |
| abstract Identifier | Identifier [get, set] |
| |
| virtual string | DebugTag [get] |
| |
| virtual bool | ForceRun [get] |
| |
| virtual bool | IgnoreUnsafeHulls [get] |
| |
| virtual bool | AbandonWhenCannotCompleteSubjectives [get] |
| |
| virtual bool | AllowSubObjectiveSorting [get] |
| |
| virtual bool | PrioritizeIfSubObjectivesActive [get] |
| |
| virtual bool | AllowMultipleInstances [get] |
| | Can there be multiple objective instaces of the same type? More...
|
| |
| virtual bool | ConcurrentObjectives [get] |
| | Run the main objective with all subobjectives concurrently? If false, the main objective will continue only when all the subobjectives have been removed (done). More...
|
| |
| virtual bool | KeepDivingGearOn [get] |
| |
| virtual bool | KeepDivingGearOnAlsoWhenInactive [get] |
| |
| virtual bool | AllowAutomaticItemUnequipping [get] |
| | There's a separate property for diving suit and mask: KeepDivingGearOn. More...
|
| |
| virtual bool | AllowOutsideSubmarine [get] |
| |
| virtual bool | AllowInFriendlySubs [get] |
| |
| virtual bool | AllowInAnySub [get] |
| |
| virtual bool | AllowWhileHandcuffed [get] |
| |
| float | CumulatedDevotion [get, set] |
| |
| virtual float | MaxDevotion [get] |
| |
| float | Priority [get, set] |
| | Final priority value after all calculations. More...
|
| |
| float | BasePriority [get, set] |
| |
| float | PriorityModifier = 1 [get] |
| |
| bool | ForceHighestPriority [get, set] |
| |
| bool | ForceWalk [get, set] |
| |
| bool | IgnoreAtOutpost [get, set] |
| |
| bool | Abandon [get, set] |
| |
| virtual bool | CanBeCompleted [get] |
| |
| virtual bool | IsLoop [get, set] |
| | When true, the objective is never completed, unless CanBeCompleted returns false. More...
|
| |
| IEnumerable< AIObjective > | SubObjectives [get] |
| |
| AIObjective | CurrentSubObjective [get] |
| |
| HumanAIController | HumanAIController [get] |
| |
| IndoorsSteeringManager | PathSteering [get] |
| |
| SteeringManager | SteeringManager [get] |
| |
| bool | IsAllowed [get] |
| |
| bool | IsCompleted [get, protected set] |
| |
|
| Action | Completed |
| | A single shot event. Automatically cleared after launching. Use OnCompleted method for implementing (internal) persistent behavior. More...
|
| |
| Action | Abandoned |
| | A single shot event. Automatically cleared after launching. Use OnAbandoned method for implementing (internal) persistent behavior. More...
|
| |
| Action | Selected |
| | A single shot event. Automatically cleared after launching. Use OnSelected method for implementing (internal) persistent behavior. More...
|
| |
| Action | Deselected |
| | A single shot event. Automatically cleared after launching. Use OnDeselected method for implementing (internal) persistent behavior. More...
|
| |
Definition at line 10 of file AIObjective.cs.
◆ AIObjective()
◆ Act()
| abstract void Barotrauma.AIObjective.Act |
( |
float |
deltaTime | ) |
|
|
protectedpure virtual |
Implemented in Barotrauma.AIObjectiveReturn, Barotrauma.AIObjectiveRescue, Barotrauma.AIObjectiveRepairItem, Barotrauma.AIObjectivePrepare, Barotrauma.AIObjectiveOperateItem, Barotrauma.AIObjectiveLoop< T >, Barotrauma.AIObjectiveLoadItem, Barotrauma.AIObjectiveIdle, Barotrauma.AIObjectiveGoTo, Barotrauma.AIObjectiveGetItems, Barotrauma.AIObjectiveGetItem, Barotrauma.AIObjectiveFixLeak, Barotrauma.AIObjectiveFindSafety, Barotrauma.AIObjectiveFindDivingGear, Barotrauma.AIObjectiveExtinguishFire, Barotrauma.AIObjectiveEscapeHandcuffs, Barotrauma.AIObjectiveDecontainItem, Barotrauma.AIObjectiveContainItem, Barotrauma.AIObjectiveCombat, Barotrauma.AIObjectiveCleanupItem, and Barotrauma.AIObjectiveCheckStolenItems.
◆ AddSubObjective()
| void Barotrauma.AIObjective.AddSubObjective |
( |
AIObjective |
objective, |
|
|
bool |
addFirst = false |
|
) |
| |
◆ CalculatePriority()
| float Barotrauma.AIObjective.CalculatePriority |
( |
| ) |
|
Call this only when the priority needs to be recalculated. Use the cached Priority property when you don't need to recalculate.
Definition at line 289 of file AIObjective.cs.
◆ CanEquip() [1/2]
| static bool Barotrauma.AIObjective.CanEquip |
( |
Character |
character, |
|
|
Item |
item, |
|
|
bool |
allowWearing |
|
) |
| |
|
staticprotected |
◆ CanEquip() [2/2]
| bool Barotrauma.AIObjective.CanEquip |
( |
Item |
item, |
|
|
bool |
allowWearing |
|
) |
| |
|
protected |
◆ CheckObjectiveSpecific()
| abstract bool Barotrauma.AIObjective.CheckObjectiveSpecific |
( |
| ) |
|
|
protectedpure virtual |
Implemented in Barotrauma.AIObjectiveReturn, Barotrauma.AIObjectiveRescue, Barotrauma.AIObjectiveRepairItem, Barotrauma.AIObjectivePrepare, Barotrauma.AIObjectiveOperateItem, Barotrauma.AIObjectiveLoop< T >, Barotrauma.AIObjectiveLoadItem, Barotrauma.AIObjectiveIdle, Barotrauma.AIObjectiveGoTo, Barotrauma.AIObjectiveGetItems, Barotrauma.AIObjectiveGetItem, Barotrauma.AIObjectiveFixLeak, Barotrauma.AIObjectiveFindSafety, Barotrauma.AIObjectiveFindDivingGear, Barotrauma.AIObjectiveExtinguishFire, Barotrauma.AIObjectiveEscapeHandcuffs, Barotrauma.AIObjectiveDecontainItem, Barotrauma.AIObjectiveContainItem, Barotrauma.AIObjectiveCombat, Barotrauma.AIObjectiveCleanupItem, and Barotrauma.AIObjectiveCheckStolenItems.
◆ GetActiveObjective()
| AIObjective Barotrauma.AIObjective.GetActiveObjective |
( |
| ) |
|
◆ GetPriority()
| virtual float Barotrauma.AIObjective.GetPriority |
( |
| ) |
|
|
protectedvirtual |
Reimplemented in Barotrauma.AIObjectiveReturn, Barotrauma.AIObjectiveRescue, Barotrauma.AIObjectiveRepairItem, Barotrauma.AIObjectivePrepare, Barotrauma.AIObjectiveOperateItem, Barotrauma.AIObjectiveLoop< T >, Barotrauma.AIObjectiveLoadItem, Barotrauma.AIObjectiveIdle, Barotrauma.AIObjectiveGoTo, Barotrauma.AIObjectiveFixLeak, Barotrauma.AIObjectiveFindSafety, Barotrauma.AIObjectiveExtinguishFire, Barotrauma.AIObjectiveEscapeHandcuffs, Barotrauma.AIObjectiveCombat, Barotrauma.AIObjectiveCleanupItem, and Barotrauma.AIObjectiveCheckStolenItems.
Definition at line 268 of file AIObjective.cs.
◆ GetSubObjectivesRecursive()
| IEnumerable<AIObjective> Barotrauma.AIObjective.GetSubObjectivesRecursive |
( |
bool |
includingSelf = false | ) |
|
◆ HandleNonAllowed()
| void Barotrauma.AIObjective.HandleNonAllowed |
( |
| ) |
|
|
protected |
◆ IsDuplicate< T >()
| virtual bool Barotrauma.AIObjective.IsDuplicate< T > |
( |
T |
otherObjective | ) |
|
|
virtual |
◆ IsIgnoredAtOutpost()
| bool Barotrauma.AIObjective.IsIgnoredAtOutpost |
( |
| ) |
|
Returns true only when at a friendly outpost and when the order is set to be ignored there. Note that even if this returns false, the objective can be disallowed, because AllowInFriendlySubs is false.
Definition at line 253 of file AIObjective.cs.
◆ OnAbandon()
| virtual void Barotrauma.AIObjective.OnAbandon |
( |
| ) |
|
|
protectedvirtual |
◆ OnCompleted()
| virtual void Barotrauma.AIObjective.OnCompleted |
( |
| ) |
|
|
protectedvirtual |
◆ OnDeselected()
| virtual void Barotrauma.AIObjective.OnDeselected |
( |
| ) |
|
|
virtual |
◆ OnSelected()
| virtual void Barotrauma.AIObjective.OnSelected |
( |
| ) |
|
|
virtual |
◆ RemoveSubObjective< T >()
| void Barotrauma.AIObjective.RemoveSubObjective< T > |
( |
ref T |
objective | ) |
|
◆ Reset()
| virtual void Barotrauma.AIObjective.Reset |
( |
| ) |
|
|
virtual |
Reimplemented in Barotrauma.AIObjectiveReturn, Barotrauma.AIObjectiveRescue, Barotrauma.AIObjectiveRepairItem, Barotrauma.AIObjectivePrepare, Barotrauma.AIObjectiveOperateItem, Barotrauma.AIObjectiveLoop< T >, Barotrauma.AIObjectiveLoadItem, Barotrauma.AIObjectiveIdle, Barotrauma.AIObjectiveGoTo, Barotrauma.AIObjectiveGetItems, Barotrauma.AIObjectiveGetItem, Barotrauma.AIObjectiveFixLeak, Barotrauma.AIObjectiveFindSafety, Barotrauma.AIObjectiveFindDivingGear, Barotrauma.AIObjectiveExtinguishFire, Barotrauma.AIObjectiveEscapeHandcuffs, Barotrauma.AIObjectiveDecontainItem, Barotrauma.AIObjectiveContainItem, Barotrauma.AIObjectiveCombat, and Barotrauma.AIObjectiveCleanupItem.
Definition at line 415 of file AIObjective.cs.
◆ SortSubObjectives()
| void Barotrauma.AIObjective.SortSubObjectives |
( |
| ) |
|
◆ SpeakAfterOrderReceived()
| virtual void Barotrauma.AIObjective.SpeakAfterOrderReceived |
( |
| ) |
|
|
virtual |
◆ SyncRemovedObjectives< T1, T2 >()
| void Barotrauma.AIObjective.SyncRemovedObjectives< T1, T2 > |
( |
Dictionary< T1, T2 > |
dictionary, |
|
|
IEnumerable< T1 > |
collection |
|
) |
| |
|
protected |
Checks if the subobjectives in the given collection are removed from the subobjectives. And if so, removes it also from the dictionary.
Definition at line 328 of file AIObjective.cs.
◆ TryAddSubObjective< T >()
| bool Barotrauma.AIObjective.TryAddSubObjective< T > |
( |
ref T |
objective, |
|
|
Func< T > |
constructor, |
|
|
Action |
onCompleted = null, |
|
|
Action |
onAbandon = null |
|
) |
| |
|
protected |
Checks if the objective already is created and added in subobjectives. If not, creates it. Handles objectives that cannot be completed. If the objective has been removed form the subobjectives, a null value is assigned to the reference. Returns true if the objective was created and successfully added.
Definition at line 347 of file AIObjective.cs.
◆ TryComplete()
| void Barotrauma.AIObjective.TryComplete |
( |
float |
deltaTime | ) |
|
Makes the character act according to the objective, or according to any subobjectives that need to be completed before this one
Definition at line 173 of file AIObjective.cs.
◆ Update()
| virtual void Barotrauma.AIObjective.Update |
( |
float |
deltaTime | ) |
|
|
virtual |
◆ AbortCondition
| Func<AIObjective, bool> Barotrauma.AIObjective.AbortCondition |
Aborts the objective when this condition is true.
Definition at line 132 of file AIObjective.cs.
◆ character
| readonly Character Barotrauma.AIObjective.character |
◆ objectiveManager
◆ Option
◆ subObjectives
◆ Abandon
| bool Barotrauma.AIObjective.Abandon |
|
getset |
◆ AbandonWhenCannotCompleteSubjectives
| virtual bool Barotrauma.AIObjective.AbandonWhenCannotCompleteSubjectives |
|
get |
◆ AllowAutomaticItemUnequipping
| virtual bool Barotrauma.AIObjective.AllowAutomaticItemUnequipping |
|
get |
There's a separate property for diving suit and mask: KeepDivingGearOn.
Definition at line 39 of file AIObjective.cs.
◆ AllowInAnySub
| virtual bool Barotrauma.AIObjective.AllowInAnySub |
|
get |
◆ AllowInFriendlySubs
| virtual bool Barotrauma.AIObjective.AllowInFriendlySubs |
|
get |
◆ AllowMultipleInstances
| virtual bool Barotrauma.AIObjective.AllowMultipleInstances |
|
get |
Can there be multiple objective instaces of the same type?
Definition at line 25 of file AIObjective.cs.
◆ AllowOutsideSubmarine
| virtual bool Barotrauma.AIObjective.AllowOutsideSubmarine |
|
get |
◆ AllowSubObjectiveSorting
| virtual bool Barotrauma.AIObjective.AllowSubObjectiveSorting |
|
get |
◆ AllowWhileHandcuffed
| virtual bool Barotrauma.AIObjective.AllowWhileHandcuffed |
|
get |
◆ BasePriority
| float Barotrauma.AIObjective.BasePriority |
|
getset |
◆ CanBeCompleted
| virtual bool Barotrauma.AIObjective.CanBeCompleted |
|
get |
◆ ConcurrentObjectives
| virtual bool Barotrauma.AIObjective.ConcurrentObjectives |
|
get |
Run the main objective with all subobjectives concurrently? If false, the main objective will continue only when all the subobjectives have been removed (done).
Definition at line 31 of file AIObjective.cs.
◆ CumulatedDevotion
| float Barotrauma.AIObjective.CumulatedDevotion |
|
getsetprotected |
◆ CurrentSubObjective
◆ DebugTag
| virtual string Barotrauma.AIObjective.DebugTag |
|
get |
◆ Devotion
| virtual float Barotrauma.AIObjective.Devotion |
|
get |
◆ ForceHighestPriority
| bool Barotrauma.AIObjective.ForceHighestPriority |
|
getset |
◆ ForceRun
| virtual bool Barotrauma.AIObjective.ForceRun |
|
get |
◆ ForceWalk
| bool Barotrauma.AIObjective.ForceWalk |
|
getset |
◆ HumanAIController
◆ Identifier
| abstract Identifier Barotrauma.AIObjective.Identifier |
|
getset |
◆ IgnoreAtOutpost
| bool Barotrauma.AIObjective.IgnoreAtOutpost |
|
getset |
◆ IgnoreUnsafeHulls
| virtual bool Barotrauma.AIObjective.IgnoreUnsafeHulls |
|
get |
◆ IsAllowed
| bool Barotrauma.AIObjective.IsAllowed |
|
get |
◆ IsCompleted
| bool Barotrauma.AIObjective.IsCompleted |
|
getprotected set |
◆ IsLoop
| virtual bool Barotrauma.AIObjective.IsLoop |
|
getset |
When true, the objective is never completed, unless CanBeCompleted returns false.
Definition at line 109 of file AIObjective.cs.
◆ KeepDivingGearOn
| virtual bool Barotrauma.AIObjective.KeepDivingGearOn |
|
get |
◆ KeepDivingGearOnAlsoWhenInactive
| virtual bool Barotrauma.AIObjective.KeepDivingGearOnAlsoWhenInactive |
|
get |
◆ MaxDevotion
| virtual float Barotrauma.AIObjective.MaxDevotion |
|
getprotected |
◆ PathSteering
◆ PrioritizeIfSubObjectivesActive
| virtual bool Barotrauma.AIObjective.PrioritizeIfSubObjectivesActive |
|
get |
◆ Priority
| float Barotrauma.AIObjective.Priority |
|
getset |
Final priority value after all calculations.
Definition at line 58 of file AIObjective.cs.
◆ PriorityModifier
| float Barotrauma.AIObjective.PriorityModifier = 1 |
|
get |
◆ SteeringManager
◆ SubObjectives
| IEnumerable<AIObjective> Barotrauma.AIObjective.SubObjectives |
|
get |
◆ Abandoned
| Action Barotrauma.AIObjective.Abandoned |
A single shot event. Automatically cleared after launching. Use OnAbandoned method for implementing (internal) persistent behavior.
Definition at line 142 of file AIObjective.cs.
◆ Completed
| Action Barotrauma.AIObjective.Completed |
A single shot event. Automatically cleared after launching. Use OnCompleted method for implementing (internal) persistent behavior.
Definition at line 138 of file AIObjective.cs.
◆ Deselected
| Action Barotrauma.AIObjective.Deselected |
A single shot event. Automatically cleared after launching. Use OnDeselected method for implementing (internal) persistent behavior.
Definition at line 150 of file AIObjective.cs.
◆ Selected
| Action Barotrauma.AIObjective.Selected |
A single shot event. Automatically cleared after launching. Use OnSelected method for implementing (internal) persistent behavior.
Definition at line 146 of file AIObjective.cs.