diff --git a/src/core/particles/ParticleContainer.js b/src/core/particles/ParticleContainer.js index 28e1a62..8289de0 100644 --- a/src/core/particles/ParticleContainer.js +++ b/src/core/particles/ParticleContainer.js @@ -1,4 +1,5 @@ -var Container = require('../display/Container'); +var Container = require('../display/Container'), + CONST = require('../const'); /** * The ParticleContainer class is a really fast version of the Container built solely for speed, @@ -68,6 +69,14 @@ */ this.interactiveChildren = false; + /** + * The blend mode to be applied to the sprite. Apply a value of blendModes.NORMAL to reset the blend mode. + * + * @member {number} + * @default CONST.BLEND_MODES.NORMAL; + */ + this.blendMode = CONST.BLEND_MODES.NORMAL; + this.setProperties(properties); } diff --git a/src/core/particles/ParticleContainer.js b/src/core/particles/ParticleContainer.js index 28e1a62..8289de0 100644 --- a/src/core/particles/ParticleContainer.js +++ b/src/core/particles/ParticleContainer.js @@ -1,4 +1,5 @@ -var Container = require('../display/Container'); +var Container = require('../display/Container'), + CONST = require('../const'); /** * The ParticleContainer class is a really fast version of the Container built solely for speed, @@ -68,6 +69,14 @@ */ this.interactiveChildren = false; + /** + * The blend mode to be applied to the sprite. Apply a value of blendModes.NORMAL to reset the blend mode. + * + * @member {number} + * @default CONST.BLEND_MODES.NORMAL; + */ + this.blendMode = CONST.BLEND_MODES.NORMAL; + this.setProperties(properties); } diff --git a/src/core/particles/webgl/ParticleRenderer.js b/src/core/particles/webgl/ParticleRenderer.js index c94f0e4..91f8705 100644 --- a/src/core/particles/webgl/ParticleRenderer.js +++ b/src/core/particles/webgl/ParticleRenderer.js @@ -189,7 +189,8 @@ // if the uvs have not updated then no point rendering just yet! - //this.renderer.blendModeManager.setBlendMode(sprite.blendMode); + this.renderer.blendModeManager.setBlendMode(container.blendMode); + var gl = this.renderer.gl; var m = container.worldTransform.copy( this.tempMatrix );