Вход Регистрация
Файл: vkolhoze.com/inc/collections.php
Строк: 831
<?

require_header 
('Коллекции');
if(
$ank['level']<15)
{

  echo 
"<div class='block'>Игрок ".on_k($ank['id'])." <a class='' href='/user/$ank[id]'> ".$ank['nick']."</a> ещё не имеет доступа к коллекциям.. </div>";
}

$collections=mysql_fetch_array(mysql_query("SELECT * FROM `kolhoz_collections` WHERE `id_user` = '$ank[id]'"));
if(
$ank['level']>15)
{
echo 
"<div class='event'><title>Коллекции </title></div>";

$all_1 =  $collections['butterfly1'] + $collections['butterfly2'] + $collections['butterfly3'] + $collections['butterfly4'] + $collections['butterfly5'] + $collections['butterfly6'] + $collections['butterfly7'] + $collections['butterfly8'] + $collections['butterfly9'] + $collections['butterfly10'];
echo 
'<li class="block2"><span>Бабочки '.$all_1.'/10</span><div>';
echo 
"<span><img width='48' height='48' src='/images/collections/butterfly/".($collections['butterfly1']==0?"no_butterfly1.jpg":"butterfly1.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/butterfly/".($collections['butterfly2']==0?"no_butterfly2.jpg":"butterfly2.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/butterfly/".($collections['butterfly3']==0?"no_butterfly3.jpg":"butterfly3.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/butterfly/".($collections['butterfly4']==0?"no_butterfly3.jpg":"butterfly4.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/butterfly/".($collections['butterfly5']==0?"no_butterfly5.jpg":"butterfly5.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/butterfly/".($collections['butterfly6']==0?"no_butterfly6.jpg":"butterfly6.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/butterfly/".($collections['butterfly7']==0?"no_butterfly7.jpg":"butterfly7.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/butterfly/".($collections['butterfly8']==0?"no_butterfly8.jpg":"butterfly8.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/butterfly/".($collections['butterfly9']==0?"no_butterfly9.jpg":"butterfly9.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/butterfly/".($collections['butterfly10']==0?"no_butterfly10.jpg":"butterfly10.jpg")."'></span>";
echo 
'</div></li>';

$all_2 =  $collections['coin1'] + $collections['coin2'] + $collections['coin3'] + $collections['coin4'] + $collections['coin5'] + $collections['coin6'] + $collections['coin7'] + $collections['coin8'] + $collections['coin9'] + $collections['coin10'];
echo 
'<li class="block2"><span>Монетки '.$all_2.'/10</span><div>';
echo 
"<span><img width='48' height='48' src='/images/collections/coins/".($collections['coin1']==0?"no_coin1.jpg":"coin1.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/coins/".($collections['coin2']==0?"no_coin2.jpg":"coin2.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/coins/".($collections['coin3']==0?"no_coin3.jpg":"coin3.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/coins/".($collections['coin4']==0?"no_coin4.jpg":"coin4.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/coins/".($collections['coin5']==0?"no_coin5.jpg":"coin5.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/coins/".($collections['coin6']==0?"no_coin6.jpg":"coin6.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/coins/".($collections['coin7']==0?"no_coin7.jpg":"coin7.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/coins/".($collections['coin8']==0?"no_coin8.jpg":"coin8.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/coins/".($collections['coin9']==0?"no_coin9.jpg":"coin9.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/coins/".($collections['coin10']==0?"no_coin10.jpg":"coin10.jpg")."'></span>";
echo 
'</div></li>';

$all_3 =  $collections['herbal1'] + $collections['herbal2'] + $collections['herbal3'] + $collections['herbal4'] + $collections['herbal5'] + $collections['herbal6'] + $collections['herbal7'] + $collections['herbal8'] + $collections['herbal9'] + $collections['herbal10'];
echo 
'<li class="block2"><span>Гербарий '.$all_3.'/10</span><div><span>';
echo 
"<span><img width='48' height='48' src='/images/collections/herbals/".($collections['herbal1']==0?"no_herbal1.jpg":"herbal1.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/herbals/".($collections['herbal2']==0?"no_herbal2.jpg":"herbal2.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/herbals/".($collections['herbal3']==0?"no_herbal3.jpg":"herbal3.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/herbals/".($collections['herbal4']==0?"no_herbal4.jpg":"herbal4.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/herbals/".($collections['herbal5']==0?"no_herbal5.jpg":"herbal5.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/herbals/".($collections['herbal6']==0?"no_herbal6.jpg":"herbal6.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/herbals/".($collections['herbal7']==0?"no_herbal7.jpg":"herbal7.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/herbals/".($collections['herbal8']==0?"no_herbal8.jpg":"herbal8.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/herbals/".($collections['herbal9']==0?"no_herbal9.jpg":"herbal9.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/herbals/".($collections['herbal10']==0?"no_herbal10.jpg":"herbal10.jpg")."'></span>";
echo 
'</div></li>';



$all_4 =  $collections['wrapper1'] + $collections['wrapper2'] + $collections['wrapper3'] + $collections['wrapper4'] + $collections['wrapper5'] + $collections['wrapper6'] + $collections['wrapper7'] + $collections['wrapper8'] + $collections['wrapper9'] + $collections['wrapper10'];
echo 
'<li class="block2"><span>Фантики '.$all_4.'/10</span><div><span>';
echo 
"<span><img width='48' height='48' src='/images/collections/wrappers/".($collections['wrapper1']==0?"no_wrapper1.jpg":"wrapper1.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/wrappers/".($collections['wrapper2']==0?"no_wrapper2.jpg":"wrapper2.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/wrappers/".($collections['wrapper3']==0?"no_wrapper3.jpg":"wrapper3.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/wrappers/".($collections['wrapper4']==0?"no_wrapper4.jpg":"wrapper4.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/wrappers/".($collections['wrapper5']==0?"no_wrapper5.jpg":"wrapper5.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/wrappers/".($collections['wrapper6']==0?"no_wrapper6.jpg":"wrapper6.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/wrappers/".($collections['wrapper7']==0?"no_wrapper7.jpg":"wrapper7.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/wrappers/".($collections['wrapper8']==0?"no_wrapper8.jpg":"wrapper8.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/wrappers/".($collections['wrapper9']==0?"no_wrapper9.jpg":"wrapper9.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/wrappers/".($collections['wrapper10']==0?"no_wrapper10.jpg":"wrapper10.jpg")."'></span>";
echo 
'</span></div></li>';


$all_5 =  $collections['car1'] + $collections['car2'] + $collections['car3'] + $collections['car4'] + $collections['car5'] + $collections['car6'] + $collections['car7'] + $collections['car8'] + $collections['car9'] + $collections['car10'];
echo 
'<li class="block2"><span>Машинки '.$all_5.'/10</span><div><span>';
echo 
"<span><img width='48' height='48' src='/images/collections/cars/".($collections['car1']==0?"no_car1.jpg":"car1.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/cars/".($collections['car2']==0?"no_car2.jpg":"car2.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/cars/".($collections['car3']==0?"no_car3.jpg":"car3.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/cars/".($collections['car4']==0?"no_car4.jpg":"car4.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/cars/".($collections['car5']==0?"no_car5.jpg":"car5.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/cars/".($collections['car6']==0?"no_car6.jpg":"car6.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/cars/".($collections['car7']==0?"no_car7.jpg":"car7.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/cars/".($collections['car8']==0?"no_car8.jpg":"car8.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/cars/".($collections['car9']==0?"no_car9.jpg":"car9.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/cars/".($collections['car10']==0?"no_car10.jpg":"car10.jpg")."'></span>";
echo 
'</span></div></li>';

$all_6 =  $collections['necke1'] + $collections['necke2'] + $collections['necke3'] + $collections['necke4'] + $collections['necke5'] + $collections['necke6'] + $collections['necke7'] + $collections['necke8'] + $collections['necke9'] + $collections['necke10'];
echo 
'<li class="block2"><span>Нэцкэ '.$all_6.'/10</span><div><span>';
echo 
"<span><img width='48' height='48' src='/images/collections/necke/".($collections['necke1']==0?"no_necke1.jpg":"necke1.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/necke/".($collections['necke2']==0?"no_necke2.jpg":"necke2.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/necke/".($collections['necke3']==0?"no_necke3.jpg":"necke3.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/necke/".($collections['necke4']==0?"no_necke4.jpg":"necke4.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/necke/".($collections['necke5']==0?"no_necke5.jpg":"necke5.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/necke/".($collections['necke6']==0?"no_necke6.jpg":"necke6.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/necke/".($collections['necke7']==0?"no_necke7.jpg":"necke7.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/necke/".($collections['necke8']==0?"no_necke8.jpg":"necke8.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/necke/".($collections['necke9']==0?"no_necke9.jpg":"necke9.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/necke/".($collections['necke10']==0?"no_necke10.jpg":"necke10.jpg")."'></span>";
echo 
'</span></div></li>';

$all_7 =  $collections['fan1'] + $collections['fan2'] + $collections['fan3'] + $collections['fan4'] + $collections['fan5'] + $collections['fan6'] + $collections['fan7'] + $collections['fan8'] + $collections['fan9'] + $collections['fan10'];
echo 
'<li class="block2"><span>Веера '.$all_7.'/10</span><div><span>';
echo 
"<span><img width='48' height='48' src='/images/collections/fans/".($collections['fan1']==0?"no_fan1.jpg":"fan1.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/fans/".($collections['fan2']==0?"no_fan2.jpg":"fan2.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/fans/".($collections['fan3']==0?"no_fan3.jpg":"fan3.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/fans/".($collections['fan4']==0?"no_fan4.jpg":"fan4.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/fans/".($collections['fan5']==0?"no_fan5.jpg":"fan5.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/fans/".($collections['fan6']==0?"no_fan6.jpg":"fan6.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/fans/".($collections['fan7']==0?"no_fan7.jpg":"fan7.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/fans/".($collections['fan8']==0?"no_fan8.jpg":"fan8.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/fans/".($collections['fan9']==0?"no_fan9.jpg":"fan9.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/fans/".($collections['fan10']==0?"no_fan10.jpg":"fan10.jpg")."'></span>";
echo 
'</span></div></li>';

$all_8 =  $collections['stamp1'] + $collections['stamp2'] + $collections['stamp3'] + $collections['stamp4'] + $collections['stamp5'] + $collections['stamp6'] + $collections['stamp7'] + $collections['stamp8'] + $collections['stamp9'] + $collections['stamp10'];
echo 
'<li class="block2"><span>Марки '.$all_8.'/10</span><div><span>';
echo 
"<span><img width='48' height='48' src='/images/collections/stamp/".($collections['stamp1']==0?"no_stamp1.jpg":"stamp1.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/stamp/".($collections['stamp2']==0?"no_stamp2.jpg":"stamp2.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/stamp/".($collections['stamp3']==0?"no_stamp3.jpg":"stamp3.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/stamp/".($collections['stamp4']==0?"no_stamp4.jpg":"stamp4.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/stamp/".($collections['stamp5']==0?"no_stamp5.jpg":"stamp5.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/stamp/".($collections['stamp6']==0?"no_stamp6.jpg":"stamp6.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/stamp/".($collections['stamp7']==0?"no_stamp7.jpg":"stamp7.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/stamp/".($collections['stamp8']==0?"no_stamp8.jpg":"stamp8.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/stamp/".($collections['stamp9']==0?"no_stamp9.jpg":"stamp9.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/stamp/".($collections['stamp10']==0?"no_stamp10.jpg":"stamp10.jpg")."'></span>";
echo 
'</span></div></li>';

$all_9 =  $collections['perfume1'] + $collections['perfume2'] + $collections['perfume3'] + $collections['perfume4'] + $collections['perfume5'] + $collections['perfume6'] + $collections['perfume7'] + $collections['perfume8'] + $collections['perfume9'] + $collections['perfume10'];
echo 
'<li class="block2"><span>Духи '.$all_9.'/10</span><div><span>';
echo 
"<span><img width='48' height='48' src='/images/collections/perfume/".($collections['perfume1']==0?"no_perfume1.jpg":"perfume1.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/perfume/".($collections['perfume2']==0?"no_perfume2.jpg":"perfume2.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/perfume/".($collections['perfume3']==0?"no_perfume3.jpg":"perfume3.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/perfume/".($collections['perfume4']==0?"no_perfume4.jpg":"perfume4.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/perfume/".($collections['perfume5']==0?"no_perfume5.jpg":"perfume5.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/perfume/".($collections['perfume6']==0?"no_perfume6.jpg":"perfume6.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/perfume/".($collections['perfume7']==0?"no_perfume7.jpg":"perfume7.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/perfume/".($collections['perfume8']==0?"no_perfume8.jpg":"perfume8.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/perfume/".($collections['perfume9']==0?"no_perfume9.jpg":"perfume9.jpg")."'></span>";
echo 
"<span><img width='48' height='48' src='/images/collections/perfume/".($collections['perfume10']==0?"no_perfume10.jpg":"perfume10.jpg")."'></span>";
echo 
'</span></div></li>';

$all $all_1 $all_2 $all_3 $all_4 $all_5 $all_6 $all_7 $all_8 $all_9;
$bon $all 2;

if(
$collections['chanse']<=5)$plus=5;
elseif(
$collections['chanse']>=and $collections['chanse']<=10)$plus=5;
elseif(
$collections['chanse']>=11 and $collections['chanse']<=15)$plus=10;
elseif(
$collections['chanse']>=16 and $collections['chanse']<=20)$plus=15;
elseif(
$collections['chanse']>=21 and $collections['chanse']<=25)$plus=20;
elseif(
$collections['chanse']>=26 and $collections['chanse']<=30)$plus=25;
elseif(
$collections['chanse']>=31 and $collections['chanse']<=35)$plus=30;
elseif(
$collections['chanse']>=36 and $collections['chanse']<=40)$plus=35;
elseif(
$collections['chanse']>=41 and $collections['chanse']<=45)$plus=40;

if(
$collections['chanse']<60)
{
if(
$ank['id'] == $ku['id']){

if(isset(
$_GET['chanse']))
{
if(
$ku['chanse']<=480){
$cena $collections['chanse']*10+10*$plus;
if(
$ku['rubies'] < $cena){
no_rubies($cena $plus $ku['rubies']);
} else {
$cena $collections['chanse']*10+10*$plus;
mysql_query("UPDATE `kolhoz_collections` SET `chanse` = '".($collections['chanse']+1)."'  WHERE `id_user` = '$ku[id]'");
mysql_query("UPDATE `kolhoz_user` SET `rubies` = '".($ku['rubies']-$cena)."' WHERE `id` = '$ku[id]'");

header("Location:/?collections=$ank[id]");
}
}
}
}
}

echo 
'<div class="block">';
echo 
'<div>Личные коллекции дают +<span>'.$bon,'</span>% опыта.</div>';
echo 
'<div>Шанс найти коллекционную вещь <span><span>'.($collections['chanse']*0.5 10).'</span>%</span></div><br>';
if(
$ank['id'] == $ku['id']){
if(
$collections['chanse']<60)echo '<a class="loc" href="/?collections='.$ank['id'].'&chanse">Увеличить шанс до <span>'.($collections['chanse']*0.5 10.5).'</span>% за <span><span class="nobr"><img width="16" height="16" src="/images/icons/ruby.png" alt="o"/> <span class="title">'.($collections['chanse']*10 10 $plus).'</a></span></span></span></div>';
}
}
include_once 
'inc/foot.php';
?>
Онлайн: 0
Реклама