cocos2d-x  3.5
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
PUDoAffectorEventHandler Class Reference

#include <CCPUDoAffectorEventHandler.h>

Inheritance diagram for PUDoAffectorEventHandler:
PUEventHandler Ref

Public Member Functions

const bool getPrePost (void) const
 Get the indication whether pre- and postprocessing must be done. More...
 
void setPrePost (const bool prePost)
 Set the indication whether pre- and postprocessing must be done. More...
 
const std::string & getAffectorName (void) const
 Get the name of the affector that must be enabled or disabled. More...
 
void setAffectorName (const std::string &affectorName)
 Set the name of the affector. More...
 
virtual void handle (PUParticleSystem3D *particleSystem, PUParticle3D *particle, float timeElapsed) override
 If the _handle() function of this class is invoked (by an Observer), it searches the ParticleAffector defined by the its name. More...
 
virtual void copyAttributesTo (PUEventHandler *eventHandler) override
virtual ~PUDoAffectorEventHandler (void)
- Public Member Functions inherited from PUEventHandler
const std::string & getName (void) const
 Todo. More...
 
void setName (const std::string &name)
PUObservergetParentObserver (void) const
 Todo. More...
 
void setParentObserver (PUObserver *parentObserver)
const std::string & getEventHandlerType (void) const
 Todo. More...
 
void setEventHandlerType (const std::string &eventHandlerType)
virtual void notifyRescaled (const Vec3 &scale)
 Notify that the event handler is rescaled. More...
 
virtual ~PUEventHandler ()
- Public Member Functions inherited from Ref
void retain ()
 Retains the ownership. More...
 
void release ()
 Releases the ownership immediately. More...
 
Refautorelease ()
 Releases the ownership sometime soon automatically. More...
 
unsigned int getReferenceCount () const
 Returns the Ref's current reference count. More...
 
virtual ~Ref ()
 Destructor. More...
 

Static Public Member Functions

static PUDoAffectorEventHandlercreate ()

Public Attributes

CC_CONSTRUCTOR_ACCESS __pad0__: PUDoAffectorEventHandler(void)
- Public Attributes inherited from PUEventHandler
CC_CONSTRUCTOR_ACCESS __pad0__: PUEventHandler()

Static Public Attributes

static const bool DEFAULT_PRE_POST

Protected Attributes

std::string _affectorName
bool _prePost
- Protected Attributes inherited from PUEventHandler
PUObserver_parentObserver
std::string _eventHandlerType
std::string _name
Vec3 _eventHandlerScale
 Although the scale is on a Particle System level, the event handler can also be scaled. More...
 
- Protected Attributes inherited from Ref
unsigned int _referenceCount
 count of references More...
 

Additional Inherited Members

- Protected Member Functions inherited from Ref
 Ref ()
 Constructor. More...
 

Constructor & Destructor Documentation

virtual ~PUDoAffectorEventHandler ( void  )
inlinevirtual

Member Function Documentation

virtual void copyAttributesTo ( PUEventHandler eventHandler)
overridevirtual

Reimplemented from PUEventHandler.

static
PUDoAffectorEventHandler*
create
( )
static
const std::string& getAffectorName ( void  ) const
inline

Get the name of the affector that must be enabled or disabled.

const bool getPrePost ( void  ) const
inline

Get the indication whether pre- and postprocessing must be done.

virtual void handle ( PUParticleSystem3D particleSystem,
PUParticle3D particle,
float  timeElapsed 
)
overridevirtual

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 PUEventHandler.

void setAffectorName ( const std::string &  affectorName)
inline

Set the name of the affector.

void setPrePost ( const bool  prePost)
inline

Set the indication whether pre- and postprocessing must be done.

Member Data Documentation

std::string _affectorName
protected
bool _prePost
protected
const bool DEFAULT_PRE_POST
static

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