overview wiki api reference download
 All Classes Functions Variables Typedefs Enumerations Enumerator
Public Member Functions
gameplay::AIController Class Reference

#include <AIController.h>

List of all members.

Public Member Functions

void sendMessage (AIMessage *message, float delay=0)
AIAgentfindAgent (const char *id) const

Detailed Description

Defines and facilitates the state machine execution and message passing between AI objects in the game. This class is generally not interfaced with directly.

Member Function Documentation

AIAgent* gameplay::AIController::findAgent ( const char *  id) const

Searches for an AIAgent that is registered with the AIController with the specified ID.

idID of the agent to find.
The first agent matching the specified ID, or NULL if no matching agent could be found.
void gameplay::AIController::sendMessage ( AIMessage message,
float  delay = 0 

Routes the specified message to its intended recipient(s).

Messages are arbitrary packets of data that are sent either to a single or to multiple recipients in the game.

Once the specified message has been delivered, it is automatically destroyed by the AIController. For this reason, AIMessage pointers should NOT be held or explicitly destroyed by any code after they are sent through the AIController.

messageThe message to send.
delayThe delay (in milliseconds) to wait before sending the message.
 All Classes Functions Variables Typedefs Enumerations Enumerator