<?xml version="1.0" encoding="utf-8"?>

<puzzle>
   <!-- team include(s), max of 2 per puzzle -->
   <includeTeam>humans</includeTeam>
   <includeTeam>orcs</includeTeam>
   <!-- board spec -->
   <board>
      <Art gridOffsetX="-3.0" gridOffsetY="0.0">OrcGameBoard.pvr</Art>
      <deployZone>
         <tile x="1" y="0"/>
         <tile x="2" y="1"/>
         <tile x="3" y="2"/>
         <tile x="2" y="3"/>
         <tile x="1" y="4"/>
      </deployZone>
      <premiumTiles>
   	  </premiumTiles>
      <preplace name="SpikyMediumCrystal" x="2" y="0" player ="0" victoryHealthPool="true"/>       
      <preplace name="SpikyMediumCrystal" x="2" y="4" player ="0" victoryHealthPool="true"/>              
      <preplace name="SpikyMediumCrystal" x="6" y="0" player ="1" victoryHealthPool="true"/>       
      <preplace name="SpikyMediumCrystal" x="6" y="4" player ="1" victoryHealthPool="true"/>              
      <preplace name="wizard" x="4" y="2" player ="1" healthFraction="0.5"/>
      <preplace name="cleric" x="5" y="4" player ="1" healthFraction="0.125"/>
      <preplace name="archer" x="5" y="3" player ="1" healthFraction="0.125"/>       
      <preplace name="cleric" x="5" y="1" player ="1" healthFraction="0.125"/>
      <preplace name="archer" x="6" y="3" player ="1" healthFraction="0.125"/>
      <preplace name="knight" x="4" y="1" player ="1" healthFraction="0.1"/>  
   </board>
   
   <!-- tile spec -->
   <tileAllocation randomize="false">
	  <tile name="axethrower">1</tile>
	  <tile name="warrior">1</tile>
      <tile name="witch">1</tile>
	  <tile name="shaman">1</tile>      
   </tileAllocation>   
   <script>
      <onStart>
         <hideUI name="SubmitButton"/>      
         <hideUI name="SettingsButton"/>         
         <showDialog name="welcome" tapToClose="true" closeTag="OK1" showTapIcon="true">Challenge_Goal_TeamKill</showDialog>
      </onStart>
      <onNamedTag tagName="OK1">
         <hideAllDialogs/>
         <setSection name="GoWin"/>
      </onNamedTag>
      <section name="GoWin">
         <onKO count="6">
            <sendTag tagName="Winning"/>
            <victory/>
         </onKO> 
         <untilTag tagName="Winning">
            <onAPRemaining count="0">
                <hideAllDialogs/>
                <showDialog name="fail" vAlign="Top" background="TutorialBubble02.png">Challenge_Defeat_NoAP</showDialog>
                <showArrow uiElement="ResetButton" orientation="Down"/>
            </onAPRemaining>
            <onUndo>
               <hideAllDialogs/>
               <hideArrow/>
            </onUndo>
          </untilTag> 
      </section>
   </script>
</puzzle>