title: Playing particles multiple times
body: <p>So I'm pretty sure there is a simple answer to this, but I don't know it or really what to look for. I have some code that is designed so that, when the player holds down the mouse button, a particle emitter sprays particles where they are facing, and when they stop holding it down, it stops spraying. So far, that is working, except, if they make a burst of particles, stop clicking, then try to click again, no new particles will be created until the first cloud stops existing. I'm not sure if I need to change some settings or not. Any suggestions would be appreciated.</p>
  
  <p>Here is the code:</p>
  
  <pre><code>if (Input.GetMouseButton (0) &amp;&amp; scoreTrack.sprayBottles &gt; 0) {
          if(!sprayEffect.GetComponent&lt;ParticleSystem&gt; ().isPlaying) 
              sprayEffect.GetComponent&lt;ParticleSystem&gt; ().Play ();
  }
  else if (!Input.GetMouseButton (0)) {
          if(sprayEffect.GetComponent&lt;ParticleSystem&gt; ().isPlaying)
              sprayEffect.GetComponent&lt;ParticleSystem&gt;().Stop();
  
  }
  </code></pre>
  
  <p>What the settings look like:</p>
  
  <p><a href="https://i.stack.imgur.com/Swida.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Swida.png" alt="The current settings"></a></p>