Guest User

[FS] NON-TeamKill

a guest
Jul 12th, 2012
625
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 4.47 KB | None | 0 0
  1. // Credits to JustinAn AKA Mike for the filterscript.
  2.  
  3. /*
  4. =====================WARNING!========================
  5. - This script has been compiled by a 0.3e server package
  6. - Script will not work in earlier versions.
  7. =====================WARNING!=========================
  8. */
  9. #include <a_samp>
  10.  
  11. #define COLOR_GRAD1 0xB4B5B7FF
  12.  
  13. #if defined FILTERSCRIPT
  14.  
  15. public OnFilterScriptInit()
  16. {
  17.     print("\n--------------------------------------");
  18.     print(" NON-Teamkilling filterscript loaded...");
  19.     print("--------------------------------------\n");
  20.     return 1;
  21. }
  22.  
  23. public OnFilterScriptExit()
  24. {
  25.     return 1;
  26. }
  27.  
  28. #else
  29.  
  30. main()
  31. {
  32.     print("\n----------------------------------");
  33.     print(" NON-TeamKilling filterscrpit loaded...");
  34.     print("----------------------------------\n");
  35. }
  36.  
  37. #endif
  38.  
  39. public OnGameModeInit()
  40. {
  41.     // Don't use these lines if it's a filterscript
  42.     SetGameModeText("[FS] NON-TeamKilling");
  43.     AddPlayerClass(299, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
  44.     return 1;
  45. }
  46.  
  47. public OnGameModeExit()
  48. {
  49.     return 1;
  50. }
  51.  
  52. public OnPlayerRequestClass(playerid, classid)
  53. {
  54.     SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);
  55.     SetPlayerCameraPos(playerid, 1958.3783, 1343.1572, 15.3746);
  56.     SetPlayerCameraLookAt(playerid, 1958.3783, 1343.1572, 15.3746);
  57.     return 1;
  58. }
  59.  
  60. public OnPlayerConnect(playerid)
  61. {
  62.     return 1;
  63. }
  64.  
  65. public OnPlayerDisconnect(playerid, reason)
  66. {
  67.     return 1;
  68. }
  69.  
  70. public OnPlayerSpawn(playerid)
  71. {
  72.     return 1;
  73. }
  74.  
  75. public OnPlayerDeath(playerid, killerid, reason)
  76. {
  77.     if(GetPlayerTeam(killerid) == GetPlayerTeam(playerid)) // If killerid's team == playerid's team ( who has been killed )
  78.     {
  79.         new Float:slx, Float:sly, Float:slz; // Creates a new float variable.
  80.         GetPlayerPos(killerid, slx, sly, slz); // Get's the player position.
  81.         SetPlayerPos(killerid, slx, sly, slz+5); // Sets the player's position +5 up in the air.
  82.         PlayerPlaySound(killerid, 1130, slx, sly, slz+5); // Plays a slapping sound in the air when the player teamkilled.
  83.         SendClientMessage(killerid, COLOR_GRAD1, "No teamkilling allowed !"); // Sends a message to the player who teamkilled saying "No teamkilling allowed !"
  84.         GivePlayerMoney(killerid, -1000); // Take $1000 from the killerid, because teamkilling - You can change the amount you want.
  85.     }
  86.     return 1;
  87. }
  88.  
  89.  
  90. public OnVehicleSpawn(vehicleid)
  91. {
  92.     return 1;
  93. }
  94.  
  95. public OnVehicleDeath(vehicleid, killerid)
  96. {
  97.     return 1;
  98. }
  99.  
  100. public OnPlayerText(playerid, text[])
  101. {
  102.     return 1;
  103. }
  104.  
  105. public OnPlayerCommandText(playerid, cmdtext[])
  106. {
  107.     if (strcmp("/mycommand", cmdtext, true, 10) == 0)
  108.     {
  109.         // Do something here
  110.         return 1;
  111.     }
  112.     return 0;
  113. }
  114.  
  115. public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
  116. {
  117.     return 1;
  118. }
  119.  
  120. public OnPlayerExitVehicle(playerid, vehicleid)
  121. {
  122.     return 1;
  123. }
  124.  
  125. public OnPlayerStateChange(playerid, newstate, oldstate)
  126. {
  127.     return 1;
  128. }
  129.  
  130. public OnPlayerEnterCheckpoint(playerid)
  131. {
  132.     return 1;
  133. }
  134.  
  135. public OnPlayerLeaveCheckpoint(playerid)
  136. {
  137.     return 1;
  138. }
  139.  
  140. public OnPlayerEnterRaceCheckpoint(playerid)
  141. {
  142.     return 1;
  143. }
  144.  
  145. public OnPlayerLeaveRaceCheckpoint(playerid)
  146. {
  147.     return 1;
  148. }
  149.  
  150. public OnRconCommand(cmd[])
  151. {
  152.     return 1;
  153. }
  154.  
  155. public OnPlayerRequestSpawn(playerid)
  156. {
  157.     return 1;
  158. }
  159.  
  160. public OnObjectMoved(objectid)
  161. {
  162.     return 1;
  163. }
  164.  
  165. public OnPlayerObjectMoved(playerid, objectid)
  166. {
  167.     return 1;
  168. }
  169.  
  170. public OnPlayerPickUpPickup(playerid, pickupid)
  171. {
  172.     return 1;
  173. }
  174.  
  175. public OnVehicleMod(playerid, vehicleid, componentid)
  176. {
  177.     return 1;
  178. }
  179.  
  180. public OnVehiclePaintjob(playerid, vehicleid, paintjobid)
  181. {
  182.     return 1;
  183. }
  184.  
  185. public OnVehicleRespray(playerid, vehicleid, color1, color2)
  186. {
  187.     return 1;
  188. }
  189.  
  190. public OnPlayerSelectedMenuRow(playerid, row)
  191. {
  192.     return 1;
  193. }
  194.  
  195. public OnPlayerExitedMenu(playerid)
  196. {
  197.     return 1;
  198. }
  199.  
  200. public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
  201. {
  202.     return 1;
  203. }
  204.  
  205. public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
  206. {
  207.     return 1;
  208. }
  209.  
  210. public OnRconLoginAttempt(ip[], password[], success)
  211. {
  212.     return 1;
  213. }
  214.  
  215. public OnPlayerUpdate(playerid)
  216. {
  217.     return 1;
  218. }
  219.  
  220. public OnPlayerStreamIn(playerid, forplayerid)
  221. {
  222.     return 1;
  223. }
  224.  
  225. public OnPlayerStreamOut(playerid, forplayerid)
  226. {
  227.     return 1;
  228. }
  229.  
  230. public OnVehicleStreamIn(vehicleid, forplayerid)
  231. {
  232.     return 1;
  233. }
  234.  
  235. public OnVehicleStreamOut(vehicleid, forplayerid)
  236. {
  237.     return 1;
  238. }
  239.  
  240. public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
  241. {
  242.     return 1;
  243. }
  244.  
  245. public OnPlayerClickPlayer(playerid, clickedplayerid, source)
  246. {
  247.     return 1;
  248. }
Advertisement
Add Comment
Please, Sign In to add comment