Search code examples
iphoneioscocos2d-iphoneparticles

access to particles's property in cocos2d


so I've created a particle system with particle designer and added to my project :

emitter =[CCParticleSystemQuad particleWithFile:@"bonparticle9.plist"];
emitter.position=ccp(size.width/2,size.height/2);
[self addChild:emitter z:10];

I would like to know if with code I can access to the property of my particle. For example during the game modify the speed of my particle . thank you :) sorry for my english I'm french :)


Solution

  • Your emitter is a CCParticleSystemQuad object, that means you have access to all the properties of CCParticleSystem class. Things like duration, life, speed, speedVar... are all accessable.