Guest User

TDM

a guest
Feb 9th, 2015
370
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 40.37 KB | None | 0 0
  1.        /////////////////////////////////////////////////////////////////////////
  2.        //                                                                     //
  3.        //  /////////////////////////////////////////////////////////////////  //
  4.        //  ///                                                           ///  //
  5.        //  ///  =========                                  ============  ///  //
  6.        //  ///  ========= ===                              ============  ///  //
  7.        //  ///  ====      ===     ===      === ===     === ===           ///  //
  8.        //  ///  ====      ===     ===      === ===     === ===           ///  //
  9.        //  ///  ====      ======    ===   ===   ===   ===  ============  ///  //
  10.        //  ///  ====      =======    === ===     === ===   ============  ///  //
  11.        //  ///  ====      ========    ====        ====              ===  ///  //
  12.        //  ///  ====      ===  ===    ====        ====              ===  ///  //
  13.        //  ///  ========= ===  ===    ====        ====     ============  ///  //
  14.        //  ///  ========= ===  ===    ====        ====     ============  ///  //
  15.        //  ///                                                           ///  //
  16.        // /////////////////////////////////////////////////////////////////   //
  17.        //                                                                     //
  18.        /////////////////////////////////////////////////////////////////////////
  19.  
  20. //veiculo mafia
  21. #define CAR_MAFIA          13
  22. #define CAR_MILITARES      23
  23. #define CAR_TERRORISTA     21
  24. #define CAR_TRIADS         18
  25.  
  26. new Car_Militares[CAR_MILITARES];
  27. new Car_Mafia[CAR_MAFIA];
  28. new Car_Terrorista[CAR_TERRORISTA];
  29. new Car_Triads[CAR_TRIADS];
  30. //gangzones
  31. new Militar;
  32. new Mafiosos;
  33. new Terrorista;
  34. new Triad;
  35. //=========================
  36. //ANTI AMX
  37. AntiDeAMX()
  38. {
  39.     new a[][] = { "Unarmed (Fist)", "Brass K" };
  40.     #pragma unused a
  41. }
  42. #define MES_LIMITE 12
  43. //===========================================
  44. new Text:Textdraw0;
  45. new Text:Textdraw1;
  46. new Total = 0;
  47. forward hora(playerid);
  48.  
  49. #include a_samp
  50. #include zcmd
  51. #include <dini>
  52. #include <sscanf>
  53. // TextDraw
  54. new Text:BemVindo;
  55. new Text:GM;
  56. new Text:GM1;
  57. new Text:Site;
  58.  
  59. //equipes
  60. new gTeam[MAX_PLAYERS];
  61.  
  62. #define Mafia       0
  63. #define Militares   1
  64. #define Terroristas 2
  65. #define Triads      3
  66.  
  67. #define CorMafia       0x0101DFFF
  68. #define CorMilitares   0x0B610BFF
  69. #define CorTerroristas 0x8A0808FF
  70. #define CorTriads      0xFE2EF7FF
  71.  
  72. //==== ADMINS ====
  73. #define Ajudante      1
  74. #define Administrador 2
  75. #define Moderador     3
  76. #define Master        4
  77. //====================================
  78. new nrg[80];
  79.  
  80. main()
  81. {
  82.     print("=======================================================");
  83.     print("-------------------------------------------------------");
  84.     print("  +++++++++++++++++++++++++++++++++++++++++++++++++++  ");
  85.     print("  ++  Gamemode Foi iniciado Corretamente           ++  ");
  86.     print("  ++  Gamemode Criado por [NNF]ChryyS              ++  ");
  87.     print("  ++  FilterScripts Criado/Editado por [NNF]ChryyS ++  ");
  88.     print("  ++  ============================================ ++  ");
  89.     print("  ++  Este GM Só Rodará se o Autor Permitir        ++  ");
  90.     print("  +++++++++++++++++++++++++++++++++++++++++++++++++++  ");
  91.     print("-------------------------------------------------------");
  92.     print("=======================================================");
  93.  
  94. }
  95.  
  96. //========================================
  97. //========== Cores ==========
  98. #define COLOR_DARKGREEN 0x088A08FF
  99. #define COLOR_CINZA 0x848484FF
  100. #define COLOR_CONNECT 0x009EB0AA
  101. #define COLOR_TOPOC 0x089CFFAA
  102. #define COLOR_ROSITA 0xFF0080FF
  103. #define COLOR_TIMES 0x089CFFAA
  104. #define COLOR_RED 0xFF0000AA
  105. #define COLOR_BLUE 0x33CCFFAA
  106. #define COLOR_YELLOW 0xFFFF00AA
  107. #define COLOR_DARKBLUE 0x0000FFAA
  108. #define COLOR_ORANGE 0xFF5604AA
  109. #define COLOR_GREY 0xAFAFAFAA
  110. #define COLOR_COCONUT 0x96D742FF
  111. #define COLOR_GREEN 0x33AA33AA
  112. #define COLOR_YELLOW 0xFFFF00AA
  113. #define COLOR_WHITE 0xFFFFFFAA
  114. #define COLOR_LIGHTBLUE 0x33CCFFFF
  115. #define COLOR_LIGHTYELLOW 0xFAEAA9FF
  116. #define COLOR_LIGHTGREEN 0x5BC476FF
  117. #define COLOR_LIMON 0x00FF00FF
  118. #define COLOR_LIGHTORANGE 0xF7A26FFF
  119. #define COLOR_LIGHTRED 0xFF6A6AFF
  120. #define COLOR_MARROM 0x673B15FF
  121. #define COLOR_BARRAS 0x96D742AA
  122. #define COLOR_GOLD 0xFFD700AA
  123. #define COLOR_PINK 0xDF01D7FF
  124. #define COLOR_BARRAS 0x96D742AA
  125.  
  126. //Nome dos veiculos
  127. new vehName[][] =
  128. {
  129.     "Landstalker", "Bravura", "Buffalo", "Linerunner", "Perrenial", "Sentinel",
  130.     "Dumper", "Firetruck", "Trashmaster", "Stretch", "Manana", "Infernus",
  131.     "Voodoo", "Pony", "Mule", "Cheetah", "Ambulance", "Leviathan", "Moonbeam",
  132.     "Esperanto", "Taxi", "Washington", "Bobcat", "Whoopee", "BF Injection",
  133.     "Hunter", "Premier", "Enforcer", "Securicar", "Banshee", "Predator", "Bus",
  134.     "Rhino", "Barracks", "Hotknife", "Trailer", "Previon", "Coach", "Cabbie",
  135.     "Stallion", "Rumpo", "RC Bandit", "Romero", "Packer", "Monster", "Admiral",
  136.     "Squalo", "Seasparrow", "Pizzaboy", "Tram", "Trailer", "Turismo", "Speeder",
  137.     "Reefer", "Tropic", "Flatbed", "Yankee", "Caddy", "Solair", "Berkley's RC Van",
  138.     "Skimmer", "PCJ-600", "Faggio", "Freeway", "RC Baron", "RC Raider", "Glendale",
  139.     "Oceanic","Sanchez", "Sparrow", "Patriot", "Quad", "Coastguard", "Dinghy",
  140.     "Hermes", "Sabre", "Rustler", "ZR-350", "Walton", "Regina", "Comet", "BMX",
  141.     "Burrito", "Camper", "Marquis", "Baggage", "Dozer", "Maverick", "News Chopper",
  142.     "Rancher", "FBI Rancher", "Virgo", "Greenwood", "Jetmax", "Hotring", "Sandking",
  143.     "Blista Compact", "Police Maverick", "Boxvillde", "Benson", "Mesa", "RC Goblin",
  144.     "Hotring Racer A", "Hotring Racer B", "Bloodring Banger", "Rancher", "Super GT",
  145.     "Elegant", "Journey", "Bike", "Mountain Bike", "Beagle", "Cropduster", "Stunt",
  146.     "Tanker", "Roadtrain", "Nebula", "Majestic", "Buccaneer", "Shamal", "Hydra",
  147.     "FCR-900", "NRG-500", "HPV1000", "Cement Truck", "Tow Truck", "Fortune",
  148.     "Cadrona", "FBI Truck", "Willard", "Forklift", "Tractor", "Combine", "Feltzer",
  149.     "Remington", "Slamvan", "Blade", "Freight", "Streak", "Vortex", "Vincent",
  150.     "Bullet", "Clover", "Sadler", "Firetruck", "Hustler", "Intruder", "Primo",
  151.     "Cargobob", "Tampa", "Sunrise", "Merit", "Utility", "Nevada", "Yosemite",
  152.     "Windsor", "Monster", "Monster", "Uranus", "Jester", "Sultan", "Stratium",
  153.     "Elegy", "Raindance", "RC Tiger", "Flash", "Tahoma", "Savanna", "Bandito",
  154.     "Freight Flat", "Streak Carriage", "Kart", "Mower", "Dune", "Sweeper",
  155.     "Broadway", "Tornado", "AT-400", "DFT-30", "Huntley", "Stafford", "BF-400",
  156.     "News Van", "Tug", "Trailer", "Emperor", "Wayfarer", "Euros", "Hotdog", "Club",
  157.     "Freight Box", "Trailer", "Andromada", "Dodo", "RC Cam", "Launch", "Police Car",
  158.     "Police Car", "Police Car", "Police Ranger", "Picador", "S.W.A.T", "Alpha",
  159.     "Phoenix", "Glendale", "Sadler", "Luggage", "Luggage", "Stairs", "Boxville",
  160.     "Tiller", "Utility Trailer"
  161. };
  162.  
  163. //==============================================================================
  164. //========================================
  165. public OnGameModeInit()
  166. {
  167. //ANTI AMX
  168. AntiDeAMX();
  169.  
  170. ShowNameTags(1);
  171. EnableStuntBonusForAll(0);
  172. AllowInteriorWeapons(0); //bloquea armas em interiores
  173. UsePlayerPedAnims();
  174. DisableInteriorEnterExits();
  175.  
  176. {
  177.     new Data[3];
  178.     getdate(Data[0], Data[1], Data[2]); // Ano, mes, dia
  179.     if(Data[1] > MES_LIMITE) // Se o mês atual é maior que o permitido, o servidor fechará.
  180.     {
  181.         printf("Proteção por Data ativada.");
  182.         printf("Você não tem permissão para usar este GameMode.");
  183.         SendRconCommand("exit");
  184.         return true;
  185.     }
  186. }
  187.  
  188. //==========================
  189. {
  190.     SetTimer("hora",1000,1);
  191. }
  192. //GangZone
  193.     Militar = GangZoneCreate(-1485.684692, 481.744476, -1231.547485, 524.751647);
  194.     Mafiosos = GangZoneCreate(-2517.578125, 507.8125, -2376.953125, 566.40625);
  195.     Terrorista = GangZoneCreate(-2159.059, -273.8304, -2008.414, -60.80231);
  196.     Triad = GangZoneCreate(-2247.901, 945.1636, -2139.745, 1122.687);
  197. //=================
  198. //***
  199. //***
  200. //*** CADA VEÍCULO QUE É CRIADO, SEJA COM CREATEVEHICLE OU ADDSTATICVEHICLE, ELE GERA UM ID DE VEÍCULO DO SERVIDOR. Se um servidor tiver 1000 veículos, cada veículo terá o seu id
  201. //*** E cada função de CreateVehicle ou AddStaticVehicle gera um ID.
  202. //***
  203.     // Base mafia
  204.     Car_Mafia[0] = AddStaticVehicleEx(545,-2413.8999000,535.9000200,29.9000000,254.0000000,223,223,100); //hustler ****** ID 0
  205.     Car_Mafia[1] = AddStaticVehicleEx(580,-2413.3000000,539.7999900,29.8000000,268.0000000,223,223,100); //Stafford
  206.     Car_Mafia[2] = AddStaticVehicleEx(461,-2441.5000000,495.7999900,29.8000000,0.0000000,223,223,100); //PCJ-600
  207.     Car_Mafia[3] = AddStaticVehicleEx(461,-2442.8000000,495.3999900,29.8000000,0.0000000,223,223,100); //PCJ-600
  208.     Car_Mafia[4] = AddStaticVehicleEx(461,-2444.3999000,494.8999900,29.8000000,0.0000000,223,223,100); //PCJ-600
  209.     Car_Mafia[5] = AddStaticVehicleEx(461,-2446.6001000,494.2999900,29.8000000,0.0000000,223,223,100); //PCJ-600
  210.     Car_Mafia[6] = AddStaticVehicleEx(461,-2448.2000000,493.7000100,29.8000000,0.0000000,223,223,100); //PCJ-600
  211.     Car_Mafia[7] = AddStaticVehicleEx(419,-2414.7000000,531.7999900,29.9000000,248.0000000,223,223,100); //Esperanto
  212.     Car_Mafia[8] = AddStaticVehicleEx(580,-2416.7000000,528.7000100,29.8000000,237.9950000,223,223,100); //Stafford
  213.     Car_Mafia[9] = AddStaticVehicleEx(545,-2419.5000000,525.0999800,29.9000000,227.9980000,223,223,100); //Hustler
  214.     Car_Mafia[10] = AddStaticVehicleEx(489,-2425.8999000,517.9000200,30.3000000,220.0000000,223,223,100); //Rancher
  215.     Car_Mafia[11] = AddStaticVehicleEx(489,-2429.5000000,514.7999900,30.3000000,219.9960000,223,223,100); //Rancher
  216.     Car_Mafia[12] = AddStaticVehicleEx(519,-2489.2000000,522.7999900,52.1000000,272.0000000,223,223,100); //Shamal ****** ID 12
  217.    
  218. //Base Militares
  219.     Car_Militares[0] =  AddStaticVehicleEx(548,-1406.9000000,491.6000100,20.1000000,0.0000000,160,128,100); //Cargobob ****** ID 13
  220.     Car_Militares[1] = AddStaticVehicleEx(548,-1421.0000000,491.5000000,20.1000000,0.0000000,160,128,100); //Cargobob
  221.     Car_Militares[2] = AddStaticVehicleEx(476,-1439.5996000,505.5996100,19.4000000,272.0000000,160,128,100); //Rustler
  222.     Car_Militares[3] = AddStaticVehicleEx(476,-1366.0000000,507.2002000,19.4000000,270.0000000,160,128,100); //Rustler
  223.     Car_Militares[4] = AddStaticVehicleEx(476,-1303.3000000,506.8999900,19.4000000,270.0000000,160,128,100); //Rustler
  224.     Car_Militares[5] = AddStaticVehicleEx(487,-1310.5000000,496.2999900,18.5000000,0.0000000,160,128,100); //Maverick
  225.     Car_Militares[6] = AddStaticVehicleEx(487,-1289.9000000,496.1000100,18.5000000,0.0000000,160,128,100); //Maverick
  226.     Car_Militares[7] = AddStaticVehicleEx(487,-1267.7000000,496.2999900,18.5000000,0.0000000,160,128,100); //Maverick
  227.     Car_Militares[8] = AddStaticVehicleEx(595,-1441.9004000,507.4003900,0.0000000,87.9950000,160,128,100); //Launch
  228.     Car_Militares[9] = AddStaticVehicleEx(473,-1443.6000000,492.5000000,0.0000000,88.0000000,160,128,100); //Dinghy
  229.     Car_Militares[10] = AddStaticVehicleEx(473,-1443.5000000,497.2000100,0.0000000,87.9950000,160,128,100); //Dinghy
  230.     Car_Militares[11] = AddStaticVehicleEx(473,-1451.4004000,501.4003900,0.0000000,87.9950000,160,128,100); //Dinghy
  231.     Car_Militares[12] = AddStaticVehicleEx(430,-1481.5000000,486.5996100,0.0000000,2.0000000,160,128,100); //Predator
  232.     Car_Militares[13] = AddStaticVehicleEx(470,-1529.3000000,459.3999900,7.3000000,90.0000000,160,128,100); //Patriot
  233.     Car_Militares[14] = AddStaticVehicleEx(470,-1529.2000000,448.6000100,7.3000000,90.0000000,160,128,100); //Patriot
  234.     Car_Militares[15] = AddStaticVehicleEx(470,-1529.0000000,436.2999900,7.3000000,90.0000000,160,128,100); //Patriot
  235.     Car_Militares[16] = AddStaticVehicleEx(455,-1530.3000000,425.3999900,7.8000000,87.9950000,160,128,100); //Flatbed
  236.     Car_Militares[17] = AddStaticVehicleEx(455,-1530.4000000,419.2000100,7.8000000,87.9950000,160,128,100); //Flatbed
  237.     Car_Militares[18] = AddStaticVehicleEx(433,-1530.2002000,431.0000000,7.8000000,87.9950000,160,128,100); //Barracks
  238.     Car_Militares[19] = AddStaticVehicleEx(470,-1529.2000000,454.7000100,7.3000000,90.0000000,160,128,100); //Patriot
  239.     Car_Militares[20] = AddStaticVehicleEx(470,-1529.2000000,443.2999900,7.3000000,90.0000000,160,128,100); //Patriot
  240.     Car_Militares[21] = AddStaticVehicleEx(519,-1467.4004000,467.5000000,8.2000000,270.0000000,160,128,100); //Shamal
  241.     Car_Militares[22] = AddStaticVehicleEx(595,-1476.5000000,491.0996100,0.0000000,359.9950000,160,128,100); //Launch ****** ID 35
  242.  
  243. //base Terroristas
  244.     Car_Terrorista[0] = AddStaticVehicleEx(411,-2127.0000000,-198.5000000,35.1000000,180.0000000,3,3,100); //Infernus
  245.     Car_Terrorista[1] = AddStaticVehicleEx(411,-2122.6001000,-198.3999900,35.1000000,180.0000000,3,3,100); //Infernus
  246.     Car_Terrorista[2] = AddStaticVehicleEx(411,-2118.1001000,-198.3999900,35.1000000,180.0000000,3,3,100); //Infernus
  247.     Car_Terrorista[3] = AddStaticVehicleEx(411,-2113.3999000,-198.5000000,35.1000000,180.0000000,3,3,100); //Infernus
  248.     Car_Terrorista[4] = AddStaticVehicleEx(411,-2108.1001000,-198.3000000,35.1000000,180.0000000,3,3,100); //Infernus
  249.     Car_Terrorista[5] = AddStaticVehicleEx(411,-2102.1001000,-198.5000000,35.1000000,180.0000000,3,3,100); //Infernus
  250.     Car_Terrorista[6] = AddStaticVehicleEx(522,-2155.6001000,-191.6000100,35.0000000,92.0000000,3,3,100); //NRG-500
  251.     Car_Terrorista[7] = AddStaticVehicleEx(522,-2155.8000000,-193.3000000,35.0000000,92.0000000,3,3,100); //NRG-500
  252.     Car_Terrorista[8] = AddStaticVehicleEx(522,-2155.6001000,-195.6000100,35.0000000,92.0000000,3,3,100); //NRG-500
  253.     Car_Terrorista[9] = AddStaticVehicleEx(522,-2155.8000000,-198.5000000,35.0000000,92.0000000,3,3,100); //NRG-500
  254.     Car_Terrorista[10] = AddStaticVehicleEx(522,-2155.7000000,-203.5000000,35.0000000,92.0000000,3,3,100); //NRG-500
  255.     Car_Terrorista[11] = AddStaticVehicleEx(522,-2155.7000000,-200.8000000,35.0000000,92.0000000,3,3,100); //NRG-500
  256.     Car_Terrorista[12] = AddStaticVehicleEx(470,-2134.6609000,-242.2063000,35.3138000,271.1147000,3,3,100); //Patriot
  257.     Car_Terrorista[13] = AddStaticVehicleEx(470,-2134.6001000,-238.3999900,35.4000000,270.0000000,3,3,100); //Patriot
  258.     Car_Terrorista[14] = AddStaticVehicleEx(470,-2134.6001000,-233.8999900,35.4000000,270.0000000,3,3,100); //Patriot
  259.     Car_Terrorista[15] = AddStaticVehicleEx(470,-2134.6001000,-228.3000000,35.4000000,270.0000000,3,3,100); //Patriot
  260.     Car_Terrorista[16] = AddStaticVehicleEx(476,-2021.2998000,-273.2002000,36.8000000,358.1380000,3,3,100); //Rustler
  261.     Car_Terrorista[17] = AddStaticVehicleEx(513,-2058.0000000,-271.7000100,36.1000000,0.0000000,3,3,100); //Stunt
  262.     Car_Terrorista[18] = AddStaticVehicleEx(513,-2071.8000000,-271.3999900,36.1000000,0.0000000,3,3,100); //Stunt
  263.     Car_Terrorista[19] = AddStaticVehicleEx(476,-2038.2000000,-272.7999900,36.5000000,358.1380000,3,3,100); //Rustler
  264.     Car_Terrorista[20] = AddStaticVehicleEx(487,-2115.5000000,-186.8000000,46.5000000,90.0000000,3,3,100); //Maverick
  265.  
  266. //Veiculos Triads
  267.     Car_Triads[0] = AddStaticVehicleEx(487,-2190.5996100,1045.5000000,88.6000000,180.0000000,146,146,100); //Maverick
  268.     Car_Triads[1] = AddStaticVehicleEx(513,-2204.8999000,968.9000200,85.6000000,0.0000000,146,146,100); //Stunt
  269.     Car_Triads[2] = AddStaticVehicleEx(470,-2197.7000000,1032.5000000,80.1000000,182.0000000,146,146,100); //Patriot
  270.     Car_Triads[3] = AddStaticVehicleEx(470,-2190.2000000,1032.6000000,80.1000000,182.0000000,146,146,100); //Patriot
  271.     Car_Triads[4] = AddStaticVehicleEx(470,-2182.7000000,1032.7000000,80.1000000,182.0000000,146,146,100); //Patriot
  272.     Car_Triads[5] = AddStaticVehicleEx(451,-2198.3000000,965.2999900,79.8000000,270.0000000,146,146,100); //Turismo
  273.     Car_Triads[6] = AddStaticVehicleEx(451,-2198.2000000,971.5000000,79.8000000,270.0000000,146,146,100); //Turismo
  274.     Car_Triads[7] = AddStaticVehicleEx(451,-2198.3000000,977.7999900,79.8000000,270.0000000,146,146,100); //Turismo
  275.     Car_Triads[8] = AddStaticVehicleEx(451,-2198.5000000,983.7999900,79.8000000,270.0000000,146,146,100); //Turismo
  276.     Car_Triads[9] = AddStaticVehicleEx(415,-2198.6001000,990.0000000,79.8000000,270.0000000,146,146,100); //Cheetah
  277.     Car_Triads[10] = AddStaticVehicleEx(415,-2198.3999000,996.0000000,79.8000000,270.0000000,146,146,100); //Cheetah
  278.     Car_Triads[11] = AddStaticVehicleEx(415,-2198.5000000,1002.3000000,79.8000000,270.0000000,146,146,100); //Cheetah
  279.     Car_Triads[12] = AddStaticVehicleEx(415,-2198.3000000,1008.3000000,79.8000000,270.0000000,146,146,100); //Cheetah
  280.     Car_Triads[13] = AddStaticVehicleEx(522,-2235.3999000,1012.9000000,83.5000000,272.0000000,146,146,100); //NRG-500
  281.     Car_Triads[14] = AddStaticVehicleEx(522,-2235.3999000,1015.8000000,83.5000000,272.0000000,146,146,100); //NRG-500
  282.     Car_Triads[15] = AddStaticVehicleEx(522,-2235.3999000,1018.6000000,83.3000000,272.0000000,146,146,100); //NRG-500
  283.     Car_Triads[16] = AddStaticVehicleEx(522,-2235.3999000,1021.6000000,83.4000000,272.0000000,146,146,100); //NRG-500
  284.     Car_Triads[17] = AddStaticVehicleEx(522,-2235.6001000,1025.1000000,83.5000000,272.0000000,146,146,100); //NRG-500
  285. //***
  286. //***
  287. //*** Se tu for adicionar mais Orgs, coisa que envolva mais veículos, faz um "new PrimeiroCarroOrgX = CreateVehicle(....);"
  288. //*** Aí depois na hora de contar tu só joga o nome da var ao invés de ficar contando.
  289. //***
  290. //Objetos Triads
  291.     CreateObject(3475,-2161.3999000,1010.6000000,81.4000000,0.0000000,0.0000000,0.0000000); //object(vgsn_fncelec_pst) (1)
  292.     CreateObject(3475,-2162.1001000,1028.3000000,81.4000000,0.0000000,0.0000000,182.0000000); //object(vgsn_fncelec_pst) (2)
  293.     CreateObject(3934,-2190.3999000,1045.5000000,87.3000000,0.0000000,0.0000000,88.0000000); //object(helipad01) (1)
  294.     CreateObject(8613,-2207.8999000,1053.7000000,82.9000000,0.0000000,0.0000000,0.0000000); //object(vgssstairs03_lvs) (1)
  295.     CreateObject(8615,-2205.5000000,961.2999900,81.8000000,0.0000000,0.0000000,358.0000000); //object(vgssstairs04_lvs) (1)
  296.     CreateObject(987,-2237.1001000,1029.2000000,82.8000000,0.0000000,0.0000000,268.0000000); //object(elecfence_bar) (1)
  297.     CreateObject(987,-2237.3999000,1017.3000000,82.6000000,0.0000000,0.0000000,267.9950000); //object(elecfence_bar) (2)
  298. //==============================================================================
  299. //terroristas
  300.     CreateObject(3934,-2114.8999000,-186.8999900,45.3000000,0.0000000,0.0000000,0.0000000); //object(helipad01) (1)
  301.     CreateObject(14407,-2099.8000000,-278.7000100,37.5000000,0.0000000,0.0000000,92.0000000); //object(carter-stairs01) (2)
  302.     CreateObject(14407,-2093.1001000,-278.7000100,37.5000000,0.0000000,0.0000000,270.0000000); //object(carter-stairs01) (3)
  303.     CreateObject(14407,-2109.1001000,-178.2000000,37.5000000,0.0000000,0.0000000,89.9950000); //object(carter-stairs01) (4)
  304.     CreateObject(14407,-2100.6001000,-178.2000000,42.9000000,0.0000000,0.0000000,89.9950000); //object(carter-stairs01) (6)
  305. //==============================================================================
  306.     CreateObject(8615,-2453.7000000,523.2000100,47.3000000,0.0000000,0.0000000,90.0000000); //object(vgssstairs04_lvs) (1)
  307.     CreateObject(3279,-2464.5000000,503.5000000,29.1000000,0.0000000,0.0000000,0.0000000); //object(a51_spottower) (2)
  308. //Helipad
  309.     CreateObject(3934,-1407.1000000,495.0000000,17.3000000,0.0000000,0.0000000,90.0000000); //object(helipad01) (1)
  310.     CreateObject(3934,-1409.2000000,491.7000100,17.2000000,0.0000000,0.0000000,90.0000000); //object(helipad01) (2)
  311.     CreateObject(3934,-1421.1000000,496.5000000,17.3000000,0.0000000,0.0000000,270.0000000); //object(helipad01) (3)
  312.     CreateObject(3934,-1310.7000000,496.7999900,17.3000000,0.0000000,0.0000000,270.0000000); //object(helipad01) (4)
  313.     CreateObject(3934,-1290.0000000,497.5000000,17.4000000,0.0000000,0.0000000,270.0000000); //object(helipad01) (5)
  314.     CreateObject(3934,-1267.6000000,497.0000000,17.4000000,0.0000000,0.0000000,270.0000000); //object(helipad01) (6)
  315. //==============================================================================
  316.     CreateObject(987,-1641.8000000,360.6000100,6.2000000,0.0000000,0.0000000,356.0000000); //object(elecfence_bar) (1)
  317.     CreateObject(987,-1630.0000000,359.7000100,6.2000000,0.0000000,0.0000000,357.9950000); //object(elecfence_bar) (2)
  318.     CreateObject(987,-1618.3000000,359.3999900,6.2000000,0.0000000,0.0000000,357.9950000); //object(elecfence_bar) (3)
  319.     CreateObject(1698,-1467.1000000,485.3999900,0.0000000,0.0000000,0.0000000,180.0000000); //object(esc_step8) (1)
  320.     CreateObject(1698,-1468.6000000,486.8999900,0.0000000,0.0000000,0.0000000,180.0000000); //object(esc_step8) (2)
  321.     CreateObject(1698,-1461.1000000,491.0000000,0.0000000,0.0000000,0.0000000,270.0000000); //object(esc_step8) (3)
  322.     CreateObject(1698,-1464.4000000,491.0000000,0.0000000,0.0000000,0.0000000,269.9950000); //object(esc_step8) (4)
  323.     CreateObject(1698,-1467.7000000,491.0000000,0.0000000,0.0000000,0.0000000,269.9950000); //object(esc_step8) (5)
  324.     CreateObject(1698,-1468.6000000,488.7999900,0.0000000,0.0000000,0.0000000,179.9950000); //object(esc_step8) (6)
  325.     CreateObject(1698,-1467.1000000,488.7000100,0.0000000,0.0000000,0.0000000,179.9950000); //object(esc_step8) (7)
  326.     CreateObject(1698,-1467.6000000,488.8999900,0.0000000,0.0000000,0.0000000,179.9950000); //object(esc_step8) (8)
  327.     CreateObject(1698,-1468.1000000,486.8999900,0.0000000,0.0000000,0.0000000,179.9950000); //object(esc_step8) (9)
  328.     CreateObject(18446,-1437.5000000,514.0000000,17.0000000,0.0000000,2.0000000,200.9980000); //object(mtbfence43) (1)
  329.     CreateObject(18446,-1391.5000000,514.0999800,17.0000000,0.0000000,2.0000000,200.9950000); //object(mtbfence43) (2)
  330.     CreateObject(18446,-1367.4000000,514.2999900,17.0000000,0.0000000,2.0000000,200.9950000); //object(mtbfence43) (3)
  331.     CreateObject(18446,-1343.5000000,514.2999900,17.0000000,0.0000000,2.0000000,200.9950000); //object(mtbfence43) (4)
  332.     CreateObject(18446,-1325.2000000,514.2999900,17.0000000,0.0000000,2.0000000,200.9950000); //object(mtbfence43) (5)
  333.  
  334. //==============================================================================
  335.  
  336.     BemVindo = TextDrawCreate(300.0, 436.5," ~h~Seja ~h~Bem ~h~Vindo");
  337.     TextDrawAlignment(BemVindo, 2);
  338.     TextDrawColor(BemVindo, COLOR_WHITE);
  339.     TextDrawFont(BemVindo, 0);
  340.     TextDrawLetterSize(BemVindo, 1.0 ,1.0);
  341.     TextDrawSetShadow(BemVindo, 0);
  342.     TextDrawUseBox(BemVindo, 2);
  343.     TextDrawBoxColor(BemVindo, 0x000000FF);
  344.  
  345.     //texdraw
  346.     GM = TextDrawCreate(490.0, 350.0," ~h~Death");
  347.     TextDrawColor(GM, 0xFF0000FF);
  348.     TextDrawFont(GM, 0);
  349.     TextDrawLetterSize(GM, 0.90, 2.4);
  350.     TextDrawSetShadow(GM, 2);
  351.     TextDrawBackgroundColor(GM, 0x000000FF );
  352.    
  353.     //texdraw death
  354.     GM1 = TextDrawCreate(560.0, 350.0," ~h~Match");
  355.     TextDrawColor(GM1, 0x0000FFFF);
  356.     TextDrawFont(GM1, 0);
  357.     TextDrawLetterSize(GM1, 0.80, 2.4);
  358.     TextDrawSetShadow(GM1, 2);
  359.     TextDrawBackgroundColor(GM1, 0x000000FF );
  360.  
  361.     //site
  362.     Site = TextDrawCreate(500.0, 375.0," portalsampbr.forumeiros.com");
  363.     TextDrawColor(Site, 0xFFFFFFFF);
  364.     TextDrawFont(Site, 1);
  365.     TextDrawLetterSize(Site, 0.25, 1.0);
  366.     TextDrawSetShadow(Site, 0);
  367.     TextDrawBackgroundColor(Site, 0x000000FF );
  368.    
  369.     //relogio e data
  370.     Textdraw0 = TextDrawCreate(565.0, 390.0, "00:00:00");
  371.     TextDrawBackgroundColor(Textdraw0, 255);
  372.     TextDrawFont(Textdraw0, 1);
  373.     TextDrawLetterSize(Textdraw0, 0.30, 1.0);
  374.     TextDrawColor(Textdraw0, -1);
  375.     TextDrawSetOutline(Textdraw0, 0);
  376.     TextDrawSetProportional(Textdraw0, 1);
  377.     TextDrawSetShadow(Textdraw0, 1);
  378.  
  379.     Textdraw1 = TextDrawCreate(503.0, 390.0, "(00/00/00)");
  380.     TextDrawBackgroundColor(Textdraw1, 255);
  381.     TextDrawFont(Textdraw1, 1);
  382.     TextDrawLetterSize(Textdraw1, 0.30, 1.0);
  383.     TextDrawColor(Textdraw1, -1);
  384.     TextDrawSetOutline(Textdraw1, 0);
  385.     TextDrawSetProportional(Textdraw1, 1);
  386.     TextDrawSetShadow(Textdraw1, 1);
  387.  
  388.  
  389.    
  390.     // arena DM
  391.     CreateObject(987,2387.8999000,1543.8000000,27.9000000,0.0000000,0.0000000,180.0000000); //object(elecfence_bar) (1)
  392.     CreateObject(987,2376.2000000,1543.8000000,27.9000000,0.0000000,0.0000000,180.0000000); //object(elecfence_bar) (2)
  393.     CreateObject(987,2364.7000000,1543.8000000,27.9000000,0.0000000,0.0000000,180.0000000); //object(elecfence_bar) (3)
  394.     CreateObject(987,2375.7000000,1602.8000000,27.9000000,0.0000000,0.0000000,0.0000000); //object(elecfence_bar) (4)
  395.     CreateObject(987,2363.7000000,1602.8000000,27.9000000,0.0000000,0.0000000,0.0000000); //object(elecfence_bar) (5)
  396.     CreateObject(987,2351.8999000,1602.8000000,27.9000000,0.0000000,0.0000000,0.0000000); //object(elecfence_bar) (6)
  397.  
  398.    
  399.     SetGameModeText("Brazil TDM Basic 2.0");//Nome do Gamemode
  400. // =========================== MILITARES =======================================
  401.     AddPlayerClass(121,-1359.6172,489.7504,24.2969,89.8915,16,10,0,0,0,0);  //  0
  402.     AddPlayerClass(287,-1461.9897,490.5496,18.2344,276.1779,16,10,0,0,0,0); //  1
  403.     AddPlayerClass(117,-1277.5145,497.7430,18.2344,343.4592,16,10,0,0,0,0); //  2
  404.     // =========================== MAFIA =======================================
  405.     AddPlayerClass(123,-2445.7893,526.7397,30.1211,27.0658,16,10,0,0,0,0) ; //  3
  406.     AddPlayerClass(124,-2464.1338,503.3128,37.7782,92.1591,16,10,0,0,0,0);  //  4
  407.     AddPlayerClass(126,-2457.7957,539.4711,30.0721,261.2480,16,10,0,0,0,0); //  5
  408.     //========================== TERRORISTAS ===================================
  409.     AddPlayerClass(28,-2064.9551,-277.0950,35.3203,335.1935,18,10,0,0,0,0); //  6
  410.     AddPlayerClass(29,-2182.5837,-223.2722,36.5156,33.3441,18,10,0,0,0,0);  //  7
  411.     AddPlayerClass(46,-2155.0957,-114.0387,35.3203,181.0893,18,10,0,0,0,0); //  8
  412.     //=========================== TRIADS =======================================
  413.     AddPlayerClass(117,-2209.5002,963.2730,84.8594,325.5063,18,10,0,0,0,0); // 9
  414.     AddPlayerClass(118,-2185.9351,1053.2732,88.3125,3.0440,18,10,0,0,0,0); // 10
  415.     AddPlayerClass(120,-2229.6597,1019.3564,83.6849,274.7444,18,10,0,0,0,0); // 11
  416.     return 1;
  417.  
  418. }
  419. public OnPlayerRequestClass (playerid, classid)
  420. {
  421.    
  422.     SetPlayerPos(playerid,-325.1284,1505.5378,84.5203); // PLAYER Fica para a escolha
  423.     SetPlayerCameraPos(playerid,-323.8512,1500.7587,87.2668); // CAMERA
  424.     SetPlayerCameraLookAt(playerid,-325.1284,1505.5378,84.5203); // Para aonde a Camera Vira
  425.     SetPlayerFacingAngle(playerid, 189.9624); //Angulo que o Player Olha
  426.     ApplyAnimation(playerid, "DANCING","DAN_LOOP_A", 4.0,1,0,0,0,-1); // Animação No Inicio =D
  427.  
  428.     if((classid >= 0) && (classid <= 2))
  429.     {
  430.     gTeam[playerid] = Mafia;
  431.     GameTextForPlayer(playerid,"~n~~n~~n~~g~Militares",5000,5);
  432.     SetPlayerColor(playerid, CorMilitares);
  433.  
  434.     }
  435.     if((classid >= 3) && (classid <= 5))
  436.     {
  437.     gTeam[playerid] = Militares;
  438.     GameTextForPlayer(playerid,"~n~~n~~n~~b~Mafia",5000,5);
  439.     SetPlayerColor(playerid, CorMafia);
  440.     }
  441.    
  442.     if((classid >= 6) && (classid <= 8))
  443.     {
  444.     gTeam[playerid] = Terroristas;
  445.     GameTextForPlayer(playerid,"~n~~n~~n~~r~Terroristas",5000,5);
  446.     SetPlayerColor(playerid, CorTerroristas);
  447.     }
  448.     if((classid >= 9) && (classid <= 11))
  449.     {
  450.     gTeam[playerid] = Triads;
  451.     GameTextForPlayer(playerid,"~p~~u~Triads~d~",5000,5);
  452.     SetPlayerColor(playerid, CorTriads);
  453.     }
  454.     return 1;
  455.    
  456. }
  457. public OnGameModeExit()
  458. {
  459.     return 1;
  460. }
  461. public OnPlayerConnect(playerid)
  462. {
  463.     SendDeathMessage(INVALID_PLAYER_ID, playerid, 200);
  464.    
  465.     TextDrawShowForPlayer(playerid,BemVindo);
  466.     TextDrawShowForPlayer(playerid,GM);
  467.     TextDrawShowForPlayer(playerid,GM1);
  468.     TextDrawShowForPlayer(playerid,Site);
  469.    
  470.     TextDrawShowForPlayer(playerid, Textdraw0);//nome da draw no caso a que definimos la emcima
  471.     TextDrawShowForPlayer(playerid, Textdraw1);
  472.  
  473.  
  474.     {
  475.     SendClientMessage(playerid, COLOR_LIMON, "==================================================================");
  476.     SendClientMessage(playerid, COLOR_YELLOW,"Seja Bem Vindo, Project Death Match");
  477.     SendClientMessage(playerid, COLOR_ORANGE,"Mate ou Morra Aqui é Death Match");
  478.     SendClientMessage(playerid, COLOR_DARKGREEN,"Agradecimentos a Equipe StrategyPoint www.strategypoint.com.br");
  479.     SendClientMessage(playerid, COLOR_LIGHTBLUE,"Qualquer Dúvida , Contate um Administrador ou Digite &[mensagem]");
  480.     SendClientMessage(playerid, COLOR_RED,"Gamemode Criado por [NNF]ChryyS.");
  481.     SendClientMessage(playerid, COLOR_DARKBLUE,"Agradecimentos à [NNF]Minds.");
  482.     SendClientMessage(playerid, COLOR_PINK,"Em Breve Sistema de Equipes");
  483.     SendClientMessage(playerid, COLOR_LIMON, "==================================================================");
  484.     }
  485.    
  486.     {
  487.     RemoveBuildingForPlayer(playerid, 966,-1526.3906, 481.38281, 6.17969, 200.0);
  488.     RemoveBuildingForPlayer(playerid, 968,-1526.4375, 481.38281, 6.90625, 200.0);
  489.     return 1;
  490. }
  491.  
  492. }
  493. public OnPlayerDisconnect(playerid)
  494. {
  495.     SendDeathMessage(INVALID_PLAYER_ID, playerid, 201);
  496. }
  497. //==========COMANDOS==========
  498. CMD:afk (playerid, params[])
  499. {
  500.     SetPlayerInterior(playerid, 17);
  501.     SetPlayerVirtualWorld(playerid, 1);
  502.     SetPlayerPos(playerid, 488.3956,-1.9185,1002.3828,175.0163);
  503.     ResetPlayerWeapons(playerid);
  504.     ResetPlayerMoney(playerid);
  505.     SendClientMessage(playerid, COLOR_LIGHTYELLOW,"[AFK] Você está em modo AFK,Para sair digite /AFKOFF");
  506.     return 1;
  507. }
  508. CMD:afkoff (playerid, params[])
  509. {
  510.     SetPlayerInterior(playerid, 0);
  511.     SetPlayerVirtualWorld(playerid, 0);
  512.     SpawnPlayer(playerid);
  513.     SendClientMessage(playerid, COLOR_LIGHTYELLOW,"[AFK] Você não está mais em modo AFK");
  514.     return 1;
  515. }
  516.  
  517. CMD:kill (playerid, parms [])
  518. {
  519.     SetPlayerHealth(playerid, 0);
  520.     SetTimerEx("Kill", 5000, false, "i", playerid);
  521.     SendClientMessage(playerid,COLOR_RED,"[KILL]Você se suicidou.");
  522.     ResetPlayerMoney(playerid);
  523.     return 1;
  524. }
  525.  
  526. CMD:vida (playerid, parms [])
  527. {
  528.     SetPlayerHealth(playerid, 100);
  529.     GivePlayerMoney(playerid, -5000);
  530.     SendClientMessage(playerid,COLOR_YELLOW,"[COMPRA]Vida comprada com sucesso." );
  531.     return 1;
  532. }
  533.  
  534. CMD:colete (playerid, parms [])
  535. {
  536.     SetPlayerArmour(playerid, 100);
  537.     GivePlayerMoney(playerid, -5000);
  538.     SendClientMessage(playerid,COLOR_YELLOW,"[COMPRA]Colete comprado com sucesso." );
  539.     return 1;
  540. }
  541.  
  542. CMD:kit(playerid, parms [])
  543. {
  544.     GivePlayerWeapon(playerid, 26,499);
  545.     GivePlayerWeapon(playerid, 31,499);
  546.     GivePlayerWeapon(playerid, 28,499);
  547.     GivePlayerWeapon(playerid, 16,10);
  548.     GivePlayerWeapon(playerid, 42,500);
  549.     GivePlayerWeapon(playerid, 9,1);
  550.     GivePlayerMoney(playerid, -15000);
  551.     SendClientMessage(playerid,COLOR_YELLOW,"[COMPRA] Kit comprado com sucesso." );
  552.     return 1;
  553. }
  554.  
  555. CMD:comandos(playerid, parms [])
  556. {
  557.  
  558.     SendClientMessage(playerid, COLOR_BLUE,"||====================[ Comandos ]====================||");
  559.     SendClientMessage(playerid, -1  ,"||>> /ajuda, /admins, /regras, /dm ");
  560.     SendClientMessage(playerid, -1  ,"||>> /Vida, /Colete, /Kill, /Kit, /nrg, /infernus");
  561.     SendClientMessage(playerid, COLOR_BLUE,"||====================[ Comandos ]====================||");
  562.     return 1;
  563.  
  564. }
  565.  
  566. CMD:ajuda(playerid, parms [])
  567. {
  568.     SendClientMessage(playerid, COLOR_BLUE,"||=========================[ Ajuda ]=========================||");
  569.     SendClientMessage(playerid, -1  ,"||>> Digite: /Comandos > Mostra todos os comandos do servidor,");
  570.     SendClientMessage(playerid, -1  ,"||>> Digite: /Regras   > Para ver as regras do servidor,");
  571.     SendClientMessage(playerid, -1  ,"||>> Digite: /Admins   > Para saber ver os admins do servidor,");
  572.     SendClientMessage(playerid, -1  ,"||>>                                                      ");
  573.     SendClientMessage(playerid, COLOR_YELLOW,"||                                     Em breve mais funções");
  574.     SendClientMessage(playerid, -1  ,"||>>                                                      ");
  575.     SendClientMessage(playerid, COLOR_BLUE,"||=========================[ Ajuda ]=========================||");
  576.     return 1;
  577. }
  578.  
  579. CMD:regras(playerid, params[])
  580. {
  581.     SendClientMessage(playerid, COLOR_BLUE,"||=========================[ Regras ]=========================||");
  582.     SendClientMessage(playerid, COLOR_WHITE,"* Proibido Bater/matar dentro de Ammu-Nation");
  583.     SendClientMessage(playerid, COLOR_WHITE,"* Não ofender ou desrespeitar os outros jogadores");
  584.     SendClientMessage(playerid, COLOR_WHITE,"* Não fazer propaganda de Sites/Servidores/Comunidades");
  585.     SendClientMessage(playerid, COLOR_WHITE,"* Proibido qualquer Mod(hack) que lhe traga vantagem");
  586.     SendClientMessage(playerid, COLOR_WHITE,"* Evite Flood (mensagens repetidas).");
  587.     SendClientMessage(playerid, COLOR_WHITE,"* Cadastrar no forum com seu nick do jogo.");
  588.     SendClientMessage(playerid, COLOR_BLUE,"||=========================[ Regras ]=========================||");
  589.     return 1;
  590. }
  591.  
  592. CMD:nrg(playerid)
  593. {
  594.     new Float:pX, Float:pY, Float:pZ;
  595.     GetPlayerPos(playerid, pX, pY, pZ);
  596.     nrg[playerid] = CreateVehicle(522, pX, pY, pZ, 0.0,-1,-1, -1);
  597.     PutPlayerInVehicle(playerid, nrg[playerid], 0);
  598.     return true;
  599. }
  600.  
  601. CMD:hydra(playerid)
  602. {
  603.     new Float:pX, Float:pY, Float:pZ;
  604.     GetPlayerPos(playerid, pX, pY, pZ);
  605.     nrg[playerid] = CreateVehicle(520, pX, pY, pZ, 0.0,-1,-1, -1);
  606.     PutPlayerInVehicle(playerid, nrg[playerid], 0);
  607.     return true;
  608. }
  609.  
  610. CMD:infernus(playerid)
  611. {
  612.     new Float:pX, Float:pY, Float:pZ;
  613.     GetPlayerPos(playerid, pX, pY, pZ);
  614.     nrg[playerid] = CreateVehicle(411, pX, pY, pZ, 0.0,-1,-1, -1);
  615.     PutPlayerInVehicle(playerid, nrg[playerid], 0);
  616.     return true;
  617. }
  618.  
  619. CMD:dm(playerid)
  620. {
  621.     SendClientMessage(playerid, COLOR_ORANGE,"Bem Vindo 'ARENA DM', Mate quantos puder.");
  622.    
  623.     SetPlayerVirtualWorld(playerid, 3);
  624.     SetPlayerPos(playerid, 2371.6279,1568.9275,27.9443,36.5975);
  625.     SetPlayerArmour(playerid, 100);
  626.     SetPlayerHealth(playerid, 100);
  627.     GivePlayerWeapon(playerid, 16,9999);
  628.     GivePlayerWeapon(playerid, 24,9999);
  629.     GivePlayerWeapon(playerid, 26,9999);
  630.     GivePlayerWeapon(playerid, 31,9999);
  631.     GivePlayerWeapon(playerid, 32,9999);
  632.     GivePlayerWeapon(playerid, 34,9999);
  633.     return 1;
  634.  }
  635.  
  636. CMD:limparchat(playerid, params[])
  637. {
  638.    for(new a = 0; a < 95; a++)
  639.    {
  640.       SendClientMessageToAll(0x33CCFFAA, " ");
  641.    }
  642.    return 1;
  643. }
  644. //Comandos para Admin
  645.  
  646. //==================
  647. public OnPlayerDeath(playerid,killerid,reason)
  648. {
  649.     if(killerid != INVALID_PLAYER_ID)
  650.     {
  651.         SendDeathMessage(killerid,playerid,reason);
  652.     }
  653.     {
  654.     new specid;
  655.      TogglePlayerSpectating(playerid, true);
  656.      PlayerSpectatePlayer(playerid, killerid, 1);
  657.      SetTimerEx("OwnedNoob", 5000, false, "d", playerid);
  658.      return 1;
  659.     }
  660.     {
  661.     SetPlayerScore(killerid, GetPlayerScore(killerid) +1);
  662.     return 1;
  663.     }
  664.     return true;
  665.  
  666. }
  667. public OnPlayerSpawn(playerid)
  668. {
  669.    
  670.     GangZoneShowForAll(Militar, 0x008000FF);
  671.     GangZoneShowForAll(Mafiosos, 0x0000A0FF);
  672.     GangZoneShowForAll(Terrorista, 0x8A0808FF);
  673.     GangZoneShowForAll(Triad,  0xFE2EF7FF);
  674.    
  675.     ResetPlayerMoney(playerid);
  676.     GivePlayerWeapon(playerid,24,500);
  677.     GivePlayerWeapon(playerid,26,500);
  678.     GivePlayerWeapon(playerid,32,500);
  679.     GivePlayerWeapon(playerid,31,500);
  680.     GivePlayerWeapon(playerid,34,500);
  681.     SetPlayerHealth(playerid, 100);
  682.     GivePlayerMoney(playerid, 30000);
  683.     return true;
  684.    
  685.     if(gTeam[playerid] == Mafia)
  686.     {
  687.     SetPlayerPos(playerid, -2445.7893,526.7397,30.1211,27.0658);
  688.     SetPlayerInterior(playerid, 0);
  689.     }
  690.  
  691.     if(gTeam[playerid] == Militares)
  692.     {
  693.     SetPlayerPos(playerid, -1427.1178,495.4426,11.1953,318.1845);
  694.     SetPlayerInterior(playerid, 0);
  695.  
  696.     if(gTeam[playerid] == Terroristas)
  697.     {
  698.     SetPlayerPos(playerid, -2064.9551,-277.0950,35.3203,335.1935);
  699.     SetPlayerInterior(playerid, 0);
  700.     }
  701.     return true;
  702.     }
  703.     return 1;
  704. }
  705. public OnPlayerCommandPerformed(playerid, cmdtext[], success)
  706. {
  707.     if(!success)
  708.     return SendClientMessage(playerid, COLOR_RED, "[ERRO] Digite '/comandos' para ver a lista de todos os comandos.");
  709.     return 1;
  710. }
  711. public hora(playerid)
  712. {
  713.      new str[128],//criamos a primeira string
  714.           str2[128],//criamos a segunda string
  715.                year, //criamos a variavel Ano
  716.                     month,//criamos a Varivel mes
  717.                         day,//criamos a Variavel dia
  718.                             hour,//criamos  a Variavel hora
  719.                                minute;//criamos a Variavel minutos
  720.  
  721.     getdate(day, month, year); //getamos a data em ANO:MES:DIA
  722.     gettime(hour,minute); //getamos o tempo em HORAS:MINUTOS:SEGUNDOS
  723.     new mes[12];//definimos uma Array para armarzenar os meses
  724.  
  725.     if(month == 1) { mes = "1"; }//criamos a primeira IF do mes 1 Voce poderia EX:colocar janeiro no lugar de '1'
  726.     else if(month == 2) {mes = "2";}//getamos o mes 2
  727.     else if(month == 3) {mes = "3";}//getamos o mes 3
  728.     else if(month == 4) {mes = "4";}// Assim em diante lembrando, voce podera colocar o mes em nome! Nao em numeros ai fica a criterio!
  729.     else if(month == 5) {mes = "5";}
  730.     else if(month == 6) {mes = "6";}
  731.     else if(month == 7) {mes = "7";}
  732.     else if(month == 8) {mes = "8";}
  733.     else if(month == 9) {mes = "9";}
  734.     else if(month == 10) {mes = "10";}
  735.     else if(month == 11) {mes = "11";}
  736.     else if(month == 12) {mes= "12";}
  737.     format(str, sizeof(str), "(%d/%s/%d)", day, mes,year);//criamos o formato da string sempre usando o '%d' no caso'DIA/MES/ANO' por isso %d/%d/%d
  738.     TextDrawSetString(Text:Textdraw0, str);//aki a Draw para definir a string,Text:Textdraw0 e o nome da draw la no inicio, a 'str' e a que colocamos no inicio
  739.     format(str2, sizeof(str2), "(%d:%d:)", hour, minute);//aqui usaremos a str2 usamos '%d:%d:%d' de Horas:minutos:segundos
  740.     TextDrawSetString(Text:Textdraw1, str2);//se seu GM usa outra Draw no lugar da Text:Textdraw1 mude
  741. }
  742.  
  743. public OnPlayerStateChange(playerid, newstate, oldstate)
  744. {
  745. /*  new string[128];
  746.     if(newstate == PLAYER_STATE_DRIVER || newstate == PLAYER_STATE_PASSENGER)
  747.     {
  748.         for(new i = Car_Mafia[0]; i < Car_Mafia[12]; i++)
  749.         {
  750.             if(gTeam[playerid] == Mafia)
  751.             {
  752.                 if(GetPlayerVehicleID(playerid) != i)
  753.                 {
  754.                     format(string, sizeof(string), "Você entrou no veiculo id: %d", GetPlayerVehicleID(playerid));
  755.                     SendClientMessage(playerid, 0xFFFFFFFF, string);
  756.                     RemovePlayerFromVehicle(playerid);
  757.                     break;
  758.                 }
  759.             }
  760.         }
  761.         for(new j = Car_Militares[0]; j < Car_Militares[22]; j++)
  762.         {
  763.             if(gTeam[playerid] == Militares)
  764.             {
  765.                 if(GetPlayerVehicleID(playerid) != j)
  766.                 {
  767.                     format(string, sizeof(string), "Você entrou no veiculo id: %d", GetPlayerVehicleID(playerid));
  768.                     SendClientMessage(playerid, 0xFFFFFFFF, string);
  769.                     RemovePlayerFromVehicle(playerid);
  770.                     break;
  771.                 }
  772.             }
  773.         }
  774.     }*/
  775.    
  776.     new str[75];
  777.     new oldnew;
  778.     if (oldnew == 0)
  779.         {
  780.         format(str, sizeof(str), "~g~%s",vehName[GetVehicleModel(GetPlayerVehicleID(playerid))-400]);
  781.         GameTextForPlayer(playerid, str, 5000, 1);
  782.         }
  783. }
  784.  
  785. public OnPlayerEnterVehicle(playerid,vehicleid, ispassenger)
  786. {
  787.     if(gTeam[playerid] != Mafia)
  788.     {
  789.         if(vehicleid <= Car_Militares[22] && vehicleid >= Car_Militares[0])
  790.         {
  791.             new Float:x,Float:y,Float:z;
  792.             GetPlayerPos(playerid, x, y, z);
  793.             SetPlayerPos(playerid, x, y, z+0.5);
  794.             SendClientMessage(playerid, 0xFF0000FF,"Você não é Militar.");
  795.             return 0;
  796.         }
  797.     }
  798.    
  799.     if(gTeam[playerid] != Militares)
  800.     {
  801.         if(vehicleid <= Car_Mafia[12] && vehicleid >= Car_Mafia[0])
  802.         {
  803.             new Float:x,Float:y,Float:z;
  804.             GetPlayerPos(playerid, x, y, z);
  805.             SetPlayerPos(playerid, x, y, z+0.5);
  806.             SendClientMessage(playerid, 0xFF0000FF,"Você não é da Mafia.");
  807.             return 0;
  808.         }
  809.     }
  810.    
  811.     if(gTeam[playerid] != Triads)
  812.     {
  813.         if(vehicleid <= Car_Triads[17] && vehicleid >= Car_Triads[0])
  814.         {
  815.             new Float:x,Float:y,Float:z;
  816.             GetPlayerPos(playerid, x, y, z);
  817.             SetPlayerPos(playerid, x, y, z+0.5);
  818.             SendClientMessage(playerid, 0xFF0000FF,"Você não é da Triads.");
  819.             return 0;
  820.         }
  821.  }
  822.  
  823.  if(gTeam[playerid] != Terroristas)
  824.     {
  825.         if(vehicleid <= Car_Terrorista[20] && vehicleid >= Car_Terrorista[0])
  826.         {
  827.             new Float:x,Float:y,Float:z;
  828.             GetPlayerPos(playerid, x, y, z);
  829.             SetPlayerPos(playerid, x, y, z+0.5);
  830.             SendClientMessage(playerid, 0xFF0000FF,"Você não é Terrorista.");
  831.             return 0;
  832.         }
  833.      }
  834. }
  835. public OwnedNoob(playerid)
  836. {
  837.      TogglePlayerSpectating(playerid, false);
  838.      SpawnPlayer(playerid);
  839.      return 1;
  840. }
  841. public OnPlayerText(playerid, text[])
  842. {
  843. new string[256];
  844.  
  845.     format(string,sizeof(string),"[ID:%d]: %s",playerid,text);
  846.     SendPlayerMessageToAll(playerid,string);
  847.     return 0;
  848. }
Advertisement
Add Comment
Please, Sign In to add comment