RAIN.Minds.SimpleMind Class Reference

SimpleMind is a Mind setup designed to allow developers to create a list of AIBehaviors that are executed in order at each timestep. The Mind manages execution of the behaviors. More...

Inheritance diagram for RAIN.Minds.SimpleMind:
RAIN.Core.Mind

List of all members.

Public Member Functions

override void Init (Agent agent)
 Init is called by the Agent upon startup. The Mind is initialized and Sensors are loaded. InitBehavior is called on each action.
override void Think (Agent agent, float deltaTime)
 The SimpleMind doesn't think, it just does...
override void Act (Agent agent, float deltaTime)
 Act causes each action to be performed in turn, regardless of the success or failure of any other action.
void Add (AIBehavior behavior)
 Add an AI Behavior to the action array.

Public Attributes

bool autoMove = true
 if autoMove is true, the AI will attempt to move based on the PathManager MoveTarget
bool autoLook = true
 if autoLook is true, the AI will attempt to look based on the PathManager LookTarget
AIBehavior[] actions = new AIBehavior[1]
 An array of actions to perform, in order.

Detailed Description

SimpleMind is a Mind setup designed to allow developers to create a list of AIBehaviors that are executed in order at each timestep. The Mind manages execution of the behaviors.


Member Function Documentation

override void RAIN.Minds.SimpleMind.Act ( Agent  agent,
float  deltaTime 
) [virtual]

Act causes each action to be performed in turn, regardless of the success or failure of any other action.

Parameters:
agentThe agent owning this Mind
deltaTimetimestep in seconds

Implements RAIN.Core.Mind.

void RAIN.Minds.SimpleMind.Add ( AIBehavior  behavior)

Add an AI Behavior to the action array.

Parameters:
behaviorThe AIBehavior to add. This may be a duplicate of an AIBehavior already in the array
override void RAIN.Minds.SimpleMind.Init ( Agent  agent) [virtual]

Init is called by the Agent upon startup. The Mind is initialized and Sensors are loaded. InitBehavior is called on each action.

Parameters:
agentThe agent owning this Mind

Implements RAIN.Core.Mind.

override void RAIN.Minds.SimpleMind.Think ( Agent  agent,
float  deltaTime 
) [virtual]

The SimpleMind doesn't think, it just does...

Parameters:
agentThe agent owning this Mind
deltaTimetimestep in seconds

Implements RAIN.Core.Mind.


Member Data Documentation

An array of actions to perform, in order.

if autoLook is true, the AI will attempt to look based on the PathManager LookTarget

if autoMove is true, the AI will attempt to move based on the PathManager MoveTarget