title: How to make a sound only play once
body: <p>How do I make it play the sound only once I tap the spacebar and not when I'm holding it down and when I'm holding it down I want it to only play it once.</p>
  
  <pre><code>// makes my character jump
  if (keys.jump &amp;&amp; is_grounded) {
      yvel = jump;
      // plays a cat sound when I jump problem
      cat.play(); 
  }
  </code></pre>