Share Pastebin
Guest
Public paste!

Untitled

By: a guest | Feb 9th, 2010 | Syntax: None | Size: 2.86 KB | Hits: 20 | Expires: Never
This paste has a previous version, view the difference. Copy text to clipboard
  1. <?php
  2. //******IT.PRO.inc******//
  3. //Immortal Thug Security//
  4. //////////////////////////
  5. require_once("globals.php");
  6.  
  7. $_GET['action'] = isset($_GET['action']) && is_string($_GET['action']) ? strtolower(trim($_GET['action'])) : false;
  8.  
  9. if($ir['village2'] ==10)
  10. {
  11. $db->query(sprintf("UPDATE `users` SET `village3`=`village3`+1 WHERE (`userid`=%d)", $userid));
  12. $db->query(sprintf("UPDATE `users` SET `fishing_aloud`=`fishing_aloud`+`village3` WHERE (`userid`=%d)", $userid));
  13. $db->query(sprintf("UPDATE `users` SET `village2`=`village2`-10 WHERE (`userid`=%d)", $userid));
  14. }
  15.  
  16.  
  17. switch($_GET['action'])
  18. {
  19. case 'fish': fish_1(); break;
  20. case 'fishsub': fish_1_sub(); break;
  21. default: fish_index(); break;
  22. }
  23. /**
  24. ** Calls the cases so kill.php?fish
  25. **/
  26. function fish_index()
  27. {
  28. global $ir,$userid;
  29. echo "<center><h2>Welcome to the entrance of human village number ".$ir['village']."</h2>
  30. </center>";
  31. echo "<center><br /><u>--------------------Human Village--------------------</u><br /><br />
  32. <a href='kill.php?action=fish'>----------<font color=red>K</font color>i<font color=red>l</font color>l <font color=red>H</font color>u<font color=red>m</font color>a<font color=red>n</font color>----------</u></a><br /><br />You Have ".$ir['fishing_aloud']." humans left to kill<br />You Have Killed a Total Of ".$ir['humanskilled']." Humans<br />
  33. </center>";
  34. }
  35. /**
  36. ** This is the main part you see when you come into the php page
  37. **/
  38.  
  39. if ($ir['jailtime'] > 0){
  40. echo "<center>You cannot Kill when you're in hells jail!</center>";
  41. exit;
  42. }
  43. if ($ir['hospital'] > 0){
  44. echo "<center>You cannot kill when you're in hells hospital!</center>";
  45. exit;
  46. }
  47. /**
  48. ** That makes sure you are not in jail or hospital
  49. **/
  50. function fish_1()
  51. {
  52. global $ir,$userid,$db,$h;
  53. if($ir['fishing_aloud'] < 1){
  54. echo sprintf("You have %u humans to kill", $ir['fishing_aloud']);
  55. exit;
  56. }
  57. if ($ir['fishing_aloud'] ==1){
  58. $db->query(sprintf("UPDATE `users` SET `village`=`village`+1 WHERE (`userid`=%d)", $userid));
  59. $db->query(sprintf("UPDATE `users` SET `village2`=`village2`+1 WHERE (`userid`=%d)", $userid));
  60. }
  61. $db->query(sprintf("UPDATE `users` SET `fishing_aloud`=`fishing_aloud`-1 WHERE (`userid`=%d)", $userid));
  62. $db->query(sprintf("UPDATE `users` SET `humanskilled`=`humanskilled`+1 WHERE (`userid`=%d)", $userid));
  63. $rand_fish = rand(1,1);
  64. $rand_money = rand(100,500);
  65. $rand_exp = rand(1,100);
  66. echo sprintf("<center>You begin to look through the village when you spot a human, you sold sold it for %u money!</center><br />
  67. There are %u Humans Left to find in This village", abs((int) $rand_money), number_format($ir['fishing_aloud']));
  68. $db->query(sprintf("UPDATE `users` SET `money`=`money`+%u WHERE (`userid`=%d)", abs((int) $rand_money), $userid));
  69.  
  70. echo "<center><br />[<a href='kill.php?action=fish'>Kill again</a>]</center><br />";
  71.  
  72. echo "<center>[<a href='kill.php'>Back</a>]</center><br />";
  73. }
  74. ?>