Corgi Engine
v9.0
|
This decision will return true if an object on its TargetLayer layermask is within its specified radius, false otherwise. It will also set the Brain's Target to that object. More...
Public Member Functions | |
override void | Initialization () |
On init we grab our Character component More... | |
override bool | Decide () |
On Decide we check for our target More... | |
Public Member Functions inherited from MoreMountains.Tools.AIDecision | |
virtual void | OnEnterState () |
Meant to be overridden, called when the Brain enters a State this Decision is in More... | |
virtual void | OnExitState () |
Meant to be overridden, called when the Brain exits a State this Decision is in More... | |
Public Attributes | |
float | Radius = 3f |
the radius to search our target in More... | |
Vector3 | DetectionOriginOffset = new Vector3(0, 0, 0) |
the center of the search circle More... | |
LayerMask | TargetLayer = LayerManager.PlayerLayerMask |
the layer(s) to search our target on More... | |
Public Attributes inherited from MoreMountains.Tools.AIDecision | |
string | Label |
a label you can set to organize your AI Decisions, not used by anything else More... | |
Protected Member Functions | |
virtual bool | DetectTarget () |
Returns true if a target is found within the circle More... | |
virtual void | OnDrawGizmosSelected () |
Draws gizmos for the detection circle More... | |
Protected Member Functions inherited from MoreMountains.Tools.AIDecision | |
virtual void | Awake () |
On Awake we grab our Brain More... | |
Protected Attributes | |
Vector2 | _facingDirection |
Vector2 | _raycastOrigin |
Character | _character |
Collider2D | _detectionCollider = null |
Color | _gizmoColor = Color.yellow |
bool | _init = false |
Protected Attributes inherited from MoreMountains.Tools.AIDecision | |
AIBrain | _brain |
Additional Inherited Members | |
Properties inherited from MoreMountains.Tools.AIDecision | |
virtual bool | DecisionInProgress [get, set] |
This decision will return true if an object on its TargetLayer layermask is within its specified radius, false otherwise. It will also set the Brain's Target to that object.
|
virtual |
|
protectedvirtual |
Returns true if a target is found within the circle
|
virtual |
On init we grab our Character component
Reimplemented from MoreMountains.Tools.AIDecision.
|
protectedvirtual |
Draws gizmos for the detection circle
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
Vector3 MoreMountains.CorgiEngine.AIDecisionDetectTargetRadius.DetectionOriginOffset = new Vector3(0, 0, 0) |
the center of the search circle
float MoreMountains.CorgiEngine.AIDecisionDetectTargetRadius.Radius = 3f |
the radius to search our target in
LayerMask MoreMountains.CorgiEngine.AIDecisionDetectTargetRadius.TargetLayer = LayerManager.PlayerLayerMask |
the layer(s) to search our target on