Вход Регистрация
Файл: www/character.php
Строк: 218
<?php

include 'inc/mysql.php';

include 
'inc/check.php';

include 
'inc/functions.php';

top();

include 
'inc/account.php';

include 
'inc/interface.php';


if(isset(
$_SESSION['auth']) && $_SESSION['auth']==1){

$hp['width'] = 100/($account['max_hp']/$account['hp']);

$mp['width'] = 100/($account['max_mp']/$account['mp']);

echo 
'

<div class="title">

'
.$account['name'].' '.$account['lvl'].' ур.

</div>

<table width="100%">

<tr>

<td valign="top" width="50%">

<div style="height:13px;background:#5FA566;margin-bottom:2px;border-top-left-radius:2px;border-bottom-left-radius:2px;border-top-right-radius:2px;border-bottom-right-radius:2px;">

<div style="height:13px;padding-left:10px;float:left;font-size:11px;color:white;border-top-left-radius:2px;border-bottom-left-radius:2px;border-top-right-radius:2px;border-bottom-right-radius:2px;">'
.$account['hp'].'/'.$account['max_hp'].'</div>

<div style="height:13px;width:'
.$hp['width'].'%;background:#339D45;border-top-left-radius:2px;border-bottom-left-radius:2px;border-top-right-radius:2px;border-bottom-right-radius:2px;"></div></div>

</td><td valign="top" width="50%">

<div style="height:13px;background:#5B5BB5;margin-bottom:2px;border-top-left-radius:2px;border-bottom-left-radius:2px;border-top-right-radius:2px;border-bottom-right-radius:2px;">

<div style="height:13px;padding-left:10px;float:left;font-size:11px;color:white;border-top-left-radius:2px;border-bottom-left-radius:2px;border-top-right-radius:2px;border-bottom-right-radius:2px;">'
.$account['mp'].'/'.$account['max_mp'].'</div>

<div style="height:13px;width:'
.$mp['width'].'%;background:#4249CE;border-top-left-radius:2px;border-bottom-left-radius:2px;border-top-right-radius:2px;border-bottom-right-radius:2px;"></div></div>

</td>

</tr>

</table>

<div class="title">
<center>
<table align="center">
<tr><td>
'
;
$head=mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `id`='".$account['armor_head']."'"));
$body=mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `id`='".$account['armor_body']."'"));
$pants=mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `id`='".$account['armor_pants']."'"));
$gloves=mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `id`='".$account['armor_gloves']."'"));
$belt=mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `id`='".$account['armor_belt']."'"));
$ring=mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `id`='".$account['armor_ring']."'"));
$neckleace=mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `id`='".$account['armor_neckleace']."'"));
$earring=mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `id`='".$account['armor_earring']."'"));
$shoulder=mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `id`='".$account['armor_shoulder']."'"));
$weaponright=mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `id`='".$account['weapon_right']."'"));
$boots=mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `id`='".$account['weapon_boots']."'"));
$weaponshieldleft=mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `id`='".$account['weaponshield_left']."'"));
if (
$head){
    echo 
'<img src="/data/img/items/armor/'.$head['icon'].'.jpg" title="'.htmlspecialchars(stripslashes($head['name'])).'" width="30px" height="30px"><br />';
}else{
    echo 
'<img src="/data/img/items/empty.png" width="30px" title="Пусто" height="30px"><br />';
}
if (
$body){
    echo 
'<img src="/data/img/items/armor/'.$body['icon'].'.jpg" title="'.htmlspecialchars(stripslashes($body['name'])).'" width="30px" height="30px"><br />';
}else{
    echo 
'<img src="/data/img/items/empty.png" width="30px" title="Пусто" height="30px"><br />';
}
if (
$belt){
    echo 
'<img src="/data/img/items/armor/'.$belt['icon'].'.jpg" title="'.htmlspecialchars(stripslashes($belt['name'])).'" width="30px" height="30px"><br />';
}else{
    echo 
'<img src="/data/img/items/empty.png" width="30px" title="Пусто" height="30px"><br />';
}
if (
$pants){
    echo 
'<img src="/data/img/items/armor/'.$pants['icon'].'.jpg" title="'.htmlspecialchars(stripslashes($pants['name'])).'" width="30px" height="30px"><br />';
}else{
    echo 
'<img src="/data/img/items/empty.png" width="30px" title="Пусто" height="30px"><br />';
}
if (
$boots){
    echo 
'<img src="/data/img/items/armor/'.$ring['icon'].'.jpg" title="'.htmlspecialchars(stripslashes($boots['name'])).'" width="30px" height="30px"><br />';
}else{
    echo 
'<img src="/data/img/items/empty.png" width="30px" title="Пусто" height="30px"><br />';
}
if (
$weaponright){
    echo 
'<img src="/data/img/items/weapon/'.$weaponright['icon'].'.jpg" title="'.htmlspecialchars(stripslashes($weaponright['name'])).'" width="30px" height="30px">';
}else{
    echo 
'<img src="/data/img/items/empty.png" width="30px" title="Пусто" height="30px">';
}
echo 
'</td><td>
<img src="/data/img/units/'
.$account['class'].'/'.$account['race'].'_'.$account['class'].'.png" width="100" height="200" />
</td><td>'
;

if (
$earring){
    echo 
'<img src="/data/img/items/armor/'.$earring['icon'].'.jpg" title="'.htmlspecialchars(stripslashes($earring['name'])).'" width="30px" height="30px"><br />';
}else{
    echo 
'<img src="/data/img/items/empty.png" width="30px" title="Пусто" height="30px"><br />';
}
if (
$neckleace){
    echo 
'<img src="/data/img/items/armor/'.$neckleace['icon'].'.jpg" title="'.htmlspecialchars(stripslashes($neckleace['name'])).'" width="30px" height="30px"><br />';
}else{
    echo 
'<img src="/data/img/items/empty.png" width="30px" title="Пусто" height="30px"><br />';
}
if (
$shoulders){
    echo 
'<img src="/data/img/items/armor/'.$shoulders['icon'].'.jpg" title="'.htmlspecialchars(stripslashes($shoulders['name'])).'" width="30px" height="30px"><br />';
}else{
    echo 
'<img src="/data/img/items/empty.png" width="30px" title="Пусто" height="30px"><br />';
}
if (
$gloves){
    echo 
'<img src="/data/img/items/armor/'.$gloves['icon'].'.jpg" title="'.htmlspecialchars(stripslashes($gloves['name'])).'" width="30px" height="30px"><br />';
}else{
    echo 
'<img src="/data/img/items/empty.png" width="30px" title="Пусто" height="30px"><br />';
}
if (
$ring){
    echo 
'<img src="/data/img/items/armor/'.$ring['icon'].'.jpg" title="'.htmlspecialchars(stripslashes($ring['name'])).'" width="30px" height="30px"><br />';
}else{
    echo 
'<img src="/data/img/items/empty.png" width="30px" title="Пусто" height="30px"><br />';
}
if (
$weaponshieldleft){
    if (
$weaponshieldleft=='armor_shield'){
        echo 
'<img src="/data/img/items/armor/'.$weaponshieldleft['icon'].'.jpg" title="'.htmlspecialchars(stripslashes($weaponshieldleft['name'])).'" width="30px" height="30px"><br />';
    }
    else{
        echo 
'<img src="/data/img/items/weapon/'.$weaponshieldleft['icon'].'.jpg" title="'.htmlspecialchars(stripslashes($weaponshieldleft['name'])).'" width="30px" height="30px">';
    }
}else{
    echo 
'<img src="/data/img/items/empty.png" width="30px" title="Пусто" height="30px">';
}

echo 
'</td></tr>
</table>
</center>
<br>

<table width="99%">

<tr>

<td valign="top" width="30%">

<span style="color:gray">

Опыт<br>

</span>

</td>

<td width="20%" align="center">

'
.$account['exp'].'/'.($account['exp']+$lvl['exp']).'

</td>

<td valign="top" width="30%">

<span style="color:gray">

Золото<br>

</span>

</td>

<td width="20%" align="center">

'
.$account['gold'].'

</td>


</tr>

</table>



</div>

<div class="line"></div>

<div class="title">

Основное

<table width="99%">

<tr>

<td valign="top" width="30%">

<span style="color:gray">

Сила

<br>

Ум

<br>

Ловкость

<br>

Живучесть

<br />

Дух

</span>

</td>

<td valign="top" width="20%" align="center">

'
.$account['power'].'<br>'.$account['wit'].'<br>'.$account['dexterity'].'<br>'.$account['vitality'].'<br>'.$account['spirit'].'

</td>

<td valign="top" >

<span style="color:gray">

Сложение

<br>

Воля

<br>

Реакция

<br />

Очки жизни

<br />

Очки маны

</span>

</td>

<td width="20%" align="center">

'
.$account['adding'].'%<br>'.$account['will'].'%<br>'.$account['reaction'].'%<br />'.$account['max_hp'].'<br />'.$account['max_mp'].'

</td>

</tr>

</table>

</div>

<div class="line"></div>

<div class="title">

Мастерство

<table width="100%">

<tr>

<td width="39%">

<font color="gray">Защита от ударов</font>

</td>

<td>

'
.$account['feature_armor_weapon'].'%

</td>

<td>

<font color="gray">Мощн. удара</font>

</td>

<td>

'
.ceil(100+$account['feature_attack_weapon']).'%

</td>

</tr>

<tr>

<td width="39%">

<font color="gray">Защита от стрел</font>

</td>

<td>

'
.$account['feature_armor_arrow'].'%

</td>
<td>

<font color="gray">Мощн. стрел</font>

</td>

<td>

'
.ceil(100+$account['feature_attack_arrow']).'%

</td>

</tr>

<tr>

<td width="39%">

<font color="gray">Защита от магии</font>

</td>

<td>

'
.$account['feature_armor_magic'].'%

</td>

<td>

<font color="gray">Мощн. магии</font>

</td>

<td>

'
.ceil(100+$account['feature_attack_magic']).'%

</td>

</tr>

</table>

</div>
'
;

}else{

header ("Location: /?"); exit;

}

down();

?>
Онлайн: 4
Реклама