# GPUParticleSystem is still updating with activeParticleCount and emitRate are 0

**URL:** <https://forum.babylonjs.com/t/gpuparticlesystem-is-still-updating-with-activeparticlecount-and-emitrate-are-0/42284>\
**Category:** Questions\
**Created:** [July 10, 2023, 6:50am UTC](https://forum.babylonjs.com/t/gpuparticlesystem-is-still-updating-with-activeparticlecount-and-emitrate-are-0/42284 "2023-07-10T06:50:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![tanpopo](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/tanpopo/32/32025_2.png) [@tanpopo](https://forum.babylonjs.com/u/tanpopo)\
**Post date:** [July 10, 2023, 6:50am UTC](https://forum.babylonjs.com/t/gpuparticlesystem-is-still-updating-with-activeparticlecount-and-emitrate-are-0/42284/1 "2023-07-10T06:50:00Z")

</div>

In my workaround, I’m using a custom param strength to control the particle system, when strength is bigger, I set emit rate and activeParticleCount to bigger, when strength is 0, I expect there is no particles introduced.

playground to reproduce: [https://playground.babylonjs.com/#PU4WYI#399](https://playground.babylonjs.com/#PU4WYI#399)  
In the play ground, if I set emitRate to 0 then activeParticleCount to 0, the particle system is still updating.  
I can understand this when emitRate is 0, but it is weird that activeParticleCount is not in use in this situation.

> <https://github.com/BabylonJS/Babylon.js/blob/cbb72fc23b511ba64c45001ad829ba86cd7e98ec/packages/dev/core/src/Particles/gpuParticleSystem.ts#L1661>

The problem is activeParticleCount will not be in use until `_accumulatedCount > 1`, it seems it is not necessary? I think activeParticleCount should work even if `_accumulatedCount <= 1`, so in my opinion it should be changed to:

```auto
if (this._accumulatedCount > 1) {
    const intPart = this._accumulatedCount | 0;
    this._accumulatedCount -= intPart;
    this._currentActiveCount = this._currentActiveCount + intPart;
}
this._currentActiveCount = Math.min(this._activeCount, this._currentActiveCount);

```

If this is expected, is it possible to achieve my ‘strength’ with GPUParticleSystem and how?

---

<div class="post-metadata">

**Author:** ![Evgeni\_Popov](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/evgeni_popov/32/4432_2.png) [@Evgeni\_Popov](https://forum.babylonjs.com/u/Evgeni_Popov)\
**Post date:** [July 10, 2023, 11:43am UTC](https://forum.babylonjs.com/t/gpuparticlesystem-is-still-updating-with-activeparticlecount-and-emitrate-are-0/42284/2 "2023-07-10T11:43:44Z")

</div>

I think this is a bug, the current active count should not be allowed to exceed the maximum number of active particles (`_activeCount`).

Here’s the PR:

> <https://github.com/BabylonJS/Babylon.js/pull/14036>
>
> See https://forum.babylonjs.com/t/gpuparticlesystem-is-still-updating-with-activ…eparticlecount-and-emitrate-are-0/42284
