jefferson789

[uD] Universal Drift v1.0 [BASE]

Sep 29th, 2012
1,179
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 66.92 KB | None | 0 0
  1. /*
  2.                     |   - Universal Drift v1.0 -   |
  3.  
  4.              ******************| CRÈDITOS |***************
  5.                 GM Densevolvido por:
  6.                     -   .CrazZy._.  =  "Jefferson Gomes".
  7.                         Contato Email: jefferson-gomes16@hotmail.com
  8.              *********************************************
  9.              
  10. */
  11. #include    <  a_samp  >
  12.  
  13. #pragma tabsize 0
  14.  
  15. //========================[ DIALOGS ]==========================
  16. #define          Comandos        9
  17. #define          MudarCor        10
  18. #define          Horario         11
  19. #define          uD              12
  20. #define          Cores           13
  21. #define          Mundo           14
  22. #define          Musicas         15
  23. #define          Menssagem       16
  24. //======================[Textdraw Mudando]======================
  25. new news[][] =
  26. {
  27. "U~w~n~b~i~p~v~g~ers~w~a~w~l", "~r~    ~w~D~b~r~g~i~p~f~y~t"
  28. };
  29.  
  30. //====================================[ NEWS ]=======================================
  31. new AdmCars[3];
  32. new Text:Jeff1, Text:Jeff2, Text:Jeff3;
  33. new Text:Rodape;
  34. new Text:Nome;
  35. new players;
  36. new Afk[MAX_PLAYERS];
  37. new Text:topblack, Text:bottomblack;
  38. new Text:Textdraw1;
  39. new Text:On, Text:Ausente;
  40. new Float:PosX[MAX_PLAYERS], Float:PosY[MAX_PLAYERS], Float:PosZ[MAX_PLAYERS], Float:PosA[MAX_PLAYERS], PosI[MAX_PLAYERS];
  41. new bool: EnCoche[MAX_PLAYERS];
  42. new carro[MAX_PLAYERS];
  43.  
  44.  
  45. //==================================[FORWARD]=========================================
  46. forward OnPlayerVirtualWorldChange(playerid, newworld, oldworld);
  47. forward DeletarTextodoJeff(playerid);
  48. forward FLIPAUTO(playerid);
  49. forward RandomMSG();
  50. forward IsVehicleOccupied(vehicleid);
  51. forward RodapeTimer();
  52. forward atualizar ();
  53. forward Nitro(playerid);
  54.  
  55. new vehName[][] ={
  56. "Landstalker","Bravura","Buffalo","Linerunner","Pereniel","Sentinel","Dumper","Firetruck","Trashmaster",
  57. "Stretch","Manana","Infernus","Voodoo","Pony","Mule","Cheetah","Ambulance","Leviathan","Moonbeam","Esperanto",
  58. "Taxi","Washington","Bobcat","Mr Whoopee","BF Injection","Hunter","Premier","Enforcer","Securicar","Banshee",
  59. "Predator","Bus","Rhino","Barracks","Hotknife","Trailer","Previon","Coach","Cabbie","Stallion","Rumpo",
  60. "RC Bandit","Romero","Packer","Monster","Admiral","Squalo","Seasparrow","Pizzaboy","Tram","Trailer",
  61. "Turismo","Speeder","Reefer","Tropic","Flatbed","Yankee","Caddy","Solair","Berkley's RC Van","Skimmer",
  62. "PCJ-600","Faggio","Freeway","RC Baron","RC Raider","Glendale","Oceanic","Sanchez","Sparrow","Patriot",
  63. "Quad","Coastguard","Dinghy","Hermes","Sabre","Rustler","ZR3 50","Walton","Regina","Comet","BMX",
  64. "Burrito","Camper","Marquis","Baggage","Dozer","Maverick","News Chopper","Rancher","FBI Rancher","Virgo",
  65. "Greenwood","Jetmax","Hotring","Sandking","Blista Compact","Police Maverick","Boxville","Benson","Mesa",
  66. "RC Goblin","Hotring Racer A","Hotring Racer B","Bloodring Banger","Rancher","Super GT","Elegant",
  67. "Journey","Bike","Mountain Bike","Beagle","Cropdust","Stunt","Tanker","RoadTrain","Nebula","Majestic",
  68. "Buccaneer","Shamal","Hydra","FCR-900","NRG-500","HPV1000","Cement Truck","Tow Truck","Fortune","Cadrona",
  69. "FBI Truck","Willard","Forklift","Tractor","Combine","Feltzer","Remington","Slamvan","Blade","Freight",
  70. "Streak","Vortex","Vincent","Bullet","Clover","Sadler","Firetruck","Hustler","Intruder","Primo","Cargobob",
  71. "Tampa","Sunrise","Merit","Utility","Nevada","Yosemite","Windsor","Monster A","Monster B","Uranus",
  72. "Jester","Sultan","Stratum","Elegy","Raindance","RC Tiger","Flash","Tahoma","Savanna","Bandito","Freight",
  73. "Trailer","Kart","Mower","Duneride","Sweeper","Broadway","Tornado","AT-400","DFT-30","Huntley","Stafford",
  74. "BF-400","Newsvan","Tug","Trailer A","Emperor","Wayfarer","Euros","Hotdog","Club","Trailer B","Trailer C",
  75. "Andromada","Dodo","RC Cam","Launch","Police Car (LSPD)","Police Car (SFPD)","Police Car (LVPD)","Police Ranger",
  76. "Picador","S.W.A.T. Van","Alpha","Phoenix","Glendale","Sadler","Luggage Trailer A","Luggage Trailer B",
  77. "Stair Trailer","Boxville","Farm Plow","Utility Trailer" };
  78.  
  79. //============================ CORES ===================================//
  80. #define Cor          0xFFAA82AA
  81. #define Verde        0x00FF00FF
  82. #define Vermelho     0xFF0000AA
  83. #define Azul         0x0000FFAA
  84. #define Marron       0x804000AA
  85. #define Branco       0xFFFFFFAA
  86. #define Laranja      0xFF8000AA
  87. #define Azul_Marinho 0x80FFFFAA
  88. #define Cinza        0xC0C0C0AA
  89. #define Rosa         0xFF80FFAA
  90. #define Azul_Claro   0x80BFFFAA
  91. #define Verde_Escuro 0x007138AA
  92. #define Amarelo      0xFFFF00AA
  93. #define Roxo         0x9F009FAA
  94. #define Verde        0x00FF00FF
  95. #define Preto        0x00000000
  96.  
  97. new mensagens[9][256] = { //Mude o 1 se for colocar mais mensagens
  98. "INFO: » Xiter's ou cheats no servidor ? utilize: /Report.",
  99. "INFO: » Chame seus amigos servidor crescendo Humíldemente.",
  100. "INFO: » Gamemode Densevolvido por .CrazZy._.",
  101. "INFO: » Universal Drift fazendo o melhor por você.",
  102. "INFO: » Servidor crescendo com você.",
  103. "INFO: » Quer trocar acor do seu veículo ? Ùtilize: /Cores.",
  104. "INFO: » Bugs, algo do tipo no servidor ? contate-nós.",
  105. "INFO: » Servidor lagando ? ùtilize: /Mundo",
  106. "INFO: » Equipe [uD] Agradece sua vísita."
  107. };
  108.  
  109. new cores[] = {
  110. Cor
  111. };
  112.  
  113.  
  114. main()
  115. {
  116.     print("\n----------------------------------");
  117.     print("[uD] Universal Drift - BRASIL");
  118.     print("Gamemode densevolvido por: .CrazZy._.");
  119.     print("----------------------------------\n");
  120. }
  121.  
  122.  
  123. public OnGameModeInit()
  124. {
  125.    AddStaticPickup(1318, 1, 976.681274, -2151.978515, 13.223649, 0);
  126.    Create3DTextLabel("Mansão oficial da: Universal Drift\nSeja bem Vindo! =D", Azul_Claro, 976.681274, -2151.978515, 13.223649, 500, 0, 1);
  127.    
  128.    AddStaticPickup(1272, 1, 981.474487, -2152.880371, 13.714790, 0);
  129.    Create3DTextLabel("Entre na mansão da uD!!\n Apete 'F'.", 0xFFFFFFAA, 981.474487, -2152.880371, 13.714790, 500, 0, 1);
  130.    
  131.    AddStaticPickup(1272, 1, 2324.6113,-1148.4275,1050.7101, 0);
  132.    Create3DTextLabel("Pra sair da mansão Aperte 'F'.", 0xFFFFFFAA, 2324.6113,-1148.4275,1050.7101, 500, 0, 1);
  133.    
  134.    Create3DTextLabel("Bem Vindo(a), a [uD] - Universal Drift\nPista Oficial da [uD].", Amarelo, -312.7437,1509.3748,75.5625, 60, 0);
  135.    Create3DTextLabel("Segure 'F' pra pegar um elegy.", Amarelo, -300.8931,1555.4410,75.3594, 60, 0);
  136.  
  137.     //======================================| VEÍCULOS ADMIN |=============================================
  138.     AdmCars[0] = CreateVehicle(446,945.00781250,-2126.42773438,0.00000000,345.51403809,-1,-1,15); //Squalo
  139.     AdmCars[1] = CreateVehicle(446,940.17187500,-2145.98144531,0.00000000,345.51403809,-1,-1,15); //Squalo
  140.     AdmCars[2] = CreateVehicle(487,972.73339844,-2138.79833984,13.49535942,98.00000000,-1,1,15); //Maverick
  141.  
  142.     Jeff1 = TextDrawCreate(320, 160, "                                                                          ~n~       ~n~       ~n~       ~n~       ~n~       ~n~       ~n~       ~n~       ~n~       ~n~       ~n~       ~n~       ~n~       ~n~       ~n~       ~n~       ~n~       ~n~       ");
  143.     TextDrawUseBox(Jeff1, 1);
  144.     TextDrawAlignment(Jeff1, 2);
  145.     TextDrawBoxColor(Jeff1, 0x000000AA);
  146.     TextDrawTextSize(Jeff1, 400, 400);
  147.     Jeff2 = TextDrawCreate(247.000000, 143.000000, "                ~g~Bem Vindo");
  148.     TextDrawSetShadow(Jeff2, 0);
  149.     TextDrawSetOutline(Jeff2, 1);
  150.     TextDrawLetterSize(Jeff2, 0.280000, 1.400001);
  151.     TextDrawFont(Jeff2, 3);
  152.     TextDrawAlignment(Jeff2, 2);
  153.     TextDrawSetProportional(Jeff2, 1);
  154.     TextDrawColor(Jeff2, 0x00FFAAFF);
  155.     Jeff3 = TextDrawCreate(170.000000, 173.000000, "Bem vindo a [uD]~n~~n~Aqui pra voce ser bem tratado, voce tem que tratar os outros.~n~~n~Nao tente usar qualquer tipo de cheater, /hack/s0rvete.~n~~n~Tambem devera respeitar os players & adminstradores.~n~~n~Utulize: /Comandos pra saber tudo do servidor.~n~~n~Bom jogo =)!");
  156.     TextDrawSetShadow(Jeff3, 0);
  157.     TextDrawSetOutline(Jeff3, 1);
  158.     TextDrawLetterSize(Jeff3, 0.2904, 0.946);
  159.     TextDrawFont(Jeff3, 1);
  160.     TextDrawSetProportional(Jeff3, 1);
  161.     for(new i; i < MAX_PLAYERS; i++)
  162.  
  163.     Ausente = TextDrawCreate(19.000000, 190.000000, "Voce esta ausente ~p~/afk");
  164.     TextDrawBackgroundColor(Ausente, 65535);
  165.     TextDrawFont(Ausente, 1);
  166.     TextDrawLetterSize(Ausente, 0.500000, 1.000000);
  167.     TextDrawColor(Ausente, 16711935);
  168.     TextDrawSetOutline(Ausente, 0);
  169.     TextDrawSetProportional(Ausente, 1);
  170.     TextDrawSetShadow(Ausente, 1);
  171.     TextDrawUseBox(Ausente, 1);
  172.     TextDrawBoxColor(Ausente, 0x00000066);
  173.     TextDrawTextSize(Ausente, 277.000000, 201.000000);
  174.  
  175.     On = TextDrawCreate(18.000000, 216.000000, "Para voltar ao jogo digite /on");
  176.     TextDrawBackgroundColor(On, 16711935);
  177.     TextDrawFont(On, 1);
  178.     TextDrawLetterSize(On, 0.500000, 1.000000);
  179.     TextDrawColor(On, -16711681);
  180.     TextDrawSetOutline(On, 0);
  181.     TextDrawSetProportional(On, 1);
  182.     TextDrawSetShadow(On, 1);
  183.     TextDrawUseBox(On, 1);
  184.     TextDrawBoxColor(On, 0x00000066);
  185.     TextDrawTextSize(On, 277.000000, 0.000000);
  186.  
  187. Rodape = TextDrawCreate(608.000000, 425.000000, "(/)");//(/)
  188. TextDrawBackgroundColor(Rodape, 255);
  189. TextDrawFont(Rodape, 2);
  190. TextDrawLetterSize(Rodape, 0.159999, 0.800000);
  191. TextDrawColor(Rodape, -1);
  192. TextDrawSetOutline(Rodape, 1);
  193. TextDrawSetProportional(Rodape, 1);
  194. SetTimer("RodapeTimer", 1000, true);
  195.  
  196. SetTimer("atualizar", 3000, 1); //Setimer ira atualizar a cada 300 Mile.
  197. Nome = TextDrawCreate(535.000000, 412.000000, "__");
  198. TextDrawBackgroundColor(Nome, 255);
  199. TextDrawFont(Nome, 0);
  200. TextDrawLetterSize(Nome, 0.519999, 2.399999);
  201. TextDrawColor(Nome, -65281);
  202. TextDrawSetOutline(Nome, 1);
  203. TextDrawSetProportional(Nome, 1);
  204.  
  205.     // ============================ TestDrawEntrada :D PRETO ========================
  206.     topblack = TextDrawCreate(1.000000,-45.000000,"__");
  207.     bottomblack = TextDrawCreate(-2.000000,371.000000,"__");
  208.     TextDrawUseBox(topblack,1);
  209.     TextDrawBoxColor(topblack,0x000000ff);
  210.     TextDrawTextSize(topblack,655.000000,80.000000);
  211.     TextDrawUseBox(bottomblack,1);
  212.     TextDrawBoxColor(bottomblack,0x000000ff);
  213.     TextDrawTextSize(bottomblack,840.000000,240.000000);
  214.     TextDrawAlignment(topblack,0);
  215.     TextDrawAlignment(bottomblack,0);
  216.     TextDrawBackgroundColor(topblack,0x000000ff);
  217.     TextDrawBackgroundColor(bottomblack,0x000000ff);
  218.     TextDrawFont(topblack,3);
  219.     TextDrawLetterSize(topblack,1.000000,14.000000);
  220.     TextDrawFont(bottomblack,3);
  221.     TextDrawLetterSize(bottomblack,1.000000,24.000000);
  222.     TextDrawColor(topblack,0xffffffff);
  223.     TextDrawColor(bottomblack,0xffffffff);
  224.     TextDrawSetOutline(topblack,1);
  225.     TextDrawSetOutline(bottomblack,1);
  226.     TextDrawSetProportional(topblack,1);
  227.     TextDrawSetProportional(bottomblack,1);
  228.     TextDrawSetShadow(topblack,1);
  229.     TextDrawSetShadow(bottomblack,1);
  230.  
  231. Textdraw1 = TextDrawCreate(530.000000, 439.000000, "www.equipe-ud.blogspot.com");
  232. TextDrawBackgroundColor(Textdraw1, 255);
  233. TextDrawFont(Textdraw1, 2);
  234. TextDrawLetterSize(Textdraw1, 0.159999, 0.700000);
  235. TextDrawColor(Textdraw1, -1);
  236. TextDrawSetOutline(Textdraw1, 1);
  237. TextDrawSetProportional(Textdraw1, 1);
  238.  
  239.     for(new i = 0; i < 299; i++)
  240.     {
  241.         switch(i)
  242.         {
  243.             case 3, 4, 5, 6, 7, 8, 42, 53, 64, 74, 86, 91, 149, 208, 273, 289:
  244.             {
  245.                 continue;
  246.             }
  247.         }
  248.         AddPlayerClass(i, 976.6573,-2163.1172,13.1535,359.8774, 0, 0, 0, 0, 0, 0);
  249.     }
  250.  
  251.  
  252.  
  253.  
  254.     SetGameModeText("[uD]- Brasil 2011");
  255.     SendRconCommand("mapname Brasil Drift");
  256.     SendRconCommand("hostname |«»|uD|«»| - Universal Drift™ | 0.3d");
  257.     SetTimer("RandomMSG",150000,1);
  258.     return 1;
  259. }
  260.  
  261. public OnGameModeExit()
  262. {
  263.     return 1;
  264. }
  265. public OnPlayerRequestClass(playerid, classid)
  266. {
  267.     SetPlayerInterior(playerid,0);
  268.     SetPlayerPos(playerid,2028.6447,1551.3442,26.5231);
  269.     SetPlayerFacingAngle(playerid,175.8012);
  270.     SetPlayerCameraPos(playerid,2028.7723,1546.7264,27.4419);
  271.     SetPlayerCameraLookAt(playerid,2028.6447,1551.3442,26.5231);
  272.     ApplyAnimation(playerid, "ON_LOOKERS", "wave_loop", 4.0, 1, 0, 0, 0, 0); // Wave
  273. /*  SetPlayerInterior(playerid,0);
  274.     SetPlayerPos(playerid,-316.7726,1537.8578,79.3660);
  275.     SetPlayerCameraPos(playerid,-318.7147,1540.8372,80.3377);//aqui
  276.     SetPlayerCameraLookAt(playerid,-316.7726,1537.8578,79.3660);
  277.     ApplyAnimation(playerid,"ON_LOOKERS","panic_hide",4.1,0,1,1,1,1);*/
  278.     return 1;
  279. }
  280.  
  281. public OnPlayerConnect(playerid)
  282. {
  283. SendClientMessage(playerid, Cinza,"|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|");
  284. SendClientMessage(playerid, Branco, "- [uD] Usá a versão 1.0 do Gamemode, equipe[uD] sempre inovando!");
  285. SendClientMessage(playerid, Branco, "- Equipe [uD] Agradece sua vísita, tenha um bom jogo!");
  286. SendClientMessage(playerid, Cinza,"|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|__|");
  287. players++;
  288. new nome[24], string[60];
  289. GetPlayerName(playerid, nome, 24);
  290. format(string, 60,"%s Conectou-se no servidor da [uD]. (%d/%d)",nome, players, GetMaxPlayers());
  291. SendClientMessageToAll(Cinza, string);
  292. TextDrawShowForPlayer(playerid, Textdraw1);
  293. TextDrawShowForPlayer(playerid, topblack);
  294. TextDrawShowForPlayer(playerid, bottomblack);
  295. TextDrawShowForPlayer(playerid, Rodape);
  296.     SetTimerEx("DeletarTextodoJeff",100000,0,"i",playerid);
  297.     TextDrawShowForPlayer(playerid, Jeff1);
  298.     TextDrawShowForPlayer(playerid, Jeff2);
  299.     TextDrawShowForPlayer(playerid, Jeff3);
  300.     TogglePlayerControllable(playerid, 0);
  301.     return 1;
  302. }
  303.  
  304. public OnPlayerDisconnect(playerid, reason)
  305. {
  306.     new
  307.         string[64],
  308.         name[MAX_PLAYER_NAME];
  309.     GetPlayerName(playerid,name,MAX_PLAYER_NAME);
  310.     switch(reason)
  311.     {
  312.         case 0: format(string,sizeof string,"%s Saiu da [uD]. | Fail Conexão |",name);
  313.         case 1: format(string,sizeof string,"%s Saiu da [uD]. | Disconectou-se |",name);
  314.         case 2: format(string,sizeof string,"%s Saiu da [uD]. | Kickado/Banido |",name);
  315.     }
  316.     SendClientMessageToAll(Cinza,string);
  317.     TextDrawHideForPlayer(playerid, Nome);
  318.     TextDrawHideForPlayer(playerid, Rodape);
  319.     players--;
  320.     StopAudioStreamForPlayer(playerid);
  321.     return 1;
  322. }
  323.  
  324. public OnPlayerSpawn(playerid)
  325. {
  326.     SendClientMessage(playerid,Cinza,"** Sem veículo ? Ùtilize: /carro [nome] [cor1] [cor2] - Divirta-se. **");
  327.     TextDrawHideForPlayer(playerid, topblack);
  328.     TextDrawHideForPlayer(playerid, bottomblack);
  329.     TextDrawHideForAll(Jeff1);//Desligará o TextDraw De Todos
  330.     TextDrawHideForAll(Jeff2);//Desligará o TextDraw De Todos
  331.     TextDrawHideForAll(Jeff3);//Desligará o TextDraw De Todos
  332.     return 1;
  333. }
  334.  
  335. public OnPlayerDeath(playerid, killerid, reason)
  336. {
  337.     GameTextForPlayer(playerid,"~r~Morreuuu ~b~Playboy!!",1000,1);
  338.     return 1;
  339. }
  340.  
  341. public OnVehicleSpawn(vehicleid)
  342. {
  343.     return 1;
  344. }
  345.  
  346. public OnVehicleDeath(vehicleid, killerid)
  347. {
  348.     return 1;
  349. }
  350.  
  351. public OnPlayerText(playerid, text[])
  352. {
  353.     new string[128];
  354.     format(string, sizeof(string), "(%d) %s", playerid, text);
  355.     SendPlayerMessageToAll(playerid, string);
  356.     SetPlayerChatBubble(playerid, text, 0xFF0000FF, 100.0, 10000);
  357.     return 0;
  358. }
  359.  
  360. public OnPlayerCommandText(playerid, cmdtext[])
  361. {
  362.     new cmd[256];
  363.     new idx;
  364.     new tmp[256];
  365.     new string[256];
  366.     new txt[256];
  367.     cmd = strtok(cmdtext, idx);
  368.  
  369.  
  370. if(strcmp(cmdtext, "/entrandointerior", true) == 0)
  371. {
  372.    if(IsPlayerInRangeOfPoint(playerid, 2.0, 981.474487, -2152.880371, 13.714790))
  373.    {
  374.        SetPlayerInterior(playerid, 12);
  375.        SetPlayerPos(playerid, 2324.419921,-1145.568359,1050.710083);
  376.        SendClientMessage(playerid,Verde,"Você entro na mansão da uD!");
  377.    }
  378.    return true;
  379. }
  380. if(strcmp(cmdtext, "/sairdointerior", true) == 0)
  381. {
  382.    if(IsPlayerInRangeOfPoint(playerid, 2.0, 2324.6113,-1148.4275,1050.7101))
  383.    {
  384.       SetPlayerInterior(playerid, 0);
  385.       SetPlayerPos(playerid, 981.474487, -2152.880371, 13.714790);
  386.       SendClientMessage(playerid,Vermelho,"Você saiu da mansão da uD!");
  387.    }
  388.    return true;
  389. }
  390. if(strcmp("/cruzarbraço", cmd, true) == 0)
  391. {
  392. ApplyAnimation(playerid, "COP_AMBIENT", "Coplook_loop", 4.0, 0, 1, 1, 1, -1);
  393. return 1;
  394. }
  395. if(strcmp("/deitar", cmd, true) == 0)
  396. {
  397. ApplyAnimation(playerid, "BEACH", "bather", 4.0, 1, 0, 0, 0, 0);
  398. return 1;
  399. }
  400. if(strcmp("/abaixar", cmd, true) == 0)
  401. {
  402. ApplyAnimation(playerid, "ped", "cower", 3.0, 1, 0, 0, 0, 0);
  403. return 1;
  404. }
  405. if(strcmp("/fumar", cmd, true) == 0)
  406. {
  407. ApplyAnimation(playerid, "SMOKING", "M_smklean_loop", 4.0, 1, 0, 0, 0, 0);
  408. return 1;
  409. }
  410. if(strcmp("/fumar2", cmd, true) == 0)
  411. {
  412. ApplyAnimation(playerid, "SMOKING", "F_smklean_loop", 4.0, 1, 0, 0, 0, 0);
  413. return 1;
  414. }
  415. if(strcmp("/sentar", cmd, true) == 0)
  416. {
  417. ApplyAnimation(playerid, "BEACH", "ParkSit_M_loop", 4.0, 1, 0, 0, 0, 0);
  418. return 1;
  419. }
  420. if(strcmp("/conversar", cmd, true) == 0)
  421. {
  422. ApplyAnimation(playerid, "PED", "IDLE_CHAT", 4.0, 0, 0, 0, 0, 0);
  423. return 1;
  424. }
  425. //=============================================== CONSTRUINDO ;D ===============================================================
  426. if(strcmp(cmd,"/car",true) ==0 || strcmp(cmd,"/carro",true)==0)
  427.     {
  428.         new VeiculosNomesC[][] =
  429.         {
  430.             "Landstalker","Bravura","Buffalo","Linerunner","Pereniel","Sentinel","Dumper","Firetruck","Trashmaster",
  431.             "Stretch","Manana","Infernus","Voodoo","Pony","Mule","Cheetah","Ambulancia","Leviathan","Moonbeam","Esperanto",
  432.             "Taxi","Washington","Bobcat","Mr Whoopee","BF Injection","Hunter","Premier","Enforcer","Securicar","Banshee",
  433.             "Predator","Bus","Rhino","Barracks","Hotknife","Trailer","Previon","Coach","Cabbie","Stallion","Rumpo",
  434.             "RC Bandit","Romero","Packer","Monster","Admiral","Squalo","Seasparrow","Pizzaboy","Tram","Trailer",
  435.             "Turismo","Speeder","Reefer","Tropic","Flatbed","Yankee","Caddy","Solair","Berkley's RC Van","Skimmer",
  436.             "PCJ-600","Faggio","Freeway","RC Baron","RC Raider","Glendale","Oceanic","Sanchez","Sparrow","Patriot",
  437.             "Quad","Coastguard","Dinghy","Hermes","Sabre","Rustler","ZR-350","Walton","Regina","Comet","BMX",
  438.             "Burrito","Camper","Marquis","Baggage","Dozer","Maverick","News Chopper","Rancher","FBI Rancher","Virgo",
  439.             "Greenwood","Jetmax","Hotring","Sandking","Blista Compact","Maverick Policial","Boxville","Benson","Mesa",
  440.             "RC Goblin","Hotring Racer A","Hotring Racer B","Bloodring Banger","Rancher","Super GT","Elegant",
  441.             "Journey","Bike","Mountain Bike","Beagle","Cropdust","Stunt","Tanker","RoadTrain","Nebula","Majestic",
  442.             "Buccaneer","Shamal","Hydra","FCR-900","NRG-500","HPV1000","Cement Truck","Tow Truck","Fortune","Cadrona",
  443.             "FBI Truck","Willard","Forklift","Tractor","Combine","Feltzer","Remington","Slamvan","Blade","Freight",
  444.             "Streak","Vortex","Vincent","Bullet","Clover","Sadler","Firetruck","Hustler","Intruder","Primo","Cargobob",
  445.             "Tampa","Sunrise","Merit","Utility","Nevada","Yosemite","Windsor","Monster A","Monster B","Uranus",
  446.             "Jester","Sultan","Stratum","Elegy","Raindance","RC Tiger","Flash","Tahoma","Savanna","Bandito","Freight",
  447.             "Trailer","Kart","Mower","Duneride","Sweeper","Broadway","Tornado","AT-400","DFT-30","Huntley","Stafford",
  448.             "BF-400","Newsvan","Tug","Trailer A","Emperor","Wayfarer","Euros","Hotdog","Club","Trailer B","Trailer C",
  449.             "Andromada","Dodo","RC Cam","Launch","Viatura (LSPD)","Viatura (SFPD)","Viatura (LVPD)","Police Ranger",
  450.             "Picador","S.W.A.T. Van","Alpha","Phoenix","Glendale","Sadler","Luggage Trailer A","Luggage Trailer B",
  451.             "Stair Trailer","Boxville","Farm Plow","Utility Trailer"
  452.         };
  453.         tmp = strtok(cmdtext, idx);
  454.         if(!strlen(tmp))
  455.         {
  456.             SendClientMessage(playerid, Verde, "[Info] USO: /carro [nome] [color1] [color2]");
  457.             return 1;
  458.         }
  459.         new carnome[25], bool:have;
  460.         format(carnome, sizeof(carnome), tmp);
  461.         for(new x = 0; x < 212; x++)
  462.         {
  463.             if(!strcmp(carnome,VeiculosNomesC[x],true))
  464.             {
  465.                 have = true;
  466.             }
  467.         }
  468.         if(!have) return SendClientMessage(playerid, Vermelho, "Nome de veículo inválido !");
  469.         tmp = strtok(cmdtext, idx);
  470.         if(!strlen(tmp))
  471.         {
  472.             SendClientMessage(playerid, Verde, "[Info] USO: /car [nome] [color1] [color2]");
  473.             return 1;
  474.         }
  475.         new color1;
  476.         color1 = strval(tmp);
  477.         if(color1 < -1 || color1 > 300) { SendClientMessage(playerid, Vermelho, "   Id's de cores tem que ser entre 0 e 300 !"); return 1; }
  478.         tmp = strtok(cmdtext, idx);
  479.         if(!strlen(tmp))
  480.         {
  481.             SendClientMessage(playerid, Verde, "[Info] USO: /carro [nome] [color1] [color2]");
  482.             return 1;
  483.         }
  484.         new color2;
  485.         color2 = strval(tmp);
  486.         if(color2 < -1 || color2 > 300) { SendClientMessage(playerid, Vermelho, "Id's de cores tem que ser entre 0 e 300 !"); return 1; }
  487.         new carval;
  488.         for(new y = 0; y < 212; y++)
  489.         {
  490.             if(!strcmp(carnome,VeiculosNomesC[y],true)) carval = (y+400);
  491.         }
  492.         if(IsPlayerInAnyVehicle(playerid)) DestroyVehicle(GetPlayerVehicleID(playerid));
  493.         if(carro[playerid] != 0) DestroyVehicle(carro[playerid]);
  494.         new Float:x, Float:y, Float:z; GetPlayerPos(playerid, x,y,z);
  495.         new carid = CreateVehicle(carval, x,y,z, 0.0, color1, color2, 888);
  496.         PutPlayerInVehicle(playerid, carid, 0);
  497.         format(string, sizeof(string), "[Info] Veículo [ID] %d, criado.", carid);
  498.         SendClientMessage(playerid, Verde, string);
  499.         return 1;
  500.     }
  501. if(strcmp(cmdtext,"/mansao", true) == 0)
  502. {
  503. new VehicleID;
  504. new pname[MAX_PLAYER_NAME];
  505. if(!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, 0xC9170EFF, "[ERROR]: Você precisa estár em um veículo.");
  506. GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  507. format(string, sizeof(string),"%s Foi pra mansão da uD. (/Mansão)", pname);
  508. SendClientMessageToAll(Verde, string);
  509. VehicleID = GetPlayerVehicleID(playerid);
  510. SetVehiclePos(VehicleID, 976.6573,-2163.1172,13.1535);
  511. SetVehicleZAngle(GetPlayerVehicleID(playerid), 0.0);
  512. SetPlayerInterior(playerid,0);
  513. return 1;
  514. }
  515.  
  516. if(strcmp(cmdtext,"/sf", true) == 0)
  517. {
  518.   new VehicleID;
  519.    new pname[MAX_PLAYER_NAME];
  520.   if(!IsPlayerInAnyVehicle(playerid))  return SendClientMessage(playerid, 0xC9170EFF, "[ERROR]: Você precisar estár em um veículo.");
  521.   GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  522.   format(string, sizeof(string),"%s Foi pra cidade de San Fierro (/Sf)", pname);
  523.     SendClientMessageToAll(Verde, string);
  524.     VehicleID = GetPlayerVehicleID(playerid);
  525.     SetVehiclePos(VehicleID, -1973.3356,288.3230,34.8320);
  526.     SetVehicleZAngle(GetPlayerVehicleID(playerid), 0.0);
  527.     SetPlayerInterior(playerid,0);
  528.   return 1;
  529. }
  530. if(strcmp(cmdtext,"/lv", true) == 0)
  531. {
  532.   new VehicleID;
  533.    new pname[MAX_PLAYER_NAME];
  534.   if(!IsPlayerInAnyVehicle(playerid))  return SendClientMessage(playerid, 0xC9170EFF, "[ERROR]: Você precisar estár em um veículo.");
  535.   GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  536.   format(string, sizeof(string),"%s Foi pra cidade de Las Venturas (/Lv)", pname);
  537.     SendClientMessageToAll(Verde, string);
  538.     VehicleID = GetPlayerVehicleID(playerid);
  539.     SetVehiclePos(VehicleID, 1692.8406,1434.9109,10.3291);
  540.     SetVehicleZAngle(GetPlayerVehicleID(playerid), 0.0);
  541.     SetPlayerInterior(playerid,0);
  542.   return 1;
  543. }
  544. if(strcmp(cmdtext,"/ls", true) == 0)
  545. {
  546.   new VehicleID;
  547.    new pname[MAX_PLAYER_NAME];
  548.   if(!IsPlayerInAnyVehicle(playerid))  return SendClientMessage(playerid, 0xC9170EFF, "[ERROR]: Você precisar estár em um veículo.");
  549.   GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  550.   format(string, sizeof(string),"%s Foi pra cidade de Los Santos (/Ls)", pname);
  551.     SendClientMessageToAll(Verde, string);
  552.     VehicleID = GetPlayerVehicleID(playerid);
  553.     SetVehiclePos(VehicleID, 1601.3708,-1624.0551,13.1385);
  554.     SetVehicleZAngle(GetPlayerVehicleID(playerid), 0.0);
  555.     SetPlayerInterior(playerid,0);
  556.   return 1;
  557. }
  558. if(strcmp(cmdtext,"/ud1", true) == 0)
  559. {
  560.   new VehicleID;
  561.    new pname[MAX_PLAYER_NAME];
  562.   if(!IsPlayerInAnyVehicle(playerid))  return SendClientMessage(playerid, 0xC9170EFF, "[ERROR]: Você precisar estár em um veículo.");
  563.   GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  564.   format(string, sizeof(string),"%s Foi pro /UD1 Pista Oficial", pname);
  565.     SendClientMessageToAll(Verde, string);
  566.     VehicleID = GetPlayerVehicleID(playerid);
  567.     SetVehiclePos(VehicleID, -364.7623,1532.6614,75.3594);
  568.     SetVehicleZAngle(GetPlayerVehicleID(playerid), 0.0);
  569.     SetPlayerInterior(playerid,0);
  570.   return 1;
  571. }
  572. if(strcmp(cmdtext,"/ud2", true) == 0)
  573. {
  574.   new VehicleID;
  575.    new pname[MAX_PLAYER_NAME];
  576.   if(!IsPlayerInAnyVehicle(playerid))  return SendClientMessage(playerid, 0xC9170EFF, "[ERROR]: Você precisar estár em um veículo.");
  577.   GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  578.   format(string, sizeof(string),"%s Foi pro /UD2 Pista de drift", pname);
  579.     SendClientMessageToAll(Verde, string);
  580.     VehicleID = GetPlayerVehicleID(playerid);
  581.     SetVehiclePos(VehicleID, 1255.3643,-2033.8282,59.5524);
  582.     SetVehicleZAngle(GetPlayerVehicleID(playerid), 0.0);
  583.     SetPlayerInterior(playerid,0);
  584.   return 1;
  585. }
  586. if(strcmp(cmdtext,"/ud3", true) == 0)
  587. {
  588.   new VehicleID;
  589.    new pname[MAX_PLAYER_NAME];
  590.   if(!IsPlayerInAnyVehicle(playerid))  return SendClientMessage(playerid, 0xC9170EFF, "[ERROR]: Você precisar estár em um veículo.");
  591.   GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  592.   format(string, sizeof(string),"%s Foi pro /UD3 Pista de drift", pname);
  593.     SendClientMessageToAll(Verde, string);
  594.     VehicleID = GetPlayerVehicleID(playerid);
  595.     SetVehiclePos(VehicleID, 2262.9102,1398.5728,42.8203);
  596.     SetVehicleZAngle(GetPlayerVehicleID(playerid), 0.0);
  597.     SetPlayerInterior(playerid,0);
  598.   return 1;
  599. }
  600. if(strcmp(cmdtext,"/ud4", true) == 0)
  601. {
  602.   new VehicleID;
  603.    new pname[MAX_PLAYER_NAME];
  604.   if(!IsPlayerInAnyVehicle(playerid))  return SendClientMessage(playerid, 0xC9170EFF, "[ERROR]: Você precisar estár em um veículo.");
  605.   GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  606.   format(string, sizeof(string),"%s Foi pro /UD4 Pista de drift", pname);
  607.     SendClientMessageToAll(Verde, string);
  608.     VehicleID = GetPlayerVehicleID(playerid);
  609.     SetVehiclePos(VehicleID, 2226.2451,1978.7045,31.7797);
  610.     SetVehicleZAngle(GetPlayerVehicleID(playerid), 0.0);
  611.     SetPlayerInterior(playerid,0);
  612.   return 1;
  613. }
  614.     if(!strcmp(cmd,"/pm",true))
  615.     {
  616.         tmp = strtok(cmdtext, idx);
  617.         if(!strlen(tmp))
  618.         return SendClientMessage(playerid,0xFF0000AA,"[USO CORRETO] /pm [playerid] [mensagem]");
  619.         new id = strval(tmp);
  620.         if(id == playerid)
  621.         {
  622.             SendClientMessage(playerid,0xFF0000AA,"[ERRO] Você não pode enviar PM pra você mesmo.");
  623.             return 1;
  624.         }
  625.         if(IsPlayerConnected(id)){
  626.             //new txt[256];
  627.             txt = strtok(cmdtext,idx);
  628.             if(!strlen(txt))
  629.             return SendClientMessage(playerid,0xFF0000AA,"[USO CORRETO] /pm [playerid] [mensagem]");
  630.             new pName[MAX_PLAYER_NAME],RecName[MAX_PLAYER_NAME];
  631.             GetPlayerName(id, RecName, sizeof(RecName));
  632.             GetPlayerName(playerid, pName, sizeof(pName));
  633.             GetPlayerName(playerid, pName, sizeof(pName));
  634.             GetPlayerName(id, RecName, sizeof(RecName));
  635.             new length = strlen(cmdtext);
  636.             while ((idx < length) && (cmdtext[idx] <= ' '))
  637.             {
  638.                 idx++;
  639.             }
  640.             new offset = idx;
  641.             new result[64];
  642.             while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
  643.             {
  644.                 result[idx - offset] = cmdtext[idx];
  645.                 idx++;
  646.             }
  647.             result[idx - offset] = EOS;
  648.             for(new luplay=0;luplay<6;luplay++){
  649.             PlayerPlaySound(playerid,1057,0.0,0.0,0.0);
  650.             PlayerPlaySound(id,1057,0.0,0.0,0.0);
  651.             format(string, sizeof(string), "[PM] Recebida de %s(%i): %s", pName, playerid, cmdtext[1]);
  652.             SendClientMessage(id,0xFFFF00AA, string);
  653.             format(string, sizeof(string), "[PM] Enviada para %s(%i): %s", RecName, id, cmdtext[1]);
  654.             SendClientMessage(playerid,0xFFFF00AA, string);}
  655.  
  656.             } else {
  657.             SendClientMessage(playerid,0xFF0000AA,"[ERRO] O jogador não está conectado.");
  658.         }
  659.         return 0;
  660.     }
  661.     if(strcmp(cmd, "/afk", true) == 0)
  662.         {
  663.         if(Afk[playerid]==0)
  664.         {
  665.         Afk[playerid]=1;
  666.         SetPlayerVirtualWorld(playerid, 1);
  667.         SetCameraBehindPlayer(playerid);
  668.         TogglePlayerControllable(playerid,0);
  669.         TextDrawShowForPlayer(playerid,Ausente);
  670.         TextDrawShowForPlayer(playerid,On);
  671.         new Ausentes[200];
  672.         GetPlayerName(playerid, Ausentes, 30);
  673.         format(string, 256, "%s Esta Ausente /afk.", Ausentes);
  674.         SendClientMessageToAll( 0x00FFFFAA, string);
  675.         }else{
  676.         SendClientMessage(playerid,0xF60000AA,"(ERRO) Você já está no modo AFK!");
  677.         return 1;
  678.         }
  679.         return 1;
  680.         }
  681.     if(strcmp(cmd, "/on", true) == 0)
  682.         {
  683.         if(Afk[playerid]==1)
  684.         {
  685.         Afk[playerid]=0;
  686.         SetPlayerVirtualWorld(playerid, 0);
  687.         TogglePlayerControllable(playerid,1);
  688.         TextDrawHideForPlayer(playerid,Ausente);
  689.         TextDrawHideForPlayer(playerid,On);
  690.         new Onli[200];
  691.         GetPlayerName(playerid, Onli, 30);
  692.         format(string, 256, "%s Voltou ao Jogo.", Onli);
  693.         SendClientMessageToAll( 0x00FFFFAA, string);
  694.         }else{
  695.         SendClientMessage(playerid,0xF60000AA,"(ERRO) Você não está Afk!");
  696.         return 1;
  697.         }
  698.         return 1;
  699.     }
  700.  
  701. if(strcmp(cmd, "/goto", true) == 0)
  702.     {
  703.         tmp = strtok(cmdtext, idx);
  704.         new Float:X, Float:Y, Float:Z, PlayerB;
  705.         if(!strlen(tmp)) return SendClientMessage(playerid, Vermelho, "Uso correto: /goto [id]");
  706.         PlayerB = strval(tmp);
  707.         if(!IsPlayerConnected(PlayerB)) return SendClientMessage(playerid, Vermelho, "Este jogador não está online.");
  708.         GetPlayerPos(PlayerB, X, Y, Z);
  709.         SetPlayerPos(playerid, X, Y+1, Z);
  710.         if(GetPlayerState(playerid) == 2)
  711.         {
  712.             new carrro = GetPlayerVehicleID(playerid);
  713.             SetVehiclePos(carrro, X, Y+1, Z);
  714.             PutPlayerInVehicle(playerid, carrro, 0);
  715.         }
  716.         format(string, sizeof(string), "Você foi até o jogador %s.", pNome(PlayerB));
  717.         SendClientMessage(playerid, Verde, string);
  718.         format(string, sizeof(string), "O Player %s foi até você.", pNome(playerid));
  719.         SendClientMessage(PlayerB, Verde, string);
  720.         return 1;
  721. }
  722.        if (strcmp("/creditos", cmdtext, true, 10) == 0)
  723.     {
  724.       new creditos[3000];
  725.       strins(creditos,"\n",strlen(creditos));
  726.       strins(creditos,"Gamemode Criado por: .CrazZy._.\nDonos:  [uD].CrazZy._. & \nScripter: .CrazZy._.\nsite: seu site\nContato: Jefferson.pipo@hotmail.com\n",strlen(creditos));
  727.       strins(creditos,"\n",strlen(creditos));
  728.       ShowPlayerDialog(playerid,8439, DIALOG_STYLE_MSGBOX, " -----------  Créditos  ----------- ",creditos, "Ok","Fechar");
  729.       return 1;
  730.      }
  731.     if(strcmp("/Mundo", cmdtext, true, 10) == 0)
  732.     {
  733.         ShowPlayerDialog(playerid,Mundo,DIALOG_STYLE_LIST,"Escolha um mundo:","|uD| Mundo 0 - Principal\n|uD| Mundo 1 - Alternativo\n|uD| Mundo 2 - Alternativo\n|uD| Mundo 3 - Alternativo\n|uD| Mundo 4 - Alternativo\n|uD| Mundo 5 - Alternativo","OK","Fechar");
  734.         return 1;
  735.     }
  736.         if(strcmp(cmdtext, "/aerolv", true) == 0)
  737.         {
  738.         new cartype = GetPlayerVehicleID(playerid);
  739.         new State=GetPlayerState(playerid);
  740.         SetPlayerInterior(playerid,0);
  741.         {
  742.         if(State!=PLAYER_STATE_DRIVER)
  743.         {
  744.         SetPlayerPos(playerid,1508.4031,1449.0800,10.8494);
  745.         }
  746.         else if(IsPlayerInVehicle(playerid, cartype) == 1)
  747.         {
  748.         SetVehiclePos(cartype,1508.4031,1449.0800,10.8494);
  749.         SetVehicleZAngle(cartype,30.6101);}
  750.         else
  751.         {
  752.         SetPlayerPos(playerid,1508.4031,1449.0800,10.8494);
  753.         }
  754.         new pname[MAX_PLAYER_NAME];
  755.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  756.         format(string, sizeof(string), "%s Foi pro Aeroporto de Lv (/Aerolv)", pname);
  757.         SendClientMessageToAll(0x80FF00FF, string);
  758.         }
  759.         return 1;
  760.         }
  761.     if(strcmp(cmdtext, "/aerols", true) == 0)
  762.         {
  763.         new cartype = GetPlayerVehicleID(playerid);
  764.         new State=GetPlayerState(playerid);
  765.         SetPlayerInterior(playerid,0);
  766.         {
  767.         if(State!=PLAYER_STATE_DRIVER)
  768.         {
  769.         SetPlayerPos(playerid,1832.2773,-2474.8826,13.5547);
  770.         }
  771.         else if(IsPlayerInVehicle(playerid, cartype) == 1)
  772.         {
  773.         SetVehiclePos(cartype,1832.2773,-2474.8826,13.5547);
  774.         SetVehicleZAngle(cartype,189.0651);}
  775.         else
  776.         {
  777.         SetPlayerPos(playerid,1832.2773,-2474.8826,13.5547);
  778.         }
  779.         new pname[MAX_PLAYER_NAME];
  780.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  781.         format(string, sizeof(string), "%s Foi pro Aeroporto de LS (/Aerols)", pname);
  782.         SendClientMessageToAll(0x80FF00FF, string);
  783.         }
  784.         return 1;
  785.         }
  786.  
  787.     if(strcmp(cmdtext, "/aerosf", true) == 0)
  788.        {
  789.        new cartype = GetPlayerVehicleID(playerid);
  790.        new State=GetPlayerState(playerid);
  791.        SetPlayerInterior(playerid,0);
  792.        {
  793.        if(State!=PLAYER_STATE_DRIVER)
  794.        {
  795.        SetPlayerPos(playerid,-1444.3123,31.4322,14.1484);
  796.        }
  797.        else if(IsPlayerInVehicle(playerid, cartype) == 1)
  798.        {
  799.        SetVehiclePos(cartype,-1444.3123,31.4322,14.1484);
  800.        SetVehicleZAngle(cartype,30.6101);}
  801.        else
  802.        {
  803.        SetPlayerPos(playerid,-1444.3123,31.4322,14.1484);
  804.        }
  805.        new pname[MAX_PLAYER_NAME];
  806.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  807.         format(string, sizeof(string), "%s Foi pro Aeroporto de SF (/Aerosf)", pname);
  808.         SendClientMessageToAll(0x80FF00FF, string);
  809.        }
  810.        return 1;
  811.        }
  812.            if(strcmp(cmdtext, "/ps", true) == 0)
  813.        {
  814.        new cartype = GetPlayerVehicleID(playerid);
  815.        new State=GetPlayerState(playerid);
  816.        SetPlayerInterior(playerid,0);
  817.        {
  818.        if(State!=PLAYER_STATE_DRIVER)
  819.        {
  820.        SetPlayerPos(playerid,3747.6513671875, -1226.2119140625, 223.36529541016);
  821.        }
  822.        else if(IsPlayerInVehicle(playerid, cartype) == 1)
  823.        {
  824.        SetVehiclePos(cartype,3747.6513671875, -1226.2119140625, 223.36529541016);
  825.        SetVehicleZAngle(cartype,30.6101);}
  826.        else
  827.        {
  828.        SetPlayerPos(playerid,3747.6513671875, -1226.2119140625, 223.36529541016);
  829.        }
  830.        new pname[MAX_PLAYER_NAME];
  831.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  832.         format(string, sizeof(string), "%s Foi Correr na Pista speed (/Ps)", pname);
  833.         SendClientMessageToAll(0x80FF00FF, string);
  834.        }
  835.        return 1;
  836.        }
  837.       if(strcmp(cmd, "/skin", true) == 0)
  838.        {
  839.         tmp = strtok(cmdtext, idx);
  840.         if(!strlen(tmp)) return SendClientMessage(playerid, Vermelho, "[USO CORRETO] /skin [skinid]");
  841.         if(strval(tmp) < 0 || strval(tmp) > 299) return SendClientMessage(playerid, Vermelho, "[ERRO] O ID das skins são de 0 até 299!");
  842.         SendClientMessage(playerid, Verde, "[INFO] Skin alterado Com sucesso!");
  843.         SetPlayerSkin(playerid, strval(tmp));
  844.         return 1;
  845.     }
  846.         if (strcmp(cmdtext, "/cores", true) == 0){
  847. if(!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, 0xC9170EFF, "[ERROR]: Você Não Esta Em Um Veículo!!");
  848. ShowPlayerDialog(playerid, Cores, DIALOG_STYLE_LIST, "Menu Cores", "[ Preta ]\n[ Branca ]\n[ Azul Escuro ]\n[ Azul Claro ]\n[ Verde ]\n[ Vermelho ]\n[ Amarelho ]", "OK", "Sair");
  849. return 1;
  850. }
  851.     if(strcmp(cmdtext,"/x",true)==0) //GetVehicleZAngle(vehicleid, &Float:z_angle);
  852.     {
  853.     if(IsPlayerInAnyVehicle(playerid)){
  854.     new Float:plocx,Float:plocy,Float:plocz;
  855.     GetVehiclePos(GetPlayerVehicleID(playerid), plocx, plocy, plocz);
  856.     SetVehicleZAngle(GetPlayerVehicleID(playerid),plocz);}
  857.     SendClientMessage(playerid,Verde, "INFO: Você virou seu Veiculo com sucesso!");
  858.     PlayerPlaySound(playerid, 1137 , 0.0, 0.0, 0.0);
  859.     return 1;
  860.     }
  861. if (strcmp("/sp", cmdtext, true, 10) == 0){
  862. GetPlayerPos(playerid, PosX[playerid], PosY[playerid], PosZ[playerid]);
  863. GetPlayerFacingAngle(playerid, PosA[playerid]);
  864. SendClientMessage(playerid, 0x57E427AA, "[INFO]: Sua posição foi salva, para voltar use: /irp");
  865. PosI[playerid] = (GetPlayerInterior(playerid));
  866. PlayerPlaySound(playerid, 1137 , 0.0, 0.0, 0.0);
  867. return 1;
  868. }
  869. if (strcmp("/irp", cmdtext, true, 10) == 0){
  870. if (!floatsqroot(PosX[playerid]+PosY[playerid]+PosZ[playerid]))
  871. {
  872. SendClientMessage(playerid, 0xF60000AA, "[ERRO] Você não tem nenhuma posição salva.");
  873. }
  874. else
  875. {
  876. if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
  877. {
  878. SetVehiclePos(GetPlayerVehicleID(playerid), PosX[playerid], PosY[playerid], PosZ[playerid]);
  879. SetVehicleZAngle(GetPlayerVehicleID(playerid), PosA[playerid]);
  880. SetCameraBehindPlayer(playerid);
  881. LinkVehicleToInterior(GetPlayerVehicleID(playerid), PosI[playerid]);
  882. }
  883.  else
  884. {
  885. EnCoche[playerid] = false;
  886. SetPlayerPos(playerid, PosX[playerid], PosY[playerid], PosZ[playerid]);
  887. SetPlayerFacingAngle(playerid, PosA[playerid]);
  888. SetCameraBehindPlayer(playerid);
  889. }
  890. PlayerPlaySound(playerid, 1085, 0.0, 0.0, 0.0);
  891. SetPlayerInterior(playerid, PosI[playerid]);
  892. SendClientMessage(playerid, 0x008040FF, "Você se teleportou para a ultima posição salva.");
  893. }
  894. return 1;
  895. }
  896. /*    if(!strcmp(cmdtext, "/elegy", true))
  897.     {
  898.         if(IsPlayerInAnyVehicle(playerid)) DestroyVehicle(GetPlayerVehicleID(playerid));
  899.         if(carro[playerid] != 0) DestroyVehicle(carro[playerid]);
  900.         new Float:x, Float:y, Float:z; GetPlayerPos(playerid, x,y,z);
  901.         carro[playerid] = CreateVehicle(562, x,y,z, 0.0, -1, -1, 888);
  902.         PutPlayerInVehicle(playerid, carro[playerid], 0);
  903.         SendClientMessage(playerid,Verde,"INFO: Você Spawnou um Elegy!");
  904.         return 1;
  905.     }
  906.     if(!strcmp(cmdtext, "/infernus", true))
  907.     {
  908.         if(IsPlayerInAnyVehicle(playerid)) DestroyVehicle(GetPlayerVehicleID(playerid));
  909.         if(carro[playerid] != 0) DestroyVehicle(carro[playerid]);
  910.         new Float:x, Float:y, Float:z; GetPlayerPos(playerid, x,y,z);
  911.         carro[playerid] = CreateVehicle(411, x,y,z, 0.0, -1, -1, 888);
  912.         PutPlayerInVehicle(playerid, carro[playerid], 0);
  913.         SendClientMessage(playerid,Verde,"INFO: Você Spawnou um Infernus!");
  914.         return 1;
  915.     }
  916.     if(!strcmp(cmdtext, "/bus", true))
  917.     {
  918.         if(IsPlayerInAnyVehicle(playerid)) DestroyVehicle(GetPlayerVehicleID(playerid));
  919.         if(carro[playerid] != 0) DestroyVehicle(carro[playerid]);
  920.         new Float:x, Float:y, Float:z; GetPlayerPos(playerid, x,y,z);
  921.         carro[playerid] = CreateVehicle(431, x,y,z, 0.0, -1, -1, 888);
  922.         PutPlayerInVehicle(playerid, carro[playerid], 0);
  923.         SendClientMessage(playerid,Verde,"INFO: Você Spawnou um Bus!");
  924.         return 1;
  925.     }
  926.     if(!strcmp(cmdtext, "/nrg500", true))
  927.     {
  928.         if(IsPlayerInAnyVehicle(playerid)) DestroyVehicle(GetPlayerVehicleID(playerid));
  929.         if(carro[playerid] != 0) DestroyVehicle(carro[playerid]);
  930.         new Float:x, Float:y, Float:z; GetPlayerPos(playerid, x,y,z);
  931.         carro[playerid] = CreateVehicle(522, x,y,z, 0.0, -1, -1, 888);
  932.         PutPlayerInVehicle(playerid, carro[playerid], 0);
  933.         SendClientMessage(playerid,Verde,"INFO: Você Spawnou uma Nrg500!");
  934.         return 1;
  935.     }
  936.         if(!strcmp(cmdtext, "/sultan", true))
  937.     {
  938.         if(IsPlayerInAnyVehicle(playerid)) DestroyVehicle(GetPlayerVehicleID(playerid));
  939.         if(carro[playerid] != 0) DestroyVehicle(carro[playerid]);
  940.         new Float:x, Float:y, Float:z; GetPlayerPos(playerid, x,y,z);
  941.         carro[playerid] = CreateVehicle(560, x,y,z, 0.0, -1, -1, 888);
  942.         PutPlayerInVehicle(playerid, carro[playerid], 0);
  943.         SendClientMessage(playerid,Verde,"INFO: Você Spawnou um Sultan!");
  944.         return 1;
  945.     }
  946.             if(!strcmp(cmdtext, "/flash", true))
  947.     {
  948.         if(IsPlayerInAnyVehicle(playerid)) DestroyVehicle(GetPlayerVehicleID(playerid));
  949.         if(carro[playerid] != 0) DestroyVehicle(carro[playerid]);
  950.         new Float:x, Float:y, Float:z; GetPlayerPos(playerid, x,y,z);
  951.         carro[playerid] = CreateVehicle(565, x,y,z, 0.0, -1, -1, 888);
  952.         PutPlayerInVehicle(playerid, carro[playerid], 0);
  953.         SendClientMessage(playerid,Verde,"INFO: Você Spawnou um Flash!");
  954.         return 1;
  955.     }
  956.             if(!strcmp(cmdtext, "/savanna", true))
  957.     {
  958.         if(IsPlayerInAnyVehicle(playerid)) DestroyVehicle(GetPlayerVehicleID(playerid));
  959.         if(carro[playerid] != 0) DestroyVehicle(carro[playerid]);
  960.         new Float:x, Float:y, Float:z; GetPlayerPos(playerid, x,y,z);
  961.         carro[playerid] = CreateVehicle(567, x,y,z, 0.0, -1, -1, 888);
  962.         PutPlayerInVehicle(playerid, carro[playerid], 0);
  963.         SendClientMessage(playerid,Verde,"INFO: Você Spawnou um Savanna!");
  964.         return 1;
  965.     }
  966.                 if(!strcmp(cmdtext, "/picador", true))
  967.     {
  968.         if(IsPlayerInAnyVehicle(playerid)) DestroyVehicle(GetPlayerVehicleID(playerid));
  969.         if(carro[playerid] != 0) DestroyVehicle(carro[playerid]);
  970.         new Float:x, Float:y, Float:z; GetPlayerPos(playerid, x,y,z);
  971.         carro[playerid] = CreateVehicle(600, x,y,z, 0.0, -1, -1, 888);
  972.         PutPlayerInVehicle(playerid, carro[playerid], 0);
  973.         SendClientMessage(playerid,Verde,"INFO: Você Spawnou um Picador!");
  974.         return 1;
  975.     }*/
  976. if(!strcmp("/Comandos", cmdtext, true))
  977. {
  978.       ShowPlayerDialog(playerid, Comandos, DIALOG_STYLE_LIST, "INFO: Oquê você deseja fazer ?", "» Comandos\n» Teletransporte\n» Ajuda\n» Regras\n» Eventos\n» MudarCor\n» Horarios\n» Pistas de Drift", "Selecionar", "Sair");
  979.     return 1;
  980. }
  981. if(!strcmp("/textradio", cmdtext ,true))
  982. {
  983.      ShowPlayerDialog(playerid, Musicas, DIALOG_STYLE_LIST, "INFO: Escolha alguma música!", "TestexD", "Selecionar", "Sair");
  984.      return 1;
  985. }
  986.     return SendClientMessage(playerid,Vermelho,"ERRO: » Este comando é inexistente: /Comandos.");
  987. }
  988.  
  989. public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
  990. {
  991.     SendClientMessage(playerid, Cinza, "[INFO]: Este Servidor Possui Sistema Anti-Roubo, Caso Roubar Será Morto Automaticamente !");
  992.     if(!ispassenger && IsVehicleOccupied(vehicleid)) SetPlayerHealth(playerid, 0.0);
  993.     return 1;
  994. }
  995.  
  996.     stock IsVehicleOccupied(vehicleid)
  997.     {
  998.     for(new i = 0; i < MAX_PLAYERS; i++)
  999.     if(IsPlayerInVehicle(i, vehicleid) && GetPlayerState(i) == PLAYER_STATE_DRIVER)
  1000.     return 1;
  1001.     return 0;
  1002. }
  1003.  
  1004. public OnPlayerExitVehicle(playerid, vehicleid)
  1005. {
  1006.     return 1;
  1007. }
  1008.  
  1009. public OnPlayerStateChange(playerid, newstate, oldstate)
  1010. {
  1011.     new str[256];
  1012.     new oldnew;
  1013.     if (newstate == 2 || newstate == 3)
  1014.     {
  1015.     if (oldnew == 0)
  1016.         {
  1017.         format(str, sizeof(str), "~g~%s",vehName[GetVehicleModel(GetPlayerVehicleID(playerid))-400]);
  1018.         GameTextForPlayer(playerid, str, 6000, 1);
  1019.         }
  1020.     }
  1021.         for(new i = 0; i < sizeof(AdmCars); i ++)
  1022.         {
  1023.             new vehicleid = GetPlayerVehicleID(playerid);
  1024.             if(vehicleid == AdmCars[i])
  1025.             {
  1026.                 if(!IsPlayerAdmin(playerid))
  1027.                 {
  1028.                     SendClientMessage(playerid,Vermelho,"{FF3D3D}[ERRO]{FFFFFF} Você não é Admin.");
  1029.                     TogglePlayerControllable(playerid, 1);
  1030.                     RemovePlayerFromVehicle(playerid);
  1031.                 }
  1032.             }
  1033.         }
  1034.     return 1;
  1035. }
  1036.  
  1037. public OnPlayerEnterCheckpoint(playerid)
  1038. {
  1039.     return 1;
  1040. }
  1041.  
  1042. public OnPlayerLeaveCheckpoint(playerid)
  1043. {
  1044.     return 1;
  1045. }
  1046.  
  1047. public OnPlayerEnterRaceCheckpoint(playerid)
  1048. {
  1049.     return 1;
  1050. }
  1051.  
  1052. public OnPlayerLeaveRaceCheckpoint(playerid)
  1053. {
  1054.     return 1;
  1055. }
  1056.  
  1057. public OnRconCommand(cmd[])
  1058. {
  1059.     return 1;
  1060. }
  1061.  
  1062. public OnPlayerRequestSpawn(playerid)
  1063. {
  1064.     return 1;
  1065. }
  1066.  
  1067. public OnObjectMoved(objectid)
  1068. {
  1069.     return 1;
  1070. }
  1071.  
  1072. public OnPlayerObjectMoved(playerid, objectid)
  1073. {
  1074.     return 1;
  1075. }
  1076.  
  1077. public OnPlayerPickUpPickup(playerid, pickupid)
  1078. {
  1079.     return 1;
  1080. }
  1081.  
  1082. public OnVehicleMod(playerid, vehicleid, componentid)
  1083. {
  1084.     return 1;
  1085. }
  1086.  
  1087. public OnVehiclePaintjob(playerid, vehicleid, paintjobid)
  1088. {
  1089.     return 1;
  1090. }
  1091.  
  1092. public OnVehicleRespray(playerid, vehicleid, color1, color2)
  1093. {
  1094.     return 1;
  1095. }
  1096.  
  1097. public OnPlayerSelectedMenuRow(playerid, row)
  1098. {
  1099.     return 1;
  1100. }
  1101.  
  1102. public OnPlayerExitedMenu(playerid)
  1103. {
  1104.     return 1;
  1105. }
  1106.  
  1107. public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
  1108. {
  1109.     return 1;
  1110. }
  1111.  
  1112. public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
  1113. {
  1114.    if((oldkeys & 1 || oldkeys & 4))
  1115.     {
  1116.         Nitro(playerid);
  1117.     }
  1118. if ((newkeys==KEY_SECONDARY_ATTACK)) // Key ( F / Enter )
  1119. {
  1120.    OnPlayerCommandText(playerid,"/entrandointerior"); // Ao Apertar "F" Funcionará o Comando Do Lado.
  1121.    OnPlayerCommandText(playerid,"/sairdointerior"); // Ao Apertar "F" Funcionará o Comando Do Lado.
  1122.    }
  1123.    return 1;
  1124.     // Se Quiser Colocar mais, a vontade.
  1125. }
  1126.  
  1127. public OnRconLoginAttempt(ip[], password[], success)
  1128. {
  1129.     return 1;
  1130. }
  1131.  
  1132. public OnPlayerUpdate(playerid)
  1133. {
  1134.     RepairVehicle(GetPlayerVehicleID(playerid));
  1135.     SetPlayerScore(playerid, GetPlayerMoney(playerid));
  1136.     return 1;
  1137. }
  1138.  
  1139. public OnPlayerStreamIn(playerid, forplayerid)
  1140. {
  1141.     return 1;
  1142. }
  1143.  
  1144. public OnPlayerStreamOut(playerid, forplayerid)
  1145. {
  1146.     return 1;
  1147. }
  1148.  
  1149. public OnVehicleStreamIn(vehicleid, forplayerid)
  1150. {
  1151.     return 1;
  1152. }
  1153.  
  1154. public OnVehicleStreamOut(vehicleid, forplayerid)
  1155. {
  1156.     return 1;
  1157. }
  1158.  
  1159. public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
  1160. {
  1161.         if(dialogid == Cores) // CORES
  1162. {
  1163. if(response)
  1164. {
  1165. if(listitem == 0)
  1166. {
  1167. ChangeVehicleColor(GetPlayerVehicleID(playerid),0,0);
  1168. PlayerPlaySound(playerid,1133,0.0,0.0,0.0);
  1169. }
  1170. if(listitem == 1)
  1171. {
  1172. ChangeVehicleColor(GetPlayerVehicleID(playerid),1,1);
  1173. PlayerPlaySound(playerid,1133,0.0,0.0,0.0);
  1174. }
  1175. if(listitem == 2)
  1176. {
  1177. ChangeVehicleColor(GetPlayerVehicleID(playerid),425,425);
  1178. PlayerPlaySound(playerid,1133,0.0,0.0,0.0);
  1179. }
  1180. if(listitem == 3)
  1181. {
  1182. ChangeVehicleColor(GetPlayerVehicleID(playerid),2,2);
  1183. PlayerPlaySound(playerid,1133,0.0,0.0,0.0);
  1184. }
  1185. if(listitem == 4)
  1186. {
  1187. ChangeVehicleColor(GetPlayerVehicleID(playerid),16,16);
  1188. PlayerPlaySound(playerid,1133,0.0,0.0,0.0);
  1189. }
  1190. if(listitem == 5)
  1191. {
  1192. ChangeVehicleColor(GetPlayerVehicleID(playerid),3,3);
  1193. PlayerPlaySound(playerid,1133,0.0,0.0,0.0);
  1194. }
  1195. if(listitem == 6)
  1196. {
  1197. ChangeVehicleColor(GetPlayerVehicleID(playerid),6,6);
  1198. PlayerPlaySound(playerid,1133,0.0,0.0,0.0);
  1199. }
  1200. if(listitem == 7)
  1201. {
  1202. ChangeVehicleColor(GetPlayerVehicleID(playerid),146,146);
  1203. PlayerPlaySound(playerid,1133,0.0,0.0,0.0);
  1204. return 1;
  1205. }
  1206. }
  1207. }
  1208.     if(dialogid == uD){
  1209.     if(response){
  1210.         if(listitem == 0){
  1211.         if(IsPlayerInAnyVehicle(playerid)) {
  1212.         new VehicleID;
  1213.         VehicleID = GetPlayerVehicleID(playerid);
  1214.         SetVehiclePos(VehicleID,-312.2921,1540.4182,75.2216);
  1215.         new pname[MAX_PLAYER_NAME];
  1216.         new string [90];
  1217.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  1218.         format(string, sizeof(string), "%s Foi Fazer Drift Em uD1 ", pname);
  1219.         SendClientMessageToAll(0x33CCFFAA, string);
  1220.         SetPlayerInterior(playerid,0);
  1221.         }
  1222.         else{
  1223.         new pname[MAX_PLAYER_NAME];
  1224.         new string [90];
  1225.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  1226.         format(string, sizeof(string), "%s Foi Fazer Drift Em uD1 ", pname);
  1227.         SendClientMessageToAll(0x33CCFFAA, string);
  1228.         SetPlayerInterior(playerid,0);
  1229.         SetPlayerPos(playerid,-312.2921,1540.4182,75.2216);
  1230.         ResetPlayerWeapons(playerid);
  1231.         }
  1232.         }
  1233.         if(listitem == 1){
  1234.         if(IsPlayerInAnyVehicle(playerid)) {
  1235.         new VehicleID;
  1236.         VehicleID = GetPlayerVehicleID(playerid);
  1237.         SetVehiclePos(VehicleID,-2423.2783,-609.5183,132.5589);
  1238.         new pname[MAX_PLAYER_NAME];
  1239.         new string [90];
  1240.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  1241.         format(string, sizeof(string), "%s Foi Fazer Drift Em uD2 ", pname);
  1242.         SendClientMessageToAll(0x33CCFFAA, string);
  1243.         SetPlayerInterior(playerid,0);
  1244.         }
  1245.         else{
  1246.         new pname[MAX_PLAYER_NAME];
  1247.         new string [90];
  1248.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  1249.         format(string, sizeof(string), "%s Foi Fazer Drift Em uD2 ", pname);
  1250.         SendClientMessageToAll(0x33CCFFAA, string);
  1251.         SetPlayerInterior(playerid,0);
  1252.         SetPlayerPos(playerid,-2423.2783,-609.5183,132.5589);
  1253.         ResetPlayerWeapons(playerid);
  1254.         }
  1255.         }
  1256.         if(listitem == 2){
  1257.         if(IsPlayerInAnyVehicle(playerid)) {
  1258.         new VehicleID;
  1259.         VehicleID = GetPlayerVehicleID(playerid);
  1260.         SetVehiclePos(VehicleID,1257.6019,-2027.8704,59.1490);
  1261.         new pname[MAX_PLAYER_NAME];
  1262.         new string [90];
  1263.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  1264.         format(string, sizeof(string), "%s Foi Fazer Drift Em uD3 ", pname);
  1265.         SendClientMessageToAll(0x33CCFFAA, string);
  1266.         SetPlayerInterior(playerid,0);
  1267.         }
  1268.         else{
  1269.         new pname[MAX_PLAYER_NAME];
  1270.         new string [90];
  1271.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  1272.         format(string, sizeof(string), "%s Foi Fazer Drift Em uD3 ", pname);
  1273.         SendClientMessageToAll(0x33CCFFAA, string);
  1274.         SetPlayerInterior(playerid,0);
  1275.         SetPlayerPos(playerid,1257.6019,-2027.8704,59.1490);
  1276.         ResetPlayerWeapons(playerid);
  1277.         }
  1278.         }
  1279.         if(listitem == 3){
  1280.         if(IsPlayerInAnyVehicle(playerid)) {
  1281.         new VehicleID;
  1282.         VehicleID = GetPlayerVehicleID(playerid);
  1283.         SetVehiclePos(VehicleID,2328.7517,1399.8760,42.4814);
  1284.         new pname[MAX_PLAYER_NAME];
  1285.         new string [90];
  1286.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  1287.         format(string, sizeof(string), "%s Foi Fazer Drift Em uD4 ", pname);
  1288.         SendClientMessageToAll(0x33CCFFAA, string);
  1289.         SetPlayerInterior(playerid,0);
  1290.         }
  1291.         else{
  1292.         new pname[MAX_PLAYER_NAME];
  1293.         new string [90];
  1294.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  1295.         format(string, sizeof(string), "%s Foi Fazer Drift Em uD4 ", pname);
  1296.         SendClientMessageToAll(0x33CCFFAA, string);
  1297.         SetPlayerInterior(playerid,0);
  1298.         SetPlayerPos(playerid,2328.7517,1399.8760,42.4814);
  1299.         ResetPlayerWeapons(playerid);
  1300.         }
  1301.         }
  1302.         if(listitem == 4){
  1303.         if(IsPlayerInAnyVehicle(playerid)) {
  1304.         new VehicleID;
  1305.         VehicleID = GetPlayerVehicleID(playerid);
  1306.         SetVehiclePos(VehicleID,2284.0291,1577.4082,20.0502);
  1307.         new pname[MAX_PLAYER_NAME];
  1308.         new string [90];
  1309.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  1310.         format(string, sizeof(string), "%s Foi Fazer Drift Em uD5 ", pname);
  1311.         SendClientMessageToAll(0x33CCFFAA, string);
  1312.         SetPlayerInterior(playerid,0);
  1313.         }
  1314.         else{
  1315.         new pname[MAX_PLAYER_NAME];
  1316.         new string [90];
  1317.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  1318.         format(string, sizeof(string), "%s Foi Fazer Drift Em uD5 ", pname);
  1319.         SendClientMessageToAll(0x33CCFFAA, string);
  1320.         SetPlayerInterior(playerid,0);
  1321.         SetPlayerPos(playerid,2284.0291,1577.4082,20.0502);
  1322.         ResetPlayerWeapons(playerid);
  1323.         }
  1324.         }
  1325.         if(listitem == 5){
  1326.         if(IsPlayerInAnyVehicle(playerid)) {
  1327.         new VehicleID;
  1328.         VehicleID = GetPlayerVehicleID(playerid);
  1329.         SetVehiclePos(VehicleID,2892.3997,2431.1709,10.4781);
  1330.         new pname[MAX_PLAYER_NAME];
  1331.         new string [90];
  1332.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  1333.         format(string, sizeof(string), "%s Foi Fazer Drift Em uD6 ", pname);
  1334.         SendClientMessageToAll(0x33CCFFAA, string);
  1335.         SetPlayerInterior(playerid,0);
  1336.         }
  1337.         else{
  1338.         new pname[MAX_PLAYER_NAME];
  1339.         new string [90];
  1340.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  1341.         format(string, sizeof(string), "%s Foi Fazer Drift Em uD6 ", pname);
  1342.         SendClientMessageToAll(0x33CCFFAA, string);
  1343.         SetPlayerInterior(playerid,0);
  1344.         SetPlayerPos(playerid,2892.3997,2431.1709,10.4781);
  1345.         ResetPlayerWeapons(playerid);
  1346.         }
  1347.         }
  1348.         if(listitem == 6){
  1349.         if(IsPlayerInAnyVehicle(playerid)) {
  1350.         new VehicleID;
  1351.         VehicleID = GetPlayerVehicleID(playerid);
  1352.         SetVehiclePos(VehicleID,2142.0715,2788.7520,10.8203);
  1353.         new pname[MAX_PLAYER_NAME];
  1354.         new string [90];
  1355.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  1356.         format(string, sizeof(string), "%s Foi Fazer Drift Em uD7 ", pname);
  1357.         SendClientMessageToAll(0x33CCFFAA, string);
  1358.         SetPlayerInterior(playerid,0);
  1359.         }
  1360.         else{
  1361.         new pname[MAX_PLAYER_NAME];
  1362.         new string [90];
  1363.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  1364.         format(string, sizeof(string), "%s Foi Fazer Drift Em uD7 ", pname);
  1365.         SendClientMessageToAll(0x33CCFFAA, string);
  1366.         SetPlayerInterior(playerid,0);
  1367.         SetPlayerPos(playerid,2142.0715,2788.7520,10.8203);
  1368.         ResetPlayerWeapons(playerid);
  1369.         }
  1370.         }
  1371.         if(listitem == 7){
  1372.         if(IsPlayerInAnyVehicle(playerid)) {
  1373.         new VehicleID;
  1374.         VehicleID = GetPlayerVehicleID(playerid);
  1375.         SetVehiclePos(VehicleID,332.39550781,1998.21386719,2420.94555664);
  1376.         new pname[MAX_PLAYER_NAME];
  1377.         new string [90];
  1378.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  1379.         format(string, sizeof(string), "%s Foi fazer twin em Drift Organico ", pname);
  1380.         SendClientMessageToAll(0x33CCFFAA, string);
  1381.         SetPlayerInterior(playerid,0);
  1382.         }
  1383.         else{
  1384.         new pname[MAX_PLAYER_NAME];
  1385.         new string [90];
  1386.         GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
  1387.         format(string, sizeof(string), "%s Foi fazer twin em Drift Organico ", pname);
  1388.         SendClientMessageToAll(0x33CCFFAA, string);
  1389.         SetPlayerInterior(playerid,0);
  1390.         SetPlayerPos(playerid,332.39550781,1998.21386719,2420.94555664);
  1391.         ResetPlayerWeapons(playerid);
  1392.         }
  1393.         }
  1394.  
  1395.     }
  1396.     else{
  1397.     }
  1398. }
  1399. if(dialogid == Horario) // Dialog +1! ( CORRIDA )
  1400. {
  1401.        if(response) // Botão
  1402.        {
  1403.            if(listitem == 0)
  1404.            {
  1405.             SetPlayerTime(playerid, 06,0);
  1406.             GameTextForPlayer(playerid,"~w~ Mudou para ~r~Dia",1000,1);
  1407.                  return true;
  1408.            }
  1409.            else if(listitem == 1)
  1410.            {
  1411.             SetPlayerTime(playerid, 12,0);
  1412.             GameTextForPlayer(playerid,"~w~ Mudou para ~r~Tarde",1000,1);
  1413.                  return true;
  1414.            }
  1415.            if(listitem == 2)
  1416.            {
  1417.             SetPlayerTime(playerid, 00,0);
  1418.             GameTextForPlayer(playerid,"~w~ Mudou para ~r~Noite",1000,1);
  1419.                  return true;
  1420.            }
  1421.       }
  1422.       return true;
  1423. }
  1424.  
  1425. if(dialogid == Mundo)
  1426. {
  1427.       if(response)
  1428.       {
  1429.          SetVehicleVirtualWorld(GetPlayerVehicleID(playerid), listitem);
  1430.          if(listitem ==0)
  1431.          {
  1432.           SetPlayerVirtualWorld(playerid, 0);
  1433.           SendClientMessage(playerid,Verde,"Conectado ao mundo Principal Com Sucesso!");
  1434.           return true;
  1435.       }
  1436.       else if(listitem == 1)
  1437.       {
  1438.           SetPlayerVirtualWorld(playerid, 1);
  1439.           SendClientMessage(playerid,Verde,"Conectado ao mundo 1 Com sucesso!");
  1440.           return true;
  1441.       }
  1442.           else if(listitem == 2)
  1443.       {
  1444.           SetPlayerVirtualWorld(playerid, 2);
  1445.           SendClientMessage(playerid,Verde,"Conectado ao mundo 2 Com sucesso!");
  1446.           return true;
  1447.       }
  1448.           else if(listitem == 3)
  1449.       {
  1450.           SetPlayerVirtualWorld(playerid, 3);
  1451.           SendClientMessage(playerid,Verde,"Conectado ao mundo 3 Com sucesso!");
  1452.           return true;
  1453.       }
  1454.           else if(listitem == 4)
  1455.       {
  1456.           SetPlayerVirtualWorld(playerid, 4);
  1457.           SendClientMessage(playerid,Verde,"Conectado ao mundo 4 Com sucesso!");
  1458.           return true;
  1459.       }
  1460.           else if(listitem == 5)
  1461.       {
  1462.           SetPlayerVirtualWorld(playerid, 5);
  1463.           SendClientMessage(playerid,Verde,"Conectado ao mundo 5 Com sucesso!");
  1464.           return true;
  1465.       }
  1466.   }
  1467. return 1;
  1468. }
  1469. if(dialogid == Comandos)
  1470. {
  1471.       if(response)
  1472.       {
  1473.            if(listitem == 0)
  1474.            {
  1475.                ShowPlayerDialog(playerid, Comandos+1, DIALOG_STYLE_MSGBOX, "INFO::", "COMANDOS DE PLAYER:/sp /skin /goto /mundo /on /afk /pm\nANIMES: /cruzarbraço /conversar /fumar /fumar2 /deitar /abaixar /sentar\nCOMANDOS DE VEICULO: /x [desvirar veiculo] /Cores", "Selecionar", "Sair");
  1476.                return true;
  1477.            }
  1478.            if(listitem == 1)
  1479.            {
  1480.                ShowPlayerDialog(playerid, Comandos+1, DIALOG_STYLE_MSGBOX, "INFO: Teletransporte", "/Aerosf /Aerolv /Aerols /uD 1~4 /Sf /Lv /Ls /Mansão", "Selecionar", "Sair");
  1481.                return true;
  1482.            }
  1483.            if(listitem == 2)
  1484.            {
  1485.                ShowPlayerDialog(playerid, Comandos+1, DIALOG_STYLE_MSGBOX, "INFO: Ajuda:", "Vejo que você é novato aqui.\nEste servidor é de drift, você poderá pegar veiculos e treinar até você fica um 'EXPERT'.\nVeja as Regras do servidor, antes de jogar.\nBoa Sorte!", "Selecionar", "Sair");
  1486.                return true;
  1487.            }
  1488.            if(listitem == 3)
  1489.            {
  1490.                ShowPlayerDialog(playerid, Comandos+1, DIALOG_STYLE_MSGBOX, "INFO: Regras:", "Aqui vocês vão respeitar as Seguinte regras:\n- Não usar speed.\n- Não usa qualquer outro tipo de mod, que der vantagem aos outros jogadores.\n- Não usar armas no servidor.\n- Não comenter DB 'Atropelar os Jogadores'.\n- Respeitar os administradores.\n- Respeitar todos os jogadores.\n- Não usar Sobeit, e divulgar servidores aqui.\nCaso alcontrario você será Kick/Ban.\nBom jogo!", "Ok", "Sair");
  1491.                return true;
  1492.            }
  1493.                       if(listitem == 4)
  1494.            {
  1495.                ShowPlayerDialog(playerid, Comandos+1, DIALOG_STYLE_MSGBOX, "INFO: Eventos:", "Nosso clan provavelmente só fazemos eventos no final de semana, Qual vantagem eu ganho particpando dos eventos ?\n R: Você particpando dos eventos, fica mais fácil você entrar pro nosso clan.\nATÇ: Só fazemos eventos quando os administradores tiverem online.", "Ok", "Sair");
  1496.                return true;
  1497.            }
  1498.                       if(listitem == 5)
  1499.            {
  1500.                ShowPlayerDialog(playerid, MudarCor, DIALOG_STYLE_LIST, "Escolha uma cor:", "Vermelho\nVerde\nAmarelo\nAzul\nLaranja\nRoxo\nAzul Marinho\nRosa\nCinza\nMarrom\nBranco\nAzul Claro\nVerde Escuro", "Ok", "Cancelar");
  1501.                return true;
  1502.            }
  1503.                      if(listitem == 6)
  1504.            {
  1505.                ShowPlayerDialog(playerid, Horario, DIALOG_STYLE_LIST, "INFO: Horarios:", "Dia\nTarde\nNoite", "Selecionar", "Sair");
  1506.                return true;
  1507.            }
  1508.                      if(listitem == 7)
  1509.            {
  1510.                ShowPlayerDialog(playerid,uD,DIALOG_STYLE_LIST,"INFO: Pistas de Drift",\tDrift: Pista uD 1 [OFICIAL]\n\t»Drift: Pista uD 2\n\t»Drift: Pista uD 3\n\t»Drift: Pista uD 4\n\t»Drift: Pista uD 5\n\t»Drift: Pista uD 6\n\t»Drift: Pista uD 7\n\tTwin - Drif Organico\n","OK","Fechar");
  1511.                return true;
  1512.            }
  1513.       }
  1514.       return true;
  1515. }
  1516.     new sendername[MAX_PLAYER_NAME];
  1517.     new string[128];
  1518.  
  1519.     if(dialogid == MudarCor)
  1520.     {
  1521.         if(response)
  1522.         {
  1523.             if(listitem == 0)
  1524.             {
  1525.                 SetPlayerColor(playerid, Vermelho);
  1526.                 GetPlayerName(playerid, sendername, sizeof(sendername));
  1527.                 format(string, sizeof(string), "%s Trocou a cor do Nick Para Vermelho!", sendername);
  1528.                 SendClientMessageToAll(Branco, string);
  1529.             }
  1530.             if(listitem == 1)
  1531.             {
  1532.                 SetPlayerColor(playerid, Verde);
  1533.                 GetPlayerName(playerid, sendername, sizeof(sendername));
  1534.                 format(string, sizeof(string), "%s Trocou a cor do Nick Para Verde!", sendername);
  1535.                 SendClientMessageToAll(Branco, string);
  1536.             }
  1537.             if(listitem == 2)
  1538.             {
  1539.                 SetPlayerColor(playerid, Amarelo);
  1540.                 GetPlayerName(playerid, sendername, sizeof(sendername));
  1541.                 format(string, sizeof(string), "%s Trocou a cor do Nick Para Amarelo!", sendername);
  1542.                 SendClientMessageToAll(Branco, string);
  1543.             }
  1544.             if(listitem == 3)
  1545.             {
  1546.                 SetPlayerColor(playerid, Azul);
  1547.                 GetPlayerName(playerid, sendername, sizeof(sendername));
  1548.                 format(string, sizeof(string), "%s Trocou a cor do Nick Para Azul!", sendername);
  1549.                 SendClientMessageToAll(Branco, string);
  1550.             }
  1551.             if(listitem == 4)
  1552.             {
  1553.                 SetPlayerColor(playerid, Laranja);
  1554.                 GetPlayerName(playerid, sendername, sizeof(sendername));
  1555.                 format(string, sizeof(string), "%s Trocou a cor do Nick Para Laranja!", sendername);
  1556.                 SendClientMessageToAll(Branco, string);
  1557.             }
  1558.             if(listitem == 5)
  1559.             {
  1560.                 SetPlayerColor(playerid, Roxo);
  1561.                 GetPlayerName(playerid, sendername, sizeof(sendername));
  1562.                 format(string, sizeof(string), "%s Trocou a cor do Nick para Roxo!", sendername);
  1563.                 SendClientMessageToAll(Branco, string);
  1564.             }
  1565.             if(listitem == 6)
  1566.             {
  1567.                 SetPlayerColor(playerid, Azul_Marinho);
  1568.                 GetPlayerName(playerid, sendername, sizeof(sendername));
  1569.                 format(string, sizeof(string), "%s Trocou a cor do Nick Para Azul Marinho!", sendername);
  1570.                 SendClientMessageToAll(Branco, string);
  1571.             }
  1572.             if(listitem == 7)
  1573.             {
  1574.                 SetPlayerColor(playerid, Rosa);
  1575.                 GetPlayerName(playerid, sendername, sizeof(sendername));
  1576.                 format(string, sizeof(string), "%s Trocou a cor do Nick Para Rosa!", sendername);
  1577.                 SendClientMessageToAll(Branco, string);
  1578.             }
  1579.             if(listitem == 8)
  1580.             {
  1581.                 SetPlayerColor(playerid, Cinza);
  1582.                 GetPlayerName(playerid, sendername, sizeof(sendername));
  1583.                 format(string, sizeof(string), "%s Trocou a cor do Nick Para Cinza!", sendername);
  1584.                 SendClientMessageToAll(Branco, string);
  1585.             }
  1586.             if(listitem == 9)
  1587.             {
  1588.                 SetPlayerColor(playerid, Marron);
  1589.                 GetPlayerName(playerid, sendername, sizeof(sendername));
  1590.                 format(string, sizeof(string), "%s Trocou a cor do Nick Para Marron!", sendername);
  1591.                 SendClientMessageToAll(Branco, string);
  1592.             }
  1593.             if(listitem == 10)
  1594.             {
  1595.                 SetPlayerColor(playerid, Branco);
  1596.                 GetPlayerName(playerid, sendername, sizeof(sendername));
  1597.                 format(string, sizeof(string), "%s Trocou a cor do Nick Para Branco!", sendername);
  1598.                 SendClientMessageToAll(Branco, string);
  1599.             }
  1600.             if(listitem == 11)
  1601.             {
  1602.                 SetPlayerColor(playerid, Azul_Claro);
  1603.                 GetPlayerName(playerid, sendername, sizeof(sendername));
  1604.                 format(string, sizeof(string), "%s Trocou a cor do Nick Para Azul Claro!", sendername);
  1605.                 SendClientMessageToAll(Branco, string);
  1606.             }
  1607.             if(listitem == 12)
  1608.             {
  1609.                 SetPlayerColor(playerid, Verde_Escuro);
  1610.                 GetPlayerName(playerid, sendername, sizeof(sendername));
  1611.                 format(string, sizeof(string), "%s Trocou a cor do Nick Para Verde Escuro!", sendername);
  1612.                 SendClientMessageToAll(Branco, string);
  1613.             }
  1614.         }
  1615.     }
  1616.     if(dialogid == Musicas)
  1617. {
  1618.     for(new i=0; i<MAX_PLAYERS; i++)
  1619.     {
  1620.         if(IsPlayerConnected(i))
  1621.         {
  1622.             new Float:X, Float:Y, Float:Z, Float:Distance = 25.0;
  1623.             GetPlayerPos(i, X, Y, Z);
  1624.             if(response)
  1625.             {
  1626.                 if(listitem == 0)// Musica teste
  1627.                 {
  1628.                    StopAudioStreamForPlayer(i);
  1629.                    PlayAudioStreamForPlayer(i, "http://dc311.4shared.com/img/233926950/4f760756/dlink__2Fdownload_2F8H3ruy1b_3Ftsid_3D20111206-195937-e565d3b/preview.mp3", X, Y, Z, Distance, 1);
  1630.                 }
  1631.             }
  1632.         }
  1633.     }
  1634. }
  1635.     return true;
  1636.     }
  1637.  
  1638.  
  1639. public OnPlayerClickPlayer(playerid, clickedplayerid, source)
  1640. {
  1641.     return 1;
  1642. }
  1643. public RandomMSG()
  1644. {
  1645.  new string[80];
  1646.     new random1 = random(sizeof(mensagens));
  1647.     new random2 = random(sizeof(cores));
  1648.     format(string, sizeof(string), "%s", mensagens[random1]);
  1649.     SendClientMessageToAll(cores[random2],string);
  1650.     return 1;
  1651. }
  1652.  
  1653. strtok(const string[], &index)
  1654. {
  1655.     new length = strlen(string);
  1656.     while ((index < length) && (string[index] <= ' '))
  1657.     {
  1658.         index++;
  1659.     }
  1660.  
  1661.     new offset = index;
  1662.     new result[20];
  1663.     while ((index < length) && (string[index] > ' ') && ((index - offset) < (sizeof(result) - 1)))
  1664.     {
  1665.         result[index - offset] = string[index];
  1666.         index++;
  1667.     }
  1668.     result[index - offset] = EOS;
  1669.     return result;
  1670. }
  1671. stock IsValidSkin(skin)
  1672. {
  1673.     if((skin == 0)||(skin == 7)||(skin >= 9 && skin <= 41)||(skin >= 43 && skin <= 64)||(skin >= 66 && skin <= 73)||(skin >= 75 && skin <= 85)||(skin >= 87 && skin <= 118)||(skin >= 120 && skin <= 148)||(skin >= 150 && skin <= 207)||(skin >= 209 && skin <= 264)||(skin >= 274 && skin <= 288)||(skin >= 290 && skin <= 299)) return true;
  1674.     else return false;
  1675. }
  1676. public atualizar () //Inicio da public obvio
  1677. {
  1678. static Number = 0; // Static quase a mesma coisa de uma string pelo oque eu acho se eu estiver errado me corrijam.
  1679. TextDrawSetString(Nome, news[Number++]); //Strings usadas para o Texto
  1680. TextDrawShowForAll(Nome); //Mostra o Texto a todos os players
  1681. if(Number == sizeof(news)) Number = 0; //se o tamanho do Number de Number news = 0;
  1682. return 1;
  1683. }
  1684. stock pNome(playerid)
  1685. {
  1686.     new nome[MAX_PLAYER_NAME];
  1687.     GetPlayerName(playerid,nome,sizeof(nome));
  1688.     return nome;
  1689. }
  1690. public RodapeTimer()
  1691. {
  1692.     new PlayersOn, string[125], hour, minute, second;
  1693.     for(new i = 0; i < MAX_PLAYERS; i ++)
  1694.     {
  1695.         if(!IsPlayerConnected(i)) continue;
  1696.         PlayersOn++;
  1697.     }
  1698.     gettime(hour,minute,second);
  1699.     format(string, sizeof string, "(%d/%d)", PlayersOn, GetMaxPlayers(), hour, minute, second);
  1700.     TextDrawSetString(Rodape, string);
  1701.  
  1702.     return 1;
  1703. }
  1704. AntiCheatUpdate();
  1705. public AntiCheatUpdate()
  1706. {
  1707.     new slot = GetMaxPlayers();
  1708.     while(slot--)
  1709.     {
  1710.         if(IsPlayerConnected(slot) && !IsPlayerAdmin(slot))
  1711.         {
  1712.             new pName[MAX_PLAYER_NAME];
  1713.             new ArmaNome[17];
  1714.             new string[128];
  1715.             GetPlayerName(slot, pName, sizeof(pName));
  1716.             switch(GetPlayerWeapon(slot))
  1717.             {
  1718.                 case 35: ArmaNome = #Rocket Launcher;
  1719.                 case 36: ArmaNome = #Bazuca;
  1720.                 case 37: ArmaNome = #Lança Chamas;
  1721.                 case 38: ArmaNome = #Minigun;
  1722.                 case 39: ArmaNome = #Satchel Charge;
  1723.                 case 40: ArmaNome = #Detonador;
  1724.                 case 44: ArmaNome = #Visão Noturna;
  1725.                 case 45: ArmaNome = #Visão Termal;
  1726.                 case 18: ArmaNome = #Molotov Cocktail;
  1727.                 case 17: ArmaNome = #Bomba de Gás;
  1728.                 default: goto stop;
  1729.             }
  1730.             format(string,128,"[ANTI-CHEAT]: %s Foi kickado pelo administrador BOT [motivo: Arma Proibida: %s ]",pName,ArmaNome);
  1731.             SendClientMessageToAll(0xFF0000AA,string);
  1732.             Kick(slot);
  1733.             stop:
  1734.         }
  1735.     }
  1736.     return true;
  1737. }
  1738. public DeletarTextodoJeff(playerid)
  1739. {
  1740.     TextDrawHideForPlayer(playerid, Jeff1);
  1741.     TextDrawHideForPlayer(playerid, Jeff2);
  1742.     TextDrawHideForPlayer(playerid, Jeff3);
  1743.     TogglePlayerControllable(playerid, 1);
  1744.     return 1;
  1745. }
  1746. public Nitro(playerid)
  1747. {
  1748.     if(IsPlayerInAnyVehicle(playerid))
  1749.     {
  1750.         switch(GetVehicleModel(GetPlayerVehicleID(playerid)))
  1751.         {
  1752.             case 448,461,462,463,468,471,509,510,521,522,523,581,586,449: return;
  1753.         }
  1754.         AddVehicleComponent(GetPlayerVehicleID(playerid),1010);
  1755. }
  1756. }
Add Comment
Please, Sign In to add comment