Biggerplay Posted January 30, 2014 Share Posted January 30, 2014 What's the correct way to set the size of a particle from an emitter? I've tried scale.setTo, I've tried setSize, i've tried emitter.scale, nothing seems to have any effect. Link to comment Share on other sites More sharing options...
jcs Posted January 30, 2014 Share Posted January 30, 2014 the particles are simply Phaser Sprites. to change their scale, set it using 'p.scale.x = n; p.scale.y = m' or 'p.scale.setTo( n, m )' be aware that the emitter selects a random size between 'minParticleScale' and 'maxParticleScale' when it emits the particle, so setting the scale must be done after that point. if you wanted all the particles scaled the same, just set 'minParticleScale' and 'maxParticleScale' to the same value Link to comment Share on other sites More sharing options...
XekeDeath Posted January 30, 2014 Share Posted January 30, 2014 If you want your particles to alter over time, like expanding smoke or shrinking them until they vanish, then remember that the emitter is just a fancy group,and gives you functions like forEach, forEachAlive, and setAll. Link to comment Share on other sites More sharing options...
Recommended Posts