Вход Регистрация
Файл: mpets/head.php
Строк: 83
<!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.0//EN" "http://www.wapforum.org/DTD/xhtml-mobile10.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/><link rel="shortcut icon" href="favicon.ico" />
<link rel="stylesheet" type="text/css" media="all" href="style/index.css" />
<?echo "<title>$titles</title>";?>
</head>
<body>
<div class="main"><div class="content">
<?
echo '    <?xml version="1.0" encoding="utf-8"?>';
$mpets=mysql_fetch_array(mysql_query("SELECT * FROM `mpets` WHERE `id_user`='".$user['id']."'"));

$mpets_user_opit_dop=$mpets['opit_dop']/3*2;
$mpets_user_opit=$mpets['opit_dop'];
$i=$mpets_user_opit/100;
$proc=round($mpets['opit']/$i);



///Авторизация
if (!isset($user)){
echo 
'<div class="warning-block large_orange"><center>Чтобы играть надо <a href="/reg.php">зарегистрироваться</a></center></div>';
exit;
}

echo 
'
<div class="content">
        <div class="header"><div class="top-panel2">
                <div class="wrapper1"><div class="wrapper2">
'
;
echo 
'<div class="pet-icon">';
if(
$mpets['ustal']=='-1')
echo
'<img src="img/avatars.png" height="50" alt="pet">';
else if(
$mpets['vid_pets']!='0')
echo
'<img src="img/avatar/avatarr'.$mpets['vid_pets'].'.png" alt="pet">';
else echo
'<img src="img/avatar'.$mpets['pol'].'.png" height="50" alt="pet">';
echo 
'</div>';
echo 
'<div class="data-panel">
                        <div class="wrap1"><div class="wrap2">
                            <div class="data">
                                <div class="indicators">
'
;
echo
'
                                    <div class="item"><img src="img/icons/beauty.png" /> '
.$mpets['krasota'].'</div>
                                    <div class="item"><img src="img/icons/coin.png" /> '
.$mpets['monet'].'</div>
                                    <div class="item"><img src="img/icons/heart.png" /> '
.$mpets['serd'].'</div>
</div>
'
;
if(
$mpets['eda_time']>time()&&$mpets['igra_time']>time())echo '<div class="refresh"><a href="?" class="refresh_ref"><img src="img/icons/refresh.png" alt="refresh"></a></div>';
echo
'
                                
                            </div>
                            <div class="experience">
                                <div class="wrp1"><div class="wrp2"><div class="wrp3">
                                    <table>
                                        <tr>
                                            <td>
                                                <div class="star">
                                                    <img src="img/icons/up.png" /> '
.$mpets['urov'].'
                                                </div>
                                            </td>
                                            <td style="width:100%;">
                                                <div class="progressbar">
                                                    <div class="scale">
                                                        <div class="mask">
                                                            <div class="in1">&nbsp;</div>
                                                        </div>
                                                        <div class="scl" style="width:'
.$proc.'%;">
                                                            <div class="in1"><div class="in2">&nbsp;</div></div>
                                                        </div>
                                                    </div>
                                                </div>
                                            </td>
                                            <td>
                                                <div class="percent">
                                                    '
.$proc.'%
                                                </div>
                                            </td>
                                        </tr>
                                    </table>
                                </div></div></div>
                            </div>
                        </div></div>
                    </div>
                </div></div>
            </div></div>
  '
;     

if(
$mpets['opit']>=$mpets['opit_dop']){
mysql_query("UPDATE `mpets` SET `urov` = '".($mpets['urov']+1)."', `opit_dop` = '".($mpets['opit_dop']+$mpets_user_opit_dop)."',`opit` = '0',`monet` = '".($mpets['monet']+10)."',`krasota` = '".($mpets['krasota']+1)."',`ustal` = '".($mpets['ustal']+1)."' WHERE `id_user` = '".$user['id']."' LIMIT 1");
echo 
'
<div class="warning-block large_orange"><span class="text_log succes"><b>Вы достигли '
.($mpets['urov']+1).' уровня!<br />Награда: </b>монет <img class="price_img" src="img/icons/coin.png" />10, красота <img class="price_img" src="img/icons/beauty.png" />1</span></div>
'
;
}

if(
$mpets['urov']>=20)$ustal_urov_time '120';
else if(
$mpets['urov']>=10 && $mpets['urov']<20)$ustal_urov_time '80';
else if(
$mpets['urov']<10)$ustal_urov_time '45';

if(
$mpets['ustal']>=$ustal_urov_time){
mysql_query("UPDATE `mpets` SET `ustal` = '-1',`igra_time` = '".($time+1800)."',`eda_time` = '".($time+1800)."' WHERE `id_user` = '".$user['id']."' LIMIT 1");
echo 
'<div class="warning-block large_orange"><span class="succes"><b>Питомец устал и уснул</b><br />Возвращайтесь через 30 минут  и питомец будет снова рад вас видеть!</span></div>';
}
$podarok_v_den=date('d.m.y'time());
if(
$podarok_v_den != $mpets['podarok_v_den']){
mysql_query("UPDATE `mpets` SET `monet` = '".($mpets['monet']+20)."',`podarok_v_den` = '$podarok_v_den' WHERE `id_user` = '".$user['id']."' LIMIT 1");
echo 
'<div class="warning-block large_orange"><span class="succes blocks">Ежедневный подарок!<br /><img class="price_img" src="img/icons/coin.png" />20 монет<br />Приходи завтра и получишь еще монет!</span></div>';
}
Онлайн: 2
Реклама