Advertisement
Guest User

[INC] BSVIP

a guest
Jan 26th, 2012
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 4.13 KB | None | 0 0
  1. /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
  2. *            * * * * * * * * * * * * * * * * * * * * * * * * * *           *            *
  3. *            *                                                 *           *
  4. *            *       ******* Include - BSVIP *******           *           *
  5. *            *                                                 *           *
  6. *            *    BS's  --  Very Important Person  (BSVIP)     *           *
  7. *            *                                                 *           *
  8. *            *           Autor: BrunoStyle ou BS               *           *
  9. *            * * * * * * * * * * * * * * * * * * * * * * * * * *           *
  10. *                                                                          *
  11. *                                                                          *
  12. * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *  */
  13.  
  14.  
  15. #include <a_samp>
  16.  
  17.  
  18. #define ON true
  19. #define OFF false
  20.  
  21. enum BSInfo
  22. {
  23.     bool:BSVip,
  24.     BSSVIP
  25. };
  26. new VIPInfo[MAX_PLAYERS][BSInfo];
  27. new CarroVIP[MAX_PLAYERS];
  28. new string[90] ,NameVIP[25], NameRCON[25];
  29.  
  30.  
  31. /*
  32. Funções:
  33.  
  34.  
  35. native SetPlayerVIP(playerid, playervip, bool:status);
  36. native SetPlayerSVIP(playerid, playersvip, bool:status);
  37. native CreateVehicleVIP(modelid, color1, color2);
  38. native GetPlayerVIP(playerid);
  39. native GetPlayerSVIP(playerid);
  40. */
  41.  
  42.  
  43. stock SetPlayerVIP(playerid, playervip, bool:status)
  44. {
  45.     GetPlayerName(playervip, NameVIP, sizeof(NameVIP));
  46.     GetPlayerName(playerid, NameRCON, sizeof(NameRCON));
  47.     VIPInfo[playervip][BSVIP] = status;
  48.     format(string, sizeof(string), "Você recebeu VIP do Administrador %s", NameRCON);
  49.     SendClientMessage(playervip, 0x33CCFFAA, string);
  50.     CarroVIP[playervip] = OFF;
  51.     format(string, sizeof(string), "Você entregou VIP ao Jogador %s", NameVIP);
  52.     SendClientMessage(playerid, 0x33CCFFAA, string);
  53.     return 1;
  54. }
  55.  
  56.  
  57. stock SetPlayerSVIP(playerid, playersvip, bool:status)
  58. {
  59.     GetPlayerName(playersvip, NameSVIP, sizeof(NameSVIP));
  60.     GetPlayerName(playerid, NameRCON, sizeof(NameRCON));
  61.     VIPInfo[playervip][BSSVIP] = status;
  62.     CarroVIP[playersvip] = OFF;
  63.     format(string, sizeof(string), "Você recebeu SUPER-VIP do Administrador %s", NameRCON);
  64.     SendClientMessage(playervip, 0x33CCFFAA, string);
  65.     format(string, sizeof(string), "Você entregou SUPER-VIP ao Jogador %s", NameVIP);
  66.     SendClientMessage(playerid, 0x33CCFFAA, string);
  67.     return 1;
  68. }
  69.  
  70.  
  71. stock CreateVehicleVIP(modelid, color1, color2)
  72. {
  73.     if(CarroVIP[playervip] == OFF || CarroVIP[playersvip] == OFF))
  74.     {
  75.         if(VIPInfo[playervip][BSVIP] == ON || VIPInfo[playervip][BSSVIP] == ON))
  76.         {
  77.             new Float:Pos[3];
  78.             GetPlayerPos(playervip, Pos, Pos, Pos);
  79.             CreateVehicle(modelid, Pos, Pos, Pos, 180, color1, color2, 9999);
  80.             format(string, sizeof(string), "Você comprou o seu Veiculo VIP", playersvip);
  81.             SendClientMessage(playervip, 0x33CCFFAA, string);
  82.             SendClientMessage(playersvip, 0x33CCFFAA, string);
  83.         }
  84.         else
  85.         {
  86.             SendClientMessage(playerid, 0xA5A5A5AA, "Acesso Negado");
  87.         }
  88.     }
  89.     return 1;
  90. }
  91.  
  92.  
  93. stock GetPlayerVIP(playerid)
  94. {
  95.     if(VIPInfo[playerid][BSVIP] == ON)
  96.     {
  97.         GetPlayerName(playervip, NameVIP, sizeof(NameVIP));
  98.         format(string, sizeof(string), "{FFFFFF}[SUCESSO]{33CCFF} O Jogador %s é VIP", NameVIP);
  99.         SendClientMessage(playerid, 0x33CCFFAA, string);
  100.     }
  101.     if(VIPInfo[playerid][BSVIP] == OFF)
  102.     {
  103.         GetPlayerName(playervip, NameVIP, sizeof(NameVIP));
  104.         format(string, sizeof(string), "{FFFF00}[ERRO]{33CCFF} O Jogador %s não é VIP", NameVIP);
  105.         SendClientMessage(playerid, 0x33CCFFAA, string);
  106.     }
  107.     return 1;
  108. }
  109. stock GetPlayerSVIP(playerid)
  110. {
  111.     if(VIPInfo[playerid][BSSVIP] == ON)
  112.     {
  113.         GetPlayerName(playervip, NameSVIP, sizeof(NameSVIP));
  114.         format(string, sizeof(string), "{FFFFFF}[SUCESSO]{33CCFF} O Jogador %s é VIP", NameVIP);
  115.         SendClientMessage(playerid, 0x33CCFFAA, string);
  116.     }
  117.     if(VIPInfo[playerid][BSSVIP] == OFF)
  118.     {
  119.         GetPlayerName(playervip, NameSVIP, sizeof(NameSVIP));
  120.         format(string, sizeof(string), "{FFFF00}[ERRO]{33CCFF} O Jogador %s não é VIP", NameSVIP);
  121.         SendClientMessage(playerid, 0x33CCFFAA, string);
  122.     }
  123.     return 1;
  124. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement