Advertisement
Guest User

Airdrop_System_ClaudioF_v1.0

a guest
Feb 14th, 2015
1,562
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 4.88 KB | None | 0 0
  1. /*
  2. ########################################################
  3. ########################################################
  4. ####                                               #####
  5. ####  Criado Por: ClaudioF                         #####
  6. ####                                               #####
  7. ####  Sistema: Airdrop 1.0 BETA                    #####
  8. ####                                               #####
  9. ####  Reporte Qualquer Bug                         #####
  10. ####                                               #####
  11. ####  Skype: like.pixell                           #####
  12. ####                                               #####
  13. ####  Site: www.markahost.tk                       #####
  14. ####                                               #####
  15. ########################################################
  16. ######################################################## */
  17.  
  18.  
  19.  
  20.  
  21. #define FILTERSCRIPT
  22.  
  23. #include <a_samp>
  24. #include <cpstream>
  25.  
  26. #pragma tabsize 0
  27.  
  28. #define DIALOG_AIRDROP 2478
  29.  
  30. #if defined FILTERSCRIPT
  31.  
  32.  
  33. new aircp;
  34.  
  35. new air;
  36. new Text3D: airlabel;
  37.  
  38.  
  39. public OnFilterScriptInit()
  40. {
  41.  printf("---------------------------------------\n\n\n");
  42.  printf("Sistema Airdrop By: Claudinho Carregado");
  43.  printf("\n\n\n---------------------------------------");
  44.   //Timer Soltar AirDrop 20 em 20 minutos
  45.  SetTimer("AtivarAir", 200000, true);
  46.  return 1;
  47. }
  48.  
  49. public OnFilterScriptExit()
  50. {
  51.     return 1;
  52. }
  53. public OnPlayerEnterCheckpoint(playerid)
  54. {
  55.  if(CPS_IsPlayerInCheckpoint(playerid, aircp))
  56.  {
  57.  //Definir se o Player Esta Ou não em um Veiculo & Bloquear a função do Checkpoint
  58.    if(IsPlayerInAnyVehicle(playerid))
  59.     {
  60.      return SendClientMessage(playerid, -1,"{ff0000}You Can not Catch A Airdrop in One Vehicle");
  61.     }
  62.  
  63.  
  64.  
  65.  
  66.    //Pegar Nome Do Player
  67.    new string[128], nome[MAX_PLAYER_NAME];
  68.    GetPlayerName(playerid, nome, MAX_PLAYER_NAME);
  69.  
  70.  
  71.  
  72.  
  73.    // Mostrar Quem pegou o Airdrop
  74.    format(string, sizeof string,"{ff0000}[AIRDROP]{ffffff}: %s He took the Airdrop in: Area 51",nome);
  75.    SendClientMessageToAll(-1,string);
  76.    printf(" ");
  77.  
  78.  
  79.  
  80.  
  81.  
  82.    //Prints e Variaveis Pegar Hora Quando o Player entrar no Checkpoint
  83.    new hora, minuto, segundo; gettime(hora,minuto,segundo);
  84.    printf("> [AIRDROP]: Jogador %s Pegou o Airdrop Na Area 51, Horas: [%i/%i/%i]",nome,hora, minuto,segundo);
  85.    printf(" ");
  86.  
  87.  
  88.  
  89.  
  90.     //Deletar TextLabel bjeto & Disabilitar Checkpoint Ao Player Entrar no checkpoint
  91.    Delete3DTextLabel(airlabel);
  92.    DisablePlayerCheckpoint(playerid);
  93.    DestroyObject(air);
  94.  
  95.  
  96.  
  97.  
  98.    //Mostrar Dialog Para o Player e Deletar Airdrop
  99.    ShowPlayerDialog(playerid, DIALOG_AIRDROP, DIALOG_STYLE_LIST,"AirDrop","{ffffff}Katana\n{ffffff}Binoculars\n{ffffff}Baseball Bat\n{0000FF}MakarovPM\n{0000FF}Silenced 9mm\n{fff700}MP5A5\n{ff0000}Shotgun\n{ff0000}M1014\n{ff00b3}M4A1\n{ff00b3}AK-47\n{00ff00}Sniper Rifle\n{00ff00}Country Rifle","Take","Close");
  100.    return 1;
  101.   }
  102.  return 1;
  103. }
  104.  
  105.  
  106. forward AtivarAir(playerid);
  107. public AtivarAir(playerid)
  108. {
  109.  for(new i=0; i < MAX_PLAYERS; ++i)
  110.  {
  111.   // Deletar TextLabel, Checkpoint, Etc...
  112.   Delete3DTextLabel(airlabel);
  113.   DisablePlayerCheckpoint(playerid);
  114.   DestroyObject(air);
  115.  
  116.  
  117.   //Criar TextLabel
  118.   airlabel = Create3DTextLabel("{fff700}AIRDROP:{ffffff}This military cargo \ncontains Multiple weapons",0xFFFFFF,306.42618, 2026.72473, 16.73662, 30, 0);
  119.  
  120.  
  121.  
  122.  
  123.   //Criar e Mover Airdrop
  124.   air = CreateObject(18849, 306.47028, 2026.83362, 92.34710,   0.00000, 0.00000, 0.00000);
  125.   MoveObject(air, 306.47028, 2026.83362, 23.92002, 3.0);
  126.  
  127.  
  128.  
  129.  
  130.  
  131.   //Setar Checkpoint Para o Jogador
  132.   aircp = CPS_AddCheckpoint(306.42618, 2026.72473, 16.73662, 3.0, 50);
  133.  
  134.  
  135.  
  136.  
  137.   //Enviar Mensagem Que o Airdrop Foi Solto
  138.   SendClientMessage(playerid, -1, "{ff0000}[AIRDROP]: {ffffff}A Load Military was in Play Area 51");
  139.   printf(" ");
  140.  
  141.  
  142.  
  143.  
  144.   new hora, minuto, segundo; gettime(hora,minuto,segundo);
  145.   printf("> [AIRDROP]: O Airdrop Foi Jogado Na Area 51: Horas: [%i/%i/%i]", hora, minuto, segundo);
  146.   return 1;
  147.  }
  148. return 1;
  149. }
  150.  
  151.  
  152.  
  153. public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
  154. {
  155.  if(dialogid == DIALOG_AIRDROP)
  156.   {
  157.    if(response)
  158.     {
  159.     if(listitem == 0)
  160.     {
  161.     GivePlayerWeapon(playerid, 8, 1);
  162.     }
  163.     if(listitem == 1)
  164.     {
  165.     GivePlayerWeapon(playerid, 43, 99);
  166.     }
  167.     if(listitem == 2)
  168.     {
  169.     GivePlayerWeapon(playerid, 5, 1);
  170.     }
  171.     if(listitem == 3)
  172.     {
  173.     GivePlayerWeapon(playerid, 22, 25);
  174.     }
  175.     if(listitem == 4)
  176.     {
  177.     GivePlayerWeapon(playerid, 23, 40);
  178.     }
  179.     if(listitem == 5)
  180.     {
  181.     GivePlayerWeapon(playerid, 29, 30);
  182.     }
  183.     if(listitem == 6)
  184.     {
  185.     GivePlayerWeapon(playerid, 25, 20);
  186.     }
  187.     if(listitem == 7)
  188.     {
  189.     GivePlayerWeapon(playerid, 27, 12);
  190.     }
  191.     if(listitem == 8)
  192.     {
  193.     GivePlayerWeapon(playerid, 31, 50);
  194.     }
  195.     if(listitem == 9)
  196.     {
  197.     GivePlayerWeapon(playerid, 30, 60);
  198.     }
  199.     if(listitem == 10)
  200.     {
  201.     GivePlayerWeapon(playerid, 34, 15);
  202.     }
  203.     if(listitem == 11)
  204.     {
  205.     GivePlayerWeapon(playerid, 33, 20);
  206.    }
  207.   }
  208.  }
  209.  return 1;
  210. }
  211.  
  212. #endif
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement