<?php
/*======================================================================*\
|| #################################################################### ||
|| # EoT-Clan BF3 Leaderboard                                         # ||
|| # ---------------------------------------------------------------- # ||
|| # Dieses Copyright darf nicht entfernet werden                     # ||
|| # This file may not be redistributed in whole or significant part. # ||
|| # -----------------BF3 Leaderboard is a free Software--------------# ||
|| #                   http://eot-clan.net                            # ||
|| #################################################################### ||
\*======================================================================*/
require_once ('../inc/config.php');
require_once ('../language/'.$row['language'].'.php');

$_GET = security::escape($_GET);
$_POST = security::escape($_POST);

require_once ('../inc/details.query.php');
 
echo $styleSettings;


$aWeaponsGeneral = array(                
             //general
             "sg870" => 1,
             "pG17" => 4,
             "smPP2000" => 7,
             "pM412" => 5000,
             "pM9F" => 10,
             "pMP443L" => 13,
             "smUMP" => 16,
             "pG17S" => 19,
             "sgM1014" => 22,
             "smMP7" => 34000,
             "pM9S" => 25,
             "pg18" => 30,
             "smPDR" => 32,
             "sgSaiga" => 34,
             "sgDAO" => 38,
             "smP90" => 40,
             "pg18S" => 41,
             "pM93R" => 86000,
             "sgUSAS" => 43,
             "pMP443S" => 44,
             "smVAL" => 45);

?>
<title>All Classes</title>
<table class="default" cellspacing="0" cellpadding="2">
 <thead>
  <td class="head" colspan="10" cellspacing="0"> <?php echo LANG_GENERAL_UNLOCKS_TITLE; ?></td>
	  <tr><td class="result" width="200px" height="400px" rowspan="4" style="border-right:<?php echo $style['result_border']; ?>">
	  		<img src="<?php echo $domain; ?>/img/fav/class/weapons/all.png" />
	  	</td>
	  	<?php  
         $i = 0;
         $ii = 0;
         $iii = 0;
         foreach($aWeaponsGeneral as $key => $unlocks){
         	
         	if ($key == "pM412" OR $key == "pM93R" OR $key == "smMP7" ){
         		$points = $data['coop_score'];
         		$name = LANG_GENERAL_UNLOCKS_COOP_POINTS;
         	}else{
         		$name = LANG_GENERAL_UNLOCKS_RANK_POINTS;
         		$points = $data['rank'];
         	}
         	
          $weaponsName = 'LANG_WEAPONS_'.$key;
	  	    $weaponsTEXT = 'LANG_WEAPONS_TEXT_'.$key;
         	
         	if ($unlocks <= $points){
         		$progress = "";	
         		$img = '<img src="'.$domain.'/img/weapons/'.$key.'.png" width="80px" />';
         		$need = "";
         	}else{
         		$progress = $points*100/$unlocks;
         		$progress = '<div class="progress_small" style="width:90px;">
	 		  <div class="progress_size_small" style="width:'.$progress.'%;max-width:89px;">&nbsp;</div>
	 		 </div>';
	 		      $img = '<img src="'.$domain.'/img/weapons/transparent/'.$key.'.png" width="80px" />';
	 		      $need = $points.'/'.$unlocks.$name;
	 		      
	 		}
         	
	     ?>
         <td class="result" width="100px" rowspan="1" height="100px">
         	 <a class="tooltip"><?php echo $img; ?>
         	 	<span style="margin-top:10px;margin-left:-60px;width:250px;">
         	 	  <div style="text-align:center;width:120px;"><b><?php echo constant($weaponsName); ?></b></div><br />
	  			     <div style="float:left;"><img src="<?php echo $domain; ?>/img/weapons/<?php echo $key; ?>.png" width="120px"/></div><div style="text-align:left;"><?php echo constant($weaponsTEXT); ?></div>
	  			    <div class="DIVtext"><?php echo $need; ?></div>
	  			  </span>
	  			 </a> 
         	<br/><?php echo $progress; ?>
         	</td>
        <?php  
        if (++$i == 6 ) echo'<tr />';
        if (++$ii == 12 ) echo'<tr />';
        if (++$iii == 18 ) echo'<tr />';
        } ?>	
        	<td class="result" width="100px" rowspan="1"></td>
        	<td class="result" width="100px" rowspan="1"></td>
        	<td class="result" width="100px" rowspan="1"></td>
 	</table>


      