Planeshift
|
Whenever an NPCPet is told by it's owner to stay, this perception is passed to the NPCPet. More...
#include <perceptions.h>
Public Member Functions | |
virtual void | ExecutePerception (NPC *pet, float weight) |
All preconditions has been checked, now excecute the perception. | |
virtual gemNPCObject * | GetTarget () |
Some perception has a target/source. | |
virtual Perception * | MakeCopy () |
Make a copy of this perception. | |
OwnerCmdPerception (const char *n, psPETCommandMessage::PetCommand_t command, gemNPCObject *owner, gemNPCObject *pet, gemNPCObject *target) | |
virtual bool | ShouldReact (Reaction *reaction, NPC *pet) |
Check if this perception should react to a reaction. | |
Static Public Member Functions | |
static csString | BuildName (psPETCommandMessage::PetCommand_t command) |
Protected Attributes | |
psPETCommandMessage::PetCommand_t | command |
csWeakRef< gemNPCObject > | owner |
csWeakRef< gemNPCObject > | pet |
csWeakRef< gemNPCActor > | target |
Whenever an NPCPet is told by it's owner to stay, this perception is passed to the NPCPet.
Right now, it changes the current behavior of the NPCPet.
Definition at line 487 of file perceptions.h.
OwnerCmdPerception::OwnerCmdPerception | ( | const char * | n, |
psPETCommandMessage::PetCommand_t | command, | ||
gemNPCObject * | owner, | ||
gemNPCObject * | pet, | ||
gemNPCObject * | target | ||
) |
static csString OwnerCmdPerception::BuildName | ( | psPETCommandMessage::PetCommand_t | command | ) | [static] |
All preconditions has been checked, now excecute the perception.
npc | The target of the percpetion. |
weight | Indicate how much the HateList of the npc should be changed. Value comes from the reaction. |
Reimplemented from Perception.
virtual gemNPCObject* OwnerCmdPerception::GetTarget | ( | ) | [inline, virtual] |
Some perception has a target/source.
Reimplemented from Perception.
Definition at line 501 of file perceptions.h.
virtual Perception* OwnerCmdPerception::MakeCopy | ( | ) | [virtual] |
Check if this perception should react to a reaction.
reaction | The reaction to check for. |
npc | The NPC that might receive this. |
Reimplemented from Perception.
Definition at line 490 of file perceptions.h.
csWeakRef<gemNPCObject> OwnerCmdPerception::owner [protected] |
Definition at line 491 of file perceptions.h.
csWeakRef<gemNPCObject> OwnerCmdPerception::pet [protected] |
Definition at line 492 of file perceptions.h.
csWeakRef<gemNPCActor> OwnerCmdPerception::target [protected] |
Definition at line 493 of file perceptions.h.