title: delay in as3 while loop
body: <p>I am using as3.  My sprites are not working correctly on hittestpoint in a while loop.  I think this is because it is going too fast before it can update the display.  So I would like to add a delay to the while loop.  What is the easiest way to do this?</p>
  
  <p>Like:</p>
  
  <pre><code>while (condition){
  MAIN CODE HERE    
  CODE FOR DELAY OF 20ms    
  }
  </code></pre>
  
  <p>How can I do a delay in as3?</p>