Cocos2d-x  v3.12
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Groups
ParticleSystemQuad Class Reference

ParticleSystemQuad is a subclass of ParticleSystem. More...

Inherits ParticleSystem.

Inherited by ParticleExplosion, ParticleFire, ParticleFireworks, ParticleFlower, ParticleGalaxy, ParticleMeteor, ParticleRain, ParticleSmoke, ParticleSnow, ParticleSpiral, and ParticleSun.

Public Member Functions

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 listenRendererRecreated (EventCustom *event)
 Listen the event that renderer was recreated on Android/WP8. More...
 

Static Public Member Functions

static ParticleSystemQuadcreate ()
 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 particle emitter from a plist file. More...
 
local create ( local filename)
 Creates an particle emitter from a plist file. More...
 
static ParticleSystemQuadcreate (ValueMap &dictionary)
 Creates a particle emitter with a dictionary. More...
 
local create ( local dictionary)
 Creates a particle emitter with a dictionary. More...
 

Detailed Description

ParticleSystemQuad is a subclass of ParticleSystem.

It includes all the features of ParticleSystem.

Special features and Limitations:

  • Particle size can be any float number.
  • The system can be scaled.
  • The particles can be rotated.
  • It supports subrects.
  • It supports batched rendering since 1.1.

Member Function Documentation

static ParticleSystemQuad* create ( )
static

Creates a particle emitter.

An autoreleased ParticleSystemQuad object.

local create ( )
static

Creates a particle emitter.

An autoreleased ParticleSystemQuad object.

static ParticleSystemQuad*
createWithTotalParticles
( int  numberOfParticles)
static

Creates a particle emitter with a number of particles.

A given number of particles. An autoreleased ParticleSystemQuad object.

local createWithTotalParticles ( local  numberOfParticles)
static

Creates a particle emitter with a number of particles.

A given number of particles. An autoreleased ParticleSystemQuad object.

static ParticleSystemQuad* create ( const std::string &  filename)
static

Creates an particle emitter from a plist file.

This plist files can be created manually or with Particle Designer.

Particle plist file name. An autoreleased ParticleSystemQuad object.

local create ( local  filename)
static

Creates an particle emitter from a plist file.

This plist files can be created manually or with Particle Designer.

Particle plist file name. An autoreleased ParticleSystemQuad object.

static ParticleSystemQuad* create ( ValueMap &  dictionary)
static

Creates a particle emitter with a dictionary.

Particle dictionary. An autoreleased ParticleSystemQuad object.

local create ( local  dictionary)
static

Creates a particle emitter with a dictionary.

Particle dictionary. An autoreleased ParticleSystemQuad object.

void setDisplayFrame ( SpriteFrame spriteFrame)

Sets a new SpriteFrame as particle.

this method is experimental. Use setTextureWithRect instead. A given sprite frame as particle texture.

local setDisplayFrame ( local  spriteFrame)

Sets a new SpriteFrame as particle.

this method is experimental. Use setTextureWithRect instead. A given sprite frame as particle texture.

void setTextureWithRect ( Texture2D texture,
const Rect rect 
)

Sets a new texture with a rect.

The rect is in Points. A given texture. A given rect, in points.

void listenRendererRecreated ( EventCustom event)

Listen the event that renderer was recreated on Android/WP8.

Don't call this manually.

local listenRendererRecreated ( local  event)

Listen the event that renderer was recreated on Android/WP8.

Don't call this manually.


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