View file umnikmat2.php

File size: 6.83Kb
<?

$a = mysql_query ("Select * from vopros where klu4='2'"); 
$b = mysql_fetch_array ($a);
$nom = $b["number"];
$vr = $b["time"];
$answ = $b["answer"]; 
$tran = $b["tran"];
$amsg = rus_to_k($msg); //сообщение
$kansw = rus_to_k($answ); //сообщение = ответу 

if ($msg=="!вопрос"||$msg=="!vopros"){
$r = mysql_query ("select * from vopros where klu4='2'");
$a = mysql_fetch_array($r);
$vp = $a["question"];
$otvet = $a["answer"];
if($otvet!=""){
$i = $a ["number"];
if ($i!=5){
$st = getmicrotime();           
$today=date ("H:i"); 
$a = @mysql_query ("Select posts from users where id='".$uid."'");
$b = mysql_fetch_array ($a);
$p = $b["posts"]; 
$p++;
@mysql_query ("Update users set posts='".$p."', onl='".$st."', room='11' where id ='".$uid."'");
$rnd = rand(0,99999999);
mysql_query ("Insert into room11 set klu4= '".$rnd."', time='".$today."', who='".$uus."', message='".$us.", ".$vp."', id='".$st."', towhom='', hid='0', usid='".$uid."', komu=''");   }
}else{
$vp = "$us, блять! Для тупых повторяю: время вышло! Жди следующего вопроса!";
$st = getmicrotime();           
$today=date ("H:i"); 
$a = @mysql_query ("Select posts from users where id='".$uid."'");
$b = mysql_fetch_array ($a);
$p = $b["posts"]; 
$p++;
@mysql_query ("Update users set posts='".$p."', onl='".$st."', room='11' where id ='".$uid."'");
$rnd = rand(0,99999999);
mysql_query ("Insert into room11 set klu4= '".$rnd."', time='".$today."', who='".$uus."', message='".$vp."', id='".$st."', towhom='', hid='0', usid='".$uid."', komu=''");     
}
}

$s = substr ($msg,0,5); 
if (($s == "stats")&&(strlen($msg) > 6)){
$stsus = substr ($msg,6,strlen($msg)-6);                          
$a = @mysql_query ("Select credits from users where user='".$stsus."'");
if (mysql_affected_rows() != 0){ 
$st = getmicrotime();           
$today=date ("H:i");
$b = mysql_fetch_array($a);
$i = $b["credits"];  
$a = @mysql_query ("Select user from users order by credits desc LIMIT 101");
$j = 1;
$b = mysql_fetch_array($a);   

while (($b["user"] != $stsus)&&($j <= 100)) {$b = mysql_fetch_array($a); $j++;}
if ($j<=31){ 
if ($row["sex"]=="М") $mes = "Уёбище ".$stsus." успешно отсосало ".$i." хуев, и оно занимает в рейтинге хуесосов ".$j." место.";
else $mes = "Уёбище ".$stsus." успешно отсосало ".$i." хуев, и оно занимает в рейтинге хуесосов ".$j." место.";
}else{ 
if ($row["sex"]=="М") $mes = "В рейтинге этот гандон занимает место за пределами первых трех десятков хуюмников.";
else $mes  = "В рейтинге эта сука занимает место за пределами первых трех десятков хуюмников.";
}
$rnd = rand(0,99999999);
if($towhom == $uid) $th = $id; else $th ="";
mysql_query ("Insert into room11 set klu4= '".$rnd."', time='".$today."', who='".$uus."', message='".$mes."', id='".$st."', towhom='".$th."', hid='0', usid='".$uid."'");  
$a = @mysql_query ("Select posts from users where id='".$uid."'");
$b = mysql_fetch_array ($a);
$p = $b["posts"]; 
$p++;
@mysql_query ("Update users set posts='".$p."', onl='".$st."', room='11' where id ='".$uid."'");
}else{ 
$st = getmicrotime();           
$today=date ("H:i");
$mes = "Хуюмника с ником $stsus нет в базе данных!";
$rnd = rand(0,99999999);
if($towhom == $uid) $th = $id; else $th ="";
mysql_query ("Insert into room11 set klu4= '".$rnd."', time='".$today."', who='".$uus."', message='".$mes."', id='".$st."', towhom='".$th."', hid='0', usid='".$uid."', komu=''");  
                                     
$a = @mysql_query ("Select posts from users where id='".$uid."'");
$b = mysql_fetch_array ($a);
$p = $b["posts"]; 
$p++;
@mysql_query ("Update users set posts='".$p."', onl='".$st."', room='11' where id ='".$uid."'");
}
}
$agent = htmlentities(addslashes($HTTP_USER_AGENT));
if (((strpos ($agent,"M3Gate") !== false)||(strpos ($agent,"Opera") !== false)||(strpos ($agent,"emulator") !== false)||(strpos ($agent,"WinWAP") !== false)||(strpos ($agent,"Wapsilon") !== false)||(strpos ($agent,"Mozilla") !== false)||(strpos ($agent,"M3GATE") !== false))&&($rm==0)&&($set["vict"] == 0)){
if (($amsg == $kansw||$amsg == $tran)&&$nom!=5){
$st = time();
$today=date ("H:i");
$mes = "Вы великолепно отсосали хуй. Но у хуесосов отвечающих с компа ответы не засчитываются.";     
$rnd = rand(0,99999999);
mysql_query ("Insert into room11 set klu4= '".$rnd."', time='".$today."', who='".$uus."', message='".$mes."', id='".$st."', towhom='".$id."', hid='".$id."', usid='".$uid."', komu='".$us."'");
}
}else{
if (($amsg == $kansw||$amsg == $tran)&&$nom!=5){{
$st = time();
$victint = $set["victint"];
$st = $st + $victint;
if ($victint=="10") $interval="10 секунд";
else if ($victint=="30") $interval="30 секунд";
else if ($victint=="60") $interval="минуту";
else $interval="2 минуты";
mysql_query ("Update vopros set number = '5', time = '".$st."', answer = ' ', tran = ' ' WHERE klu4 ='2'");
$a = @mysql_query ("Select posts from users where id='".$uid."'");
$b = mysql_fetch_array ($a);
$p = $b["posts"]; 
$p++;
@mysql_query ("Update users set posts='".$p."', onl='".$st."', room='11' where id ='".$uid."'");
$a = @mysql_query ("Select posts from users where id='".$uid."'");
$b = mysql_fetch_array ($a);
$p = $b["posts"]; 
$p++;
@mysql_query ("Update users set posts='".$p."', onl='".$st."', room='11' where id ='".$uid."'");
               
$p = $row["credits"];
$p++;
 mysql_query ("Update users set credits='".$p."' where id ='".$id."'");
$st = getmicrotime();           
$today=date ("H:i");

$mes = rand(1,2); 
$mes = str_replace("1","Заебись, ".$us."! Ты хуйнул в тему, баклан! ".$us." виртуозно отсосал ".$row["credits"]." хуёв! Следующий вопрос, когда я вас всех выебу.",$mes);
$mes = str_replace("2","Ну ты ".$us." и ботаник. Что типа умный? Дай другим ответить гандон. Следующий вопрос через ".$interval.".",$mes);
$mes = str_replace("3","",$mes);
$mes = str_replace("4","",$mes);
$mes = str_replace("5","",$mes);
$mes = str_replace("6","",$mes);
$mes2 = $mes;


$rnd = rand(0,99999999);
mysql_query ("Insert into room11 set klu4= '".$rnd."', time='".$today."', who='".$uus."', message='".$mes2."', id='".$st."', towhom='".$towhom."', hid='0', usid='".$uid."', komu=''");  
} 
$st = time();
$today=date ("H:i");
$mes = "Заебись сосёшь:)";     
$rnd = rand(0,99999999);
mysql_query ("Insert into room11 set klu4= '".$rnd."', time='".$today."', who='".$uus."', message='".$mes."', id='".$st."', towhom='".$id."', hid='".$id."', usid='".$uid."', komu='".$us."'");
}
}
?>