title: How do I check if an array of Booleans is all true in Actionscript 3?
body: <p>Well, technically not all the Booleans. I have an array (ArrayMain) that stores a player and a bunch of other movieclips in an array, and I have another array of Booleans (this corresponds to the ArrayMain and is called ArrayDeadCheck) that I need to check.</p>
  
  <p>My player is the first in the array, so it occupies ArrayMain[0] and in ArrayDeadCheck will always be false (it never dies). I need to loop through the rest of ArrayDeadCheck (which can vary because for my enemy number from level to level can change, so ArrayMain's length might vary). So I need to do something like this?:</p>
  
  <pre><code>for (var i:int=1; i &lt; ArrayMain.length; i++)
  { 
      //Code/condition?? that does this: 
      //if all of the Booleans in ArrayMain from 1 to n are true
  
      if (Insert condition here)
  
      {
  
      //trigger another Boolean called EndGame to end the game
  
      EndGame = true;
  
      }
  }
  </code></pre>
  
  <p>Sorry if this is a repeated question (I saw a similar question but that was in Java, AS3 conversion please?) or if it's formatted weirdly, it's my first question here. Please help!! And thank you very much in advance, if anyone is kind enough to help :)</p>