Advertisement
Guest User

Untitled

a guest
Feb 4th, 2010
306
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. /*
  2. *---------------------------------------------------*|
  3. | |
  4. | |
  5. | AntiWeapon HACK |
  6. | |
  7. *----------------------------------------------------*
  8. */
  9. #include <a_samp>
  10. #pragma tabsize 0
  11. //------------------------------------------------------------------------------
  12. #define COLOR_LIGHTRED 0xFF6347AA
  13. //------------------------------------------------------------------------------
  14. forward wantihack();
  15. //------------------------------------------------------------------------------
  16. public OnFilterScriptInit()
  17. {
  18. SetTimer("wantihack", 3000, 1);
  19. return 1;
  20. }
  21. //------------------------------------------------------------------------------
  22. public wantihack()
  23. {
  24. for(new i; i < MAX_PLAYERS; i++)
  25. {
  26. new sendername[MAX_PLAYER_NAME];
  27. GetPlayerName(i, sendername, sizeof(sendername));
  28. new string[256];
  29. if(GetPlayerWeapon(i) == 16)
  30. {
  31. format(string, sizeof(string), "%s was banned, reason: Grenade.",sendername);
  32. SendClientMessageToAll(COLOR_LIGHTRED, string);
  33. BanEx(i,"Grenades");
  34. return 1;
  35. }
  36. if(GetPlayerWeapon(i) == 17)
  37. {
  38. format(string, sizeof(string), "%s was banned, reason: Tear Gas.",sendername);
  39. SendClientMessageToAll(COLOR_LIGHTRED, string);
  40. BanEx(i,"Tear Gas");
  41. return 1;
  42. }
  43. if(GetPlayerWeapon(i) == 18)
  44. {
  45. format(string, sizeof(string), "%s was banned, reason: Molotov Cockatils",sendername);
  46. SendClientMessageToAll(COLOR_LIGHTRED, string);
  47. BanEx(i,"Molotov Cockatils");
  48. return 1;
  49. }
  50. if(GetPlayerWeapon(i) == 22)
  51. {
  52. format(string, sizeof(string), "%s was banned, reason: 9MM Pistol",sendername);
  53. SendClientMessageToAll(COLOR_LIGHTRED, string);
  54. BanEx(i,"9MM Pistol");
  55. return 1;
  56. }
  57. if(GetPlayerWeapon(i) == 26)
  58. {
  59. format(string, sizeof(string), "%s was banned, reason: Sawn-off Shotgun",sendername);
  60. SendClientMessageToAll(COLOR_LIGHTRED, string);
  61. BanEx(i,"Sawn-off Shotgun");
  62. return 1;
  63. }
  64. if(GetPlayerWeapon(i) == 27)
  65. {
  66. format(string, sizeof(string), "%s was banned, reason: Combat Shotgun",sendername);
  67. SendClientMessageToAll(COLOR_LIGHTRED, string);
  68. BanEx(i,"Combat Shotgun");
  69. return 1;
  70. }
  71. if(GetPlayerWeapon(i) == 28)
  72. {
  73. format(string, sizeof(string), "%s was banned, reason: Micro SMG",sendername);
  74. SendClientMessageToAll(COLOR_LIGHTRED, string);
  75. BanEx(i,"Micro SMG");
  76. return 1;
  77. }
  78. if(GetPlayerWeapon(i) == 32)
  79. {
  80. format(string, sizeof(string), "%s was banned, reason: Tec9",sendername);
  81. SendClientMessageToAll(COLOR_LIGHTRED, string);
  82. BanEx(i,"Tec9");
  83. return 1;
  84. }
  85. if(GetPlayerWeapon(i) == 35)
  86. {
  87. format(string, sizeof(string), "%s was banned, reason: Rocket Launcher",sendername);
  88. SendClientMessageToAll(COLOR_LIGHTRED, string);
  89. BanEx(i,"Rocket Launcher");
  90. return 1;
  91. }
  92. if(GetPlayerWeapon(i) == 36)
  93. {
  94. format(string, sizeof(string), "%s was banned, reason: HS Rocket Launcher",sendername);
  95. SendClientMessageToAll(COLOR_LIGHTRED, string);
  96. BanEx(i,"HS Rocket Launcher");
  97. return 1;
  98. }
  99. if(GetPlayerWeapon(i) == 37)
  100. {
  101. format(string, sizeof(string), "%s was banned, reason: Flamethrower",sendername);
  102. SendClientMessageToAll(COLOR_LIGHTRED, string);
  103. BanEx(i,"Flamethrower");
  104. return 1;
  105. }
  106. if(GetPlayerWeapon(i) == 38)
  107. {
  108. format(string, sizeof(string), "%s was banned, reason: Minigun",sendername);
  109. SendClientMessageToAll(COLOR_LIGHTRED, string);
  110. BanEx(i,"Minigun");
  111. return 1;
  112. }
  113. if(GetPlayerWeapon(i) == 39)
  114. {
  115. format(string, sizeof(string), "%s was banned, reason: Satchel Charge",sendername);
  116. SendClientMessageToAll(COLOR_LIGHTRED, string);
  117. BanEx(i,"Satchel Charge");
  118. return 1;
  119. }
  120. if(GetPlayerWeapon(i) == 40)
  121. {
  122. format(string, sizeof(string), "%s was banned, reason: Detonator",sendername);
  123. SendClientMessageToAll(COLOR_LIGHTRED, string);
  124. BanEx(i,"Detonator");
  125. return 1;
  126. }
  127. if(GetPlayerWeapon(i) == 42)
  128. {
  129. format(string, sizeof(string), "%s was banned, reason: Fire Extinguisher",sendername);
  130. SendClientMessageToAll(COLOR_LIGHTRED, string);
  131. BanEx(i,"Fire Extinguisher");
  132. return 1;
  133. }
  134. if(GetPlayerWeapon(i) == 44)
  135. {
  136. format(string, sizeof(string), "%s was banned, reason: Nightvision Goggles",sendername);
  137. SendClientMessageToAll(COLOR_LIGHTRED, string);
  138. BanEx(i,"Nightvision Goggles");
  139. return 1;
  140. }
  141. if(GetPlayerWeapon(i) == 45)
  142. {
  143. format(string, sizeof(string), "%s was banned, reason: Thermal Goggles",sendername);
  144. SendClientMessageToAll(COLOR_LIGHTRED, string);
  145. BanEx(i,"Thermal Goggles");
  146. return 1;
  147. }
  148. if(GetPlayerSpecialAction(i) == SPECIAL_ACTION_USEJETPACK)
  149. {
  150. format(string, sizeof(string), "%s was banned, reason: JetPack",sendername);
  151. SendClientMessageToAll(COLOR_LIGHTRED, string);
  152. BanEx(i,"Jetpack");
  153. return 1;
  154. }
  155. }
  156. return 1;
  157. }
  158. /*
  159. *---------------------------------------------------*|
  160. | |
  161. | |
  162. | End of the script |
  163. | |
  164. *----------------------------------------------------*
  165. */
Advertisement
Advertisement
Advertisement
RAW Paste Data Copied
Advertisement