Файл: npc.php
Строк: 11
<?php
define('cms', 1);
require_once 'core.php';
if ($user)
{
Error_Reporting(E_ALL & ~E_NOTICE);
$u = mysql_fetch_array(mysql_query("SELECT `level` FROM `users` WHERE `id` = '".$user."'"));
echo '<div class="menu">Информация</div>';
echo '<div class="pt">';
switch ($_GET['a'])
{
default:
if ($_GET['bot'])
{
$b = mysql_fetch_array(mysql_query("SELECT * FROM `bots` WHERE `id` = '".abs(round($_GET['bot']))."'"));
if (!empty($b) AND $b['level'] <= $u['level'])
{
echo '<b>'.htmlspecialchars($b['login']).'</b><br />';
echo '<img src="./img/bots/'.$b['img'].'.jpg" height="150" width="160">';
echo '<br />Аткака: '.$b['damage'].'<br />';
echo 'Защита: '.$b['armor'].'<br />';
echo 'Жизни: '.$b['hp'];
} else echo 'Несуществующий NPC';
}
break;
case 'search':
break;
}
echo '</div>';
}
else
{
header('Location: ./index.php');
}
include './include/foot.php';
?>