Particle Universe
1.2
|
#include <ParticleUniverseDoAffectorEventHandler.h>
Public Member Functions | |
DoAffectorEventHandler (void) | |
virtual | ~DoAffectorEventHandler (void) |
const bool | getPrePost (void) const |
void | setPrePost (const bool prePost) |
const String & | getAffectorName (void) const |
void | setAffectorName (const String &affectorName) |
virtual void | _handle (ParticleTechnique *particleTechnique, Particle *particle, Real timeElapsed) |
virtual void | copyAttributesTo (ParticleEventHandler *eventHandler) |
Public Member Functions inherited from ParticleUniverse::ParticleEventHandler | |
ParticleEventHandler (void) | |
virtual | ~ParticleEventHandler (void) |
const String & | getName (void) const |
void | setName (const String &name) |
ParticleObserver * | getParentObserver (void) const |
void | setParentObserver (ParticleObserver *parentObserver) |
const String & | getEventHandlerType (void) const |
void | setEventHandlerType (const String &eventHandlerType) |
virtual void | _notifyRescaled (const Vector3 &scale) |
virtual void | copyParentAttributesTo (ParticleEventHandler *eventHandler) |
Public Member Functions inherited from ParticleUniverse::IAlias | |
IAlias (void) | |
virtual | ~IAlias (void) |
const String & | getAliasName (void) const |
void | setAliasName (String aliasName) |
const AliasType | getAliasType (void) const |
void | setAliasType (AliasType aliasType) |
Public Member Functions inherited from ParticleUniverse::IElement | |
IElement (void) | |
virtual | ~IElement (void) |
Static Public Attributes | |
static const bool | DEFAULT_PRE_POST |
Protected Attributes | |
String | mAffectorName |
bool | mPrePost |
Protected Attributes inherited from ParticleUniverse::ParticleEventHandler | |
ParticleObserver * | mParentObserver |
String | mEventHandlerType |
String | mName |
Vector3 | _mEventHandlerScale |
Protected Attributes inherited from ParticleUniverse::IAlias | |
String | mAliasName |
AliasType | mAliasType |
Additional Inherited Members | |
Public Types inherited from ParticleUniverse::IAlias | |
enum | AliasType { AT_UNDEFINED, AT_TECHNIQUE, AT_RENDERER, AT_EMITTER, AT_AFFECTOR, AT_OBSERVER, AT_EXTERN, AT_HANDLER, AT_BEHAVIOUR } |
This class explicitly calls an affector to affect the particles. There are several reasons why this is appropriate. One reason is, that you only want to affect a particle if a certain event occurs. Disable an affector and call it using this event handler, is the method (calling the affector from the event handler doesn't take into consideration that the affector is disabled).
ParticleUniverse::DoAffectorEventHandler::DoAffectorEventHandler | ( | void | ) |
|
inlinevirtual |
|
virtual |
If the _handle() function of this class is invoked (by an Observer), it searches the ParticleAffector defined by the its name. The ParticleAffector is either part of the ParticleTechnique in which the DoAffectorEventHandler is defined, or if the Affector is not found, other ParticleTechniques are searched.
Implements ParticleUniverse::ParticleEventHandler.
|
virtual |
Copy attributes to another event handler.
Reimplemented from ParticleUniverse::ParticleEventHandler.
|
inline |
Get the name of the affector that must be enabled or disabled.
|
inline |
Get the indication whether pre- and postprocessing must be done.
|
inline |
Set the name of the affector.
|
inline |
Set the indication whether pre- and postprocessing must be done.
|
static |
|
protected |
|
protected |