Файл: rayb.me/profile.php
Строк: 750
<?php
require_once 'system/func.php';
$id = text($_GET['id']);
if($id) $profile = mysqli_fetch_assoc(DB::Query("SELECT * FROM `users` WHERE `id` = '".$id."'"));
else $profile = $user;
if(isset($_GET['okdx2'])){
$title = 'Подтверждение х2 дохода?';
require_once 'system/header.php';
echo '<div class="block">';
echo '<div class="feedback">';
echo '<center>Удвоить доход за ангелы х2?<br>';
echo '<a href="/dx2/'.$user['dubl'].'/" class="myButton"> Да </a>';
echo ' | ';
echo '<a href="/profile/" class="myButton"> Нет </a>';
echo '</center></div></div>';
require_once 'system/footer.php';
exit;
}
if(isset($_GET['okgr'])){
$title = 'Подтверждение прописки?';
require_once 'system/header.php';
echo '<div class="block">';
echo '<div class="feedback">';
echo '<center>Вы точно хотите купить прописку?<br>';
echo '<a href="/gr/'.$user['g_id'].'/'.rand(1000,9999).'" class="myButton"> Да </a>';
echo ' | ';
echo '<a href="/profile/" class="myButton"> Нет </a>';
echo '</center></div></div>';
require_once 'system/footer.php';
exit;
}
if(!$profile){
$_SESSION['msg'] == 'Такого игрока не существует';
go('/online?search');
}
if(isset($_GET['clan_memb']) and $uid != $profile['id'] and $user['clan_rang'] > 2 and $profile['id_clan'] == 0 and $profile['side'] == $user['side']){
DB::Query("INSERT INTO `clan_memb` SET `id_user` = '".$profile['id']."', `id_user2` = '".$uid."', `login` = '".$ulogin."', `id_clan` = '".$user['id_clan']."'");
$_SESSION['msg'] = "Заявка отправлена!";
go('?');
}
$clp = mysqli_fetch_assoc(DB::Query("SELECT * FROM `clans` WHERE `id` = '".$profile['id_clan']."'"));
$cst = $clp['stat'];
$pms = $money_updater[0]*$p;
$pcms = ($pms*$cst)/100;
$money_sek_angel = $pms+$pcms;
$mdsec = $pms+$pcms;
$tat = tls(time()-$user['tangels']);
if(isset($_GET['block']) and $user['access']>=2){
DB::Query("INSERT INTO `ban` SET `id_user` = '".$profile['id']."', `id_admin` = '".$uid."', `last` = '".(time()+60*60*24*365)."', `text` = 'спам', `block` = '1'");
DB::Query("UPDATE `users` SET `fon` = '0.png' WHERE `id` = '".$profile['id']."'");
DB::Query("UPDATE `users` SET `ava` = '0.png' WHERE `id` = '".$profile['id']."'");
DB::Query("UPDATE `users` SET `status` = 'Rayb.Me' WHERE `id` = '".$profile['id']."'");
DB::Query("UPDATE `users` SET `angels` = '0' WHERE `id` = '".$profile['id']."'");
DB::Query("DELETE FROM `mail` WHERE `in` = '".$profile['id']."'");
DB::Query("DELETE FROM `topic` WHERE `id_user` = '".$profile['id']."'");
DB::Query("DELETE FROM `kont` WHERE `id_user` = '".$profile['id']."'");
DB::Query("DELETE FROM `cforum_topic` WHERE `id_user` = '".$profile['id']."'");
DB::Query("DELETE FROM `chat` WHERE `id_user` = '".$profile['id']."'");
DB::Query("DELETE FROM `cforum_comments` WHERE `id_user` = '".$profile['id']."'");
DB::Query("DELETE FROM `clanchat` WHERE `id_user` = '".$profile['id']."'");
DB::Query("DELETE FROM `room_users` WHERE `id_user` = '".$profile['id']."'");
DB::Query("DELETE FROM `topic_msg` WHERE `id_user` = '".$profile['id']."'");
$_SESSION['msg'] = 'Пользователь заблокирован, сообщения пользователя были везде удалены';
go('?');
}
if(isset($_GET['block_fon']) and $user['access'] >= 1){
mysql_query("UPDATE `users` SET `fon` = '0.png' WHERE `id` = '".$profile['id']."'");
$_SESSION['msg'] = 'Fon Delete';
header('Location: ?');
exit;
}
if(isset($_GET['block_ava']) and $user['access'] >= 1){
mysql_query("UPDATE `users` SET `ava` = '0.png' WHERE `id` = '".$profile['id']."'");
$_SESSION['msg'] = 'Avatars Delete';
header('Location: ?');
exit;
}
if(isset($_GET['block_status']) and $user['access'] >= 1){
mysql_query("UPDATE `users` SET `status` = 'Rayb.Me' WHERE `id` = '".$profile['id']."'");
$_SESSION['msg'] = 'Status Delete';
header('Location: ?');
exit;
}
if(isset($_GET['angl'])){
$id = text($_GET['angl']);
$title = 'Сброс ангелов?';
require_once 'system/header.php';
echo '<div class="block">';
echo '<div class="feedback">';
echo '<a class="myButton" href="?angels"> Да, сбросить</a>';
echo ' | ';
echo "<a href='/profile/' class='myButton'>Нет, отмена</a>";
echo "</div></div>";
require_once 'system/footer.php';
exit;
}
if(isset($_GET['angels'])){
$id = text($_GET['angels']);
$angels_bonus = ($user['angels_bonus']+1);
$angels = text(ceil(100*sqrt(($money_sek_angel*$tat)/1000000000)));
$gold = text(2);
$money_sek = text(0);
if($money_sek_angel < 100){
$_SESSION['msg'] = "Ваш доход должен быть больше <img width='20' height='20' src='/img/money_36.png'/> ".n_f(100)."";
header('Location: /profile/');
exit;
}else{
mysql_query("UPDATE `room_users` SET `level` = '0', `pay_update` =`pay`, `give_money_sek` = '0', `money_sek` = '0' WHERE `id_user` = '".$uid."'");
mysql_query("UPDATE `users` SET `angels_bonus` = '".text($user['angels_bonus']+1)."', `angels` = '".text($user['angels']+$angels)."', `gold` = '$gold', `tangels` = '".time()."' WHERE `id` = '$uid'");
header('Location: /profile/');
exit;
}
}
if(isset($_GET['angl_ruby'])){
$id = text($_GET['angl_ruby']);
$title = 'Сброс ангелов?';
require_once 'system/header.php';
echo "<div class='block'>";
echo "<div class='feedback'>";
echo '<a class="myButton" href="?angels_ruby">Да</a>';
echo ' | ';
echo "<a href='/profile/' class='myButton'> Нет </a>";
echo "</div></div>";
require_once 'system/footer.php';
exit;
}
if(isset($_GET['angels_ruby'])){
$ruby = 250;
$id = text($_GET['angels_ruby']);
$angels_bonus = text($user['angels_bonus']+1);
$angels = text(ceil(100*sqrt(($money_sek_angel*$tat)/1000000000)));
if($user['ruby'] < $ruby){
$_SESSION['msg'] = "Не хватает <img width='20' height='20' src='/img/ruby.png'/> ".n_f($ruby-$user['ruby'])."";
header('Location: /profile/');
exit;
}else{
mysql_query("UPDATE users SET `angels_bonus` = '".text($user['angels_bonus']+1)."', `angels` = '".text($user['angels']+$angels)."', `tangels` = '".time()."', `ruby` = '".text($user['ruby']-$ruby)."' WHERE `id` = '$uid'");
$_SESSION['msg'] = 'Вы успешно сбросили бизнес за рубины';
header('Location: /profile/');
exit;
}
}
if(isset($_GET['angl3'])){
$id = text($_GET['angl3']);
$title = 'Сброс х 2 ангелов?';
require_once 'system/header.php';
echo "<div class='block'>";
echo "<div class='feedback'>";
echo '<a class="myButton" href="?angels3"> Да, сбросить</a>';
echo ' | ';
echo "<a href='/profile/' class='myButton'>Нет, отмена</a>";
echo "</div></div>";
require_once 'system/footer.php';
exit;
}
if(isset($_GET['angels3'])){
$ruby = 10000;
$id = text($_GET['angels3']);
$angels_bonus = text($user['angels_bonus']+1);
$angels = text(ceil(100*sqrt(($money_sek_angel*$tat)/1000000000)));
if($user['ruby'] < $ruby){
$_SESSION['msg'] = "Не хватает <img width='20' height='20' src='/img/ruby.png'/> ".n_f(($ruby-$user['ruby']))."";
header('Location: /profile/');
exit;
}else{
mysql_query("UPDATE users SET `angels_bonus` = '".text($user['angels_bonus']+1)."', `angels` = '".text(($user['angels']+(($angels)*2)))."', `tangels` = '".time()."', `ruby` = '".text($user['ruby']-$ruby)."' WHERE `id` = '".$myID."'");
$_SESSION['msg'] = 'Вы успешно сбросили х2 бизнес за рубины';
header('Location: /profile/');
exit;
}
}
if(isset($_GET['angl4'])){
$id = text($_GET['angl4']);
$title = 'Сброс х 4 ангелов?';
require_once 'system/header.php';
echo "<div class='block'>";
echo "<div class='feedback'>";
echo '<a class="myButton" href="?angels4"> Да, сбросить</a>';
echo ' | ';
echo " <a href='/profile/' class='myButton'>Нет, отмена</a>";
echo "</div></div>";
require_once 'system/footer.php';
exit;
}
if(isset($_GET['angels4'])){
$id = text($_GET['angels4']);
$angels_bonus = text($user['angels_bonus']+1);
$angels = text(ceil(100*sqrt(($money_sek_angel*$tat)/1000000000)));
$ruby = 50000;
if($user['ruby'] < $ruby){
$_SESSION['msg'] = "Не хватает <img width='20' height='20' src='/img/ruby.png'/> ".n_f(($ruby-$user['ruby']))."";
header('Location: /profile/');
exit;
}else{
mysql_query("UPDATE users SET `angels_bonus` = '".text($user['angels_bonus']+1)."', `angels` = '".text(($user['angels']+((($angels)*4)))) ."', `tangels` = '".time()."', `ruby` = '".text($user['ruby']-$ruby)."' WHERE `id` = '".$myID."'");
$_SESSION['msg'] = 'Вы успешно сбросили х4 бизнес за рубины';
header('Location: /profile/');
exit;
}
}
## dubl
if(isset($_GET['dubl'])){
$id = abs(intval($_GET['dubl']));
if($user['angels'] < ($user['gold_dubl'])){
header('Location: /profile/ ');
exit;
}else{
mysql_query("UPDATE `users` SET `angels` = '".text($user['angels']-$user['gold_dubl'])."', `dubl` = '".text($user['dubl']+1)."', `x2` = '".text($user['x2']*2)."', `gold_dubl` = '".text($user['gold_dubl']*10)."' WHERE (`id` = '".$myID."')");
}
header('Location: /profile/ ');
exit;
}
if(isset($_GET['g_buy'])){
$id = abs(intval($_GET['g_buy']));
$g_buy = mysql_fetch_assoc(mysql_query("SELECT * FROM `gr` WHERE `id_up` = '".$id."'"));
if($user['g_cena'] < ($dubl['ruby'])){
header('Location: /profile/ ');
exit;
}else{
$g_buy = mysql_fetch_assoc(mysql_query("SELECT * FROM `gr` WHERE `id_up` = '".$id."'"));
mysql_query("UPDATE `users` SET `ruby` = '".text($user['ruby']-$g_buy['g_cena'])."', `g_id` = '".text($user['g_id']+1)."', `g_x2` = '".text($g_buy['g_x2'])."', `g_cena` = '".text($user['g_cena']*2)."' WHERE (`id` = '".$myID."')");
}
header('Location: /profile/ ');
exit;
}
if(isset($_GET['pay10'])){
require_once 'system/header.php';
if(isset($_POST['summ'])){
$id = text($_GET['summ']);
$pppay = text($_POST['summ']);
$rubu = text(10*$pppay);
$lpay = text($pppay);
$repay = (($money_sek_angel*86400)*$lpay);
if($pppay < 1){
$_SESSION['msg'] = 'Минимальная покупка возможна только от 1 и больше';
header('Location: /profile/pay/10/');
exit;
}
if($pppay > 1000){
$_SESSION['msg'] = 'Максимальная покупка возможна только до 1000 и меньше';
header('Location: /profile/pay/10/');
exit;
}
if($user['ruby'] < $rubu){
$_SESSION['msg'] = "Не хватает <img width".n_f(($rubu-$user['ruby']))."";
header('Location: /profile/pay/10/');
exit;
}else{
mysql_query("UPDATE `users` SET `ruby` = '".text($user['ruby']-$rubu)."', `gold` = '".text($user['gold']+$repay)."' WHERE (`id` = '".$myID."')");
$_SESSION['msg'] = "Вы купили ".n_f($repay)." <img width='20' height='20' src='/img/money_36.png'/> за ".n_f($rubu)." <img width='20' height='20' src='/img/ruby.png'/>";
header('Location: /profile/pay/10/');
exit;
}
require_once ('system/footer.php');
exit;
}
$pay10 = n_f($money_sek_angel*86400);
echo '<div class="block">';
echo 'цена: '.$pay10.' х 1 = 10 <img src="/img/ruby.png" alt="$" width="24" height="24">';
echo '</div>';
echo '<form class="block" action="" method="POST"><input type="number" name="summ" value="1" /><input class="myButton" type="submit" name="submit" value="ok" />
</form>';
require_once 'system/footer.php';
exit;
}
if(isset($_GET['pay30'])){
require_once 'system/header.php';
if(isset($_POST['summ'])){
$id = text($_GET['summ']);
$pppay = text($_POST['summ']);
$rubu = text(30*$pppay);
$lpay = text(7*$pppay);
$repay = (($money_sek_angel*86400)*$lpay);
if($pppay < 1){
$_SESSION['msg'] = 'Минимальная покупка возможна только от 1 и больше';
header('Location: /profile/pay/30/');
exit;
}
if($pppay > 1000){
$_SESSION['msg'] = 'Максимальная покупка возможна только до 1000 и меньше';
header('Location: /profile/pay/30/');
exit;
}
if($user['ruby'] < $rubu){
$_SESSION['msg'] = "Не хватает ".n_f(($rubu-$user['ruby']))." <img width='20' height='20' src='/img/ruby.png'/>";
header('Location: /profile/pay/30/');
exit;
}else{
mysql_query("UPDATE `users` SET `ruby` = '".text($user['ruby']-$rubu)."', `gold` = '".text($user['gold']+$repay)."' WHERE (`id` = '".$myID."')");
$_SESSION['msg'] = "Вы купили ".n_f($repay)." <img width='20' height='20' src='/img/money_36.png'/> за ".n_f($rubu)." <img width='20' height='20' src='/img/ruby.png'/>";
header('Location: /profile/pay/30/');
exit;
}
require_once ('system/footer.php');
exit;
}
$pay30 = n_f(($money_sek_angel*86400)*7);
echo '<div class="block">';
echo 'цена: '.$pay30.' х 1 = 30 <img src="/img/ruby.png" alt="$" width="24" height="24">';
echo '</div>';
echo '<form class="block" action="" method="POST"><input type="number" name="summ" value="1" /><input class="myButton" type="submit" name="submit" value="ok" />
</form>';
require_once 'system/footer.php';
exit;
}
if(isset($_GET['pay90'])){
require_once 'system/header.php';
if(isset($_POST['summ'])){
$id = text($_GET['summ']);
$pppay = text($_POST['summ']);
$rubu = text(90*$pppay);
$lpay = text(49*$pppay);
$repay = (($money_sek_angel*86400)*$lpay);
if($pppay < 1){
$_SESSION['msg'] = 'Минимальная покупка возможна только от 1 и больше';
header('Location: /profile/pay/90/');
exit;
}
if($pppay > 1000){
$_SESSION['msg'] = 'Максимальная покупка возможна только до 1000 и меньше';
header('Location: /profile/pay/90/');
exit;
}
if($user['ruby'] < $rubu){
$_SESSION['msg'] = "Не хватает <img width='20' height='20' src='/img/ruby.png'/> ".n_f(($rubu-$user['ruby']))."";
header('Location: /profile/pay/90/');
exit;
}else{
mysql_query("UPDATE `users` SET `ruby` = '".text($user['ruby']-$rubu)."', `gold` = '".text($user['gold']+$repay)."' WHERE (`id` = '".$myID."')");
$_SESSION['msg'] = "Вы купили ".n_f($repay)." <img width='20' height='20' src='/img/money_36.png'/> за ".n_f($rubu)." <img width='20' height='20' src='/img/ruby.png'/>";
header('Location: /profile/pay/90/');
exit;
}
require_once ('system/footer.php');
exit;
}
$pay90 = n_f(($money_sek_angel*86400)*49);
echo '<div class="block">';
echo 'цена: '.$pay90.' х 1 = 90 <img src="/img/ruby.png" alt="$" width="24" height="24">';
echo '</div>';
echo '<form class="block" action="" method="POST"><input type="number" name="summ" value="1" /><input class="myButton" type="submit" name="submit" value="ok" />
</form>';
require_once 'system/footer.php';
exit;
}
if(isset($_GET['pay270'])){
require_once 'system/header.php';
if(isset($_POST['summ'])){
$id = text($_GET['summ']);
$pppay = text($_POST['summ']);
$rubu = text(270*$pppay);
$lpay = text(343*$pppay);
$repay = (($money_sek_angel*86400)*$lpay);
if($pppay < 1){
$_SESSION['msg'] = 'Минимальная покупка возможна только от 1 и больше';
header('Location: /profile/pay/270/');
exit;
}
if($pppay > 1000){
$_SESSION['msg'] = 'Максимальная покупка возможна только до 1000 и меньше';
header('Location: /profile/pay/270/');
exit;
}
if($user['ruby'] < $rubu){
$_SESSION['msg'] = "Не хватает ".n_f(($rubu-$user['ruby']))." <img width='20' height='20' src='/img/ruby.png'/>";
header('Location: /profile/pay/270/');
exit;
}else{
mysql_query("UPDATE `users` SET `ruby` = '".text($user['ruby']-$rubu)."', `gold` = '".text($user['gold']+$repay)."' WHERE (`id` = '".$myID."')");
$_SESSION['msg'] = "Вы купили ".n_f($repay)." <img width='20' height='20' src='/img/money_36.png'/> за ".n_f($rubu)." <img width='20' height='20' src='/img/ruby.png'/>";
header('Location: /profile/pay/270/');
exit;
}
require_once ('system/footer.php');
exit;
}
$pay270 = n_f(($money_sek_angel*86400)*343);
echo '<div class="block">';
echo 'цена: '.$pay270.' х 1 = 270 <img src="/img/ruby.png" alt="$" width="24" height="24">';
echo '</div>';
echo '<form class="block" action="" method="POST"><input type="number" name="summ" value="1" /><input class="myButton" type="submit" name="submit" value="ok" />
</form>';
require_once 'system/footer.php';
exit;
}
if(isset($_GET['pay810'])){
require_once 'system/header.php';
if(isset($_POST['summ'])){
$id = text($_GET['summ']);
$pppay = text($_POST['summ']);
$rubu = text(810*$pppay);
$lpay = text(2401*$pppay);
$repay = (($money_sek_angel*86400)*$lpay);
if($pppay < 1){
$_SESSION['msg'] = 'Минимальная покупка возможна только от 1 и больше';
header('Location: /profile.php?ppay');
exit;
}
if($pppay > 1000){
$_SESSION['msg'] = 'Максимальная покупка возможна только до 1000 и меньше';
header('Location: /profile/pay/810/');
exit;
}
if($user['ruby'] < $rubu){
$_SESSION['msg'] = "Не хватает ".n_f(($rubu-$user['ruby']))." <img width='20' height='20' src='/img/ruby.png'/>";
header('Location: /profile/pay/810/');
exit;
}else{
mysql_query("UPDATE `users` SET `ruby` = '".text($user['ruby']-$rubu)."', `gold` = '".text($user['gold']+$repay)."' WHERE (`id` = '".$myID."')");
$_SESSION['msg'] = "Вы купили ".n_f($repay)." <img width='20' height='20' src='/img/money_36.png'/> за ".n_f($rubu)." <img width='20' height='20' src='/img/ruby.png'/>";
header('Location: /profile/pay/810/');
exit;
}
require_once ('system/footer.php');
exit;
}
$pay810 = n_f(($money_sek_angel*86400)*2401);
echo '<div class="block">';
echo 'цена: '.$pay810.' х 1 = 810 <img src="/img/ruby.png" alt="$" width="24" height="24">';
echo '</div>';
echo '<form class="block" action="" method="POST"><input type="number" name="summ" value="1" /><input class="myButton" type="submit" name="submit" value="ok" />
</form>';
require_once 'system/footer.php';
exit;
}
if(isset($_GET['pay2430'])){
require_once 'system/header.php';
if(isset($_POST['summ'])){
$id = text($_GET['summ']);
$pppay = text($_POST['summ']);
$rubu = text(2430*$pppay);
$lpay = text(16807*$pppay);
$repay = (($money_sek_angel*86400)*$lpay);
if($pppay < 1){
$_SESSION['msg'] = 'Минимальная покупка возможна только от 1 и больше';
header('Location: /profile/pay/2430/');
exit;
}
if($pppay > 1000){
$_SESSION['msg'] = 'Максимальная покупка возможна только до 1000 и меньше';
header('Location: /profile/pay/2430/');
exit;
}
if($user['ruby'] < $rubu){
$_SESSION['msg'] = "Не хватает ".n_f(($rubu-$user['ruby']))." <img width='20' height='20' src='/img/ruby.png'/>";
header('Location: /profile/pay/2430/');
exit;
}else{
mysql_query("UPDATE `users` SET `ruby` = '".text($user['ruby']-$rubu)."', `gold` = '".text($user['gold']+$repay)."' WHERE (`id` = '".$myID."')");
$_SESSION['msg'] = "Вы купили ".n_f($repay)." <img width='20' height='20' src='/img/money_36.png'/> за ".n_f($rubu)." <img width='20' height='20' src='/img/ruby.png'/>";
header('Location: /profile/pay/2430/');
exit;
}
require_once ('system/footer.php');
exit;
}
$pay2430 = n_f(($money_sek_angel*86400)*16807);
echo '<div class="block">';
echo 'цена: '.$pay2430.' х 1 = 2430 <img src="/img/ruby.png" alt="$" width="24" height="24">';
echo '</div>';
echo '<form class="block" action="" method="POST"><input type="number" name="summ" value="1" /><input class="myButton" type="submit" name="submit" value="ok" />
</form>';
require_once 'system/footer.php';
exit;
}
$title = $profile['name'];
require_once 'system/header.php';
$pay_10 = n_f($money_sek_angel*86400);
$pay_30 = n_f(($money_sek_angel*86400)*7);
$pay_90 = n_f(($money_sek_angel*86400)*49);
$pay_270 = n_f(($money_sek_angel*86400)*343);
$pay_810 = n_f(($money_sek_angel*86400)*2401);
$pay_2430 = n_f(($money_sek_angel*86400)*16807);
echo'<div class="block"><center><a href="/profile/'.($profile['id']).'">';
echo icons_user($profile['id']).' '.$profile['login'].'</a>';
if($profile['access'] == 7){
echo '<font color="#FF0000"><small> [R] </small></font>';
}elseif($profile['access'] == 6){
echo '<font color="#FF0000"><small> [S] </small></font>';
}elseif($profile['access'] == 5){
echo '<font color="#FF4500"><small> [A] </small></font>';
}elseif($profile['access'] == 4){
echo '<font color="#20859e"><small> [M] </small></font>';
}elseif($profile['access'] == 3){
echo '<font color="#FF4500"><small> [a] </small></font>';
}elseif($profile['access'] == 2){
echo '<font color="#20859e"><small> [m] </small></font>';
}elseif($profile['access'] == 1){
echo '<font color="#000000"><small> [t] </small></font>';
}
if($profile['id'] == $myID) echo'<img src="/img/ruby.png" width="20px" alt="ruby" /> '.n_f($profile['ruby']).' ';
if($user['access'] >= 2 and $myID != $profile['id']) echo' <img src="/img/ruby.png" width="20px" alt="ruby" />'.n_f($profile['ruby']).' ';
echo '</center></div>';
$clan = mysql_fetch_array(mysql_query("SELECT * FROM `clans` WHERE `id` = '".$profile['id_clan']."' LIMIT 1"));
switch($profile['clan_rang']){
case 1:
$clan_rang = 'стажер';
break;
case 2:
$clan_rang = 'директор';
break;
case 3:
$clan_rang = 'акционер';
break;
case 4:
$clan_rang = 'заместитель';
break;
case 5:
$clan_rang = "<font color='green'>Владелец</font>";
break;
}
echo '<div class="block">';
echo '<div id="avatar"></div>';
echo '<div id="contentss">';
echo '<div style="position:relative;"></div>
';
echo '<div class="wrap">';
echo '<link rel="stylesheet" id="nexus-fonts-css" href="https://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,700italic,800italic,400,300,700,800|Raleway:400,200,100,500,700,800,900&subset=latin,latin-ext" type="text/css" media="all">';
echo '<div class="avafon" style="height: 200px; background-image: url(/img/fon/'.$profile['fon'].');">';
echo '<style="max-width:200px; max-height:200px;">';
if($profile['id'] == $myID)echo'<a href="/avatar.php?new">';
if($profile['ava'] == NULL){
echo '<img class="photo transition-scale" src="/img/avatar/0.png" alt="No Awatars" style="max-width:200px; max-height:200px;" ></a> ';
}else{
echo '<img class="photo transition-scale" src="/img/avatar/'.$profile['ava'].'" alt="$" style="max-width:200px; max-height:200px;" ></a> ';
}
echo'</div></div>';
if($profile['id'] == $myID) echo'<small><p align="right"><a href="/fon.php?new">изменить фон</a></p></small>';
echo '</div>';
echo '<span id="top_v"></span>';
echo '<div class="status">'.text_msg($profile['status']).'<small class="private_info" id="right">'; if($profile['id'] == $myID) echo'<a href="/status.php?new">Сменить?</a>';
echo'</small></div></div></b></font>';
if($user['access'] >= 3){
echo '<div class="block">';
echo '<center><a href="?block_fon">Delete Fon</a> |';
echo ' <a href="?block_status">Delete status</a> |';
echo ' <a href="?block_ava">Delete avatar</a></center></div>';
}
echo '</div>';
echo '<div class="block">';
echo'<div class="save1">';
if($profile['access'] == 7){
echo "Роль в игре: <font color='#FF0000'>Разработчик</font>";
}elseif($profile['access'] == 6){
echo "Роль в игре: <font color='#FF0000'>Sys.Bot</font>";
}elseif($profile['access'] == 5){
echo "Роль в игре: <font color='#FF4500'>г.Администратор</font>";
}elseif($profile['access'] == 4){
echo "Роль в игре: <font color='#20859E'>г.Модератор</font>";
}elseif($profile['access'] == 3){
echo "Роль в игре: <font color='#FF4500'>м.Администратор</font>";
}elseif($profile['access'] == 2){
echo "Роль в игре: <font color='#20859E'>м.Модератор</font>";
}elseif($profile['access'] == 1){
echo "Роль в игре: <font color='#000000'>Тестер</font>";
}
$narush = mysql_result(mysql_query("SELECT COUNT(*) FROM `ban` WHERE `id_user` = '".$profile['id']."'"),0);
if($profile['id'] != $myID) echo '<li><a href="/narush/'.$profile['id'].'/"> Нарушения ('.$narush.') </li></a>';
$money_updater_ank = mysql_fetch_array(mysql_query("SELECT SUM(money_sek) FROM room_users WHERE id_user = '".$profile['id']."'"));
$cu = mysql_fetch_assoc(mysql_query("SELECT * FROM `clans` WHERE `id` = '".$profile['id_clan']."'"));
$ac11 = mysql_fetch_array(mysql_query("SELECT SUM(angels) FROM `users` WHERE `id_clan` = '".$profile['id_clan']."'"));
if($profile['id_clan'] >= 1 and $ac11[0] >= 100){
$kol = ($ac11[0]/100);
$u = text($kol*$profile['x2']*$profile['g_x2']);
}else{
if($profile['angels'] < 100){
$u = text($profile['x2']*$profile['g_x2']);
}else{
$koll = text($profile['angels']/100);
$u = text($koll*$profile['x2']*$profile['g_x2']);
}
}
$pcc = ($money_updater_ank[0]*$u);
$pcms = (($pcc*$cst)/100);
echo '<center>
Доход: '.n_f(($money_updater_ank[0]*$u)+$pcms).'<img src="/img/money_36.png" alt="$" width="16" height="16"> в сек
<br>Бизнес-ангелы: '.n_f($profile['angels']).'<img src="/img/angel48.png" alt="$" width="16" height="16"><br/>';
echo 'Последний сброс: '.(tl(time()-$profile['tangels'])).'<img src="/img/clock.png" alt="$" width="16" height="16"><br/>';
if($profile['online'] > time()-300){
echo 'был(а) в <font color="green">Online</font>: '.(time_last($profile['online'])).'<img src="/img/clock.png" alt="$" width="16" height="16">';
}else{
echo 'был(а) в <font color="red">Online</font>: '.(time_last($profile['online'])).'<img src="/img/clock.png" alt="$" width="16" height="16">';
}
echo '<br>Начал игру: '.time_last($profile['registr']).'<img src="/img/clock.png" alt="$" width="16" height="16"> <small>(ID: '.($profile['id']).')</small></center>';
## Гражданство
switch($profile['g_id']){
case 1:
$g_name = 'Прописку';
break;
case 2:
$g_name = 'Вид на жительство';
break;
case 3:
$g_name = 'Гражданство';
break;
}
if($profile['id'] == $myID){
if($user['g_id'] < 4 && $user['g_id'] == $user['g_id']){
if($user['ruby'] > $user['g_cena']){
echo'<div class="center">
<a href="?okgr" class="btnl mt4"> <span>Оформить '.$g_name.' за <img src="/img/ruby.png" alt="$" width="16" height="16"/>'.n_f($user['g_cena']).'</span> </a>
</div>';
}else{
echo'<div class="center">
<span class="btnl mt4"> <span>Оформить '.$g_name.' за <img src="/img/ruby.png" alt="$" width="16" height="16"/>'.n_f($user['g_cena']).'</span> </span>
</div>';
}
}else{
}
}else{
}
if($profile['g_id'] == 4){
echo'<div class="center">';
echo'<span><img src="/img/citizenship_64x64.png" alt="$" width="24" height="24"/>Гражданин Рейба</span>';
echo'</div>';
}
echo'</div></div>';
if(isset($user)){
echo '<div class="block">';
if($profile['id'] != $myID) echo'<a class="btnl mt4" href="/mail/'.$profile['id'].'" class="btn"><img src="/img/mail_white.png" alt="*" width="20" height="20"/> Написать сообщение</a>';
if($profile['id'] != $myID) echo'<a class="btnl mt4" href="/gifts/'.$id.'?do" class="btn"><img width="20" height="20" alt="" src="/img/podarok.png" title=""/> Подарить подарок '.$profile['name'].'</a>';
if($profile['id'] != $myID) echo'<a class="btnl mt4" href="/freinds/'.$id.'?add" class="btn"><img width="20" height="20" alt="" src="/img/friends.png" title=""/> Пригласить в друзья '.$profile['name'].'</a>';
echo '</div>';
}
$angels = text(ceil(100*sqrt(($money_sek_angel*$tat)/1000000000)));
echo '<div class="block">';
if($profile['fsbros'] == 1){
if($profile['id'] == $myID and $money_sek_angel > 100 and $angels > 10)
echo'<a class="btnl mt4" href="/profile/?angl">Сброс <b>x1</b> '.n_f($angels).' <img src="/img/angel48.png" alt="$" width="24" height="24"> за 0 <img src="/img/ruby.png" alt="$" width="24" height="24"></a>';
}
if($profile['id'] == $myID and $money_sek_angel > 100 and $angels > 10)
echo'<a class="btnl mt4" href="/profile/?angl_ruby">Сброс <b>x1</b> '.n_f($angels).'<img src="/img/angel48.png" alt="$" width="24" height="24"> за 250 <img src="/img/ruby.png" alt="$" width="24" height="24"></a>
';
if($profile['id'] == $myID and $money_sek_angel > 300 and $angels > 100)
echo'<a class="btnl mt4" href="/profile/?angl3">Сброс <b>х2</b> '.n_f(($angels)*2).'<img src="/img/angel48.png" alt="$" width="24" height="24"> за 10к <img src="/img/ruby.png" alt="$" width="24" height="24"></a>
';
if($profile['id'] == $myID and $money_sek_angel > 900 and $angels > 1000)
echo'<a class="btnl mt4" href="/profile/?angl4">Сброс <b>х4</b> '.n_f(($angels)*4).'<img src="/img/angel48.png" alt="$" width="24" height="24"> за 50к <img src="/img/ruby.png" alt="$" width="24" height="24"></a>';
if($profile['id'] == $myID)echo'<a class="btnl mt4" href="/payment/" class="btn"> Купить <img src="/img/ruby.png" alt="$" width="24" height="24"></a>';
echo '</div>';
if($profile['id'] == $myID){
echo'<div class="center">';
echo'<a class="btni" style="min-width:135px;margin:4px;" href="/profile/pay/10/">купить '.$pay_10.' <img src="/img/money_36.png" alt="$" width="16" height="16"/></a>';
echo'<a class="btni" style="min-width:135px;margin:4px;" href="/profile/pay/30/">купить '.$pay_30.' <img src="/img/money_36.png" alt="$" width="16" height="16"/></a>';
echo'<a class="btni" style="min-width:135px;margin:4px;" href="/profile/pay/90/">купить '.$pay_90.' <img src="/img/money_36.png" alt="$" width="16" height="16"/></a>';
echo'<a class="btni" style="min-width:135px;margin:4px;" href="/profile/pay/270/">купить '.$pay_270.' <img src="/img/money_36.png" alt="$" width="16" height="16"/></a>';
echo'<a class="btni" style="min-width:135px;margin:4px;" href="/profile/pay/810/">купить '.$pay_810.' <img src="/img/money_36.png" alt="$" width="16" height="16"/></a>';
echo'<a class="btni" style="min-width:135px;margin:4px;" href="/profile/pay/2430/">купить '.$pay_2430.' <img src="/img/money_36.png" alt="$" width="16" height="16"/></a>';
echo '</div>';
}else{
}
## Двойной доход
if($profile['id'] == $myID){
if($user['dubl'] < 70){
if($user['angels'] > $user['gold_dubl']*2){
echo'<div class="center">
<a href="?okdx2" marsgame_rewrite_money="'.n_f($user['gold_dubl']).'" class="btnl mt4"> <span>x2 <img src="/img/angel48.png" alt="$" width="20" height="20"/> '.n_f($user['gold_dubl']).'</span> </a>
</div>';
}else{
echo'<div class="center">
<span class="btnl mt4"> <span>x2 <img src="/img/angel48.png" alt="$" width="20" height="20"/> '.n_f($user['gold_dubl']).'</span> </span>
</div>';
}
}else{
echo'<div class="center">';
echo'<a class="subl" style="display: inline-block;min-width: 220px;">';
echo'<span>В разработке</span>';
echo'</a>';
echo'</div>';
echo'<div class="cb"></div>';
}
}else{
}
if($profile['id'] != $myID)echo'<a class="btnl mt4" href="/gifts/'.$id.'?g" class="btn"><img width="20" height="20" alt="" src="/img/podarok.png" title=""/> Подарки игрока: '.$profile['name'].'</a>';
if($profile['id'] == $myID)echo'<a class="btnl mt4" href="/gifts/?my" class="btn"><img width="20" height="20" alt="" src="/img/podarok.png" title=""/> Мои подарки</a>';
if($profile['id'] == $myID)echo'<a class="btnl mt4" href="/freinds/?my" class="btn"><img width="20" height="20" alt="" src="/img/friends.png" title=""/> Мои друзья</a>';
if($profile['id'] == $myID)echo'<a class="btnl mt4" href="/ref.php" class="btn"><img width="20" height="20" alt="" src="/img/ref.png" title=""/> Мои реф.пользователи</a>';
if($profile['id'] != $myID)echo'<a class="btnl mt4" href="/transfer.php?id='.$id.'" class="btn"><img width="20" height="20" alt="" src="/img/ruby.png" title=""/> Передать рубины</a>';
echo'</div>';
if($clan){
echo'<a class="btnl mt4" href="/corp/'.$clan['id'].'/"><img src="/img/corp2.png" width="24" height="24" alt="" /> Корпорация ['.$clan['name'].']</a>';
}
$clan_col = mysql_result(mysql_query("SELECT COUNT(*) FROM `users` WHERE `id_clan` = '".$clan['id']."'"),0);
$clan = mysql_fetch_assoc(mysql_query("SELECT * FROM `clans` WHERE `id` = '".$user['id_clan']."'"));
$kol_user = mysql_result(mysql_query("SELECT COUNT(*) FROM `users` WHERE `id_clan` = '".$user['id_clan']."'"),0);
if($myID != $profile['id'] and $user['clan_rang'] > 2 and $profile['id_clan'] == 0 and $clan['max'] > $kol_user and mysql_result(mysql_query("SELECT COUNT(*) FROM `clan_memb` WHERE `id_user` = '$id' AND `id_clan` = '".$user['id_clan']."'"),0) == 0){
echo "<li><a class='btnl mt4' href='?clan_memb' class='btn'>Пригласить в корпорацию</li></a>";}
if($user['access'] >= 2 and $myID != $profile['id']){
if(isset($_GET['blockid'])){
$title = 'Подтверждение х2 дохода?';
require_once 'system/header.php';
echo '<div class="block">';
echo '<div class="feedback">';
echo '<center>Вы точно хотите заблокировать данного персонажа '.$profile['login'].'? И тем самым очистить все последние действия?<br>';
echo '<a href="/profile/'.$profile['id'].'?block" class="myButton"> Да </a>';
echo ' | ';
echo '<a href="/profile/'.$profile['id'].'" class="myButton"> Нет </a>';
echo '</center></div></div>';
require_once 'system/footer.php';
exit;
}
if($myID != $profile['id']) echo "<li><a class='btnl mt4' href='/ban/".$profile['id']."/' class='btn'><font color='black'><b>Блокировка Игрока</b></font></a></li>";
if($myID != $profile['id']) echo "<li><a class='btnl mt4' href='?blockid' class='btn'><font color='black'><b>Момент. Бан, Спам(Вечный)</b></font></a></li>";
if($myID != $profile['id'])echo "<div class='feedback'><li>IP-адрес: <span class='title'>".$profile['ip']."</span></li></div>";
if($myID != $profile['id'])echo "<div class='feedback'><li>Железо: <span class='title'>".$profile['browser']."</span></li></div>";
}
if($profile['id'] == $myID) echo'<a class="btnl mt4" href="/narush/'.$profile['id'].'/" class="btn"> Нарушения ('.$narush.')</a>';
if($profile['id'] == $myID) echo'<a class="btnl mt4" href="/settings" class="btn"><span><img src="/img/accept.png" alt="$" width="16" height="16"/> <span> Настройки</a>';
if($profile['id'] == $myID) echo'<a class="btnl mt4" href="/ref_top.php" class="btn"><span><img src="/img/1.png" alt="$" width="16" height="16"/> <span> Рейтинг Рефералов</a>';
if($profile['id'] == $myID) echo'<a class="btnl mt4" href="/settings?exit" class="btn"><img width="20" height="20" alt="" src="/img/cross.png" title=""/> Выход из игры</a>';
if($profile['access'] >= 1){
if($profile['id'] == $myID) echo'<a class="btnl mt4" href="/panel/" class="btn"> Панель Управления </a>';
}
require_once ('system/footer.php');
?>