Файл: komp.php
Строк: 90
<?
define('PROTECTOR', 1);
include('files/db.php');
include($path.'files/auth.php');
if ($user_id==0){
header('location: index.php');exit;
}
$textl='Комплект';
include($path.'files/core.php');
include($path.'files/head.php');
include($path.'files/zag.php');
echo '<div class="v3 bts brs bls b p v12">Навигация</div><div class="v4 bts brs bls bbs p">
<img src=img/main/i26.png class="menu"> <a href=game.php>главная</a> / <a href=?>комплект</a>
</div>';
echo '<div class="v8"><div class="v3 bts brs bls b p v12">Комплект</div><div class="v2 bts brs bls bbs p t3">';
$kggf=mysql_query("SELECT * FROM `komp` WHERE `id`='".$_GET['id']."'");
$gre=mysql_fetch_array($kggf);
if($gre['id']<19)
{
$tr=mysql_query("SELECT * FROM `torg_red` WHERE `komp`='".$gre['id']."' ORDER BY `id`");
$c='<font color=#990099>'.$t['name'].'</font>';
}
else
{
$tr=mysql_query("SELECT * FROM `torg_ger` WHERE `komp`='".$gre['id']."' ORDER BY `lvl`");
$c=''.$t['name'].'';
}
while($t=mysql_fetch_array($tr))
{
echo '<table>
<tr>
<td><img src=img/arm/'.$t['tip'].'/'.$t['img'].'.jpg></td>
<td><img src=img/main/p28.png>';
if($gre['id']<19)
{
echo'<a href=trade_red.php?td=info&id='.$t['id'].'><font color=#990099>'.$t['name'].'</font>';
}
else
{
echo'<a href=trade_ger.php?td=info&id='.$t['id'].'>'.$t['name'].'';
}
echo'</a> <img src=img/main/p10.png> '.$t['lvl'].' <img src=img/main/p36.png> '.$t['rang'].'<br>
</td>
</tr>
</table>
';
}
echo '<font color=#ff9900><b>Бонус комплекта:</b></font><br>';
echo'3 предмета: ';
if($gre['sila']>0)
{
echo '<img src=img/main/b8.png> <font color=#00ff00>+'.$gre['sila'].'</font> ';
}
if($gre['hp']>0)
{
echo '<img src=img/main/p3.png> <font color=#00ff00>+'.$gre['hp'].'</font> ';
}
if($gre['arm']>0)
{
echo '<img src=img/main/p2.png> <font color=#00ff00>+'.$gre['arm'].'</font> ';
}
echo'<br>';
echo'4 предмета: ';
if($gre['sila']>0)
{
echo '<img src=img/main/b8.png> <font color=#00ff00>+'.$gre['sila'].'</font> ';
}
if($gre['hp']>0)
{
echo '<img src=img/main/p3.png> <font color=#00ff00>+'.$gre['hp'].'</font> ';
}
if($gre['arm']>0)
{
echo '<img src=img/main/p2.png> <font color=#00ff00>+'.$gre['arm'].'</font> ';
}
if($gre['krit']>0 and $gre['blok']>0)
{
$grek=$gre['krit'];
$greb=0;
}
elseif($gre['krit']>0 and $gre['blok']==0)
{
$grek=round($gre['krit']/2);
$greb=0;
}
elseif($gre['krit']==0 and $gre['blok']>0)
{
$greb=round($gre['blok']/2);
$grek=0;
}
if($grek>0)
{
echo '<img src=img/main/b2.png> <font color=#00ff00>+'.$grek.'%</font> ';
}
if($greb>0)
{
echo '<img src=img/main/b23.png> <font color=#00ff00>+'.$greb.'%</font> ';
}
echo'<br>';
echo'5 предметов: ';
if($gre['sila']>0)
{
echo '<img src=img/main/b8.png> <font color=#00ff00>+'.$gre['sila'].'</font> ';
}
if($gre['hp']>0)
{
echo '<img src=img/main/p3.png> <font color=#00ff00>+'.$gre['hp'].'</font> ';
}
if($gre['arm']>0)
{
echo '<img src=img/main/p2.png> <font color=#00ff00>+'.$gre['arm'].'</font> ';
}
if($gre['krit']>0)
{
echo '<img src=img/main/b2.png> <font color=#00ff00>+'.$gre['krit'].'%</font> ';
}
if($gre['blok']>0)
{
echo '<img src=img/main/b23.png> <font color=#00ff00>+'.$gre['blok'].'%</font> ';
}
echo '</div></div>';
include('files/down.php');
?>