Advertisement
OtaconEvil

[EN] 'Insecticide >F.R.I.K.I<'| exterminator of insects

Apr 15th, 2014
319
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 4.28 KB | None | 0 0
  1. /*
  2.     * ## LEASE ATENTAMENTE PARA NO CONVERTIRSE EN LAMMER!!.: :D ##
  3.     *
  4.     * Estè Simple FILTERSCRIPT esta hecho especialmente para www.forum.sa-mp.com
  5.     * NO Publicar estè FILTERSCRIPT en Otros foros de SA-MP y hacerse pasar por el creador del CODE.
  6.     *
  7.     * Codigo Creado Por OTACON
  8.     *
  9.     * CREDITOS:
  10.     *     OTACON: Realizacion y Idea de creacion del code.
  11.     *     TÙ: Modificacion libremente respetando lo mencionado ;).
  12.     *
  13.     *    NOTA: Menos Creditos para los que me los critican.. JO'PUTAS! :D xD ;)
  14.     *
  15.     *                Prohibido TOTALMENTE el Robo de Créditos o la
  16.     *                  Publicación de este FILTERSCRIPT sin Mi Permiso.
  17. */
  18. /*
  19.     * ## READ CAREFULLY TO AVOID BECOMING LAMMER!.: :D ##
  20.     *
  21.     * This simple FILTERSCRIPT is made especially for www.forum.sa-mp.com
  22.     * DO NOT Post the FILTERSCRIPT in Other SAMP forums and impersonating the creator of the CODE.
  23.     *
  24.     * Code Created By OTACON
  25.     *
  26.     * CREDITS:
  27.     *     OTACON: Idea Making and code creation.
  28.     *     YOUR: Modification freely respecting the above ;).
  29.     *
  30.     *    NOTE: Less Credits for those who criticize me.. JO'PUTAS! :D xD ;)
  31.     *
  32.     *                        FULLY spaces Theft Credit or
  33.     *                 Publication of this FILTERSCRIPT without my permission.
  34. */
  35. #include <a_samp>
  36. #include <zcmd>
  37. /*
  38.     'Insecticide >F.R.I.K.I<'| kills all kinds of insects instantly!.
  39.      * protects the environment from the 'pesky bugs' to live in harmony.
  40.      
  41.      ¿That is?:
  42.      * is a minigame to kill each other, a number of dead set, you'll earn a monetary reward
  43.      
  44.      Credits:
  45.      * OTACON (creation / processing code)
  46.      * ADRI1 and 'other unmentionables'( involuntary idea )
  47.      
  48.      Dedication:
  49.      * ADRI1 and 'other unmentionables'( involuntary idea )
  50. */
  51.  
  52. #define REWARD_INSECTICIDE (10000) //the maximum reward
  53. #define VALUE_INSECTICIDE (100) //the value of the insecticide
  54. #define MAX_INSECTICIDE (50) //maximum kill insects
  55. #define AMMO_INSECTICIDE (100) //insecticide ammunition gun
  56. #define GUN_INSECTICIDE (41) //the id of the insecticide weapon
  57. new bool:KillInsects[MAX_PLAYERS],
  58. CountingDeadInsects[MAX_PLAYERS];
  59.  
  60. COMMAND:insecticide(playerid, params[]){
  61.     if(GetPlayerMoney(playerid)<VALUE_INSECTICIDE) return SendClientMessage(playerid,-1,"{0099FF}INFO: You do not have enough money to buy a 'Insecticide >F.R.I.K.I<'{FFFFFF}!.");
  62.     if(KillInsects[playerid]==true) return SendClientMessage(playerid,-1,"{0099FF}INFO: You already have a 'Insecticide >F.R.I.K.I<'{FFFFFF}!.");
  63.     KillInsects[playerid]=true;
  64.     GivePlayerWeapon(playerid,GUN_INSECTICIDE,AMMO_INSECTICIDE);
  65.     GivePlayerMoney(playerid,(0-VALUE_INSECTICIDE));
  66.     GameTextForPlayer(playerid, "~w~these protected ~n~~g~kills insects!.", 5000, 3);
  67.     SendClientMessage(playerid,-1,"{0099FF}INFO: You have purchased a 'Insecticide >F.R.I.K.I<' correctly{FFFFFF}!.");
  68.     return true;
  69. }
  70. public OnPlayerDeath(playerid, killerid, reason){
  71.     new data[144];
  72.     if(playerid!=INVALID_PLAYER_ID && KillInsects[playerid]==true){
  73.         if(GetPlayerWeapon(playerid)==GUN_INSECTICIDE){
  74.             CountingDeadInsects[playerid]++;
  75.             CountingDeadInsects[killerid]--;
  76.             GameTextForPlayer(playerid, "~g~dead insect!.", 5000, 3);
  77.             SendClientMessage(playerid,-1,"{0099FF}INFO: You have killed a 'insect', congratulations one less{FFFFFF}!.");
  78.             SendClientMessage(killerid,-1,"{0099FF}INFO: You have been exterminated by the 'Insecticide >F.R.I.K.I<', un insecto menos{FFFFFF}!.");
  79.             if(CountingDeadInsects[playerid]>=MAX_INSECTICIDE){
  80.                 SendClientMessage(playerid,-1,"{0099FF}INFO: Congratulations you have exterminated all insects, society is safe{FFFFFF}!.");
  81.                 SendClientMessage(playerid,-1,"{0099FF}INFO:{You have received a reward from the company to clean up the planet de'Insectos unbearable 'FFFFFF}!.");
  82.                 format(data,sizeof(data),"{FFFFFF}REWARD VALUE: {0099FF}%s",REWARD_INSECTICIDE);
  83.                 SendClientMessage(playerid,-1,data);
  84.                 GivePlayerMoney(playerid,(0+REWARD_INSECTICIDE));
  85.                 CountingDeadInsects[playerid]=0;
  86.                 KillInsects[playerid]=false;
  87.                 GameTextForPlayer(playerid, "~w~these unprotected ~n~~r~careful with insects.!.", 5000, 3);
  88.             }
  89.         }
  90.     }
  91.     return true;
  92. }
  93. public OnPlayerDisconnect(playerid, reason){
  94.     CountingDeadInsects[playerid]=0;
  95.     KillInsects[playerid]=false;
  96.     return true;
  97. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement