0) { echo "Не в бою..."; } elseif (rand(1,100)!=1) { //undressall($user['id']); if (empty($_SESSION['uid'])) { header("Location: index.php"); exit; } global $rooms; $rs = mysql_query("SELECT * FROM `users` WHERE `in_tower` = 1 ORDER by `room` DESC;"); while($r = mysql_fetch_array($rs)) { if($rt != $r['room']) { $rt = $r['room']; $rr .= "\n".$rooms[$r['room']].": "; } $rr .= $r['login'].", "; } echo "Отчет о сканировании у вас в рюкзаке"; mysql_query("INSERT INTO `inventory` (`bs`,`owner`,`name`,`type`,`massa`,`cost`,`img`,`letter`,`maxdur`,`isrep`)VALUES('1','{$_SESSION['uid']}','Отчет о сканировании','200',1,0,'paper100.gif','{$rr}',1,0) ;"); $bet=1; }