Planeshift
Classes | Public Member Functions | Static Public Member Functions | Protected Types | Protected Attributes

PerceptOperation Class Reference

Send a custon perception from a behavior script. More...

#include <npcoperations.h>

List of all members.

Classes

class  DelayedPerceptOperationGameEvent

Public Member Functions

virtual bool CheckCondition (NPC *npc)
virtual bool Load (iDocumentNode *node)
virtual ScriptOperationMakeCopy ()
 PerceptOperation ()
virtual OperationResult Run (NPC *npc, bool interrupted)
virtual ~PerceptOperation ()

Static Public Member Functions

static void TriggerEvent (NPC *npc, Perception &pcpt, TargetType target, float maxRange)

Protected Types

enum  TargetType { SELF, ALL, TRIBE, TARGET }

Protected Attributes

MathScriptcalcCondition
 This is the particular calculation for condition.
csString condition
 A condition for when the perception should be fired.
csString delayed
 If set this perception should be delayed.
csString failedPerception
 A perception to fire if the condition fails.
float maxRange
 Is there a max range for this, 0.0 is without limit.
csString perception
 The perception name to send.
TargetType target
 Hold the target for the perception, default SELF.
csString type
 The type value of the perception.

Detailed Description

Send a custon perception from a behavior script.

Will send the custom perception at the given time in the script.

Definition at line 1224 of file npcoperations.h.


Member Enumeration Documentation

enum PerceptOperation::TargetType [protected]
Enumerator:
SELF 
ALL 
TRIBE 
TARGET 

Definition at line 1227 of file npcoperations.h.


Constructor & Destructor Documentation

PerceptOperation::PerceptOperation ( ) [inline]

Definition at line 1260 of file npcoperations.h.

virtual PerceptOperation::~PerceptOperation ( ) [inline, virtual]

Definition at line 1267 of file npcoperations.h.


Member Function Documentation

virtual bool PerceptOperation::CheckCondition ( NPC npc) [virtual]
virtual bool PerceptOperation::Load ( iDocumentNode *  node) [virtual]

Reimplemented from ScriptOperation.

virtual ScriptOperation* PerceptOperation::MakeCopy ( ) [virtual]

Implements ScriptOperation.

virtual OperationResult PerceptOperation::Run ( NPC npc,
bool  interrupted 
) [virtual]

Implements ScriptOperation.

static void PerceptOperation::TriggerEvent ( NPC npc,
Perception pcpt,
TargetType  target,
float  maxRange 
) [static]

Member Data Documentation

This is the particular calculation for condition.

Definition at line 1257 of file npcoperations.h.

csString PerceptOperation::condition [protected]

A condition for when the perception should be fired.

Definition at line 1253 of file npcoperations.h.

csString PerceptOperation::delayed [protected]

If set this perception should be delayed.

Definition at line 1255 of file npcoperations.h.

csString PerceptOperation::failedPerception [protected]

A perception to fire if the condition fails.

Definition at line 1254 of file npcoperations.h.

Is there a max range for this, 0.0 is without limit.

Definition at line 1252 of file npcoperations.h.

csString PerceptOperation::perception [protected]

The perception name to send.

Definition at line 1249 of file npcoperations.h.

Hold the target for the perception, default SELF.

Definition at line 1251 of file npcoperations.h.

csString PerceptOperation::type [protected]

The type value of the perception.

Definition at line 1250 of file npcoperations.h.


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