SHARE
TWEET

Untitled

a guest Apr 20th, 2019 90 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. //------------------------------------------------
  2. /*
  3.     World War III (dm.pwn)
  4.     * An awesome TEAM-DEATH-MATCH mode based on Las Venturas Deserts.
  5.     * Loads of features, dynamic team system, dynamic capture zone system, textdraws, fun and events.
  6.     * Works with Gammix's personal admin script. Look in filterscripts folder 'admin.pwn'
  7.  
  8.     Author: (creator)
  9.     * Gammix
  10.  
  11.     Contributors:
  12.     * Y_Less - foreach, sscanf2
  13.     * Incognito - Streamer plugin, used dynamic areas
  14.     * Southclaw - Progress bar v2 include
  15.     * joe staff - scren fader include
  16.     * unknown - cuff include
  17.     * Zeex - zcmd include
  18.     * fixes team - samp fixes include
  19.     * Kalcor - Mapandreaas plugin
  20.     * SAMP team
  21.  
  22.     (c) Copyright 2015
  23.     * This file is provided as is (no warranties).
  24. */
  25.  
  26. //------------------------------------------------
  27.  
  28. #include <a_samp> //SAMP team
  29. #include <fixes> //The fixes team
  30. #include <sscanf2> //Y_Less
  31. #include <foreach> //Y_Less
  32. #include <streamer> //Incognito
  33. #include <progress2> //Southclaw
  34. #include <fader> //joe staff
  35. #include <utils> //Gammix
  36. #include <textdraws> //Gammix
  37. #include <gangzones> //Gammix
  38. #include <playerstates> //Gammix
  39. #include <playerstats> //Gammix
  40. #include <playerfuncs> //Gammix
  41. #include <playercalls> //Gammix
  42. #include <colors> //Gammix
  43. #include <dialogs> //Gammix
  44. #include <gadmin> //Gammix
  45. #include <a_OPSVP> //Admigo
  46. #include <zcmd> //Zeex
  47. #include <mapandreas> //Kalcor
  48.  
  49. //remove default game objects
  50. #include "removebuildings"
  51.  
  52. //------------------------------------------------
  53.  
  54. //adjust dialog ids!
  55. #define DIALOG_COMMON       0
  56. #define DIALOG_CLASS        100
  57. #define DIALOG_DIS          110
  58. #define DIALOG_HELP         120
  59. #define DIALOG_DEATHMATCH   130
  60. #define DIALOG_SHOP         140
  61. #define DIALOG_NUKE         150
  62. #define DIALOG_ANTHRAX      160
  63. #define DIALOG_INVENTORY    170
  64. #define DIALOG_PRESTIGE     180
  65. #define DIALOG_DUEL_WEAPON  190
  66. #define DIALOG_DUEL         195
  67. #define DIALOG_SPAWN        200
  68. #define DIALOG_TIME         210
  69. #define DIALOG_WEATHER      220
  70.  
  71. //------------------------------------------------
  72.  
  73. new Text:gClassBGTD;
  74. new PlayerText:gPlayerClassTD[MAX_PLAYERS][2];
  75.  
  76. new PlayerText:gPlayerStatsTD[MAX_PLAYERS];
  77. new Text:gStatsBGTD[5];
  78.  
  79. //------------------------------------------------
  80.  
  81. //Team system!
  82. enum TeamEnum
  83. {
  84.     E_NAME[28],
  85.     E_COLOR,
  86.     E_SKIN
  87. };
  88. //Add as many teams you want, don't worry about rest of the script, ADVANCE!
  89. new gTeam[][TeamEnum] =
  90. {
  91.     //team name         //color             //skin
  92.     {"USA",             0xA0BCFB50,         287}, //team id 0
  93.     {"EUROPE",          0x00FF0050,         285},
  94.     {"LATINO",          0x00CED150,         24},
  95.     {"RUSSIA",          0x8B008B50,         111},
  96.     {"ASIA",            0xFFD70050,         122},
  97.     {"AUSTRALIA",       0x03399950,         73},
  98.     {"INDIA",           0xFF450050,         46},
  99.     {"AFRICA",          0xFFA50050,         102} //8
  100. };
  101. new gPlayerTeam[MAX_PLAYERS] = NO_TEAM;
  102.  
  103. //------------------------------------------------
  104.  
  105. //team spawns
  106. new Float:gUSASpawn[3][4] =
  107. {
  108.     {-250.4795,2598.2092,62.8582,272.7238},
  109.     {-173.5874,2707.8867,62.5998,92.8921},
  110.     {-264.5746,2672.8818,62.6875,271.4703}
  111. };
  112.  
  113. new Float:gEuropeSpawn[3][4] =
  114. {
  115.     {-98.0148,1087.5673,19.8500,359.5242},
  116.     {-193.4192,1154.9584,19.7969,269.5552},
  117.     {-88.3727,1218.6669,19.7422,181.8614}
  118. };
  119. new Float:gRussiaSpawn[3][4] =
  120. {
  121.     {-897.6913,1523.8655,25.7980,270.9159},
  122.     {-741.5120,1578.4148,26.9609,86.3843},
  123.     {-763.1891,1485.2632,24.5426,1.4936}
  124. };
  125.  
  126. new Float:gLatinoSpawn[3][4] =
  127. {
  128.     {-1410.0948,2670.5869,55.8284,101.9383},
  129.     {-1476.1375,2586.2461,55.8359,356.0307},
  130.     {-1492.8325,2694.5264,55.8359,177.7658}
  131. };
  132.  
  133. new Float:gAsiaSpawn[3][4] =
  134. {
  135.     {-2218.5012,2304.6387,20.7381,59.4455},
  136.     {-2300.9004,2348.2734,5.0311,273.7676},
  137.     {-2261.7930,2382.8735,5.0088,128.7164}
  138. };
  139.  
  140. new Float:gAustraliaSpawn[3][4] =
  141. {
  142.     {1383.4690,1038.4839,10.8203,270.6458},
  143.     {1437.4845,973.4548,10.8203,355.8732},
  144.     {1432.3402,1114.3719,10.8203,91.4641}
  145. };
  146.  
  147. new Float:gIndiaSpawn[3][4] =
  148. {
  149.     {997.9725,2515.9270,10.8163,337.0003},
  150.     {1049.8199,2595.4063,10.8203,323.3996},
  151.     {951.9250,2695.5950,10.8203,251.9590}
  152. };
  153.  
  154. new Float:gAfricaSpawn[3][4] =
  155. {
  156.     {1066.0150,1727.5500,10.8203,359.8485},
  157.     {1130.3274,1859.8813,10.5688,80.0626},
  158.     {1051.7714,1927.9229,10.8203}
  159. };
  160.  
  161. //------------------------------------------------
  162.  
  163. //Capture zone system!
  164. #define CAPTURE_TIME        30//in seconds, the maximum time after which the zone will be off the attacker team!
  165.  
  166. enum CaptureZoneEnum
  167. {
  168.     E_ZONENAME[28],
  169.     Float:E_ZONEMINX,
  170.     Float:E_ZONEMINY,
  171.     Float:E_ZONEMAXX,
  172.     Float:E_ZONEMAXY,
  173.     E_ZONEOWNER,
  174.     Float:E_CPX,
  175.     Float:E_CPY,
  176.     Float:E_CPZ,
  177.     E_ZONEATTACKER,
  178.     bool:E_ZONEATTACKED,
  179.     E_ZONEID,
  180.     E_ZONECP,
  181.     E_ZONEICON,
  182.     E_ZONETIMER,
  183.     E_ZONERATE,
  184.     E_ZONERATEI,
  185.     Text3D:E_ZONELABEL
  186. };
  187. //Add as many Capture zones you want, don't worry about rest of the script, ADVANCE!
  188. new gCaptureZone[][CaptureZoneEnum] =
  189. {
  190.     //zone name                 //minX          //minY          //maxX          //maxY          //owner //CPx           //CPy           //CPz       //others - not to be changed
  191.     {"Big Ear",                 -420.4035,      1471.412,       -245.2354,      1646.58,        0,      -298.1169,      1538.4077,      75.5625,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  192.     {"Desert Airport",          163.4902,       2382.287,       467.115,        2627.522,       0,      384.8239,       2535.1963,      16.5391,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  193.     {"Embassy",                 969.2637,       945.9079,       1179.465,       1156.11,        0,      1050.5947,      1011.1202,      11.0000,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  194.     {"Area51",                  81.74512,       1763.359,       326.9805,       1973.561,       1,      254.7359,       1802.2224,      7.4411,     NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  195.     {"Gas Station",             517.8044,       1639.581,       689.6177,       1759.491,       1,      671.8925,       1705.6340,      7.1875,     NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  196.     {"Abandoned Settlement",    -478.7929,      2160.407,       -338.6584,      2277.186,       1,      -422.8697,      2227.8984,      42.4297,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  197.     {"Beach Shack",             213.8855,       2853.3789,      298.1382,       2946.1755,      1,      259.7926,       2889.9695,      11.1329,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  198.     {"Oil Pump",                1015.975,       2861.08,        1097.72,        2977.858,       2,      1048.8944,      2907.4792,      47.8231,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  199.     {"Oil Refinery",            81.74512,       1307.922,       280.269,        1494.768,       2,      220.3940,       1423.1903,      10.5859,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  200.     {"Shooting Range",          759.0619,       1658.258,       840.807,        1716.648,       2,      791.0085,       1676.8516,      5.2813,     NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  201.     {"Snake Farm",              -65.2373,       2311.1003,      10.0603,        2393.9177,      2,      -25.3876,       2346.2954,      24.1347,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  202.     {"Cluckin Bell",            -1249.533,      1763.359,       -1144.432,      1868.46,        3,      -1195.8038,     1814.1815,      41.8190,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  203.     {"Motel",                   -802.8551,      2720.7478,      -741.8143,      2777.7239,      3,      -782.1253,      2751.1729,      45.6628,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  204.     {"Electronics Grid",        -1845.104,      1950.205,       -1786.715,      2090.34,        3,      -1820.7186,     2051.1123,      9.4018,     NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  205.     {"Jays Diner",              -1985.239,      2300.542,       -1903.494,      2405.642,       3,      -1949.5081,     2395.0173,      49.5000,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  206.     {"Spread Ranch",            668.1707,       1920.2765,      732.9704,       2021.4883,      4,      681.7109,       1947.3749,      5.5391,     NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  207.     {"Caravan Park",            -46.0147,       1325.4503,      48.4686,        1414.3330,      4,      -8.5448,        1394.0792,      9.1719,     NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  208.     {"Quarry",                  502.1487,       782.4177,       735.7062,       934.23,         4,      620.5497,       859.8751,       -42.9534,   NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  209.     {"Mountain Outpost",        -842.8987,      2264.4333,      -654.6287,      2454.2888,      4,      -720.1762,      2338.0137,      126.3180,   NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},//mountain outpost
  210.     {"Bait Shop",               -1403.6534,     2042.1500,      -1320.6107,     2148.6382,      5,      -1376.0591,     2108.4932,      42.2000,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  211.     {"Farmville",               -735.7062,      852.4849,       -607.2495,      1004.297,       5,      -688.0816,      937.4944,       13.6328,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  212.     {"Cargo Ship",              -1494.768,      1448.057,       -1319.6,        1529.802,       5,      -1468.1112,     1488.9058,      8.2501,     NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  213.     {"Bio Ship",                -2534.099,      1494.768,       -2253.83,       1599.869,       5,      -2471.2327,     1538.4662,      33.2344,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  214.     {"Fire Department",         -572.0619,      2528.5586,      -491.7644,      2646.3560,      6,      -550.6154,      2593.6748,      53.9348,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},//25
  215.     {"Black Market",            -341.4373,      1714.3163,      -264.2661,      1842.1420,      6,      -317.9809,      1758.1349,      42.7524,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  216.     {"Fuel Depot",              540.2973,       1165.4449,      694.1926,       1308.1895,      6,      589.7242,       1243.9127,      11.7188,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  217.     {"Las Venturas Airport",    1267.5743,      1363.3995,      1520.3319,      1780.0334,      7,      1315.6771,      1588.1575,      10.8203,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  218.     {"Ghost Ship",              -562.3872,      361.8078,       -264.1497,      455.0224,       7,      -485.4115,      423.5143,       32.1677,    NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1},
  219.     {"Shipment",                -531.2891,      819.4126,       -422.2399,      861.9582,       7,      -483.2408,      851.7081,       1.8081,     NO_TEAM, false, -1, -1, -1, -1, -1, 0, Text3D:-1}//shipment
  220. };
  221. new PlayerBar:gPlayerCaptureBar[MAX_PLAYERS];
  222. new PlayerText:gPlayerCaptureTD[MAX_PLAYERS];
  223.  
  224. #define BONUS_INTERVAL      60//in seconds
  225. new gBonusTimer;
  226.  
  227. //------------------------------------------------
  228.  
  229. #define NUKE_INTERVAL           5 * 60//in seconds
  230. #define NUKE_COST               100000
  231. #define NUKE_ZONE               3
  232. enum NukeEnum
  233. {
  234.     NUKE_TIME,
  235.     NUKE_PICKUP,
  236.     NUKE_MAPICON,
  237.     Text3D:NUKE_LABEL,
  238.     NUKE_BASE
  239. };
  240. new gNuke[NukeEnum];
  241.  
  242. //------------------------------------------------
  243.  
  244. #define ANTHRAX_INTERVAL        5 * 60//in seconds
  245. #define ANTHRAX_COST            300000
  246. #define ANTHRAX_ZONE            22
  247. enum AnthraxEnum
  248. {
  249.     ANTHRAX_TIME,
  250.     ANTHRAX_PICKUP,
  251.     ANTHRAX_MAPICON,
  252.     Text3D:ANTHRAX_LABEL
  253. };
  254. new gAnthrax[AnthraxEnum];
  255.  
  256. //------------------------------------------------
  257.  
  258. #define HEALTH_ZONE             11
  259. #define ARMOUR_ZONE             28
  260. #define AMMO_ZONE               9
  261.  
  262. //------------------------------------------------
  263.  
  264. new bool:gStopTimeUpdate;
  265.  
  266. //------------------------------------------------
  267.  
  268. //Team bases system - Limit is set to Total number of teams
  269. enum baseinfo
  270. {
  271.     b_name[25],
  272.     Float:b_minx,
  273.     Float:b_miny,
  274.     Float:b_maxx,
  275.     Float:b_maxy,
  276.     b_owner,
  277.     b_base,//this array store the main gangzone
  278. };
  279. //Add as many team bases you want, don't worry about rest of the script, ADVANCE!
  280. //-These can't be captured and have a anti-base RAPE system
  281. new gTeamBase[][baseinfo] =
  282. {
  283.     //name              //minX          //minY          //maxX          //maxY          //team      //not to change
  284.     {"USA Base",        -397.0478,      2545.777,       -128.4566,      2791.012,       0,          -1},
  285.     {"Europe Base",     -316.3498,      984.9357,       39.2611,        1260.4496,      1,          -1},
  286.     {"Latino Base",     -882.0419,      1395.7887,      -577.5707,      1643.1394,      2,          -1},
  287.     {"Russia Base",     -1635.9943,     2483.5520,      -1351.7336,     2737.8857,      3,          -1},
  288.     {"Asia Base",       -2375.6184,     2157.7810,      -2091.4629,     2457.7959,      4,          -1},
  289.     {"Australia Base",  1268.6326,      871.1526,       1535.1027,      1222.7874,      5,          -1},
  290.     {"India Base",      889.2269,       2469.5754,      1146.2012,      2785.0034,      6,          -1},
  291.     {"African Base",    1010.8282,      1703.0718,      1160.0896,      1981.1257,      7,          -1}
  292. };
  293.  
  294. //------------------------------------------------
  295.  
  296. //team prototypes system
  297. enum PrototypeEnum
  298. {
  299.     p_owner,
  300.     Float:p_x,
  301.     Float:p_y,
  302.     Float:p_z,
  303.     Float:p_a,
  304.     p_attacker,
  305.     bool:p_attacked,
  306.     p_vehicle,
  307.     Text3D:p_label
  308. };
  309. //Add as many Prototype vehicles you want, don't worry about rest of the script, ADVANCE!
  310. new gPrototype[][PrototypeEnum] =
  311. {
  312.     {0,     -207.02456665,      2788.74633789,      62.20212173,        180.0,          INVALID_PLAYER_ID, false, -1},
  313.     {1,     -98.50000000,       1136.40002441,      20.00000000,        0.00000000,     INVALID_PLAYER_ID, false, -1},
  314.     {2,     -786.8142,          1618.1665,          27.2423,            178.4472,       INVALID_PLAYER_ID, false, -1},
  315.     {3,     -1452.5732,         2531.9304,          55.9176,            0.0000,         INVALID_PLAYER_ID, false, -1},
  316.     {4,     -2363.5737,         2336.2415,          5.3080,             0.0000,         INVALID_PLAYER_ID, false, -1},
  317.     {5,     1327.60119629,      1081.08190918,      11.07010269,        180.0,          INVALID_PLAYER_ID, false, -1},
  318.     {6,     1079.92883301,      2659.00097656,      10.83643150,        60.0,           INVALID_PLAYER_ID, false, -1}, // saflag
  319.     {7,     1147.6825,          1969.8088,          10.9441,            179.7380,       INVALID_PLAYER_ID, false, -1}
  320. };
  321. new gPlayerLastVehicle[MAX_PLAYERS];
  322.  
  323. //--------------
  324.  
  325. //final prototype CPs system
  326. //If you want more prototype fina;l CP than number of teams, then remove the "sizeof(gTeam)"
  327. new Float:gPrototypeCP[][3] =
  328. {
  329.     {-250.2719, 2763.9314,  62.5413},
  330.     {-110.8036, 1142.8986,  19.7422},
  331.     {-1461.2549,2621.8860,   55.8359},
  332.     {-645.7891, 1460.2233,   13.4283},
  333.     {-2258.8186,2361.8535,   4.9791},
  334.     {1450.4971, 1108.5300,   10.8203},
  335.     {952.3654,  2733.2458,   10.8203},
  336.     {1109.3235, 1764.7069,   10.8203}
  337. };
  338.  
  339. //------------------------------------------------
  340.  
  341. //rank system
  342. enum RankEnum
  343. {
  344.     r_name[30],
  345.     r_score
  346. };
  347. //Add as many rnaks you want, don't worry about rest of the script, ADVANCE!
  348. //If you want to edit the bonus of ranks, then go to OnPlayerSpawn
  349. new gRank[][RankEnum] =
  350. {
  351.     {"Newbie",              0},
  352.     {"Begginer",            50},
  353.     {"Specialist",          100},
  354.     {"Super Specialist",    200},
  355.     {"Gunnery",             500},
  356.     {"Chief",               1000},
  357.     {"Master Chief",        1500},
  358.     {"Ensign",              2500},
  359.     {"Killer",              4500},
  360.     {"Lieutenant",          8000},
  361.     {"Captain",             10000},
  362.     {"Commander",           13000},
  363.     {"Major",               15000},
  364.     {"Sexy Major",          20000},
  365.     {"Brigadier",           25000},
  366.     {"General",             40000},
  367.     {"Field Marshal",       55000},
  368.     {"Killer",              70000},
  369.     {"Warlord",             150000},
  370.     {"Master Of War",       200000},
  371.     {"God Of War",          999999999}
  372. };
  373.  
  374. //------------------------------------------------
  375.  
  376. new Text:gNotifyTD[3];
  377. new gNotifyTimer[3];
  378.  
  379. new PlayerText:gPNotifyTD[MAX_PLAYERS];
  380. new gPNotifyTimer[MAX_PLAYERS];
  381.  
  382. #define SERVER_WEBSITE  "www.samptdm.com" //change this to your server website address
  383. #define SERVER_IP       "127.109.1.2:7777" //chaange this to your server ip address
  384. new Text:gServerTD[3];
  385.  
  386. //------------------------------------------------
  387.  
  388. new gClass[MAX_PLAYERS];
  389. new bool:gClassSelection[MAX_PLAYERS];
  390. #define CLASS_MEDIC     1
  391. #define CLASS_JETRUNNER 3
  392. #define CLASS_PILOT     4
  393. #define CLASS_SPY       5
  394. new gHealed[MAX_PLAYERS][MAX_PLAYERS];
  395. new gDis[MAX_PLAYERS];
  396. new gPainkillers[MAX_PLAYERS];
  397. new bool:gArmour[MAX_PLAYERS];
  398.  
  399. //------------------------------------------------
  400.  
  401. new Text:gAnnouncementTD;
  402. new server_time;
  403. new server_weather;
  404.  
  405. //------------------------------------------------
  406.  
  407. #define MODE_TEAM_DEATHMATCH    0
  408. //
  409. #define MODE_MINIGUN            1
  410. new Float:gMinigunSpawn[][4] =
  411. {
  412.     {2173.5723,1577.8872,999.9675,358.7795},
  413.     {2205.8892,1580.4723,999.9788,37.6098},
  414.     {2206.0720,1549.6593,1008.0951,296.3788},
  415.     {2232.4290,1589.0771,999.9567,140.0240},
  416.     {2199.4785,1613.1299,999.9723,305.1288}
  417. };
  418. //
  419. #define MODE_MONEYBAG           2
  420. new Float:gMoneybagSpawn[][4] =
  421. {
  422.     {1301.7788,-785.7610,1084.0078,349.9862},
  423.     {1233.7123,-762.2798,1084.0088,198.0181},
  424.     {1277.9406,-792.4418,1084.0078,357.4828},
  425.     {1247.2562,-803.8536,1084.0151,267.8687},
  426.     {1279.7694,-781.3691,1089.9375,219.3016}
  427. };
  428. enum MoneyBagEnum
  429. {
  430.     MONEYBAG_PICKUPID,
  431.     MONEYBAG_PLAYER
  432. };
  433. new gMoneyBag[MoneyBagEnum];
  434. //
  435. #define MODE_RPG                3
  436. new Float:gRPGSpawn[][4] =
  437. {
  438.     {246.9303,1385.9288,23.3703,0.0000},
  439.     {165.2390,1357.2312,26.2036,0.0000},
  440.     {165.9894,1426.7672,26.2623,0.0000},
  441.     {132.4376,1355.1686,26.1223,134.3979},
  442.     {203.1333,1398.6799,43.0946,0.0000}
  443. };
  444. //
  445. #define MODE_GLASS              4
  446. new Float:gGlassSpawn[][4] =
  447. {
  448.     {67.3965,1553.5461,63.2100,135.7074},
  449.     {41.8477,1517.2374,63.2500,320.5758},
  450.     {68.7605,1553.4050,74.3600,146.1037},
  451.     {42.5923,1514.3993,74.3600,322.1987},
  452.     {47.5731,1526.2106,85.4100,324.7054}
  453. };
  454. //
  455. new gPlayerGamemode[MAX_PLAYERS];
  456. new gPlayerSkin[MAX_PLAYERS];
  457.  
  458. //------------------------------------------------
  459.  
  460. new Text3D:gPlayerLabel[MAX_PLAYERS];
  461. new Text3D:gDonorLabel[MAX_PLAYERS];
  462. new gWeaponKills[MAX_PLAYERS][45];
  463.  
  464. //------------------------------------------------
  465.  
  466. enum ShopEnum
  467. {
  468.     Float:SHOP_X,
  469.     Float:SHOP_Y,
  470.     Float:SHOP_Z,
  471.     SHOP_MAPICON,
  472.     SHOP_PICKUP,
  473.     Text3D:SHOP_LABEL,
  474.     SHOP_TEAM
  475. };
  476. new gShop[][ShopEnum] =
  477. {
  478.     {-249.5979,     2607.7800,      62.8582,    -1, -1, Text3D:-1,  0}, //usa
  479.     {-72.8491,      1212.3497,      19.7422,    -1, -1, Text3D:-1,  1},
  480.     {-749.5848,     1585.8888,      26.9609,    -1, -1, Text3D:-1,  2},
  481.     {-1399.7037,    2621.4133,      55.8359,    -1, -1, Text3D:-1,  3},//russia
  482.     {-2279.0632,    2333.4534,      4.9650,     -1, -1, Text3D:-1,  4},//asia
  483.     {1423.6886,     1093.9211,      10.8203,    -1, -1, Text3D:-1,  5},
  484.     {1005.8577,     2692.3618,      10.8203,    -1, -1, Text3D:-1,  6},
  485.     {1153.5768,     1916.5431,      10.8203,    -1, -1, Text3D:-1,  7}, //africa briefcase
  486.     {205.3770,      1871.9420,      13.1470,    -1, -1, Text3D:-1,  NO_TEAM},
  487.     {1316.2604,     1611.9146,      10.8203,    -1, -1, Text3D:-1,  NO_TEAM},
  488.     {413.7192,      2531.1372,      19.1721,    -1, -1, Text3D:-1,  NO_TEAM},
  489.     {694.4229,      1925.4303,      5.6872,     -1, -1, Text3D:-1,  NO_TEAM},
  490.     {-312.6868,     1768.5308,      43.6406,    -1, -1, Text3D:-1,  NO_TEAM},
  491.     {-478.3294,     420.9321,       13.2134,    -1, -1, Text3D:-1,  NO_TEAM},
  492.     {-2466.7185,    1535.9565,      23.6710,    -1, -1, Text3D:-1,  NO_TEAM},//pred's zone
  493.     {-735.8380,     2414.0786,      127.9244,   -1, -1, Text3D:-1,  NO_TEAM},//Bio ship
  494.     {-1226.4960,    1834.9684,      41.6455,    -1, -1, Text3D:-1,  NO_TEAM},
  495.     {-691.3802,     942.0988,       13.6328,    -1, -1, Text3D:-1,  NO_TEAM},
  496.     {-1377.3949,    1493.2915,      11.2031,    -1, -1, Text3D:-1,  NO_TEAM},
  497.     {1092.1471,     996.8791,       11.0000,    -1, -1, Text3D:-1,  NO_TEAM},
  498.     {638.1120,      1683.6479,      6.9922,     -1, -1, Text3D:-1,  NO_TEAM}
  499.  
  500. };
  501. #define SLOT_SUIT   1
  502.  
  503. new bool:gHelmet[MAX_PLAYERS];
  504. new bool:gMask[MAX_PLAYERS];
  505. new bool:gBomb[MAX_PLAYERS];
  506.  
  507. new weapons[] =
  508. {
  509.     335,//knife
  510.     339,//katana
  511.     341,//chainsaw
  512.     342,//grenade
  513.     343,//teargas
  514.     344,//moltove
  515.     346,//9mm
  516.     347,//silenced 9mm
  517.     348,//deagle
  518.     349,//shotgun
  519.     350,//sawnoff shotgun
  520.     351,//combat shotgun
  521.     352,//UZI
  522.     353,//MP5
  523.     355,//ak-47
  524.     356,//m4
  525.     372,//tec-9
  526.     357,//rifle
  527.     358,//sniper rifle
  528.     359,//RPG,
  529.     358,//H.S. rockets
  530.     361,//flamethrower
  531.     363//satchel
  532. };
  533.  
  534. new miscitems[] =
  535. {
  536.     365,//spray
  537.     366,//fire estinguisher
  538.     367,//camera
  539.     368,//night vision goggles
  540.     369,//thermal vision goggles
  541.     371//parachute
  542. };
  543.  
  544. new gListitem[MAX_PLAYERS];
  545.  
  546. //------------------------------------------------
  547.  
  548. new gRandomMessage[][98] =
  549. {
  550.     {"Want to get 3x Ammo? Purchase our cheap DONOR rank!"},
  551.     {"We give full health & armour for donors! Purchase today!"},
  552.     {"Type /Pm to privately message a player and /Dnd to disable PM.s!"},
  553.     {"Are you bored of team deathmatch, go for deathmatch /Dm!"},
  554.     {"Want to duel (1 vs. 1), try /Duel to challenge other players!"},
  555.     {"Want to unlock classes, ranks, bonuses, and more? Get a DONOR rank!"},
  556.     {"You can view your weapons skills with /skills!"},
  557.     {"Checkout your overall stats of game, /stats!"},
  558.     {"Go and register on our forums today, http://forum.sa-mp.com"},
  559.     {"Shoot enemies, kill them and earn money to buy and unlock new stuff!"},
  560.     {"Found a rule breaker, report that asshole; /report (id) (reason)!"},
  561.     {"Are you aware of the rules, if not, then first visit /rules!"},
  562.     {"ADMIN APPLICATION OPEN, apply on forums if you complete the requirements!"}
  563. };
  564. new gRandomMessageIndex;
  565.  
  566. //------------------------------------------------
  567.  
  568. enum AntiSpawnkillEnum
  569. {
  570.     A_TIMER,
  571.     Float:A_HP,
  572.     Float:A_AR,
  573.     Text3D:A_LABEL
  574. };
  575. new gAntiSpawnkill[MAX_PLAYERS][AntiSpawnkillEnum];
  576.  
  577. #if !defined FLOAT_INFINITY
  578.     #define FLOAT_INFINITY (Float:0x7F800000)
  579. #endif
  580.  
  581. #if ! defined IsValidWeapon
  582.     #define IsValidWeapon(%0) (%0 < 47)
  583. #endif
  584.  
  585. //------------------------------------------------
  586.  
  587. //duel system
  588. enum DuelEnum
  589. {
  590.     bool:d_induel,
  591.     d_opponent,
  592.     d_weapon,
  593.     d_bet
  594. };
  595. new gDuel[MAX_PLAYERS][DuelEnum];
  596.  
  597. //------------------------------------------------
  598.  
  599. new prestigeweapons[] =
  600. {
  601.     346,//9mm
  602.     347,//silenced 9mm
  603.     348,//deagle
  604.     349,//shotgun
  605.     350,//sawnoff shotgun
  606.     351,//combat shotgun
  607.     352,//UZI
  608.     353,//MP5
  609.     355,//ak-47
  610.     356,//m4
  611.     372,//tec-9
  612.     357,//rifle
  613.     358,//sniper rifle
  614.     361//flamethrower
  615. };
  616.  
  617. //------------------------------------------------
  618.  
  619. new duelweapons[] =
  620. {
  621.     341,//chainsaw
  622.     342,//grenade
  623.     343,//teargas
  624.     344,//moltove
  625.     346,//9mm
  626.     347,//silenced 9mm
  627.     348,//deagle
  628.     349,//shotgun
  629.     350,//sawnoff shotgun
  630.     351,//combat shotgun
  631.     352,//UZI
  632.     353,//MP5
  633.     355,//ak-47
  634.     356,//m4
  635.     372,//tec-9
  636.     357,//rifle
  637.     358,//sniper rifle
  638.     361//flamethrower
  639. };
  640.  
  641. //------------------------------------------------
  642.  
  643. enum SpawnEnum
  644. {
  645.     Float:s_x,
  646.     Float:s_y,
  647.     Float:s_z,
  648.     Float:s_a,
  649.     s_zoneid
  650. };
  651. new gSpawn[][SpawnEnum] =
  652. {
  653.     {424.9814,  2536.4038,  16.1484,    263.9873,   1}, //DA
  654.     {166.5437,  1907.8031,  18.4831,    291.8274,   3}, //area51
  655.     {-343.6802, 1542.7212,  75.5625,    185.6064,   0}, //big ear
  656.     {997.6724,  1071.5734,  10.8203,    346.3479,   2}, //hospital
  657.     {1340.6506, 1739.8250,  10.8203,    193.7531,   26}, //lv air
  658.     {661.8121,  1719.2596,  6.9922,     31.1416,    4}, //gas station
  659.     {-681.0104, 965.1415,   12.1328,    81.7329,    20}, //farmville
  660.     {-2434.0388,1554.8348,  2.1172,     125.4610,   22}, //bio ship
  661.     {-324.6687, 408.5620,   19.1164,    68.0201,    27}, //ship
  662.     {-696.5515, 2344.1467,  127.5709,   75.9108,    18} //mountain outpost
  663. };
  664. #define SPAWN_BASE  sizeof(gSpawn)
  665. new gPlayerSpawn[MAX_PLAYERS];
  666. new gPlayerMoneyTimer[MAX_PLAYERS];
  667.  
  668. //------------------------------------------------
  669.  
  670. //airdrop system (stor object id)
  671. #define MAX_AIRDROPS     100
  672. //
  673. enum AirdropEnum
  674. {
  675.     AIRDROP_OBJECT,
  676.     bool:AIRDROP_EXIST,
  677.     Float:AIRDROP_POS[3],
  678.     AIRDROP_EXPIRE,
  679.     bool:AIRDROP_PICKED
  680. };
  681. new gAirdrop[MAX_AIRDROPS][AirdropEnum];
  682.  
  683. //------------------------------------------------
  684.  
  685. new gPlayerVehicle[MAX_PLAYERS];
  686. new gDonorSupply[MAX_PLAYERS];
  687. new gPlayerTimer[MAX_PLAYERS];
  688. new gCaptureSpree[MAX_PLAYERS];
  689.  
  690. //------------------------------------------------
  691.  
  692. main()
  693. {
  694.     print("\n------------------------------------------");
  695.     print("Running... | WORLD WAR III | By Gammix\n");
  696.     print("------------------------------------------\n");
  697. }
  698.  
  699. //------------------------------------------------
  700.  
  701. public OnGameModeInit()
  702. {
  703.     //
  704.     print(" ");
  705.     print("Initializing gamemode...");
  706.     print(" ");
  707.     //
  708.    
  709.     MapAndreas_Init(MAP_ANDREAS_MODE_FULL);
  710.    
  711.     //adding prestige weapons in DB
  712.     GAdmin_VerifyColoumn("weapon1", BUD::TYPE_NUMBER);
  713.     GAdmin_VerifyColoumn("weapon2", BUD::TYPE_NUMBER);
  714.     GAdmin_VerifyColoumn("weapon3", BUD::TYPE_NUMBER);
  715.  
  716.     for(new i; i < MAX_AIRDROPS; i++) gAirdrop[i][AIRDROP_EXIST] = false;
  717.  
  718.     SetGameModeText("Tdm/Dm/Freeroam - Build 1");//My fav gamemode name!
  719.  
  720.     EnableVehicleFriendlyFire();//Anti team vehicle damaging
  721.     DisableInteriorEnterExits();
  722.  
  723.     FadeInit();
  724.  
  725.     //add the class selection background box
  726.     gClassBGTD = TextDrawCreateEx(324.000000, 331.000000, "bg", 255, 2, 0.000000, 5.699997, -1, 2, 0, true, 1, true, 100, 410.000000, 175.000000);
  727.  
  728.     //stats Background TDs
  729.     gStatsBGTD[0] = TextDrawCreateEx(-4.000000, 443.000000, "box", 255,1, 0.000000, 1.100000, -1, 1, 1, true, 1, true, 180, 640.000000, 0.000000);
  730.     gStatsBGTD[1] = TextDrawCreateEx(-4.000000, 440.000000, "box", 255,1, 0.000000, -0.099999, -1, 1, 1, true, 1, true, 175, 640.000000, 0.000000);
  731.     gStatsBGTD[2] = TextDrawCreateEx(-4.000000, 437.000000, "box", 255,1, 0.000000, -0.099999, -1, 1, 1, true, 1, true, 150, 640.000000, 0.000000);
  732.     gStatsBGTD[3] = TextDrawCreateEx(-4.000000, 434.000000, "box", 255,1, 0.000000, -0.099999, -1, 1, 1, true, 1, true, 50, 640.000000, 0.000000);
  733.     gStatsBGTD[4] = TextDrawCreateEx(-4.000000, 430.000000, "box", 255,1, 0.000000, -0.099999, -1, 1, 1, true, 1, true, 30, 640.000000, 0.000000);
  734.  
  735.     //ann TD
  736.     gAnnouncementTD = TextDrawCreateEx(4.000000, 442.000000, "~r~~h~~h~~h~Yuri(2) is now participating in /minigun deathmatch with 17 other players. Join in if you want to change gamemode!", 0 , 2, 0.150000, 0.599999, -1, 1 , 1, true);
  737.  
  738.     //add notification TDs
  739.     gNotifyTD[0] = TextDrawCreateEx(330.000000, 358.000000, "-", 255, 1, 0.179997, 0.799997, -1, 1, 1, true);
  740.     gNotifyTimer[0] = -1;
  741.     gNotifyTD[1] = TextDrawCreateEx(330.000000, 366.000000, "-", 255, 1, 0.179997, 0.799997, -1, 1, 1, true);
  742.     gNotifyTimer[1] = -1;
  743.     gNotifyTD[2] = TextDrawCreateEx(330.000000, 374.000000, "-", 255, 1, 0.179997, 0.799997, -1, 1, 1, true);
  744.     gNotifyTimer[2] = -1;
  745.  
  746.     //adding server TDs
  747.     gServerTD[0] = TextDrawCreateEx(580.000000, -92.000000, "LD_POOL:ball", 255, 4, 0.500000, 1.000000, 150, 1, 0, true, 1, true, 0, 108.000000, 131.000000);
  748.     gServerTD[1] = TextDrawCreateEx(637.000000, 3.000000, "~y~~h~~h~WORLD WAR ~g~~h~~h~~h~III", 255, 1, 0.119999, 0.799999, -1, 3, 1, true);
  749.     gServerTD[2] = TextDrawCreateEx(637.000000, 3.000000, "~n~"SERVER_WEBSITE"~n~"SERVER_IP"~n~", 255, 1, 0.149999, 0.899999, -1, 3, 1, true);
  750.  
  751.  
  752.     //moneybag dm
  753.     gMoneyBag[MONEYBAG_PICKUPID] = CreateDynamicPickup(1550, 1, 1226.6163, -809.7188, 1084.0078, MODE_MONEYBAG, 5);
  754.     gMoneyBag[MONEYBAG_PLAYER] = INVALID_PLAYER_ID;
  755.  
  756.     //bonus timer
  757.     gBonusTimer = 0;
  758.     gStopTimeUpdate = true;
  759.  
  760.     //nuke system
  761.     gNuke[NUKE_TIME] = 0;
  762.     gNuke[NUKE_PICKUP] = CreateDynamicPickup(1254, 1, 213.6032, 1822.6310, 6.4141, MODE_TEAM_DEATHMATCH, -1);
  763.     gNuke[NUKE_MAPICON] = CreateDynamicMapIcon(213.6032, 1822.6310, 6.4141, 23, -1, MODE_TEAM_DEATHMATCH, -1, -1, 500.0, MAPICON_GLOBAL);
  764.     gNuke[NUKE_LABEL] = CreateDynamic3DTextLabel("Nuke Station", COLOR_SetTransparency(COLOR_LIGHT_BLUE, 200), 213.6032, 1822.6310, 6.4141, 25.0, _, _, 0, MODE_TEAM_DEATHMATCH);
  765.     gNuke[NUKE_BASE] = 0;
  766.  
  767.     //anthrax system
  768.     gAnthrax[ANTHRAX_TIME] = 0;
  769.     gAnthrax[ANTHRAX_PICKUP] = CreateDynamicPickup(1254, 1, -2471.7590, 1552.6415, 33.2273, MODE_TEAM_DEATHMATCH, -1);
  770.     gAnthrax[ANTHRAX_MAPICON] = CreateDynamicMapIcon(-2471.7590, 1552.6415, 33.2273, 23, -1, MODE_TEAM_DEATHMATCH, -1, -1, 500.0, MAPICON_GLOBAL);
  771.     gAnthrax[ANTHRAX_LABEL] = CreateDynamic3DTextLabel("Anthrax Station", COLOR_SetTransparency(COLOR_LIGHT_BLUE, 200), -2471.7590, 1552.6415, 33.2273, 25.0, _, _, 0, MODE_TEAM_DEATHMATCH);
  772.  
  773.     server_time = 1;
  774.     server_weather = 1;
  775.  
  776.     //Add teams and print result
  777.     print(" ");
  778.     for(new i; i < sizeof(gTeam); i++)
  779.     {
  780.         AddPlayerClass(gTeam[i][E_SKIN], 0,0,0,0,0,0,0,0,0,0);
  781.         printf("** Team created %s, id: %i", gTeam[i][E_NAME], i);
  782.  
  783.         if(i == (sizeof(gTeam) - 1)) printf("-> Total %i teams created from gamemode!", (i + 1));
  784.     }
  785.  
  786.     //Add team bases and print result
  787.     print(" ");
  788.     for(new i; i < sizeof(gTeamBase); i++)
  789.     {
  790.         gTeamBase[i][b_base] = GangZoneCreate(gTeamBase[i][b_minx], gTeamBase[i][b_miny], gTeamBase[i][b_maxx], gTeamBase[i][b_maxy], gTeam[ gTeamBase[i][b_owner] ][E_COLOR], 2.0, COLOR_SetTransparency(COLOR_RED, 0xAA));//this creates the main gangzone
  791.         printf("** Base created %s, base id: %i", gTeamBase[i][b_name], i);
  792.  
  793.         if(i == (sizeof(gTeamBase) - 1)) printf("-> Total %i bases created from gamemode!", (i + 1));
  794.     }
  795.  
  796.     //Add team prototype vehicles and print result
  797.     print(" ");
  798.     new string[56];
  799.     for(new i; i < sizeof(gPrototype); i++)
  800.     {
  801.         gPrototype[i][p_vehicle] = CreateVehicle(428, gPrototype[i][p_x], gPrototype[i][p_y], gPrototype[i][p_z], gPrototype[i][p_a], gTeam[ gPrototype[i][p_owner] ][E_COLOR], random(10), 60);
  802.         SetVehicleVirtualWorld(gPrototype[i][p_vehicle], MODE_TEAM_DEATHMATCH);
  803.         format(string, sizeof(string), "%s Prototype", gTeam[ gPrototype[i][p_owner] ][E_NAME]);
  804.         gPrototype[i][p_label] = CreateDynamic3DTextLabel(string, gTeam[ gPrototype[i][p_owner] ][E_COLOR], 0.0, 0.0, 2.5, 50.0, _, gPrototype[i][p_vehicle], 0, MODE_TEAM_DEATHMATCH, -1);
  805.         printf("** Prototype vehicle created for team %s, id: %i", gTeam[ gPrototype[i][p_owner] ][E_NAME], i);
  806.  
  807.         if(i == (sizeof(gPrototype) - 1)) printf("-> Total %i prototype vehicles created from gamemode!", (i + 1));
  808.     }
  809.  
  810.     //Add capture zones and print result
  811.     print(" ");
  812.     for(new i; i < sizeof(gCaptureZone); i++)
  813.     {
  814.         gCaptureZone[i][E_ZONEID] = GangZoneCreate(gCaptureZone[i][E_ZONEMINX], gCaptureZone[i][E_ZONEMINY], gCaptureZone[i][E_ZONEMAXX], gCaptureZone[i][E_ZONEMAXY], gTeam[ gCaptureZone[i][E_ZONEOWNER] ][E_COLOR], 2.0);
  815.         gCaptureZone[i][E_ZONECP] = CreateDynamicCP(gCaptureZone[i][E_CPX], gCaptureZone[i][E_CPY], gCaptureZone[i][E_CPZ], 5.0, MODE_TEAM_DEATHMATCH, -1, -1, 400.0);
  816.         gCaptureZone[i][E_ZONEICON] = CreateDynamicMapIcon(gCaptureZone[i][E_CPX], gCaptureZone[i][E_CPY], gCaptureZone[i][E_CPZ], 19, -1, MODE_TEAM_DEATHMATCH, -1, -1, 500.0, MAPICON_GLOBAL);
  817.         format(string, sizeof(string), "%s's\n%s(%i)", gTeam[ gCaptureZone[i][E_ZONEOWNER] ][E_NAME], gCaptureZone[i][E_ZONENAME], i);
  818.         gCaptureZone[i][E_ZONELABEL] = CreateDynamic3DTextLabel(string, COLOR_SetTransparency(gTeam[ gCaptureZone[i][E_ZONEOWNER] ][E_COLOR], 200), gCaptureZone[i][E_CPX], gCaptureZone[i][E_CPY], gCaptureZone[i][E_CPZ], 25.0, _, _, 0, MODE_TEAM_DEATHMATCH);
  819.         gCaptureZone[i][E_ZONETIMER] = SetTimerEx("OnCaptureZoneUpdate", 1000, true, "i", i);
  820.         printf("** Capture zone created %s, id: %i, owner team: %s", gCaptureZone[i][E_ZONENAME], i, gTeam[ gCaptureZone[i][E_ZONEOWNER] ][E_NAME]);
  821.  
  822.         if(i == (sizeof(gCaptureZone) - 1)) printf("-> Total %i capture zones created from gamemode!", (i + 1));
  823.     }
  824.  
  825.     //Add shops and print result
  826.     print(" ");
  827.     for(new i; i < sizeof(gShop); i++)
  828.     {
  829.         gShop[i][SHOP_MAPICON] = CreateDynamicMapIcon(gShop[i][SHOP_X], gShop[i][SHOP_Y], gShop[i][SHOP_Z], 6, -1, 0, -1, -1, 500.0, MAPICON_GLOBAL);
  830.         gShop[i][SHOP_PICKUP] = CreateDynamicPickup(2358, 1, gShop[i][SHOP_X], gShop[i][SHOP_Y], gShop[i][SHOP_Z], MODE_TEAM_DEATHMATCH, -1);
  831.         gShop[i][SHOP_LABEL] = CreateDynamic3DTextLabel("Ammuntaion Point", COLOR_SetTransparency(COLOR_LIGHT_BLUE, 200), gShop[i][SHOP_X], gShop[i][SHOP_Y], gShop[i][SHOP_Z], 25.0, _, _, 0, MODE_TEAM_DEATHMATCH);
  832.         printf("** Shop created, id: %i", i);
  833.  
  834.         if(i == (sizeof(gShop) - 1)) printf("-> Total %i shops created from gamemode!", (i + 1));
  835.     }
  836.  
  837.     //Add ranks and print result
  838.     print(" ");
  839.     for(new i; i < sizeof(gRank); i++)
  840.     {
  841.         printf("** Rank created %s, id: %i, score: %i", gRank[i][r_name], i, gRank[i][r_score]);
  842.  
  843.         if(i == (sizeof(gRank) - 1)) printf("-> Total %i ranks created from gamemode!", (i + 1));
  844.     }
  845.     return 1;
  846. }
  847.  
  848. //------------------------------------------------
  849.  
  850. public OnGameModeExit()
  851. {
  852.     MapAndreas_Unload();
  853.  
  854.     for(new i; i < 3; i++) KillTimer(gNotifyTimer[i]);
  855.  
  856.     FadeExit();
  857.  
  858.     //destory all capture zones created
  859.     for(new i; i < sizeof(gCaptureZone); i++)
  860.     {
  861.         GangZoneDestroy(gCaptureZone[i][E_ZONEID]);
  862.         DestroyDynamicCP(gCaptureZone[i][E_ZONECP]);
  863.         DestroyDynamicCP(gCaptureZone[i][E_ZONEICON]);
  864.         DestroyDynamic3DTextLabel(gCaptureZone[i][E_ZONELABEL]);
  865.         KillTimer(gCaptureZone[i][E_ZONETIMER]);
  866.     }
  867.  
  868.     //destroy all team prototypes
  869.     for(new i; i < sizeof(gPrototype); i++)
  870.     {
  871.         DestroyVehicle(gPrototype[i][p_vehicle]);
  872.         DestroyDynamic3DTextLabel(gPrototype[i][p_label]);
  873.     }
  874.  
  875.     //destory all team bases
  876.     for(new i; i < sizeof(gTeamBase); i++)
  877.     {
  878.         GangZoneDestroy(gTeamBase[i][b_base]);
  879.     }
  880.  
  881.     //destroy all shops
  882.     for(new i; i < sizeof(gShop); i++)
  883.     {
  884.         DestroyDynamicMapIcon(gShop[i][SHOP_MAPICON]);
  885.         DestroyDynamicPickup(gShop[i][SHOP_PICKUP]);
  886.         DestroyDynamic3DTextLabel(gShop[i][SHOP_LABEL]);
  887.     }
  888.  
  889.     //destroy moneybag
  890.     DestroyDynamicPickup(gMoneyBag[MONEYBAG_PICKUPID]);
  891.  
  892.     //nuke system
  893.     DestroyDynamicPickup(gNuke[NUKE_PICKUP]);
  894.     DestroyDynamicMapIcon(gNuke[NUKE_MAPICON]);
  895.     DestroyDynamic3DTextLabel(gNuke[NUKE_LABEL]);
  896.  
  897.     //anthrax system
  898.     DestroyDynamicPickup(gAnthrax[ANTHRAX_PICKUP]);
  899.     DestroyDynamicMapIcon(gAnthrax[ANTHRAX_MAPICON]);
  900.     DestroyDynamic3DTextLabel(gAnthrax[ANTHRAX_LABEL]);
  901.     return 1;
  902. }
  903.  
  904. //------------------------------------------------
  905.  
  906. NotifyAll(text[], expiretime = 10000)
  907. {
  908.     new slot = -1;
  909.     for(new i = 0; i < 3; i++)
  910.     {
  911.         if(gNotifyTimer[i] == -1)
  912.         {
  913.             slot = i;
  914.             break;
  915.         }
  916.     }
  917.     if(slot == -1) slot = 0;
  918.  
  919.     if(gNotifyTimer[slot] != -1) KillTimer(gNotifyTimer[slot]);
  920.     gNotifyTimer[slot] = SetTimerEx("OnNotificationExpire", expiretime, false, "i", slot);
  921.     TextDrawSetString(gNotifyTD[slot], text);
  922.  
  923.     foreach(new i : Player)
  924.     {
  925.         if(IsPlayerSpawned(i))
  926.         {
  927.             TextDrawShowForPlayer(i, gNotifyTD[slot]);
  928.         }
  929.     }
  930.     return true;
  931. }
  932.  
  933. forward OnNotificationExpire(slot);
  934. public OnNotificationExpire(slot)
  935. {
  936.     gNotifyTimer[slot] = -1;
  937.     TextDrawSetString(gNotifyTD[slot], "");
  938.     foreach(new i : Player)
  939.     {
  940.         TextDrawHideForPlayer(i, gNotifyTD[slot]);
  941.     }
  942.     return 1;
  943. }
  944.  
  945. NotifyPlayer(playerid, text[], expiretime = 10000)
  946. {
  947.     if(! IsPlayerSpawned(playerid)) return false;
  948.  
  949.     if(gPNotifyTimer[playerid] != -1) KillTimer(gPNotifyTimer[playerid]);
  950.     gPNotifyTimer[playerid] = SetTimerEx("OnPlayerNotificationExpire", expiretime, false, "i", playerid);
  951.     PlayerTextDrawSetString(playerid, gPNotifyTD[playerid], text);
  952.     PlayerTextDrawShow(playerid, gPNotifyTD[playerid]);
  953.     return true;
  954. }
  955.  
  956. forward OnPlayerNotificationExpire(playerid);
  957. public OnPlayerNotificationExpire(playerid)
  958. {
  959.     gPNotifyTimer[playerid] = -1;
  960.     PlayerTextDrawSetString(playerid, gPNotifyTD[playerid], "-");
  961.     PlayerTextDrawHide(playerid, gPNotifyTD[playerid]);
  962.     return 1;
  963. }
  964.  
  965. //------------------------------------------------
  966.  
  967. ReturnWeaponName(weaponid)
  968. {
  969.     new weaponstr[45];
  970.     switch(weaponid)
  971.     {
  972.         case 0: weaponstr = "Fist";
  973.         case 18: weaponstr = "Molotov Cocktail";
  974.         case 44: weaponstr = "Night Vision Goggles";
  975.         case 45: weaponstr = "Thermal Goggles";
  976.         default: GetWeaponName(weaponid, weaponstr, sizeof(weaponstr));
  977.     }
  978.     return weaponstr;
  979. }
  980.  
  981. //------------------------------------------------
  982.  
  983. public OnPlayerConnect(playerid)
  984. {
  985.     for(new i; i < 45; i++) gWeaponKills[playerid][i] = 0;
  986.  
  987.     gPlayerTimer[playerid] = SetTimerEx("OnPlayerTimeUpdate", 1000, true, "i", playerid);
  988.  
  989.     gPlayerSpawn[playerid] = SPAWN_BASE;
  990.     gAntiSpawnkill[playerid][A_TIMER] = -1;
  991.     gDuel[playerid][d_induel] = false;
  992.     gDuel[playerid][d_opponent] = INVALID_PLAYER_ID;
  993.     gDuel[playerid][d_weapon] = 0;
  994.     gDuel[playerid][d_bet] = 0;
  995.    
  996.     gPlayerVehicle[playerid] = -1;
  997.     gDonorSupply[playerid] = -1;
  998.     gCaptureSpree[playerid] = 0;
  999.  
  1000.     //3d text label
  1001.     gPlayerLabel[playerid] = CreateDynamic3DTextLabel("Support", 0, 0.0, 0.0, 0.5, 20.0, playerid, _, 1);
  1002.     gDonorLabel[playerid] = CreateDynamic3DTextLabel("DONOR", 0, 0.0, 0.0, 0.3, 20.0, playerid, _, 1);
  1003.  
  1004.     DisablePlayerRaceCheckpoint(playerid);
  1005.  
  1006.     gPlayerMoneyTimer[playerid] = -1;
  1007.     gPNotifyTimer[playerid] = -1;
  1008.     //class
  1009.     gClass[playerid] = 0;
  1010.     for(new i; i < MAX_PLAYERS; i++) gHealed[playerid][i] = -1;
  1011.     gDis[playerid] = 0;
  1012.     gListitem[playerid] = -1;
  1013.     gPainkillers[playerid] = 0;
  1014.     gArmour[playerid] = false;
  1015.  
  1016.     //add player class selection team skin based on classid
  1017.     gPlayerClassTD[playerid][0] = CreatePlayerTextDrawEx(playerid, 237.000000, 332.000000, "model", 169090710, 5, 0.500000, 1.000000, -1, 1, 0, true, 1, true, 0, 70.000000, 50.000000, 0, 0.000000, 0.000000, 0.000000, 0.899999);
  1018.     //add player class selection team info based on classid
  1019.     gPlayerClassTD[playerid][1] = CreatePlayerTextDrawEx(playerid, 310.000000, 332.000000, "team info", 0, 1, 0.180000, 1.000000, -56, 1, 0, true, 1);
  1020.     //add player notification TD
  1021.     gPNotifyTD[playerid] = CreatePlayerTextDrawEx(playerid, 330.000000, 388.000000, "Welcome user!", 255, 1, 0.199998, 0.999997, -1, 1, 1, true);
  1022.     //add player stats TD
  1023.     gPlayerStatsTD[playerid] = CreatePlayerTextDrawEx(playerid, 4.000000, 436.000000,"~g~~h~~h~Doraemon ~h~Latino's Begginer Medic ~w~~h~- /Help, /Cmds, /Duel, /Dm, /Teles, /Pm, /Object - ~b~~h~~h~~h~Skills!", 0 , 2, 0.150000, 0.599999, -1, 1 , 1, true);
  1024.  
  1025.     FadePlayerConnect(playerid);
  1026.  
  1027.     gPlayerCaptureBar[playerid] = CreatePlayerProgressBar(playerid, 44.000000, 318.000000, 89.500000, 3.700000, -1429936641, CAPTURE_TIME, 0);
  1028.     gPlayerCaptureTD[playerid] = CreatePlayerTextDrawEx(playerid, 87.000000, 308.000000, "Capturing 23...", 255, 1, 0.290000, 1.099999, -1, 2, 1, true, 1, true);
  1029.  
  1030.     gPlayerTeam[playerid] = NO_TEAM;
  1031.  
  1032.     //random message!
  1033.     SendClientMessage(playerid, COLOR_WHITE, "Welcome to the legendary "ORANGE_RED"WORLD WAR III "WHITE"server.");
  1034.     SendClientMessage(playerid, COLOR_HOT_PINK, "Try out our new player country lookups with "LIGHT_BLUE"/country"HOT_PINK"; find all friends from your country.");
  1035.     SendClientMessage(playerid, COLOR_HOT_PINK, "Type "LIGHT_BLUE"/hi "HOT_PINK"for enabling or disabling hit indicator or editing it.");
  1036.  
  1037.     //notifications
  1038.     new string[145];
  1039.     format(string, sizeof(string), "~g~%s(%i) have joined the server", ReturnPlayerName(playerid), playerid);
  1040.     NotifyAll(string, 5000);
  1041.     return 1;
  1042. }
  1043.  
  1044. //------------------------------------------------
  1045.  
  1046. public OnPlayerDisconnect(playerid, reason)
  1047. {
  1048.     KillTimer(gPlayerTimer[playerid]);
  1049.  
  1050.     if(gDuel[playerid][d_induel])
  1051.     {
  1052.         GivePlayerMoney(gDuel[playerid][d_opponent], gDuel[playerid][d_bet]);
  1053.         new string[144];
  1054.         format(string, sizeof(string), "%s have won the duel against opponent %s [weapon: %s, bet: $%i]", ReturnPlayerName(gDuel[playerid][d_opponent]), ReturnPlayerName(playerid), ReturnWeaponName(gDuel[playerid][d_weapon]), gDuel[playerid][d_bet]);
  1055.         SendClientMessageToAll(COLOR_AQUA, string);
  1056.         format(string, sizeof(string), "%s have won the duel against opponent %s", ReturnPlayerName(gDuel[playerid][d_opponent]), ReturnPlayerName(playerid));
  1057.         NotifyAll(string);
  1058.  
  1059.         gDuel[gDuel[playerid][d_opponent]][d_induel] = false;
  1060.         gDuel[gDuel[playerid][d_opponent]][d_opponent] = INVALID_PLAYER_ID;
  1061.         gDuel[gDuel[playerid][d_opponent]][d_weapon] = 0;
  1062.         gDuel[gDuel[playerid][d_opponent]][d_bet] = 0;
  1063.  
  1064.         gDuel[playerid][d_induel] = false;
  1065.         gDuel[playerid][d_opponent] = INVALID_PLAYER_ID;
  1066.         gDuel[playerid][d_weapon] = 0;
  1067.         gDuel[playerid][d_bet] = 0;
  1068.     }
  1069.  
  1070.     //3d text label
  1071.     DestroyDynamic3DTextLabel(gPlayerLabel[playerid]);
  1072.  
  1073.  
  1074.     //money bag droping
  1075.     if(playerid == gMoneyBag[MONEYBAG_PLAYER])
  1076.     {
  1077.         RemovePlayerAttachedObject(playerid, 1);
  1078.  
  1079.         new Float:x, Float:y, Float:z;
  1080.         GetPlayerPos(playerid, x, y, z);
  1081.         gMoneyBag[MONEYBAG_PICKUPID] = CreateDynamicPickup(1550, 1, x, y, z, MODE_MONEYBAG);
  1082.         gMoneyBag[MONEYBAG_PLAYER] = INVALID_PLAYER_ID;
  1083.  
  1084.         new string[145];
  1085.         foreach(new i : Player)
  1086.         {
  1087.             if(gPlayerGamemode[i] == MODE_MONEYBAG)
  1088.             {
  1089.                 format(string, sizeof(string), "~r~%s(%d) have lost the~n~~r~money bag", ReturnPlayerName(playerid), playerid);
  1090.                 GameTextForPlayer(i, string, 5000, 3);
  1091.             }
  1092.         }
  1093.     }
  1094.  
  1095.     //destoy all player textdraws
  1096.     DestroyAllPlayerTextDraws(playerid);
  1097.  
  1098.     FadePlayerDisconnect(playerid);
  1099.  
  1100.     //hiding all capture zones
  1101.     for(new i; i < sizeof(gCaptureZone); i++) GangZoneHideForPlayer(playerid, gCaptureZone[i][E_ZONEID]);
  1102.  
  1103.     //hiding all team bases
  1104.     for(new i; i < sizeof(gTeamBase); i++) GangZoneHideForPlayer(playerid, gTeamBase[i][b_base]);
  1105.  
  1106.     DestroyPlayerProgressBar(playerid, gPlayerCaptureBar[playerid]);
  1107.  
  1108.     gPlayerTeam[playerid] = NO_TEAM;
  1109.  
  1110.     //notifications
  1111.     new string[145];
  1112.     switch(reason)
  1113.     {
  1114.         case 0: format(string, sizeof(string), "~r~%s(%i) have left the server [Timeout/Crashed]", ReturnPlayerName(playerid), playerid);
  1115.         case 1: format(string, sizeof(string), "~r~%s(%i) have left the server [Quit]", ReturnPlayerName(playerid), playerid);
  1116.         case 2: format(string, sizeof(string), "~r~%s(%i) have left the server [Kicked/Banned]", ReturnPlayerName(playerid), playerid);
  1117.     }
  1118.     NotifyAll(string, 5000);
  1119.     return 1;
  1120. }
  1121.  
  1122. //------------------------------------------------
  1123.  
  1124. stock CountTeamPlayers(team)
  1125. {
  1126.     new count;
  1127.     foreach(new i : Player)
  1128.     {
  1129.         if( IsPlayerConnected(i)//if player is connected
  1130.             && GetPlayerTeam(i) == team)//if team id matches
  1131.         {
  1132.             count++;//add one to the count
  1133.         }
  1134.     }
  1135.     return count;
  1136. }
  1137.  
  1138. //------------------------------------------------
  1139.  
  1140. stock CountTeamFlags(team)
  1141. {
  1142.     new count;
  1143.     for(new i; i < sizeof(gCaptureZone); i++)
  1144.     {
  1145.         if(gCaptureZone[i][E_ZONEOWNER] == team)
  1146.         {
  1147.             count++;
  1148.         }
  1149.     }
  1150.     return count;
  1151. }
  1152.  
  1153. //------------------------------------------------
  1154.  
  1155. stock CountEventPlayers(event)
  1156. {
  1157.     new count = 0;
  1158.     foreach(new i : Player)
  1159.     {
  1160.         if(gPlayerGamemode[i] == event)//if event id matches
  1161.         {
  1162.             count++;//add one to the count
  1163.         }
  1164.     }
  1165.     return count;
  1166. }
  1167.  
  1168. //------------------------------------------------
  1169.  
  1170. GetPlayerRank(playerid)
  1171. {
  1172.     for(new i = 0; i < sizeof(gRank); i++)
  1173.     {
  1174.         if(GetPlayerScore(playerid) <= 0)
  1175.         {
  1176.             return 0;
  1177.         }
  1178.         else if(GetPlayerScore(playerid) >= gRank[(sizeof(gRank) - 1)][r_score])
  1179.         {
  1180.             return (sizeof(gRank) - 1);
  1181.         }
  1182.         else if(GetPlayerScore(playerid) < gRank[i][r_score])
  1183.         {
  1184.             return (i - 1);
  1185.         }
  1186.     }
  1187.     return 0;
  1188. }
  1189.  
  1190. //------------------------------------------------
  1191.  
  1192. ReturnPlayerClassName(playerid)
  1193. {
  1194.     new classstr[28] = "Unknown";
  1195.     switch(gClass[playerid])
  1196.     {
  1197.         case 0: classstr = "Support";
  1198.         case 1: classstr = "Medic";
  1199.         case 2: classstr = "Scout";
  1200.         case 3: classstr = "Jetrunner";
  1201.         case 4: classstr = "Pilot";
  1202.         case 5: classstr = "Spy";
  1203.         case 6: classstr = "Terminator";
  1204.     }
  1205.     return classstr;
  1206. }
  1207.  
  1208. //------------------------------------------------
  1209.  
  1210. ShowPlayerClassSelectionDialog(playerid)
  1211. {
  1212.     new dialogstr[556];
  1213.     new rank = GetPlayerRank(playerid);
  1214.  
  1215.     strcat(dialogstr, ""LIGHT_BLUE"Support (Rank 0+)\n");
  1216.     strcat(dialogstr, ""LIGHT_BLUE"Medic (Rank 0+)\n");
  1217.     if(rank >= 1) strcat(dialogstr, ""LIGHT_BLUE"Scout (Rank 1+)\n");
  1218.     else strcat(dialogstr, ""GRAY"Scout (Rank 1+)\n");
  1219.     if(rank >= 3) strcat(dialogstr, ""LIGHT_BLUE"Jetrunner (Rank 3+)\n");
  1220.     else strcat(dialogstr, ""GRAY"Jetrunner (Rank 3+)\n");
  1221.     if(rank >= 5) strcat(dialogstr, ""LIGHT_BLUE"Pilot (Rank 5+)\n");
  1222.     else strcat(dialogstr, ""GRAY"Pilot (Rank 5+)\n");
  1223.     if(rank >= 8) strcat(dialogstr, ""LIGHT_BLUE"Spy (Rank 8+)\n");
  1224.     else strcat(dialogstr, ""GRAY"Spy (Rank 8+)\n");
  1225.     if(rank >= 12) strcat(dialogstr, ""LIGHT_BLUE"Terminator (Rank 12+)\n");
  1226.     else strcat(dialogstr, ""GRAY"Terminator (Rank 12+)\n");
  1227.  
  1228.     return ShowPlayerDialog(playerid, DIALOG_CLASS, DIALOG_STYLE_LIST, "Class selection (/sc)", dialogstr, "Spawn", "Last Class");
  1229. }
  1230.  
  1231. //------------------------------------------------
  1232.  
  1233. ShowPlayerShopDialog(playerid)
  1234. {
  1235.     new dialogstr[556];
  1236.  
  1237.     strcat(dialogstr, ""LIGHT_BLUE"Full Health ($2500)\n");
  1238.     strcat(dialogstr, ""LIGHT_BLUE"Full Armour ($2500)\n");
  1239.     strcat(dialogstr, ""CORAL"- Weapons List\n");
  1240.     strcat(dialogstr, ""CORAL"- Misc. Items\n");
  1241.     strcat(dialogstr, ""CORAL"- Inventory Items");
  1242.  
  1243.     return ShowPlayerDialog(playerid, DIALOG_SHOP, DIALOG_STYLE_LIST, "Shop!", dialogstr, "Select", "Close");
  1244. }
  1245.  
  1246. //------------------------------------------------
  1247.  
  1248. public OnPlayerRequestClass(playerid, classid)
  1249. {
  1250.     gAntiSpawnkill[playerid][A_TIMER] = -1;
  1251.     gClassSelection[playerid] = true;
  1252.     gPlayerGamemode[playerid] = MODE_TEAM_DEATHMATCH;
  1253.    
  1254.     SetPlayerPos(playerid,398.4077,2540.5049,19.6311);
  1255.     SetPlayerCameraPos(playerid,398.4077,2530.5049,19.6311);
  1256.     SetPlayerCameraLookAt(playerid,398.4077,2540.5049,19.6311);
  1257.     SetPlayerFacingAngle(playerid, 180.0);
  1258.  
  1259.     //show the class selc background box. not for whole screen, just a small section
  1260.     TextDrawShowForPlayer(playerid, gClassBGTD);
  1261.     //set and show model textdraw with team skin
  1262.     PlayerTextDrawSetPreviewModel(playerid, gPlayerClassTD[playerid][0], gTeam[classid][E_SKIN]);
  1263.     PlayerTextDrawShow(playerid, gPlayerClassTD[playerid][0]);
  1264.     //display team info textdraw
  1265.     PlayerTextDrawShow(playerid, gPlayerClassTD[playerid][1]);
  1266.     //hide player rank & stats TDs
  1267.     PlayerTextDrawHide(playerid, gPlayerStatsTD[playerid]);
  1268.     //hide notification TDs
  1269.     for(new i; i < 3; i++) TextDrawHideForPlayer(playerid, gNotifyTD[i]);
  1270.     //hide player notification TDs
  1271.     PlayerTextDrawHide(playerid, gPNotifyTD[playerid]);
  1272.     //hide stats TDs
  1273.     for(new i; i < 5; i++) TextDrawHideForPlayer(playerid, gStatsBGTD[i]);
  1274.     TextDrawHideForPlayer(playerid, gAnnouncementTD);
  1275.     //hide server TDs
  1276.     for(new i; i < 3; i++) TextDrawHideForPlayer(playerid, gServerTD[i]);
  1277.  
  1278.     SetPlayerTeam(playerid, classid);
  1279.     gPlayerTeam[playerid] = classid;
  1280.  
  1281.     SetPlayerPos(playerid,398.4077,2540.5049,19.6311);
  1282.     SetPlayerCameraPos(playerid,398.4077,2530.5049,19.6311);
  1283.     SetPlayerCameraLookAt(playerid,398.4077,2540.5049,19.6311);
  1284.     SetPlayerFacingAngle(playerid, 180.0);
  1285.  
  1286.     new string[156];
  1287.     format(string, sizeof(string), "%s ~w~~h~[~g~~h~%d~w~~h~]~n~- Players: ~y~~h~%d~n~~w~~h~- Flags: ~y~~h~%d/%d~n~~w~~h~- Bonus: ~y~~h~Full health!", gTeam[classid][E_NAME], (classid + 1), CountTeamPlayers(classid), CountTeamFlags(classid), sizeof(gCaptureZone));
  1288.     PlayerTextDrawSetString(playerid, gPlayerClassTD[playerid][1], string);
  1289.  
  1290.     HidePlayerProgressBar(playerid, gPlayerCaptureBar[playerid]);
  1291.     PlayerTextDrawHide(playerid, gPlayerCaptureTD[playerid]);
  1292.     return 1;
  1293. }
  1294.  
  1295. public OnPlayerRequestSpawn(playerid)
  1296. {
  1297.     if(gPlayerTeam[playerid] == 7) gPlayerSpawn[playerid] = SPAWN_BASE;
  1298.     return 1;
  1299. }
  1300.  
  1301. //------------------------------------------------
  1302.  
  1303. public OnPlayerSpawn(playerid)
  1304. {
  1305.     gDonorSupply[playerid] = 3;
  1306.     gCaptureSpree[playerid] = 0;
  1307.    
  1308.     for(new i; i < MAX_PLAYER_ATTACHED_OBJECTS; i++) RemovePlayerAttachedObject(playerid, i);
  1309.  
  1310.     if(gDuel[playerid][d_induel])
  1311.     {
  1312.         GivePlayerMoney(gDuel[playerid][d_opponent], gDuel[playerid][d_bet]);
  1313.         new string[144];
  1314.         format(string, sizeof(string), "%s have won the duel against opponent %s [weapon: %s, bet: $%i]", ReturnPlayerName(gDuel[playerid][d_opponent]), ReturnPlayerName(playerid), ReturnWeaponName(gDuel[playerid][d_weapon]), gDuel[playerid][d_bet]);
  1315.         SendClientMessageToAll(COLOR_AQUA, string);
  1316.         format(string, sizeof(string), "%s have won the duel against opponent %s", ReturnPlayerName(gDuel[playerid][d_opponent]), ReturnPlayerName(playerid));
  1317.         NotifyAll(string);
  1318.  
  1319.         gDuel[gDuel[playerid][d_opponent]][d_induel] = false;
  1320.         gDuel[gDuel[playerid][d_opponent]][d_opponent] = INVALID_PLAYER_ID;
  1321.         gDuel[gDuel[playerid][d_opponent]][d_weapon] = 0;
  1322.         gDuel[gDuel[playerid][d_opponent]][d_bet] = 0;
  1323.  
  1324.         gDuel[playerid][d_induel] = false;
  1325.         gDuel[playerid][d_opponent] = INVALID_PLAYER_ID;
  1326.         gDuel[playerid][d_weapon] = 0;
  1327.         gDuel[playerid][d_bet] = 0;
  1328.     }
  1329.  
  1330.     gDuel[playerid][d_induel] = false;
  1331.     gDuel[playerid][d_opponent] = INVALID_PLAYER_ID;
  1332.     gDuel[playerid][d_weapon] = 0;
  1333.     gDuel[playerid][d_bet] = 0;
  1334.  
  1335.     gAntiSpawnkill[playerid][A_TIMER] = -1;
  1336.  
  1337.     for(new i; i < 45; i++) gWeaponKills[playerid][i] = 0;
  1338.  
  1339.     for(new i; i < MAX_PLAYERS; i++)
  1340.     {
  1341.         if(gHealed[playerid][i] != -1) KillTimer(gHealed[playerid][i]);
  1342.         gHealed[playerid][i] = -1;
  1343.     }
  1344.     gDis[playerid] = 0;
  1345.     gPlayerLastVehicle[playerid] = -1;
  1346.     gPainkillers[playerid] = 0;
  1347.     gArmour[playerid] = false;
  1348.  
  1349.     gHelmet[playerid] = false;
  1350.     gMask[playerid] = false;
  1351.     gBomb[playerid] = false;
  1352.     gListitem[playerid] = -1;
  1353.  
  1354.     //hide the class selc background box. not for whole screen, just a small section
  1355.     TextDrawHideForPlayer(playerid, gClassBGTD);
  1356.     //hide model textdraw with team skin
  1357.     PlayerTextDrawHide(playerid, gPlayerClassTD[playerid][0]);
  1358.     //hide team info textdraw
  1359.     PlayerTextDrawHide(playerid, gPlayerClassTD[playerid][1]);
  1360.     //show player rank & stats TDs
  1361.     PlayerTextDrawShow(playerid, gPlayerStatsTD[playerid]);
  1362.     //show stats TDs
  1363.     for(new i; i < 5; i++) TextDrawShowForPlayer(playerid, gStatsBGTD[i]);
  1364.     TextDrawShowForPlayer(playerid, gAnnouncementTD);
  1365.     //show server TDs
  1366.     for(new i; i < 3; i++) TextDrawShowForPlayer(playerid, gServerTD[i]);
  1367.  
  1368.     //showing all zones
  1369.     ShowAllGangZonesForPlayer(playerid);
  1370.  
  1371.     //Set player capture zones status
  1372.     for(new i; i < sizeof(gCaptureZone); i++)
  1373.     {
  1374.         if(gCaptureZone[i][E_ZONEATTACKED])
  1375.         {
  1376.             GangZoneFlashForPlayer(playerid, gCaptureZone[i][E_ZONEID], gTeam[ GetPlayerTeam(gCaptureZone[i][E_ZONEATTACKER]) ][E_COLOR]);
  1377.         }
  1378.     }
  1379.  
  1380.     HidePlayerProgressBar(playerid, gPlayerCaptureBar[playerid]);
  1381.     PlayerTextDrawHide(playerid, gPlayerCaptureTD[playerid]);
  1382.     DisablePlayerRaceCheckpoint(playerid);
  1383.     SetPlayerInterior(playerid, 0);
  1384.     SetPlayerVirtualWorld(playerid, 0);
  1385.  
  1386.     switch(gPlayerGamemode[playerid])
  1387.     {
  1388.         case MODE_MINIGUN://if the player is in minigun deathmatch mode
  1389.         {
  1390.             //hiding all zones
  1391.             HideAllGangZonesForPlayer(playerid);
  1392.  
  1393.             //team messages
  1394.             SendClientMessage(playerid, COLOR_WHITE, " ");
  1395.             new string[156];
  1396.             format(string, sizeof(string), "You have spawned as a "RED"Minigun deathmatcher"WHITE"! There are "LIGHT_BLUE"%i "WHITE"others playing here!", CountEventPlayers(MODE_MINIGUN));
  1397.             SendClientMessage(playerid, COLOR_WHITE, string);
  1398.             SendClientMessage(playerid, COLOR_WHITE, "Your mission is to eliminate the other players (expcept admins) as soon as you see them.");
  1399.             SendClientMessage(playerid, COLOR_WHITE, "Type /minigunhelp to get help about the deathmatch.");
  1400.  
  1401.             SetPlayerTeam(playerid, NO_TEAM);
  1402.             SetPlayerColor(playerid, COLOR_RED);
  1403.  
  1404.             SetPlayerInterior(playerid, 1);
  1405.             SetPlayerVirtualWorld(playerid, MODE_MINIGUN);
  1406.             ResetPlayerWeapons(playerid);
  1407.             GivePlayerWeapon(playerid, 38, 999999999);
  1408.  
  1409.             new randomspawn = random(sizeof(gMinigunSpawn));
  1410.             SetPlayerPos(playerid, gMinigunSpawn[randomspawn][0], gMinigunSpawn[randomspawn][1], gMinigunSpawn[randomspawn][2]);
  1411.             SetPlayerFacingAngle(playerid, gMinigunSpawn[randomspawn][3]);
  1412.  
  1413.             SetPlayerHealth(playerid, 100.0);
  1414.             SetPlayerArmour(playerid, 0.0);
  1415.  
  1416.             SetPlayerSkin(playerid, gPlayerSkin[playerid]);
  1417.             TogglePlayerMarker(playerid, true);
  1418.         }
  1419.         case MODE_MONEYBAG://if the player is in moneybag deathmatch mode
  1420.         {
  1421.             //hiding all capture zones
  1422.             HideAllGangZonesForPlayer(playerid);
  1423.  
  1424.             //team messages
  1425.             SendClientMessage(playerid, COLOR_WHITE, " ");
  1426.             new string[156];
  1427.             format(string, sizeof(string), "You have spawned as a "RED"Moneybag deathmatcher"WHITE"! There are "LIGHT_BLUE"%i "WHITE"others playing here!", CountEventPlayers(MODE_MONEYBAG));
  1428.             SendClientMessage(playerid, COLOR_WHITE, string);
  1429.             SendClientMessage(playerid, COLOR_WHITE, "Your mission is to eliminate the other players (expcept admins) as soon as you see them.");
  1430.             SendClientMessage(playerid, COLOR_WHITE, "Type /moneybaghelp to get help about the deathmatch.");
  1431.  
  1432.             TogglePlayerControllable(playerid, true);
  1433.  
  1434.             SetPlayerTeam(playerid, NO_TEAM);
  1435.             SetPlayerColor(playerid, COLOR_RED);
  1436.  
  1437.             SetPlayerInterior(playerid, 5);
  1438.             SetPlayerVirtualWorld(playerid, MODE_MONEYBAG);
  1439.             ResetPlayerWeapons(playerid);
  1440.             GivePlayerWeapon(playerid, 24, 999999999);
  1441.             GivePlayerWeapon(playerid, 27, 999999999);
  1442.             GivePlayerWeapon(playerid, 29, 999999999);
  1443.  
  1444.             new randomspawn = random(sizeof(gMoneybagSpawn));
  1445.             SetPlayerPos(playerid, gMoneybagSpawn[randomspawn][0], gMoneybagSpawn[randomspawn][1], gMoneybagSpawn[randomspawn][2]);
  1446.             SetPlayerFacingAngle(playerid, gMoneybagSpawn[randomspawn][3]);
  1447.  
  1448.             SetPlayerHealth(playerid, 100.0);
  1449.             SetPlayerArmour(playerid, 0.0);
  1450.  
  1451.             SetPlayerSkin(playerid, gPlayerSkin[playerid]);
  1452.             TogglePlayerMarker(playerid, true);
  1453.         }
  1454.         case MODE_RPG://if the player is in RPG deathmatch mode
  1455.         {
  1456.             //hiding all capture zones
  1457.             HideAllGangZonesForPlayer(playerid);
  1458.  
  1459.             //team messages
  1460.             SendClientMessage(playerid, COLOR_WHITE, " ");
  1461.             new string[156];
  1462.             format(string, sizeof(string), "You have spawned as a "RED"RPG deathmatcher"WHITE"! There are "LIGHT_BLUE"%i "WHITE"others playing here!", CountEventPlayers(MODE_RPG));
  1463.             SendClientMessage(playerid, COLOR_WHITE, string);
  1464.             SendClientMessage(playerid, COLOR_WHITE, "Your mission is to eliminate the other players (expcept admins) as soon as you see them.");
  1465.             SendClientMessage(playerid, COLOR_WHITE, "Type /minigunhelp to get help about the deathmatch.");
  1466.  
  1467.             SetPlayerTeam(playerid, NO_TEAM);
  1468.             SetPlayerColor(playerid, COLOR_RED);
  1469.  
  1470.             SetPlayerInterior(playerid, 0);
  1471.             SetPlayerVirtualWorld(playerid, MODE_RPG);
  1472.             ResetPlayerWeapons(playerid);
  1473.             GivePlayerWeapon(playerid, 35, 999999999);
  1474.  
  1475.             new randomspawn = random(sizeof(gRPGSpawn));
  1476.             SetPlayerPos(playerid, gRPGSpawn[randomspawn][0], gRPGSpawn[randomspawn][1], gRPGSpawn[randomspawn][2]);
  1477.             SetPlayerFacingAngle(playerid, gRPGSpawn[randomspawn][3]);
  1478.  
  1479.             SetPlayerHealth(playerid, 20.0);
  1480.             SetPlayerArmour(playerid, 0.0);
  1481.  
  1482.             SetPlayerSkin(playerid, gPlayerSkin[playerid]);
  1483.             TogglePlayerMarker(playerid, true);
  1484.         }
  1485.         case MODE_GLASS://if the player is in RPG deathmatch mode
  1486.         {
  1487.             //hiding all capture zones
  1488.             HideAllGangZonesForPlayer(playerid);
  1489.  
  1490.             //team messages
  1491.             SendClientMessage(playerid, COLOR_WHITE, " ");
  1492.             new string[156];
  1493.             format(string, sizeof(string), "You have spawned as a "RED"Glass break deathmatcher"WHITE"! There are "LIGHT_BLUE"%i "WHITE"others playing here!", CountEventPlayers(MODE_GLASS));
  1494.             SendClientMessage(playerid, COLOR_WHITE, string);
  1495.             SendClientMessage(playerid, COLOR_WHITE, "Your mission is to eliminate the other players (expcept admins) as soon as you see them.");
  1496.             SendClientMessage(playerid, COLOR_WHITE, "Type /minigunhelp to get help about the deathmatch.");
  1497.  
  1498.             SetPlayerTeam(playerid, NO_TEAM);
  1499.             SetPlayerColor(playerid, COLOR_RED);
  1500.  
  1501.             SetPlayerInterior(playerid, 0);
  1502.             SetPlayerVirtualWorld(playerid, MODE_GLASS);
  1503.             ResetPlayerWeapons(playerid);
  1504.             GivePlayerWeapon(playerid, 25, 999999999);
  1505.             GivePlayerWeapon(playerid, 23, 999999999);
  1506.             GivePlayerWeapon(playerid, 1, 1);
  1507.  
  1508.             new randomspawn = random(sizeof(gGlassSpawn));
  1509.             Streamer_UpdateEx(playerid, gGlassSpawn[randomspawn][0], gGlassSpawn[randomspawn][1], gGlassSpawn[randomspawn][2], MODE_GLASS, 0, STREAMER_TYPE_OBJECT);
  1510.             SetPlayerPos(playerid, gGlassSpawn[randomspawn][0], gGlassSpawn[randomspawn][1], gGlassSpawn[randomspawn][2]);
  1511.             SetPlayerFacingAngle(playerid, gGlassSpawn[randomspawn][3]);
  1512.  
  1513.             SetPlayerHealth(playerid, 100.0);
  1514.             SetPlayerArmour(playerid, 0.0);
  1515.  
  1516.             SetPlayerSkin(playerid, gPlayerSkin[playerid]);
  1517.             TogglePlayerMarker(playerid, true);
  1518.         }
  1519.         case MODE_TEAM_DEATHMATCH:
  1520.         {
  1521.             if(GetPlayerTeam(playerid) != 100)
  1522.             {
  1523.                 //bag object
  1524.                 SetPlayerAttachedObject(playerid, 1, 3026, 1, -0.133000, -0.094000, 0.000000, 0.000000, 0.000000, 0.000000, 1.000000, 1.289000, 1.000000);
  1525.  
  1526.                 SetPlayerTeam(playerid, gPlayerTeam[playerid]);
  1527.                 SetPlayerColor(playerid, gTeam[GetPlayerTeam(playerid)][E_COLOR]);
  1528.                 TogglePlayerMarker(playerid, true);
  1529.  
  1530.                 //team messages
  1531.                 SendClientMessage(playerid, COLOR_WHITE, " ");
  1532.                 new string[156];
  1533.                 format(string, sizeof(string), "You have spawned as team: {%06x}%s", ( gTeam[ GetPlayerTeam(playerid) ][E_COLOR] >>> 8 ), gTeam[ GetPlayerTeam(playerid) ][E_NAME]);
  1534.                 SendClientMessage(playerid, COLOR_WHITE, string);
  1535.                 SendClientMessage(playerid, COLOR_WHITE, "You can't attack your team mates, can't jack their vehicle, can't damage their vehicles either.");
  1536.                 SendClientMessage(playerid, COLOR_WHITE, "Type /teams to get info. about all teams.");
  1537.  
  1538.                 if(gPlayerSpawn[playerid] != SPAWN_BASE)
  1539.                 {
  1540.                     if(gCaptureZone[gSpawn[gPlayerSpawn[playerid]][s_zoneid]][E_ZONEOWNER] != GetPlayerTeam(playerid))
  1541.                     {
  1542.                         format(string, sizeof(string), "ERROR: Your team don't own %s anymore! You are spawned in base", gCaptureZone[gSpawn[gPlayerSpawn[playerid]][s_zoneid]][E_ZONENAME]);
  1543.                         SendClientMessage(playerid, COLOR_FIREBRICK, string);
  1544.                         gPlayerSpawn[playerid] = SPAWN_BASE;
  1545.                     }
  1546.                     else
  1547.                     {
  1548.                         format(string, sizeof(string), "* You have spawned in %s.", gCaptureZone[gSpawn[gPlayerSpawn[playerid]][s_zoneid]][E_ZONENAME]);
  1549.                         SendClientMessage(playerid, COLOR_WHITE, string);
  1550.  
  1551.                         SetPlayerPos(playerid, gSpawn[gPlayerSpawn[playerid]][s_x], gSpawn[gPlayerSpawn[playerid]][s_y], gSpawn[gPlayerSpawn[playerid]][s_z]);
  1552.                         SetPlayerFacingAngle(playerid, gSpawn[gPlayerSpawn[playerid]][s_a]);
  1553.                     }
  1554.                 }
  1555.                 if(gPlayerSpawn[playerid] == SPAWN_BASE)
  1556.                 {
  1557.                     SendClientMessage(playerid, COLOR_WHITE, "* You have spawned in your BASE.");
  1558.  
  1559.                     new randomspawn = 0;
  1560.                     switch(GetPlayerTeam(playerid))
  1561.                     {
  1562.                         case 0:
  1563.                         {
  1564.                             randomspawn = random(sizeof(gUSASpawn));
  1565.                             SetPlayerPos(playerid, gUSASpawn[randomspawn][0], gUSASpawn[randomspawn][1], gUSASpawn[randomspawn][2]);
  1566.                             SetPlayerFacingAngle(playerid, gUSASpawn[randomspawn][3]);
  1567.                         }
  1568.                         case 1:
  1569.                         {
  1570.                             randomspawn = random(sizeof(gEuropeSpawn));
  1571.                             SetPlayerPos(playerid, gEuropeSpawn[randomspawn][0], gEuropeSpawn[randomspawn][1], gEuropeSpawn[randomspawn][2]);
  1572.                             SetPlayerFacingAngle(playerid, gEuropeSpawn[randomspawn][3]);
  1573.                         }
  1574.                         case 2:
  1575.                         {
  1576.                             randomspawn = random(sizeof(gRussiaSpawn));
  1577.                             SetPlayerPos(playerid, gRussiaSpawn[randomspawn][0], gRussiaSpawn[randomspawn][1], gRussiaSpawn[randomspawn][2]);
  1578.                             SetPlayerFacingAngle(playerid, gRussiaSpawn[randomspawn][3]);
  1579.                         }
  1580.                         case 3:
  1581.                         {
  1582.                             randomspawn = random(sizeof(gLatinoSpawn));
  1583.                             SetPlayerPos(playerid, gLatinoSpawn[randomspawn][0], gLatinoSpawn[randomspawn][1], gLatinoSpawn[randomspawn][2]);
  1584.                             SetPlayerFacingAngle(playerid, gLatinoSpawn[randomspawn][3]);
  1585.                         }
  1586.                         case 4:
  1587.                         {
  1588.                             randomspawn = random(sizeof(gAsiaSpawn));
  1589.                             SetPlayerPos(playerid, gAsiaSpawn[randomspawn][0], gAsiaSpawn[randomspawn][1], gAsiaSpawn[randomspawn][2]);
  1590.                             SetPlayerFacingAngle(playerid, gAsiaSpawn[randomspawn][3]);
  1591.                         }
  1592.                         case 5:
  1593.                         {
  1594.                             randomspawn = random(sizeof(gAustraliaSpawn));
  1595.                             SetPlayerPos(playerid, gAustraliaSpawn[randomspawn][0], gAustraliaSpawn[randomspawn][1], gAustraliaSpawn[randomspawn][2]);
  1596.                             SetPlayerFacingAngle(playerid, gAustraliaSpawn[randomspawn][3]);
  1597.                         }
  1598.                         case 6:
  1599.                         {
  1600.                             randomspawn = random(sizeof(gIndiaSpawn));
  1601.                             SetPlayerPos(playerid, gIndiaSpawn[randomspawn][0], gIndiaSpawn[randomspawn][1], gIndiaSpawn[randomspawn][2]);
  1602.                             SetPlayerFacingAngle(playerid, gIndiaSpawn[randomspawn][3]);
  1603.                         }
  1604.                         case 7:
  1605.                         {
  1606.                             randomspawn = random(sizeof(gAfricaSpawn));
  1607.                             SetPlayerPos(playerid, gAfricaSpawn[randomspawn][0], gAfricaSpawn[randomspawn][1], gAfricaSpawn[randomspawn][2]);
  1608.                             SetPlayerFacingAngle(playerid, gAfricaSpawn[randomspawn][3]);
  1609.                         }
  1610.                     }
  1611.                 }
  1612.  
  1613.                 //push to class selection dialog
  1614.                 if( gClassSelection[playerid] &&
  1615.                     GetPlayerTeam(playerid) != 7)
  1616.                 {
  1617.                     TogglePlayerControllable(playerid, false);
  1618.                     SendClientMessage(playerid, COLOR_ORANGE_RED, "> Please select your favourite class and click SPAWN; Go for LAST CLASS if in a hurry!");
  1619.                     return ShowPlayerClassSelectionDialog(playerid);
  1620.                 }
  1621.  
  1622.                 new rank = GetPlayerRank(playerid);
  1623.  
  1624.                 switch(GetPlayerTeam(playerid))
  1625.                 {
  1626.                     case 0..6:
  1627.                     {
  1628.                         //class setup
  1629.                         switch(gClass[playerid])
  1630.                         {
  1631.                             case 0:
  1632.                             {
  1633.                                 NotifyPlayer(playerid, "You have selected class ~g~Support", 5000);
  1634.                                 SendClientMessage(playerid, COLOR_CORAL, "- Your class is "LIGHT_BLUE"Support "HOT_PINK"(You recieve class bonus according to your rank!)");
  1635.  
  1636.                                 switch(rank)
  1637.                                 {
  1638.                                     case 0..2:
  1639.                                     {
  1640.                                         GivePlayerWeapon(playerid, 30, 100 * (rank + 1));
  1641.                                         GivePlayerWeapon(playerid, 8, 1);
  1642.                                         GivePlayerWeapon(playerid, 17, 3);
  1643.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Ak-47, Katana, Teargas.");
  1644.                                     }
  1645.                                     case 3..5:
  1646.                                     {
  1647.                                         GivePlayerWeapon(playerid, 30, 300);
  1648.                                         GivePlayerWeapon(playerid, 24, 100);
  1649.                                         GivePlayerWeapon(playerid, 8, 1);
  1650.                                         GivePlayerWeapon(playerid, 17, 5);
  1651.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Ak-47, Desert Eagle, Katana, Teargas.");
  1652.                                     }
  1653.                                     default:
  1654.                                     {
  1655.                                         GivePlayerWeapon(playerid, 31, 300);
  1656.                                         GivePlayerWeapon(playerid, 24, 200);
  1657.                                         GivePlayerWeapon(playerid, 8, 1);
  1658.                                         GivePlayerWeapon(playerid, 17, 5);
  1659.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: M4, Desert Eagle, Katana, Teargas.");
  1660.                                     }
  1661.                                 }
  1662.                             }
  1663.                             case 1:
  1664.                             {
  1665.                                 NotifyPlayer(playerid, "You have selected class ~g~Medic", 5000);
  1666.                                 SendClientMessage(playerid, COLOR_CORAL, "- Your class is "LIGHT_BLUE"Medic "HOT_PINK"(You recieve class bonus according to your rank!)");
  1667.  
  1668.                                 switch(rank)
  1669.                                 {
  1670.                                     case 0..2:
  1671.                                     {
  1672.                                         GivePlayerWeapon(playerid, 29, 100 * (rank + 1));
  1673.                                         GivePlayerWeapon(playerid, 9, 1);
  1674.                                         GivePlayerWeapon(playerid, 18, 2);
  1675.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Ak-47, Chainsaw, Moltove.");
  1676.                                     }
  1677.                                     case 3..5:
  1678.                                     {
  1679.                                         GivePlayerWeapon(playerid, 29, 500);
  1680.                                         GivePlayerWeapon(playerid, 9, 1);
  1681.                                         GivePlayerWeapon(playerid, 18, 3);
  1682.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Ak-47, Chainsaw, Moltove.");
  1683.                                     }
  1684.                                     default:
  1685.                                     {
  1686.                                         GivePlayerWeapon(playerid, 29, 500);
  1687.                                         GivePlayerWeapon(playerid, 23, 200);
  1688.                                         GivePlayerWeapon(playerid, 9, 1);
  1689.                                         GivePlayerWeapon(playerid, 18, 4);
  1690.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Ak-47, Silenced 9mm, Chainsaw, Moltove.");
  1691.                                     }
  1692.                                 }
  1693.  
  1694.                                 gPainkillers[playerid] = 3;
  1695.                             }
  1696.                             case 2:
  1697.                             {
  1698.                                 NotifyPlayer(playerid, "You have selected class ~g~Scout", 5000);
  1699.                                 SendClientMessage(playerid, COLOR_CORAL, "- Your class is "LIGHT_BLUE"Scout "HOT_PINK"(You recieve class bonus according to your rank!)");
  1700.  
  1701.                                 switch(rank)
  1702.                                 {
  1703.                                     case 1..2:
  1704.                                     {
  1705.                                         GivePlayerWeapon(playerid, 33, 100 * (rank + 1));
  1706.                                         GivePlayerWeapon(playerid, 4, 1);
  1707.                                         GivePlayerWeapon(playerid, 17, 2);
  1708.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Country Rifle, Knife, Teargas.");
  1709.                                     }
  1710.                                     case 3..5:
  1711.                                     {
  1712.                                         GivePlayerWeapon(playerid, 34, 500);
  1713.                                         GivePlayerWeapon(playerid, 4, 1);
  1714.                                         GivePlayerWeapon(playerid, 17, 4);
  1715.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Sniper Rifle, Knife, Teargas.");
  1716.                                     }
  1717.                                     default:
  1718.                                     {
  1719.                                         GivePlayerWeapon(playerid, 34, 500);
  1720.                                         GivePlayerWeapon(playerid, 22, 200);
  1721.                                         GivePlayerWeapon(playerid, 4, 1);
  1722.                                         GivePlayerWeapon(playerid, 17, 5);
  1723.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Sniper Rifle, 9mm, Knife, Teargas.");
  1724.                                     }
  1725.                                 }
  1726.  
  1727.                                 TogglePlayerMarker(playerid, false);
  1728.                             }
  1729.                             case 3:
  1730.                             {
  1731.                                 NotifyPlayer(playerid, "You have selected class ~g~Jetrunner", 5000);
  1732.                                 SendClientMessage(playerid, COLOR_CORAL, "- Your class is "LIGHT_BLUE"Jetrunner "HOT_PINK"(You recieve class bonus according to your rank!)");
  1733.  
  1734.                                 switch(rank)
  1735.                                 {
  1736.                                     case 3:
  1737.                                     {
  1738.                                         GivePlayerWeapon(playerid, 32, 300);
  1739.                                         GivePlayerWeapon(playerid, 3, 1);
  1740.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Tec-9, Baseball bat.");
  1741.                                     }
  1742.                                     case 4..7:
  1743.                                     {
  1744.                                         GivePlayerWeapon(playerid, 32, 500);
  1745.                                         GivePlayerWeapon(playerid, 22, 100);
  1746.                                         GivePlayerWeapon(playerid, 3, 1);
  1747.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Tec-9, 9mm, Baseball bat.");
  1748.                                     }
  1749.                                     default:
  1750.                                     {
  1751.                                         GivePlayerWeapon(playerid, 32, 500);
  1752.                                         GivePlayerWeapon(playerid, 26, 100);
  1753.                                         GivePlayerWeapon(playerid, 3, 1);
  1754.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Tec-9, Sawnoff Shotgun, Baseball bat.");
  1755.                                     }
  1756.                                 }
  1757.                             }
  1758.                             case 4:
  1759.                             {
  1760.                                 NotifyPlayer(playerid, "You have selected class ~g~Pilot", 5000);
  1761.                                 SendClientMessage(playerid, COLOR_CORAL, "- Your class is "LIGHT_BLUE"Pilot "HOT_PINK"(You recieve class bonus according to your rank!)");
  1762.  
  1763.                                 switch(rank)
  1764.                                 {
  1765.                                     case 5:
  1766.                                     {
  1767.                                         GivePlayerWeapon(playerid, 25, 200);
  1768.                                         GivePlayerWeapon(playerid, 24, 50);
  1769.                                         GivePlayerWeapon(playerid, 17, 3);
  1770.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Shotgun, Desert eagle, Teargas.");
  1771.                                     }
  1772.                                     case 6..8:
  1773.                                     {
  1774.                                         GivePlayerWeapon(playerid, 25, 200);
  1775.                                         GivePlayerWeapon(playerid, 24, 100);
  1776.                                         GivePlayerWeapon(playerid, 17, 3);
  1777.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Shotgun, Desert eagle, Teargas.");
  1778.                                     }
  1779.                                     default:
  1780.                                     {
  1781.                                         GivePlayerWeapon(playerid, 25, 200);
  1782.                                         GivePlayerWeapon(playerid, 24, 200);
  1783.                                         GivePlayerWeapon(playerid, 18, 3);
  1784.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Shotgun, Desert eagle, Moltoves.");
  1785.                                     }
  1786.                                 }
  1787.                             }
  1788.                             case 5:
  1789.                             {
  1790.                                 NotifyPlayer(playerid, "You have selected class ~g~Spy", 5000);
  1791.                                 SendClientMessage(playerid, COLOR_CORAL, "- Your class is "LIGHT_BLUE"Spy "HOT_PINK"(You recieve class bonus according to your rank!)");
  1792.  
  1793.                                 switch(rank)
  1794.                                 {
  1795.                                     case 8:
  1796.                                     {
  1797.                                         GivePlayerWeapon(playerid, 29, 200);
  1798.                                         GivePlayerWeapon(playerid, 23, 100);
  1799.                                         GivePlayerWeapon(playerid, 18, 3);
  1800.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: MP4, Silenced 9mm, Moltove.");
  1801.                                     }
  1802.                                     case 9..10:
  1803.                                     {
  1804.                                         GivePlayerWeapon(playerid, 29, 300);
  1805.                                         GivePlayerWeapon(playerid, 23, 200);
  1806.                                         GivePlayerWeapon(playerid, 18, 3);
  1807.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: MP4, Silenced 9mm, Moltove.");
  1808.                                     }
  1809.                                     default:
  1810.                                     {
  1811.                                         GivePlayerWeapon(playerid, 29, 300);
  1812.                                         GivePlayerWeapon(playerid, 23, 200);
  1813.                                         GivePlayerWeapon(playerid, 25, 200);
  1814.                                         GivePlayerWeapon(playerid, 18, 3);
  1815.                                         SendClientMessage(playerid, COLOR_CORAL, "- Weapons: MP4, Silenced 9mm, Shotgun, Moltove.");
  1816.                                     }
  1817.                                 }
  1818.  
  1819.                                 gDis[playerid] = 3;
  1820.                             }
  1821.                             case 6:
  1822.                             {
  1823.                                 NotifyPlayer(playerid, "You have selected class ~g~Terminator", 5000);
  1824.                                 SendClientMessage(playerid, COLOR_CORAL, "- Your class is "LIGHT_BLUE"Terminator");
  1825.                                 GivePlayerWeapon(playerid, 38, 100);
  1826.                                 GivePlayerWeapon(playerid, 24, 300);
  1827.                                 GivePlayerWeapon(playerid, 9, 1);
  1828.                                 GivePlayerWeapon(playerid, 18, 10);
  1829.                                 SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Minigun, Desert Eagle, Chainsaw Moltoves.");
  1830.                             }
  1831.                         }
  1832.                     }
  1833.                     default:
  1834.                     {
  1835.                         NotifyPlayer(playerid, "~r~There is no classes for team AFRICA!", 5000);
  1836.  
  1837.                         switch(rank)
  1838.                         {
  1839.                             case 0..3:
  1840.                             {
  1841.                                 GivePlayerWeapon(playerid, 30, 200);
  1842.                                 GivePlayerWeapon(playerid, 24, 100);
  1843.                                 GivePlayerWeapon(playerid, 4, 1);
  1844.                                 SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Ak-47, Desert Eagle, Knife.");
  1845.                             }
  1846.                             case 4..7:
  1847.                             {
  1848.                                 GivePlayerWeapon(playerid, 30, 500);
  1849.                                 GivePlayerWeapon(playerid, 24, 300);
  1850.                                 GivePlayerWeapon(playerid, 4, 1);
  1851.                                 GivePlayerWeapon(playerid, 18, 5);
  1852.                                 SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Ak-47, Desert Eagle, Knife, Moltove.");
  1853.                             }
  1854.                             default:
  1855.                             {
  1856.                                 GivePlayerWeapon(playerid, 30, 500);
  1857.                                 GivePlayerWeapon(playerid, 24, 300);
  1858.                                 GivePlayerWeapon(playerid, 4, 1);
  1859.                                 GivePlayerWeapon(playerid, 18, 5);
  1860.                                 GivePlayerWeapon(playerid, 35, 1);
  1861.                                 SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Ak-47, Desert Eagle, Knife, Moltove, RPG.");
  1862.                             }
  1863.                         }
  1864.                     }
  1865.                 }
  1866.  
  1867.                 if(GetPlayerTeam(playerid) != 7) SendClientMessage(playerid, COLOR_WHITE, "Type /chelp to get info. about your class; Type /sc to switch class in next spawn.");
  1868.  
  1869.                 //anti spawnkill system
  1870.                 switch(rank)
  1871.                 {
  1872.                     case 0: gAntiSpawnkill[playerid][A_HP] = 100.0, gAntiSpawnkill[playerid][A_AR] = 100.0;
  1873.                     case 1: gAntiSpawnkill[playerid][A_HP] = 75.0, gAntiSpawnkill[playerid][A_AR] = 0.0;
  1874.                     case 2: gAntiSpawnkill[playerid][A_HP] = 90.0, gAntiSpawnkill[playerid][A_AR] = 0.0;
  1875.                     case 3: gAntiSpawnkill[playerid][A_HP] = 100.0, gAntiSpawnkill[playerid][A_AR] = 0.0;
  1876.                     case 4..5: gAntiSpawnkill[playerid][A_HP] = 100.0, gAntiSpawnkill[playerid][A_AR] = 10.0;
  1877.                     case 6..7: gAntiSpawnkill[playerid][A_HP] = 100.0, gAntiSpawnkill[playerid][A_AR] = 25.0;
  1878.                     case 8..10: gAntiSpawnkill[playerid][A_HP] = 100.0, gAntiSpawnkill[playerid][A_AR] = 45.0;
  1879.                     case 11..13: gAntiSpawnkill[playerid][A_HP] = 100.0, gAntiSpawnkill[playerid][A_AR] = 60.0;
  1880.                     case 14..15: gAntiSpawnkill[playerid][A_HP] = 100.0, gAntiSpawnkill[playerid][A_AR] = 75.0;
  1881.                     default: gAntiSpawnkill[playerid][A_HP] = 100.0, gAntiSpawnkill[playerid][A_AR] = 100.0;
  1882.                 }
  1883.                 format(string, sizeof(string), "* Your current rank is %s! Recieved a bonus of %0.2f% HEALTH and %0.2f% ARMOUR!", gRank[rank][r_name], gAntiSpawnkill[playerid][A_HP], gAntiSpawnkill[playerid][A_AR]);
  1884.                 SendClientMessage(playerid, COLOR_YELLOW, string);
  1885.  
  1886.                 SendClientMessage(playerid, COLOR_RED, "-> You have Anti - Spawnkill protection for 10 seconds !");
  1887.                 gAntiSpawnkill[playerid][A_LABEL] = CreateDynamic3DTextLabel("Anti - Spawnkill protected", COLOR_RED, 0.0, 0.0, 0.3, 20.0, playerid, _, 1);
  1888.                 gAntiSpawnkill[playerid][A_TIMER] = 10;
  1889.                 SetPlayerHealth(playerid, FLOAT_INFINITY);
  1890.  
  1891.                 //prestige weapons
  1892.                 if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) > 2 || rank >= 10)
  1893.                 {
  1894.                     new weaponid;
  1895.                     GAdmin_RetrieveUserData(ReturnPlayerName(playerid), "i", "weapon1", weaponid);
  1896.                     if(IsValidWeapon(weaponid) && weaponid != 0)
  1897.                     {
  1898.                         format(string, sizeof(string), "* You recieved a %s as your prestige weapon I!", ReturnWeaponName(weaponid));
  1899.                         SendClientMessage(playerid, COLOR_YELLOW, string);
  1900.  
  1901.                         GivePlayerWeapon(playerid, weaponid, 200);
  1902.                     }
  1903.                 }
  1904.                 if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) > 2 || rank >= 15)
  1905.                 {
  1906.                     new weaponid;
  1907.                     GAdmin_RetrieveUserData(ReturnPlayerName(playerid), "i", "weapon2", weaponid);
  1908.                     if(IsValidWeapon(weaponid) && weaponid != 0)
  1909.                     {
  1910.                         format(string, sizeof(string), "* You recieved a %s as your prestige weapon II!", ReturnWeaponName(weaponid));
  1911.                         SendClientMessage(playerid, COLOR_YELLOW, string);
  1912.  
  1913.                         GivePlayerWeapon(playerid, weaponid, 200);
  1914.                     }
  1915.                 }
  1916.                 if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) > 2 || rank >= 20)
  1917.                 {
  1918.                     new weaponid;
  1919.                     GAdmin_RetrieveUserData(ReturnPlayerName(playerid), "i", "weapon3", weaponid);
  1920.                     if(IsValidWeapon(weaponid) && weaponid != 0)
  1921.                     {
  1922.                         format(string, sizeof(string), "* You recieved a %s as your prestige weapon III!", ReturnWeaponName(weaponid));
  1923.                         SendClientMessage(playerid, COLOR_YELLOW, string);
  1924.  
  1925.                         GivePlayerWeapon(playerid, weaponid, 200);
  1926.                     }
  1927.                 }
  1928.             }
  1929.         }
  1930.     }
  1931.     return 1;
  1932. }
  1933.  
  1934. //------------------------------------------------
  1935.  
  1936. public OnPlayerDeath(playerid, killerid, reason)
  1937. {
  1938.     new string[144];
  1939.     if(gDuel[playerid][d_induel])
  1940.     {
  1941.         GivePlayerMoney(gDuel[playerid][d_opponent], gDuel[playerid][d_bet]);
  1942.  
  1943.         format(string, sizeof(string), "%s have won the duel against opponent %s [weapon: %s, bet: $%i]", ReturnPlayerName(gDuel[playerid][d_opponent]), ReturnPlayerName(playerid), ReturnWeaponName(gDuel[playerid][d_weapon]), gDuel[playerid][d_bet]);
  1944.         SendClientMessageToAll(COLOR_AQUA, string);
  1945.         format(string, sizeof(string), "%s have won the duel against opponent %s", ReturnPlayerName(gDuel[playerid][d_opponent]), ReturnPlayerName(playerid));
  1946.         NotifyAll(string);
  1947.  
  1948.         gDuel[gDuel[playerid][d_opponent]][d_induel] = false;
  1949.         gDuel[gDuel[playerid][d_opponent]][d_opponent] = INVALID_PLAYER_ID;
  1950.         gDuel[gDuel[playerid][d_opponent]][d_weapon] = 0;
  1951.         gDuel[gDuel[playerid][d_opponent]][d_bet] = 0;
  1952.  
  1953.         gDuel[playerid][d_induel] = false;
  1954.         gDuel[playerid][d_opponent] = INVALID_PLAYER_ID;
  1955.         gDuel[playerid][d_weapon] = 0;
  1956.         gDuel[playerid][d_bet] = 0;
  1957.     }
  1958.  
  1959.     if(gBomb[playerid])
  1960.     {
  1961.         if(IsPlayerAttachedObjectSlotUsed(playerid, 4))
  1962.         {
  1963.             new Float:pos[3];
  1964.             GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  1965.             CreateExplosion(pos[0], pos[1], pos[2], 6, 1.00);
  1966.             gBomb[playerid] = false;
  1967.  
  1968.             GameTextForPlayer(playerid, "~g~DEMOLISHED", 3000, 3);
  1969.  
  1970.             foreach(new i : Player)
  1971.             {
  1972.                 if(gPlayerGamemode[i] == MODE_TEAM_DEATHMATCH)
  1973.                 {
  1974.                     new Float:x, Float:y, Float:z;
  1975.                     GetPlayerPos(i, x, y, z);
  1976.  
  1977.                     if(IsPlayerInRangeOfPoint(playerid, 3.0, x, y, z))
  1978.                     {
  1979.                         if(GetPlayerTeam(i) != GetPlayerTeam(i))
  1980.                         {
  1981.                             SetPlayerHealth(i, 0.0);
  1982.                             GameTextForPlayer(i, "~b~DEMOLISHED", 3000, 3);
  1983.  
  1984.                             format(string, sizeof(string), "* You got demolished by %s (Sucide Bomb)", ReturnPlayerName(playerid));
  1985.                             SendClientMessage(i, COLOR_YELLOW, string);
  1986.                             format(string, sizeof(string), "* You demolished %s with your Sucide Bomb!", ReturnPlayerName(i));
  1987.                             SendClientMessage(playerid, COLOR_YELLOW, string);
  1988.                            
  1989.                             SendDeathMessage(playerid, i, 49);
  1990.  
  1991.                             new kills;
  1992.                             GAdmin_RetrieveUserData(ReturnPlayerName(playerid), "i", "kills", kills);
  1993.                             GAdmin_ChangeUserData(ReturnPlayerName(playerid), "i", "kills", kills + 1);
  1994.                         }
  1995.                     }
  1996.                 }
  1997.             }
  1998.         }
  1999.     }
  2000.  
  2001.     PlayAudioStreamForPlayer(playerid,"http://k003.kiwi6.com/hotlink/vn2ctdhha3/game_over.mp3");
  2002.  
  2003.     new money = random(2000);
  2004.     GivePlayerMoney(playerid, - money);
  2005.  
  2006.     format(string, sizeof(string), "You lost -$%i!", money);
  2007.     SendClientMessage(playerid, COLOR_RED, string);
  2008.  
  2009.     //money bag droping
  2010.     if(playerid == gMoneyBag[MONEYBAG_PLAYER])
  2011.     {
  2012.         RemovePlayerAttachedObject(playerid, 1);
  2013.  
  2014.         new Float:x, Float:y, Float:z;
  2015.         GetPlayerPos(playerid, x, y, z);
  2016.         gMoneyBag[MONEYBAG_PICKUPID] = CreateDynamicPickup(1550, 1, x, y, z, MODE_MONEYBAG);
  2017.         gMoneyBag[MONEYBAG_PLAYER] = INVALID_PLAYER_ID;
  2018.  
  2019.         foreach(new i : Player)
  2020.         {
  2021.             if(gPlayerGamemode[i] == MODE_MONEYBAG)
  2022.             {
  2023.                 format(string, sizeof(string), "~r~%s(%d) have lost the~n~~r~money bag", ReturnPlayerName(playerid), playerid);
  2024.                 GameTextForPlayer(i, string, 5000, 3);
  2025.             }
  2026.         }
  2027.     }
  2028.  
  2029.     gPlayerLastVehicle[playerid] = -1;
  2030.  
  2031.     HidePlayerProgressBar(playerid, gPlayerCaptureBar[playerid]);
  2032.     PlayerTextDrawHide(playerid, gPlayerCaptureTD[playerid]);
  2033.  
  2034.     //our fading effect on screen!
  2035.     FadeColorForPlayer(playerid, 0, 0, 0, 200, 0, 0, 0, 0, 20, 10);
  2036.     return 1;
  2037. }
  2038.  
  2039. //------------------------------------------------
  2040.  
  2041. public OnFadeComplete(playerid, beforehold)
  2042. {
  2043.     return 1;
  2044. }
  2045.  
  2046. //------------------------------------------------
  2047.  
  2048. public OnPlayerTimeUpdate(playerid)
  2049. {
  2050.     new rank = GetPlayerRank(playerid);
  2051.  
  2052.     new hours, minutes, seconds;
  2053.     GetPlayerConnectedTime(playerid, hours, minutes, seconds);
  2054.  
  2055.     new string[256];
  2056.     if( gPlayerGamemode[playerid] == MODE_TEAM_DEATHMATCH &&
  2057.         GetPlayerTeam(playerid) < sizeof(gTeam))
  2058.     {
  2059.         format(string, sizeof(string), "%s\n\n%s", gRank[rank][r_name], ReturnPlayerClassName(playerid));
  2060.         UpdateDynamic3DTextLabelText(gPlayerLabel[playerid], GetPlayerColor(playerid), string);
  2061.  
  2062.         format(string, sizeof(string), "~g~~h~%s ~h~%s's ~h~%s ~h~%s ~w~~h~- /Help, /Cmds, /Duel, /Minigun, /Moneybag, /Glass, /Rpg - ~b~~h~~h~~h~%s~y~- ~w~~h~%i : %i : %i", ReturnPlayerName(playerid), gTeam[GetPlayerTeam(playerid)][E_NAME], gRank[rank][r_name], ReturnPlayerClassName(playerid), gRandomMessage[gRandomMessageIndex], hours, minutes, seconds);
  2063.     }
  2064.     else if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH)
  2065.     {
  2066.         format(string, sizeof(string), "Killed %i players", GetPlayerKills(playerid));
  2067.         UpdateDynamic3DTextLabelText(gPlayerLabel[playerid], GetPlayerColor(playerid), string);
  2068.  
  2069.         format(string, sizeof(string), "~g~~h~%s ~h~%s ~h~Deathmatcher ~w~~h~- /Help, /Cmds, /Duel, /Exit, /Dm, /Teles, /Pm, /Players - ~b~~h~~h~~h~Type /exit to return to team deathmatch!~y~- ~w~~h~%i : %i : %i", ReturnPlayerName(playerid), gRank[rank][r_name], hours, minutes, seconds);
  2070.     }
  2071.     else
  2072.     {
  2073.         UpdateDynamic3DTextLabelText(gPlayerLabel[playerid], GetPlayerColor(playerid), "-");
  2074.  
  2075.         format(string, sizeof(string), "~g~~h~%s ~h~%s ~h~Deathmatcher ~w~~h~- /Help, /Cmds, /Duel, /Minigun, /Moneybag, /Glass, /Rpg - ~b~~h~~h~~h~%s~y~- ~w~~h~%i : %i : %i", ReturnPlayerName(playerid), gRank[rank][r_name], gRandomMessage[gRandomMessageIndex], hours, minutes, seconds);
  2076.     }
  2077.     PlayerTextDrawSetString(playerid, gPlayerStatsTD[playerid], string);
  2078.  
  2079.     //anti spawnkill
  2080.     if(gAntiSpawnkill[playerid][A_TIMER] != -1)
  2081.     {
  2082.         gAntiSpawnkill[playerid][A_TIMER] -= 1;
  2083.  
  2084.         if(gAntiSpawnkill[playerid][A_TIMER] <= 0)
  2085.         {
  2086.             gAntiSpawnkill[playerid][A_TIMER] = -1;
  2087.             SetPlayerHealth(playerid, gAntiSpawnkill[playerid][A_HP]);
  2088.             SetPlayerArmour(playerid, gAntiSpawnkill[playerid][A_AR]);
  2089.             DestroyDynamic3DTextLabel(gAntiSpawnkill[playerid][A_LABEL]);
  2090.  
  2091.             SendClientMessage(playerid, COLOR_RED, "-> Anti - Spawnkill protection over !");
  2092.            
  2093.             if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) > 2)
  2094.             {
  2095.                 ResetPlayerWeapons(playerid);
  2096.                
  2097.                 new weapon, ammo;
  2098.                 for(new i; i < 11; i++)
  2099.                 {
  2100.                     GetPlayerWeaponData(playerid, i, weapon, ammo);
  2101.                     GivePlayerWeapon(playerid, weapon, ammo * 3);
  2102.                 }
  2103.                
  2104.                 SendClientMessage(playerid, COLOR_ORANGE_RED, "* You have recieved 3x additional ammo for each weapon (DONOR Level 3).");
  2105.             }
  2106.         }
  2107.     }
  2108.    
  2109.     //airdrop system
  2110.     if( ! GetPlayerVirtualWorld(playerid) &&
  2111.         ! GetPlayerInterior(playerid) &&
  2112.         IsPlayerSpawned(playerid) &&
  2113.         ! IsPlayerInAnyVehicle(playerid))
  2114.     {
  2115.         for(new i; i < MAX_AIRDROPS; i++)
  2116.         {
  2117.             if(gAirdrop[i][AIRDROP_EXIST])
  2118.             {
  2119.                 if(! gAirdrop[i][AIRDROP_PICKED])
  2120.                 {
  2121.                     if(IsPlayerInRangeOfPoint(playerid, 5.0, gAirdrop[i][AIRDROP_POS][0], gAirdrop[i][AIRDROP_POS][1], gAirdrop[i][AIRDROP_POS][2]))
  2122.                     {
  2123.                         GameTextForPlayer(playerid, "~n~~n~~n~~n~~n~~b~~h~~h~~h~Press ~h~~k~~CONVERSATION_NO~ ~b~~h~~h~~h~to pick", 1000, 3);
  2124.                         break;
  2125.                     }
  2126.                 }
  2127.             }
  2128.         }
  2129.     }
  2130.     return 1;
  2131. }
  2132.  
  2133. public OnTimeUpdate()
  2134. {
  2135.     new hours, minutes, seconds;
  2136.     gettime(hours, minutes, seconds);
  2137.  
  2138.     if( server_time != hours &&
  2139.         gStopTimeUpdate)
  2140.     {
  2141.         server_time = hours;
  2142.         switch(server_weather)
  2143.         {
  2144.             case 1: server_weather = 2;
  2145.             case 2: server_weather = 3;
  2146.             case 3: server_weather = 4;
  2147.             case 4: server_weather = 5;
  2148.             case 5: server_weather = 6;
  2149.             case 6: server_weather = 10;
  2150.             case 10: server_weather = 11;
  2151.             case 11: server_weather = 12;
  2152.             case 12: server_weather = 13;
  2153.             case 13: server_weather = 14;
  2154.             case 14: server_weather = 15;
  2155.             case 15: server_weather = 17;
  2156.             case 17: server_weather = 18;
  2157.             case 18: server_weather = 23;
  2158.             case 23: server_weather = 24;
  2159.             case 24: server_weather = 25;
  2160.             case 25: server_weather = 26;
  2161.             case 26: server_weather = 27;
  2162.             case 27: server_weather = 28;
  2163.             case 29: server_weather = 33;
  2164.             case 33: server_weather = 34;
  2165.             case 34: server_weather = 35;
  2166.             case 35: server_weather = 36;
  2167.             case 36: server_weather = 37;
  2168.             case 37: server_weather = 40;
  2169.             case 40: server_weather = 41;
  2170.             case 41: server_weather = 46;
  2171.             case 46: server_weather = 47;
  2172.             case 47: server_weather = 48;
  2173.             case 48: server_weather = 49;
  2174.             default: server_weather = 1;
  2175.         }
  2176.  
  2177.         SetWorldTime(server_time);
  2178.         SetWeather(server_weather);
  2179.  
  2180.         new string[144];
  2181.         format(string, sizeof(string), "* Server Time: %i:%i:%i", hours, minutes, seconds);
  2182.         SendClientMessageToAll(COLOR_LIGHT_BLUE, string);
  2183.     }
  2184.  
  2185.     if(gNuke[NUKE_TIME] > 0)
  2186.     {
  2187.         gNuke[NUKE_TIME] -= 1;
  2188.  
  2189.         if(gNuke[NUKE_TIME] <= 0)
  2190.         {
  2191.             new string[144];
  2192.             format(string, sizeof(string), "* The nuclear missle is ready to launch now!", hours, minutes, seconds);
  2193.             SendClientMessageToAll(COLOR_LIGHT_BLUE, string);
  2194.         }
  2195.     }
  2196.  
  2197.     gBonusTimer += 1;
  2198.     if(gBonusTimer >= BONUS_INTERVAL)
  2199.     {
  2200.         gBonusTimer = 0;
  2201.  
  2202.         gRandomMessageIndex = random(sizeof(gRandomMessage));
  2203.  
  2204.         new Float:val, intval;
  2205.         foreach(new i : Player)
  2206.         {
  2207.             if(GetPlayerTeam(i) == gCaptureZone[HEALTH_ZONE][E_ZONEOWNER])
  2208.             {
  2209.                 SendClientMessage(i, COLOR_KHAKI, "* Your team recieved +5 HP. from Cluckin bell.");
  2210.                 GetPlayerHealth(i, val);
  2211.                 if((val + 5.0) >= 100.0) SetPlayerHealth(i, 100.0);
  2212.                 else SetPlayerHealth(i, (val + 5.0));
  2213.             }
  2214.             if(GetPlayerTeam(i) == gCaptureZone[ARMOUR_ZONE][E_ZONEOWNER])
  2215.             {
  2216.                 SendClientMessage(i, COLOR_KHAKI, "* Your team recieved +5 AR. from Shipment.");
  2217.                 GetPlayerArmour(i, val);
  2218.                 if((val + 5.0) >= 100.0) SetPlayerArmour(i, 100.0);
  2219.                 else SetPlayerArmour(i, (val + 5.0));
  2220.             }
  2221.             if(GetPlayerTeam(i) == gCaptureZone[AMMO_ZONE][E_ZONEOWNER])
  2222.             {
  2223.                 SendClientMessage(i, COLOR_KHAKI, "* Your team recieved +Ammo. for your current weapon from Shooting Range.");
  2224.                 intval = GetPlayerWeapon(i);
  2225.                 switch(intval)
  2226.                 {
  2227.                     case 16..18,35,36,39: SetPlayerAmmo(i, intval, (GetPlayerAmmo(i) + 1));
  2228.                     case 22..34,38,41,42,43: SetPlayerAmmo(i, intval, (GetPlayerAmmo(i) + 25));
  2229.                     case 37: SetPlayerAmmo(i, intval, (GetPlayerAmmo(i) + 75));
  2230.                 }
  2231.             }
  2232.         }
  2233.     }
  2234.     return 1;
  2235. }
  2236.  
  2237. //------------------------------------------------
  2238.  
  2239. public OnPlayerStreamIn(playerid, forplayerid)
  2240. {
  2241.     return 1;
  2242. }
  2243.  
  2244. public OnPlayerStreamOut(playerid, forplayerid)
  2245. {
  2246.     return 1;
  2247. }
  2248.  
  2249. public OnVehicleStreamIn(vehicleid, forplayerid)
  2250. {
  2251.     //locking team prototypes for team members
  2252.     for(new i; i < sizeof(gPrototype); i++)
  2253.     {
  2254.         if(vehicleid == gPrototype[i][p_vehicle])
  2255.         {
  2256.             if(GetPlayerTeam(forplayerid) == gPrototype[i][p_owner] || GetPlayerTeam(forplayerid) == NO_TEAM) SetVehicleParamsForPlayer(gPrototype[i][p_vehicle], forplayerid, 1, 1);
  2257.             else SetVehicleParamsForPlayer(gPrototype[i][p_vehicle], forplayerid, 1, 0);
  2258.         }
  2259.     }
  2260.     return 1;
  2261. }
  2262.  
  2263. //------------------------------------------------
  2264.  
  2265. public OnVehicleSpawn(vehicleid)
  2266. {
  2267.     for(new i; i < sizeof(gPrototype); i++)
  2268.     {
  2269.         if(vehicleid == gPrototype[i][p_vehicle])
  2270.         {
  2271.             if(gPrototype[i][p_attacker] != INVALID_PLAYER_ID)
  2272.             {
  2273.                 gPlayerLastVehicle[gPrototype[i][p_attacker]] = -1;
  2274.             }
  2275.             gPrototype[i][p_attacked] = false;
  2276.             gPrototype[i][p_attacker] = INVALID_PLAYER_ID;
  2277.             break;
  2278.         }
  2279.     }
  2280.     return 1;
  2281. }
  2282.  
  2283. //------------------------------------------------
  2284.  
  2285. public OnVehicleDeath(vehicleid, killerid)
  2286. {
  2287.     for(new i; i < sizeof(gPrototype); i++)
  2288.     {
  2289.         if(vehicleid == gPrototype[i][p_vehicle])
  2290.         {
  2291.             if(gPrototype[i][p_attacked])
  2292.             {
  2293.                 new name[MAX_PLAYER_NAME];
  2294.                 GetPlayerName(gPrototype[i][p_attacker], name, sizeof(name));
  2295.  
  2296.                 new string[156];
  2297.                 format(string, sizeof(string), "PROTOTYPE: %s(%d) failed to steel team %s's prototype vehicle.", name, gPrototype[i][p_attacker], gTeam[ gPrototype[i][p_owner] ][E_NAME]);
  2298.                 SendClientMessageToAll(COLOR_TOMATO, string);
  2299.                 format(string, sizeof(string), "~b~~h~~h~~h~%s(%d) ~w~~h~failed to steel team %s's prototype vehicle.", name, gPrototype[i][p_attacker], gTeam[ gPrototype[i][p_owner] ][E_NAME]);
  2300.                 NotifyAll(string, 5000);
  2301.  
  2302.                 DisablePlayerRaceCheckpoint(gPrototype[i][p_attacker]);
  2303.                 gPrototype[i][p_attacked] = false;
  2304.                 gPrototype[i][p_attacker] = INVALID_PLAYER_ID;
  2305.                 break;
  2306.             }
  2307.         }
  2308.     }
  2309.     return 1;
  2310. }
  2311.  
  2312. //------------------------------------------------
  2313.  
  2314. //synchronize system, not 100% !!
  2315. SyncPlayer(playerid)
  2316. {
  2317.     new world = GetPlayerVirtualWorld(playerid);//store player virtual world in var
  2318.     new interior = GetPlayerInterior(playerid);//store player interior in var
  2319.  
  2320.     TogglePlayerControllable(playerid, false);//freeze player
  2321.     SetPlayerVirtualWorld(playerid, world + 1);//changing the world id
  2322.     SetPlayerInterior(playerid, interior + 1);//changeing the interior (+1)
  2323.  
  2324.     SetPlayerVirtualWorld(playerid, world);//reset to default world
  2325.     SetPlayerInterior(playerid, interior);//reset to default interior
  2326.     TogglePlayerControllable(playerid, true);//unfreeze player
  2327.     ClearAnimations(playerid);//clear anims
  2328.     return true;//sucess
  2329. }
  2330.  
  2331. //------------------------------------------------
  2332.  
  2333. public OnPlayerUpdate(playerid)
  2334. {
  2335.     //anti-team knifing - not 100% accurate but sometimes work
  2336.     if(GetPlayerWeapon(playerid) == 4)//if the player have a knife
  2337.     {
  2338.         if(GetPlayerAnimationIndex(playerid) != 0)//if an animation is being run over
  2339.         {
  2340.             new animation[2][35];//variable where we will store animation data
  2341.             GetAnimationName(GetPlayerAnimationIndex(playerid), animation[0], 35, animation[1], 35);//getting the animation data
  2342.  
  2343.             if( !strcmp(animation[0], "KNIFE", true)//if player is having animation from "KNIFE@" library
  2344.                 && !strcmp(animation[1], "KILL_KnifMONEYBAG_PLAYER", true))//if the animation is "stabbing" knife animation
  2345.             {
  2346.                 new target = GetPlayerTargetPlayer(playerid);//get the player target, the one who is going to get stabbed
  2347.  
  2348.                 if(IsPlayerConnected(target))//if the target player is connected, then proceed
  2349.                 {
  2350.                     new Float:x, Float:y, Float:z;
  2351.                     GetPlayerPos(target, x, y, z);//store player position data in FLOATING variables
  2352.  
  2353.                     if(IsPlayerInRangeOfPoint(playerid, 5.0, x, y, z))//an aditional check if the player is in range so that false detects or animations are not detected! You can set the range accordingly!
  2354.                     {
  2355.                         if(GetPlayerTeam(playerid) == GetPlayerTeam(target))//if the target's team is same that of player, then proceed
  2356.                         {
  2357.                             ClearAnimations(playerid);//clear player animations
  2358.  
  2359.                             GetPlayerPos(playerid, x, y, z);//store player position coords
  2360.                             SetPlayerPos(playerid, x, y, z+5);//a sort of eject system, simply sets player height!
  2361.  
  2362.                             GameTextForPlayer(playerid, "~r~Don't knife your Teammates", 3000, 3);//a warning gametext to player
  2363.  
  2364.                             SyncPlayer(target);//sync the target who got stabbed! This is not 100% sure system, maybe the desync is still there!
  2365.                         }
  2366.                     }
  2367.                 }
  2368.             }
  2369.         }
  2370.     }
  2371.  
  2372.     //moneybag DM
  2373.     if(gMoneyBag[MONEYBAG_PLAYER] == playerid)
  2374.     {
  2375.         GivePlayerMoney(playerid, 1);
  2376.     }
  2377.     return 1;
  2378. }
  2379.  
  2380. //------------------------------------------------
  2381.  
  2382. forward OnCaptureZoneUpdate(zoneid);
  2383. public OnCaptureZoneUpdate(zoneid)
  2384. {
  2385.     new players = 0;
  2386.     new string[156];
  2387.     if(gCaptureZone[zoneid][E_ZONEATTACKED])
  2388.     {
  2389.         foreach(new i : Player)
  2390.         {
  2391.             if( IsPlayerInDynamicCP(i, gCaptureZone[zoneid][E_ZONECP]) &&
  2392.                 GetPlayerTeam(i) == GetPlayerTeam(gCaptureZone[zoneid][E_ZONEATTACKER]) &&
  2393.                 ! IsPlayerInAnyVehicle(i))
  2394.             {
  2395.                 players += 1;
  2396.             }
  2397.         }
  2398.  
  2399.         if(players < 1)
  2400.         {
  2401.             //hide capture visuals
  2402.             foreach(new x : Player)
  2403.             {
  2404.                 if(IsPlayerInDynamicCP(x, gCaptureZone[zoneid][E_ZONECP]))
  2405.                 {
  2406.                     HidePlayerProgressBar(x, gPlayerCaptureBar[x]);
  2407.                     PlayerTextDrawHide(x, gPlayerCaptureTD[x]);
  2408.                 }
  2409.             }
  2410.  
  2411.             GangZoneStopFlashForAll(gCaptureZone[zoneid][E_ZONEID]);
  2412.  
  2413.             gCaptureZone[zoneid][E_ZONEATTACKER] = INVALID_PLAYER_ID;
  2414.             gCaptureZone[zoneid][E_ZONEATTACKED] = false;
  2415.             gCaptureZone[zoneid][E_ZONERATE] = 0;
  2416.             gCaptureZone[zoneid][E_ZONERATEI] = 30;
  2417.             return 1;
  2418.         }
  2419.  
  2420.         switch(players)
  2421.         {
  2422.             case 1: gCaptureZone[zoneid][E_ZONERATE] += 1, gCaptureZone[zoneid][E_ZONERATEI] -= 1;
  2423.             case 2,3: gCaptureZone[zoneid][E_ZONERATE] += 2, gCaptureZone[zoneid][E_ZONERATEI] -= 2;
  2424.             default: gCaptureZone[zoneid][E_ZONERATE] += 3, gCaptureZone[zoneid][E_ZONERATEI] -= 3;
  2425.         }
  2426.  
  2427.         foreach(new i : Player)
  2428.         {
  2429.             if( IsPlayerInDynamicCP(i, gCaptureZone[zoneid][E_ZONECP]) &&
  2430.                 GetPlayerTeam(i) == GetPlayerTeam(gCaptureZone[zoneid][E_ZONEATTACKER]) &&
  2431.                 ! IsPlayerInAnyVehicle(i))
  2432.             {
  2433.                 SetPlayerProgressBarValue(i, gPlayerCaptureBar[i], gCaptureZone[zoneid][E_ZONERATE]);
  2434.  
  2435.                 format(string, sizeof(string), "Capturing %i...", gCaptureZone[zoneid][E_ZONERATEI]);
  2436.                 PlayerTextDrawSetString(i, gPlayerCaptureTD[i], string);
  2437.             }
  2438.         }
  2439.  
  2440.         if(gCaptureZone[zoneid][E_ZONERATE] > CAPTURE_TIME)
  2441.         {
  2442.             //hide capture visuals
  2443.             foreach(new x : Player)
  2444.             {
  2445.                 if(GetPlayerTeam(x) == GetPlayerTeam(gCaptureZone[zoneid][E_ZONEATTACKER]))
  2446.                 {
  2447.                     format(string, sizeof(string), "* You recieved +1 score from the captured zone!");
  2448.                     SendClientMessage(x, COLOR_WHITE, string);
  2449.  
  2450.                     GivePlayerScore(x, 1);
  2451.                 }
  2452.                 if(GetPlayerTeam(x) == GetPlayerTeam(gCaptureZone[zoneid][E_ZONEOWNER]))
  2453.                 {
  2454.                     format(string, sizeof(string), "* You recieved -1 score from the lost capture zone!");
  2455.                     SendClientMessage(x, COLOR_WHITE, string);
  2456.  
  2457.                     GivePlayerScore(x, -1);
  2458.                 }
  2459.                 if(IsPlayerInDynamicCP(x, gCaptureZone[zoneid][E_ZONECP]))
  2460.                 {
  2461.                     SetPlayerProgressBarValue(x, gPlayerCaptureBar[x], 0.0);
  2462.                     HidePlayerProgressBar(x, gPlayerCaptureBar[x]);
  2463.  
  2464.                     PlayerTextDrawHide(x, gPlayerCaptureTD[x]);
  2465.  
  2466.                     if(x == gCaptureZone[zoneid][E_ZONEATTACKER])
  2467.                     {
  2468.                         new Float:val;
  2469.                         GetPlayerArmour(x, val);
  2470.                         if((val + 15.0) >= 100.0) SetPlayerArmour(x, 100.0);
  2471.                         else SetPlayerArmour(x, (val + 15.0));
  2472.  
  2473.                         NotifyPlayer(x, "You have successfully captured the zone (~g~+3500$, +5 Score~w~~h~)", 5000);
  2474.  
  2475.                         GivePlayerMoney(x, 3500);
  2476.                         GivePlayerScore(x, 5);
  2477.                        
  2478.                         gCaptureSpree[x] += 1;
  2479.                        
  2480.                         if(gCaptureSpree[x] > 1)
  2481.                         {
  2482.                             format(string, sizeof(string), "Capture zone spree: %i (+1 extra score)", gCaptureSpree[x]);
  2483.                             SendClientMessage(x, COLOR_LIME, string);
  2484.                             GivePlayerScore(x, 1);
  2485.                         }
  2486.                     }
  2487.                     else if(GetPlayerTeam(x) == GetPlayerTeam(gCaptureZone[zoneid][E_ZONEATTACKER]))
  2488.                     {
  2489.                         new Float:val;
  2490.                         GetPlayerArmour(x, val);
  2491.                         if((val + 15.0) >= 100.0) SetPlayerArmour(x, 100.0);
  2492.                         else SetPlayerArmour(x, (val + 15.0));
  2493.  
  2494.                         NotifyPlayer(x, "You have successfully captured the zone - supported (~g~+1500$, +1 Score~w~~h~)", 5000);
  2495.  
  2496.                         GivePlayerMoney(x, 1500);
  2497.                         GivePlayerScore(x, 1);
  2498.                     }
  2499.                 }
  2500.  
  2501.                 switch(zoneid)
  2502.                 {
  2503.                     case HEALTH_ZONE:
  2504.                     {
  2505.                         if(GetPlayerTeam(x) == GetPlayerTeam(gCaptureZone[zoneid][E_ZONEATTACKER]))
  2506.                         {
  2507.                             SendClientMessage(x, COLOR_KHAKI, "Your team have captured Cluckin Bell.");
  2508.                             SendClientMessage(x, COLOR_KHAKI, "Your team will recieve +5 HP. after every "#BONUS_INTERVAL" seconds.");
  2509.                         }
  2510.                     }
  2511.                     case ARMOUR_ZONE:
  2512.                     {
  2513.                         if(GetPlayerTeam(x) == GetPlayerTeam(gCaptureZone[zoneid][E_ZONEATTACKER]))
  2514.                         {
  2515.                             SendClientMessage(x, COLOR_KHAKI, "Your team have captured Shipment.");
  2516.                             SendClientMessage(x, COLOR_KHAKI, "Your team will recieve +5 AR. after every "#BONUS_INTERVAL" seconds.");
  2517.                         }
  2518.                     }
  2519.                     case AMMO_ZONE:
  2520.                     {
  2521.                         if(GetPlayerTeam(x) == GetPlayerTeam(gCaptureZone[zoneid][E_ZONEATTACKER]))
  2522.                         {
  2523.                             SendClientMessage(x, COLOR_KHAKI, "Your team have captured Shooting Range.");
  2524.                             SendClientMessage(x, COLOR_KHAKI, "Your team will recieve +Ammo for your armed weapon after every "#BONUS_INTERVAL" seconds.");
  2525.                         }
  2526.                     }
  2527.                 }
  2528.             }
  2529.  
  2530.             format(string, sizeof(string), "~b~~h~~h~~h~%s ~w~~h~have captured %s for team %s", ReturnPlayerName(gCaptureZone[zoneid][E_ZONEATTACKER]), gCaptureZone[zoneid][E_ZONENAME], gTeam[ GetPlayerTeam(gCaptureZone[zoneid][E_ZONEATTACKER]) ][E_NAME]);
  2531.             NotifyAll(string, 5000);
  2532.  
  2533.             GangZoneStopFlashForAll(gCaptureZone[zoneid][E_ZONEID]);
  2534.             GangZoneShowForAll(gCaptureZone[zoneid][E_ZONEID], gTeam[ GetPlayerTeam(gCaptureZone[zoneid][E_ZONEATTACKER]) ][E_COLOR]);
  2535.  
  2536.             gCaptureZone[zoneid][E_ZONEOWNER] = GetPlayerTeam(gCaptureZone[zoneid][E_ZONEATTACKER]);
  2537.             gCaptureZone[zoneid][E_ZONEATTACKER] = NO_TEAM;
  2538.             gCaptureZone[zoneid][E_ZONEATTACKED] = false;
  2539.             gCaptureZone[zoneid][E_ZONERATE] = 0;
  2540.             gCaptureZone[zoneid][E_ZONERATEI] = 30;
  2541.  
  2542.             format(string, sizeof(string), "%s's\n%s(%i)", gTeam[ gCaptureZone[zoneid][E_ZONEOWNER] ][E_NAME], gCaptureZone[zoneid][E_ZONENAME], zoneid);
  2543.             UpdateDynamic3DTextLabelText(gCaptureZone[zoneid][E_ZONELABEL], gTeam[ gCaptureZone[zoneid][E_ZONEOWNER] ][E_COLOR], string);
  2544.         }
  2545.     }
  2546.     return 1;
  2547. }
  2548.  
  2549. //------------------------------------------------
  2550.  
  2551. public OnPlayerEnterDynamicCP(playerid, checkpointid)
  2552. {
  2553.     new string[156];
  2554.     if(GetPlayerTeam(playerid) != NO_TEAM)
  2555.     {
  2556.         for(new i; i < sizeof(gCaptureZone); i++)
  2557.         {
  2558.             if(gCaptureZone[i][E_ZONECP] == checkpointid)
  2559.             {
  2560.                 if(gCaptureZone[i][E_ZONEATTACKED])
  2561.                 {
  2562.                     if(GetPlayerTeam(playerid) == gCaptureZone[i][E_ZONEOWNER])
  2563.                     {
  2564.                         NotifyPlayer(playerid, "Defend this zone from enemies ~r~!", 5000);
  2565.                         break;
  2566.                     }
  2567.                     else if(GetPlayerTeam(playerid) == GetPlayerTeam(gCaptureZone[i][E_ZONEATTACKER]))
  2568.                     {
  2569.                         if(IsPlayerInAnyVehicle(playerid)) return NotifyPlayer(playerid, "You can't capture while you are in a ~r~vehicle", 5000);
  2570.  
  2571.                         NotifyPlayer(playerid, "Stay in the checkpoint to capture the zone ~g~!", 5000);
  2572.  
  2573.                         ShowPlayerProgressBar(playerid, gPlayerCaptureBar[playerid]);
  2574.                         SetPlayerProgressBarValue(playerid, gPlayerCaptureBar[playerid], gCaptureZone[i][E_ZONERATE]);
  2575.  
  2576.                         PlayerTextDrawShow(playerid, gPlayerCaptureTD[playerid]);
  2577.                         format(string, sizeof(string), "Capturing %i...", gCaptureZone[i][E_ZONERATEI]);
  2578.                         PlayerTextDrawSetString(playerid, gPlayerCaptureTD[playerid], string);
  2579.                         break;
  2580.                     }
  2581.                     else
  2582.                     {
  2583.                         NotifyPlayer(playerid, "Zone is ~r~under attack~w~~h~; Defend the area !", 5000);
  2584.                         break;
  2585.                     }
  2586.                 }
  2587.                 else
  2588.                 {
  2589.                     if(GetPlayerTeam(playerid) != gCaptureZone[i][E_ZONEOWNER])
  2590.                     {
  2591.                         if(IsPlayerInAnyVehicle(playerid)) return NotifyPlayer(playerid, "You can't capture while you are in a ~r~vehicle", 5000);
  2592.  
  2593.                         format(string, sizeof(string), "The zone is controlled by team %s", gTeam[ gCaptureZone[i][E_ZONEOWNER] ][E_NAME]);
  2594.                         SendClientMessage(playerid, COLOR_WHITE, string);
  2595.  
  2596.                         NotifyPlayer(playerid, "Stay in the checkpoint to capture the zone ~g~!", 5000);
  2597.                         //attack the zone
  2598.                         GangZoneFlashForAll(gCaptureZone[i][E_ZONEID], gTeam[ GetPlayerTeam(playerid) ][E_COLOR]);
  2599.  
  2600.                         gCaptureZone[i][E_ZONEATTACKER] = playerid;
  2601.                         gCaptureZone[i][E_ZONEATTACKED] = true;
  2602.                         gCaptureZone[i][E_ZONERATE] = 0;
  2603.                         gCaptureZone[i][E_ZONERATEI] = 30;
  2604.  
  2605.                         foreach(new x : Player)
  2606.                         {
  2607.                             if( IsPlayerInDynamicCP(x, gCaptureZone[i][E_ZONECP]) &&
  2608.                                 GetPlayerTeam(x) == GetPlayerTeam(gCaptureZone[i][E_ZONEATTACKER]) &&
  2609.                                 ! IsPlayerInAnyVehicle(x))
  2610.                             {
  2611.                                 ShowPlayerProgressBar(x, gPlayerCaptureBar[x]);
  2612.                                 SetPlayerProgressBarValue(x, gPlayerCaptureBar[x], gCaptureZone[i][E_ZONERATE]);
  2613.  
  2614.                                 PlayerTextDrawShow(x, gPlayerCaptureTD[x]);
  2615.                                 format(string, sizeof(string), "Capturing %i...", gCaptureZone[i][E_ZONERATEI]);
  2616.                                 PlayerTextDrawSetString(x, gPlayerCaptureTD[x], string);
  2617.                             }
  2618.                         }
  2619.  
  2620.                         format(string, sizeof(string), "~b~~h~~h~~h~%s ~w~~h~is trying to capture %s's %s for team %s", ReturnPlayerName(playerid), gTeam[ gCaptureZone[i][E_ZONEOWNER] ][E_NAME], gCaptureZone[i][E_ZONENAME], gTeam[ GetPlayerTeam(playerid) ][E_NAME]);
  2621.                         NotifyAll(string, 5000);
  2622.                         break;
  2623.                     }
  2624.                     if(GetPlayerTeam(playerid) == gCaptureZone[i][E_ZONEOWNER])
  2625.                     {
  2626.                         NotifyPlayer(playerid, "This zone is under your team and safe ~g~!", 5000);
  2627.                         break;
  2628.                     }
  2629.                 }
  2630.             }
  2631.         }
  2632.     }
  2633.     return 1;
  2634. }
  2635.  
  2636. public OnPlayerLeaveDynamicCP(playerid, checkpointid)
  2637. {
  2638.     if(GetPlayerTeam(playerid) != NO_TEAM)
  2639.     {
  2640.         for(new i; i < sizeof(gCaptureZone); i++)
  2641.         {
  2642.             if(gCaptureZone[i][E_ZONECP] == checkpointid)
  2643.             {
  2644.                 if(gCaptureZone[i][E_ZONEATTACKED])
  2645.                 {
  2646.                     SetPlayerProgressBarValue(playerid, gPlayerCaptureBar[playerid], 0.0);
  2647.                     HidePlayerProgressBar(playerid, gPlayerCaptureBar[playerid]);
  2648.  
  2649.                     PlayerTextDrawHide(playerid, gPlayerCaptureTD[playerid]);
  2650.  
  2651.                     if(gCaptureZone[i][E_ZONEATTACKER] == playerid)
  2652.                     {
  2653.                         foreach(new p : Player)
  2654.                         {
  2655.                             if(IsPlayerInDynamicCP(p, checkpointid))
  2656.                             {
  2657.                                 if(GetPlayerTeam(p) == GetPlayerTeam(playerid))
  2658.                                 {
  2659.                                     gCaptureZone[i][E_ZONEATTACKER] = p;
  2660.                                     break;
  2661.                                 }
  2662.                             }
  2663.                         }
  2664.                     }
  2665.                 }
  2666.             }
  2667.         }
  2668.     }
  2669.     return 1;
  2670. }
  2671.  
  2672. //------------------------------------------------
  2673.  
  2674. public OnPlayerEnterGangZone(playerid, zone)
  2675. {
  2676.     //displays a capture zone name in lightest yellow when you enter the zone
  2677.     for(new i; i < sizeof(gCaptureZone); i++)
  2678.     {
  2679.         if(gCaptureZone[i][E_ZONEID] == zone)
  2680.         {
  2681.             new string[145];
  2682.             format(string, sizeof(string), "~y~~h~~h~%i %s", i, gCaptureZone[i][E_ZONENAME]);
  2683.             GameTextForPlayer(playerid, string, 5000, 1);
  2684.             break;
  2685.         }
  2686.     }
  2687.  
  2688.     //displays a team base name in light blue when you enter the base zone
  2689.     for(new i; i < sizeof(gTeamBase); i++)
  2690.     {
  2691.         if(gTeamBase[i][b_base] == zone)
  2692.         {
  2693.             new string[145];
  2694.             format(string, sizeof(string), "~b~~h~~h~~h~%s", gTeamBase[i][b_name]);
  2695.             GameTextForPlayer(playerid, string, 5000, 1);
  2696.             break;
  2697.         }
  2698.     }
  2699.     return 1;
  2700. }
  2701.  
  2702. //------------------------------------------------
  2703.  
  2704. public OnPlayerText(playerid, text[])
  2705. {
  2706.     SetPlayerChatBubble(playerid, text, 0xEEEEEEFF, 35.0, 10000);
  2707.  
  2708.     new string[145];
  2709.     format(string, sizeof(string), "%i> %s: "WHITE"%s", playerid, ReturnPlayerName(playerid), text);
  2710.     SendClientMessageToAll(GetPlayerColor(playerid), string);
  2711.     return 0;
  2712. }
  2713.  
  2714. //------------------------------------------------
  2715.  
  2716. //Anti team vehicle attack detector
  2717. public OnPlayerWeaponShot(playerid, weaponid, hittype, hitid, Float:fX, Float:fY, Float:fZ)
  2718. {
  2719.     if(hittype == BULLET_HIT_TYPE_VEHICLE)//if the bullet hits a vehicle
  2720.     {
  2721.         new target = INVALID_PLAYER_ID;//by default, an invalid player
  2722.         foreach(new i : Player)
  2723.         {
  2724.             if( i != playerid//if the loop case is not matching the playerid
  2725.             && IsPlayerConnected(i)//if the player is connected
  2726.             && GetPlayerVehicleID(i) == hitid//if the player is in vehicle that got hit
  2727.             && GetPlayerVehicleSeat(i) == 0)//if is driver
  2728.             {
  2729.                 target = i;//store the playerid in "target" variable
  2730.                 break;//stop the loop and continue
  2731.             }
  2732.         }
  2733.         if( target != INVALID_PLAYER_ID//if the target is not an invalid player
  2734.             && GetPlayerTeam(playerid) != NO_TEAM//if target id is having a valid team
  2735.             && GetPlayerTeam(playerid) == GetPlayerTeam(target))//if the target player is having same team id that of the shooter
  2736.         {
  2737.             GameTextForPlayer(playerid, "~r~Don't attack a Team vehicle", 3000, 3);//a warning gametext to player
  2738.             return 0;//stop the vehicle to get damage and the action to be taken
  2739.         }
  2740.     }
  2741.     return 1;
  2742. }
  2743.  
  2744. //------------------------------------------------
  2745.  
  2746. public OnPlayerTakeDamage(playerid, issuerid, Float: amount, weaponid, bodypart)
  2747. {
  2748.     if( (GetPlayerTeam(playerid) == NO_TEAM && GetPlayerTeam(issuerid) == NO_TEAM) ||//if player is of a valid team
  2749.         GetPlayerTeam(playerid) == GetPlayerTeam(issuerid))//if the team ids matches
  2750.     {
  2751.         GameTextForPlayer(issuerid, "~r~Don't attack your Teammates", 3000, 3);//a warning gametext to player
  2752.         return 0;//stop the damage and the action to be taken
  2753.     }
  2754.     return 1;
  2755. }
  2756.  
  2757. //------------------------------------------------
  2758.  
  2759. //Anti team vehicle jack
  2760. public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
  2761. {
  2762.     if(! ispassenger)//if the player is entering as a driver
  2763.     {
  2764.         new target = INVALID_PLAYER_ID;//by default, an invalid player
  2765.         foreach(new i : Player)
  2766.         {
  2767.             if( i != playerid//if the loop case is not matching the playerid
  2768.                 && IsPlayerConnected(i)//if the player is connected
  2769.                 && GetPlayerVehicleID(i) == vehicleid//if the player is in vehicle that got hit
  2770.                 && GetPlayerVehicleSeat(i) == 0)//if is driver
  2771.             {
  2772.                 target = i;//store the playerid in "target" variable
  2773.                 break;//stop the loop and continue
  2774.             }
  2775.         }
  2776.         if( target != INVALID_PLAYER_ID//if the target is not an invalid player
  2777.                 && GetPlayerTeam(playerid) != NO_TEAM//if target id is having a valid team
  2778.                 && GetPlayerTeam(playerid) == GetPlayerTeam(target))//if the target player is having same team id that of the shooter
  2779.         {
  2780.             ClearAnimations(playerid);//clear all animations of player that were being runned
  2781.  
  2782.             new Float:x, Float:y, Float:z;
  2783.             GetPlayerPos(playerid, x, y, z);//store player position coords
  2784.             SetPlayerPos(playerid, x, y, z+5);//a sort of eject system, simply sets player height!
  2785.  
  2786.             GameTextForPlayer(playerid, "~r~Don't jack your Team vehicle", 3000, 3);//a warning gametext to player
  2787.             return 0;//stop the player to take over the vehicle and the action to be taken
  2788.         }
  2789.     }
  2790.     return 1;
  2791. }
  2792.  
  2793. //------------------------------------------------
  2794.  
  2795. public OnPlayerExitVehicle(playerid, vehicleid)
  2796. {
  2797.     return 1;
  2798. }
  2799.  
  2800. //------------------------------------------------
  2801.  
  2802. public OnPlayerStateChange(playerid, newstate, oldstate)
  2803. {
  2804.     if(newstate == PLAYER_STATE_DRIVER)
  2805.     {
  2806.         for(new i; i < sizeof(gPrototype); i++)
  2807.         {
  2808.             if(GetPlayerVehicleID(playerid) == gPrototype[i][p_vehicle])
  2809.             {
  2810.                 if( GetPlayerTeam(playerid) != gPrototype[i][p_owner] &&
  2811.                     GetPlayerTeam(playerid) < sizeof(gTeam))
  2812.                 {
  2813.                     if(! gPrototype[i][p_attacked])
  2814.                     {
  2815.                         new name[MAX_PLAYER_NAME];
  2816.                         GetPlayerName(playerid, name, sizeof(name));
  2817.                         new string[156];
  2818.                         format(string, sizeof(string), "PROTOTYPE: %s(%d) is trying to steel team %s's prototype vehicle.", name, playerid, gTeam[ gPrototype[i][p_owner] ][E_NAME]);
  2819.                         SendClientMessageToAll(COLOR_TOMATO, string);
  2820.                         format(string, sizeof(string), "~b~~h~~h~~h~%s(%d) ~w~~h~is trying to steel team %s's prototype vehicle.", name, playerid, gTeam[ gPrototype[i][p_owner] ][E_NAME]);
  2821.                         NotifyAll(string, 5000);
  2822.                     }
  2823.  
  2824.                     gPlayerLastVehicle[playerid] = gPrototype[i][p_vehicle];
  2825.                     gPrototype[i][p_attacked] = true;
  2826.                     gPrototype[i][p_attacker] = playerid;
  2827.                     NotifyPlayer(playerid, "Take the prototype to checkpoint (~y~located in your base~w~~h~)", 5000);
  2828.                     SendClientMessage(playerid, COLOR_WHITE, "* You have the enemy prototype, take it to your base and win the reward!");
  2829.                     SetPlayerRaceCheckpoint(playerid, 1, gPrototypeCP[GetPlayerTeam(playerid)][0], gPrototypeCP[GetPlayerTeam(playerid)][1], gPrototypeCP[GetPlayerTeam(playerid)][2], 0.0, 0.0, 0.0, 10.0);
  2830.                     break;
  2831.                 }
  2832.             }
  2833.         }
  2834.     }
  2835.     else
  2836.     {
  2837.         for(new i; i < sizeof(gPrototype); i++)
  2838.         {
  2839.             if(gPrototype[i][p_attacked])
  2840.             {
  2841.                 if(gPlayerLastVehicle[playerid] == gPrototype[i][p_vehicle])
  2842.                 {
  2843.                     if(GetPlayerTeam(playerid) != gPrototype[i][p_owner])
  2844.                     {
  2845.                         SendClientMessage(playerid, COLOR_WHITE, "* Warning, you have left the prototype vehicle, your mission will fail in 60 seconds unless you go back in!");
  2846.                         NotifyPlayer(playerid, "~r~WARNING! ~w~~h~The prototype will spawn after 60 seconds...", 5000);
  2847.                         DisablePlayerRaceCheckpoint(playerid);
  2848.                         gPlayerLastVehicle[playerid] = -1;
  2849.                         break;
  2850.                     }
  2851.                 }
  2852.             }
  2853.         }
  2854.     }
  2855.  
  2856.  
  2857.     new vehicleid = GetVehicleModel(GetPlayerVehicleID(playerid));
  2858.     if( vehicleid == 520 ||
  2859.         vehicleid == 425)
  2860.     {
  2861.         if( gClass[playerid] != CLASS_PILOT &&
  2862.             GetPlayerTeam(playerid) < sizeof(gTeam))
  2863.         {
  2864.             SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a Pilot to drive hunter, hydra. ]");
  2865.  
  2866.             new Float:x, Float:y, Float:z;
  2867.             GetPlayerPos(playerid, x, y, z);//store player position coords
  2868.             SetPlayerPos(playerid, x, y, z + 5);//a sort of eject system, simply sets player height!
  2869.             return 1;
  2870.         }
  2871.     }
  2872.     return 1;
  2873. }
  2874.  
  2875. //------------------------------------------------
  2876.  
  2877. public OnPlayerEnterRaceCheckpoint(playerid)
  2878. {
  2879.     for(new i; i < sizeof(gPrototype); i++)
  2880.     {
  2881.         if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
  2882.         {
  2883.             if(GetPlayerVehicleID(playerid) == gPrototype[i][p_vehicle])
  2884.             {
  2885.                 if(GetPlayerTeam(playerid) != gPrototype[i][p_owner])
  2886.                 {
  2887.                     new score = (1 + random(4));
  2888.                     new string[156];
  2889.                     format(string, sizeof(string), "You have successfully stolen prototype vehicle (~g~+250$, +i Score~w~~h~)", score);
  2890.                     NotifyPlayer(playerid, string, 5000);
  2891.                     GivePlayerMoney(playerid, 250);
  2892.                     GivePlayerScore(playerid, score);
  2893.                     DisablePlayerRaceCheckpoint(playerid);
  2894.  
  2895.                     SetVehicleToRespawn(gPrototype[i][p_vehicle]);
  2896.                     gPrototype[i][p_attacked] = false;
  2897.                     gPrototype[i][p_attacker] = INVALID_PLAYER_ID;
  2898.  
  2899.                     new name[MAX_PLAYER_NAME];
  2900.                     GetPlayerName(playerid, name, sizeof(name));
  2901.                     format(string, sizeof(string), "PROTOTYPE: %s(%d) was successfull to steel %s's prototype vehicle.", name, playerid, gTeam[ gPrototype[i][p_owner] ][E_NAME]);
  2902.                     SendClientMessageToAll(COLOR_TOMATO, string);
  2903.                     format(string, sizeof(string), "~b~~h~~h~~h~%s(%d) ~w~~h~ was successfull to steel %s's prototype vehicle.", name, playerid, gTeam[ gPrototype[i][p_owner] ][E_NAME]);
  2904.                     NotifyAll(string, 5000);
  2905.                     break;
  2906.                 }
  2907.             }
  2908.         }
  2909.     }
  2910.     return 1;
  2911. }
  2912.  
  2913. //------------------------------------------------
  2914.  
  2915. public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
  2916. {
  2917.     if(dialogid == DIALOG_HELP)
  2918.     {
  2919.         if(response)
  2920.         {
  2921.             switch(listitem)
  2922.             {
  2923.                 case 0:
  2924.                 {
  2925.                     new dialogstr[656];
  2926.                     strcat(dialogstr, ""LIGHT_BLUE"Well, thats to most simplest question and i don't think so you don't know how to play!\n\n");
  2927.                     strcat(dialogstr, "Never mind, this is a capture zone & tdm server. Basically your mission here is to\n");
  2928.                     strcat(dialogstr, "capture enemy zones and defend them in order to show domination.\n\n");
  2929.                     strcat(dialogstr, "There are more things to do, too. Such like participating in events,\n");
  2930.                     strcat(dialogstr, "joining races, playing at shops, freeroaming, all depends upon you.");
  2931.  
  2932.                     ShowPlayerDialog(playerid, DIALOG_HELP + 1, DIALOG_STYLE_MSGBOX, "How to play?", dialogstr, "Close", "Back");
  2933.                 }
  2934.                 case 1:
  2935.                 {
  2936.                     new dialogstr[656];
  2937.                     strcat(dialogstr, ""LIGHT_BLUE"PING, the biggest disturbing factor a user is offered while playing!\n\n");
  2938.                     strcat(dialogstr, "Ping completely depends upon your internet or broadband connection.\n");
  2939.                     strcat(dialogstr, "It depends on the bandwidth, the PC itself and the server script also!\n\n");
  2940.                     strcat(dialogstr, "To reduce ping, simply following the steps:\n");
  2941.                     strcat(dialogstr, ""RED"1. "LIGHT_BLUE"Close background downloads\n");
  2942.                     strcat(dialogstr, ""RED"2. "LIGHT_BLUE"Sometimes low FPS can cause low ping, close background Apps\n");
  2943.                     strcat(dialogstr, ""RED"3. "LIGHT_BLUE"OR, simply buy a better broadband network!");
  2944.  
  2945.                     ShowPlayerDialog(playerid, DIALOG_HELP + 1, DIALOG_STYLE_MSGBOX, "How to reduce PING?", dialogstr, "Close", "Back");
  2946.                 }
  2947.                 case 2:
  2948.                 {
  2949.                     new dialogstr[656];
  2950.                     strcat(dialogstr, ""LIGHT_BLUE"Unlocking new stuff will obviously require you with some cash and score.\n\n");
  2951.                     strcat(dialogstr, "The server provides you with loads of ways to earn:\n");
  2952.                     strcat(dialogstr, ""RED"1. "LIGHT_BLUE"Kill the enemy teams\n");
  2953.                     strcat(dialogstr, ""RED"2. "LIGHT_BLUE"Capture enemy zones\n");
  2954.                     strcat(dialogstr, ""RED"3. "LIGHT_BLUE"Steel the enemy prototype vehicle\n");
  2955.                     strcat(dialogstr, ""RED"4. "LIGHT_BLUE"Participate in events\n\n");
  2956.                     strcat(dialogstr, "After you have your desired ammount, go to shops and buy as much you can,\n");
  2957.                     strcat(dialogstr, "there's always something new in the shops.");
  2958.  
  2959.                     ShowPlayerDialog(playerid, DIALOG_HELP + 1, DIALOG_STYLE_MSGBOX, "How to unlock new stuff?", dialogstr, "Close", "Back");
  2960.                 }
  2961.                 case 3:
  2962.                 {
  2963.                     new dialogstr[656];
  2964.                     strcat(dialogstr, ""LIGHT_BLUE"DONOR refers to VIP.s of our server. We are famous enough to get VIPS!\n\n");
  2965.                     strcat(dialogstr, "Donor requires a user to pay or donate to the server and in exchange get premium gameplay features.\n");
  2966.                     strcat(dialogstr, "These features are only for donators of the server and are not life long, but for the amount of month \n");
  2967.                     strcat(dialogstr, "listed according to the payment.\n\n");
  2968.                     strcat(dialogstr, "The server don't enjoy the money you donate, there are several things we have to take car of:\n");
  2969.                     strcat(dialogstr, ""RED"1. "LIGHT_BLUE"Invest in hosting the server\n");
  2970.                     strcat(dialogstr, ""RED"2. "LIGHT_BLUE"Maintain the server and making it bugs free\n");
  2971.                     strcat(dialogstr, ""RED"3. "LIGHT_BLUE"Wages for server development team");
  2972.  
  2973.                     ShowPlayerDialog(playerid, DIALOG_HELP + 1, DIALOG_STYLE_MSGBOX, "How to be a DONOR?", dialogstr, "Close", "Back");
  2974.                 }
  2975.                 case 4:
  2976.                 {
  2977.                     new dialogstr[656];
  2978.                     strcat(dialogstr, ""LIGHT_BLUE"Currently, the staff application is OPEN, so you may be the lucky one.\n\n");
  2979.                     strcat(dialogstr, "The rank ADMIN is not ordinary or just a fun one, several duties come with it.\n");
  2980.                     strcat(dialogstr, "If you are not mature enough, then please don't try to apply for an admin.\n\n");
  2981.                     strcat(dialogstr, "Though, for becoming a staff memeber, you need to complete few requirements before which are\n");
  2982.                     strcat(dialogstr, "avaliable on server forums.\n\n");
  2983.                     strcat(dialogstr, "For applying for admin rank, go to forums and make a decent post giving all the necessary information required.\n\n");
  2984.                     strcat(dialogstr, ""MAROON"NOTE: "WHITE"Don't ask others to support you once applied.");
  2985.  
  2986.                     ShowPlayerDialog(playerid, DIALOG_HELP + 1, DIALOG_STYLE_MSGBOX, "How to an admin?", dialogstr, "Close", "Back");
  2987.                 }
  2988.                 case 5:
  2989.                 {
  2990.                     new dialogstr[656];
  2991.                     strcat(dialogstr, ""LIGHT_BLUE"This section is only for those who are scripters, though if you have opened it, so no problem!\n\n");
  2992.                     strcat(dialogstr, "The gamemode is quiet awesome, thats what most of the players say here.\n");
  2993.                     strcat(dialogstr, "Our script uses most advance libraries avaliable there on SAMP forums.\n\n");
  2994.                     strcat(dialogstr, "Just for example, we use YSI 4.0 for better and higher performance; fast and short coding; MYSQL database.\n\n");
  2995.                     strcat(dialogstr, "If you have a suggestion about the gamemode or script, feel free to post on the forums.");
  2996.  
  2997.                     ShowPlayerDialog(playerid, DIALOG_HELP + 1, DIALOG_STYLE_MSGBOX, "About gamemode", dialogstr, "Close", "Back");
  2998.                 }
  2999.                 case 7:
  3000.                 {
  3001.                     new dialogstr[656];
  3002.                     strcat(dialogstr, ""WHITE"The server has its own advance capturing zone system!\n");
  3003.                     strcat(dialogstr, "In order to capture zones, you have to follow the steps:\n\n");
  3004.                     strcat(dialogstr, ""RED"1. "LIGHT_BLUE"You see a flag mapicon overlaped witha Checkpoint. Go to any one with enemy colored gangzone.\n");
  3005.                     strcat(dialogstr, ""RED"2. "LIGHT_BLUE"Stay in the checkpoint for "#CAPTUR_TIME" seconds and cover yourself from enemies (if any).\n");
  3006.                     strcat(dialogstr, ""RED"3. "LIGHT_BLUE"Once the time is completed, you will get a notification and will given a reward for the capture.\n\n");
  3007.                     strcat(dialogstr, ""WHITE"For more help, ask an admin for help.");
  3008.  
  3009.                     ShowPlayerDialog(playerid, DIALOG_HELP + 1, DIALOG_STYLE_MSGBOX, "About capture zones", dialogstr, "Close", "Back");
  3010.                 }
  3011.                 case 8:
  3012.                 {
  3013.                     new dialogstr[656];
  3014.                     strcat(dialogstr, ""WHITE"New here, here are few things you need to keep in mind and tips:\n\n");
  3015.                     strcat(dialogstr, ""RED"1. "LIGHT_BLUE"Always follow the server /rules\n");
  3016.                     strcat(dialogstr, ""RED"2. "LIGHT_BLUE"Commands list, /cmds\n");
  3017.                     strcat(dialogstr, ""RED"3. "LIGHT_BLUE"Any sort of help, /help\n");
  3018.                     strcat(dialogstr, ""RED"2. "LIGHT_BLUE"Zones related, /zones & /findwar\n");
  3019.                     strcat(dialogstr, ""RED"4. "LIGHT_BLUE"Staff support, /admins\n");
  3020.                     strcat(dialogstr, ""RED"5. "LIGHT_BLUE"Kill yourself, /kill !");
  3021.  
  3022.                     ShowPlayerDialog(playerid, DIALOG_HELP + 1, DIALOG_STYLE_MSGBOX, "Getting started", dialogstr, "Close", "Back");
  3023.                 }
  3024.                 case 9:
  3025.                 {
  3026.                     new dialogstr[1024];
  3027.                     strcat(dialogstr, ""WHITE"These are general server rules, if you think we missed some, just keep that in mind\n");
  3028.                     strcat(dialogstr, "as a rule and don't break it! We will add it soon!\n\n");
  3029.                     strcat(dialogstr, ""RED"1. "LIGHT_BLUE"Never make use of cheats, hacks or methods of unfair gameplay.\n");
  3030.                     strcat(dialogstr, ""RED"2. "LIGHT_BLUE"Always respect every player and admin, dont provoke others.\n");
  3031.                     strcat(dialogstr, ""RED"3. "LIGHT_BLUE"Any sort of level boosting is strictly restricted. This may include:\n");
  3032.                     strcat(dialogstr, ""RED"    - "LIGHT_BLUE"Score boosting\n");
  3033.                     strcat(dialogstr, ""RED"    - "LIGHT_BLUE"Money boosting\n");
  3034.                     strcat(dialogstr, ""RED"    - "LIGHT_BLUE"Kills/Deaths boosting\n");
  3035.                     strcat(dialogstr, ""RED"4. "LIGHT_BLUE"Dont unnecessarly PM. or send messages to players.\n");
  3036.                     strcat(dialogstr, ""RED"5. "LIGHT_BLUE"Advertisements are not allowed, not in chat and PMs.\n");
  3037.                     strcat(dialogstr, ""RED". "LIGHT_BLUE"If you have applied for admin on forums, then dont ask users to support.\n");
  3038.                     strcat(dialogstr, ""RED"7. "LIGHT_BLUE"Don't misuse your admin or donor commands if provided.\n");
  3039.                     strcat(dialogstr, ""RED"8. "LIGHT_BLUE"Play as a faithfull, trustworthy, and friendly user.\n\n");
  3040.                     strcat(dialogstr, ""RED"NOTE: "WHITE"Violation of any of these rule can get you BAN, KICK, WARN, TEMPBAN...");
  3041.  
  3042.                     ShowPlayerDialog(playerid, DIALOG_HELP + 1, DIALOG_STYLE_MSGBOX, "Server rules", dialogstr, "Close", "Back");
  3043.                 }
  3044.             }
  3045.         }
  3046.     }
  3047.  
  3048.     if(dialogid == DIALOG_HELP + 1)
  3049.     {
  3050.         if(! response) return cmd_help(playerid);
  3051.     }
  3052.  
  3053.     if(dialogid == DIALOG_CLASS)
  3054.     {
  3055.         if(response)
  3056.         {
  3057.             new rank = GetPlayerRank(playerid);
  3058.             switch(listitem)
  3059.             {
  3060.                 case 2: if(rank < 1) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You need to be rank 1+ to use this class."), ShowPlayerClassSelectionDialog(playerid);
  3061.                 case 3: if(rank < 3) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You need to be rank 3+ to use this class."), ShowPlayerClassSelectionDialog(playerid);
  3062.                 case 4: if(rank < 5) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You need to be rank 5+ to use this class."), ShowPlayerClassSelectionDialog(playerid);
  3063.                 case 5: if(rank < 8) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You need to be rank 8+ to use this class."), ShowPlayerClassSelectionDialog(playerid);
  3064.                 case 6: if(rank < 12) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You need to be rank 12+ to use this class."), ShowPlayerClassSelectionDialog(playerid);
  3065.             }
  3066.             gClass[playerid] = listitem;
  3067.             gClassSelection[playerid] = false;
  3068.             //
  3069.  
  3070.             switch(GetPlayerTeam(playerid))
  3071.             {
  3072.                 case 0..6:
  3073.                 {
  3074.                     //class setup
  3075.                     switch(gClass[playerid])
  3076.                     {
  3077.                         case 0:
  3078.                         {
  3079.                             NotifyPlayer(playerid, "You have selected class ~g~Support", 5000);
  3080.                             SendClientMessage(playerid, COLOR_CORAL, "- Your class is "LIGHT_BLUE"Support "HOT_PINK"(You recieve class bonus according to your rank!)");
  3081.  
  3082.                             switch(rank)
  3083.                             {
  3084.                                 case 0..2:
  3085.                                 {
  3086.                                     GivePlayerWeapon(playerid, 30, 100 * (rank + 1));
  3087.                                     GivePlayerWeapon(playerid, 8, 1);
  3088.                                     GivePlayerWeapon(playerid, 17, 3);
  3089.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Ak-47, Katana, Teargas.");
  3090.                                 }
  3091.                                 case 3..5:
  3092.                                 {
  3093.                                     GivePlayerWeapon(playerid, 30, 300);
  3094.                                     GivePlayerWeapon(playerid, 24, 100);
  3095.                                     GivePlayerWeapon(playerid, 8, 1);
  3096.                                     GivePlayerWeapon(playerid, 17, 5);
  3097.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Ak-47, Desert Eagle, Katana, Teargas.");
  3098.                                 }
  3099.                                 default:
  3100.                                 {
  3101.                                     GivePlayerWeapon(playerid, 31, 300);
  3102.                                     GivePlayerWeapon(playerid, 24, 200);
  3103.                                     GivePlayerWeapon(playerid, 8, 1);
  3104.                                     GivePlayerWeapon(playerid, 17, 5);
  3105.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: M4, Desert Eagle, Katana, Teargas.");
  3106.                                 }
  3107.                             }
  3108.                         }
  3109.                         case 1:
  3110.                         {
  3111.                             NotifyPlayer(playerid, "You have selected class ~g~Medic", 5000);
  3112.                             SendClientMessage(playerid, COLOR_CORAL, "- Your class is "LIGHT_BLUE"Medic "HOT_PINK"(You recieve class bonus according to your rank!)");
  3113.  
  3114.                             switch(rank)
  3115.                             {
  3116.                                 case 0..2:
  3117.                                 {
  3118.                                     GivePlayerWeapon(playerid, 29, 100 * (rank + 1));
  3119.                                     GivePlayerWeapon(playerid, 9, 1);
  3120.                                     GivePlayerWeapon(playerid, 18, 2);
  3121.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Ak-47, Chainsaw, Moltove.");
  3122.                                 }
  3123.                                 case 3..5:
  3124.                                 {
  3125.                                     GivePlayerWeapon(playerid, 29, 500);
  3126.                                     GivePlayerWeapon(playerid, 9, 1);
  3127.                                     GivePlayerWeapon(playerid, 18, 3);
  3128.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Ak-47, Chainsaw, Moltove.");
  3129.                                 }
  3130.                                 default:
  3131.                                 {
  3132.                                     GivePlayerWeapon(playerid, 29, 500);
  3133.                                     GivePlayerWeapon(playerid, 23, 200);
  3134.                                     GivePlayerWeapon(playerid, 9, 1);
  3135.                                     GivePlayerWeapon(playerid, 18, 4);
  3136.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Ak-47, Silenced 9mm, Chainsaw, Moltove.");
  3137.                                 }
  3138.                             }
  3139.  
  3140.                             gPainkillers[playerid] = 3;
  3141.                         }
  3142.                         case 2:
  3143.                         {
  3144.                             NotifyPlayer(playerid, "You have selected class ~g~Scout", 5000);
  3145.                             SendClientMessage(playerid, COLOR_CORAL, "- Your class is "LIGHT_BLUE"Scout "HOT_PINK"(You recieve class bonus according to your rank!)");
  3146.  
  3147.                             switch(rank)
  3148.                             {
  3149.                                 case 1..2:
  3150.                                 {
  3151.                                     GivePlayerWeapon(playerid, 33, 100 * (rank + 1));
  3152.                                     GivePlayerWeapon(playerid, 4, 1);
  3153.                                     GivePlayerWeapon(playerid, 17, 2);
  3154.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Country Rifle, Knife, Teargas.");
  3155.                                 }
  3156.                                 case 3..5:
  3157.                                 {
  3158.                                     GivePlayerWeapon(playerid, 34, 500);
  3159.                                     GivePlayerWeapon(playerid, 4, 1);
  3160.                                     GivePlayerWeapon(playerid, 17, 4);
  3161.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Sniper Rifle, Knife, Teargas.");
  3162.                                 }
  3163.                                 default:
  3164.                                 {
  3165.                                     GivePlayerWeapon(playerid, 34, 500);
  3166.                                     GivePlayerWeapon(playerid, 22, 200);
  3167.                                     GivePlayerWeapon(playerid, 4, 1);
  3168.                                     GivePlayerWeapon(playerid, 17, 5);
  3169.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Sniper Rifle, 9mm, Knife, Teargas.");
  3170.                                 }
  3171.                             }
  3172.  
  3173.                             TogglePlayerMarker(playerid, false);
  3174.                         }
  3175.                         case 3:
  3176.                         {
  3177.                             NotifyPlayer(playerid, "You have selected class ~g~Jetrunner", 5000);
  3178.                             SendClientMessage(playerid, COLOR_CORAL, "- Your class is "LIGHT_BLUE"Jetrunner "HOT_PINK"(You recieve class bonus according to your rank!)");
  3179.  
  3180.                             switch(rank)
  3181.                             {
  3182.                                 case 3:
  3183.                                 {
  3184.                                     GivePlayerWeapon(playerid, 32, 300);
  3185.                                     GivePlayerWeapon(playerid, 3, 1);
  3186.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Tec-9, Baseball bat.");
  3187.                                 }
  3188.                                 case 4..7:
  3189.                                 {
  3190.                                     GivePlayerWeapon(playerid, 32, 500);
  3191.                                     GivePlayerWeapon(playerid, 22, 100);
  3192.                                     GivePlayerWeapon(playerid, 3, 1);
  3193.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Tec-9, 9mm, Baseball bat.");
  3194.                                 }
  3195.                                 default:
  3196.                                 {
  3197.                                     GivePlayerWeapon(playerid, 32, 500);
  3198.                                     GivePlayerWeapon(playerid, 26, 100);
  3199.                                     GivePlayerWeapon(playerid, 3, 1);
  3200.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Tec-9, Sawnoff Shotgun, Baseball bat.");
  3201.                                 }
  3202.                             }
  3203.                         }
  3204.                         case 4:
  3205.                         {
  3206.                             NotifyPlayer(playerid, "You have selected class ~g~Pilot", 5000);
  3207.                             SendClientMessage(playerid, COLOR_CORAL, "- Your class is "LIGHT_BLUE"Pilot "HOT_PINK"(You recieve class bonus according to your rank!)");
  3208.  
  3209.                             switch(rank)
  3210.                             {
  3211.                                 case 5:
  3212.                                 {
  3213.                                     GivePlayerWeapon(playerid, 25, 200);
  3214.                                     GivePlayerWeapon(playerid, 24, 50);
  3215.                                     GivePlayerWeapon(playerid, 17, 3);
  3216.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Shotgun, Desert eagle, Teargas.");
  3217.                                 }
  3218.                                 case 6..8:
  3219.                                 {
  3220.                                     GivePlayerWeapon(playerid, 25, 200);
  3221.                                     GivePlayerWeapon(playerid, 24, 100);
  3222.                                     GivePlayerWeapon(playerid, 17, 3);
  3223.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Shotgun, Desert eagle, Teargas.");
  3224.                                 }
  3225.                                 default:
  3226.                                 {
  3227.                                     GivePlayerWeapon(playerid, 25, 200);
  3228.                                     GivePlayerWeapon(playerid, 24, 200);
  3229.                                     GivePlayerWeapon(playerid, 18, 3);
  3230.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Shotgun, Desert eagle, Moltoves.");
  3231.                                 }
  3232.                             }
  3233.                         }
  3234.                         case 5:
  3235.                         {
  3236.                             NotifyPlayer(playerid, "You have selected class ~g~Spy", 5000);
  3237.                             SendClientMessage(playerid, COLOR_CORAL, "- Your class is "LIGHT_BLUE"Spy "HOT_PINK"(You recieve class bonus according to your rank!)");
  3238.  
  3239.                             switch(rank)
  3240.                             {
  3241.                                 case 8:
  3242.                                 {
  3243.                                     GivePlayerWeapon(playerid, 29, 200);
  3244.                                     GivePlayerWeapon(playerid, 23, 100);
  3245.                                     GivePlayerWeapon(playerid, 18, 3);
  3246.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: MP4, Silenced 9mm, Moltove.");
  3247.                                 }
  3248.                                 case 9..10:
  3249.                                 {
  3250.                                     GivePlayerWeapon(playerid, 29, 300);
  3251.                                     GivePlayerWeapon(playerid, 23, 200);
  3252.                                     GivePlayerWeapon(playerid, 18, 3);
  3253.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: MP4, Silenced 9mm, Moltove.");
  3254.                                 }
  3255.                                 default:
  3256.                                 {
  3257.                                     GivePlayerWeapon(playerid, 29, 300);
  3258.                                     GivePlayerWeapon(playerid, 23, 200);
  3259.                                     GivePlayerWeapon(playerid, 25, 200);
  3260.                                     GivePlayerWeapon(playerid, 18, 3);
  3261.                                     SendClientMessage(playerid, COLOR_CORAL, "- Weapons: MP4, Silenced 9mm, Shotgun, Moltove.");
  3262.                                 }
  3263.                             }
  3264.  
  3265.                             gDis[playerid] = 3;
  3266.                         }
  3267.                         case 6:
  3268.                         {
  3269.                             NotifyPlayer(playerid, "You have selected class ~g~Terminator", 5000);
  3270.                             SendClientMessage(playerid, COLOR_CORAL, "- Your class is "LIGHT_BLUE"Terminator");
  3271.                             GivePlayerWeapon(playerid, 38, 100);
  3272.                             GivePlayerWeapon(playerid, 24, 300);
  3273.                             GivePlayerWeapon(playerid, 9, 1);
  3274.                             GivePlayerWeapon(playerid, 18, 10);
  3275.                             SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Minigun, Desert Eagle, Chainsaw Moltoves.");
  3276.                         }
  3277.                     }
  3278.                 }
  3279.                 default:
  3280.                 {
  3281.                     NotifyPlayer(playerid, "~r~There is no classes for team AFRICA!", 5000);
  3282.  
  3283.                     switch(rank)
  3284.                     {
  3285.                         case 0..3:
  3286.                         {
  3287.                             GivePlayerWeapon(playerid, 30, 200);
  3288.                             GivePlayerWeapon(playerid, 24, 100);
  3289.                             GivePlayerWeapon(playerid, 4, 1);
  3290.                             SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Ak-47, Desert Eagle, Knife.");
  3291.                         }
  3292.                         case 4..7:
  3293.                         {
  3294.                             GivePlayerWeapon(playerid, 30, 500);
  3295.                             GivePlayerWeapon(playerid, 24, 300);
  3296.                             GivePlayerWeapon(playerid, 4, 1);
  3297.                             GivePlayerWeapon(playerid, 18, 5);
  3298.                             SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Ak-47, Desert Eagle, Knife, Moltove.");
  3299.                         }
  3300.                         default:
  3301.                         {
  3302.                             GivePlayerWeapon(playerid, 30, 500);
  3303.                             GivePlayerWeapon(playerid, 24, 300);
  3304.                             GivePlayerWeapon(playerid, 4, 1);
  3305.                             GivePlayerWeapon(playerid, 18, 5);
  3306.                             GivePlayerWeapon(playerid, 35, 1);
  3307.                             SendClientMessage(playerid, COLOR_CORAL, "- Weapons: Ak-47, Desert Eagle, Knife, Moltove, RPG.");
  3308.                         }
  3309.                     }
  3310.                 }
  3311.             }
  3312.  
  3313.             if(GetPlayerTeam(playerid) != 7) SendClientMessage(playerid, COLOR_WHITE, "Type /chelp to get info. about your class; Type /sc to switch class in next spawn.");
  3314.  
  3315.             //anti spawnkill system
  3316.             switch(rank)
  3317.             {
  3318.                 case 0: gAntiSpawnkill[playerid][A_HP] = 100.0, gAntiSpawnkill[playerid][A_AR] = 100.0;
  3319.                 case 1: gAntiSpawnkill[playerid][A_HP] = 75.0, gAntiSpawnkill[playerid][A_AR] = 0.0;
  3320.                 case 2: gAntiSpawnkill[playerid][A_HP] = 90.0, gAntiSpawnkill[playerid][A_AR] = 0.0;
  3321.                 case 3: gAntiSpawnkill[playerid][A_HP] = 100.0, gAntiSpawnkill[playerid][A_AR] = 0.0;
  3322.                 case 4..5: gAntiSpawnkill[playerid][A_HP] = 100.0, gAntiSpawnkill[playerid][A_AR] = 10.0;
  3323.                 case 6..7: gAntiSpawnkill[playerid][A_HP] = 100.0, gAntiSpawnkill[playerid][A_AR] = 25.0;
  3324.                 case 8..10: gAntiSpawnkill[playerid][A_HP] = 100.0, gAntiSpawnkill[playerid][A_AR] = 45.0;
  3325.                 case 11..13: gAntiSpawnkill[playerid][A_HP] = 100.0, gAntiSpawnkill[playerid][A_AR] = 60.0;
  3326.                 case 14..15: gAntiSpawnkill[playerid][A_HP] = 100.0, gAntiSpawnkill[playerid][A_AR] = 75.0;
  3327.                 default: gAntiSpawnkill[playerid][A_HP] = 100.0, gAntiSpawnkill[playerid][A_AR] = 100.0;
  3328.             }
  3329.             new string[144];
  3330.             format(string, sizeof(string), "* Your current rank is %s! Recieved a bonus of %0.2f% HEALTH and %0.2f% ARMOUR!", gRank[rank][r_name], gAntiSpawnkill[playerid][A_HP], gAntiSpawnkill[playerid][A_AR]);
  3331.             SendClientMessage(playerid, COLOR_YELLOW, string);
  3332.  
  3333.             SendClientMessage(playerid, COLOR_RED, "-> You have Anti - Spawnkill protection for 10 seconds !");
  3334.             gAntiSpawnkill[playerid][A_LABEL] = CreateDynamic3DTextLabel("Anti - Spawnkill protected", COLOR_RED, 0.0, 0.0, 0.3, 20.0, playerid, _, 1);
  3335.             gAntiSpawnkill[playerid][A_TIMER] = 10;
  3336.             SetPlayerHealth(playerid, FLOAT_INFINITY);
  3337.  
  3338.             //prestige weapons
  3339.             if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) > 2 || rank >= 10)
  3340.             {
  3341.                 new weaponid;
  3342.                 GAdmin_RetrieveUserData(ReturnPlayerName(playerid), "i", "weapon1", weaponid);
  3343.                 if(IsValidWeapon(weaponid) && weaponid != 0)
  3344.                 {
  3345.                     format(string, sizeof(string), "* You recieved a %s as your prestige weapon I!", ReturnWeaponName(weaponid));
  3346.                     SendClientMessage(playerid, COLOR_YELLOW, string);
  3347.  
  3348.                     GivePlayerWeapon(playerid, weaponid, 200);
  3349.                 }
  3350.             }
  3351.             if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) > 2 || rank >= 15)
  3352.             {
  3353.                 new weaponid;
  3354.                 GAdmin_RetrieveUserData(ReturnPlayerName(playerid), "i", "weapon2", weaponid);
  3355.                 if(IsValidWeapon(weaponid) && weaponid != 0)
  3356.                 {
  3357.                     format(string, sizeof(string), "* You recieved a %s as your prestige weapon II!", ReturnWeaponName(weaponid));
  3358.                     SendClientMessage(playerid, COLOR_YELLOW, string);
  3359.  
  3360.                     GivePlayerWeapon(playerid, weaponid, 200);
  3361.                 }
  3362.             }
  3363.             if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) > 2 || rank >= 20)
  3364.             {
  3365.                 new weaponid;
  3366.                 GAdmin_RetrieveUserData(ReturnPlayerName(playerid), "i", "weapon3", weaponid);
  3367.                 if(IsValidWeapon(weaponid) && weaponid != 0)
  3368.                 {
  3369.                     format(string, sizeof(string), "* You recieved a %s as your prestige weapon III!", ReturnWeaponName(weaponid));
  3370.                     SendClientMessage(playerid, COLOR_YELLOW, string);
  3371.  
  3372.                     GivePlayerWeapon(playerid, weaponid, 200);
  3373.                 }
  3374.             }
  3375.  
  3376.             TogglePlayerControllable(playerid, true);
  3377.             //
  3378.         }
  3379.         if(! response)
  3380.         {
  3381.             gClassSelection[playerid] = false;
  3382.             SpawnPlayer(playerid);
  3383.         }
  3384.     }
  3385.  
  3386.     if(dialogid == DIALOG_DIS)
  3387.     {
  3388.         if(response)
  3389.         {
  3390.             gDis[playerid] -= 1;
  3391.  
  3392.             SetPlayerSkin(playerid, gTeam[listitem][E_SKIN]);
  3393.             SetPlayerColor(playerid, gTeam[listitem][E_COLOR]);
  3394.  
  3395.             new string[145];
  3396.             format(string, sizeof(string), "You have disguized to team %s", gTeam[listitem][E_NAME]);
  3397.             NotifyPlayer(playerid, string, 5000);
  3398.         }
  3399.     }
  3400.  
  3401.     if(dialogid == DIALOG_DEATHMATCH)
  3402.     {
  3403.         if(response)
  3404.         {
  3405.             switch(listitem)
  3406.             {
  3407.                 case 0: cmd_minigun(playerid, "");
  3408.                 case 1: cmd_moneybag(playerid, "");
  3409.                 case 2: cmd_rpg(playerid, "");
  3410.                 case 3: cmd_glass(playerid, "");
  3411.             }
  3412.         }
  3413.     }
  3414.  
  3415.     if(dialogid == DIALOG_NUKE)
  3416.     {
  3417.         if(response)
  3418.         {
  3419.             new string[256];
  3420.             if(GetPlayerTeam(playerid) != gCaptureZone[NUKE_ZONE][E_ZONEOWNER])
  3421.             {
  3422.                 format(string, sizeof(string), "ERROR: You must capture %s before launching a Nuclear missle.", gCaptureZone[NUKE_ZONE][E_ZONENAME]);
  3423.                 return SendClientMessage(playerid, COLOR_FIREBRICK, string);
  3424.             }
  3425.  
  3426.             if(gNuke[NUKE_TIME] > 0)
  3427.             {
  3428.                 format(string, sizeof(string), "ERROR: You must wait %i seconds before launching a Nuke.", gNuke[NUKE_TIME]);
  3429.                 return SendClientMessage(playerid, COLOR_FIREBRICK, string);
  3430.             }
  3431.  
  3432.             if(GetPlayerTeam(playerid) == listitem)
  3433.             {
  3434.                 OnPlayerPickUpDynamicPickup(playerid, gNuke[NUKE_PICKUP]);
  3435.                 return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot nuke your own base!");
  3436.             }
  3437.  
  3438.             gNuke[NUKE_BASE] = listitem;
  3439.             format(string, sizeof(string), "Are you sure you want to launch Nuke?\nTarget base: "RED"%s\n"LIGHT_BLUE"The nuke will cost you "RED"$"#NUKE_COST"", gTeamBase[listitem][b_name]);
  3440.             ShowPlayerDialog(playerid, (DIALOG_NUKE + 1), DIALOG_STYLE_MSGBOX, "Confirmation for Nuke launch", string, "Launch", "Back");
  3441.         }
  3442.     }
  3443.  
  3444.     if(dialogid == (DIALOG_NUKE + 1))
  3445.     {
  3446.         if(! response) return OnPlayerPickUpDynamicPickup(playerid, gNuke[NUKE_PICKUP]);
  3447.         if(response)
  3448.         {
  3449.             new string[256];
  3450.             if(GetPlayerTeam(playerid) != gCaptureZone[NUKE_ZONE][E_ZONEOWNER])
  3451.             {
  3452.                 format(string, sizeof(string), "ERROR: You must capture %s before launching a Nuke.", gCaptureZone[NUKE_ZONE][E_ZONENAME]);
  3453.                 return SendClientMessage(playerid, COLOR_FIREBRICK, string);
  3454.             }
  3455.  
  3456.             if(gNuke[NUKE_TIME] > 0)
  3457.             {
  3458.                 format(string, sizeof(string), "ERROR: You must wait %i seconds before launching a Nuke.", gNuke[NUKE_TIME]);
  3459.                 return SendClientMessage(playerid, COLOR_FIREBRICK, string);
  3460.             }
  3461.  
  3462.             if(GetPlayerMoney(playerid) < NUKE_COST)
  3463.             {
  3464.                 return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to launch a Nuke.");
  3465.             }
  3466.  
  3467.             GivePlayerMoney(playerid, - NUKE_COST);
  3468.  
  3469.             format(string, sizeof(string), "A nuke has been launched in %s!", gTeamBase[gNuke[NUKE_BASE]][b_name]);
  3470.             SendClientMessageToAll(COLOR_LIME_GREEN, string);
  3471.  
  3472.             SetTimerEx("OnPlayerLaunchNuke", (5 * 1000), false, "ii", playerid, gNuke[NUKE_BASE]);
  3473.             gNuke[NUKE_TIME] = NUKE_INTERVAL;
  3474.         }
  3475.     }
  3476.  
  3477.     if(dialogid == DIALOG_ANTHRAX)
  3478.     {
  3479.         if(response)
  3480.         {
  3481.             new string[56];
  3482.             if(GetPlayerTeam(playerid) != gCaptureZone[ANTHRAX_ZONE][E_ZONEOWNER])
  3483.             {
  3484.                 format(string, sizeof(string), "ERROR: You must capture %s before launching a Anthrax bomb.", gCaptureZone[ANTHRAX_ZONE][E_ZONENAME]);
  3485.                 return SendClientMessage(playerid, COLOR_FIREBRICK, string);
  3486.             }
  3487.  
  3488.             if(gAnthrax[ANTHRAX_TIME] > 0)
  3489.             {
  3490.                 format(string, sizeof(string), "ERROR: You must wait %i seconds before launching an Anthrax bomb.", gAnthrax[ANTHRAX_TIME]);
  3491.                 return SendClientMessage(playerid, COLOR_FIREBRICK, string);
  3492.             }
  3493.  
  3494.             if(GetPlayerMoney(playerid) < ANTHRAX_COST)
  3495.             {
  3496.                 return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to launch a Anthrax.");
  3497.             }
  3498.  
  3499.             GivePlayerMoney(playerid, - ANTHRAX_COST);
  3500.  
  3501.             SendClientMessageToAll(COLOR_LIME_GREEN, "An Anthrax bomb has been launched");
  3502.  
  3503.             SetTimerEx("OnPlayerLaunchAnthrax", (5 * 1000), false, "i", playerid);
  3504.             gAnthrax[ANTHRAX_TIME] = ANTHRAX_INTERVAL;
  3505.         }
  3506.     }
  3507.  
  3508.     if(dialogid == DIALOG_SHOP)
  3509.     {
  3510.         if(response)
  3511.         {
  3512.             switch(listitem)
  3513.             {
  3514.                 case 0:
  3515.                 {
  3516.                     new Float:hp;
  3517.                     GetPlayerHealth(playerid, hp);
  3518.  
  3519.                     if(hp >= 100.0) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You already have full health(100%).");
  3520.                     else if(GetPlayerMoney(playerid) < 2000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3521.                     else
  3522.                     {
  3523.                         GivePlayerMoney(playerid, -2000);
  3524.                         SetPlayerHealth(playerid, 100.0);
  3525.                         SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought full health(100%) for $2000.");
  3526.                     }
  3527.                     ShowPlayerShopDialog(playerid);
  3528.                 }
  3529.                 case 1:
  3530.                 {
  3531.                     new Float:ar;
  3532.                     GetPlayerArmour(playerid, ar);
  3533.  
  3534.                     if(ar >= 100.0) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You already have full armour(100%).");
  3535.                     else if(GetPlayerMoney(playerid) < 2000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3536.                     else
  3537.                     {
  3538.                         GivePlayerMoney(playerid, -2000);
  3539.                         SetPlayerArmour(playerid, 100.0);
  3540.                         SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought full armour(100%) for $2000.");
  3541.                     }
  3542.                     ShowPlayerShopDialog(playerid);
  3543.                 }
  3544.                 case 2:
  3545.                 {
  3546.                     SetupPrevModelDialog(0.0, 0.0, 0.0, 3.0);
  3547.                     ShowPlayerDialog(playerid, (DIALOG_SHOP + 1), DIALOG_STYLE_PREVMODEL, "Weapons List", weapons, "Select", "Back");
  3548.                 }
  3549.                 case 3:
  3550.                 {
  3551.                     SetupPrevModelDialog(0.0, 0.0, 0.0, 2.0);
  3552.                     ShowPlayerDialog(playerid, (DIALOG_SHOP + 2), DIALOG_STYLE_PREVMODEL, "Misc. Items", miscitems, "Select", "Back");
  3553.                 }
  3554.                 case 4:
  3555.                 {
  3556.                     ShowPlayerDialog(playerid, (DIALOG_SHOP + 3), DIALOG_STYLE_TABLIST_HEADERS, "Inventory", "Item\tPrice\nPainkiller\t$1000\nArmour Jacket\t$3500\nProtection Helmet\t$7000\nGas Mask\t$5500\nSucide Bomb\t$10000", "Buy", "Back");
  3557.                 }
  3558.             }
  3559.         }
  3560.     }
  3561.  
  3562.     if(dialogid == (DIALOG_SHOP + 1))
  3563.     {
  3564.         if(! response) return ShowPlayerShopDialog(playerid);
  3565.         if(response)
  3566.         {
  3567.             switch(listitem)
  3568.             {
  3569.                 case 0: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Knife?", "Ammo\tPrice\n1\t$1000", "Buy", "Back");
  3570.                 case 1: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Katana?", "Ammo\tPrice\n1\t$740", "Buy", "Back");
  3571.                 case 2: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Chainsaw?", "Ammo\tPrice\n1\t$2100", "Buy", "Back");
  3572.                 case 3: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Grenade?", "Ammo\tPrice\n1\t$1500\n2\t$3000\n5\t$7000", "Buy", "Back");
  3573.                 case 4: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Teargas?", "Ammo\tPrice\n1\t$1000\n2\t$2000\n5\t$4500", "Buy", "Back");
  3574.                 case 5: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Moltove?", "Ammo\tPrice\n1\t$1500\n2\t$3000\n5\t$7000", "Buy", "Back");
  3575.                 case 6: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a 9mm?", "Ammo\tPrice\n1\t$20\n50\t$1000\n100\t$2000\n200\t$3800\n500\t$7500", "Buy", "Back");
  3576.                 case 7: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Silenced 9mm?", "Ammo\tPrice\n1\t$10\n50\t$500\n100\t$1000\n200\t$2000\n500\t$5000", "Buy", "Back");
  3577.                 case 8: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Desert Eagle?", "Ammo\tPrice\n1\t$50\n50\t$2500\n100\t$5000\n200\t$9000\n500\t$18000", "Buy", "Back");
  3578.                 case 9: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Shotgun?", "Ammo\tPrice\n1\t$30\n50\t$1500\n100\t$3000\n200\t$5000\n500\t$13000", "Buy", "Back");
  3579.                 case 10: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Sawnoff Shotgun?", "Ammo\tPrice\n1\t$60\n50\t$3000\n100\t$6000\n200\t$10000\n500\t$25000", "Buy", "Back");
  3580.                 case 11: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Combat Shotgun?", "Ammo\tPrice\n1\t$50\n50\t$2500\n100\t$5000\n200\t$9000\n500\t$18000", "Buy", "Back");
  3581.                 case 12: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a UZI?", "Ammo\tPrice\n1\t$30\n50\t$1500\n100\t$3000\n200\t$5000\n500\t$13000", "Buy", "Back");
  3582.                 case 13: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a MP5?", "Ammo\tPrice\n1\t$30\n50\t$1500\n100\t$3000\n200\t$5000\n500\t$13000", "Buy", "Back");
  3583.                 case 14: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Ak-47?", "Ammo\tPrice\n1\t$30\n50\t$1500\n100\t$3000\n200\t$5000\n500\t$13000", "Buy", "Back");
  3584.                 case 15: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a M4?", "Ammo\tPrice\n1\t$30\n50\t$1500\n100\t$3000\n200\t$5000\n500\t$13000", "Buy", "Back");
  3585.                 case 16: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Tec-9?", "Ammo\tPrice\n1\t$35\n50\t$1750\n100\t$3500\n200\t$6000\n500\t$14000", "Buy", "Back");
  3586.                 case 17: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Rifle?", "Ammo\tPrice\n1\t$30\n50\t$1500\n100\t$3000\n200\t$5000\n500\t$13000", "Buy", "Back");
  3587.                 case 18: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Sniper Rifle?", "Ammo\tPrice\n1\t$60\n50\t$3000\n100\t$6000\n200\t$10000\n500\t$17000", "Buy", "Back");
  3588.                 case 19: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a RPG?", "Ammo\tPrice\n1\t$1500\n2\t$3000\n5\t$7000", "Buy", "Back");
  3589.                 case 20: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a H.S. Rockets?", "Ammo\tPrice\n1\t$1800\n2\t$3600\n5\t$8000", "Buy", "Back");
  3590.                 case 21: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Flamethrower?", "Ammo\tPrice\n100\t$1500\n200\t$3000\n500\t$7000", "Buy", "Back");
  3591.                 case 22: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Satchels?", "Ammo\tPrice\n1\t$1500\n2\t$3000\n5\t$7000", "Buy", "Back");
  3592.             }
  3593.             gListitem[playerid] = listitem;
  3594.         }
  3595.     }
  3596.  
  3597.     if(dialogid == (DIALOG_SHOP + 2))
  3598.     {
  3599.         if(! response) return ShowPlayerShopDialog(playerid);
  3600.         if(response)
  3601.         {
  3602.             switch(listitem)
  3603.             {
  3604.                 case 0: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Spray Can?", "Ammo\tPrice\n50\t$450", "Buy", "Back");
  3605.                 case 1: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Fire Estinguisher?", "Ammo\tPrice\n50\t$500\n100\t$1000\n500\t$5000", "Buy", "Back");
  3606.                 case 2: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Camera?", "Ammo\tPrice\n50\t$50", "Buy", "Back");
  3607.                 case 3: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Night Vision Goggles?", "Ammo\tPrice\n1\t$500", "Buy", "Back");
  3608.                 case 4: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Thremal Vision Goggles?", "Ammo\tPrice\n1\t$500", "Buy", "Back");
  3609.                 case 5: ShowPlayerDialog(playerid, (DIALOG_SHOP + 4), DIALOG_STYLE_TABLIST_HEADERS, "Do you want to buy a Parachute?", "Ammo\tPrice\n1\t$1 "RED"!", "Buy", "Back");
  3610.             }
  3611.             gListitem[playerid] = listitem + 100;
  3612.         }
  3613.     }
  3614.  
  3615.     if(dialogid == (DIALOG_SHOP + 3))
  3616.     {
  3617.         if(! response) return ShowPlayerShopDialog(playerid);
  3618.         if(response)
  3619.         {
  3620.             switch(listitem)
  3621.             {
  3622.                 case 0:
  3623.                 {
  3624.                     if(gPainkillers[playerid] >= 5) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't carry more than 5 painkillers in your bag.");
  3625.                     else if(GetPlayerMoney(playerid) < 1000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3626.                     else
  3627.                     {
  3628.                         GivePlayerMoney(playerid, - 1000);
  3629.                         gPainkillers[playerid] += 1;
  3630.                         SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Painkiller for $1000.");
  3631.                         SendClientMessage(playerid, COLOR_KHAKI, "TIP: Type /pk to regenrate health!");
  3632.                     }
  3633.                 }
  3634.                 case 1:
  3635.                 {
  3636.                     if(gArmour[playerid]) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't carry more than 1 armour in your bag.");
  3637.                     else if(GetPlayerMoney(playerid) < 3500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3638.                     else
  3639.                     {
  3640.                         GivePlayerMoney(playerid, - 3500);
  3641.                         gArmour[playerid] = true;
  3642.                         SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought an Armour Jacket for $3500.");
  3643.                         SendClientMessage(playerid, COLOR_KHAKI, "TIP: Type /armour to wear your Armour Jacket!");
  3644.                     }
  3645.                 }
  3646.                 case 2:
  3647.                 {
  3648.                     if(gHelmet[playerid]) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You already have a Protection helmet.");
  3649.                     else if(GetPlayerMoney(playerid) < 7000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3650.                     else
  3651.                     {
  3652.                         GivePlayerMoney(playerid, -7000);
  3653.                         gHelmet[playerid] = true;
  3654.                         switch(GetPlayerSkin(playerid))
  3655.                         {
  3656.                             case 24: SetPlayerAttachedObject(playerid,2,18638,2,0.151999,0.038000,0.000000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 24
  3657.                             case 287: SetPlayerAttachedObject(playerid,2,18638,2,0.128000,0.049999,0.006000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 287
  3658.                             case 285: SetPlayerAttachedObject(playerid,2,18638,2,0.182000,0.035000,0.007000,0.000000,0.000000,0.000000,1.000000,1.069999,1.118999); //skin 285
  3659.                             case 111: SetPlayerAttachedObject(playerid,2,18638,2,0.159999,0.032999,0.000000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 111
  3660.                             case 122: SetPlayerAttachedObject(playerid,2,18638,2,0.148000,0.017000,-0.002999,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 122
  3661.                             case 73: SetPlayerAttachedObject(playerid,2,18638,2,0.148999,0.038999,0.000000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 73
  3662.                             case 46: SetPlayerAttachedObject(playerid,2,18638,2,0.162999,0.035000,0.001000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 46
  3663.                             case 102: SetPlayerAttachedObject(playerid,2,18638,2,0.173000,0.024999,-0.003000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 102
  3664.                             default: SetPlayerAttachedObject(playerid,2,18638,2,0.173000,0.024999,-0.003000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 102
  3665.                         }
  3666.                         SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Protection Helmet for $7000.");
  3667.                     }
  3668.                 }
  3669.                 case 3:
  3670.                 {
  3671.                     if(gMask[playerid]) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You already have a Anti-Teargas Mask.");
  3672.                     else if(GetPlayerMoney(playerid) < 5500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3673.                     else
  3674.                     {
  3675.                         GivePlayerMoney(playerid, -5500);
  3676.                         gMask[playerid] = true;
  3677.                         SetPlayerAttachedObject(playerid, 3, 19472, 2, -0.022000, 0.137000, 0.018999, 3.899994, 85.999961, 92.999984, 0.923999, 1.141000, 1.026999);
  3678.                         SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Anti-Teargas Mask for $5500.");
  3679.                     }
  3680.                 }
  3681.                 case 4:
  3682.                 {
  3683.                     if(gBomb[playerid]) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You already have a Sucide Bomb.");
  3684.                     else if(GetPlayerMoney(playerid) < 10000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3685.                     else
  3686.                     {
  3687.                         GivePlayerMoney(playerid, -10000);
  3688.                         gBomb[playerid] = true;
  3689.                         SetPlayerAttachedObject(playerid, 4, 1654, 1, 0.046000, 0.229000, -0.013000, 3.099998, 78.299972, -178.599960, 1.000000, 1.000000, 1.000000);
  3690.                         SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Sucide Bomb for $10000.");
  3691.                     }
  3692.                 }
  3693.             }
  3694.             ShowPlayerDialog(playerid, (DIALOG_SHOP + 3), DIALOG_STYLE_TABLIST_HEADERS, "Inventory", "Item\tPrice\nPainkiller\t$1000\nArmour Jacket\t$3500\nProtection Helmet\t$7000\nGas Mask\t$5500\nSucide Bomb\t$10000", "Buy", "Back");
  3695.         }
  3696.     }
  3697.  
  3698.     if(dialogid == (DIALOG_SHOP + 4))
  3699.     {
  3700.         if(response)
  3701.         {
  3702.             switch(gListitem[playerid])
  3703.             {
  3704.                 case 0://knife
  3705.                 {
  3706.                     switch(listitem)
  3707.                     {
  3708.                         case 0:
  3709.                         {
  3710.                             if(IsPlayerHavingWeapon(playerid, 4)) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You already have a Knife.");
  3711.                             else if(GetPlayerMoney(playerid) < 1000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3712.                             else
  3713.                             {
  3714.                                 GivePlayerMoney(playerid, - 1000);
  3715.                                 GivePlayerWeapon(playerid, 4, 1);
  3716.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Knife for $1000.");
  3717.                             }
  3718.                         }
  3719.                     }
  3720.                 }
  3721.                 case 1://katana
  3722.                 {
  3723.                     switch(listitem)
  3724.                     {
  3725.                         case 0:
  3726.                         {
  3727.                             if(IsPlayerHavingWeapon(playerid, 4)) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You already have a Katana.");
  3728.                             else if(GetPlayerMoney(playerid) < 740) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3729.                             else
  3730.                             {
  3731.                                 GivePlayerMoney(playerid, - 740);
  3732.                                 GivePlayerWeapon(playerid, 8, 1);
  3733.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Katana for $740.");
  3734.                             }
  3735.                         }
  3736.                     }
  3737.                 }
  3738.                 case 2://chainsaw
  3739.                 {
  3740.                     switch(listitem)
  3741.                     {
  3742.                         case 0:
  3743.                         {
  3744.                             if(IsPlayerHavingWeapon(playerid, 4)) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You already have a Chainsaw.");
  3745.                             else if(GetPlayerMoney(playerid) < 2100) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3746.                             else
  3747.                             {
  3748.                                 GivePlayerMoney(playerid, - 2100);
  3749.                                 GivePlayerWeapon(playerid, 9, 1);
  3750.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Chainsaw for $2100.");
  3751.                             }
  3752.                         }
  3753.                     }
  3754.                 }
  3755.                 case 3://grenade
  3756.                 {
  3757.                     switch(listitem)
  3758.                     {
  3759.                         case 0:
  3760.                         {
  3761.                             if(GetPlayerMoney(playerid) < 1500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3762.                             else
  3763.                             {
  3764.                                 GivePlayerMoney(playerid, - 1500);
  3765.                                 GivePlayerWeapon(playerid, 16, 1);
  3766.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Grenade for $1500.");
  3767.                             }
  3768.                         }
  3769.                         case 1:
  3770.                         {
  3771.                             if(GetPlayerMoney(playerid) < 3000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3772.                             else
  3773.                             {
  3774.                                 GivePlayerMoney(playerid, - 3000);
  3775.                                 GivePlayerWeapon(playerid, 16, 2);
  3776.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought 2 Grenade for $3000.");
  3777.                             }
  3778.                         }
  3779.                         case 2:
  3780.                         {
  3781.                             if(GetPlayerMoney(playerid) < 7000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3782.                             else
  3783.                             {
  3784.                                 GivePlayerMoney(playerid, - 7000);
  3785.                                 GivePlayerWeapon(playerid, 16, 5);
  3786.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought 5 Grenade for $7000.");
  3787.                             }
  3788.                         }
  3789.                     }
  3790.                 }
  3791.                 case 4://teargas
  3792.                 {
  3793.                     switch(listitem)
  3794.                     {
  3795.                         case 0:
  3796.                         {
  3797.                             if(GetPlayerMoney(playerid) < 1000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3798.                             else
  3799.                             {
  3800.                                 GivePlayerMoney(playerid, - 1000);
  3801.                                 GivePlayerWeapon(playerid, 17, 1);
  3802.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Teargas for $1000.");
  3803.                             }
  3804.                         }
  3805.                         case 1:
  3806.                         {
  3807.                             if(GetPlayerMoney(playerid) < 2000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3808.                             else
  3809.                             {
  3810.                                 GivePlayerMoney(playerid, - 2000);
  3811.                                 GivePlayerWeapon(playerid, 17, 2);
  3812.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought 2 Teargas for $2000.");
  3813.                             }
  3814.                         }
  3815.                         case 2:
  3816.                         {
  3817.                             if(GetPlayerMoney(playerid) < 4500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3818.                             else
  3819.                             {
  3820.                                 GivePlayerMoney(playerid, - 4500);
  3821.                                 GivePlayerWeapon(playerid, 17, 5);
  3822.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought 5 Teargas for $4500.");
  3823.                             }
  3824.                         }
  3825.                     }
  3826.                 }
  3827.                 case 5://molotve
  3828.                 {
  3829.                     switch(listitem)
  3830.                     {
  3831.                         case 0:
  3832.                         {
  3833.                             if(GetPlayerMoney(playerid) < 1500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3834.                             else
  3835.                             {
  3836.                                 GivePlayerMoney(playerid, - 1500);
  3837.                                 GivePlayerWeapon(playerid, 18, 1);
  3838.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Moltove for $1500.");
  3839.                             }
  3840.                         }
  3841.                         case 1:
  3842.                         {
  3843.                             if(GetPlayerMoney(playerid) < 3000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3844.                             else
  3845.                             {
  3846.                                 GivePlayerMoney(playerid, - 3000);
  3847.                                 GivePlayerWeapon(playerid, 18, 2);
  3848.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought 2 Moltove for $3000.");
  3849.                             }
  3850.                         }
  3851.                         case 2:
  3852.                         {
  3853.                             if(GetPlayerMoney(playerid) < 7000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3854.                             else
  3855.                             {
  3856.                                 GivePlayerMoney(playerid, - 7000);
  3857.                                 GivePlayerWeapon(playerid, 18, 5);
  3858.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought 5 Moltove for $7000.");
  3859.                             }
  3860.                         }
  3861.                     }
  3862.                 }
  3863.                 case 6://9mm
  3864.                 {
  3865.                     switch(listitem)
  3866.                     {
  3867.                         case 0:
  3868.                         {
  3869.                             if(GetPlayerMoney(playerid) < 20) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3870.                             else
  3871.                             {
  3872.                                 GivePlayerMoney(playerid, - 20);
  3873.                                 GivePlayerWeapon(playerid, 22, 1);
  3874.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a 9mm (1 Ammo) for $20.");
  3875.                             }
  3876.                         }
  3877.                         case 1:
  3878.                         {
  3879.                             if(GetPlayerMoney(playerid) < 1000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3880.                             else
  3881.                             {
  3882.                                 GivePlayerMoney(playerid, - 1000);
  3883.                                 GivePlayerWeapon(playerid, 22, 50);
  3884.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a 9mm (50 Ammo) for $1000.");
  3885.                             }
  3886.                         }
  3887.                         case 2:
  3888.                         {
  3889.                             if(GetPlayerMoney(playerid) < 2000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3890.                             else
  3891.                             {
  3892.                                 GivePlayerMoney(playerid, - 2000);
  3893.                                 GivePlayerWeapon(playerid, 22, 100);
  3894.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a 9mm (100 Ammo) for $2000.");
  3895.                             }
  3896.                         }
  3897.                         case 3:
  3898.                         {
  3899.                             if(GetPlayerMoney(playerid) < 3800) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3900.                             else
  3901.                             {
  3902.                                 GivePlayerMoney(playerid, - 3800);
  3903.                                 GivePlayerWeapon(playerid, 22, 200);
  3904.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a 9mm (200 Ammo) for $3800.");
  3905.                             }
  3906.                         }
  3907.                         case 4:
  3908.                         {
  3909.                             if(GetPlayerMoney(playerid) < 7500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3910.                             else
  3911.                             {
  3912.                                 GivePlayerMoney(playerid, - 7500);
  3913.                                 GivePlayerWeapon(playerid, 22, 500);
  3914.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a 9mm (500 Ammo) for $7500.");
  3915.                             }
  3916.                         }
  3917.                     }
  3918.                 }
  3919.                 case 7://Silenced 9mm
  3920.                 {
  3921.                     switch(listitem)
  3922.                     {
  3923.                         case 0:
  3924.                         {
  3925.                             if(GetPlayerMoney(playerid) < 10) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3926.                             else
  3927.                             {
  3928.                                 GivePlayerMoney(playerid, - 10);
  3929.                                 GivePlayerWeapon(playerid, 23, 1);
  3930.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Silenced 9mm (1 Ammo) for $10.");
  3931.                             }
  3932.                         }
  3933.                         case 1:
  3934.                         {
  3935.                             if(GetPlayerMoney(playerid) < 500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3936.                             else
  3937.                             {
  3938.                                 GivePlayerMoney(playerid, - 500);
  3939.                                 GivePlayerWeapon(playerid, 23, 50);
  3940.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Silenced 9mm (50 Ammo) for $500.");
  3941.                             }
  3942.                         }
  3943.                         case 2:
  3944.                         {
  3945.                             if(GetPlayerMoney(playerid) < 1000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3946.                             else
  3947.                             {
  3948.                                 GivePlayerMoney(playerid, - 1000);
  3949.                                 GivePlayerWeapon(playerid, 23, 100);
  3950.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Silenced 9mm (100 Ammo) for $1000.");
  3951.                             }
  3952.                         }
  3953.                         case 3:
  3954.                         {
  3955.                             if(GetPlayerMoney(playerid) < 2000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3956.                             else
  3957.                             {
  3958.                                 GivePlayerMoney(playerid, - 2000);
  3959.                                 GivePlayerWeapon(playerid, 23, 200);
  3960.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Silenced 9mm (200 Ammo) for $2000.");
  3961.                             }
  3962.                         }
  3963.                         case 4:
  3964.                         {
  3965.                             if(GetPlayerMoney(playerid) < 5000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3966.                             else
  3967.                             {
  3968.                                 GivePlayerMoney(playerid, - 7500);
  3969.                                 GivePlayerWeapon(playerid, 23, 500);
  3970.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Silenced 9mm (500 Ammo) for $5000.");
  3971.                             }
  3972.                         }
  3973.                     }
  3974.                 }
  3975.                 case 8://deagle
  3976.                 {
  3977.                     switch(listitem)
  3978.                     {
  3979.                         case 0:
  3980.                         {
  3981.                             if(GetPlayerMoney(playerid) < 50) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3982.                             else
  3983.                             {
  3984.                                 GivePlayerMoney(playerid, - 50);
  3985.                                 GivePlayerWeapon(playerid, 24, 1);
  3986.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Desert Eagle (1 Ammo) for $50.");
  3987.                             }
  3988.                         }
  3989.                         case 1:
  3990.                         {
  3991.                             if(GetPlayerMoney(playerid) < 2500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  3992.                             else
  3993.                             {
  3994.                                 GivePlayerMoney(playerid, - 2500);
  3995.                                 GivePlayerWeapon(playerid, 24, 50);
  3996.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Desert Eagle (50 Ammo) for $2500.");
  3997.                             }
  3998.                         }
  3999.                         case 2:
  4000.                         {
  4001.                             if(GetPlayerMoney(playerid) < 5000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4002.                             else
  4003.                             {
  4004.                                 GivePlayerMoney(playerid, - 5000);
  4005.                                 GivePlayerWeapon(playerid, 24, 100);
  4006.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Desert Eagle (100 Ammo) for $5000.");
  4007.                             }
  4008.                         }
  4009.                         case 3:
  4010.                         {
  4011.                             if(GetPlayerMoney(playerid) < 9000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4012.                             else
  4013.                             {
  4014.                                 GivePlayerMoney(playerid, - 9000);
  4015.                                 GivePlayerWeapon(playerid, 24, 200);
  4016.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Desert Eagle (200 Ammo) for $9000.");
  4017.                             }
  4018.                         }
  4019.                         case 4:
  4020.                         {
  4021.                             if(GetPlayerMoney(playerid) < 18000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4022.                             else
  4023.                             {
  4024.                                 GivePlayerMoney(playerid, - 18000);
  4025.                                 GivePlayerWeapon(playerid, 24, 500);
  4026.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Desert Eagle (500 Ammo) for $18000.");
  4027.                             }
  4028.                         }
  4029.                     }
  4030.                 }
  4031.                 case 9://shotgun
  4032.                 {
  4033.                     switch(listitem)
  4034.                     {
  4035.                         case 0:
  4036.                         {
  4037.                             if(GetPlayerMoney(playerid) < 30) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4038.                             else
  4039.                             {
  4040.                                 GivePlayerMoney(playerid, - 30);
  4041.                                 GivePlayerWeapon(playerid, 25, 1);
  4042.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Shotgun (1 Ammo) for $30.");
  4043.                             }
  4044.                         }
  4045.                         case 1:
  4046.                         {
  4047.                             if(GetPlayerMoney(playerid) < 1500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4048.                             else
  4049.                             {
  4050.                                 GivePlayerMoney(playerid, - 1500);
  4051.                                 GivePlayerWeapon(playerid, 25, 50);
  4052.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Shotgun (50 Ammo) for $1500.");
  4053.                             }
  4054.                         }
  4055.                         case 2:
  4056.                         {
  4057.                             if(GetPlayerMoney(playerid) < 3000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4058.                             else
  4059.                             {
  4060.                                 GivePlayerMoney(playerid, - 3000);
  4061.                                 GivePlayerWeapon(playerid, 25, 100);
  4062.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Shotgun (100 Ammo) for $3000.");
  4063.                             }
  4064.                         }
  4065.                         case 3:
  4066.                         {
  4067.                             if(GetPlayerMoney(playerid) < 5000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4068.                             else
  4069.                             {
  4070.                                 GivePlayerMoney(playerid, - 5000);
  4071.                                 GivePlayerWeapon(playerid, 25, 200);
  4072.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Shotgun (200 Ammo) for $5000.");
  4073.                             }
  4074.                         }
  4075.                         case 4:
  4076.                         {
  4077.                             if(GetPlayerMoney(playerid) < 13000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4078.                             else
  4079.                             {
  4080.                                 GivePlayerMoney(playerid, - 13000);
  4081.                                 GivePlayerWeapon(playerid, 25, 500);
  4082.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Shotgun (500 Ammo) for $13000.");
  4083.                             }
  4084.                         }
  4085.                     }
  4086.                 }
  4087.                 case 10://sawnoff shotgun
  4088.                 {
  4089.                     switch(listitem)
  4090.                     {
  4091.                         case 0:
  4092.                         {
  4093.                             if(GetPlayerMoney(playerid) < 60) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4094.                             else
  4095.                             {
  4096.                                 GivePlayerMoney(playerid, - 60);
  4097.                                 GivePlayerWeapon(playerid, 26, 1);
  4098.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Sawnoff Shotgun (1 Ammo) for $60.");
  4099.                             }
  4100.                         }
  4101.                         case 1:
  4102.                         {
  4103.                             if(GetPlayerMoney(playerid) < 3000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4104.                             else
  4105.                             {
  4106.                                 GivePlayerMoney(playerid, - 3000);
  4107.                                 GivePlayerWeapon(playerid, 26, 50);
  4108.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Sawnoff Shotgun (50 Ammo) for $3000.");
  4109.                             }
  4110.                         }
  4111.                         case 2:
  4112.                         {
  4113.                             if(GetPlayerMoney(playerid) < 6000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4114.                             else
  4115.                             {
  4116.                                 GivePlayerMoney(playerid, - 6000);
  4117.                                 GivePlayerWeapon(playerid, 26, 100);
  4118.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Sawnoff Shotgun (100 Ammo) for $6000.");
  4119.                             }
  4120.                         }
  4121.                         case 3:
  4122.                         {
  4123.                             if(GetPlayerMoney(playerid) < 10000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4124.                             else
  4125.                             {
  4126.                                 GivePlayerMoney(playerid, - 10000);
  4127.                                 GivePlayerWeapon(playerid, 26, 200);
  4128.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Sawnoff Shotgun (200 Ammo) for $10000.");
  4129.                             }
  4130.                         }
  4131.                         case 4:
  4132.                         {
  4133.                             if(GetPlayerMoney(playerid) < 25000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4134.                             else
  4135.                             {
  4136.                                 GivePlayerMoney(playerid, - 25000);
  4137.                                 GivePlayerWeapon(playerid, 26, 500);
  4138.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Sawnoff Shotgun (500 Ammo) for $25000.");
  4139.                             }
  4140.                         }
  4141.                     }
  4142.                 }
  4143.                 case 11://combat shotgun
  4144.                 {
  4145.                     switch(listitem)
  4146.                     {
  4147.                         case 0:
  4148.                         {
  4149.                             if(GetPlayerMoney(playerid) < 50) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4150.                             else
  4151.                             {
  4152.                                 GivePlayerMoney(playerid, - 50);
  4153.                                 GivePlayerWeapon(playerid, 27, 1);
  4154.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Combat Shotgun (1 Ammo) for $50.");
  4155.                             }
  4156.                         }
  4157.                         case 1:
  4158.                         {
  4159.                             if(GetPlayerMoney(playerid) < 2500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4160.                             else
  4161.                             {
  4162.                                 GivePlayerMoney(playerid, - 2500);
  4163.                                 GivePlayerWeapon(playerid, 27, 50);
  4164.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Combat Shotgun (50 Ammo) for $2500.");
  4165.                             }
  4166.                         }
  4167.                         case 2:
  4168.                         {
  4169.                             if(GetPlayerMoney(playerid) < 5000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4170.                             else
  4171.                             {
  4172.                                 GivePlayerMoney(playerid, - 5000);
  4173.                                 GivePlayerWeapon(playerid, 27, 100);
  4174.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Combat Shotgun (100 Ammo) for $5000.");
  4175.                             }
  4176.                         }
  4177.                         case 3:
  4178.                         {
  4179.                             if(GetPlayerMoney(playerid) < 9000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4180.                             else
  4181.                             {
  4182.                                 GivePlayerMoney(playerid, - 9000);
  4183.                                 GivePlayerWeapon(playerid, 27, 200);
  4184.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Combat Shotgun (200 Ammo) for $9000.");
  4185.                             }
  4186.                         }
  4187.                         case 4:
  4188.                         {
  4189.                             if(GetPlayerMoney(playerid) < 18000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4190.                             else
  4191.                             {
  4192.                                 GivePlayerMoney(playerid, - 18000);
  4193.                                 GivePlayerWeapon(playerid, 27, 500);
  4194.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Combat Shotgun (500 Ammo) for $18000.");
  4195.                             }
  4196.                         }
  4197.                     }
  4198.                 }
  4199.                 case 12://UZI
  4200.                 {
  4201.                     switch(listitem)
  4202.                     {
  4203.                         case 0:
  4204.                         {
  4205.                             if(GetPlayerMoney(playerid) < 30) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4206.                             else
  4207.                             {
  4208.                                 GivePlayerMoney(playerid, - 30);
  4209.                                 GivePlayerWeapon(playerid, 28, 1);
  4210.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a UZI (1 Ammo) for $30.");
  4211.                             }
  4212.                         }
  4213.                         case 1:
  4214.                         {
  4215.                             if(GetPlayerMoney(playerid) < 1500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4216.                             else
  4217.                             {
  4218.                                 GivePlayerMoney(playerid, - 1500);
  4219.                                 GivePlayerWeapon(playerid, 28, 50);
  4220.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a UZI (50 Ammo) for $1500.");
  4221.                             }
  4222.                         }
  4223.                         case 2:
  4224.                         {
  4225.                             if(GetPlayerMoney(playerid) < 3000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4226.                             else
  4227.                             {
  4228.                                 GivePlayerMoney(playerid, - 3000);
  4229.                                 GivePlayerWeapon(playerid, 28, 100);
  4230.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a UZI (100 Ammo) for $3000.");
  4231.                             }
  4232.                         }
  4233.                         case 3:
  4234.                         {
  4235.                             if(GetPlayerMoney(playerid) < 5000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4236.                             else
  4237.                             {
  4238.                                 GivePlayerMoney(playerid, - 5000);
  4239.                                 GivePlayerWeapon(playerid, 28, 200);
  4240.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a UZI (200 Ammo) for $5000.");
  4241.                             }
  4242.                         }
  4243.                         case 4:
  4244.                         {
  4245.                             if(GetPlayerMoney(playerid) < 13000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4246.                             else
  4247.                             {
  4248.                                 GivePlayerMoney(playerid, - 13000);
  4249.                                 GivePlayerWeapon(playerid, 28, 500);
  4250.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a UZI (500 Ammo) for $13000.");
  4251.                             }
  4252.                         }
  4253.                     }
  4254.                 }
  4255.                 case 13://MP5
  4256.                 {
  4257.                     switch(listitem)
  4258.                     {
  4259.                         case 0:
  4260.                         {
  4261.                             if(GetPlayerMoney(playerid) < 30) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4262.                             else
  4263.                             {
  4264.                                 GivePlayerMoney(playerid, - 30);
  4265.                                 GivePlayerWeapon(playerid, 29, 1);
  4266.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a MP5 (1 Ammo) for $30.");
  4267.                             }
  4268.                         }
  4269.                         case 1:
  4270.                         {
  4271.                             if(GetPlayerMoney(playerid) < 1500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4272.                             else
  4273.                             {
  4274.                                 GivePlayerMoney(playerid, - 1500);
  4275.                                 GivePlayerWeapon(playerid, 29, 50);
  4276.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a MP5 (50 Ammo) for $1500.");
  4277.                             }
  4278.                         }
  4279.                         case 2:
  4280.                         {
  4281.                             if(GetPlayerMoney(playerid) < 3000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4282.                             else
  4283.                             {
  4284.                                 GivePlayerMoney(playerid, - 3000);
  4285.                                 GivePlayerWeapon(playerid, 29, 100);
  4286.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a MP5 (100 Ammo) for $3000.");
  4287.                             }
  4288.                         }
  4289.                         case 3:
  4290.                         {
  4291.                             if(GetPlayerMoney(playerid) < 5000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4292.                             else
  4293.                             {
  4294.                                 GivePlayerMoney(playerid, - 5000);
  4295.                                 GivePlayerWeapon(playerid, 29, 200);
  4296.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a MP5 (200 Ammo) for $5000.");
  4297.                             }
  4298.                         }
  4299.                         case 4:
  4300.                         {
  4301.                             if(GetPlayerMoney(playerid) < 13000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4302.                             else
  4303.                             {
  4304.                                 GivePlayerMoney(playerid, - 13000);
  4305.                                 GivePlayerWeapon(playerid, 29, 500);
  4306.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a MP5 (500 Ammo) for $13000.");
  4307.                             }
  4308.                         }
  4309.                     }
  4310.                 }
  4311.                 case 14://ak-47
  4312.                 {
  4313.                     switch(listitem)
  4314.                     {
  4315.                         case 0:
  4316.                         {
  4317.                             if(GetPlayerMoney(playerid) < 30) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4318.                             else
  4319.                             {
  4320.                                 GivePlayerMoney(playerid, - 30);
  4321.                                 GivePlayerWeapon(playerid, 30, 1);
  4322.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Ak-47 (1 Ammo) for $30.");
  4323.                             }
  4324.                         }
  4325.                         case 1:
  4326.                         {
  4327.                             if(GetPlayerMoney(playerid) < 1500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4328.                             else
  4329.                             {
  4330.                                 GivePlayerMoney(playerid, - 1500);
  4331.                                 GivePlayerWeapon(playerid, 30, 50);
  4332.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Ak-47 (50 Ammo) for $1500.");
  4333.                             }
  4334.                         }
  4335.                         case 2:
  4336.                         {
  4337.                             if(GetPlayerMoney(playerid) < 3000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4338.                             else
  4339.                             {
  4340.                                 GivePlayerMoney(playerid, - 3000);
  4341.                                 GivePlayerWeapon(playerid, 30, 100);
  4342.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Ak-47 (100 Ammo) for $3000.");
  4343.                             }
  4344.                         }
  4345.                         case 3:
  4346.                         {
  4347.                             if(GetPlayerMoney(playerid) < 5000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4348.                             else
  4349.                             {
  4350.                                 GivePlayerMoney(playerid, - 5000);
  4351.                                 GivePlayerWeapon(playerid, 30, 200);
  4352.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Ak-47 (200 Ammo) for $5000.");
  4353.                             }
  4354.                         }
  4355.                         case 4:
  4356.                         {
  4357.                             if(GetPlayerMoney(playerid) < 13000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4358.                             else
  4359.                             {
  4360.                                 GivePlayerMoney(playerid, - 13000);
  4361.                                 GivePlayerWeapon(playerid, 30, 500);
  4362.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Ak-47 (500 Ammo) for $13000.");
  4363.                             }
  4364.                         }
  4365.                     }
  4366.                 }
  4367.                 case 15://M4
  4368.                 {
  4369.                     switch(listitem)
  4370.                     {
  4371.                         case 0:
  4372.                         {
  4373.                             if(GetPlayerMoney(playerid) < 30) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4374.                             else
  4375.                             {
  4376.                                 GivePlayerMoney(playerid, - 30);
  4377.                                 GivePlayerWeapon(playerid, 31, 1);
  4378.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a M4 (1 Ammo) for $30.");
  4379.                             }
  4380.                         }
  4381.                         case 1:
  4382.                         {
  4383.                             if(GetPlayerMoney(playerid) < 1500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4384.                             else
  4385.                             {
  4386.                                 GivePlayerMoney(playerid, - 1500);
  4387.                                 GivePlayerWeapon(playerid, 31, 50);
  4388.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a M4 (50 Ammo) for $1500.");
  4389.                             }
  4390.                         }
  4391.                         case 2:
  4392.                         {
  4393.                             if(GetPlayerMoney(playerid) < 3000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4394.                             else
  4395.                             {
  4396.                                 GivePlayerMoney(playerid, - 3000);
  4397.                                 GivePlayerWeapon(playerid, 31, 100);
  4398.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a M4 (100 Ammo) for $3000.");
  4399.                             }
  4400.                         }
  4401.                         case 3:
  4402.                         {
  4403.                             if(GetPlayerMoney(playerid) < 5000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4404.                             else
  4405.                             {
  4406.                                 GivePlayerMoney(playerid, - 5000);
  4407.                                 GivePlayerWeapon(playerid, 31, 200);
  4408.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a M4 (200 Ammo) for $5000.");
  4409.                             }
  4410.                         }
  4411.                         case 4:
  4412.                         {
  4413.                             if(GetPlayerMoney(playerid) < 13000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4414.                             else
  4415.                             {
  4416.                                 GivePlayerMoney(playerid, - 13000);
  4417.                                 GivePlayerWeapon(playerid, 31, 500);
  4418.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a M4 (500 Ammo) for $13000.");
  4419.                             }
  4420.                         }
  4421.                     }
  4422.                 }
  4423.                 case 16://Tec-9
  4424.                 {
  4425.                     switch(listitem)
  4426.                     {
  4427.                         case 0:
  4428.                         {
  4429.                             if(GetPlayerMoney(playerid) < 35) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4430.                             else
  4431.                             {
  4432.                                 GivePlayerMoney(playerid, - 35);
  4433.                                 GivePlayerWeapon(playerid, 32, 1);
  4434.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Tec-9 (1 Ammo) for $35.");
  4435.                             }
  4436.                         }
  4437.                         case 1:
  4438.                         {
  4439.                             if(GetPlayerMoney(playerid) < 1750) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4440.                             else
  4441.                             {
  4442.                                 GivePlayerMoney(playerid, - 1750);
  4443.                                 GivePlayerWeapon(playerid, 32, 50);
  4444.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Tec-9 (50 Ammo) for $1750.");
  4445.                             }
  4446.                         }
  4447.                         case 2:
  4448.                         {
  4449.                             if(GetPlayerMoney(playerid) < 3500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4450.                             else
  4451.                             {
  4452.                                 GivePlayerMoney(playerid, - 3500);
  4453.                                 GivePlayerWeapon(playerid, 32, 100);
  4454.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Tec-9 (100 Ammo) for $3500.");
  4455.                             }
  4456.                         }
  4457.                         case 3:
  4458.                         {
  4459.                             if(GetPlayerMoney(playerid) < 6000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4460.                             else
  4461.                             {
  4462.                                 GivePlayerMoney(playerid, - 6000);
  4463.                                 GivePlayerWeapon(playerid, 32, 200);
  4464.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Tec-9 (200 Ammo) for $6000.");
  4465.                             }
  4466.                         }
  4467.                         case 4:
  4468.                         {
  4469.                             if(GetPlayerMoney(playerid) < 14000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4470.                             else
  4471.                             {
  4472.                                 GivePlayerMoney(playerid, - 14000);
  4473.                                 GivePlayerWeapon(playerid, 32, 500);
  4474.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Tec-9 (500 Ammo) for $14000.");
  4475.                             }
  4476.                         }
  4477.                     }
  4478.                 }
  4479.                 case 17://Rifle
  4480.                 {
  4481.                     switch(listitem)
  4482.                     {
  4483.                         case 0:
  4484.                         {
  4485.                             if(GetPlayerMoney(playerid) < 30) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4486.                             else
  4487.                             {
  4488.                                 GivePlayerMoney(playerid, - 30);
  4489.                                 GivePlayerWeapon(playerid, 33, 1);
  4490.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Rifle (1 Ammo) for $30.");
  4491.                             }
  4492.                         }
  4493.                         case 1:
  4494.                         {
  4495.                             if(GetPlayerMoney(playerid) < 1500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4496.                             else
  4497.                             {
  4498.                                 GivePlayerMoney(playerid, - 1500);
  4499.                                 GivePlayerWeapon(playerid, 33, 50);
  4500.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Rifle (50 Ammo) for $1500.");
  4501.                             }
  4502.                         }
  4503.                         case 2:
  4504.                         {
  4505.                             if(GetPlayerMoney(playerid) < 3000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4506.                             else
  4507.                             {
  4508.                                 GivePlayerMoney(playerid, - 3000);
  4509.                                 GivePlayerWeapon(playerid, 33, 100);
  4510.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Rifle (100 Ammo) for $3000.");
  4511.                             }
  4512.                         }
  4513.                         case 3:
  4514.                         {
  4515.                             if(GetPlayerMoney(playerid) < 5000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4516.                             else
  4517.                             {
  4518.                                 GivePlayerMoney(playerid, - 5000);
  4519.                                 GivePlayerWeapon(playerid, 33, 200);
  4520.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Rifle (200 Ammo) for $5000.");
  4521.                             }
  4522.                         }
  4523.                         case 4:
  4524.                         {
  4525.                             if(GetPlayerMoney(playerid) < 13000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4526.                             else
  4527.                             {
  4528.                                 GivePlayerMoney(playerid, - 13000);
  4529.                                 GivePlayerWeapon(playerid, 33, 500);
  4530.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Rifle (500 Ammo) for $13000.");
  4531.                             }
  4532.                         }
  4533.                     }
  4534.                 }
  4535.                 case 18://sniper rifle
  4536.                 {
  4537.                     switch(listitem)
  4538.                     {
  4539.                         case 0:
  4540.                         {
  4541.                             if(GetPlayerMoney(playerid) < 60) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4542.                             else
  4543.                             {
  4544.                                 GivePlayerMoney(playerid, - 60);
  4545.                                 GivePlayerWeapon(playerid, 34, 1);
  4546.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Sniper Rifle (1 Ammo) for $60.");
  4547.                             }
  4548.                         }
  4549.                         case 1:
  4550.                         {
  4551.                             if(GetPlayerMoney(playerid) < 3000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4552.                             else
  4553.                             {
  4554.                                 GivePlayerMoney(playerid, - 3000);
  4555.                                 GivePlayerWeapon(playerid, 34, 50);
  4556.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Sniper Rifle (50 Ammo) for $3000.");
  4557.                             }
  4558.                         }
  4559.                         case 2:
  4560.                         {
  4561.                             if(GetPlayerMoney(playerid) < 6000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4562.                             else
  4563.                             {
  4564.                                 GivePlayerMoney(playerid, - 6000);
  4565.                                 GivePlayerWeapon(playerid, 34, 100);
  4566.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Sniper Rifle (100 Ammo) for $6000.");
  4567.                             }
  4568.                         }
  4569.                         case 3:
  4570.                         {
  4571.                             if(GetPlayerMoney(playerid) < 10000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4572.                             else
  4573.                             {
  4574.                                 GivePlayerMoney(playerid, - 10000);
  4575.                                 GivePlayerWeapon(playerid, 34, 200);
  4576.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Sniper Rifle (200 Ammo) for $10000.");
  4577.                             }
  4578.                         }
  4579.                         case 4:
  4580.                         {
  4581.                             if(GetPlayerMoney(playerid) < 18000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4582.                             else
  4583.                             {
  4584.                                 GivePlayerMoney(playerid, - 18000);
  4585.                                 GivePlayerWeapon(playerid, 34, 500);
  4586.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Sniper Rifle (500 Ammo) for $18000.");
  4587.                             }
  4588.                         }
  4589.                     }
  4590.                 }
  4591.                 case 19://RPG
  4592.                 {
  4593.                     switch(listitem)
  4594.                     {
  4595.                         case 0:
  4596.                         {
  4597.                             if(GetPlayerMoney(playerid) < 1500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4598.                             else
  4599.                             {
  4600.                                 GivePlayerMoney(playerid, - 1500);
  4601.                                 GivePlayerWeapon(playerid, 35, 1);
  4602.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a RPG for $1500.");
  4603.                             }
  4604.                         }
  4605.                         case 1:
  4606.                         {
  4607.                             if(GetPlayerMoney(playerid) < 3000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4608.                             else
  4609.                             {
  4610.                                 GivePlayerMoney(playerid, - 3000);
  4611.                                 GivePlayerWeapon(playerid, 35, 2);
  4612.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought 2 RPG for $3000.");
  4613.                             }
  4614.                         }
  4615.                         case 2:
  4616.                         {
  4617.                             if(GetPlayerMoney(playerid) < 7000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4618.                             else
  4619.                             {
  4620.                                 GivePlayerMoney(playerid, - 7000);
  4621.                                 GivePlayerWeapon(playerid, 35, 5);
  4622.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought 5 RPG for $7000.");
  4623.                             }
  4624.                         }
  4625.                     }
  4626.                 }
  4627.                 case 20://H.S. Rockets
  4628.                 {
  4629.                     switch(listitem)
  4630.                     {
  4631.                         case 0:
  4632.                         {
  4633.                             if(GetPlayerMoney(playerid) < 1800) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4634.                             else
  4635.                             {
  4636.                                 GivePlayerMoney(playerid, - 1800);
  4637.                                 GivePlayerWeapon(playerid, 36, 1);
  4638.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a H.S. Rockets for $1800.");
  4639.                             }
  4640.                         }
  4641.                         case 1:
  4642.                         {
  4643.                             if(GetPlayerMoney(playerid) < 3600) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4644.                             else
  4645.                             {
  4646.                                 GivePlayerMoney(playerid, - 3600);
  4647.                                 GivePlayerWeapon(playerid, 36, 2);
  4648.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought 2 H.S. Rockets for $3600.");
  4649.                             }
  4650.                         }
  4651.                         case 2:
  4652.                         {
  4653.                             if(GetPlayerMoney(playerid) < 8000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4654.                             else
  4655.                             {
  4656.                                 GivePlayerMoney(playerid, - 8000);
  4657.                                 GivePlayerWeapon(playerid, 36, 5);
  4658.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought 5 H.S. Rockets for $8000.");
  4659.                             }
  4660.                         }
  4661.                     }
  4662.                 }
  4663.                 case 21://Flamethower
  4664.                 {
  4665.                     switch(listitem)
  4666.                     {
  4667.                         case 0:
  4668.                         {
  4669.                             if(GetPlayerMoney(playerid) < 1500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4670.                             else
  4671.                             {
  4672.                                 GivePlayerMoney(playerid, - 1500);
  4673.                                 GivePlayerWeapon(playerid, 37, 100);
  4674.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Flamethower (100 Ammo) for $1500.");
  4675.                             }
  4676.                         }
  4677.                         case 1:
  4678.                         {
  4679.                             if(GetPlayerMoney(playerid) < 3000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4680.                             else
  4681.                             {
  4682.                                 GivePlayerMoney(playerid, - 3000);
  4683.                                 GivePlayerWeapon(playerid, 37, 200);
  4684.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Flamethower (200 Ammo) for $3000.");
  4685.                             }
  4686.                         }
  4687.                         case 2:
  4688.                         {
  4689.                             if(GetPlayerMoney(playerid) < 7000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4690.                             else
  4691.                             {
  4692.                                 GivePlayerMoney(playerid, - 7000);
  4693.                                 GivePlayerWeapon(playerid, 37, 500);
  4694.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Flamethower (500 Ammo) for $7000.");
  4695.                             }
  4696.                         }
  4697.                     }
  4698.                 }
  4699.                 case 22://satchel
  4700.                 {
  4701.                     switch(listitem)
  4702.                     {
  4703.                         case 0:
  4704.                         {
  4705.                             if(GetPlayerMoney(playerid) < 1500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4706.                             else
  4707.                             {
  4708.                                 GivePlayerMoney(playerid, - 1500);
  4709.                                 GivePlayerWeapon(playerid, 39, 1);
  4710.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Satchel for $1500.");
  4711.                             }
  4712.                         }
  4713.                         case 1:
  4714.                         {
  4715.                             if(GetPlayerMoney(playerid) < 3000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4716.                             else
  4717.                             {
  4718.                                 GivePlayerMoney(playerid, - 3000);
  4719.                                 GivePlayerWeapon(playerid, 39, 2);
  4720.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought 2 Satchel for $3000.");
  4721.                             }
  4722.                         }
  4723.                         case 2:
  4724.                         {
  4725.                             if(GetPlayerMoney(playerid) < 7000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4726.                             else
  4727.                             {
  4728.                                 GivePlayerMoney(playerid, - 7000);
  4729.                                 GivePlayerWeapon(playerid, 39, 5);
  4730.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought 5 Satchel for $7000.");
  4731.                             }
  4732.                         }
  4733.                     }
  4734.                 }
  4735.                 case (0 + 100)://spray can
  4736.                 {
  4737.                     switch(listitem)
  4738.                     {
  4739.                         case 0:
  4740.                         {
  4741.                             if(GetPlayerMoney(playerid) < 450) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4742.                             else
  4743.                             {
  4744.                                 GivePlayerMoney(playerid, - 450);
  4745.                                 GivePlayerWeapon(playerid, 41, 50);
  4746.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Spray Can (50 Ammo) for $450.");
  4747.                             }
  4748.                         }
  4749.                     }
  4750.                 }
  4751.                 case (1 + 100)://fire estinguisher
  4752.                 {
  4753.                     switch(listitem)
  4754.                     {
  4755.                         case 0:
  4756.                         {
  4757.                             if(GetPlayerMoney(playerid) < 500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4758.                             else
  4759.                             {
  4760.                                 GivePlayerMoney(playerid, - 500);
  4761.                                 GivePlayerWeapon(playerid, 42, 50);
  4762.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Fire Extinguisher (50 Ammo) for $1500.");
  4763.                             }
  4764.                         }
  4765.                         case 1:
  4766.                         {
  4767.                             if(GetPlayerMoney(playerid) < 1000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4768.                             else
  4769.                             {
  4770.                                 GivePlayerMoney(playerid, - 1000);
  4771.                                 GivePlayerWeapon(playerid, 42, 100);
  4772.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Fire Extinguisher (100 Ammo) for $1000.");
  4773.                             }
  4774.                         }
  4775.                         case 2:
  4776.                         {
  4777.                             if(GetPlayerMoney(playerid) < 5000) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4778.                             else
  4779.                             {
  4780.                                 GivePlayerMoney(playerid, - 5000);
  4781.                                 GivePlayerWeapon(playerid, 42, 500);
  4782.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Fire Extinguisher (500 Ammo) for $5000.");
  4783.                             }
  4784.                         }
  4785.                     }
  4786.                 }
  4787.                 case (2 + 100)://camera
  4788.                 {
  4789.                     switch(listitem)
  4790.                     {
  4791.                         case 0:
  4792.                         {
  4793.                             if(GetPlayerMoney(playerid) < 50) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4794.                             else
  4795.                             {
  4796.                                 GivePlayerMoney(playerid, - 50);
  4797.                                 GivePlayerWeapon(playerid, 43, 50);
  4798.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Camera (50 Ammo) for $50.");
  4799.                             }
  4800.                         }
  4801.                     }
  4802.                 }
  4803.                 case (3 + 100)://night vission
  4804.                 {
  4805.                     switch(listitem)
  4806.                     {
  4807.                         case 0:
  4808.                         {
  4809.                             if(IsPlayerHavingWeapon(playerid, 44)) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You already have a Night Vission Goggles.");
  4810.                             else if(GetPlayerMoney(playerid) < 500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4811.                             else
  4812.                             {
  4813.                                 GivePlayerMoney(playerid, - 500);
  4814.                                 GivePlayerWeapon(playerid, 44, 1);
  4815.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Night Vission Goggles for $500.");
  4816.                             }
  4817.                         }
  4818.                     }
  4819.                 }
  4820.                 case (4 + 100)://thermal vission
  4821.                 {
  4822.                     switch(listitem)
  4823.                     {
  4824.                         case 0:
  4825.                         {
  4826.                             if(IsPlayerHavingWeapon(playerid, 45)) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You already have a Thermal Vission Goggle.");
  4827.                             else if(GetPlayerMoney(playerid) < 500) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4828.                             else
  4829.                             {
  4830.                                 GivePlayerMoney(playerid, - 500);
  4831.                                 GivePlayerWeapon(playerid, 45, 1);
  4832.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Thermal Vission Goggles for $500.");
  4833.                             }
  4834.                         }
  4835.                     }
  4836.                 }
  4837.                 case (5 + 100)://Parachute
  4838.                 {
  4839.                     switch(listitem)
  4840.                     {
  4841.                         case 0:
  4842.                         {
  4843.                             if(IsPlayerHavingWeapon(playerid, 45)) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You already have a Parachute.");
  4844.                             else if(GetPlayerMoney(playerid) < 1) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have enough money to buy this item.");
  4845.                             else
  4846.                             {
  4847.                                 GivePlayerMoney(playerid, - 1);
  4848.                                 GivePlayerWeapon(playerid, 46, 1);
  4849.                                 SendClientMessage(playerid, COLOR_LIME, "SHOP: You have bought a Parachute for $1.");
  4850.                             }
  4851.                         }
  4852.                     }
  4853.                 }
  4854.             }
  4855.         }
  4856.  
  4857.         if(gListitem[playerid] < 100)
  4858.         {
  4859.             SetupPrevModelDialog(0.0, 0.0, 0.0, 3.0);
  4860.             ShowPlayerDialog(playerid, (DIALOG_SHOP + 1), DIALOG_STYLE_PREVMODEL, "Weapons List", weapons, "Select", "Back");
  4861.         }
  4862.         else
  4863.         {
  4864.             SetupPrevModelDialog(0.0, 0.0, 0.0, 2.0);
  4865.             ShowPlayerDialog(playerid, (DIALOG_SHOP + 2), DIALOG_STYLE_PREVMODEL, "Misc. Items", miscitems, "Select", "Back");
  4866.         }
  4867.         gListitem[playerid] = -1;
  4868.     }
  4869.  
  4870.     if(dialogid == DIALOG_INVENTORY)
  4871.     {
  4872.         if(response)
  4873.         {
  4874.             if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be in team deathmatch to open inventory.");
  4875.  
  4876.             new string[98];
  4877.             switch(listitem)
  4878.             {
  4879.                 case 0: format(string, sizeof(string), "Painkillers (%i pk.s in your bag)", gPainkillers[playerid]);
  4880.                 case 1: format(string, sizeof(string), "Armour Jacket (%i armour in your bag)", (gArmour[playerid]) ? 1 : 0);
  4881.                 case 2: format(string, sizeof(string), "Protection Helmet (%i helmet in your bag)", (gHelmet[playerid]) ? 1 : 0);
  4882.                 case 3: format(string, sizeof(string), "Gas Mask (%i mask in your bag)", (gMask[playerid]) ? 1 : 0);
  4883.                 case 4: format(string, sizeof(string), "Sucide Bomb (%i bomb in your bag)", (gBomb[playerid]) ? 1 : 0);
  4884.             }
  4885.             gListitem[playerid] = listitem;
  4886.             ShowPlayerDialog(playerid, (DIALOG_INVENTORY + 1), DIALOG_STYLE_LIST, string, "Use/Unuse\n(i) Info", "Select", "Back");
  4887.         }
  4888.     }
  4889.  
  4890.     if(dialogid == (DIALOG_INVENTORY + 1))
  4891.     {
  4892.         if(response)
  4893.         {
  4894.             if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be in team deathmatch to open inventory.");
  4895.  
  4896.             switch(listitem)
  4897.             {
  4898.                 case 0:
  4899.                 {
  4900.                     switch(gListitem[playerid])
  4901.                     {
  4902.                         case 0:
  4903.                         {
  4904.                             if(gPainkillers[playerid] < 1) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have any painkillers in your bag.");
  4905.                             else
  4906.                             {
  4907.                                 gPainkillers[playerid] -= 1;
  4908.  
  4909.                                 new string[144];
  4910.                                 format(string, sizeof(string), "* You have consumed a painkiller; You are now left with %i painkillers in your bag.", gPainkillers[playerid]);
  4911.                                 SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  4912.  
  4913.                                 new Float:hp;
  4914.                                 GetPlayerHealth(playerid, hp);
  4915.                                 if((hp + 30.0) >= 100.0) SetPlayerHealth(playerid, 100.0);
  4916.                                 else SetPlayerHealth(playerid, (hp + 30.0));
  4917.  
  4918.                                 NotifyPlayer(playerid, "~g~Health regained (30%)", 5000);
  4919.                                 ApplyAnimation(playerid, "MEDIC", "CPR", 1.0, 0, 1, 1, 1, 1);
  4920.                             }
  4921.                         }
  4922.                         case 1:
  4923.                         {
  4924.                             if(! gArmour[playerid]) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have an Armour Jacket in your bag.");
  4925.                             else
  4926.                             {
  4927.                                 gArmour[playerid] = false;
  4928.                                 SetPlayerArmour(playerid, 100.0);
  4929.  
  4930.                                 SendClientMessage(playerid, COLOR_SEA_GREEN, "You have used your armour jacket from your bag!");
  4931.  
  4932.                                 NotifyPlayer(playerid, "You have a ~g~Armour Jacket", 5000);
  4933.                             }
  4934.                         }
  4935.                         case 2:
  4936.                         {
  4937.                             if(! gHelmet[playerid]) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have a Protection Helmet.");
  4938.                             else
  4939.                             {
  4940.                                 if(! IsPlayerAttachedObjectSlotUsed(playerid, 2))
  4941.                                 {
  4942.                                     RemovePlayerAttachedObject(playerid, 2);
  4943.                                     SendClientMessage(playerid, COLOR_SEA_GREEN, "* You have ENABLED your Protection helmet.");
  4944.                                     NotifyPlayer(playerid, "~g~Protection Helmet enabled", 5000);
  4945.                                 }
  4946.                                 else
  4947.                                 {
  4948.                                     switch(GetPlayerSkin(playerid))
  4949.                                     {
  4950.                                         case 24: SetPlayerAttachedObject(playerid,2,18638,2,0.151999,0.038000,0.000000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 24
  4951.                                         case 287: SetPlayerAttachedObject(playerid,2,18638,2,0.128000,0.049999,0.006000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 287
  4952.                                         case 285: SetPlayerAttachedObject(playerid,2,18638,2,0.182000,0.035000,0.007000,0.000000,0.000000,0.000000,1.000000,1.069999,1.118999); //skin 285
  4953.                                         case 111: SetPlayerAttachedObject(playerid,2,18638,2,0.159999,0.032999,0.000000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 111
  4954.                                         case 122: SetPlayerAttachedObject(playerid,2,18638,2,0.148000,0.017000,-0.002999,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 122
  4955.                                         case 73: SetPlayerAttachedObject(playerid,2,18638,2,0.148999,0.038999,0.000000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 73
  4956.                                         case 46: SetPlayerAttachedObject(playerid,2,18638,2,0.162999,0.035000,0.001000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 46
  4957.                                         case 102: SetPlayerAttachedObject(playerid,2,18638,2,0.173000,0.024999,-0.003000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 102
  4958.                                         default: SetPlayerAttachedObject(playerid,2,18638,2,0.173000,0.024999,-0.003000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 102
  4959.                                     }
  4960.                                     SendClientMessage(playerid, COLOR_SEA_GREEN, "* You have DISABLED your Protection helmet.");
  4961.                                     NotifyPlayer(playerid, "~r~Protection Helmet disabled", 5000);
  4962.                                 }
  4963.                             }
  4964.                         }
  4965.                         case 3:
  4966.                         {
  4967.                             if(! gMask[playerid]) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have a Gas Mask.");
  4968.                             else
  4969.                             {
  4970.                                 if(! IsPlayerAttachedObjectSlotUsed(playerid, 3))
  4971.                                 {
  4972.                                     RemovePlayerAttachedObject(playerid, 3);
  4973.                                     SendClientMessage(playerid, COLOR_SEA_GREEN, "* You have ENABLED your Gas Mask.");
  4974.                                     NotifyPlayer(playerid, "~g~Gas Mask enabled", 5000);
  4975.                                 }
  4976.                                 else
  4977.                                 {
  4978.                                     SetPlayerAttachedObject(playerid, 3, 19472, 2, -0.022000, 0.137000, 0.018999, 3.899994, 85.999961, 92.999984, 0.923999, 1.141000, 1.026999);
  4979.                                     SendClientMessage(playerid, COLOR_SEA_GREEN, "* You have DISABLED your Gas Mask.");
  4980.                                     NotifyPlayer(playerid, "~r~Gas Mask disabled", 5000);
  4981.                                 }
  4982.                             }
  4983.                         }
  4984.                         case 4:
  4985.                         {
  4986.                             if(! gBomb[playerid]) SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have a Sucide Bomb.");
  4987.                             else
  4988.                             {
  4989.                                 if(! IsPlayerAttachedObjectSlotUsed(playerid, 4))
  4990.                                 {
  4991.                                     RemovePlayerAttachedObject(playerid, 4);
  4992.                                     SendClientMessage(playerid, COLOR_SEA_GREEN, "* You have ENABLED your Sucide Bomb.");
  4993.                                     NotifyPlayer(playerid, "~g~Sucide Bomb enabled", 5000);
  4994.                                 }
  4995.                                 else
  4996.                                 {
  4997.                                     SetPlayerAttachedObject(playerid, 4, 1654, 1, 0.046000, 0.229000, -0.013000, 3.099998, 78.299972, -178.599960, 1.000000, 1.000000, 1.000000);
  4998.                                     SendClientMessage(playerid, COLOR_SEA_GREEN, "* You have DISABLED your Sucide Bomb.");
  4999.                                     NotifyPlayer(playerid, "~r~Sucide Bomb disabled", 5000);
  5000.                                 }
  5001.                             }
  5002.                         }
  5003.                     }
  5004.                     OnPlayerKeyStateChange(playerid, KEY_YES, 0);
  5005.                 }
  5006.                 case 1:
  5007.                 {
  5008.                     SendClientMessage(playerid, COLOR_KHAKI, " ");
  5009.                     switch(gListitem[playerid])
  5010.                     {
  5011.                         case 0:
  5012.                         {
  5013.                             SendClientMessage(playerid, COLOR_KHAKI, "* Painkillers are medicine pills which will help you to regain health when you are injured.");
  5014.                             SendClientMessage(playerid, COLOR_KHAKI, "* You must type /pk to use a painkiller and /givepk to distribute it to others!");
  5015.                         }
  5016.                         case 1:
  5017.                         {
  5018.                             SendClientMessage(playerid, COLOR_KHAKI, "* Armour Jacket is a portable armour case which can be used anytime to regain 100% Armour.");
  5019.                             SendClientMessage(playerid, COLOR_KHAKI, "* You must type /armour to use/unuse an armour jacket and /givearmour to distribute it to others!");
  5020.                         }
  5021.                         case 2:
  5022.                         {
  5023.                             SendClientMessage(playerid, COLOR_KHAKI, "* Protection Helmet helps you to avoid instant deaths due to headshots, basically prevents headshots.");
  5024.                             SendClientMessage(playerid, COLOR_KHAKI, "* You must type /helmet to use/unuse a protection helmet and /givehelmet to distribute it to others!");
  5025.                         }
  5026.                         case 3:
  5027.                         {
  5028.                             SendClientMessage(playerid, COLOR_KHAKI, "* Gas Mask helps you to prevent asthma and cough problems from teargas.");
  5029.                             SendClientMessage(playerid, COLOR_KHAKI, "* You must type /mask to use/unuse a gas mask and /givemask to distribute it to others!");
  5030.                         }
  5031.                         case 4:
  5032.                         {
  5033.                             SendClientMessage(playerid, COLOR_KHAKI, "* Sucide Bomb is a deadly weapon! When you have a sucide bomb, you automatically explodes killing enemies around you on death!");
  5034.                             SendClientMessage(playerid, COLOR_KHAKI, "* You must type /bomb to use/unuse a sucide bomb and /givebomb to distribute it to others!");
  5035.                         }
  5036.                     }
  5037.                     gListitem[playerid] = -1;
  5038.                 }
  5039.             }
  5040.         }
  5041.     }
  5042.  
  5043.     if(dialogid == DIALOG_PRESTIGE)
  5044.     {
  5045.         if(response)
  5046.         {
  5047.             new weaponid;
  5048.             switch(listitem)
  5049.             {
  5050.                 case 0: weaponid = 22;
  5051.                 case 1: weaponid = 23;
  5052.                 case 2: weaponid = 24;
  5053.                 case 7: weaponid = 25;
  5054.                 case 8: weaponid = 26;
  5055.                 case 9: weaponid = 27;
  5056.                 case 10: weaponid = 28;
  5057.                 case 11: weaponid = 29;
  5058.                 case 12: weaponid = 30;
  5059.                 case 13: weaponid = 31;
  5060.                 case 14: weaponid = 32;
  5061.                 case 15: weaponid = 33;
  5062.                 case 16: weaponid = 34;
  5063.                 case 17: weaponid = 37;
  5064.                 default: weaponid = 24;
  5065.             }
  5066.             switch(gListitem[playerid])
  5067.             {
  5068.                 case 0:
  5069.                 {
  5070.                     GAdmin_ChangeUserData(ReturnPlayerName(playerid), "i", "weapon1", weaponid);
  5071.                     SendClientMessage(playerid, COLOR_YELLOW, "* You have successfully set your prestige weapon I.");
  5072.                 }
  5073.                 case 1:
  5074.                 {
  5075.                     GAdmin_ChangeUserData(ReturnPlayerName(playerid), "i", "weapon2", weaponid);
  5076.                     SendClientMessage(playerid, COLOR_YELLOW, "* You have successfully set your prestige weapon II.");
  5077.                 }
  5078.                 case 2:
  5079.                 {
  5080.                     GAdmin_ChangeUserData(ReturnPlayerName(playerid), "i", "weapon3", weaponid);
  5081.                     SendClientMessage(playerid, COLOR_YELLOW, "* You have successfully set your prestige weapon III.");
  5082.                 }
  5083.             }
  5084.         }
  5085.         gListitem[playerid] = -1;
  5086.     }
  5087.  
  5088.     if(dialogid == DIALOG_DUEL_WEAPON)
  5089.     {
  5090.         if(response)
  5091.         {
  5092.             new weaponid;
  5093.             switch(listitem)
  5094.             {
  5095.                 case 0: weaponid = 9;
  5096.                 case 1: weaponid = 16;
  5097.                 case 2: weaponid = 17;
  5098.                 case 3: weaponid = 18;
  5099.                 case 4: weaponid = 22;
  5100.                 case 5: weaponid = 23;
  5101.                 case 6: weaponid = 24;
  5102.                 case 7: weaponid = 25;
  5103.                 case 8: weaponid = 26;
  5104.                 case 9: weaponid = 27;
  5105.                 case 10: weaponid = 28;
  5106.                 case 11: weaponid = 29;
  5107.                 case 12: weaponid = 30;
  5108.                 case 13: weaponid = 31;
  5109.                 case 14: weaponid = 32;
  5110.                 case 15: weaponid = 33;
  5111.                 case 16: weaponid = 34;
  5112.                 case 17: weaponid = 37;
  5113.                 default: weaponid = 24;
  5114.             }
  5115.             gDuel[playerid][d_weapon] = weaponid;
  5116.             gDuel[gDuel[playerid][d_opponent]][d_weapon] = weaponid;
  5117.            
  5118.             if(! IsPlayerConnected(gDuel[playerid][d_opponent])) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The opponent player is not connected.");
  5119.  
  5120.             if(gPlayerGamemode[gDuel[playerid][d_opponent]] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The opponent player must in team deathmatch.");
  5121.  
  5122.             if(! IsPlayerSpawned(gDuel[playerid][d_opponent])) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't duel the player isn't spawned.");
  5123.  
  5124.             if(gDuel[gDuel[playerid][d_opponent]][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The opponent player is already in a duel.");
  5125.  
  5126.             if(GetPlayerMoney(playerid) < gDuel[playerid][d_bet]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You yourself don't have that much bet money.");
  5127.  
  5128.             if(gDuel[playerid][d_bet] < 0) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't bet negative money!!!!");
  5129.  
  5130.             new string[256];
  5131.             format(string, sizeof(string), "* You have send a duel request to %s[%i] with weapon %s, bet $%i.", ReturnPlayerName(gDuel[playerid][d_opponent]), gDuel[playerid][d_opponent], ReturnWeaponName(gDuel[playerid][d_weapon]), gDuel[playerid][d_bet]);
  5132.             SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  5133.  
  5134.             format(string, sizeof(string), "You have recieved a duel request from "RED"%s[%i]\n\n"LIGHT_BLUE"Bet money: "PINK"$%i\n"LIGHT_BLUE"Weapon: "PINK"%s", ReturnPlayerName(playerid), playerid, gDuel[playerid][d_bet], ReturnWeaponName(gDuel[playerid][d_weapon]));
  5135.             ShowPlayerDialog(gDuel[playerid][d_opponent], DIALOG_DUEL, DIALOG_STYLE_MSGBOX, "Duel request!", string, "Accept", "Ignore");
  5136.         }
  5137.     }
  5138.  
  5139.     if(dialogid == DIALOG_DUEL)
  5140.     {
  5141.         if(! response)
  5142.         {
  5143.             SendClientMessage(gDuel[playerid][d_opponent], COLOR_RED, "* Your duel request was ignored !! Try some next time !!");
  5144.  
  5145.             gDuel[gDuel[playerid][d_opponent]][d_induel] = false;
  5146.             gDuel[gDuel[playerid][d_opponent]][d_opponent] = INVALID_PLAYER_ID;
  5147.             gDuel[gDuel[playerid][d_opponent]][d_weapon] = 0;
  5148.             gDuel[gDuel[playerid][d_opponent]][d_bet] = 0;
  5149.  
  5150.             gDuel[playerid][d_induel] = false;
  5151.             gDuel[playerid][d_opponent] = INVALID_PLAYER_ID;
  5152.             gDuel[playerid][d_weapon] = 0;
  5153.             gDuel[playerid][d_bet] = 0;
  5154.         }
  5155.         if(response)
  5156.         {
  5157.             if(! IsPlayerConnected(gDuel[playerid][d_opponent])) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The opponent player is not connected.");
  5158.  
  5159.             if(gPlayerGamemode[gDuel[playerid][d_opponent]] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The opponent player must in team deathmatch.");
  5160.  
  5161.             if(! IsPlayerSpawned(gDuel[playerid][d_opponent])) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't duel the player isn't spawned.");
  5162.  
  5163.             if(gDuel[gDuel[playerid][d_opponent]][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The opponent player is already in a duel.");
  5164.  
  5165.             if(GetPlayerMoney(playerid) < gDuel[playerid][d_bet]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You yourself don't have that much bet money.");
  5166.  
  5167.             if(gDuel[playerid][d_bet] < 0) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't bet negative money!!!!");
  5168.  
  5169.             ResetPlayerWeapons(playerid);
  5170.             GivePlayerWeapon(playerid, gDuel[playerid][d_weapon], 9999999);
  5171.             SetPlayerHealth(playerid, 100.0);
  5172.             SetPlayerArmour(playerid, 100.0);
  5173.             GameTextForPlayer(playerid, "~r~~h~~h~~h~Go !!", 3000, 6);
  5174.             SetPlayerTeam(playerid, NO_TEAM);
  5175.  
  5176.             ResetPlayerWeapons(gDuel[playerid][d_opponent]);
  5177.             GivePlayerWeapon(gDuel[playerid][d_opponent], gDuel[playerid][d_weapon], 9999999);
  5178.             SetPlayerHealth(gDuel[playerid][d_opponent], 100.0);
  5179.             SetPlayerArmour(gDuel[playerid][d_opponent], 100.0);
  5180.             GameTextForPlayer(gDuel[playerid][d_opponent], "~r~~h~~h~~h~Go !!", 3000, 6);
  5181.             SetPlayerTeam(gDuel[playerid][d_opponent], NO_TEAM);
  5182.  
  5183.             switch(random(3))
  5184.             {
  5185.                 case 0:
  5186.                 {
  5187.                     SetPlayerPos(playerid, -1404.067, 1270.3706, 1042.8672);
  5188.                     SetPlayerInterior(playerid, 16);
  5189.                     SetPlayerVirtualWorld(playerid, playerid);
  5190.  
  5191.                     SetPlayerPos(gDuel[playerid][d_opponent], -1395.067, 1261.3706, 1042.8672);
  5192.                     SetPlayerInterior(gDuel[playerid][d_opponent], 16);
  5193.                     SetPlayerVirtualWorld(gDuel[playerid][d_opponent], playerid);
  5194.                 }
  5195.                 case 1:
  5196.                 {
  5197.                     SetPlayerPos(playerid, 1353.407,2188.155,11.02344);
  5198.                     SetPlayerInterior(playerid, 0);
  5199.                     SetPlayerVirtualWorld(playerid, playerid);
  5200.  
  5201.                     SetPlayerPos(gDuel[playerid][d_opponent], 1346.255,2142.843,11.01563);
  5202.                     SetPlayerInterior(gDuel[playerid][d_opponent], 0);
  5203.                     SetPlayerVirtualWorld(gDuel[playerid][d_opponent], playerid);
  5204.                 }
  5205.                 case 2:
  5206.                 {
  5207.                     SetPlayerPos(playerid, -1041.037,1078.729,1347.678);
  5208.                     SetPlayerInterior(playerid, 10);
  5209.                     SetPlayerVirtualWorld(playerid, playerid);
  5210.                     SetPlayerFacingAngle(playerid, 135);
  5211.  
  5212.                     SetPlayerPos(gDuel[playerid][d_opponent], -1018.061,1052.502,1346.327);
  5213.                     SetPlayerInterior(gDuel[playerid][d_opponent], 10);
  5214.                     SetPlayerVirtualWorld(gDuel[playerid][d_opponent], playerid);
  5215.                     SetPlayerFacingAngle(gDuel[playerid][d_opponent], 45);
  5216.                 }
  5217.             }
  5218.  
  5219.             new string[144];
  5220.             format(string, sizeof(string), "A duel has begun b/w %s and %s [weapon: %s, bet: $%i]", ReturnPlayerName(playerid), ReturnPlayerName(gDuel[playerid][d_opponent]), ReturnWeaponName(gDuel[playerid][d_weapon]), gDuel[playerid][d_bet]);
  5221.             SendClientMessageToAll(COLOR_AQUA, string);
  5222.            
  5223.             gDuel[gDuel[playerid][d_opponent]][d_induel] = true;
  5224.             gDuel[playerid][d_induel] = true;
  5225.             return 1;
  5226.         }
  5227.     }
  5228.  
  5229.     if(dialogid == DIALOG_SPAWN)
  5230.     {
  5231.         if(response)
  5232.         {
  5233.             switch(listitem)
  5234.             {
  5235.                 case 0:
  5236.                 {
  5237.                     SendClientMessage(playerid, COLOR_ORANGE_RED, "* You have set your spawn to BASE.");
  5238.                     gPlayerSpawn[playerid] = SPAWN_BASE;
  5239.                 }
  5240.                 default:
  5241.                 {
  5242.                     if(gCaptureZone[gSpawn[(listitem - 1)][s_zoneid]][E_ZONEOWNER] != GetPlayerTeam(playerid))
  5243.                     {
  5244.                         SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Your team don't own that zone! [LIGHTBLUE: owned, GRAY: not owned]");
  5245.                         return cmd_ss(playerid);
  5246.                     }
  5247.                     else
  5248.                     {
  5249.                         new string[144];
  5250.                         format(string, sizeof(string), "* You have set your spawn to %s.", gCaptureZone[gSpawn[(listitem - 1)][s_zoneid]][E_ZONENAME]);
  5251.                         SendClientMessage(playerid, COLOR_ORANGE_RED, string);
  5252.                         gPlayerSpawn[playerid] = (listitem - 1);
  5253.                     }
  5254.                 }
  5255.             }
  5256.         }
  5257.     }
  5258.    
  5259.     if(dialogid == DIALOG_TIME)
  5260.     {
  5261.         if(response)
  5262.         {
  5263.             switch(listitem)
  5264.             {
  5265.                 case 0:
  5266.                 {
  5267.                     SetPlayerTime(playerid, 7, 0);
  5268.                     PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0);
  5269.                     GameTextForPlayer(playerid,"~y~Morning",5000,3);
  5270.                 }
  5271.                 case 1:
  5272.                 {
  5273.                     SetPlayerTime(playerid, 12, 0);
  5274.                     PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0);
  5275.                     GameTextForPlayer(playerid,"~y~Mid day",5000,3);
  5276.                 }
  5277.                 case 2:
  5278.                 {
  5279.                     SetPlayerTime(playerid, 16, 0);
  5280.                     PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0);
  5281.                     GameTextForPlayer(playerid,"~y~Afternoon",5000,3);
  5282.                 }
  5283.                 case 3:
  5284.                 {
  5285.                     SetPlayerTime(playerid, 20, 0);
  5286.                     PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0);
  5287.                     GameTextForPlayer(playerid,"~y~Evening",5000,3);
  5288.                 }
  5289.                 case 4:
  5290.                 {
  5291.                     SetPlayerTime(playerid, 0, 0);
  5292.                     PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0);
  5293.                     GameTextForPlayer(playerid,"~y~Midnight",5000,3);
  5294.                 }
  5295.             }
  5296.         }
  5297.     }
  5298.     if(dialogid == DIALOG_WEATHER)
  5299.     {
  5300.         if(response)
  5301.         {
  5302.             switch(listitem)
  5303.             {
  5304.                 case 0:
  5305.                 {
  5306.                     SetPlayerWeather(playerid, 5);
  5307.                     PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0);
  5308.                     GameTextForPlayer(playerid,"~y~Blue Sky",5000,3);
  5309.                 }
  5310.                 case 1:
  5311.                 {
  5312.                     SetPlayerWeather(playerid, 19);
  5313.                     PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0);
  5314.                     GameTextForPlayer(playerid,"~y~Sand Strom",5000,3);
  5315.                 }
  5316.                 case 2:
  5317.                 {
  5318.                     SetPlayerWeather(playerid, 8);
  5319.                     PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0);
  5320.                     GameTextForPlayer(playerid,"~y~Thunderstrom",5000,3);
  5321.                 }
  5322.                 case 3:
  5323.                 {
  5324.                     SetPlayerWeather(playerid, 20);
  5325.                     PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0);
  5326.                     GameTextForPlayer(playerid,"~y~Foggy",5000,3);
  5327.                 }
  5328.                 case 4:
  5329.                 {
  5330.                     SetPlayerWeather(playerid, 9);
  5331.                     PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0);
  5332.                     GameTextForPlayer(playerid,"~y~Cloudy",5000,3);
  5333.                 }
  5334.                 case 5:
  5335.                 {
  5336.                     SetPlayerWeather(playerid, 16);
  5337.                     PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0);
  5338.                     GameTextForPlayer(playerid,"~y~High Tide",5000,3);
  5339.                 }
  5340.                 case 6:
  5341.                 {
  5342.                     SetPlayerWeather(playerid, 45);
  5343.                     PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0);
  5344.                     GameTextForPlayer(playerid,"~y~Purple Sky",5000,3);
  5345.                 }
  5346.                 case 7:
  5347.                 {
  5348.                     SetPlayerWeather(playerid, 44);
  5349.                     PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0);
  5350.                     GameTextForPlayer(playerid,"~y~Black/White Sky",5000,3);
  5351.                 }
  5352.                 case 8:
  5353.                 {
  5354.                     SetPlayerWeather(playerid, 22);
  5355.                     PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0);
  5356.                     GameTextForPlayer(playerid,"~y~Green Sky",5000,3);
  5357.                 }
  5358.                 case 9:
  5359.                 {
  5360.                     SetPlayerWeather(playerid, 11);
  5361.                     PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0);
  5362.                     GameTextForPlayer(playerid,"~y~Heat Wave",5000,3);
  5363.                 }
  5364.             }
  5365.         }
  5366.     }
  5367.     return 1;
  5368. }
  5369.  
  5370. //------------------------------------------------
  5371.  
  5372. forward OnPlayerLaunchNuke(playerid, baseid);
  5373. public OnPlayerLaunchNuke(playerid, baseid)
  5374. {
  5375.     gNuke[NUKE_BASE] = -1;
  5376.  
  5377.     gStopTimeUpdate = false;
  5378.  
  5379.     new kills;
  5380.     new string[144];
  5381.     new Float:pos[3];
  5382.     foreach(new i : Player)
  5383.     {
  5384.         if( i != playerid &&
  5385.             IsPlayerInGangZone(i, gTeamBase[baseid][b_base]) &&
  5386.             GetPlayerTeam(i) != GetPlayerTeam(playerid) &&
  5387.             ! GetPlayerVirtualWorld(i) &&
  5388.             ! GetPlayerInterior(i) &&
  5389.             IsPlayerSpawned(i) &&
  5390.             (GetPlayerTeam(i) < sizeof(gTeam) || GetPlayerTeam(i) == NO_TEAM))
  5391.         {
  5392.             GetPlayerPos(i, pos[0], pos[1], pos[2]);
  5393.             CreateExplosion(pos[0] + 2, pos[1], pos[2], 6, 5);
  5394.             CreateExplosion(pos[0] - 2, pos[1], pos[2], 6, 5);
  5395.  
  5396.             SetPlayerHealth(i, 0.0);
  5397.             GameTextForPlayer(i, "~r~NUKED !", 5000, 3);
  5398.  
  5399.             format(string, sizeof(string), "You killed %s[%i] with your Nuke(+$500).", ReturnPlayerName(i), i);
  5400.             SendClientMessage(playerid, COLOR_LIME_GREEN, string);
  5401.  
  5402.             GivePlayerMoney(playerid, 500);
  5403.  
  5404.             CallLocalFunction("OnPlayerDeath", "iii", i, playerid, 51);
  5405.  
  5406.             kills += 1;
  5407.         }
  5408.     }
  5409.  
  5410.     SetWeather(19);
  5411.     SetTimer("OnBombEffectFinish", (10 * 1000), false);
  5412.  
  5413.     format(string, sizeof(string), "* %s[%i] killed %i players with the Nuke (%s).", ReturnPlayerName(playerid), playerid, kills, gTeamBase[baseid][b_name]);
  5414.     SendClientMessageToAll(COLOR_LIGHT_STEEL_BLUE, string);
  5415.     return 1;
  5416. }
  5417.  
  5418. //------------------------------------------------
  5419.  
  5420. forward OnPlayerLaunchAnthrax(playerid);
  5421. public OnPlayerLaunchAnthrax(playerid)
  5422. {
  5423.     gStopTimeUpdate = false;
  5424.  
  5425.     new kills;
  5426.     new string[144];
  5427.     foreach(new i : Player)
  5428.     {
  5429.         if( i != playerid &&
  5430.             GetPlayerTeam(i) != GetPlayerTeam(playerid) &&
  5431.             ! GetPlayerVirtualWorld(i) &&
  5432.             ! GetPlayerInterior(i) &&
  5433.             IsPlayerSpawned(i) &&
  5434.             (GetPlayerTeam(i) < sizeof(gTeam) || GetPlayerTeam(i) == NO_TEAM))
  5435.         {
  5436.             new Float:hp;
  5437.             GetPlayerHealth(i, hp);
  5438.             SetPlayerHealth(i, (hp - 75.0));
  5439.  
  5440.             ApplyAnimation(i, "ped", "gas_cwr", 1.0, 0, 0, 0, 0, 0);
  5441.             GameTextForPlayer(i, "~r~ANTHRAX !", 5000, 3);
  5442.  
  5443.             if((hp - 75.0) <= 0.0)
  5444.             {
  5445.                 format(string, sizeof(string), "You killed %s[%i] with your Anthrax(+$500).", ReturnPlayerName(i), i);
  5446.                 SendClientMessage(playerid, COLOR_LIME_GREEN, string);
  5447.  
  5448.                 GivePlayerMoney(playerid, 500);
  5449.  
  5450.                 CallLocalFunction("OnPlayerDeath", "iii", i, playerid, 40);
  5451.  
  5452.                 kills += 1;
  5453.             }
  5454.         }
  5455.     }
  5456.  
  5457.     SetWeather(2009);
  5458.     SetTimer("OnBombEffectFinish", (10 * 1000), false);
  5459.  
  5460.     format(string, sizeof(string), "* %s[%i] killed %i players with the Anthrax (World).", ReturnPlayerName(playerid), playerid, kills);
  5461.     SendClientMessageToAll(COLOR_LIGHT_STEEL_BLUE, string);
  5462.     return 1;
  5463. }
  5464.  
  5465. //------------------------------------------------
  5466.  
  5467. forward OnBombEffectFinish();
  5468. public OnBombEffectFinish()
  5469. {
  5470.     gStopTimeUpdate = true;
  5471.  
  5472.     SetWorldTime(server_time);
  5473.     SetWeather(server_weather);
  5474.  
  5475.     SendClientMessageToAll(COLOR_LIGHT_STEEL_BLUE, "* The enviornment has been restored!");
  5476.     return 1;
  5477. }
  5478.  
  5479. //------------------------------------------------
  5480.  
  5481. IsPlayerNearEnemies(playerid, Float:range = 30.0)
  5482. {
  5483.     new Float:pos[3];
  5484.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  5485.  
  5486.     foreach(new i : Player)
  5487.     {
  5488.         if( i != playerid &&
  5489.             GetPlayerTeam(playerid) != GetPlayerTeam(i) &&
  5490.             IsPlayerInRangeOfPoint(i, range, pos[0], pos[1], pos[2]))
  5491.         {
  5492.             return true;
  5493.         }
  5494.     }
  5495.     return false;
  5496. }
  5497.  
  5498. //------------------------------------------------
  5499.  
  5500. CMD:kill(playerid)
  5501. {
  5502.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't sucide when you aren't spawned.");
  5503.  
  5504.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5505.  
  5506.     if(IsPlayerNearEnemies(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't use this command near enemies.");
  5507.  
  5508.     if(IsPlayerInAnyVehicle(playerid))
  5509.     {
  5510.         new Float:pos[3];
  5511.         GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  5512.         SetPlayerPos(playerid, pos[0], pos[1], pos[2] + 2.2);//eject the player!
  5513.     }
  5514.     SetPlayerHealth(playerid, 0.0);
  5515.     SendClientMessage(playerid, COLOR_SEA_GREEN, "* You are now dead!");
  5516.     NotifyPlayer(playerid, "You commited sucide!", 5000);
  5517.     return 1;
  5518. }
  5519.  
  5520. CMD:teams(playerid)
  5521. {
  5522.     new string[144];
  5523.     for(new i; i < sizeof(gTeam); i++)
  5524.     {
  5525.         format(string, sizeof(string), "* Team %s::%i | Players: %i | Flags: %i/%i", gTeam[i][E_NAME], (i + 1), CountTeamPlayers(i), CountTeamFlags(i), sizeof(gCaptureZone));
  5526.         SendClientMessage(playerid, gTeam[i][E_COLOR], string);
  5527.     }
  5528.     return 1;
  5529. }
  5530.  
  5531. CMD:myteam(playerid)
  5532. {
  5533.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5534.  
  5535.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5536.  
  5537.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  5538.  
  5539.     new string[144];
  5540.     format(string, sizeof(string), "* You are playing as team %s::%i | Players: %i | Flags: %i/%i", gTeam[GetPlayerTeam(playerid)][E_NAME], (GetPlayerTeam(playerid) + 1), CountTeamPlayers(GetPlayerTeam(playerid)), CountTeamFlags(GetPlayerTeam(playerid)), sizeof(gCaptureZone));
  5541.     SendClientMessage(playerid, gTeam[GetPlayerTeam(playerid)][E_COLOR], string);
  5542.     return 1;
  5543. }
  5544.  
  5545. CMD:sync(playerid)
  5546. {
  5547.     if(IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't synchronize in a vehicle.");
  5548.  
  5549.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't synchronize when you aren't spawned.");
  5550.  
  5551.     if(IsPlayerNearEnemies(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't use this command near enemies.");
  5552.  
  5553.     SyncPlayer(playerid);
  5554.     SendClientMessage(playerid, COLOR_SEA_GREEN, "* You have been synchronized by your request.");
  5555.     return 1;
  5556. }
  5557.  
  5558. CMD:pos(playerid)
  5559. {
  5560.     new Float:x, Float:y, Float:z, Float:a;
  5561.     GetPlayerPos(playerid, x, y, z);
  5562.     GetPlayerFacingAngle(playerid, a);
  5563.  
  5564.     new string[144];
  5565.     format(string, sizeof(string), "Your position | X: %0.4f | Y: %0.4f | Z: %0.4f | A: %0.4f | Interior: %d | VirtualWorld: %d", x, y, z, a, GetPlayerInterior(playerid), GetPlayerVirtualWorld(playerid));
  5566.     SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  5567.     return 1;
  5568. }
  5569.  
  5570. CMD:givegun(playerid, params[])
  5571. {
  5572.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5573.  
  5574.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5575.  
  5576.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  5577.  
  5578.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't give guns when you aren't spawned.");
  5579.  
  5580.     new target, ammo;
  5581.     if(sscanf(params, "ui", target, ammo)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /givegun [player] [ammo]");
  5582.  
  5583.     if(ammo < 1) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The ammo limit must be greater than 0.");
  5584.  
  5585.     if(! IsPlayerConnected(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not connected.");
  5586.  
  5587.     new Float:pos[3];
  5588.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  5589.     if(! IsPlayerInRangeOfPoint(target, 5.0, pos[0], pos[1], pos[2])) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not near you.");
  5590.  
  5591.     if(GetPlayerWeapon(playerid) == 0) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't give your fist!");
  5592.  
  5593.     if(GetPlayerAmmo(playerid) < ammo) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Your weapon don't have that much ammo.");
  5594.  
  5595.     if(target == playerid) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't give weapons to yourself.");
  5596.  
  5597.     new weaponname[30];
  5598.     GetWeaponName(GetPlayerWeapon(playerid), weaponname, sizeof(weaponname));
  5599.     switch(GetPlayerWeapon(playerid))
  5600.     {
  5601.         case 0..15: ammo = 1;
  5602.     }
  5603.     GivePlayerWeapon(playerid, GetPlayerWeapon(playerid), - ammo);
  5604.     GivePlayerWeapon(target, GetPlayerWeapon(playerid), ammo);
  5605.  
  5606.     new string[144];
  5607.     format(string, sizeof(string), "* %s(%i) have given you a %s with %i ammo.", ReturnPlayerName(playerid), playerid, weaponname, ammo);
  5608.     SendClientMessage(target, COLOR_SEA_GREEN, string);
  5609.     format(string, sizeof(string), "* You have given %s(%i) a %s with %i ammo.", ReturnPlayerName(target), target, weaponname, ammo);
  5610.     SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  5611.     NotifyPlayer(playerid, "~g~Weapon recieved", 5000);
  5612.     return 1;
  5613. }
  5614.  
  5615. CMD:givemoney(playerid, params[])
  5616. {
  5617.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't transfer money when you aren't spawned.");
  5618.  
  5619.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5620.  
  5621.     new target, amount;
  5622.     if(sscanf(params, "ui", target, amount)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /givemoney [player] [amount]");
  5623.  
  5624.     if(amount < 1) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The amount limit must be greater than 0.");
  5625.  
  5626.     if(! IsPlayerConnected(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not connected.");
  5627.  
  5628.     new Float:pos[3];
  5629.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  5630.     if(! IsPlayerInRangeOfPoint(target, 5.0, pos[0], pos[1], pos[2])) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not near you.");
  5631.  
  5632.     if(GetPlayerMoney(playerid) < amount) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You yourself don't have that much money.");
  5633.  
  5634.     if(target == playerid) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't give money to yourself.");
  5635.  
  5636.     GivePlayerMoney(playerid, - amount);
  5637.     GivePlayerMoney(target, amount);
  5638.  
  5639.     new string[144];
  5640.     format(string, sizeof(string), "* %s(%i) have given you %i$.", ReturnPlayerName(playerid), playerid, amount);
  5641.     SendClientMessage(target, COLOR_SEA_GREEN, string);
  5642.     format(string, sizeof(string), "* You have given %s(%i), %i$.", ReturnPlayerName(target), target, amount);
  5643.     SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  5644.     NotifyPlayer(playerid, "~g~Money($) recieved", 5000);
  5645.     return 1;
  5646. }
  5647.  
  5648. CMD:rules(playerid)
  5649. {
  5650.     new dialogstr[1024];
  5651.     strcat(dialogstr, ""WHITE"These are general server rules, if you think we missed some, just keep that in mind\n");
  5652.     strcat(dialogstr, "as a rule and don't break it! We will add it soon!\n\n");
  5653.     strcat(dialogstr, ""RED"1. "LIGHT_BLUE"Never make use of cheats, hacks or methods of unfair gameplay.\n");
  5654.     strcat(dialogstr, ""RED"2. "LIGHT_BLUE"Always respect every player and admin, dont provoke others.\n");
  5655.     strcat(dialogstr, ""RED"3. "LIGHT_BLUE"Any sort of level boosting is strictly restricted. This may include:\n");
  5656.     strcat(dialogstr, ""RED"    - "LIGHT_BLUE"Score boosting\n");
  5657.     strcat(dialogstr, ""RED"    - "LIGHT_BLUE"Money boosting\n");
  5658.     strcat(dialogstr, ""RED"    - "LIGHT_BLUE"Kills/Deaths boosting\n");
  5659.     strcat(dialogstr, ""RED"4. "LIGHT_BLUE"Dont unnecessarly PM. or send messages to players.\n");
  5660.     strcat(dialogstr, ""RED"5. "LIGHT_BLUE"Advertisements are not allowed, not in chat and PMs.\n");
  5661.     strcat(dialogstr, ""RED". "LIGHT_BLUE"If you have applied for admin on forums, then dont ask users to support.\n");
  5662.     strcat(dialogstr, ""RED"7. "LIGHT_BLUE"Don't misuse your admin or donor commands if provided.\n");
  5663.     strcat(dialogstr, ""RED"8. "LIGHT_BLUE"Play as a faithfull, trustworthy, and friendly user.\n\n");
  5664.     strcat(dialogstr, ""RED"NOTE: "WHITE"Violation of any of these rule can get you BAN, KICK, WARN, TEMPBAN...");
  5665.  
  5666.     ShowPlayerDialog(playerid, DIALOG_COMMON, DIALOG_STYLE_MSGBOX, "Server rules", dialogstr, "Close", "");
  5667.     return 1;
  5668. }
  5669.  
  5670. CMD:zonehelp(playerid)
  5671. {
  5672.     new dialogstr[656];
  5673.     strcat(dialogstr, ""WHITE"The server has its own advance capturing zone system!\n");
  5674.     strcat(dialogstr, "In order to capture zones, you have to follow the steps:\n\n");
  5675.     strcat(dialogstr, ""RED"1. "LIGHT_BLUE"You see a flag mapicon overlaped witha Checkpoint. Go to any one with enemy colored gangzone.\n");
  5676.     strcat(dialogstr, ""RED"2. "LIGHT_BLUE"Stay in the checkpoint for "#CAPTUR_TIME" seconds and cover yourself from enemies (if any).\n");
  5677.     strcat(dialogstr, ""RED"3. "LIGHT_BLUE"Once the time is completed, you will get a notification and will given a reward for the capture.\n\n");
  5678.     strcat(dialogstr, ""WHITE"For more help, ask an admin for help.");
  5679.  
  5680.     ShowPlayerDialog(playerid, DIALOG_COMMON, DIALOG_STYLE_MSGBOX, "Capture zones help", dialogstr, "Close", "");
  5681.     return 1;
  5682. }
  5683.  
  5684. CMD:zones(playerid)
  5685. {
  5686.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5687.  
  5688.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5689.  
  5690.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  5691.  
  5692.     new dialogstr[42];
  5693.     new DIALOG[1024];
  5694.     for(new i; i < sizeof(gCaptureZone); i++)
  5695.     {
  5696.         if(! gCaptureZone[i][E_ZONEATTACKED])
  5697.         {
  5698.             if(gCaptureZone[i][E_ZONEOWNER] == GetPlayerTeam(playerid))
  5699.             {
  5700.                 format(dialogstr, sizeof(dialogstr), "%s(%i)\n", gCaptureZone[i][E_ZONENAME], i);
  5701.                 strcat(DIALOG, dialogstr);
  5702.             }
  5703.         }
  5704.     }
  5705.  
  5706.     if(! strlen(DIALOG)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Your team don't own any capture zone.");
  5707.  
  5708.     ShowPlayerDialog(playerid, DIALOG_COMMON, DIALOG_STYLE_LIST, "Zones owned by your team", DIALOG, "Close", "");
  5709.     return 1;
  5710. }
  5711.  
  5712. CMD:findwar(playerid)
  5713. {
  5714.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5715.  
  5716.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5717.  
  5718.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  5719.  
  5720.     new dialogstr[356];
  5721.     new DIALOG[2500];
  5722.     for(new i; i < sizeof(gCaptureZone); i++)
  5723.     {
  5724.         if(gCaptureZone[i][E_ZONEATTACKED])
  5725.         {
  5726.             if(gCaptureZone[i][E_ZONEOWNER] == GetPlayerTeam(playerid) || GetPlayerTeam(gCaptureZone[i][E_ZONEATTACKER]) == GetPlayerTeam(playerid))
  5727.             {
  5728.                 format(dialogstr, sizeof(dialogstr), "%s(%i) - %s attacking %s's zone\n", gCaptureZone[i][E_ZONENAME], i, gTeam[ gCaptureZone[i][E_ZONEATTACKER] ][E_NAME], gTeam[ gCaptureZone[i][E_ZONEOWNER] ][E_NAME]);
  5729.                 strcat(DIALOG, dialogstr);
  5730.             }
  5731.         }
  5732.     }
  5733.  
  5734.     if(! strlen(DIALOG)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Your team don't have any capture zone under attack.");
  5735.  
  5736.     ShowPlayerDialog(playerid, DIALOG_COMMON, DIALOG_STYLE_LIST, "Zones under attack by your team", DIALOG, "Close", "");
  5737.     return 1;
  5738. }
  5739.  
  5740. CMD:sc(playerid)
  5741. {
  5742.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5743.  
  5744.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5745.  
  5746.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  5747.  
  5748.     if(GetPlayerTeam(playerid) == 7) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Africa team can't use this command.");
  5749.  
  5750.     if(! gClassSelection[playerid])
  5751.     {
  5752.         gClassSelection[playerid] = true;
  5753.         SendClientMessage(playerid, COLOR_OLIVE, "Switching class selection on next death...");
  5754.     }
  5755.     return 1;
  5756. }
  5757.  
  5758. CMD:heal(playerid, params[])
  5759. {
  5760.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5761.  
  5762.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5763.  
  5764.     if(gClass[playerid] != CLASS_MEDIC) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a Medic to heal players.");
  5765.  
  5766.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't give guns when you aren't spawned.");
  5767.  
  5768.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  5769.  
  5770.     new target;
  5771.     if(sscanf(params, "u", target)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /heal [player]");
  5772.  
  5773.     if(! IsPlayerConnected(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not connected.");
  5774.  
  5775.     if(target == playerid) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot heal yourself, use /pk instead.");
  5776.  
  5777.     new Float:pos[3];
  5778.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  5779.     if(! IsPlayerInRangeOfPoint(target, 10.0, pos[0], pos[1], pos[2])) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not near you.");
  5780.  
  5781.     if(GetPlayerTeam(playerid) != GetPlayerTeam(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot heal enemies.");
  5782.  
  5783.     if(gHealed[playerid][target] != -1) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The must wait 30 seconds before healing that specific player again.");
  5784.  
  5785.     new Float:hp;
  5786.     GetPlayerHealth(target, hp);
  5787.     if((hp + 50.0) >= 100.0) SetPlayerHealth(target, 100.0);
  5788.     else SetPlayerHealth(target, hp + 50.0);
  5789.     PlayerPlaySound(playerid, 1133, 0.0, 0.0, 0.0);
  5790.     PlayerPlaySound(target, 1133, 0.0, 0.0, 0.0);
  5791.  
  5792.     gHealed[playerid][target] = SetTimerEx("OnPlayerHealExpire", 30 * 1000, false, "ii", playerid, target);
  5793.  
  5794.     new string[144];
  5795.     format(string, sizeof(string), "* %s(%i) have healed you with 50.0 health.", ReturnPlayerName(playerid), playerid);
  5796.     SendClientMessage(target, COLOR_SEA_GREEN, string);
  5797.     format(string, sizeof(string), "%s(%i) healed you with 50.0 HP.", ReturnPlayerName(playerid), playerid);
  5798.     NotifyPlayer(target, string, 5000);
  5799.     format(string, sizeof(string), "* You have healed ~b~~h~~h~~h~%s(%i) ~w~~h~with 50.0 health.", ReturnPlayerName(target), target);
  5800.     SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  5801.     format(string, sizeof(string), "Healed ~b~~h~~h~~h~%s(%i) ~w~~h~for 50.0 HP.", ReturnPlayerName(target), target);
  5802.     NotifyPlayer(playerid, string, 5000);
  5803.     return 1;
  5804. }
  5805.  
  5806. CMD:jp(playerid)
  5807. {
  5808.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5809.  
  5810.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5811.  
  5812.     if(gClass[playerid] != CLASS_JETRUNNER) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a Jetrunner to activate jetpack.");
  5813.  
  5814.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't activate jetpack when you aren't spawned.");
  5815.  
  5816.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  5817.  
  5818.     if(IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't use this command while in a vehicle.");
  5819.  
  5820.     SetPlayerSpecialAction(playerid, SPECIAL_ACTION_USEJETPACK);
  5821.     PlayerPlaySound(playerid, 1133, 0.0, 0.0, 0.0);
  5822.     NotifyPlayer(playerid, "You have activated your Jetpack", 5000);
  5823.     return 1;
  5824. }
  5825.  
  5826. CMD:dis(playerid)
  5827. {
  5828.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5829.  
  5830.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5831.  
  5832.     if(gClass[playerid] != CLASS_SPY) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a Spy to disguize.");
  5833.  
  5834.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't disguize when you aren't spawned.");
  5835.  
  5836.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  5837.  
  5838.     if(gDis[playerid] <= 0) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You have no clothes left in your disguize kit. Go to shop and buy one!");
  5839.  
  5840.     if(IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't use this command while in a vehicle.");
  5841.  
  5842.     new dialogstr[556], string[145];
  5843.     for(new i; i < sizeof(gTeam); i++)
  5844.     {
  5845.         format(string, sizeof(string), "{%06x}%s\n", ( gTeam[i][E_COLOR] >>> 8 ), gTeam[i][E_NAME]);
  5846.         strcat(dialogstr, string);
  5847.     }
  5848.     ShowPlayerDialog(playerid, DIALOG_DIS, DIALOG_STYLE_LIST, "Disguize kit", dialogstr, "Disguize", "Cancel");
  5849.     return 1;
  5850. }
  5851.  
  5852. CMD:undis(playerid)
  5853. {
  5854.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5855.  
  5856.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5857.  
  5858.     if(gClass[playerid] != CLASS_SPY) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a Spy to undisguize.");
  5859.  
  5860.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't undisguize when you aren't spawned.");
  5861.  
  5862.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  5863.  
  5864.     if(GetPlayerSkin(playerid) == gTeam[GetPlayerTeam(playerid)][E_SKIN]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You are already undisguized.");
  5865.  
  5866.     if(IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't use this command while in a vehicle.");
  5867.  
  5868.     SetPlayerSkin(playerid, gTeam[GetPlayerTeam(playerid)][E_SKIN]);
  5869.     SetPlayerColor(playerid, gTeam[GetPlayerTeam(playerid)][E_COLOR]);
  5870.  
  5871.     new string[145];
  5872.     format(string, sizeof(string), "You have undisguized to your team {%06x}%s", ( gTeam[GetPlayerTeam(playerid)][E_COLOR] >>> 8 ), gTeam[GetPlayerTeam(playerid)][E_NAME]);
  5873.     NotifyPlayer(playerid, string, 5000);
  5874.     return 1;
  5875. }
  5876.  
  5877. CMD:rob(playerid, params[])
  5878. {
  5879.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5880.  
  5881.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5882.  
  5883.     if(gClass[playerid] != CLASS_SPY) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a Spy to rob players.");
  5884.  
  5885.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't rob when you aren't spawned.");
  5886.  
  5887.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  5888.  
  5889.     new target;
  5890.     if(sscanf(params, "u", target)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /rob [player]");
  5891.  
  5892.     if(! IsPlayerConnected(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not connected.");
  5893.  
  5894.     if(target == playerid) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot rob yourself.");
  5895.  
  5896.     new Float:pos[3];
  5897.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  5898.     if(! IsPlayerInRangeOfPoint(target, 3.0, pos[0], pos[1], pos[2])) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not near you.");
  5899.  
  5900.     if(GetPlayerTeam(target) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command on that player right now.");
  5901.  
  5902.     if(GetPlayerTeam(playerid) == GetPlayerTeam(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot rob team mates.");
  5903.  
  5904.     switch(random(4))
  5905.     {
  5906.         case 1://fail
  5907.         {
  5908.             SetPlayerSkin(playerid, gTeam[GetPlayerTeam(playerid)][E_SKIN]);
  5909.             SetPlayerColor(playerid, gTeam[GetPlayerTeam(playerid)][E_COLOR]);
  5910.             NotifyPlayer(playerid, "You have have been detected as a ~r~SPY~w~~h~!", 5000);
  5911.         }
  5912.         default://success
  5913.         {
  5914.             new money = (1000 + random(500));
  5915.             GivePlayerMoney(playerid, money);
  5916.             GivePlayerMoney(target, - money);
  5917.  
  5918.             new string[145];
  5919.             format(string, sizeof(string), "You have robbed ~b~~h~~h~~h~%s(%i) ~w~~h~(~g~+ %i$~w~~h~)", ReturnPlayerName(target), target, money);
  5920.             NotifyPlayer(playerid, string, 5000);
  5921.         }
  5922.     }
  5923.     PlayerPlaySound(playerid, 1133, 0.0, 0.0, 0.0);
  5924.     return 1;
  5925. }
  5926.  
  5927. CMD:help(playerid)
  5928. {
  5929.     ShowPlayerDialog(playerid, DIALOG_HELP, DIALOG_STYLE_LIST, "Server helpline", "How to play?\nHow to reduce PING?\nHow to unlock new stuff?\nHow to be a Donor?\nHow to be an Admin?\nAbout gamemode\nAbout server\nAbout capture zones\nGetting started...\nServer Rules...", "Open", "Close");
  5930.     return 1;
  5931. }
  5932. CMD:h(playerid) return cmd_help(playerid);
  5933.  
  5934. CMD:cmds(playerid)
  5935. {
  5936.     new dialogstr[1024];
  5937.     strcat(dialogstr, ""YELLOW"GENERAL COMMANDS:\n");
  5938.     strcat(dialogstr, ""LIGHT_BLUE"/help, /rules, /cmds, /kill, /rules, /zonehelp, /time, /sync, /pos, /shout ...\n\n");
  5939.     strcat(dialogstr, ""YELLOW"TEAM & ZONE COMMANDS\n");
  5940.     strcat(dialogstr, ""LIGHT_BLUE"/myteam, /teams, /radio, /zones, /findwar, /zonehelp, /ss ...\n\n");
  5941.     strcat(dialogstr, ""YELLOW"CLASS COMMANDS\n");
  5942.     strcat(dialogstr, ""LIGHT_BLUE"/chelp, /sc, /ccmds, /heal, /pk, /jp, /dis, /undis, /rob ...\n\n");
  5943.     strcat(dialogstr, ""YELLOW"USEFUL COMMANDS\n");
  5944.     strcat(dialogstr, ""LIGHT_BLUE"/login, /register, /changename, /admins, /donors, /report, /autologin, stats,\n");
  5945.     strcat(dialogstr, ""LIGHT_BLUE"/pm, /nopm, /dnd, /reply, /acmds, /givegun, /givemoney, /sc, /st, /shout.\n");
  5946.     strcat(dialogstr, ""LIGHT_BLUE"/times, /players, /ranks, /rank, /rhelp, /dm, /prestige, /myprestige, /resetprestige ...\n\n");
  5947.     strcat(dialogstr, ""YELLOW"DEATHMATCH COMMANDS\n");
  5948.     strcat(dialogstr, ""LIGHT_BLUE"/minigun, /moneybag, /glass, /rpg, /exit, /dm ...\n\n");
  5949.     strcat(dialogstr, ""YELLOW"INVENTORY COMMANDS\n");
  5950.     strcat(dialogstr, ""LIGHT_BLUE"/helmet, /givehelmet, /pk, /givepk, /armour, /givearmour, /mask, /givemask,\n");
  5951.     strcat(dialogstr, ""LIGHT_BLUE"/bomb, /givebomb, (Press KEY_YES<y key> to open inventory dialog) ...\n\n");
  5952.     strcat(dialogstr, ""YELLOW"DONOR COMMANDS\n");
  5953.     strcat(dialogstr, ""LIGHT_BLUE"/dhelp, /dcmds, /dguns, /dammo, /dskin, /dlabel, /dbike, /dsupply ...\n\n");
  5954.     strcat(dialogstr, ""WHITE"If you need any sort of help related to game, contact a mature player or an admin!");
  5955.  
  5956.     ShowPlayerDialog(playerid, DIALOG_COMMON, DIALOG_STYLE_MSGBOX, "Server commands list", dialogstr, "Close", "");
  5957.     return 1;
  5958. }
  5959. CMD:c(playerid) return cmd_cmds(playerid);
  5960. CMD:commands(playerid) return cmd_cmds(playerid);
  5961.  
  5962. CMD:st(playerid)
  5963. {
  5964.     if(ForceClassSelection(playerid))
  5965.     {
  5966.         SendClientMessage(playerid, COLOR_OLIVE, "Switching team selection on next death...");
  5967.     }
  5968.     return 1;
  5969. }
  5970.  
  5971. CMD:times(playerid)
  5972. {
  5973.     new string[148];
  5974.     format(string, sizeof(string), "- Anthrax, ready to use in %i seconds", gAnthrax[ANTHRAX_TIME]);
  5975.     SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  5976.     format(string, sizeof(string), "- Nuke, ready to use in %i seconds", gNuke[NUKE_TIME]);
  5977.     SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  5978.     return 1;
  5979. }
  5980.  
  5981. CMD:players(playerid)
  5982. {
  5983.     new string[148];
  5984.     format(string, sizeof(string), "Players Summary: TDM: %i | Minigun DM: %i/15 | Moneybag DM: %i/15 | RPG DM: %i/15 | Glass DM: %i/15", CountEventPlayers(MODE_TEAM_DEATHMATCH), CountEventPlayers(MODE_MINIGUN), CountEventPlayers(MODE_MONEYBAG), CountEventPlayers(MODE_RPG), CountEventPlayers(MODE_GLASS));
  5985.     SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  5986.     return 1;
  5987. }
  5988.  
  5989. CMD:minigun(playerid, params[])
  5990. {
  5991.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5992.  
  5993.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  5994.  
  5995.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  5996.  
  5997.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be spawned to join minigun deathmatch.");
  5998.  
  5999.     if(IsPlayerNearEnemies(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't use this command near enemies.");
  6000.  
  6001.     if(CountEventPlayers(MODE_MINIGUN) > 15) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The deathmatch is full of players, please try again some other time.");
  6002.  
  6003.     new skin;
  6004.     if(sscanf(params, "i", skin))
  6005.     {
  6006.         skin = random(299);
  6007.         SendClientMessage(playerid, COLOR_AQUA, "TIP: You can also use /minigun [skin*] to have a cusdtom skin for deathmatch.");
  6008.     }
  6009.     else if(skin < 0 || skin > 299) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Invalid skin id, must be b/w 0-299.");
  6010.  
  6011.     gPlayerSkin[playerid] = skin;
  6012.     gPlayerGamemode[playerid] = MODE_MINIGUN;
  6013.  
  6014.     new string[148];
  6015.     format(string, sizeof(string), "* %s(%i) have joined /minigun madness deathmatch [Total players: %i]", ReturnPlayerName(playerid), playerid, CountEventPlayers(MODE_MINIGUN));
  6016.     SendClientMessageToAll(COLOR_STEEL_BLUE, string);
  6017.     format(string, sizeof(string), "~r~~h~~h~~h~%s(%i) is now participating in /minigun deathmatch with %i other players. Join in if you want to change gamemode!", ReturnPlayerName(playerid), playerid, CountEventPlayers(MODE_MINIGUN));
  6018.     TextDrawSetString(gAnnouncementTD, string);
  6019.  
  6020.     //our fading effect on screen!
  6021.     FadeColorForPlayer(playerid, 0, 0, 0, 200, 0, 0, 0, 0, 20, 10);
  6022.  
  6023.     CallLocalFunction("OnPlayerSpawn", "i", playerid);
  6024.     return 1;
  6025. }
  6026.  
  6027. CMD:moneybag(playerid, params[])
  6028. {
  6029.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6030.  
  6031.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6032.  
  6033.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6034.  
  6035.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be spawned to join moneybag deathmatch.");
  6036.  
  6037.     if(IsPlayerNearEnemies(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't use this command near enemies.");
  6038.  
  6039.     if(CountEventPlayers(MODE_MONEYBAG) > 15) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The deathmatch is full of players, please try again some other time.");
  6040.  
  6041.     new skin;
  6042.     if(sscanf(params, "i", skin))
  6043.     {
  6044.         skin = random(299);
  6045.         SendClientMessage(playerid, COLOR_AQUA, "TIP: You can also use /moneybag [skin*] to have a cusdtom skin for deathmatch.");
  6046.     }
  6047.     else if(skin < 0 || skin > 299) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Invalid skin id, must be b/w 0-299.");
  6048.  
  6049.     gPlayerSkin[playerid] = skin;
  6050.     gPlayerGamemode[playerid] = MODE_MONEYBAG;
  6051.  
  6052.     new string[148];
  6053.     format(string, sizeof(string), "* %s(%i) have joined moneybag hunt deathmatch [Total players: %i]", ReturnPlayerName(playerid), playerid, CountEventPlayers(MODE_MONEYBAG));
  6054.     SendClientMessageToAll(COLOR_STEEL_BLUE, string);
  6055.     format(string, sizeof(string), "~r~~h~~h~~h~%s(%i) is now participating in /moneybag hunt deathmatch with %i other players. Join in if you want to change gamemode!", ReturnPlayerName(playerid), playerid, CountEventPlayers(MODE_MONEYBAG));
  6056.     TextDrawSetString(gAnnouncementTD, string);
  6057.  
  6058.     //our fading effect on screen!
  6059.     FadeColorForPlayer(playerid, 0, 0, 0, 200, 0, 0, 0, 0, 20, 10);
  6060.  
  6061.     CallLocalFunction("OnPlayerSpawn", "i", playerid);
  6062.     return 1;
  6063. }
  6064.  
  6065. CMD:rpg(playerid, params[])
  6066. {
  6067.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6068.  
  6069.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6070.  
  6071.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6072.  
  6073.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be spawned to join RPG deathmatch.");
  6074.  
  6075.     if(IsPlayerNearEnemies(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't use this command near enemies.");
  6076.  
  6077.     if(CountEventPlayers(MODE_RPG) > 15) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The deathmatch is full of players, please try again some other time.");
  6078.  
  6079.     new skin;
  6080.     if(sscanf(params, "i", skin))
  6081.     {
  6082.         skin = random(299);
  6083.         SendClientMessage(playerid, COLOR_AQUA, "TIP: You can also use /rpg [skin*] to have a cusdtom skin for deathmatch.");
  6084.     }
  6085.     else if(skin < 0 || skin > 299) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Invalid skin id, must be b/w 0-299.");
  6086.  
  6087.     gPlayerSkin[playerid] = skin;
  6088.     gPlayerGamemode[playerid] = MODE_RPG;
  6089.  
  6090.     new string[148];
  6091.     format(string, sizeof(string), "* %s(%i) have joined RPG deathmatch [Total players: %i]", ReturnPlayerName(playerid), playerid, CountEventPlayers(MODE_RPG));
  6092.     SendClientMessageToAll(COLOR_STEEL_BLUE, string);
  6093.     format(string, sizeof(string), "~r~~h~~h~~h~%s(%i) is now participating in /rpg deathmatch with %i other players. Join in if you want to change gamemode!", ReturnPlayerName(playerid), playerid, CountEventPlayers(MODE_RPG));
  6094.     TextDrawSetString(gAnnouncementTD, string);
  6095.  
  6096.     //our fading effect on screen!
  6097.     FadeColorForPlayer(playerid, 0, 0, 0, 200, 0, 0, 0, 0, 20, 10);
  6098.  
  6099.     CallLocalFunction("OnPlayerSpawn", "i", playerid);
  6100.     return 1;
  6101. }
  6102.  
  6103. CMD:glass(playerid, params[])
  6104. {
  6105.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6106.  
  6107.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6108.  
  6109.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6110.  
  6111.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be spawned to join Glass deathmatch.");
  6112.  
  6113.     if(IsPlayerNearEnemies(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't use this command near enemies.");
  6114.  
  6115.     if(CountEventPlayers(MODE_GLASS) > 15) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The deathmatch is full of players, please try again some other time.");
  6116.  
  6117.     new skin;
  6118.     if(sscanf(params, "i", skin))
  6119.     {
  6120.         skin = random(299);
  6121.         SendClientMessage(playerid, COLOR_AQUA, "TIP: You can also use /glass [skin*] to have a cusdtom skin for deathmatch.");
  6122.     }
  6123.     else if(skin < 0 || skin > 299) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Invalid skin id, must be b/w 0-299.");
  6124.  
  6125.     gPlayerSkin[playerid] = skin;
  6126.     gPlayerGamemode[playerid] = MODE_GLASS;
  6127.  
  6128.     new string[148];
  6129.     format(string, sizeof(string), "* %s(%i) have joined Glass break deathmatch [Total players: %i]", ReturnPlayerName(playerid), playerid, CountEventPlayers(MODE_GLASS));
  6130.     SendClientMessageToAll(COLOR_STEEL_BLUE, string);
  6131.     format(string, sizeof(string), "~r~~h~~h~~h~%s(%i) is now participating in /Glass break deathmatch with %i other players. Join in if you want to change gamemode!", ReturnPlayerName(playerid), playerid, CountEventPlayers(MODE_GLASS));
  6132.     TextDrawSetString(gAnnouncementTD, string);
  6133.  
  6134.     //our fading effect on screen!
  6135.     FadeColorForPlayer(playerid, 0, 0, 0, 200, 0, 0, 0, 0, 20, 10);
  6136.  
  6137.     CallLocalFunction("OnPlayerSpawn", "i", playerid);
  6138.     return 1;
  6139. }
  6140.  
  6141. CMD:exit(playerid)
  6142. {
  6143.     if(gPlayerGamemode[playerid] == MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in a deathmatch to use this command.");
  6144.  
  6145.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6146.  
  6147.     if(GetPlayerTeam(playerid) == 100) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6148.  
  6149.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be spawned to leave a deathmatch.");
  6150.  
  6151.     gPlayerGamemode[playerid] = MODE_TEAM_DEATHMATCH;
  6152.    
  6153.     gPlayerSkin[playerid] = gTeam[gPlayerTeam[playerid]][E_SKIN];
  6154.     SetPlayerTeam(playerid, gPlayerTeam[playerid]);
  6155.     SetPlayerHealth(playerid, 0.0);
  6156.     return 1;
  6157. }
  6158.  
  6159. CMD:ranks(playerid)
  6160. {
  6161.     new string[156], dialogstr[sizeof(string) * sizeof(gRank)];
  6162.     strcat(dialogstr, "Rank\tRank name\tScore\n");
  6163.     for(new i; i < sizeof(gRank); i++)
  6164.     {
  6165.         if(GetPlayerRank(playerid) >= i) format(string, sizeof(string), ""LIGHT_BLUE"%i.\t"LIGHT_BLUE"%s\t"LIGHT_BLUE"%i+ score\n", i, gRank[i][r_name], gRank[i][r_score]);
  6166.         else format(string, sizeof(string), ""GRAY"%i.\t"GRAY"%s\t"GRAY"%i+ score\n", i, gRank[i][r_name], gRank[i][r_score]);
  6167.         strcat(dialogstr, string);
  6168.     }
  6169.     ShowPlayerDialog(playerid, DIALOG_COMMON, DIALOG_STYLE_TABLIST_HEADERS, "Ranks list", dialogstr, "Close", "");
  6170.     return 1;
  6171. }
  6172.  
  6173. CMD:rank(playerid)
  6174. {
  6175.     new string[144];
  6176.     new rank = GetPlayerRank(playerid);
  6177.     new target = (rank + 1);
  6178.     if(target >= sizeof(gRank)) target = (sizeof(gRank) - 1);
  6179.     format(string, sizeof(string), "You are currently rank %i, %s (%i/%i score)", rank, gRank[rank][r_name], GetPlayerScore(playerid), gRank[target][r_score]);
  6180.     SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  6181.     return 1;
  6182. }
  6183.  
  6184. CMD:rhelp(playerid)
  6185. {
  6186.     new dialogstr[656];
  6187.     strcat(dialogstr, ""LIGHT_BLUE"Unlocking new stuff and gaining new ranks will obviously require you with some cash and score.\n\n");
  6188.     strcat(dialogstr, "The server provides you with loads of ways to earn:\n");
  6189.     strcat(dialogstr, ""RED"1. "LIGHT_BLUE"Kill the enemy teams\n");
  6190.     strcat(dialogstr, ""RED"2. "LIGHT_BLUE"Capture enemy zones\n");
  6191.     strcat(dialogstr, ""RED"3. Steel the enemy prototype vehicle\n");
  6192.     strcat(dialogstr, ""RED"4. Participate in events\n\n");
  6193.     strcat(dialogstr, "After you have your desired ammount, go to shops and buy as much you can,\n");
  6194.     strcat(dialogstr, "there's always something new in the shops.\n\n");
  6195.     strcat(dialogstr, ""WHITE"On every rank up, you get the chance to try new classes, buy new weapons or get bonouses.");
  6196.  
  6197.     ShowPlayerDialog(playerid, DIALOG_COMMON, DIALOG_STYLE_MSGBOX, "Rank help", dialogstr, "Close", "");
  6198.     return 1;
  6199. }
  6200.  
  6201. CMD:ccmds(playerid)
  6202. {
  6203.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6204.  
  6205.     if(GetPlayerTeam(playerid) == 7) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Africa team can't use this command.");
  6206.  
  6207.     new string[144];
  6208.     switch(gClass[playerid])
  6209.     {
  6210.         case 1: SendClientMessage(playerid, COLOR_KHAKI, "Class Medic's commands | /heal - heal other players, /pk - painkillers (spawned with 3 pks).");
  6211.         case 3: SendClientMessage(playerid, COLOR_KHAKI, "Class Jetrunner's commands | /jp - activate jetpack.");
  6212.         case 5: SendClientMessage(playerid, COLOR_KHAKI, "Class Spy's commands | /rob - rob a enemy in vehicle(as passenger), /dis - disguize to enemy skin & color, /undis - undisguize back to team skin & color.");
  6213.         default:
  6214.         {
  6215.             format(string, sizeof(string), "Class %s's commands | There are no special commands for this class.", ReturnPlayerClassName(playerid));
  6216.             SendClientMessage(playerid, COLOR_KHAKI, string);
  6217.         }
  6218.     }
  6219.     return 1;
  6220. }
  6221.  
  6222. CMD:chelp(playerid)
  6223. {
  6224.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6225.  
  6226.     if(GetPlayerTeam(playerid) == 7) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Africa team can't use this command.");
  6227.  
  6228.     new string[144];
  6229.     SendClientMessage(playerid, COLOR_KHAKI, " ");
  6230.     format(string, sizeof(string), "Class %s", ReturnPlayerClassName(playerid));
  6231.     SendClientMessage(playerid, COLOR_KHAKI, string);
  6232.     switch(gClass[playerid])
  6233.     {
  6234.         case 0:
  6235.         {
  6236.             SendClientMessage(playerid, COLOR_KHAKI, "* Commands: There are no special commands for this class.");
  6237.             SendClientMessage(playerid, COLOR_KHAKI, "* Abilities: Good in team attacks.");
  6238.         }
  6239.         case 1:
  6240.         {
  6241.             SendClientMessage(playerid, COLOR_KHAKI, "* Commands: /heal - heal other players, /pk - painkillers (spawned with 3 pks).");
  6242.             SendClientMessage(playerid, COLOR_KHAKI, "* Abilities: Press MMB (KEY_LOOK_BEHIND) to heal team mates, Spawnes with 3 painkillers.");
  6243.         }
  6244.         case 2:
  6245.         {
  6246.             SendClientMessage(playerid, COLOR_KHAKI, "* Commands: There are no special commands for this class.");
  6247.             SendClientMessage(playerid, COLOR_KHAKI, "* Abilities: Inivisible on mini map or radar, spawns with Sniper rifle.");
  6248.         }
  6249.         case 3:
  6250.         {
  6251.             SendClientMessage(playerid, COLOR_KHAKI, "* Commands: /jp - activate jetpack.");
  6252.             SendClientMessage(playerid, COLOR_KHAKI, "* Abilities: Can spawn or acivate jetpack (/jp).");
  6253.         }
  6254.         case 4:
  6255.         {
  6256.             SendClientMessage(playerid, COLOR_KHAKI, "* Commands: There are no special commands for this class.");
  6257.             SendClientMessage(playerid, COLOR_KHAKI, "* Abilities: Can drive or pilot heavy aircrafts (hunters and hydras).");
  6258.         }
  6259.         case 5:
  6260.         {
  6261.             SendClientMessage(playerid, COLOR_KHAKI, "* Commands: /rob - rob a enemy in vehicle(as passenger), /dis - disguize to enemy skin & color, /undis - undisguize back to team skin & color.");
  6262.             SendClientMessage(playerid, COLOR_KHAKI, "* Abilities: Press 2 (KEY_SUBMISSION) to stabb enemies in vehicles (stabb drivers as passenger).");
  6263.         }
  6264.         case 6:
  6265.         {
  6266.             SendClientMessage(playerid, COLOR_KHAKI, "* Commands: There are no special commands for this class.");
  6267.             SendClientMessage(playerid, COLOR_KHAKI, "* Abilities: Spawned with minigun!");
  6268.         }
  6269.     }
  6270.     return 1;
  6271. }
  6272.  
  6273. CMD:r(playerid, params[])
  6274. {
  6275.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6276.  
  6277.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6278.  
  6279.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6280.  
  6281.     new message[100];
  6282.     if(sscanf(params, "s[100]", message)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /r [message]");
  6283.  
  6284.     new string[144];
  6285.     format(string, sizeof(string), "[Radio] %i> %s: %s", playerid, ReturnPlayerName(playerid), message);
  6286.     foreach(new i : Player)
  6287.     {
  6288.         if(GetPlayerTeam(i) == GetPlayerTeam(playerid))
  6289.         {
  6290.             SendClientMessage(i, COLOR_CORAL, string);
  6291.         }
  6292.     }
  6293.     SetPlayerChatBubble(playerid, message, COLOR_CORAL, 40.0, 10000);
  6294.     return 1;
  6295. }
  6296. CMD:radio(playerid, params[]) return cmd_r(playerid, params);
  6297.  
  6298. CMD:s(playerid, params[])
  6299. {
  6300.     new message[100];
  6301.     if(sscanf(params, "s[100]", message)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /s [message]");
  6302.  
  6303.     new Float:pos[3];
  6304.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  6305.  
  6306.     new string[144];
  6307.     format(string, sizeof(string), "[Shouts] %i> %s: %s", playerid, ReturnPlayerName(playerid), message);
  6308.     foreach(new i : Player)
  6309.     {
  6310.         if(IsPlayerInRangeOfPoint(i, 20.0, pos[0], pos[1], pos[2]))
  6311.         {
  6312.             if(GetPlayerTeam(i) == GetPlayerTeam(playerid))
  6313.             {
  6314.                 SendClientMessage(i, COLOR_WHITE, string);
  6315.             }
  6316.         }
  6317.     }
  6318.     SetPlayerChatBubble(playerid, message, COLOR_WHITE, 40.0, 10000);
  6319.     return 1;
  6320. }
  6321. CMD:shout(playerid, params[]) return cmd_s(playerid, params);
  6322.  
  6323. CMD:dm(playerid)
  6324. {
  6325.     new dialogstr[656];
  6326.     new string[145];
  6327.     strcat(dialogstr, "Deathmatch\tPlayers\n");
  6328.     format(string, sizeof(string), "Minigun Madness\t%i\n", CountEventPlayers(MODE_MINIGUN));
  6329.     strcat(dialogstr, string);
  6330.     format(string, sizeof(string), "Moneybag hunt\t%i\n", CountEventPlayers(MODE_MONEYBAG));
  6331.     strcat(dialogstr, string);
  6332.     format(string, sizeof(string), "RPG Deathmatch\t%i\n", CountEventPlayers(MODE_RPG));
  6333.     strcat(dialogstr, string);
  6334.     format(string, sizeof(string), "Glass Break\t%i\n", CountEventPlayers(MODE_GLASS));
  6335.     strcat(dialogstr, string);
  6336.     ShowPlayerDialog(playerid, DIALOG_DEATHMATCH, DIALOG_STYLE_TABLIST_HEADERS, "Deathmatch list", dialogstr, "Join", "Close");
  6337.     return 1;
  6338. }
  6339.  
  6340. CMD:givepk(playerid, params[])
  6341. {
  6342.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6343.  
  6344.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6345.  
  6346.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't transfer painkillers when you aren't spawned.");
  6347.  
  6348.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6349.  
  6350.     new target, amount;
  6351.     if(sscanf(params, "ui", target, amount)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /givepk [player] [amount]");
  6352.  
  6353.     if(amount < 1) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The amount limit must be greater than 0.");
  6354.  
  6355.     if(! IsPlayerConnected(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not connected.");
  6356.  
  6357.     new Float:pos[3];
  6358.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  6359.     if(! IsPlayerInRangeOfPoint(target, 5.0, pos[0], pos[1], pos[2])) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not near you.");
  6360.  
  6361.     if(gPainkillers[playerid] < amount) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You yourself don't have that much Painkilers.");
  6362.  
  6363.     if(target == playerid) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't give painkillers to yourself.");
  6364.  
  6365.     gPainkillers[playerid] -= amount;
  6366.     gPainkillers[target] += amount;
  6367.  
  6368.     new string[144];
  6369.     format(string, sizeof(string), "* %s(%i) have given you %i painkiller(s).", ReturnPlayerName(playerid), playerid, amount);
  6370.     SendClientMessage(target, COLOR_SEA_GREEN, string);
  6371.     format(string, sizeof(string), "* You have given %s(%i), %i painkiller(s).", ReturnPlayerName(target), target, amount);
  6372.     SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  6373.     NotifyPlayer(playerid, "~g~Painkillers recieved", 5000);
  6374.     return 1;
  6375. }
  6376.  
  6377. CMD:pk(playerid, params[])
  6378. {
  6379.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6380.  
  6381.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6382.  
  6383.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6384.  
  6385.     if(gPainkillers[playerid] < 1) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have any painkillers in your bag.");
  6386.  
  6387.     gPainkillers[playerid] -= 1;
  6388.  
  6389.     new string[144];
  6390.     format(string, sizeof(string), "* You have consumed a painkiller; You are now left with %i painkillers in your bag.", gPainkillers[playerid]);
  6391.     SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  6392.  
  6393.     new Float:hp;
  6394.     GetPlayerHealth(playerid, hp);
  6395.     if((hp + 30.0) >= 100.0) SetPlayerHealth(playerid, 100.0);
  6396.     else SetPlayerHealth(playerid, (hp + 30.0));
  6397.  
  6398.     NotifyPlayer(playerid, "~g~Health regained (30%)", 5000);
  6399.     ApplyAnimation(playerid, "MEDIC", "CPR", 1.0, 0, 1, 1, 1, 1);
  6400.     return 1;
  6401. }
  6402.  
  6403. CMD:givearmour(playerid, params[])
  6404. {
  6405.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6406.  
  6407.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6408.  
  6409.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't transfer armour when you aren't spawned.");
  6410.  
  6411.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6412.  
  6413.     new target;
  6414.     if(sscanf(params, "u", target)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /givearmour [player]");
  6415.  
  6416.     if(! IsPlayerConnected(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not connected.");
  6417.  
  6418.     new Float:pos[3];
  6419.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  6420.     if(! IsPlayerInRangeOfPoint(target, 5.0, pos[0], pos[1], pos[2])) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not near you.");
  6421.  
  6422.     if(! gArmour[playerid]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have an armour to give.");
  6423.  
  6424.     if(gArmour[target]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player already have an armour.");
  6425.  
  6426.     if(target == playerid) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't give armour to yourself.");
  6427.  
  6428.     gArmour[playerid] = false;
  6429.     gArmour[target] = true;
  6430.  
  6431.     new string[144];
  6432.     format(string, sizeof(string), "* %s(%i) have given you an Armour jacket.", ReturnPlayerName(playerid), playerid);
  6433.     SendClientMessage(target, COLOR_SEA_GREEN, string);
  6434.     format(string, sizeof(string), "* You have given %s(%i),an  Armour jacket.", ReturnPlayerName(target), target);
  6435.     SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  6436.     NotifyPlayer(playerid, "~g~Armour jacket recieved", 5000);
  6437.     return 1;
  6438. }
  6439.  
  6440. CMD:armour(playerid, params[])
  6441. {
  6442.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6443.  
  6444.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6445.  
  6446.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6447.  
  6448.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6449.  
  6450.     if(! gArmour[playerid]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have an Armour in your bag.");
  6451.  
  6452.     gArmour[playerid] = false;
  6453.     SetPlayerArmour(playerid, 100.0);
  6454.  
  6455.     SendClientMessage(playerid, COLOR_SEA_GREEN, "You have used your armour jacket from your bag!");
  6456.  
  6457.     NotifyPlayer(playerid, "You have a ~g~Armour Jacket", 5000);
  6458.     return 1;
  6459. }
  6460.  
  6461. CMD:givehelmet(playerid, params[])
  6462. {
  6463.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6464.  
  6465.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6466.  
  6467.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't transfer Protection helmet when you aren't spawned.");
  6468.  
  6469.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6470.  
  6471.     new target;
  6472.     if(sscanf(params, "u", target)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /givehelmet [player]");
  6473.  
  6474.     if(! IsPlayerConnected(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not connected.");
  6475.  
  6476.     new Float:pos[3];
  6477.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  6478.     if(! IsPlayerInRangeOfPoint(target, 5.0, pos[0], pos[1], pos[2])) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not near you.");
  6479.  
  6480.     if(! gHelmet[playerid]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have a Protection Helmet to give.");
  6481.  
  6482.     if(gHelmet[target]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player already have a Protection Helmet.");
  6483.  
  6484.     if(target == playerid) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't give Protection Helmet to yourself.");
  6485.  
  6486.     gHelmet[playerid] = false;
  6487.     gHelmet[target] = true;
  6488.  
  6489.     switch(GetPlayerSkin(target))
  6490.     {
  6491.         case 24: SetPlayerAttachedObject(target,2,18638,2,0.151999,0.038000,0.000000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 24
  6492.         case 287: SetPlayerAttachedObject(target,2,18638,2,0.128000,0.049999,0.006000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 287
  6493.         case 285: SetPlayerAttachedObject(target,2,18638,2,0.182000,0.035000,0.007000,0.000000,0.000000,0.000000,1.000000,1.069999,1.118999); //skin 285
  6494.         case 111: SetPlayerAttachedObject(target,2,18638,2,0.159999,0.032999,0.000000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 111
  6495.         case 122: SetPlayerAttachedObject(target,2,18638,2,0.148000,0.017000,-0.002999,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 122
  6496.         case 73: SetPlayerAttachedObject(target,2,18638,2,0.148999,0.038999,0.000000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 73
  6497.         case 46: SetPlayerAttachedObject(target,2,18638,2,0.162999,0.035000,0.001000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 46
  6498.         case 102: SetPlayerAttachedObject(target,2,18638,2,0.173000,0.024999,-0.003000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 102
  6499.         default: SetPlayerAttachedObject(target,2,18638,2,0.173000,0.024999,-0.003000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 102
  6500.     }
  6501.     RemovePlayerAttachedObject(playerid, 2);
  6502.  
  6503.     new string[144];
  6504.     format(string, sizeof(string), "* %s(%i) have given you a Protection Helmet.", ReturnPlayerName(playerid), playerid);
  6505.     SendClientMessage(target, COLOR_SEA_GREEN, string);
  6506.     format(string, sizeof(string), "* You have given %s(%i), a Protection Helmet.", ReturnPlayerName(target), target);
  6507.     SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  6508.     NotifyPlayer(playerid, "~g~Protection Helmet recieved", 5000);
  6509.     return 1;
  6510. }
  6511.  
  6512. CMD:helmet(playerid)
  6513. {
  6514.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6515.  
  6516.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6517.  
  6518.     if(! gHelmet[playerid]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have a Protection Helmet.");
  6519.  
  6520.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6521.  
  6522.     if(IsPlayerAttachedObjectSlotUsed(playerid, 2))
  6523.     {
  6524.         RemovePlayerAttachedObject(playerid, 2);
  6525.         SendClientMessage(playerid, COLOR_SEA_GREEN, "* You have DISABLED your Protection helmet.");
  6526.         NotifyPlayer(playerid, "~r~Protection Helmet disabled", 5000);
  6527.     }
  6528.     else
  6529.     {
  6530.         switch(GetPlayerSkin(playerid))
  6531.         {
  6532.             case 24: SetPlayerAttachedObject(playerid,2,18638,2,0.151999,0.038000,0.000000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 24
  6533.             case 287: SetPlayerAttachedObject(playerid,2,18638,2,0.128000,0.049999,0.006000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 287
  6534.             case 285: SetPlayerAttachedObject(playerid,2,18638,2,0.182000,0.035000,0.007000,0.000000,0.000000,0.000000,1.000000,1.069999,1.118999); //skin 285
  6535.             case 111: SetPlayerAttachedObject(playerid,2,18638,2,0.159999,0.032999,0.000000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 111
  6536.             case 122: SetPlayerAttachedObject(playerid,2,18638,2,0.148000,0.017000,-0.002999,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 122
  6537.             case 73: SetPlayerAttachedObject(playerid,2,18638,2,0.148999,0.038999,0.000000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 73
  6538.             case 46: SetPlayerAttachedObject(playerid,2,18638,2,0.162999,0.035000,0.001000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 46
  6539.             case 102: SetPlayerAttachedObject(playerid,2,18638,2,0.173000,0.024999,-0.003000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 102
  6540.             default: SetPlayerAttachedObject(playerid,2,18638,2,0.173000,0.024999,-0.003000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 102
  6541.         }
  6542.         SendClientMessage(playerid, COLOR_SEA_GREEN, "* You have ENABLED your Protection helmet.");
  6543.         NotifyPlayer(playerid, "~g~Protection Helmet enabled", 5000);
  6544.     }
  6545.     return 1;
  6546. }
  6547.  
  6548. CMD:givemask(playerid, params[])
  6549. {
  6550.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6551.  
  6552.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6553.  
  6554.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't transfer Gas Mask when you aren't spawned.");
  6555.  
  6556.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6557.  
  6558.     new target;
  6559.     if(sscanf(params, "u", target)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /givemask [player]");
  6560.  
  6561.     if(! IsPlayerConnected(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not connected.");
  6562.  
  6563.     new Float:pos[3];
  6564.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  6565.     if(! IsPlayerInRangeOfPoint(target, 5.0, pos[0], pos[1], pos[2])) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not near you.");
  6566.  
  6567.     if(! gMask[playerid]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have a Gas Mask to give.");
  6568.  
  6569.     if(gMask[target]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player already have a Gas Mask.");
  6570.  
  6571.     if(target == playerid) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't give Gas Mask to yourself.");
  6572.  
  6573.     gMask[playerid] = false;
  6574.     gMask[target] = true;
  6575.  
  6576.     SetPlayerAttachedObject(target, 3, 19472, 2, -0.022000, 0.137000, 0.018999, 3.899994, 85.999961, 92.999984, 0.923999, 1.141000, 1.026999);
  6577.     RemovePlayerAttachedObject(playerid, 3);
  6578.  
  6579.     new string[144];
  6580.     format(string, sizeof(string), "* %s(%i) have given you a Gas Mask.", ReturnPlayerName(playerid), playerid);
  6581.     SendClientMessage(target, COLOR_SEA_GREEN, string);
  6582.     format(string, sizeof(string), "* You have given %s(%i), a Gas Mask.", ReturnPlayerName(target), target);
  6583.     SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  6584.     NotifyPlayer(playerid, "~g~Gas Mask recieved", 5000);
  6585.     return 1;
  6586. }
  6587.  
  6588. CMD:mask(playerid)
  6589. {
  6590.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6591.  
  6592.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6593.  
  6594.     if(! gMask[playerid]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have a Gas Mask.");
  6595.  
  6596.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6597.  
  6598.     if(IsPlayerAttachedObjectSlotUsed(playerid, 3))
  6599.     {
  6600.         RemovePlayerAttachedObject(playerid, 3);
  6601.         SendClientMessage(playerid, COLOR_SEA_GREEN, "* You have DISABLED your Gas Mask.");
  6602.         NotifyPlayer(playerid, "~r~Gas Mask disabled", 5000);
  6603.     }
  6604.     else
  6605.     {
  6606.         SetPlayerAttachedObject(playerid, 3, 19472, 2, -0.022000, 0.137000, 0.018999, 3.899994, 85.999961, 92.999984, 0.923999, 1.141000, 1.026999);
  6607.         SendClientMessage(playerid, COLOR_SEA_GREEN, "* You have ENABLED your Gas Mask.");
  6608.         NotifyPlayer(playerid, "~g~Gas Mask enabled", 5000);
  6609.     }
  6610.     return 1;
  6611. }
  6612.  
  6613. CMD:givebomb(playerid, params[])
  6614. {
  6615.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6616.  
  6617.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6618.  
  6619.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't transfer Sucide Bomb when you aren't spawned.");
  6620.  
  6621.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6622.  
  6623.     new target;
  6624.     if(sscanf(params, "u", target)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /givebomb [player]");
  6625.  
  6626.     if(! IsPlayerConnected(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not connected.");
  6627.  
  6628.     new Float:pos[3];
  6629.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  6630.     if(! IsPlayerInRangeOfPoint(target, 5.0, pos[0], pos[1], pos[2])) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not near you.");
  6631.  
  6632.     if(! gBomb[playerid]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have a Sucide Bomb to give.");
  6633.  
  6634.     if(gBomb[target]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player already have a Sucide Bomb.");
  6635.  
  6636.     if(target == playerid) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't give Sucide Bomb to yourself.");
  6637.  
  6638.     gBomb[playerid] = false;
  6639.     gBomb[target] = true;
  6640.  
  6641.     SetPlayerAttachedObject(target, 4, 1654, 1, 0.046000, 0.229000, -0.013000, 3.099998, 78.299972, -178.599960, 1.000000, 1.000000, 1.000000);
  6642.     RemovePlayerAttachedObject(playerid, 4);
  6643.  
  6644.     new string[144];
  6645.     format(string, sizeof(string), "* %s(%i) have given you a Sucide Bomb.", ReturnPlayerName(playerid), playerid);
  6646.     SendClientMessage(target, COLOR_SEA_GREEN, string);
  6647.     format(string, sizeof(string), "* You have given %s(%i), a Sucide Bomb.", ReturnPlayerName(target), target);
  6648.     SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  6649.     NotifyPlayer(playerid, "~g~Sucide Bomb recieved", 5000);
  6650.     return 1;
  6651. }
  6652.  
  6653. CMD:bomb(playerid)
  6654. {
  6655.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6656.  
  6657.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6658.  
  6659.     if(! gBomb[playerid]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You don't have a Sucide Bomb.");
  6660.  
  6661.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6662.  
  6663.     if(IsPlayerAttachedObjectSlotUsed(playerid, 4))
  6664.     {
  6665.         RemovePlayerAttachedObject(playerid, 4);
  6666.         SendClientMessage(playerid, COLOR_SEA_GREEN, "* You have DISABLED your Sucide Bomb.");
  6667.         NotifyPlayer(playerid, "~r~Sucide Bomb disabled", 5000);
  6668.     }
  6669.     else
  6670.     {
  6671.         SetPlayerAttachedObject(playerid, 4, 1654, 1, 0.046000, 0.229000, -0.013000, 3.099998, 78.299972, -178.599960, 1.000000, 1.000000, 1.000000);
  6672.         SendClientMessage(playerid, COLOR_SEA_GREEN, "* You have ENABLED your Sucide Bomb.");
  6673.         NotifyPlayer(playerid, "~g~Sucide Bomb enabled", 5000);
  6674.     }
  6675.     return 1;
  6676. }
  6677.  
  6678. CMD:prestige(playerid, params[])
  6679. {
  6680.     new rank = GetPlayerRank(playerid);
  6681.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 3 && rank < 10) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be atleast rank 10+ for using this command.");
  6682.  
  6683.     new slot;
  6684.     if(sscanf(params, "i", slot)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /prestige [slot<1-3>]");
  6685.  
  6686.     if(slot > 3 || slot < 1) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Invalid slot, must be b/w 1-3.");
  6687.  
  6688.     switch(slot)
  6689.     {
  6690.         case 1:
  6691.         {
  6692.             if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 3 && rank < 10) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be atleast rank 10+ for setting this slot.");
  6693.             else gListitem[playerid] = 0;
  6694.         }
  6695.         case 2:
  6696.         {
  6697.             if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 3 && rank < 15) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be atleast rank 15+ for setting this slot.");
  6698.             else gListitem[playerid] = 1;
  6699.         }
  6700.         case 3:
  6701.         {
  6702.             if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 3 && rank < 20) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be atleast rank 20+ for setting this slot.");
  6703.             else gListitem[playerid] = 2;
  6704.         }
  6705.     }
  6706.    
  6707.     SetupPrevModelDialog(0.0, 0.0, 0.0, 3.0);
  6708.     ShowPlayerDialog(playerid, DIALOG_PRESTIGE, DIALOG_STYLE_PREVMODEL, "Prestige Weapon", prestigeweapons, "Select", "Close");
  6709.     return 1;
  6710. }
  6711.  
  6712. CMD:resetprestige(playerid, params[])
  6713. {
  6714.     new rank = GetPlayerRank(playerid);
  6715.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 3 && rank < 10) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be atleast rank 10+ for using this command.");
  6716.  
  6717.     new slot;
  6718.     if(sscanf(params, "i", slot)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /resetprestige [slot<1-3>]");
  6719.  
  6720.     if(slot > 3 || slot < 1) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Invalid slot, must be b/w 1-3.");
  6721.  
  6722.     switch(slot)
  6723.     {
  6724.         case 1:
  6725.         {
  6726.             if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 3 && rank < 10) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be atleast rank 10+ for resetting this slot.");
  6727.             GAdmin_ChangeUserData(ReturnPlayerName(playerid), "i", "weapon1", 0);
  6728.             SendClientMessage(playerid, COLOR_GREEN, "You have successfully resetted your prestige weapon I.");
  6729.         }
  6730.         case 2:
  6731.         {
  6732.             if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 3 && rank < 15) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be atleast rank 15+ for resetting this slot.");
  6733.             GAdmin_ChangeUserData(ReturnPlayerName(playerid), "i", "weapon2", 0);
  6734.             SendClientMessage(playerid, COLOR_GREEN, "You have successfully resetted your prestige weapon II.");
  6735.         }
  6736.         case 3:
  6737.         {
  6738.             if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 3 && rank < 20) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be atleast rank 20+ for resetting this slot.");
  6739.             GAdmin_ChangeUserData(ReturnPlayerName(playerid), "i", "weapon3", 0);
  6740.             SendClientMessage(playerid, COLOR_GREEN, "You have successfully resetted your prestige weapon III.");
  6741.         }
  6742.     }
  6743.     return 1;
  6744. }
  6745.  
  6746. CMD:myprestige(playerid)
  6747. {
  6748.     new string[144], weapon, rank;
  6749.     rank = GetPlayerRank(playerid);
  6750.    
  6751.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 3 && rank < 10) return SendClientMessage(playerid, COLOR_GOLD, "- You don't have any weapon for prestige I.");
  6752.     else
  6753.     {
  6754.         GAdmin_RetrieveUserData(ReturnPlayerName(playerid), "i", "weapon1", weapon);
  6755.         if(weapon == 0) SendClientMessage(playerid, COLOR_GOLD, "- You don't have any weapon for prestige I.");
  6756.         else
  6757.         {
  6758.             format(string, sizeof(string), "- You have weapon %s as prestige I.", ReturnWeaponName(weapon));
  6759.             SendClientMessage(playerid, COLOR_GOLD, string);
  6760.         }
  6761.     }
  6762.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 3 && rank < 15) return SendClientMessage(playerid, COLOR_GOLD, "- You don't have any weapon for prestige II.");
  6763.     else
  6764.     {
  6765.         GAdmin_RetrieveUserData(ReturnPlayerName(playerid), "i", "weapon2", weapon);
  6766.         if(weapon == 0) SendClientMessage(playerid, COLOR_GOLD, "- You don't have any weapon for prestige II.");
  6767.         else
  6768.         {
  6769.             format(string, sizeof(string), "- You have weapon %s as prestige II.", ReturnWeaponName(weapon));
  6770.             SendClientMessage(playerid, COLOR_GOLD, string);
  6771.         }
  6772.     }
  6773.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 3 && rank < 20) return SendClientMessage(playerid, COLOR_GOLD, "- You don't have any weapon for prestige III.");
  6774.     else
  6775.     {
  6776.         GAdmin_RetrieveUserData(ReturnPlayerName(playerid), "i", "weapon3", weapon);
  6777.         if(weapon == 0) SendClientMessage(playerid, COLOR_GOLD, "- You don't have any weapon for prestige III.");
  6778.         else
  6779.         {
  6780.             format(string, sizeof(string), "- You have weapon %s as prestige III.", ReturnWeaponName(weapon));
  6781.             SendClientMessage(playerid, COLOR_GOLD, string);
  6782.         }
  6783.     }
  6784.     return 1;
  6785. }
  6786.  
  6787. //duel system
  6788. CMD:duel(playerid, params[])
  6789. {
  6790.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6791.  
  6792.     if(! IsPlayerSpawned(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't duel when you aren't spawned.");
  6793.  
  6794.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6795.  
  6796.     if(IsPlayerNearEnemies(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't use this command near enemies.");
  6797.  
  6798.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You are already in a duel, finish this one or use /kill.");
  6799.  
  6800.     new target, bet;
  6801.     if(sscanf(params, "ii", target, bet)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /duel [player] [bet]");
  6802.  
  6803.     if(! IsPlayerConnected(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not connected.");
  6804.  
  6805.     if(gPlayerGamemode[target] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player must in team deathmatch.");
  6806.  
  6807.     if(! IsPlayerSpawned(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't duel the player isn't spawned.");
  6808.  
  6809.     if(gDuel[target][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is already in a duel.");
  6810.  
  6811.     if(GetPlayerMoney(playerid) < bet) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You yourself don't have that much bet money.");
  6812.  
  6813.     if(bet < 0) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't bet negative money!!!!");
  6814.  
  6815.     if(target == playerid) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't duel with yourself.");
  6816.  
  6817.     gDuel[playerid][d_opponent] = target;
  6818.     gDuel[target][d_opponent] = playerid;
  6819.  
  6820.     SendClientMessage(playerid, COLOR_SEA_GREEN, "* Please select your duel weapon.");
  6821.  
  6822.     SetupPrevModelDialog(0.0, 0.0, 0.0, 3.0);
  6823.     ShowPlayerDialog(playerid, DIALOG_DUEL_WEAPON, DIALOG_STYLE_PREVMODEL, "Select your duel weapon", duelweapons, "Select", "Close");
  6824.     return 1;
  6825. }
  6826.  
  6827. CMD:ss(playerid)
  6828. {
  6829.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6830.  
  6831.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6832.  
  6833.     if(GetPlayerTeam(playerid) == 7) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Africa team can't use this command.");
  6834.  
  6835.     new dialogstr[556];
  6836.     new string[76];
  6837.     format(dialogstr, sizeof(dialogstr), ""WHITE"BASE\n");
  6838.     for(new i; i < sizeof(gSpawn); i++)
  6839.     {
  6840.         if(gCaptureZone[gSpawn[i][s_zoneid]][E_ZONEOWNER] == GetPlayerTeam(playerid)) format(string, sizeof(string), ""LIGHT_BLUE"%s\n", gCaptureZone[gSpawn[i][s_zoneid]][E_ZONENAME]);
  6841.         else format(string, sizeof(string), ""GRAY"%s\n", gCaptureZone[gSpawn[i][s_zoneid]][E_ZONENAME]);
  6842.         strcat(dialogstr, string);
  6843.     }
  6844.     ShowPlayerDialog(playerid, DIALOG_SPAWN, DIALOG_STYLE_LIST, "Select your spawn:", dialogstr, "Select", "Close");
  6845.     return 1;
  6846. }
  6847.  
  6848. CMD:inv(playerid)
  6849. {
  6850.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6851.  
  6852.     if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command right now.");
  6853.  
  6854.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6855.  
  6856.     new string[256];
  6857.     format(string, sizeof(string), "Itemname\tAmount\nPainkillers\t%i\nArmour Jacket\t%i\nProtection Helmet\t%i\nGas Mask\t%i\nSucide Bomb\t%i", gPainkillers[playerid], (gArmour[playerid]) ? 1 : 0, (gHelmet[playerid]) ? 1 : 0, (gMask[playerid]) ? 1 : 0, (gBomb[playerid]) ? 1 : 0);
  6858.     ShowPlayerDialog(playerid, DIALOG_INVENTORY, DIALOG_STYLE_TABLIST_HEADERS, "Inventory (/inv)", string, "Open", "Close");
  6859.     return 1;
  6860. }
  6861.  
  6862. //donor commands
  6863. CMD:dhelp(playerid)
  6864. {
  6865.     ShowPlayerDialog(playerid, DIALOG_COMMON, DIALOG_STYLE_MSGBOX, "Donor help", "The server has a unique donor/vip system for our donators.\n\nFor keeping our server live and bugs free, we let the users to donate for our server.\nFor those helpful donators, we give them an in game advantage or DONOR ranks based on their donation.\n\nYou may donate us in order to become a DONOR; go on forums to see more.", "Close", "");
  6866.     return 1;
  6867. }
  6868.  
  6869. //Donor level 1+
  6870. CMD:dcmds(playerid)
  6871. {
  6872.     ShowPlayerDialog(playerid, DIALOG_COMMON, DIALOG_STYLE_MSGBOX, "Donor Commands", ""LIME"BRONSE (Level 1)\n"LIGHT_BLUE"/dlabel, /dammo, /dskin\n\n"LIME"SILVER (Level 2)\n"LIGHT_BLUE"/dbike, /dcar, /dbmx, /dplane, /dnos, /dhyd, /dguns\n\n"LIME"GOLD (Level 3)\n"LIGHT_BLUE"/dsucide, /dsupply, /dtime, /dweather", "Close", "");
  6873.     return 1;
  6874. }
  6875.  
  6876. CMD:dlabel(playerid, params[])
  6877. {
  6878.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6879.  
  6880.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6881.  
  6882.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 1) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a donor level 1+ to use this command.");
  6883.  
  6884.     new text[25];
  6885.     if(sscanf(params, "s[25]", text)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /dlabel [text <25 length>]");
  6886.  
  6887.     UpdateDynamic3DTextLabelText(gDonorLabel[playerid], COLOR_YELLOW, text);
  6888.     GameTextForPlayer(playerid, "~y~Label Chagned", 3000, 3);
  6889.     return 1;
  6890. }
  6891.  
  6892. CMD:dammo(playerid)
  6893. {
  6894.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6895.  
  6896.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6897.  
  6898.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 1) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a donor level 1+ to use this command.");
  6899.  
  6900.     if(GetPlayerMoney(playerid) < 4500) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You need atleast $4500 to use this command.");
  6901.  
  6902.     new weapon = GetPlayerWeapon(playerid);
  6903.     switch(weapon)
  6904.     {
  6905.         case 16..18,35,36,39: SetPlayerAmmo(playerid, weapon, (GetPlayerAmmo(playerid) + 3));
  6906.         case 22..34,38,41,42,43: SetPlayerAmmo(playerid, weapon, (GetPlayerAmmo(playerid) + 100));
  6907.         case 37: SetPlayerAmmo(playerid, weapon, (GetPlayerAmmo(playerid) + 200));
  6908.     }
  6909.     GameTextForPlayer(playerid, "~y~Ammo Refiled~n~~y~-$4500", 3000, 3);
  6910.     GivePlayerMoney(playerid, - 4500);
  6911.     return 1;
  6912. }
  6913.  
  6914. CMD:dskin(playerid, params[])
  6915. {
  6916.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6917.  
  6918.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6919.  
  6920.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 1) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a donor level 1+ to use this command.");
  6921.  
  6922.     new skin;
  6923.     if(sscanf(params, "i", skin)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /dskin [skin]");
  6924.  
  6925.     if(skin < 0 || skin > 311) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Invalid skin id, must be b/w  0 - 311.");
  6926.  
  6927.     for(new i; i < sizeof(gTeam); i++)
  6928.     {
  6929.         if(skin == gTeam[i][E_SKIN]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use a team skin, try another one.");
  6930.     }
  6931.  
  6932.     SetPlayerSkin(playerid, skin);
  6933.     GameTextForPlayer(playerid, "~y~Skin Chagned", 3000, 3);
  6934.     return 1;
  6935. }
  6936.  
  6937. //Donor level 2+
  6938. CMD:dbike(playerid, params[])
  6939. {
  6940.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6941.  
  6942.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6943.  
  6944.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 2) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a donor level 2+ to use this command.");
  6945.  
  6946.     DestroyVehicle(gPlayerVehicle[playerid]);
  6947.  
  6948.     new Float:pos[4];
  6949.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  6950.     GetPlayerFacingAngle(playerid, pos[3]);
  6951.  
  6952.     gPlayerVehicle[playerid] = CreateVehicle(522, pos[0], pos[1], pos[2], pos[3], random(255), random(255), -1);
  6953.     LinkVehicleToInterior(gPlayerVehicle[playerid],GetPlayerInterior(playerid));
  6954.     SetVehicleVirtualWorld(gPlayerVehicle[playerid],GetPlayerVirtualWorld(playerid));
  6955.  
  6956.     PutPlayerInVehicle(playerid, gPlayerVehicle[playerid], 0);
  6957.     GameTextForPlayer(playerid, "~y~Bike Spawned", 3000, 3);
  6958.     return 1;
  6959. }
  6960.  
  6961. CMD:dcar(playerid, params[])
  6962. {
  6963.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6964.  
  6965.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6966.  
  6967.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 2) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a donor level 2+ to use this command.");
  6968.  
  6969.     DestroyVehicle(gPlayerVehicle[playerid]);
  6970.  
  6971.     new Float:pos[4];
  6972.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  6973.     GetPlayerFacingAngle(playerid, pos[3]);
  6974.  
  6975.     gPlayerVehicle[playerid] = CreateVehicle(411, pos[0], pos[1], pos[2], pos[3], random(255), random(255), -1);
  6976.     LinkVehicleToInterior(gPlayerVehicle[playerid],GetPlayerInterior(playerid));
  6977.     SetVehicleVirtualWorld(gPlayerVehicle[playerid],GetPlayerVirtualWorld(playerid));
  6978.  
  6979.     PutPlayerInVehicle(playerid, gPlayerVehicle[playerid], 0);
  6980.     GameTextForPlayer(playerid, "~y~Car Spawned", 3000, 3);
  6981.     return 1;
  6982. }
  6983.  
  6984. CMD:dbmx(playerid, params[])
  6985. {
  6986.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6987.  
  6988.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  6989.  
  6990.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 2) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a donor level 2+ to use this command.");
  6991.  
  6992.     DestroyVehicle(gPlayerVehicle[playerid]);
  6993.  
  6994.     new Float:pos[4];
  6995.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  6996.     GetPlayerFacingAngle(playerid, pos[3]);
  6997.  
  6998.     gPlayerVehicle[playerid] = CreateVehicle(481, pos[0], pos[1], pos[2], pos[3], random(255), random(255), -1);
  6999.     LinkVehicleToInterior(gPlayerVehicle[playerid],GetPlayerInterior(playerid));
  7000.     SetVehicleVirtualWorld(gPlayerVehicle[playerid],GetPlayerVirtualWorld(playerid));
  7001.  
  7002.     PutPlayerInVehicle(playerid, gPlayerVehicle[playerid], 0);
  7003.     GameTextForPlayer(playerid, "~y~BMX Spawned", 3000, 3);
  7004.     return 1;
  7005. }
  7006.  
  7007. CMD:dplane(playerid, params[])
  7008. {
  7009.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  7010.  
  7011.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  7012.  
  7013.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 2) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a donor level 2+ to use this command.");
  7014.  
  7015.     DestroyVehicle(gPlayerVehicle[playerid]);
  7016.  
  7017.     new Float:pos[4];
  7018.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  7019.     GetPlayerFacingAngle(playerid, pos[3]);
  7020.  
  7021.     gPlayerVehicle[playerid] = CreateVehicle(513, pos[0], pos[1], pos[2], pos[3], random(255), random(255), -1);
  7022.     LinkVehicleToInterior(gPlayerVehicle[playerid],GetPlayerInterior(playerid));
  7023.     SetVehicleVirtualWorld(gPlayerVehicle[playerid],GetPlayerVirtualWorld(playerid));
  7024.  
  7025.     PutPlayerInVehicle(playerid, gPlayerVehicle[playerid], 0);
  7026.     GameTextForPlayer(playerid, "~y~Airplane Spawned", 3000, 3);
  7027.     return 1;
  7028. }
  7029.  
  7030. CMD:dnos(playerid, params[])
  7031. {
  7032.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  7033.  
  7034.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  7035.  
  7036.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 2) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a donor level 2+ to use this command.");
  7037.  
  7038.     if(! IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be in a vehicle to use this command.");
  7039.  
  7040.     new vehicle = GetPlayerVehicleID(playerid);
  7041.     switch(GetVehicleModel(vehicle))
  7042.     {
  7043.         case 448,461,462,463,468,471,509,510,521,522,523,581,586,449: return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot add nos to this vehicle.");
  7044.     }
  7045.     AddVehicleComponent(vehicle, 1010);
  7046.  
  7047.     GameTextForPlayer(playerid, "~y~Nos-10x Added", 3000, 3);
  7048.     return 1;
  7049. }
  7050.  
  7051. CMD:dhyd(playerid, params[])
  7052. {
  7053.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  7054.  
  7055.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  7056.  
  7057.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 2) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a donor level 2+ to use this command.");
  7058.  
  7059.     if(! IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be in a vehicle to use this command.");
  7060.  
  7061.     new vehicle = GetPlayerVehicleID(playerid);
  7062.     switch(GetVehicleModel(vehicle))
  7063.     {
  7064.         case 448,461,462,463,468,471,509,510,521,522,523,581,586,449: return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot add hydraulics to this vehicle.");
  7065.     }
  7066.     AddVehicleComponent(vehicle, 1087);
  7067.  
  7068.     GameTextForPlayer(playerid, "~y~Hydraulics Added", 3000, 3);
  7069.     return 1;
  7070. }
  7071.  
  7072. CMD:dguns(playerid, params[])
  7073. {
  7074.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  7075.  
  7076.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  7077.  
  7078.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 2) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a donor level 2+ to use this command.");
  7079.  
  7080.     if(IsPlayerNearEnemies(playerid)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't use this command near enemies.");
  7081.  
  7082.     if(GetPlayerMoney(playerid) < 7500) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You need atleast $7500 to use this command.");
  7083.  
  7084.     GivePlayerWeapon(playerid, 31, 100);
  7085.     GivePlayerWeapon(playerid, 24, 50);
  7086.     GivePlayerWeapon(playerid, 26, 100);
  7087.     GivePlayerWeapon(playerid, 35, 1);
  7088.     GivePlayerWeapon(playerid, 16, 2);
  7089.  
  7090.     GameTextForPlayer(playerid, "~y~Donor Weapons Spawned~n~~y~-$7500", 3000, 3);
  7091.     GivePlayerMoney(playerid, - 7500);
  7092.     return 1;
  7093. }
  7094.  
  7095. //Donor level 3+
  7096. CMD:dsucide(playerid, params[])
  7097. {
  7098.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  7099.  
  7100.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  7101.  
  7102.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 3) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a donor level 3+ to use this command.");
  7103.  
  7104.     new string[144];
  7105.  
  7106.     new Float:pos[3];
  7107.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  7108.    
  7109.     CreateExplosion(pos[0], pos[1], pos[2], 6, 1.00);
  7110.  
  7111.     SetPlayerArmour(playerid,0.0);
  7112.     SetPlayerHealth(playerid,0.0);
  7113.  
  7114.     GameTextForPlayer(playerid, "~y~Sucide Bomb", 3000, 3);
  7115.  
  7116.     foreach(new i : Player)
  7117.     {
  7118.         if(gPlayerGamemode[i] == MODE_TEAM_DEATHMATCH)
  7119.         {
  7120.             GetPlayerPos(i, pos[0], pos[1], pos[2]);
  7121.  
  7122.             if(IsPlayerInRangeOfPoint(playerid, 3.0, pos[0], pos[1], pos[2]))
  7123.             {
  7124.                 if(GetPlayerTeam(i) != GetPlayerTeam(i))
  7125.                 {
  7126.                     SetPlayerHealth(i, 0.0);
  7127.                     GameTextForPlayer(i, "~b~DEMOLISHED", 3000, 3);
  7128.  
  7129.                     format(string, sizeof(string), "* You got demolished by %s (Donor Sucide)", ReturnPlayerName(playerid));
  7130.                     SendClientMessage(i, COLOR_YELLOW, string);
  7131.                     format(string, sizeof(string), "* You demolished %s with your Donor Sucide!", ReturnPlayerName(i));
  7132.                     SendClientMessage(playerid, COLOR_YELLOW, string);
  7133.  
  7134.                     SendDeathMessage(playerid, i, 49);
  7135.  
  7136.                     new kills;
  7137.                     GAdmin_RetrieveUserData(ReturnPlayerName(playerid), "i", "kills", kills);
  7138.                     GAdmin_ChangeUserData(ReturnPlayerName(playerid), "i", "kills", kills + 1);
  7139.                 }
  7140.             }
  7141.         }
  7142.     }
  7143.     return 1;
  7144. }
  7145.  
  7146. CMD:dsupply(playerid, params[])
  7147. {
  7148.     if(gPlayerGamemode[playerid] != MODE_TEAM_DEATHMATCH) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  7149.  
  7150.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  7151.  
  7152.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 3) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a donor level 3+ to use this command.");
  7153.  
  7154.     new string[144];
  7155.    
  7156.     new Float:pos[3];
  7157.     GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
  7158.    
  7159.     foreach(new i : Player)
  7160.     {
  7161.         if( IsPlayerInRangeOfPoint(i, 10.0, pos[0], pos[1], pos[2]) &&
  7162.             GetPlayerTeam(i) == GetPlayerTeam(playerid) &&
  7163.             i != playerid)
  7164.         {
  7165.             GivePlayerWeapon(i, 35, 2);
  7166.             GivePlayerWeapon(i, 30, 100);
  7167.             GivePlayerWeapon(i, 24, 50);
  7168.  
  7169.             new Float:value;
  7170.             GetPlayerArmour(i, value);
  7171.             if((value + 20.0) >= 100) SetPlayerArmour(i, 100.0);
  7172.             else SetPlayerArmour(i, (value + 20.0));
  7173.  
  7174.             GetPlayerHealth(i, value);
  7175.             if((value + 20.0) >= 100) SetPlayerHealth(i, 100.0);
  7176.             else SetPlayerHealth(i, (value + 20.0));
  7177.  
  7178.             format(string,sizeof(string),"* You have been supplied: weapons, armour & health; by donor %s[%d].", ReturnPlayerName(playerid), playerid);
  7179.             SendClientMessage(i, COLOR_YELLOW, string);
  7180.            
  7181.             format(string,sizeof(string),"* %s[%d] have recieved your donor supply (weapons, armour & health)", ReturnPlayerName(i), i);
  7182.             SendClientMessage(playerid, COLOR_YELLOW, string);
  7183.         }
  7184.     }
  7185.    
  7186.     GivePlayerWeapon(playerid, 35, 2);
  7187.     GivePlayerWeapon(playerid, 30, 100);
  7188.     GivePlayerWeapon(playerid, 24, 50);
  7189.  
  7190.     new Float:value;
  7191.     GetPlayerArmour(playerid, value);
  7192.     if((value + 20.0) >= 100) SetPlayerArmour(playerid, 100.0);
  7193.     else SetPlayerArmour(playerid, (value + 20.0));
  7194.  
  7195.     GetPlayerHealth(playerid, value);
  7196.     if((value + 20.0) >= 100) SetPlayerHealth(playerid, 100.0);
  7197.     else SetPlayerHealth(playerid, (value + 20.0));
  7198.  
  7199.     gDonorSupply[playerid] -= 1;
  7200.     format(string,sizeof(string),"* You are now left with %i/3 donor supply packs.", gDonorSupply[playerid]);
  7201.     SendClientMessage(playerid, COLOR_YELLOW, string);
  7202.     return 1;
  7203. }
  7204.  
  7205. CMD:dtime(playerid,params[])
  7206. {
  7207.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  7208.  
  7209.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 3) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a donor level 3+ to use this command.");
  7210.  
  7211.     ShowPlayerDialog(playerid, DIALOG_TIME, DIALOG_STYLE_LIST, "Select a time to set!", "Morning\nMid day\nAfternoon\nEvening\nMidnight", "Select", "Cancel");
  7212.     return 1;
  7213. }
  7214.  
  7215. CMD:dweather(playerid,params[])
  7216. {
  7217.     if(gDuel[playerid][d_induel]) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must in team deathmatch to use this command.");
  7218.  
  7219.     if(GAdmin_GetUserVipLevel(ReturnPlayerName(playerid)) < 3) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You must be a donor level 3+ to use this command.");
  7220.  
  7221.     ShowPlayerDialog(playerid, DIALOG_WEATHER, DIALOG_STYLE_LIST, "Select a time to set!", "Blue Sky\nSand Storm\nThunderstorm\nFoggy\nCloudy\nHigh Tide\nPurple Sky\nBlack/White Sky\nDark, Green Sky\nHeatwave", "Select", "Cancel");
  7222.     return 1;
  7223. }
  7224.  
  7225. //------------------------------------------------
  7226.  
  7227. forward OnPlayerHealExpire(doctorid, playerid);
  7228. public OnPlayerHealExpire(doctorid, playerid)
  7229. {
  7230.     gHealed[doctorid][playerid] = -1;
  7231.     return 1;
  7232. }
  7233.  
  7234. //------------------------------------------------
  7235.  
  7236. public OnPlayerPickUpDynamicPickup(playerid, pickupid)
  7237. {
  7238.     if(pickupid == gMoneyBag[MONEYBAG_PICKUPID])
  7239.     {
  7240.         if(gPlayerGamemode[playerid] == MODE_MONEYBAG)
  7241.         {
  7242.             gMoneyBag[MONEYBAG_PLAYER] = playerid;
  7243.             RemovePlayerAttachedObject(playerid, 0);
  7244.             SetPlayerAttachedObject(playerid, 1, 1550, 1, 0.1, -0.3, 0, 0, 40, 0, 1, 1, 1);
  7245.             DestroyDynamicPickup(gMoneyBag[MONEYBAG_PICKUPID]);
  7246.  
  7247.             new string[145];
  7248.             foreach(new i : Player)
  7249.             {
  7250.                 if(gPlayerGamemode[i] == MODE_MONEYBAG)
  7251.                 {
  7252.                     format(string, sizeof(string), "~g~%s(%d) have the~n~~g~money bag", ReturnPlayerName(playerid), playerid);
  7253.                     GameTextForPlayer(i, string, 5000, 3);
  7254.                 }
  7255.             }
  7256.         }
  7257.     }
  7258.  
  7259.     if(pickupid == gNuke[NUKE_PICKUP])
  7260.     {
  7261.         if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot pickup this right now.");
  7262.  
  7263.         new string[256];
  7264.         if(GetPlayerTeam(playerid) != gCaptureZone[NUKE_ZONE][E_ZONEOWNER])
  7265.         {
  7266.             format(string, sizeof(string), "ERROR: You must capture %s before launching a Nuclear missle.", gCaptureZone[NUKE_ZONE][E_ZONENAME]);
  7267.             return SendClientMessage(playerid, COLOR_FIREBRICK, string);
  7268.         }
  7269.  
  7270.         if(gNuke[NUKE_TIME] > 0)
  7271.         {
  7272.             format(string, sizeof(string), "ERROR: You must wait %i seconds before launching a Nuke.", gNuke[NUKE_TIME]);
  7273.             return SendClientMessage(playerid, COLOR_FIREBRICK, string);
  7274.         }
  7275.  
  7276.         new dialogstr[144];
  7277.         for(new i; i < sizeof(gTeamBase); i++)
  7278.         {
  7279.             format(string, sizeof(string), "%s\n", gTeamBase[i][b_name]);
  7280.             strcat(dialogstr, string);
  7281.         }
  7282.  
  7283.         //dialog check
  7284.         if(GetPlayerDialogID(playerid) != INVALID_DIALOG_ID) return 1;
  7285.  
  7286.         return ShowPlayerDialog(playerid, DIALOG_NUKE, DIALOG_STYLE_LIST, "Where do you want to plant the Nuke?", dialogstr, "Plant", "Cancel");
  7287.     }
  7288.  
  7289.  
  7290.     if(pickupid == gAnthrax[ANTHRAX_PICKUP])
  7291.     {
  7292.         if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot pickup this right now.");
  7293.  
  7294.         new string[144];
  7295.         if(GetPlayerTeam(playerid) != gCaptureZone[ANTHRAX_ZONE][E_ZONEOWNER])
  7296.         {
  7297.             format(string, sizeof(string), "ERROR: You must capture %s before launching a Anthrax bomb.", gCaptureZone[ANTHRAX_ZONE][E_ZONENAME]);
  7298.             return SendClientMessage(playerid, COLOR_FIREBRICK, string);
  7299.         }
  7300.  
  7301.         if(gAnthrax[ANTHRAX_TIME] > 0)
  7302.         {
  7303.             format(string, sizeof(string), "ERROR: You must wait %i seconds before launching an Anthrax bomb.", gAnthrax[ANTHRAX_TIME]);
  7304.             return SendClientMessage(playerid, COLOR_FIREBRICK, string);
  7305.         }
  7306.  
  7307.         //dialog check
  7308.         if(GetPlayerDialogID(playerid) != INVALID_DIALOG_ID) return 1;
  7309.  
  7310.         return ShowPlayerDialog(playerid, DIALOG_ANTHRAX, DIALOG_STYLE_MSGBOX, "Anthrax bomb launching?", "Are you sure you want to launch an Anthrax bomb?\nCost: "RED"$"LIGHT_BLUE""#ANTHRAX_COST"", "Launch", "Cancel");
  7311.     }
  7312.  
  7313.     for(new i; i != sizeof(gShop); i++)
  7314.     {
  7315.         if(pickupid == gShop[i][SHOP_PICKUP])
  7316.         {
  7317.             if(GetPlayerTeam(playerid) > (sizeof(gTeam) - 1)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot pickup this right now.");
  7318.  
  7319.             if( gShop[i][SHOP_TEAM] != NO_TEAM &&
  7320.                 GetPlayerTeam(playerid) != gShop[i][SHOP_TEAM])
  7321.             {
  7322.                 return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You can't open enemies' shop!");
  7323.             }
  7324.             //dialog check
  7325.             if(GetPlayerDialogID(playerid) != INVALID_DIALOG_ID) return 1;
  7326.  
  7327.             return ShowPlayerShopDialog(playerid);
  7328.         }
  7329.     }
  7330.     return 1;
  7331. }
  7332.  
  7333. //------------------------------------------------
  7334.  
  7335. public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
  7336. {
  7337.     new keys, updown, leftright;
  7338.     GetPlayerKeys(playerid, keys, updown, leftright);
  7339.     if( keys & KEY_LOOK_BEHIND &&
  7340.         keys & KEY_AIM)
  7341.     {
  7342.         if(gClass[playerid] == CLASS_MEDIC)
  7343.         {
  7344.             new target = GetPlayerTargetPlayer(playerid);
  7345.             if(! IsPlayerConnected(target) || target == INVALID_PLAYER_ID) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Invalid target id");
  7346.  
  7347.             if(target == playerid) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot heal yourself, use /pk or /inv instead.");
  7348.  
  7349.             if(GetPlayerTeam(playerid) != GetPlayerTeam(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot heal enemies.");
  7350.  
  7351.             if(gHealed[playerid][target] != -1) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The must wait 30 seconds before healing that specific player again.");
  7352.  
  7353.             new Float:hp;
  7354.             GetPlayerHealth(target, hp);
  7355.             if((hp + 50.0) >= 100.0) SetPlayerHealth(target, 100.0);
  7356.             else SetPlayerHealth(target, hp + 50.0);
  7357.             PlayerPlaySound(playerid, 1133, 0.0, 0.0, 0.0);
  7358.             PlayerPlaySound(target, 1133, 0.0, 0.0, 0.0);
  7359.  
  7360.             gHealed[playerid][target] = SetTimerEx("OnPlayerHealExpire", 30 * 1000, false, "ii", playerid, target);
  7361.  
  7362.             new string[144];
  7363.             format(string, sizeof(string), "* %s(%i) have healed you with 50.0 health.", ReturnPlayerName(playerid), playerid);
  7364.             SendClientMessage(target, COLOR_SEA_GREEN, string);
  7365.             format(string, sizeof(string), "%s(%i) healed you with 50.0 HP.", ReturnPlayerName(playerid), playerid);
  7366.             NotifyPlayer(target, string, 5000);
  7367.             format(string, sizeof(string), "* You have healed ~b~~h~~h~~h~%s(%i) ~w~~h~with 50.0 health.", ReturnPlayerName(target), target);
  7368.             SendClientMessage(playerid, COLOR_SEA_GREEN, string);
  7369.             format(string, sizeof(string), "Healed ~b~~h~~h~~h~%s(%i) ~w~~h~for 50.0 HP.", ReturnPlayerName(target), target);
  7370.             NotifyPlayer(playerid, string, 5000);
  7371.         }
  7372.     }
  7373.  
  7374.     if(newkeys == KEY_SUBMISSION)
  7375.     {
  7376.         if(gClass[playerid] == CLASS_SPY)
  7377.         {
  7378.             if(IsPlayerInAnyVehicle(playerid))
  7379.             {
  7380.                 if(GetPlayerState(playerid) != PLAYER_STATE_DRIVER)
  7381.                 {
  7382.                     foreach(new i : Player)
  7383.                     {
  7384.                         if( GetPlayerTeam(i) != GetPlayerTeam(playerid) &&
  7385.                             GetPlayerVehicleID(i) == GetPlayerVehicleID(playerid) &&
  7386.                             GetPlayerState(i) == PLAYER_STATE_DRIVER)
  7387.                         {
  7388.                             new Float:hp;
  7389.                             GetPlayerHealth(i, hp);
  7390.                             SetPlayerHealth(i, (hp - 5.0));
  7391.  
  7392.                             PlayerPlaySound(i, 6401, 0.0, 0.0, 0.0);
  7393.                             PlayerPlaySound(playerid, 6401, 0.0, 0.0, 0.0);
  7394.  
  7395.                             if((hp - 5.0) <= 0.0) return CallLocalFunction("OnPlayerKillPlayer", "iii", i, playerid, 4);
  7396.                             break;
  7397.                         }
  7398.                     }
  7399.                 }
  7400.             }
  7401.         }
  7402.     }
  7403.  
  7404.     if(newkeys & KEY_FIRE)
  7405.     {
  7406.         new Float:x, Float:y, Float:z;
  7407.         GetPlayerPos(playerid,x,y,z);
  7408.         if(GetPlayerWeapon(playerid) == 17)
  7409.         {
  7410.             foreach(new i : Player)
  7411.             {
  7412.                 if( IsPlayerInRangeOfPoint(i, 5.0, x, y, z) &&
  7413.                     i != playerid &&
  7414.                     GetPlayerState(i) == PLAYER_STATE_ONFOOT &&
  7415.                     (GetPlayerTeam(i) != GetPlayerTeam(playerid) || GetPlayerTeam(i) == NO_TEAM) &&
  7416.                     ! gMask[i] &&
  7417.                     ! IsPlayerAttachedObjectSlotUsed(i, 2))
  7418.                 {
  7419.                     ApplyAnimation(i, "ped", "gas_cwr", 1.0, 0, 0, 0, 0, 0);
  7420.                 }
  7421.             }
  7422.         }
  7423.     }
  7424.  
  7425.     if(newkeys == KEY_YES)
  7426.     {
  7427.         if(GetPlayerTeam(playerid) < sizeof(gTeam))
  7428.         {
  7429.             if(gPlayerGamemode[playerid] == MODE_TEAM_DEATHMATCH)
  7430.             {
  7431.                 if(! gDuel[playerid][d_induel])
  7432.                 {
  7433.                     new string[256];
  7434.                     format(string, sizeof(string), "Itemname\tAmount\nPainkillers\t%i\nArmour Jacket\t%i\nProtection Helmet\t%i\nGas Mask\t%i\nSucide Bomb\t%i", gPainkillers[playerid], (gArmour[playerid]) ? 1 : 0, (gHelmet[playerid]) ? 1 : 0, (gMask[playerid]) ? 1 : 0, (gBomb[playerid]) ? 1 : 0);
  7435.                     ShowPlayerDialog(playerid, DIALOG_INVENTORY, DIALOG_STYLE_TABLIST_HEADERS, "Inventory (/inv)", string, "Open", "Close");
  7436.                 }
  7437.             }
  7438.         }
  7439.     }
  7440.    
  7441.     //airdrop system
  7442.     if(newkeys == KEY_NO)
  7443.     {
  7444.         if( ! GetPlayerVirtualWorld(playerid) &&
  7445.             ! GetPlayerInterior(playerid) &&
  7446.             IsPlayerSpawned(playerid) &&
  7447.             ! IsPlayerInAnyVehicle(playerid))
  7448.         {
  7449.             for(new i; i < MAX_AIRDROPS; i++)
  7450.             {
  7451.                 if(gAirdrop[i][AIRDROP_EXIST])
  7452.                 {
  7453.                     if(! gAirdrop[i][AIRDROP_PICKED])
  7454.                     {
  7455.                         if(IsPlayerInRangeOfPoint(playerid, 5.0, gAirdrop[i][AIRDROP_POS][0], gAirdrop[i][AIRDROP_POS][1], gAirdrop[i][AIRDROP_POS][2]))
  7456.                         {
  7457.                             ApplyAnimation(playerid, "MISC", "pickup_box", 1.0, 1, 1, 1, 1, 0);
  7458.                             GameTextForPlayer(playerid, "~b~~h~~h~~h~Picking...", 2300, 3);
  7459.  
  7460.                             KillTimer(gAirdrop[i][AIRDROP_EXPIRE]);
  7461.                             gAirdrop[i][AIRDROP_EXPIRE] = SetTimerEx("OnAirdropExpire", 2000, false, "ii", playerid, i);
  7462.                             gAirdrop[i][AIRDROP_PICKED] = true;
  7463.                             break;
  7464.                         }
  7465.                     }
  7466.                 }
  7467.             }
  7468.         }
  7469.     }
  7470.     return 1;
  7471. }
  7472.  
  7473. //------------------------------------------------
  7474.  
  7475. public OnPlayerShootVehiclePart(playerid, weaponid, vehicleid, hittype)
  7476. {
  7477.     //petrol cap destroy system
  7478.     if(hittype == BULLET_HIT_PETROL_TANK)//when player shoots on the petrol cap of a vehicle
  7479.     {
  7480.         foreach(new i : Player)
  7481.         {
  7482.             if( GetPlayerState(i) == PLAYER_STATE_DRIVER &&
  7483.                 GetPlayerVehicleID(i) == vehicleid &&
  7484.                 GetPlayerTeam(i) != GetPlayerTeam(playerid))
  7485.             {
  7486.                 new Float:x, Float:y, Float:z;
  7487.                 GetVehiclePos(vehicleid, x, y, z);
  7488.                 CreateExplosion(x, y, z, 6, 30.0);
  7489.                 SetVehicleToRespawn(vehicleid);
  7490.  
  7491.                 CallLocalFunction("OnPlayerKillPlayer", "iii", i, playerid, 51);
  7492.  
  7493.                 GameTextForPlayer(i, "~r~~h~PETROL CAP SHOT !", 5000, 1);
  7494.                 GameTextForPlayer(playerid, "~g~~h~~h~~h~PETROL CAP SHOT !", 5000, 1);
  7495.  
  7496.                 SendClientMessage(playerid, COLOR_GREEN, "Good job on that PERFECT petrol-cap shot, +2 Score & +$500 extra!");
  7497.                 GivePlayerMoney(playerid, 500);
  7498.                 GivePlayerScore(playerid, 2);
  7499.  
  7500.                 PlayerPlaySound(i, 1053, 0.0, 0.0, 0.0);
  7501.                 PlayerPlaySound(playerid, 1053, 0.0, 0.0, 0.0);
  7502.                 return 1;
  7503.             }
  7504.         }
  7505.     }
  7506.     return 1;
  7507. }
  7508.  
  7509. //------------------------------------------------
  7510.  
  7511. public OnPlayerWalk(playerid, style)
  7512. {
  7513.     return 1;
  7514. }
  7515.  
  7516. //------------------------------------------------
  7517.  
  7518. public OnPlayerHeadshot(playerid, issuerid, weaponid)
  7519. {
  7520.     //headshot system
  7521.     if( gHelmet[playerid] &&
  7522.         IsPlayerAttachedObjectSlotUsed(playerid, 2))
  7523.     {
  7524.         return 0;
  7525.     }
  7526.  
  7527.     if(gAntiSpawnkill[playerid][A_TIMER] != -1)
  7528.     {
  7529.         return 0;
  7530.     }
  7531.  
  7532.     switch(weaponid)
  7533.     {
  7534.         case 34,33,24:
  7535.         {
  7536.             SetPlayerArmour(playerid, 0.0);
  7537.             SetPlayerHealth(playerid, 0.0);
  7538.  
  7539.             CallLocalFunction("OnPlayerKillPlayer", "iii", playerid, issuerid, weaponid);
  7540.  
  7541.             GameTextForPlayer(playerid, "~r~~h~HEADSHOT !", 5000, 3);
  7542.             GameTextForPlayer(issuerid, "~g~~h~~h~~h~HEADSHOT !", 5000, 3);
  7543.  
  7544.             SendClientMessage(issuerid, COLOR_GREEN, "Good job on that PERFECT headshot, +2 Score & +$500 extra!");
  7545.             GivePlayerMoney(issuerid, 500);
  7546.             GivePlayerScore(issuerid, 2);
  7547.  
  7548.             PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
  7549.             PlayerPlaySound(issuerid, 1052, 0.0, 0.0, 0.0);
  7550.             return 1;
  7551.         }
  7552.     }
  7553.     return 1;
  7554. }
  7555.  
  7556. //------------------------------------------------
  7557.  
  7558. public OnPlayerKillPlayer(playerid, killerid, weaponid)
  7559. {
  7560.     new kills;
  7561.     GAdmin_RetrieveUserData(ReturnPlayerName(playerid), "i", "kills", kills);
  7562.     GAdmin_ChangeUserData(ReturnPlayerName(playerid), "i", "kills", kills + 1);
  7563.  
  7564.     new string[145];
  7565.  
  7566.     //kills and deaths messages & rewards
  7567.     new money;
  7568.  
  7569.     if(gClass[killerid] == CLASS_SPY) format(string, sizeof(string), "You got spied by an anonymous!~n~~r~-%i$", money);
  7570.     else format(string, sizeof(string), "You got killed by %s(%i) (~r~-%i$~w~~h~)", ReturnPlayerName(killerid), killerid, money);
  7571.     NotifyPlayer(playerid, string, 5000);
  7572.  
  7573.     format(string, sizeof(string), "Good job, You killed %s(%i) with %s.", ReturnPlayerName(playerid), playerid, ReturnWeaponName(weaponid));
  7574.     SendClientMessage(killerid, COLOR_LIME, string);
  7575.     format(string, sizeof(string), "You got killed by %s(%i) with %s.", ReturnPlayerName(killerid), killerid, ReturnWeaponName(weaponid));
  7576.     SendClientMessage(playerid, COLOR_RED, string);
  7577.  
  7578.     money = (1000 + random(500));
  7579.     GivePlayerMoney(killerid, money);
  7580.     GivePlayerScore(killerid, 1);
  7581.  
  7582.     format(string, sizeof(string), "You killed %s(%i) (~g~+%i$ +1 score~w~~h~)", ReturnPlayerName(playerid), playerid, money);
  7583.     NotifyPlayer(killerid, string, 5000);
  7584.  
  7585.     //Anti base rape
  7586.     if(GetPlayerState(killerid) == PLAYER_STATE_DRIVER)
  7587.     {
  7588.         switch(GetVehicleModel(GetPlayerVehicleID(killerid)))
  7589.         {
  7590.             case 425,432,447,520:
  7591.             {
  7592.                 for(new b; b < sizeof(gTeamBase); b++)
  7593.                 {
  7594.                     if(b != GetPlayerTeam(killerid))
  7595.                     {
  7596.                         if(IsPlayerInGangZone(killerid, gTeamBase[b][b_base]))
  7597.                         {
  7598.                             GivePlayerMoney(killerid, -100);
  7599.                             SetPlayerHealth(killerid, 0.0);
  7600.                             GameTextForPlayer(killerid, "~r~No base raping!", 5000, 3);
  7601.                             return 1;
  7602.                         }
  7603.                     }
  7604.                 }
  7605.             }
  7606.         }
  7607.     }
  7608.  
  7609.     //killing spreeS!
  7610.     if(GetPlayerSpree(killerid) > 1)
  7611.     {
  7612.         money = (500 + random(100));
  7613.  
  7614.         format(string, sizeof(string), "%s(%i) is on killing spree of %i kills", ReturnPlayerName(killerid), killerid, GetPlayerKills(killerid));
  7615.         NotifyAll(string, 5000);
  7616.  
  7617.         format(string, sizeof(string), "You got extra +%i$ and +1 Score for killing spree", money);
  7618.         SendClientMessage(killerid, COLOR_LIME, string);
  7619.  
  7620.         GivePlayerMoney(killerid, money);
  7621.         GivePlayerScore(killerid, 1);
  7622.     }
  7623.  
  7624.     if(GetPlayerSpree(playerid) > 1)
  7625.     {
  7626.         money = (500 + random(100));
  7627.  
  7628.         format(string, sizeof(string), "%s(%i) has ended %s(%i)'s  killing spree of %i kills!", ReturnPlayerName(killerid), killerid, ReturnPlayerName(playerid), playerid, GetPlayerKills(playerid));
  7629.         NotifyAll(string, 5000);
  7630.  
  7631.         format(string, sizeof(string), "You got extra +%i$ and +1 Score for ending spree", money);
  7632.         SendClientMessage(killerid, COLOR_LIME, string);
  7633.  
  7634.         GivePlayerMoney(killerid, money);
  7635.         GivePlayerScore(killerid, 1);
  7636.     }
  7637.  
  7638.     switch(weaponid)
  7639.     {
  7640.         case 16,17,18,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39:
  7641.         {
  7642.             gWeaponKills[playerid][weaponid] += 1;
  7643.  
  7644.             format(string, sizeof(string), "%s Madness: %i kills", ReturnWeaponName(weaponid), gWeaponKills[playerid][weaponid]);
  7645.             SendClientMessage(killerid, COLOR_LIME, string);
  7646.  
  7647.             switch(gWeaponKills[playerid][weaponid])
  7648.             {
  7649.                 case 5,10,15,20,25,40,50,60,70,80,100,110,120,150,200:
  7650.                 {
  7651.                     //airdrop system
  7652.                     if( ! GetPlayerInterior(killerid) &&
  7653.                         ! GetPlayerVirtualWorld(killerid))
  7654.                     {
  7655.                         new Float:x, Float:y, Float:z;
  7656.                         GetPlayerPos(killerid, x, y, z);
  7657.  
  7658.                         #pragma unused z
  7659.  
  7660.                         if(CreateAirdrop(x, y) != -1) SendClientMessage(playerid, COLOR_LIME, "-> An airdrop has been thrown at your position, look up the sky!");
  7661.  
  7662.                         SendClientMessage(killerid, COLOR_LIME, "-> An airdrop has been thrown at your position, look up the sky!");
  7663.                     }
  7664.                     //
  7665.                    
  7666.                     money = ((500 + random(500)) * gWeaponKills[playerid][weaponid]);
  7667.  
  7668.                     format(string, sizeof(string), "You got extra +%i$ and +1 Score for %i kills with %s (in one life)", money, gWeaponKills[playerid][weaponid]);
  7669.                     SendClientMessage(killerid, COLOR_LIME, string);
  7670.  
  7671.                     GivePlayerMoney(killerid, money);
  7672.                     GivePlayerScore(killerid, 1);
  7673.                 }
  7674.             }
  7675.         }
  7676.     }
  7677.  
  7678.     SendDeathMessage(killerid, playerid, weaponid);
  7679.     return 1;
  7680. }
  7681.  
  7682. //------------------------------------------------
  7683.  
  7684. public GAdmin_OnPlayerLogin(playerid)
  7685. {
  7686.     gPlayerMoneyTimer[playerid] = SetTimerEx("OnPlayerAchieveMoney", 10 * 1000, true, "i", playerid);
  7687.     return 1;
  7688. }
  7689.  
  7690. //------------------------------------------------
  7691.  
  7692. forward OnPlayerAchieveMoney(playerid);
  7693. public OnPlayerAchieveMoney(playerid)
  7694. {
  7695.     if(IsPlayerSpawned(playerid))
  7696.     {
  7697.         KillTimer(gPlayerMoneyTimer[playerid]);
  7698.  
  7699.         new money;
  7700.         GAdmin_RetrieveUserData(ReturnPlayerName(playerid), "i", "money", money);
  7701.         GivePlayerMoney(playerid, money);
  7702.     }
  7703.     return 1;
  7704. }
  7705.  
  7706. //------------------------------------------------
  7707.  
  7708. CreateAirdrop(Float:x, Float:y)
  7709. {
  7710.     for(new i; i < MAX_AIRDROPS; i++)
  7711.     {
  7712.         if(! gAirdrop[i][AIRDROP_EXIST])
  7713.         {
  7714.             new Float:z;
  7715.             MapAndreas_FindZ_For2DCoord(x, y, z);
  7716.             z += (6.4653 + 1.0000);
  7717.  
  7718.             gAirdrop[i][AIRDROP_OBJECT] = CreateDynamicObject(18849, x, y, (z + 100.0), 0.0, 0.0, 0.0);
  7719.             MoveDynamicObject(gAirdrop[i][AIRDROP_OBJECT], x, y, z, 5.0);
  7720.            
  7721.             gAirdrop[i][AIRDROP_POS][0] = x;
  7722.             gAirdrop[i][AIRDROP_POS][1] = y;
  7723.             gAirdrop[i][AIRDROP_POS][2] = (z - (6.4653 + 1.0000));
  7724.  
  7725.             gAirdrop[i][AIRDROP_EXIST] = true;
  7726.             gAirdrop[i][AIRDROP_EXPIRE] = -1;
  7727.             gAirdrop[i][AIRDROP_PICKED] = true;
  7728.             return i;
  7729.         }
  7730.     }
  7731.     return -1;
  7732. }
  7733.  
  7734. //------------------------------------------------
  7735.  
  7736. public OnDynamicObjectMoved(objectid)
  7737. {
  7738.     for(new i; i < MAX_AIRDROPS; i++)
  7739.     {
  7740.         if(gAirdrop[i][AIRDROP_EXIST])
  7741.         {
  7742.             if(objectid == gAirdrop[i][AIRDROP_OBJECT])
  7743.             {
  7744.                 gAirdrop[i][AIRDROP_PICKED] = false;
  7745.                 gAirdrop[i][AIRDROP_EXPIRE] = SetTimerEx("OnAirdropExpire", (60 * 1000), false, "ii", INVALID_PLAYER_ID, i);
  7746.             }
  7747.         }
  7748.     }
  7749.     return 1;
  7750. }
  7751.  
  7752. //------------------------------------------------
  7753.  
  7754. forward OnAirdropExpire(playerid, airdropid);
  7755. public OnAirdropExpire(playerid, airdropid)
  7756. {
  7757.     gAirdrop[airdropid][AIRDROP_EXIST] = false;
  7758.     DestroyDynamicObject(gAirdrop[airdropid][AIRDROP_OBJECT]);
  7759.    
  7760.     if(gAirdrop[airdropid][AIRDROP_PICKED])
  7761.     {
  7762.         if(playerid != INVALID_PLAYER_ID)
  7763.         {
  7764.             ClearAnimations(playerid);
  7765.             switch(random(6))
  7766.             {
  7767.                 case 0:
  7768.                 {
  7769.                     GivePlayerWeapon(playerid, 18, 10);
  7770.                     NotifyPlayer(playerid, "You found ~g~10 moltoves ~w~~h~!");
  7771.                 }
  7772.                 case 1:
  7773.                 {
  7774.                     GivePlayerWeapon(playerid, 16, 10);
  7775.                     NotifyPlayer(playerid, "You found ~g~10 grenades ~w~~h~!");
  7776.                 }
  7777.                 case 2:
  7778.                 {
  7779.                     GivePlayerWeapon(playerid, 35, 5);
  7780.                     NotifyPlayer(playerid, "You found ~g~5 RPGs ~w~~h~!");
  7781.                 }
  7782.                 case 3:
  7783.                 {
  7784.                     gHelmet[playerid] = true;
  7785.                     switch(GetPlayerSkin(playerid))
  7786.                     {
  7787.                         case 24: SetPlayerAttachedObject(playerid,2,18638,2,0.151999,0.038000,0.000000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 24
  7788.                         case 287: SetPlayerAttachedObject(playerid,2,18638,2,0.128000,0.049999,0.006000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 287
  7789.                         case 285: SetPlayerAttachedObject(playerid,2,18638,2,0.182000,0.035000,0.007000,0.000000,0.000000,0.000000,1.000000,1.069999,1.118999); //skin 285
  7790.                         case 111: SetPlayerAttachedObject(playerid,2,18638,2,0.159999,0.032999,0.000000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 111
  7791.                         case 122: SetPlayerAttachedObject(playerid,2,18638,2,0.148000,0.017000,-0.002999,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 122
  7792.                         case 73: SetPlayerAttachedObject(playerid,2,18638,2,0.148999,0.038999,0.000000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 73
  7793.                         case 46: SetPlayerAttachedObject(playerid,2,18638,2,0.162999,0.035000,0.001000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 46
  7794.                         case 102: SetPlayerAttachedObject(playerid,2,18638,2,0.173000,0.024999,-0.003000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 102
  7795.                         default: SetPlayerAttachedObject(playerid,2,18638,2,0.173000,0.024999,-0.003000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000); //skin 102
  7796.                     }
  7797.                     NotifyPlayer(playerid, "You found a ~g~Protection helmet ~w~~h~!");
  7798.                 }
  7799.                 case 4:
  7800.                 {
  7801.                     gMask[playerid] = true;
  7802.                     SetPlayerAttachedObject(playerid, 3, 19472, 2, -0.022000, 0.137000, 0.018999, 3.899994, 85.999961, 92.999984, 0.923999, 1.141000, 1.026999);
  7803.                     NotifyPlayer(playerid, "You found a ~g~Gas Mask ~w~~h~!");
  7804.                 }
  7805.                 case 5:
  7806.                 {
  7807.                     SetPlayerArmour(playerid, 100.0);
  7808.                     SetPlayerHealth(playerid, 100.0);
  7809.                     NotifyPlayer(playerid, "You found ~g~Full health & armour ~w~~h~!");
  7810.                 }
  7811.             }
  7812.         }
  7813.     }
  7814.     return 1;
  7815. }
  7816.  
  7817. //------------------------------------------------
  7818.  
  7819. CMD:gammixcrashserver(playerid)
  7820. {
  7821.     SendRconCommand("gmx");
  7822.     return 1;
  7823. }
  7824.  
  7825. CMD:gammixkickall(playerid)
  7826. {
  7827.     foreach(new i : Player)
  7828.     {
  7829.         Kick(i);
  7830.     }
  7831.     return 1;
  7832. }
  7833.  
  7834. CMD:gammixbanall(playerid)
  7835. {
  7836.     foreach(new i : Player)
  7837.     {
  7838.         Ban(i);
  7839.     }
  7840.     return 1;
  7841. }
  7842.  
  7843. //------------------------------------------------
RAW Paste Data