TopDown Engine v5.0
Loading...
Searching...
No Matches
MoreMountains.TopDownEngine.AIDecisionDistanceToTarget Class Reference

This Decision will return true if the current Brain's Target is within the specified range, false otherwise. More...

Inheritance diagram for MoreMountains.TopDownEngine.AIDecisionDistanceToTarget:
MoreMountains.Tools.AIDecision

Public Types

enum  ComparisonModes {
  StrictlyLowerThan , LowerThan , Equals , GreaterThan ,
  StrictlyGreaterThan
}
 The possible comparison modes. More...

Public Member Functions

override bool Decide ()
 On Decide we check our distance to the Target.
Public Member Functions inherited from MoreMountains.Tools.AIDecision
bool Decide ()
 Decide will be performed every frame while the Brain is in a state this Decision is in. Should return true or false, which will then determine the transition's outcome.
virtual void Initialization ()
 Meant to be overridden, called when the game starts.
virtual void OnEnterState ()
 Meant to be overridden, called when the Brain enters a State this Decision is in.
virtual void OnExitState ()
 Meant to be overridden, called when the Brain exits a State this Decision is in.

Public Attributes

ComparisonModes ComparisonMode = ComparisonModes.GreaterThan
 the comparison mode
float Distance
 the distance to compare with
Public Attributes inherited from MoreMountains.Tools.AIDecision
string Label
 a label you can set to organize your AI Decisions, not used by anything else

Protected Member Functions

virtual bool EvaluateDistance ()
 Returns true if the distance conditions are met.
Protected Member Functions inherited from MoreMountains.Tools.AIDecision
virtual void Awake ()
 On Awake we grab our Brain.

Additional Inherited Members

Protected Attributes inherited from MoreMountains.Tools.AIDecision
AIBrain _brain
Properties inherited from MoreMountains.Tools.AIDecision
virtual bool DecisionInProgress [get, set]

Detailed Description

This Decision will return true if the current Brain's Target is within the specified range, false otherwise.

Member Enumeration Documentation

◆ ComparisonModes

The possible comparison modes.

Enumerator
StrictlyLowerThan 
LowerThan 
Equals 
GreaterThan 
StrictlyGreaterThan 

Member Function Documentation

◆ Decide()

override bool MoreMountains.TopDownEngine.AIDecisionDistanceToTarget.Decide ( )

On Decide we check our distance to the Target.

Returns

◆ EvaluateDistance()

virtual bool MoreMountains.TopDownEngine.AIDecisionDistanceToTarget.EvaluateDistance ( )
protectedvirtual

Returns true if the distance conditions are met.

Returns

Member Data Documentation

◆ ComparisonMode

ComparisonModes MoreMountains.TopDownEngine.AIDecisionDistanceToTarget.ComparisonMode = ComparisonModes.GreaterThan

the comparison mode

◆ Distance

float MoreMountains.TopDownEngine.AIDecisionDistanceToTarget.Distance

the distance to compare with


The documentation for this class was generated from the following file: