You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Emitter.setScale has a new 'rate' parameter which allows particles to change in scale over time, using any Easing value or timescale.
Emitter.setAlpha has a new 'rate' parameter which allows particles to change alpha over time, using any Easing value or timescale.
Emitter.bringToTop and Emitter.sendToBack are booleans that let you optionally set the display order of the Particle when emitted.
@@ -76,6 +76,11 @@ Phaser.Particles.Arcade.Emitter = function (game, x, y, maxParticles) {
76
76
*/
77
77
this.maxParticleScale=1;
78
78
79
+
/**
80
+
* @property {array} scaleData - An array of the calculated scale easing data applied to particles with scaleRates > 0.
81
+
*/
82
+
this.scaleData=null;
83
+
79
84
/**
80
85
* @property {number} minRotation - The minimum possible angular velocity of a particle.
81
86
* @default
@@ -100,6 +105,11 @@ Phaser.Particles.Arcade.Emitter = function (game, x, y, maxParticles) {
100
105
*/
101
106
this.maxParticleAlpha=1;
102
107
108
+
/**
109
+
* @property {array} alphaData - An array of the calculated alpha easing data applied to particles with alphaRates > 0.
110
+
*/
111
+
this.alphaData=null;
112
+
103
113
/**
104
114
* @property {number} gravity - Sets the `body.gravity.y` of each particle sprite to this value on launch.
105
115
* @default
@@ -174,6 +184,28 @@ Phaser.Particles.Arcade.Emitter = function (game, x, y, maxParticles) {
174
184
*/
175
185
this.emitY=y;
176
186
187
+
/**
188
+
* @property {boolean} autoScale - When a new Particle is emitted this controls if it will automatically scale in size. Use Emitter.setScale to configure.
189
+
*/
190
+
this.autoScale=false;
191
+
192
+
/**
193
+
* @property {boolean} autoAlpha - When a new Particle is emitted this controls if it will automatically change alpha. Use Emitter.setAlpha to configure.
194
+
*/
195
+
this.autoAlpha=false;
196
+
197
+
/**
198
+
* @property {boolean} particleBringToTop - If this is `true` then when the Particle is emitted it will be bought to the top of the Emitters display list.
199
+
* @default
200
+
*/
201
+
this.particleBringToTop=false;
202
+
203
+
/**
204
+
* @property {boolean} particleSendToBack - If this is `true` then when the Particle is emitted it will be sent to the back of the Emitters display list.
205
+
* @default
206
+
*/
207
+
this.particleSendToBack=false;
208
+
177
209
/**
178
210
* @property {number} _quantity - Internal helper for deciding how many particles to launch.
179
211
* @private
@@ -398,21 +430,11 @@ Phaser.Particles.Arcade.Emitter.prototype.emitParticle = function () {
* @param {number} [min=1] - The minimum value for this range.
546
576
* @param {number} [max=1] - The maximum value for this range.
577
+
* @param {number} [rate=0] - The rate (in ms) at which the particles will change in alpha from min to max, or set to zero to pick a random alpha between the two.
578
+
* @param {number} [ease=Phaser.Easing.Linear.None] - If you've set a rate > 0 this is the easing formula applied between the min and max values.
579
+
* @param {boolean} [yoyo=false] - If you've set a rate > 0 you can set if the ease will yoyo or not (i.e. ease back to its original values)
* @param {number} [min=1] - The minimum value for this range.
563
615
* @param {number} [max=1] - The maximum value for this range.
616
+
* @param {number} [rate=0] - The rate (in ms) at which the particles will change in scale from min to max, or set to zero to pick a random size between the two.
617
+
* @param {number} [ease=Phaser.Easing.Linear.None] - If you've set a rate > 0 this is the easing formula applied between the min and max values.
618
+
* @param {boolean} [yoyo=false] - If you've set a rate > 0 you can set if the ease will yoyo or not (i.e. ease back to its original values)
0 commit comments