Skip to content

Commit fc5eb25

Browse files
committed
Particles using a blend mode wouldn't render correctly after the updates in 3.11. If the blend mode changes during the processing of an emitter manager it'll now correctly rebind the texture, stopping the particles from vanishing. Fix phaserjs#3851
1 parent 4f6790f commit fc5eb25

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

src/gameobjects/particles/ParticleManagerWebGLRenderer.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,11 @@ var ParticleManagerWebGLRenderer = function (renderer, emitterManager, interpola
6565
scrollY = 0;
6666
}
6767

68-
renderer.setBlendMode(emitter.blendMode);
68+
if (renderer.setBlendMode(emitter.blendMode))
69+
{
70+
// Rebind the texture if we've flushed
71+
pipeline.setTexture2D(texture, 0);
72+
}
6973

7074
var tintEffect = false;
7175

0 commit comments

Comments
 (0)