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

A fireworks particle system. More...

#include <CCParticleExamples.h>

Inheritance diagram for ParticleFireworks:
ParticleSystemQuad ParticleSystem Node TextureProtocol Ref BlendProtocol

Static Public Member Functions

static ParticleFireworkscreate ()
static ParticleFireworkscreateWithTotalParticles (int numberOfParticles)
- Static Public Member Functions inherited from ParticleSystemQuad
static ParticleSystemQuadcreate ()
 creates a Particle Emitter More...
 
local create ()
 creates a Particle Emitter More...
 
static ParticleSystemQuadcreateWithTotalParticles (int numberOfParticles)
 creates a Particle Emitter with a number of particles More...
 
local createWithTotalParticles ( local numberOfParticles)
 creates a Particle Emitter with a number of particles More...
 
static ParticleSystemQuadcreate (const std::string &filename)
 creates an initializes a ParticleSystemQuad from a plist file. More...
 
local create ( local filename)
 creates an initializes a ParticleSystemQuad from a plist file. More...
 
- Static Public Member Functions inherited from ParticleSystem
static ParticleSystemcreate (const std::string &plistFile)
 creates an initializes a ParticleSystem from a plist file. More...
 
static ParticleSystemcreateWithTotalParticles (int numberOfParticles)
 create a system with a fixed number of particles More...
 
- Static Public Member Functions inherited from Node
static Nodecreate (void)
 Allocates and initializes a node. More...
 
var create ()
 Allocates and initializes a node. More...
 
local create ()
 Allocates and initializes a node. More...
 

Protected Member Functions

 ParticleFireworks ()
virtual ~ParticleFireworks ()
bool init ()
virtual bool initWithTotalParticles (int numberOfParticles)
 Initializes a system with a fixed number of particles. More...
 
- Protected Member Functions inherited from ParticleSystemQuad
 ParticleSystemQuad ()
virtual ~ParticleSystemQuad ()
void initIndices ()
 initializes the indices for the vertices More...
 
void initTexCoordsWithRect (const Rect &rect)
 initializes the texture with a rectangle measured Points More...
 
var initTexCoordsWithRect ( var rect)
 initializes the texture with a rectangle measured Points More...
 
local initTexCoordsWithRect ( local rect)
 initializes the texture with a rectangle measured Points More...
 
void updateTexCoords ()
 Updates texture coords. More...
 
void setupVBOandVAO ()
void setupVBO ()
bool allocMemory ()
- Protected Member Functions inherited from ParticleSystem
 ParticleSystem ()
virtual ~ParticleSystem ()
bool init ()
 initializes a ParticleSystem More...
 
bool initWithFile (const std::string &plistFile)
 initializes a ParticleSystem from a plist file. More...
 
bool initWithDictionary (ValueMap &dictionary)
 initializes a QuadParticleSystem from a Dictionary. More...
 
bool initWithDictionary (ValueMap &dictionary, const std::string &dirname)
 initializes a particle system from a NSDictionary and the path from where to load the png More...
 
virtual void updateBlendFunc ()
- Protected Member Functions inherited from Node
 Node ()
 Node ()
 Node ()
virtual ~Node ()
local ~Node ()
void childrenAlloc (void)
 lazy allocs More...
 
var childrenAlloc ()
 lazy allocs More...
 
local childrenAlloc ()
 lazy allocs More...
 
void insertChild (Node *child, int z)
 helper that reorder a child More...
 
var insertChild ( var child, var z)
 helper that reorder a child More...
 
local insertChild ( local child, local z)
 helper that reorder a child More...
 
void detachChild (Node *child, ssize_t index, bool doCleanup)
 Removes a child, call child->onExit(), do cleanup, remove it from children array. More...
 
var detachChild ( var child, var index, var doCleanup)
 Removes a child, call child->onExit(), do cleanup, remove it from children array. More...
 
local detachChild ( local child, local index, local doCleanup)
 Removes a child, call child->onExit(), do cleanup, remove it from children array. More...
 
Point convertToWindowSpace (const Point &nodePoint) const
 Convert cocos2d coordinates to UI windows coordinate. More...
 
var convertToWindowSpace ( var nodePoint)
 Convert cocos2d coordinates to UI windows coordinate. More...
 
local convertToWindowSpace ( local nodePoint)
 Convert cocos2d coordinates to UI windows coordinate. More...
 
kmMat4 transform (const kmMat4 &parentTransform)
virtual void updateCascadeOpacity ()
var updateCascadeOpacity ()
local updateCascadeOpacity ()
virtual void disableCascadeOpacity ()
var disableCascadeOpacity ()
local disableCascadeOpacity ()
virtual void updateCascadeColor ()
var updateCascadeColor ()
local updateCascadeColor ()
virtual void disableCascadeColor ()
var disableCascadeColor ()
virtual void updateColor ()
var updateColor ()
local updateColor ()
- Protected Member Functions inherited from Ref
 Ref ()
 Constructor. More...
 

Additional Inherited Members

- Public Types inherited from ParticleSystem
enum  Mode { GRAVITY, RADIUS }
 
enum  PositionType { FREE, RELATIVE, GROUPED }
 possible types of particle positions More...
 
enum  { DURATION_INFINITY = -1, START_SIZE_EQUAL_TO_END_SIZE = -1, START_RADIUS_EQUAL_TO_END_RADIUS = -1 }
 
- Public Member Functions inherited from ParticleSystemQuad
void setDisplayFrame (SpriteFrame *spriteFrame)
 Sets a new SpriteFrame as particle. More...
 
void setTextureWithRect (Texture2D *texture, const Rect &rect)
 Sets a new texture with a rect. More...
 
void listenBackToForeground (EventCustom *event)
 listen the event that coming to foreground on Android More...
 
virtual void setTexture (Texture2D *texture) override
 Sets a new texuture. More...
 
virtual void updateQuadWithParticle (tParticle *particle, const Point &newPosition) override
 should be overridden by subclasses More...
 
virtual void postStep () override
 should be overridden by subclasses More...
 
virtual void draw (Renderer *renderer, const kmMat4 &transform, bool transformUpdated) override
 Override this method to draw your own node. More...
 
virtual void setBatchNode (ParticleBatchNode *batchNode) override
virtual void setTotalParticles (int tp) override
virtual std::string getDescription () const override
 Gets the description string. More...
 
- Static Public Attributes inherited from Node
static const int INVALID_TAG = -1
 Default tag used for all the nodes. More...
 
var INVALID_TAG = -1
 Default tag used for all the nodes. More...
 
local INVALID_TAG = -1
 Default tag used for all the nodes. More...
 
- Protected Attributes inherited from ParticleSystemQuad
V3F_C4B_T2F_Quad_quads
GLushort * _indices
var _indices
local _indices
GLuint _VAOname
var _VAOname
local _VAOname
GLuint _buffersVBO [2]
var _buffersVBO ()
local _buffersVBO ()
QuadCommand _quadCommand
var _quadCommand
local _quadCommand
- Static Protected Attributes inherited from Node
static int s_globalOrderOfArrival
var s_globalOrderOfArrival
local s_globalOrderOfArrival

Detailed Description

A fireworks particle system.

Constructor & Destructor Documentation

ParticleFireworks ( )
inlineprotected
virtual ~ParticleFireworks ( )
inlineprotectedvirtual

Member Function Documentation

static ParticleFireworks* create ( )
static
static ParticleFireworks*
createWithTotalParticles
( int  numberOfParticles)
static
bool init ( void  )
inlineprotectedvirtual

Reimplemented from Node.

virtual bool initWithTotalParticles ( int  numberOfParticles)
protectedvirtual

Initializes a system with a fixed number of particles.

Reimplemented from ParticleSystemQuad.


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