Просмотр файла city1/chuvak.php

Размер файла: 2.42Kb
  1. <?php
  2. include "./../ini3.php";
  3. include "./../includes/header2.php";
  4. include "./../includes/inc_online.php";
  5.  
  6.  
  7. $id=cyr(htmlspecialchars(stripslashes(trim($id))));
  8. $pass=cyr(htmlspecialchars(stripslashes(trim($pass))));
  9.  
  10. if(!empty($id))
  11. {
  12. $q = mysql_query("select secur,golod,voodoo,nums,guns,cars,id,login,pass,money,level,police,health,zav,lsd,ban from users where id='".$id."';");
  13. }
  14. else
  15. {
  16. die ($lang['empty_login']."</body>
  17. </html>");
  18. }
  19.  
  20. $data = mysql_fetch_array($q);
  21.  
  22. $id=$data['id'];
  23. $login=$data['login'];
  24. $money=$data['money'];
  25. $level=$data['level'];
  26. $police=$data['police'];
  27. $stage=$data['stage'];
  28. $health=$data['health'];
  29. $cars=$data['cars'];
  30. $guns=$data['guns'];
  31. $nums=$data['nums'];
  32. $voo_por=$data['voodoo'];
  33. $golod=$data['golod'];
  34. $secur=$data['secur'];
  35. $zav=$data['zav'];
  36. $lsd=$data['lsd'];
  37. $ban=$data['ban'];
  38.  
  39. if($pass!=$data['pass'])
  40. {
  41. die ($lang['empty_login']."</body>
  42. </html>");
  43. }
  44.  
  45. mysql_query("update users set last='".time()."',city='1' where id='".$id."';");
  46. if($ban==0)
  47. {
  48.  
  49. include "./../includes/inc_secur.php";
  50. include "./../includes/inc_golod.php";
  51. include "./../includes/inc_hospital.php";
  52. include "./../includes/inc_police.php";
  53. include "./../includes/inc_die.php";
  54. include "./../includes/inc_voodoo.php";
  55. include "./../includes/inc_attack.php";
  56. include "./../includes/inc_mes.php";
  57. print "<b>[Зд: $health %][Сыт: $golod %][Зщ: $secur %]</b><br/>";
  58. print "<b>".$lang['game_city1']."</b><br/>";
  59. print "<u>[".$lang['chuv_enter']."]</u><br/>";
  60.  
  61. switch ($mode)
  62. {
  63. case "e":
  64. if(empty($p))
  65. {
  66. print $lang['chuv_yes'];
  67. print "<a href=\"chuvak.php?id=$id&amp;pass=$pass&amp;mode=e&amp;p=k\">".$lang['ph_kup']."</a><br/>";
  68. }
  69. else
  70. {
  71. if($money<100) die($lang['bands_user_without_money_for']."<br/><anchor>".$lang['back']."<prev/></anchor></p></card></wml>");
  72. $money=$money-1000;
  73. ++$police;
  74. mysql_query("update users set money='".$money."',police='".$police."',health='300' where id='".$id."';");
  75. print $lang['chuv_warning'];
  76. }
  77. break;
  78. default:
  79. print $lang['chuv_mes'];
  80. print "<a href=\"chuvak.php?id=$id&amp;pass=$pass&amp;mode=e\">".$lang['chuv_vopros']."</a><br/>";
  81. print "<a href=\"area.php?id=$id&amp;pass=$pass\">".$lang['chuv_ok']."</a><br/>";
  82. break;
  83. }
  84.  
  85.  
  86. include("./../includes/inc_in_city.php");
  87.  
  88. mysql_close();
  89. include "./../includes/footer2.php";
  90. }
  91.  
  92. elseif($ban==1)
  93. {
  94. die ($lang['empty_login']."</body>
  95. </html>");
  96.  
  97. }
  98. ?>