title: How to set the loudness of HTML5 audio?
body: <p>In an HTML5 game I'm making, I play a "thud" sound when things collide. However, it is a bit unrealistic. No matter the velocity of the objects, they will always make the same, relatively loud "thud" sound. What I'd like to do is to have that sound's loudness depend on velocity, but how do I do that? I only know how to play a sound.</p>
  
  <pre><code>playSound = function(id)
  {
      sounds[id].play();
  }
  </code></pre>
  
  <p><code>sounds</code> is an array full of <code>new Audio("url")</code>'s.</p>