<?php
#Made By: ENK
#URL: http://wap-mast.su
#ICQ: net
#Mail: dcms7@spaces.ru
#Скрипт запрещено продавать, раздавать, менять, выкладывать, переписывать!
#Все права на скрипт принадлежат мне!
#Приду и снесу сайт
include_once '../../sys/inc/start.php';
include_once '../../sys/inc/compress.php';
include_once '../../sys/inc/sess.php';
include_once '../../sys/inc/home.php';
include_once '../../sys/inc/settings.php';
include_once '../../sys/inc/db_connect.php';
include_once '../../sys/inc/ipua.php';
include_once '../../sys/inc/fnc.php';
include_once '../../sys/inc/user.php';
$set['title']='Охота';
include_once '../../sys/inc/thead.php';
title();
aut();

if(!isset($user)){
header("Location:/aut.php");
break;
}
$arr=mysql_fetch_array(mysql_query("SELECT * FROM `oxota` WHERE `ids`='$user[id]'"));

$ss=rand(1,9);
################################################################################
$flood = mysql_fetch_assoc(mysql_query("SELECT `time` FROM `oxota` WHERE `ids` = '".$user['id']."' order by `time` desc limit 1"));
if($flood['time']<(time()-10))
{


if($arr['patron']<=0){
echo "У вас закончились патроны!";
}else{
// Это вывод зверей с 1 локации....
if ($arr['lok']==1)
{
if ($ss==1) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_a`=`zver_a`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/1r/1.png' alt='kaktuz'/><br /><br /></td></table></center>";
}

if ($ss==2) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_b`=`zver_b`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/1r/2.png' alt='Кот'/><br /><br /></td></table></center>";
}

if ($ss==3) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_c`=`zver_c`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/1r/3.png' alt='Обезъяна'/><br /><br /></td></table></center>";
}

if ($ss==4) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_d`=`zver_d`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/1r/4.png' alt='Бегемот'/><br /><br /></td></table></center>";
}

if ($ss==5) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_e`=`zver_e`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/1r/5.png' alt='------'/><br /><br /></td></table></center>";
}

if ($ss==6) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_f`=`zver_f`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/1r/6.png' alt='Морт'/><br /><br /></td></table></center>";
}

if ($ss==7) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_h`=`zver_h`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/1r/7.png' alt='Морт'/><br /><br /></td></table></center>";
}

if ($ss==8) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_i`=`zver_i`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/1r/8.png' alt='Морт'/><br /><br /></td></table></center>";
}

if ($ss==9) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_j`=`zver_j`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/1r/9.png' alt='Морт'/><br /><br /></td></table></center>";
}
echo '<form action="?" method="POST"><input type="submit" name="" value="Стрелять" /></form>';
}


// Это вывод зверей с 2 локации....
if ($arr['lok']==2)
{
if ($ss==1) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_a`=`zver_a`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/2r/1.png' alt='kaktuz'/><br /><br /></td></table></center>";
}

if ($ss==2) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_b`=`zver_b`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/2r/2.png' alt='Кот'/><br /><br /></td></table></center>";
}

if ($ss==3) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_c`=`zver_c`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/2r/3.png' alt='Обезъяна'/><br /><br /></td></table></center>";
}

if ($ss==4) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_d`=`zver_d`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/2r/4.png' alt='Бегемот'/><br /><br /></td></table></center>";
}

if ($ss==5) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_e`=`zver_e`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/2r/5.png' alt='------'/><br /><br /></td></table></center>";
}

if ($ss==6) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_f`=`zver_f`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/2r/6.png' alt='Морт'/><br /><br /></td></table></center>";
}

if ($ss==7) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_h`=`zver_h`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/2r/7.png' alt='Морт'/><br /><br /></td></table></center>";
}

if ($ss==8) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_i`=`zver_i`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/2r/8.png' alt='Морт'/><br /><br /></td></table></center>";
}

if ($ss==9) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_j`=`zver_j`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/2r/9.png' alt='Морт'/><br /><br /></td></table></center>";
}

echo '<form action="?" method="POST"><input type="submit" name="" value="Стрелять" /></form>';
}



// Это вывод зверей с 3 локации....
if ($arr['lok']==3)
{
if ($ss==1) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_a`=`zver_a`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/3r/1.png' alt='kaktuz'/><br /><br /></td></table></center>";
}

if ($ss==2) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_b`=`zver_b`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/3r/2.png' alt='Кот'/><br /><br /></td></table></center>";
}

if ($ss==3) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_c`=`zver_c`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/3r/3.png' alt='Обезъяна'/><br /><br /></td></table></center>";
}

if ($ss==4) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_d`=`zver_d`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/3r/4.png' alt='Бегемот'/><br /><br /></td></table></center>";
}

if ($ss==5) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_e`=`zver_e`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/3r/5.png' alt='------'/><br /><br /></td></table></center>";
}

if ($ss==6) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_f`=`zver_f`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/3r/6.png' alt='Морт'/><br /><br /></td></table></center>";
}

if ($ss==7) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_h`=`zver_h`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/3r/7.png' alt='Морт'/><br /><br /></td></table></center>";
}

if ($ss==8) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_i`=`zver_i`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/3r/8.png' alt='Морт'/><br /><br /></td></table></center>";
}

if ($ss==9) {
mysql_query("UPDATE `oxota` SET `time` = '".time()."' WHERE `ids` = '$user[id]' LIMIT 1");
mysql_query("UPDATE `oxota` SET `zvereu_ubito`=`zvereu_ubito`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `zver_j`=`zver_j`+'1' WHERE `ids`='".$user['id']."'");
mysql_query("UPDATE `oxota` SET `patron`=`patron`-'1' WHERE `ids`='".$user['id']."'");
echo '<center><table width="162" height="162" style="color: white; background-image: url(zver/kroog.png);" border="0">';
echo "<td valign='bottom'><img src='zver/3r/9.png' alt='Морт'/><br /><br /></td></table></center>";
}
echo '<form action="?" method="POST"><input type="submit" name="" value="Стрелять" /></form>';
}
}
}else{echo '<div class="err">Часто стреляешь! Можно стрелять раз в 10 секунд , дуло нагревается!</div>';}

echo "<div class='aut'><a href='index.php?id=$user[id]'>Назад</a></div>";

include_once '../../sys/inc/tfoot.php';
?>