Planeshift
psGEMEvent Class Reference

This class automatically implements timed events which depend on the existence and validity of a gemObject of any kind. More...

#include <gem.h>

Public Member Functions

virtual void DeleteObjectCallback (iDeleteNotificationObject *object)
 
 psGEMEvent (csTicks ticks, int offsetticks, gemObject *depends, const char *newType)
 
virtual ~psGEMEvent ()
 
- Public Member Functions inherited from psGameEvent
virtual bool CheckTrigger ()
 Called right before a Trigger is called. More...
 
const char * GetType ()
 Return the type that this event where created with. More...
 
virtual bool IsValid ()
 Return the valid flag. More...
 
bool operator< (const psGameEvent &other) const
 
bool operator== (const psGameEvent &other) const
 
bool operator> (const psGameEvent &other) const
 
 psGameEvent (csTicks ticks, int offsetticks, const char *newType)
 Construct a new game event. More...
 
void QueueEvent ()
 Publish the game event to the local program. More...
 
virtual void SetValid (bool valid)
 Set the valid flag. More...
 
virtual csString ToString () const
 Return a string with information about the event. More...
 
virtual void Trigger ()=0
 Abstract event processing function. More...
 
virtual ~psGameEvent ()
 
- Public Member Functions inherited from iDeleteObjectCallback
virtual ~iDeleteObjectCallback ()
 

Public Attributes

csWeakRef< gemObjectdependency
 
- Public Attributes inherited from psGameEvent
csTicks delayticks
 delay before the event starts More...
 
int id
 id value combined with ticks ensures uniqueness for tree More...
 
csTicks triggerticks
 ticks value when event should be triggered. More...
 
bool valid
 Set this to false if the trigger should not be fired. More...
 

Additional Inherited Members

- Static Public Attributes inherited from psGameEvent
static EventManagereventmanager
 
static int nextid
 id counter sequence More...
 

Detailed Description

This class automatically implements timed events which depend on the existence and validity of a gemObject of any kind.

It will make sure this event is cancelled and skipped when the gemObject is deleted before the event is fired.

Definition at line 2164 of file gem.h.

Constructor & Destructor Documentation

psGEMEvent::psGEMEvent ( csTicks  ticks,
int  offsetticks,
gemObject depends,
const char *  newType 
)
inline

Definition at line 2169 of file gem.h.

virtual psGEMEvent::~psGEMEvent ( )
inlinevirtual

Definition at line 2182 of file gem.h.

Member Function Documentation

virtual void psGEMEvent::DeleteObjectCallback ( iDeleteNotificationObject object)
inlinevirtual

Implements iDeleteObjectCallback.

Reimplemented in psAdviceRequestTimeoutGameEvent, and psAdviceSessionTimeoutGameEvent.

Definition at line 2194 of file gem.h.

Member Data Documentation

csWeakRef<gemObject> psGEMEvent::dependency

Definition at line 2167 of file gem.h.


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