Planeshift
Public Member Functions | Protected Attributes

InventoryPerception Class Reference

This perception is used when a item is added or removed from inventory. More...

#include <perceptions.h>

List of all members.

Public Member Functions

virtual int GetCount () const
virtual bool GetLocation (csVector3 &pos, iSector *&sector)
 Get a location assosiated with the perception.
virtual float GetRadius () const
 Get the radius of the perception.
 InventoryPerception (const char *n, const char *t, const int c, const csVector3 &p, iSector *s, float r)
virtual PerceptionMakeCopy ()
 Make a copy of this perception.

Protected Attributes

int count
csVector3 pos
float radius
iSector * sector

Detailed Description

This perception is used when a item is added or removed from inventory.

Definition at line 438 of file perceptions.h.


Constructor & Destructor Documentation

InventoryPerception::InventoryPerception ( const char *  n,
const char *  t,
const int  c,
const csVector3 &  p,
iSector *  s,
float  r 
) [inline]

Definition at line 447 of file perceptions.h.


Member Function Documentation

virtual int InventoryPerception::GetCount ( ) const [inline, virtual]

Definition at line 466 of file perceptions.h.

virtual bool InventoryPerception::GetLocation ( csVector3 &  pos,
iSector *&  sector 
) [inline, virtual]

Get a location assosiated with the perception.

Some perception might hold a location. Default impl get location from target if there is one.

Parameters:
posThe position of the location.
sectorThe sector of the location.
Returns:
true if there where a location.

Reimplemented from Perception.

Definition at line 455 of file perceptions.h.

virtual float InventoryPerception::GetRadius ( ) const [inline, virtual]

Get the radius of the perception.

Reimplemented from Perception.

Definition at line 462 of file perceptions.h.

virtual Perception* InventoryPerception::MakeCopy ( ) [virtual]

Make a copy of this perception.

Returns:
the copy.

Reimplemented from Perception.


Member Data Documentation

Definition at line 444 of file perceptions.h.

csVector3 InventoryPerception::pos [protected]

Definition at line 441 of file perceptions.h.

Definition at line 443 of file perceptions.h.

iSector* InventoryPerception::sector [protected]

Definition at line 442 of file perceptions.h.


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