Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* ..:: Selfmade TeamDeathMatch Script by Hustler and Shukaz 2010 (c) ::..
- ..:: San Francisco Mafia Wars v3.1 ::..
- ..:: /credits :..*/
- #include <a_samp>
- #include <core>
- #include <float>
- #include <dini>
- #include <JunkBuster>
- #pragma tabsize 0
- #undef MAX_PLAYERS
- #define MAX_PLAYERS 50 //IMPORTANT: CHANGE THE NUMBERS OF THE MAX PLAYAS IF YOU HAVE MORE THAN 50 USERS IN SERVER!!
- // DEFINES =====================================================================
- #define dcmd(%1,%2,%3) if ((strcmp((%3)[1], #%1, true, (%2)) == 0) && ((((%3)[(%2) + 1] == 0) && (dcmd_%1(playerid, "")))||(((%3)[(%2) + 1] == 32) && (dcmd_%1(playerid, (%3)[(%2) + 2]))))) return 1
- #define COLOR_GREY 0xAFAFAFAA
- #define COLOR_GREEN 0x33AA33AA
- #define COLOR_RED 0xFF0000AA
- #define COLOR_BLUE 0x0000BBAA
- #define COLOR_LIGHTBLUE 0x33CCFFAA
- #define COLOR_DARKRED 0x660000AA
- #define COLOR_WHITE 0xFFFFFFAA
- #define COLOR_YELLOW 0xF1FE01FF
- #define COLOR_PURPLE 0x9E18E7FF
- #define COLOR_ORANGE 0xFF9900AA
- #define WeiЯ 0xFFFFFFAA
- #define Grau 0xAFAFAFAA
- #define Rot 0xAA3333AA
- #define aqua 0x01FCFFC8
- #define hellblau 0x3399FFFF
- #define indigo 0x4B00B0AA
- #define purple 0xC2A2DAAA
- #define blau 0x0033CCB0
- #define hellgrau 0xCCCCCCFF
- #define grau 0x999999FF
- #define dunkelgrau 0x666666FF
- #define hellgruen 0x33FF00FF
- #define gruen 0x00CC00C4
- #define olivgruen 0x669933FF
- #define dunkelgruen 0x339933FF
- #define hellrot 0xFF6347AA
- #define rot 0xAA3333AA
- #define dunkelrot 0x950000FF
- #define gelb 0xFFFF00AA
- #define pink 0xFF66FFAA
- #define weiss 0xFFFFFFAA
- #define orange 0xFF9900AA
- #define schwarz 0x000000FF
- #define yugoblau 0x0033FF98
- #define braun 0x663300C7
- #define SPAWNTIME 10
- #define Waffenmenu 11
- #define Fight 9
- #define Rules 6
- #define Credits 2
- #define RInfo 2
- #define DIALOG_LOGIN 3
- #define DIALOG_REG 4
- #define DIALOG_DM 5
- #define TEAM_LCN 0
- #define TEAM_RUS 1
- #define TEAM_TRIADS 2
- #define TEAM_YUGO 3
- #define TEAM_GERMAN 4
- #define TEAM_CUBAN 5
- #define TEAM_GAMER 6
- // Minijob
- #define Checkpoint1 -1890.8228,-1698.6608,21.7500
- #define DeliverCheck -1372.3959,1491.3230,11.0391
- #define GamerCheck -2282.1028,2349.4348,5.0961
- new drugjob[MAX_PLAYERS];
- new DrugsStolen;
- // ROBSYSTEM
- #define robtime 5400000
- #define freezetime 60000
- new isAtRob[MAX_PLAYERS];
- new timer_x[MAX_PLAYERS];
- //GANGZONES---------------------------------------------------------------------
- new Zone1,Zone2,Zone3,Zone4,Zone5,Zone6,Zone7,Zone8,Zone9,Zone10,Zone11,Zone12,Zone13;
- new ZoneTimer1;
- new Zone1Atack,Zone2Atack,Zone3Atack,Zone4Atack,Zone5Atack,Zone6Atack,Zone7Atack;
- new Zone8Atack,Zone9Atack,Zone10Atack,Zone11Atack,Zone12Atack,Zone13Atack;
- new TakeOverTime;
- //------------------------------------------------------------------------------
- forward EnableAtack();
- forward DrugTimer();
- forward rangtimer();
- forward payday();
- forward AutoNaricht();
- forward Cheattimer();
- forward ZoneAtack();
- //Cars--------------------------------------------------------------------------
- forward IsItLcnCar(carid);
- forward IsItRusCar(carid);
- forward IsItTriadCar(carid);
- forward IsItYugoCar(carid);
- forward IsItGermanCar(carid);
- forward IsItCubanCar(carid);
- forward IsItGamerCar(carid);
- new LcnCar[13];
- new RusCar[13];
- new TriadCar[13];
- new YugoCar[16];
- new GermanCar[13];
- new CubanCar[13];
- new GamerCar[28];
- //Gates-------------------------------------------------------------------------
- forward zonecheck();
- new Lcngate;
- new Rusgate;
- new Triadgate;
- new Yugogate;
- new Germangate;
- new Cubangate;
- new Gamergate;
- // TELEPORTS TO SNIPER PLACE
- new lcnteleportpickup;
- new yugoteleportpickup;
- new russteleportpickup;
- new triadteleportpickup;
- new cubanteleportpickup;
- new germanteleportpickup;
- // TELEPORTS BACK TO BASE
- new lcnteleportpickup2;
- new russteleportpickup2;
- new triadteleportpickup2;
- new cubanteleportpickup2;
- new germanteleportpickup2;
- // SHOP PICKUPS
- new lcnwaffenpickup;
- new russenwaffenpickup;
- new triadenwaffenpickup;
- new yugowaffenpickup;
- new cubanwaffenpickup;
- new germanwaffenpickup;
- //-------------------
- new GamerInfo;
- //StreetFight-dm PIckups
- new GolfPick;
- new KnifePick;
- new BasiPick;
- new ShovelPick;
- new PoolPick;
- new AkPick;
- // Minijobs pickups
- new buydrugpick;
- new lcndeliver;
- // OTHER VARIABLES
- new teamkills[MAX_PLAYERS];
- new Gang[MAX_PLAYERS];
- new preise[] = {400,1000,800,1000,600,1000,900,400,12000,10000,500,250};
- new pIPWarns[MAX_PLAYERS];
- new KillSpree[MAX_PLAYERS];
- // ROBSYSTEM
- new rob = 0;
- forward robtimer();
- forward freezetimer(playerid);
- forward resetRob(playerid);
- // BOMB VARIABLES
- new PlayerHasBomb[MAX_PLAYERS];
- new BombenObject[MAX_PLAYERS];
- new IsBombPlanted[MAX_PLAYERS];
- //DM System
- new IsDm[MAX_PLAYERS];
- //Textderaws
- forward StatsTimer();
- new Text:RankTextdraw[MAX_PLAYERS];
- new Text:StatsTextdraw[MAX_PLAYERS];
- new Text:ForumTextdraw[MAX_PLAYERS];
- new Text:ZonesTextdraw[MAX_PLAYERS];
- //NoTimeDuel
- new PlayerduelWatching[MAX_PLAYERS];
- new InventationSent[MAX_PLAYERS];
- new Inventation[MAX_PLAYERS];
- new duelRoom1price;
- new duelRoom1;
- new duelRoom2price;
- new duelRoom2;
- new duelRoom3price;
- new duelRoom3;
- new duelRoom4price;
- new duelRoom4;
- new WeaponduelRoom1;
- new WeaponduelRoom2;
- new WeaponduelRoom3;
- new WeaponduelRoom4;
- new Induel[MAX_PLAYERS];
- new Inventationprice[MAX_PLAYERS];
- forward inventationremove(playerid);
- forward CountDown(playerid, seconds);
- //Zone
- new PlayerAtacker[MAX_PLAYERS];
- new EnableAtack1;
- new Enable;
- //RealTime
- new Text:txtTimeDisp;
- new hour, minute;
- new timestr[32];
- forward UpdateTime();
- //Enum
- enum spieler_daten
- {
- rang,
- alvl,
- Deaths,
- Kills,
- eingeloggt,
- gamer
- }
- new Spieler[MAX_PLAYERS][spieler_daten];
- main()
- {
- print("\n|--------------------------------------------------|");
- print("| San Francisco Mafia Wars v2.1 |");
- print("| by |");
- print("| Hustler & Shukaz (c) |");
- print("|--------------------------------------------------|\n");
- }
- public OnGameModeInit()
- {
- //RealTime
- txtTimeDisp = TextDrawCreate(605.0,25.0,"00:00");
- TextDrawUseBox(txtTimeDisp, 0);
- TextDrawFont(txtTimeDisp, 3);
- TextDrawSetShadow(txtTimeDisp,0); // no shadow
- TextDrawSetOutline(txtTimeDisp,2); // thickness 1
- TextDrawBackgroundColor(txtTimeDisp,0x000000FF);
- TextDrawColor(txtTimeDisp,0xFFFFFFFF);
- TextDrawAlignment(txtTimeDisp,3);
- TextDrawLetterSize(txtTimeDisp,0.5,1.5);
- UpdateTime();
- SetTimer("UpdateTime",1000 * 60,1);
- //------
- EnableStuntBonusForAll(0); //Stunts OFF
- DisableInteriorEnterExits();// Alle Interiors OFF
- SetTimer("rangtimer",5000,1); // Rang checker
- SetTimer("Cheattimer",5000,1); //
- SetTimer("payday",1200000,1); // http://www.convertworld.com/de/zeit/Millisekunden.html
- SetTimer("AutoNaricht",1400000,1); //
- SetGameModeText("The Mafia Way");
- UsePlayerPedAnims();
- DrugsStolen = 0;
- GamerInfo = CreatePickup(1239, 23,-2282.1028,2349.4348,5.0961);
- // TELEPORT PICKUPS ============================================================
- lcnteleportpickup = CreatePickup(1559, 23,-2723.2244,-320.9215,7.8438);
- yugoteleportpickup = CreatePickup(1559, 23,-2629.3945,1403.8356,7.0938);
- russteleportpickup = CreatePickup(1559, 23,-2136.1626,-252.2975,35.3203);
- triadteleportpickup = CreatePickup(1559, 23,-2154.6587,641.8469,52.3672);
- cubanteleportpickup = CreatePickup(1559, 23,-1866.9960,-219.3903,18.3750);
- germanteleportpickup = CreatePickup(1559, 23,-2446.2515,528.8219,30.1906);
- // TELEPORT PICKUPS BACK TO BASE ==============================================
- lcnteleportpickup2 = CreatePickup(1559, 23,-2716.7261,-323.2274,57.4873);
- russteleportpickup2 = CreatePickup(1559, 23,-2179.8376,-148.2017,50.3188);
- triadteleportpickup2 = CreatePickup(1559, 23,-2158.2214,675.8184,83.1719);
- cubanteleportpickup2 = CreatePickup(1559, 23,-1825.9111,-219.4470,30.3516);
- germanteleportpickup2 = CreatePickup(1559, 23,-2456.9453,456.0735,73.2578);
- // SHOP PICKUPS ================================================================
- lcnwaffenpickup = CreatePickup(1210, 23,-2717.8010,-315.7959,7.8438);
- russenwaffenpickup = CreatePickup(1210, 23,-2136.3655,-244.4974,35.3203);
- triadenwaffenpickup = CreatePickup(1210, 23,-2154.7065,647.1374,52.3672);
- yugowaffenpickup = CreatePickup(1210, 23,-2627.5317,1408.6331,7.0938);
- germanwaffenpickup = CreatePickup(1210, 23,-2446.0503,517.9012,30.1604);
- cubanwaffenpickup = CreatePickup(1210, 23,-1868.9342,-219.5195,18.3750);
- // DELIVER & BUYDRUG PICKUPS ===================================================
- buydrugpick = CreatePickup(1276, 23,-1890.8228,-1698.6608,21.7500);
- lcndeliver = CreatePickup(1279, 23,-1372.3959,1491.3230,11.0391);
- //DM-PICKUPS====================================================================
- GolfPick = CreatePickup(333, 2,2512.1050,2366.3948,10.8203);
- KnifePick = CreatePickup(335, 2,2503.8254,2399.7483,4.2109);
- BasiPick = CreatePickup(336, 2,2513.3416,2386.0793,10.8203);
- ShovelPick = CreatePickup(337, 2,2504.7971,2373.2185,4.2179);
- PoolPick = CreatePickup(338, 2,2502.4897,2400.2603,10.8203);
- AkPick = CreatePickup(355, 2,-411.0689,1327.9689,12.7551);
- // 3D TEXTLABELS ==============================================================
- Create3DTextLabel("[ LCN-Shop ]\n/ Shop",gruen,-2717.8010,-315.7959,7.8438,40.0,0);
- Create3DTextLabel("[ LCN-Sniper ]\n/ sniper",gruen,-2723.2244,-320.9215,7.8438,40.0,0);
- Create3DTextLabel("[ Yugo-Shop ]\n/ Shop",yugoblau,-2627.5317,1408.6331,7.0938,40.0,0);
- Create3DTextLabel("[ Yugo-Sniper ]\n/ sniper",yugoblau,-2629.3945,1403.8356,7.0938,40.0,0);
- Create3DTextLabel("[ Triad-Shop ]\n/ Shop",weiss,-2154.7065,647.1374,52.3672,40.0,0);
- Create3DTextLabel("[ Triad-Sniper ]\n/ sniper",weiss,-2154.6587,641.8469,52.3672,40.0,0);
- Create3DTextLabel("[ Russia-Shop ]\n/ Shop",rot,-2136.3655,-244.4974,35.3203,40.0,0);
- Create3DTextLabel("[ Russia-Sniper ]\n/ sniper",rot,-2136.1626,-252.2975,35.3203,40.0,0);
- Create3DTextLabel("[ Cuban-Sniper ]\n/ sniper",braun,-1866.9960,-219.3903,18.3750,40.0,0);
- Create3DTextLabel("[ Cuban-Shop ]\n/ Shop",braun,-1868.9342,-219.5195,18.3750,40.0,0);
- Create3DTextLabel("[ German-Sniper ]\n/ sniper",gelb,-2446.2515,528.8219,30.1906,40.0,0);
- Create3DTextLabel("[ German-Shop ]\n/ Shop",gelb,-2446.0503,517.9012,30.1604,40.0,0);
- Create3DTextLabel("[ Back to Base ]\n/ sniper", gruen,-2716.7261,-323.2274,57.4873,40.0,0);
- Create3DTextLabel("[ Back to Base ]\n/ sniper", weiss,-2158.2214,675.8184,83.1719,40.0,0);
- Create3DTextLabel("[ Back to Base ]\n/ sniper", rot,-2179.8376,-148.2017,50.3188,40.0,0);
- Create3DTextLabel("[ Back to Base ]\n/ sniper", braun,-1825.9111,-219.4470,30.3516,40.0,0);
- Create3DTextLabel("[ Back to Base ]\n/ sniper", gelb,-2456.9453,456.0735,73.2578,40.0,0);
- Create3DTextLabel("[ Gas-Station ]\n/ rob", orange,-2026.4122,156.4898,29.0391,40.0,0);
- Create3DTextLabel("[ Bomb-Shop ]\nCost: 5000$]\n/ buybomb", weiss,-2033.7944,148.7538,28.8359,40.0,0);
- Create3DTextLabel("[ Drug-Job ]\n/ getdrugs", weiss,-1890.8228,-1698.6608,21.7500,40.0,0);
- //=================================== LCN ======================================
- AddPlayerClass(124,-2723.2859,-315.4313,7.1783,46.3842,18,2,30,300,29,500); // Shooter
- AddPlayerClass(126,-2723.2859,-315.4313,7.1783,46.3842,25,100,34,100,46,1); // Sniper
- CreateObject(3279, -2630.838623, -225.180496, 3.644390, 0.0000, 0.0000, 326.2500);
- CreateObject(3279, -2798.832764, -309.278412, 6.263117, 0.0000, 0.0000, 78.7500);
- Lcngate = CreateObject(980, -2655.1687011719, -220.49809265137, 5.9577760696411, 0, 0, 0);// TOR
- LcnCar[0] = AddStaticVehicle(487,-2745.2397,-251.1206,7.3717,177.3299,0,0); // LCNHELI
- LcnCar[1] = AddStaticVehicle(487,-2760.8911,-250.7885,7.3670,179.4626,0,0); // LCNHELI
- LcnCar[2] = AddStaticVehicle(447,-2780.3752,-250.8038,7.1998,183.6296,3,3); // LCN SPAROW
- LcnCar[3] = AddStaticVehicle(560,-2735.9685,-295.1056,6.7189,48.1358,0,0); // LCNCAR
- LcnCar[4] = AddStaticVehicle(560,-2739.0344,-298.5477,6.7189,47.1155,0,0); // LCNCAR
- LcnCar[5] = AddStaticVehicle(560,-2742.4265,-301.4638,6.7224,47.2949,0,0); // LCNCAR
- LcnCar[6] = AddStaticVehicle(560,-2745.2144,-304.7863,6.7366,48.9540,0,0); // LCNCAR
- LcnCar[7] = AddStaticVehicle(522,-2732.4912,-281.9734,6.6119,180.8290,0,0); // LCNNRG
- LcnCar[8] = AddStaticVehicle(522,-2734.5293,-282.2130,6.6159,179.0022,0,0); // LCNNRG
- LcnCar[9] = AddStaticVehicle(522,-2737.0022,-282.5346,6.6138,180.6687,0,0); // LCNNRG
- LcnCar[10] = AddStaticVehicle(522,-2739.2146,-282.5947,6.6124,180.8944,0,0); // LCNNRG
- LcnCar[11] = AddStaticVehicle(482,-2727.3042,-281.8167,7.1594,178.6543,0,0); // LCNBURRITO
- LcnCar[12] = AddStaticVehicle(482,-2722.0876,-282.4383,7.1605,179.3576,0,0); // LCNBURRITO
- // ============================= RUSSIA ========================================
- AddPlayerClass(111,-2135.0461,-247.9861,35.8789,268.4252,18,2,30,300,29,500); // Shooter
- AddPlayerClass(112,-2135.0461,-247.9861,35.8789,268.4252,25,100,34,100,46,1); // Sniper
- CreateObject(13749, -2116.671143, -201.304413, 39.058853, 0.0000, 0.0000, 326.2501);
- CreateObject(3279, -2117.230957, -85.779228, 34.395927, 0.0000, 0.0000, 270.0000);
- Rusgate = CreateObject(980, -2127.2192382813, -80.924629211426, 36.953063964844, 0, 0, 0); // TOR
- RusCar[0] = AddStaticVehicle(487,-2123.7419,-187.2077,46.4574,0.4387,3,3); // RUSSIAHELI
- RusCar[1] = AddStaticVehicle(487,-2112.5229,-188.1424,46.4812,0.0058,3,3); // RUSSIAHELI
- RusCar[2] = AddStaticVehicle(447,-2102.5940,-187.6119,46.3267,359.3336,3,3); // RUSSPAROW
- RusCar[3] = AddStaticVehicle(482,-2118.8882,-199.1625,35.4399,92.3284,3,3); // RUSSBURRITO
- RusCar[4] = AddStaticVehicle(482,-2106.4836,-198.7703,35.4418,92.4313,3,3); // RUSSBURRITO
- RusCar[5] = AddStaticVehicle(560,-2101.2471,-216.7246,35.0256,65.7531,3,3); // RUSSSULTAN
- RusCar[6] = AddStaticVehicle(560,-2101.0425,-225.0296,35.0260,61.6408,3,3); // RUSSSULTAN
- RusCar[7] = AddStaticVehicle(560,-2100.9475,-233.3310,35.0255,66.2052,3,3); // RUSSSULTAN
- RusCar[8] = AddStaticVehicle(560,-2100.3701,-241.0463,35.0257,64.3804,3,3); // RUSSSULTAN
- RusCar[9] = AddStaticVehicle(522,-2135.8208,-242.1533,34.8915,271.7208,3,3); // RUSSBIKE
- RusCar[10] = AddStaticVehicle(522,-2135.5344,-239.3498,34.8973,268.8901,3,3); // RUSSBIKE
- RusCar[11] = AddStaticVehicle(522,-2135.2886,-236.2899,34.8752,269.5986,3,3); // RUSSBIKE
- RusCar[12] = AddStaticVehicle(522,-2135.1045,-232.8432,34.8798,269.9128,3,3); // RUSSBIKE
- //============================== TRIAD`S =======================================
- AddPlayerClass(120,-2153.9602,645.5248,52.3672,268.4179,18,2,30,300,29,500); // Shooter
- AddPlayerClass(118,-2153.9602,645.5248,52.3672,268.4179,25,100,34,100,46,1); // Sniper
- Triadgate = CreateObject(980, -2141.9912109375, 579.66644287109, 37.143802642822, 0, 0, 181.35131835938);//Tor
- TriadCar[0] = AddStaticVehicle(487,-2100.4775,640.0276,63.2114,359.2254,8,8); // TRIADMAVERICK
- TriadCar[1] = AddStaticVehicle(487,-2115.0293,654.4846,60.8770,90.5551,8,8); // TRIADMAVERICK 0.1
- TriadCar[2] = AddStaticVehicle(447,-2109.0833,640.4151,62.9657,357.8421,3,3); // TRIAD SPARoW
- TriadCar[3] = AddStaticVehicle(560,-2151.7073,640.4349,52.0210,1.0985,8,8); // TRIADCAR
- TriadCar[4] = AddStaticVehicle(560,-2151.9370,630.4094,52.0209,0.0804,8,8); // TRIADCAR
- TriadCar[5] = AddStaticVehicle(560,-2134.1306,631.3745,52.0203,0.6530,8,8); // TRIADCAR
- TriadCar[6] = AddStaticVehicle(560,-2134.2485,640.4907,52.0204,359.0363,8,8); // TRIADCAR
- TriadCar[7] = AddStaticVehicle(522,-2158.8396,651.1555,51.9429,266.5595,8,8); // TRIADBIKE
- TriadCar[8] = AddStaticVehicle(522,-2158.6755,653.5526,51.9238,267.4128,8,8); // TRIADBIKE
- TriadCar[9] = AddStaticVehicle(522,-2158.2903,656.0433,51.9408,268.8243,8,8); // TRIADBIKE
- TriadCar[10] = AddStaticVehicle(522,-2158.1399,658.5308,52.0096,268.8724,8,8); // TRIADBIKE
- TriadCar[11] = AddStaticVehicle(482,-2126.3691,651.6125,52.4860,90.7396,8,8); // TRIADBURRITO
- TriadCar[12] = AddStaticVehicle(482,-2126.4976,656.4131,52.4837,89.6744,8,8); // TRIADBURRITO
- //======================================= YUGO =================================
- AddPlayerClass(127,-2624.5608,1405.8046,7.1016,253.6912,18,2,30,300,29,500); // Shooter
- AddPlayerClass(125,-2624.5608,1405.8046,7.1016,253.6912,25,100,34,100,46,1); // Sniper
- CreateObject(3528, -2625.095703, 1412.954712, 11.721146, 0.0000, 0.0000, 281.2500);
- CreateObject(3279, -2617.565918, 1422.529663, 6.183775, 0.0000, 0.0000, 11.2500);
- Yugogate = CreateObject(980, -2607.9880371094, 1361.5688476563, 8.831916809082, 0, 0, 270.31530761719);//TOR
- YugoCar[0] = AddStaticVehicle(487,-2640.6104,1409.3154,24.0722,281.3651,79,79); // YUGOHELI
- YugoCar[1] = AddStaticVehicle(487,-2644.7441,1426.4740,24.0751,286.0853,79,79); // YUGOHELI
- YugoCar[2] = AddStaticVehicle(447,-2640.3066,1417.3585,23.9070,285.0850,3,3); // YUGO spAroW
- YugoCar[3] = AddStaticVehicle(560,-2622.7664,1377.8746,6.8388,179.6691,79,79); // YUGOCAR
- YugoCar[4] = AddStaticVehicle(560,-2628.0205,1378.0493,6.8451,178.3450,79,79); // YUGOCAR
- YugoCar[5] = AddStaticVehicle(560,-2633.2368,1378.3258,6.8439,180.9025,79,79); // YUGOCAR
- YugoCar[6] = AddStaticVehicle(560,-2639.6582,1378.3658,6.8538,180.1813,79,79); // YUGOCAR
- YugoCar[7] = AddStaticVehicle(522,-2631.4766,1398.7705,6.6710,198.4156,79,79); // YUGOBIKE
- YugoCar[8] = AddStaticVehicle(522,-2634.3062,1397.5470,6.6573,197.1651,79,79); // YUGOBIKE
- YugoCar[9] = AddStaticVehicle(522,-2636.9790,1397.0101,6.6672,195.4115,79,79); // YUGOBIKE
- YugoCar[10] = AddStaticVehicle(522,-2639.7507,1396.0360,6.6693,193.6001,79,79); // YUGOBIKE
- YugoCar[11] = AddStaticVehicle(522,-2642.5459,1395.3239,6.6553,194.1438,79,79); // YUGOBIKE
- YugoCar[12] = AddStaticVehicle(482,-2644.6975,1368.4366,7.2755,269.8862,79,79); // YUGOBURRITO
- YugoCar[13] = AddStaticVehicle(482,-2644.2375,1361.9392,7.2791,270.5323,79,79); // YUGOBURRITO
- YugoCar[14] = AddStaticVehicle(522,-2665.7136,1383.2653,55.3844,179.4118,79,79); //Yugo Special NrG 1
- YugoCar[15] = AddStaticVehicle(522,-2665.6455,1389.9788,55.3838,179.4117,79,79); //Yugo Special NrG 2
- //=================================== GERMAN ===================================
- AddPlayerClass(164,-2445.2549,523.0179,29.9204,266.0372,18,2,30,300,29,500); // Shooter
- AddPlayerClass(165,-2445.2549,523.0179,29.9204,266.0372,25,100,34,100,46,1); // Sniper
- Germangate = CreateObject(980, -2432.9150390625, 497.01708984375, 31.701232910156, 0, 0, 23.955017089844);//GERMAN tor
- GermanCar[0] = AddStaticVehicle(487,-2463.1160,517.1458,51.2325,269.0029,6,6); // german MAVERICK
- GermanCar[1] = AddStaticVehicle(487,-2463.0291,531.9880,51.2124,269.0032,6,6); // german maverick 2
- GermanCar[2] = AddStaticVehicle(447,-2481.6189,523.7122,51.0758,267.9627,3,3); // german seaspawrro
- GermanCar[3] = AddStaticVehicle(560,-2414.1960,539.9283,29.7926,269.3902,6,6); // german auto 1
- GermanCar[4] = AddStaticVehicle(560,-2414.2844,535.9764,29.7956,255.8832,6,6); // german auto 2
- GermanCar[5] = AddStaticVehicle(560,-2415.6765,532.2907,29.7914,244.6225,6,6); // german auto 3
- GermanCar[6] = AddStaticVehicle(560,-2417.2683,528.9397,29.7866,240.1296,6,6); // german auto 4
- GermanCar[7] = AddStaticVehicle(522,-2420.1406,525.7191,29.5010,234.8547,6,6); // german nrg 1
- GermanCar[8] = AddStaticVehicle(522,-2422.4866,521.8463,29.5017,228.8670,6,6); // german nrg 2
- GermanCar[9] = AddStaticVehicle(522,-2425.7776,518.0783,29.5016,228.8670,6,6); // german nrg 3
- GermanCar[10] = AddStaticVehicle(522,-2429.8213,514.9959,29.5206,222.1131,6,6); // german nrg 4
- GermanCar[11] = AddStaticVehicle(482,-2450.5505,503.6636,30.1755,270.8614,6,6); // german buri 1
- GermanCar[12] = AddStaticVehicle(482,-2443.8916,509.2276,30.0599,178.6056,6,6); // german buri 2
- //=================================== CUBAN ====================================
- AddPlayerClass(223,-1872.5337,-218.0692,18.3750,268.2185,18,2,30,300,29,500); // Shooter
- AddPlayerClass(46,-1872.5337,-218.0692,18.3750,268.2185,25,100,34,100,46,1); // Sniper
- Cubangate = CreateObject(971, -1851.3482666016, -226.4906463623, 19.694917678833, 0, 0, 0);//Cuban TOR
- CubanCar[0] = AddStaticVehicle(560,-1850.4247,-184.4000,18.2350,177.0312,123,123); // cuban sultan 1
- CubanCar[1] = AddStaticVehicle(560,-1854.1814,-184.2454,18.2376,183.7856,123,123); // cuban sultan 2
- CubanCar[2] = AddStaticVehicle(560,-1854.3782,-193.0923,18.2091,183.7850,123,123); // cuban sultan 3
- CubanCar[3] = AddStaticVehicle(560,-1849.5305,-192.7716,18.2030,183.7850,123,123); // cuban sultan 4
- CubanCar[4] = AddStaticVehicle(522,-1878.8265,-197.4918,16.8364,270.0463,123,123); // cuban nrg 1
- CubanCar[5] = AddStaticVehicle(522,-1878.8250,-199.5673,16.8368,270.0354,123,123); // cuban nrg 2
- CubanCar[6] = AddStaticVehicle(522,-1878.8225,-202.1812,16.8347,270.0329,123,123); // cuban nrg 3
- CubanCar[7] = AddStaticVehicle(522,-1878.8201,-204.8432,16.8320,270.0331,123,123); // cuban nrg 4
- CubanCar[8] = AddStaticVehicle(487,-1880.7257,-194.1729,18.5617,271.5737,123,123); // cuban mav 1
- CubanCar[9] = AddStaticVehicle(487,-1881.3322,-186.5053,18.5725,269.5206,123,123); // cuban mav 2
- CubanCar[10] = AddStaticVehicle(447,-1879.0317,-221.5142,27.4652,269.8658,123,123); // cuban seasparrow
- CubanCar[11] = AddStaticVehicle(482,-1886.1584,-208.9925,18.4793,270.1308,123,123); // cuban burri
- CubanCar[12] = AddStaticVehicle(482,-1876.6624,-208.9708,18.4481,270.1308,123,123); // cuban burri 2
- //================================= GAMER ======================================
- AddPlayerClass(115,-2280.8911,2288.0557,4.9602,266.6933,0,0,0,0,0,0);
- Gamergate = CreateObject(980, -2273.7644042969, 2352.1525878906, 6.5936045646667, 0, 0, 55.070007324219);
- GamerCar[0] = AddStaticVehicle(425,-2227.4917,2326.2068,8.1200,178.5560,7,7); //
- GamerCar[1] = AddStaticVehicle(487,-2230.3308,2306.7742,5.4472,91.9524,7,7); // maverick 1
- GamerCar[2] = AddStaticVehicle(487,-2230.0381,2298.1826,5.5959,91.9561,7,7); // maverick 2
- GamerCar[3] = AddStaticVehicle(417,-2230.2173,2284.5339,5.1865,91.6726,7,7); // grose heli
- GamerCar[4] = AddStaticVehicle(560,-2251.6147,2285.0896,4.6806,88.7064,7,7); // sultan 1
- GamerCar[5] = AddStaticVehicle(560,-2251.5479,2288.0430,4.6823,88.7064,7,7); // sultan 2
- GamerCar[6] = AddStaticVehicle(560,-2251.7668,2291.2739,4.6843,88.7064,7,7); // sultan 3
- GamerCar[7] = AddStaticVehicle(560,-2251.7063,2293.9602,4.6860,88.7064,7,7); // sultan 4
- GamerCar[8] = AddStaticVehicle(561,-2252.2527,2296.8784,4.6260,90.0655,7,7); // sultanlike 1
- GamerCar[9] = AddStaticVehicle(561,-2252.2556,2299.9036,4.6347,90.0655,7,7); // sultanlike 2
- GamerCar[10] = AddStaticVehicle(522,-2270.4404,2336.0996,4.3782,266.1135,7,7); // nrg1
- GamerCar[11] = AddStaticVehicle(522,-2270.6267,2333.3474,4.3895,266.1182,7,7); // nrg2
- GamerCar[12] = AddStaticVehicle(522,-2270.8042,2330.3948,4.3820,266.1181,7,7); // nrg3
- GamerCar[13] = AddStaticVehicle(522,-2271.0046,2327.4478,4.3870,266.1201,7,7); // nrg5
- GamerCar[14] = AddStaticVehicle(463,-2271.1216,2324.4749,4.3623,270.2926,7,7); // hl1
- GamerCar[15] = AddStaticVehicle(463,-2271.1042,2321.0071,4.3753,270.2865,7,7); // hl2
- GamerCar[16] = AddStaticVehicle(468,-2271.1011,2318.3032,4.3933,270.3314,7,7); // san1
- GamerCar[17] = AddStaticVehicle(468,-2271.0857,2315.6169,4.3933,270.3316,7,7); // san2
- GamerCar[18] = AddStaticVehicle(468,-2271.0703,2312.9072,4.4041,270.3273,7,7); // san3
- GamerCar[19] = AddStaticVehicle(411,-2252.8792,2303.0581,4.3891,90.2496,7,7); // infer 1
- GamerCar[20] = AddStaticVehicle(411,-2252.8914,2305.8445,4.3979,90.2494,7,7); // infer 2
- GamerCar[21] = AddStaticVehicle(541,-2252.7295,2308.9944,3.9776,87.7732,7,7); // bu;elt 1
- GamerCar[22] = AddStaticVehicle(541,-2252.6121,2312.0183,3.9777,90.0196,7,7); // bu;elt 2
- GamerCar[23] = AddStaticVehicle(444,-2252.0046,2316.4492,5.1838,88.2991,7,7); // monsta
- GamerCar[24] = AddStaticVehicle(579,-2252.5796,2320.9246,4.8795,89.7031,7,7); // hunteley 1
- GamerCar[25] = AddStaticVehicle(579,-2252.5632,2323.9531,4.9165,89.7037,7,7); // hunteley 2
- GamerCar[26] = AddStaticVehicle(601,-2227.8975,2351.8188,4.7502,131.9561,7,7); // wannabe pancer
- GamerCar[27] = AddStaticVehicle(432,-2245.2588,2373.2214,5.0096,131.3261,7,7); // panca
- //===========================RANDOM CARS========================================
- AddStaticVehicle(402,-2416.7737,-588.8609,132.4809,212.9476,22,22); //
- AddStaticVehicle(402,-2392.7947,-606.6710,132.4809,35.4784,22,22); //
- AddStaticVehicle(402,-2505.5735,-602.0001,132.3949,180.4139,22,22); //
- AddStaticVehicle(602,-2524.3076,-603.2769,132.1032,177.1063,45,45); //
- AddStaticVehicle(602,-2397.5764,-591.3733,132.1897,125.2256,45,45); //
- AddStaticVehicle(602,-2689.6602,-53.8021,3.8765,356.5940,45,45); //
- AddStaticVehicle(602,-2666.7334,-35.0318,3.8770,179.5092,45,45); //
- AddStaticVehicle(604,-2466.8621,-118.7112,25.4212,175.7007,16,76); //
- AddStaticVehicle(603,-2616.9404,-148.9009,4.1739,267.5471,69,1); //
- AddStaticVehicle(589,-2673.0483,-56.0744,3.9953,359.6624,124,124); //
- AddStaticVehicle(587,-2686.6667,-22.6627,3.8813,180.2258,53,1); //
- AddStaticVehicle(587,-2796.6511,-116.9296,6.7310,90.6214,53,1); //
- AddStaticVehicle(579,-2691.5525,268.8220,4.4169,1.7204,53,53); //
- AddStaticVehicle(579,-2678.0889,268.4761,4.4077,0.2683,53,53); //
- AddStaticVehicle(565,-2693.5349,230.0450,3.9594,270.3218,53,53); //
- AddStaticVehicle(562,-2693.2332,234.2977,4.0688,269.1766,11,1); //
- AddStaticVehicle(561,-2692.7903,238.3800,4.1494,269.2351,54,38); //
- AddStaticVehicle(560,-2659.9922,236.9559,4.1965,90.0651,17,1); //
- AddStaticVehicle(559,-2659.7073,230.9937,3.9925,90.6057,68,8); //
- AddStaticVehicle(555,-2589.0430,622.9824,14.1434,271.0290,68,1); //
- AddStaticVehicle(555,-2481.6553,740.9810,34.6993,179.3592,68,1); //
- AddStaticVehicle(551,-2490.7146,740.9293,34.8161,180.0638,83,1); //
- AddStaticVehicle(551,-2557.7073,626.1100,27.6104,2.3983,83,1); //
- AddStaticVehicle(551,-2546.1150,632.2814,14.2543,267.0381,83,1); //
- AddStaticVehicle(551,-2681.4585,870.7302,76.7349,3.5970,83,1); //
- AddStaticVehicle(549,-2837.1501,863.8202,43.7521,265.8561,75,39); //
- AddStaticVehicle(545,-2590.9053,655.7697,27.6236,270.9669,44,96); //
- AddStaticVehicle(545,-2455.8062,739.6643,34.8267,179.2579,44,96); //
- AddStaticVehicle(545,-2319.6079,1030.2946,50.5063,180.1270,44,96); //
- AddStaticVehicle(544,-2020.6604,75.1712,28.3104,271.9673,3,1); //
- AddStaticVehicle(542,-2267.4387,73.8585,34.9041,94.3648,31,93); //
- AddStaticVehicle(542,-2483.8291,57.9779,26.0350,181.9599,31,93); //
- AddStaticVehicle(542,-2476.8799,412.8604,27.5206,141.1121,31,93); //
- AddStaticVehicle(541,-2486.4304,421.6219,26.9149,137.8478,68,8); //
- AddStaticVehicle(541,-2528.8848,318.6894,34.2509,253.5956,13,8); //
- AddStaticVehicle(541,-2661.5933,267.9075,3.4696,359.6380,36,8); //
- AddStaticVehicle(539,-2786.0757,1332.6061,0.1816,358.2801,70,86); //
- AddStaticVehicle(539,-2782.3066,1333.1011,0.7608,358.2859,70,86); //
- AddStaticVehicle(539,-2777.5085,1332.9355,0.1159,358.2740,70,86); //
- AddStaticVehicle(539,-2769.9219,1332.7059,0.4023,358.2728,70,86); //
- AddStaticVehicle(535,-2500.5483,1223.2570,37.1884,322.0706,55,1); //
- AddStaticVehicle(536,-2512.3865,1210.1990,37.1608,90.8730,32,1); //
- AddStaticVehicle(536,-2458.1453,1070.1851,55.5270,4.2328,32,1); //
- AddStaticVehicle(536,-2665.0784,989.4171,64.6383,5.7381,32,1); //
- AddStaticVehicle(533,-2721.6648,980.0848,54.1718,359.4666,79,1); //
- AddStaticVehicle(533,-2665.2952,912.9135,79.3844,177.3759,79,1); //
- AddStaticVehicle(529,-2635.5833,931.1577,71.3666,191.3667,11,11); //
- AddStaticVehicle(526,-2580.9834,913.6854,64.6670,90.1655,41,29); //
- AddStaticVehicle(526,-2583.2576,626.1356,27.5792,0.0105,41,29); //
- AddStaticVehicle(522,-2592.5022,645.2698,27.3825,265.8216,6,25); //
- AddStaticVehicle(522,-2503.2314,740.8766,34.5830,184.4830,8,82); //
- AddStaticVehicle(522,-2416.9053,742.3102,34.5879,176.1381,8,82); //
- AddStaticVehicle(522,-2264.4927,196.9080,34.7348,90.6708,8,82); //
- AddStaticVehicle(522,-2264.5798,204.3056,34.7348,90.6708,8,82); //
- AddStaticVehicle(522,-2504.2976,343.6132,34.6887,63.1587,8,82); //
- AddStaticVehicle(522,-2586.9048,73.9291,4.2018,82.9552,8,82); //
- AddStaticVehicle(522,-2718.9224,148.3790,4.3030,268.1398,8,82); //
- AddStaticVehicle(522,-2272.4729,-77.7391,34.8918,267.7599,8,82); //
- AddStaticVehicle(522,-2513.4597,-602.4126,132.1312,180.0149,8,82); //
- AddStaticVehicle(522,-2402.7180,-584.8160,132.2173,121.9623,8,82); //
- AddStaticVehicle(522,-2769.6147,361.9973,4.0446,356.5796,8,82); //
- AddStaticVehicle(521,-2495.6731,430.6870,27.3448,129.8253,92,3); //
- AddStaticVehicle(521,-2408.4280,360.4786,34.5510,244.4185,92,3); //
- AddStaticVehicle(521,-2266.4126,86.1168,34.7428,84.2874,92,3); //
- AddStaticVehicle(521,-2616.6287,91.5754,3.9068,264.8586,92,3); //
- AddStaticVehicle(508,-2620.3015,-55.3205,4.7743,0.3559,1,1); //
- AddStaticVehicle(507,-2626.5676,-55.4859,4.0731,359.2131,62,62); //
- AddStaticVehicle(507,-2693.5891,-147.4060,4.0719,92.2627,62,62); //
- AddStaticVehicle(507,-2695.0918,268.2522,4.0670,1.3253,62,62); //
- AddStaticVehicle(507,-2544.0439,654.7109,27.5470,90.5020,62,62); //
- AddStaticVehicle(507,-2481.9761,741.5717,34.7513,180.5906,62,62); //
- AddStaticVehicle(507,-2601.6611,983.7361,77.9329,357.2890,62,62); //
- AddStaticVehicle(507,-2438.9194,1313.1979,15.3514,83.4565,62,62); //
- AddStaticVehicle(507,-2525.8203,1228.6616,37.1680,31.3433,62,62); //
- AddStaticVehicle(506,-2538.5596,1228.8173,37.1724,29.6455,7,7); //
- AddStaticVehicle(506,-2419.0891,1031.2866,50.1426,0.7437,7,7); //
- AddStaticVehicle(506,-2265.7019,141.3937,34.9080,92.2847,7,7); //
- AddStaticVehicle(492,-2519.0327,346.7296,34.8927,246.8088,71,107); //
- AddStaticVehicle(492,-2511.0879,343.3191,27.5478,246.6736,71,107); //
- AddStaticVehicle(407,-2021.0590,84.1284,28.2096,270.8073,3,1); //
- AddStaticVehicle(407,-2021.1887,93.3797,28.2203,270.8951,3,1); //
- AddStaticVehicle(409,-2421.4583,321.5449,34.7090,331.4807,1,1); //
- AddStaticVehicle(409,-2413.0474,337.2351,34.7077,331.4331,1,1); //
- AddStaticVehicle(411,-2268.6028,61.7404,34.7245,87.6070,116,1); //
- AddStaticVehicle(411,-2525.4194,330.4707,34.6774,247.4376,116,1); //
- AddStaticVehicle(411,-2620.9844,-22.6765,3.8963,182.2069,116,1); //
- AddStaticVehicle(411,-2716.4058,870.2601,70.2635,2.0156,116,1); //
- AddStaticVehicle(415,-2710.4360,870.0539,70.4679,0.9241,40,1); //
- AddStaticVehicle(415,-2490.5366,741.6411,34.7875,184.1428,40,1); //
- AddStaticVehicle(415,-2589.7197,652.5753,14.2233,266.8899,40,1); //
- AddStaticVehicle(416,-2655.2434,619.2186,14.5597,271.2412,1,3); //
- AddStaticVehicle(416,-2630.0767,619.3177,14.5599,267.9827,1,3); //
- AddStaticVehicle(416,-2676.2449,620.0023,14.5573,269.2327,1,3); //
- AddStaticVehicle(416,-2676.5942,593.7836,14.5596,269.2327,1,3); //
- AddStaticVehicle(416,-2654.5942,593.4889,14.5615,269.2393,1,3); //
- AddStaticVehicle(429,-2545.9397,632.7849,14.3046,89.6988,14,14); //
- AddStaticVehicle(445,-2543.8198,633.4100,27.6004,91.0144,37,37); //
- AddStaticVehicle(445,-2546.6067,713.8347,27.6833,91.3185,37,37); //
- AddStaticVehicle(603,-2132.2844,-42.5832,35.1576,272.4647,18,1); //
- AddStaticVehicle(603,-2021.1115,-52.2344,35.1856,177.1012,45,45); //
- AddStaticVehicle(589,-2085.3547,-84.7091,34.8221,359.6764,22,22); //
- AddStaticVehicle(565,-2057.6096,55.8275,28.0248,265.6232,53,53); //
- AddStaticVehicle(562,-2021.3917,66.2360,28.2073,359.4389,11,1); //
- AddStaticVehicle(560,-2015.9558,49.3553,31.1138,0.8346,21,1); //
- AddStaticVehicle(559,-1972.5265,100.8323,27.3437,89.2393,2,1); //
- AddStaticVehicle(549,-1988.0210,118.9040,27.2364,0.1400,79,39); //
- AddStaticVehicle(549,-1988.1639,171.1337,27.2364,359.1077,84,36); //
- AddStaticVehicle(544,-2020.0958,91.2405,28.1560,273.1722,3,1); //
- AddStaticVehicle(541,-2075.5562,212.9287,35.0172,325.9548,60,1); //
- AddStaticVehicle(535,-2107.9919,244.2583,35.5119,219.6379,31,1); //
- AddStaticVehicle(524,-2102.3103,172.4187,36.0033,15.0231,65,31); //
- AddStaticVehicle(506,-2266.8696,89.3536,34.8760,269.6390,7,7); //
- AddStaticVehicle(505,-2266.0847,192.7231,35.3072,269.2906,120,123); //
- AddStaticVehicle(500,-2184.4709,305.9776,35.2281,178.6576,40,110); //
- AddStaticVehicle(506,-2201.7024,293.2020,34.8216,359.9998,6,6); //
- AddStaticVehicle(402,-2231.5627,293.2117,34.9487,0.3397,30,30); //
- AddStaticVehicle(411,-1971.2395,303.1635,34.8925,129.9415,116,1); //
- AddStaticVehicle(415,-2020.5674,388.0089,34.9437,359.9985,40,1); //
- AddStaticVehicle(429,-2019.9009,418.6103,34.8516,269.0737,14,14); //
- AddStaticVehicle(445,-1979.5588,443.6755,35.0468,359.2050,39,39); //
- AddStaticVehicle(411,-1977.8130,459.5112,28.2935,359.9947,12,1); //
- AddStaticVehicle(451,-1976.6556,797.7638,54.7005,269.9808,16,16); //
- AddStaticVehicle(467,-1984.7444,867.9398,44.9430,359.4640,2,1); //
- AddStaticVehicle(477,-2021.5891,905.3015,46.5911,271.1561,121,1); //
- AddStaticVehicle(480,-1987.9614,947.4948,45.2180,147.6258,6,6); //
- AddStaticVehicle(496,-1973.2938,1117.3418,53.2098,2.2422,37,19); //
- AddStaticVehicle(451,-2114.9343,1159.9274,55.0916,1.2296,123,123); //
- AddStaticVehicle(411,-1781.5710,1201.3925,24.8510,271.9113,106,1); //
- AddStaticVehicle(411,-1567.4487,1115.4772,6.9146,89.2141,75,1); //
- AddStaticVehicle(415,-1572.5841,1204.1324,6.9623,65.3284,40,1); //
- //OBJECTS FOR DUEL SYSTEM ======================================================
- CreateObject(3095, 1745.2294921875, -2835.8447265625, 5, 0, 0, 0);
- CreateObject(3095, 1736.2451171875, -2835.8447265625, 5, 0, 0, 0);
- CreateObject(3095, 1745.2294921875, -2844.833984375, 5, 0, 0, 0);
- CreateObject(3095, 1736.2451171875, -2844.833984375, 5, 0, 0, 0);
- CreateObject(3095, 1745.2294921875, -2853.8239746094, 5, 0, 0, 0);
- CreateObject(3095, 1736.2451171875, -2853.8239746094, 5, 0, 0, 0);
- CreateObject(3095, 1727.2551269531, -2835.8447265625, 5, 0, 0, 0);
- CreateObject(3095, 1727.2551269531, -2844.833984375, 5, 0, 0, 0);
- CreateObject(3095, 1727.2551269531, -2853.8232421875, 5, 0, 0, 0);
- CreateObject(3095, 1745.2294921875, -2862.8132324219, 5, 0, 0, 0);
- CreateObject(3095, 1736.2451171875, -2862.8132324219, 5, 0, 0, 0);
- CreateObject(3095, 1727.2548828125, -2862.8132324219, 5, 0, 0, 0);
- CreateObject(3095, 1718.2648925781, -2835.8447265625, 5, 0, 0, 0);
- CreateObject(3095, 1718.2648925781, -2844.833984375, 5, 0, 0, 0);
- CreateObject(3095, 1718.2648925781, -2853.8232421875, 5, 0, 0, 0);
- CreateObject(3095, 1718.2648925781, -2862.8125, 5, 0, 0, 0);
- CreateObject(3401, 1742.7684326172, -2859.9912109375, 7.9004049301147, 0, 0, 0);
- CreateObject(994, 1742.6313476563, -2852.4506835938, 5.5881395339966, 0, 0, 0);
- CreateObject(994, 1736.0305175781, -2852.4506835938, 5.5881395339966, 0, 0, 0);
- CreateObject(3095, 1749.6668701172, -2835.8447265625, 9.5, 0, 90, 0);
- CreateObject(3095, 1749.666015625, -2862.8134765625, 9.5, 0, 90, 0);
- CreateObject(3095, 1749.666015625, -2853.8232421875, 9.5, 0, 90, 0);
- CreateObject(3095, 1749.666015625, -2844.833984375, 9.5, 0, 90, 0);
- CreateObject(994, 1734.8913574219, -2866.2641601563, 5.555365562439, 0, 0, 90);
- CreateObject(994, 1734.890625, -2859.5632324219, 5.555365562439, 0, 0, 90);
- CreateObject(3401, 1742.7684326172, -2838.2465820313, 7.9004049301147, 0, 0, 0);
- CreateObject(994, 1742.630859375, -2845.4501953125, 5.5881395339966, 0, 0, 0);
- CreateObject(994, 1736.0302734375, -2845.4501953125, 5.5881395339966, 0, 0, 0);
- CreateObject(994, 1734.890625, -2838.0625, 5.555365562439, 0, 0, 90);
- CreateObject(994, 1734.890625, -2844.8625488281, 5.555365562439, 0, 0, 90);
- CreateObject(3095, 1745.2294921875, -2830.8447265625, 9.5, 0, 90, 270);
- CreateObject(3095, 1736.2451171875, -2830.8447265625, 9.5, 0, 90, 270);
- CreateObject(3095, 1718.2648925781, -2830.8447265625, 9.5, 0, 90, 270);
- CreateObject(3095, 1727.2551269531, -2830.8447265625, 9.5, 0, 90, 270);
- CreateObject(3095, 1713.2648925781, -2862.8125, 9.5, 0, 90, 0);
- CreateObject(3095, 1713.2646484375, -2835.8447265625, 9.5, 0, 90, 0);
- CreateObject(3095, 1713.2646484375, -2844.833984375, 9.5, 0, 90, 0);
- CreateObject(3095, 1713.2646484375, -2853.8232421875, 9.5, 0, 90, 0);
- CreateObject(3095, 1718.2648925781, -2866.8125, 9.5, 0, 90, 270);
- CreateObject(3095, 1727.2548828125, -2866.8125, 9.5, 0, 90, 270);
- CreateObject(3095, 1736.2451171875, -2866.8125, 9.5, 0, 90, 270);
- CreateObject(3095, 1745.2294921875, -2866.8125, 9.5, 0, 90, 270);
- CreateObject(3095, 1745.2294921875, -2835.8447265625, 10.199999809265, 0, 0, 0);
- CreateObject(3095, 1736.2451171875, -2835.8447265625, 10.199999809265, 0, 0, 0);
- CreateObject(3095, 1745.2294921875, -2844.833984375, 10.199999809265, 0, 0, 0);
- CreateObject(3095, 1736.2451171875, -2844.833984375, 10.199999809265, 0, 0, 0);
- CreateObject(3095, 1745.2294921875, -2853.8232421875, 10.199999809265, 0, 0, 0);
- CreateObject(3095, 1745.2294921875, -2862.8125, 10.199999809265, 0, 0, 0);
- CreateObject(3095, 1736.2451171875, -2853.8232421875, 10.199999809265, 0, 0, 0);
- CreateObject(3095, 1736.2451171875, -2862.8125, 10.199999809265, 0, 0, 0);
- CreateObject(3401, 1720.767578125, -2838.24609375, 7.9004049301147, 0, 0, 0);
- CreateObject(994, 1728.2906494141, -2838.0625, 5.555365562439, 0, 0, 90);
- CreateObject(994, 1728.2906494141, -2844.8623046875, 5.555365562439, 0, 0, 90);
- CreateObject(994, 1714.0302734375, -2845.4501953125, 5.5881395339966, 0, 0, 0);
- CreateObject(994, 1720.7302246094, -2845.4501953125, 5.5881395339966, 0, 0, 0);
- CreateObject(3401, 1720.767578125, -2859.9912109375, 7.9004049301147, 0, 0, 0);
- CreateObject(994, 1728.2906494141, -2866.263671875, 5.555365562439, 0, 0, 90);
- CreateObject(994, 1728.2906494141, -2859.5625, 5.555365562439, 0, 0, 90);
- CreateObject(994, 1714.0302734375, -2852.4501953125, 5.5881395339966, 0, 0, 0);
- CreateObject(994, 1720.7294921875, -2852.4501953125, 5.5881395339966, 0, 0, 0);
- CreateObject(3095, 1727.2548828125, -2862.8125, 10.199999809265, 0, 0, 0);
- CreateObject(3095, 1718.2646484375, -2862.8125, 10.199999809265, 0, 0, 0);
- CreateObject(3095, 1727.2548828125, -2853.8232421875, 10.199999809265, 0, 0, 0);
- CreateObject(3095, 1718.2646484375, -2853.8232421875, 10.199999809265, 0, 0, 0);
- CreateObject(3095, 1727.2548828125, -2844.833984375, 10.199999809265, 0, 0, 0);
- CreateObject(3095, 1718.2646484375, -2844.833984375, 10.199999809265, 0, 0, 0);
- CreateObject(3095, 1727.2548828125, -2835.8447265625, 10.199999809265, 0, 0, 0);
- CreateObject(3095, 1718.2646484375, -2835.8447265625, 10.199999809265, 0, 0, 0);
- //ZONES
- Zone1 = GangZoneCreate(-2799.996093, -173.397064, -2463.996093, 154.602935);
- Zone2 = GangZoneCreate(-2799.354492, 232.376708, -2615.354492, 696.376708);
- Zone3 = GangZoneCreate(-2276.547119, -86.489639, -2004.547119, 169.510360);
- Zone4 = GangZoneCreate(-2445.138183, -232.113327, -2293.138183, 223.886672);
- Zone5 = GangZoneCreate(-2328.167480, 337.696594, -1944.167480, 681.696594);
- Zone6 = GangZoneCreate(-1824.531494, 624.765625, -1496.531494, 920.765625);
- Zone7 = GangZoneCreate(-2439.947753, 1035.557861, -2119.947753, 1307.557861);
- Zone8 = GangZoneCreate(-1854.087280, 1178.869628, -1622.087280, 1410.869628);
- Zone9 = GangZoneCreate(-2213.718750, 710.110534, -1949.718750, 982.110534);
- Zone10 = GangZoneCreate(-2765.796386, 784.332397, -2437.796386, 1104.332397);
- Zone11 = GangZoneCreate(-1922.631958, -28.333175, -1706.631958, 403.666809);
- Zone12 = GangZoneCreate(-1957.691406, -758.583618, -1645.691406, -430.583618);
- Zone13 = GangZoneCreate(-2518.000000, -602.239868, -2246.000000, -306.239868);
- //Textdraws===============================================================
- SetTimer("StatsTimer",1500,1);
- for(new playerid = 0; playerid < MAX_PLAYERS; playerid++)
- {
- //RanksTextdraw-------
- RankTextdraw[playerid] = TextDrawCreate(23.000000, 114.000000, "-");
- TextDrawBackgroundColor(RankTextdraw[playerid],255);
- TextDrawFont(RankTextdraw[playerid],2);
- TextDrawLetterSize(RankTextdraw[playerid], 0.379999, 1.050000);
- TextDrawColor(RankTextdraw[playerid], 16777215);
- TextDrawSetOutline(RankTextdraw[playerid],0);
- TextDrawSetProportional(RankTextdraw[playerid],1);
- TextDrawSetShadow(RankTextdraw[playerid],1);
- //Stats Text Draw --------------
- StatsTextdraw[playerid] = TextDrawCreate(130.000000, 420.000000, "-");
- TextDrawBackgroundColor(StatsTextdraw[playerid], 255);
- TextDrawFont(StatsTextdraw[playerid], 2);
- TextDrawLetterSize(StatsTextdraw[playerid], 0.549999, 1.400000);
- TextDrawColor(StatsTextdraw[playerid], -1);
- TextDrawSetOutline(StatsTextdraw[playerid], 1);
- TextDrawSetProportional(StatsTextdraw[playerid], 1);
- //Forum Text DRaw----------------
- ForumTextdraw[playerid] = TextDrawCreate(0.000000, 437.000000, "Forum: gta-dm.de");
- TextDrawBackgroundColor(ForumTextdraw[playerid], 255);
- TextDrawFont(ForumTextdraw[playerid], 1);
- TextDrawLetterSize(ForumTextdraw[playerid], 0.500000, 1.000000);
- TextDrawColor(ForumTextdraw[playerid], 65535);
- TextDrawSetOutline(ForumTextdraw[playerid], 1);
- TextDrawSetProportional(ForumTextdraw[playerid], 1);
- //ZonestextDraw------------------
- ZonesTextdraw[playerid] = TextDrawCreate(11.000000, 324.000000, "-");
- TextDrawBackgroundColor(ZonesTextdraw[playerid], 255);
- TextDrawFont(ZonesTextdraw[playerid], 3);
- TextDrawLetterSize(ZonesTextdraw[playerid], 0.360000, 1.600000);
- TextDrawColor(ZonesTextdraw[playerid], -1);
- TextDrawSetOutline(ZonesTextdraw[playerid], 1);
- TextDrawSetProportional(ZonesTextdraw[playerid], 1);
- //NoTimeDuel--------------------------------------------------------------------
- duelRoom1 = -1;
- duelRoom2 = -1;
- duelRoom3 = -1;
- duelRoom4 = -1;
- }
- return 1;
- }
- public OnGameModeExit()
- {
- return 1;
- }
- public OnPlayerRequestClass(playerid, classid)
- {
- if (classid == 0)
- {
- GameTextForPlayer(playerid,"~g~ LA COSA NOSTRA SHOOTER-TEAM",2000,3);
- SetPlayerPos(playerid,-2723.2859,-315.4313,7.1783);
- SetPlayerFacingAngle(playerid,45.3784);
- SetPlayerCameraPos(playerid,-2725.5479,-312.8718,7.0391);
- SetPlayerCameraLookAt(playerid,-2723.2859,-315.4313,7.1783);
- Gang[playerid] = TEAM_LCN;
- }
- if (classid == 1)
- {
- GameTextForPlayer(playerid,"~g~ LA COSA NOSTRA SNIPER-TEAM",2000,3);
- SetPlayerPos(playerid,-2723.2859,-315.4313,7.1783);
- SetPlayerFacingAngle(playerid,45.3784);
- SetPlayerCameraPos(playerid,-2725.5479,-312.8718,7.0391);
- SetPlayerCameraLookAt(playerid,-2723.2859,-315.4313,7.1783);
- Gang[playerid] = TEAM_LCN;
- }
- if (classid == 2)
- {
- GameTextForPlayer(playerid,"~r~ RUSSIAN MAFIA SHOOTER-TEAM",2000,3);
- SetPlayerPos(playerid,-2135.0461,-247.9861,35.8789);
- SetPlayerFacingAngle(playerid,270.3784);
- SetPlayerCameraPos(playerid,-2132.0156,-247.8858,35.3203);
- SetPlayerCameraLookAt(playerid,-2135.0461,-247.9861,35.8789);
- Gang[playerid] = TEAM_RUS;
- }
- if (classid == 3)
- {
- GameTextForPlayer(playerid,"~r~ RUSSIAN MAFIA SNIPER-TEAM",2000,3);
- SetPlayerPos(playerid,-2135.0461,-247.9861,35.8789);
- SetPlayerFacingAngle(playerid,270.3784);
- SetPlayerCameraPos(playerid,-2132.0156,-247.8858,35.3203);
- SetPlayerCameraLookAt(playerid,-2135.0461,-247.9861,35.8789);
- Gang[playerid] = TEAM_RUS;
- }
- if (classid == 4)
- {
- GameTextForPlayer(playerid,"~w~ TRIAD SHOOTER-TEAM",2000,3);
- SetPlayerPos(playerid,-2153.9602,645.5248,52.3672);
- SetPlayerFacingAngle(playerid,270.3784);
- SetPlayerCameraPos(playerid,-2150.3926,645.6638,52.2656);
- SetPlayerCameraLookAt(playerid,-2153.9602,645.5248,52.3672);
- Gang[playerid] = TEAM_TRIADS;
- }
- if (classid == 5)
- {
- GameTextForPlayer(playerid,"~w~ TRIAD SNIPER-TEAM",2000,3);
- SetPlayerPos(playerid,-2153.9602,645.5248,52.3672);
- SetPlayerFacingAngle(playerid,270.3784);
- SetPlayerCameraPos(playerid,-2150.3926,645.6638,52.2656);
- SetPlayerCameraLookAt(playerid,-2153.9602,645.5248,52.3672);
- Gang[playerid] = TEAM_TRIADS;
- }
- if (classid == 6)
- {
- GameTextForPlayer(playerid,"~b~ YUGOSLAWIAN MAFIA SHOOTER-TEAM",2000,3);
- SetPlayerPos(playerid,-2624.5608,1405.8046,7.1016);
- SetPlayerFacingAngle(playerid,270.3784);
- SetPlayerCameraPos(playerid,-2619.5066,1405.4160,7.0938);
- SetPlayerCameraLookAt(playerid,-2624.5608,1405.8046,7.1016);
- Gang[playerid] = TEAM_YUGO;
- }
- if (classid == 7)
- {
- GameTextForPlayer(playerid,"~b~ YUGOSLAWIAN MAFIA SNIPER-TEAM",2000,3);
- SetPlayerPos(playerid,-2624.5608,1405.8046,7.1016);
- SetPlayerFacingAngle(playerid,270.3784);
- SetPlayerCameraPos(playerid,-2619.5066,1405.4160,7.0938);
- SetPlayerCameraLookAt(playerid,-2624.5608,1405.8046,7.1016);
- Gang[playerid] = TEAM_YUGO;
- }
- if (classid == 8)
- {
- GameTextForPlayer(playerid,"~y~ GERMAN MAFIA SHOOTER-TEAM",2000,3);
- SetPlayerPos(playerid,-2445.2549,523.0179,29.9204);
- SetPlayerFacingAngle(playerid,270.3784);
- SetPlayerCameraPos(playerid,-2438.1738,523.0526,29.9058);
- SetPlayerCameraLookAt(playerid,-2445.2549,523.0179,29.9204);
- Gang[playerid] = TEAM_GERMAN;
- }
- if (classid == 9)
- {
- GameTextForPlayer(playerid,"~y~ GERMAN MAFIA SNIPER-TEAM",2000,3);
- SetPlayerPos(playerid,-2445.2549,523.0179,29.9204);
- SetPlayerFacingAngle(playerid,270.3784);
- SetPlayerCameraPos(playerid,-2438.1738,523.0526,29.9058);
- SetPlayerCameraLookAt(playerid,-2445.2549,523.0179,29.9204);
- Gang[playerid] = TEAM_GERMAN;
- }
- if (classid == 10)
- {
- GameTextForPlayer(playerid,"~p~ CUBAN MAFIA SHOOTER-TEAM",2000,3);
- SetPlayerPos(playerid,-1872.5337,-218.0692,18.3750);
- SetPlayerFacingAngle(playerid,270.3784);
- SetPlayerCameraPos(playerid,-1865.4303,-217.8114,18.3750);
- SetPlayerCameraLookAt(playerid,-1872.5337,-218.0692,18.3750);
- Gang[playerid] = TEAM_CUBAN;
- }
- if (classid == 11)
- {
- GameTextForPlayer(playerid,"~p~ CUBAN MAFIA SNIPER-TEAM",2000,3);
- SetPlayerPos(playerid,-1872.5337,-218.0692,18.3750);
- SetPlayerFacingAngle(playerid,270.3784);
- SetPlayerCameraPos(playerid,-1865.4303,-217.8114,18.3750);
- SetPlayerCameraLookAt(playerid,-1872.5337,-218.0692,18.3750);
- Gang[playerid] = TEAM_CUBAN;
- }
- if(classid == 12)
- {
- GameTextForPlayer(playerid,"~b~ SF-MW ELITE GAMER-TEAM",2000,3);
- SetPlayerPos(playerid,-2280.8911,2288.0557,4.9602);
- SetPlayerFacingAngle(playerid,270.3784);
- SetPlayerCameraPos(playerid,-2270.8911,2288.0557,4.9602);
- SetPlayerCameraLookAt(playerid,-2280.8911,2288.0557,4.9602);
- Gang[playerid] = TEAM_GAMER;
- }
- return 1;
- }
- public OnPlayerConnect(playerid)
- {
- // REGISTER SYSTEM =============================================================
- new pname[MAX_PLAYERS],accFormat[128];
- GetPlayerName(playerid,pname,sizeof pname);
- format(accFormat,sizeof accFormat,"acc/%s.sav",pname); // the place where your stats should be saved
- if(fexist(accFormat))
- {
- ShowPlayerDialog(playerid,DIALOG_LOGIN,1,"Login","Hello!\nYour Account has been founded\nPlease logg in!","Cancel","Next");
- }
- else
- {
- ShowPlayerDialog(playerid,DIALOG_REG,1,"Register","You have not an Account on this Server\nPlease register!","Cancel","Next");
- }
- // JOIN & LEAVE MESSAGES =======================================================
- new pName[MAX_PLAYER_NAME];
- new string[48];
- GetPlayerName(playerid, pName, sizeof(pName));
- format(string, sizeof(string), "** %s has joined the Server. **", pName);
- SendClientMessageToAll(COLOR_GREEN, string);
- //------------------------------------------------------------------------------
- pIPWarns[playerid] = 0;
- teamkills[playerid] = 0;
- IsBombPlanted[playerid] = 0;//Bomb is not planted
- PlayerHasBomb[playerid] = 0;//wenn der Spieler connected hat er keine bombe
- IsDm[playerid] = 0; //pllyer ist not in DM arenas
- KillSpree[playerid] = 0;
- //==============================================================================
- SendClientMessage(playerid, hellblau, "|_______ WELCOME TO SAN FRANCISCO MAFIA WARS v3 _______|");
- SendClientMessage(playerid, weiss,"Read the Rules before you do Stupid things. (/rules)");
- SendClientMessage(playerid, weiss,"When you need Help, ask an Admin or read (/help)");
- SendClientMessage(playerid, weiss,"Type (/rinfo) to get information about our Ranksystem");
- SendClientMessage(playerid, weiss,"Be ware Cheaters, this Server is protectet by an Anti-Cheat System!");
- //---------
- PlayerduelWatching[playerid] = 0;
- InventationSent[playerid] = -1;
- Inventation[playerid] = -1;
- Induel[playerid] = 0;
- Inventationprice[playerid] = 0;
- //---------
- TextDrawShowForPlayer(playerid,ForumTextdraw[playerid]);
- //--------
- gettime(hour, minute);
- SetPlayerTime(playerid,hour,minute);
- return 1;
- }
- public OnPlayerDisconnect(playerid, reason)
- {
- // STATS SAVER IN REGISTERSYSTEM ===============================================
- new pname[MAX_PLAYERS],accFormat[128];
- GetPlayerName(playerid,pname,sizeof pname);
- format(accFormat,sizeof accFormat,"acc/%s.sav",pname);
- if(fexist(accFormat) && Spieler[playerid][eingeloggt])
- {
- dini_IntSet(accFormat,"rang",Spieler[playerid][rang]);
- dini_IntSet(accFormat,"Adminlvl",Spieler[playerid][alvl]);
- dini_IntSet(accFormat,"Kills",Spieler[playerid][Kills]);
- dini_IntSet(accFormat,"Deaths",Spieler[playerid][Deaths]);
- dini_IntSet(accFormat,"Geld",GetPlayerMoney(playerid));
- dini_IntSet(accFormat,"Score",GetPlayerScore(playerid));
- dini_IntSet(accFormat,"gamer",Spieler[playerid][gamer]);
- }
- Spieler[playerid][eingeloggt] = 0;
- // ROBSYSTEM
- isAtRob[playerid] = 0;
- if(timer_x[playerid] > 0)KillTimer(timer_x[playerid]);
- timer_x[playerid] = 0;
- //----
- PlayerduelWatching[playerid] = 0;
- InventationSent[playerid] = -1;
- Inventation[playerid] = -1;
- Induel[playerid] = 0;
- Inventationprice[playerid] = 0;
- // LEAVE MESSAGE ===========================================================
- new pName[MAX_PLAYER_NAME];
- new string[56];
- GetPlayerName(playerid, pName, sizeof(pName));
- switch(reason)
- {
- case 0: format(string, sizeof(string), "**%s has left the Server.(Timeout/Crash)**", pName);
- case 1: format(string, sizeof(string), "** %s has left the Server. **", pName);
- case 2: format(string, sizeof(string), "** %s has left the Server.(Kick/Ban)**", pName);
- }
- SendAdminMessage(COLOR_RED, string);
- return 1;
- }
- public OnPlayerSpawn(playerid)
- {
- SetTimer("zonecheck",1500,1);// zone cheks
- SetPlayerArmour(playerid, 100.0);
- SendClientMessage(playerid, COLOR_GREEN, "*** ANTI SPAWNKILL ACTIVE ***");
- // ANTI SPAWN KILL =============================================================
- SetTimerEx("GiveWeapons", SPAWNTIME*1000, false, "i", playerid);
- //----
- SetPlayerHealth(playerid, 1000.0);
- if (Gang[playerid] == TEAM_LCN) { SetPlayerColor(playerid,gruen);}//LCN COLOR GREEN
- else if (Gang[playerid] == TEAM_RUS) { SetPlayerColor(playerid,rot);}//RUSSIA COLOR RED
- else if (Gang[playerid] == TEAM_TRIADS) { SetPlayerColor(playerid,weiss); }//TRIADS YELLOW
- else if (Gang[playerid] == TEAM_YUGO) { SetPlayerColor(playerid,yugoblau);}//YUGOS GREY
- else if (Gang[playerid] == TEAM_GERMAN) { SetPlayerColor(playerid,gelb);}//GERMANS
- else if (Gang[playerid] == TEAM_CUBAN) { SetPlayerColor(playerid,braun);}//CUBANS
- // Minijob =====================================================================
- drugjob[playerid] = 0;
- //------------------------------------------------------------------------------
- new color1 = dini_Int("/zones/zones.ini","Zone1");
- new color2 = dini_Int("/zones/zones.ini","Zone2");
- new color3 = dini_Int("/zones/zones.ini","Zone3");
- new color4 = dini_Int("/zones/zones.ini","Zone4");
- new color5 = dini_Int("/zones/zones.ini","Zone5");
- new color6 = dini_Int("/zones/zones.ini","Zone6");
- new color7 = dini_Int("/zones/zones.ini","Zone7");
- new color8 = dini_Int("/zones/zones.ini","Zone8");
- new color9 = dini_Int("/zones/zones.ini","Zone9");
- new color10 = dini_Int("/zones/zones.ini","Zone10");
- new color11 = dini_Int("/zones/zones.ini","Zone11");
- new color12 = dini_Int("/zones/zones.ini","Zone12");
- new color13 = dini_Int("/zones/zones.ini","Zone13");
- //------------------------------------------------------------------------------
- GangZoneShowForPlayer(playerid, Zone1, color1);
- GangZoneShowForPlayer(playerid, Zone2, color2);
- GangZoneShowForPlayer(playerid, Zone3, color3);
- GangZoneShowForPlayer(playerid, Zone4, color4);
- GangZoneShowForPlayer(playerid, Zone5, color5);
- GangZoneShowForPlayer(playerid, Zone6, color6);
- GangZoneShowForPlayer(playerid, Zone7, color7);
- GangZoneShowForPlayer(playerid, Zone8, color8);
- GangZoneShowForPlayer(playerid, Zone9, color9);
- GangZoneShowForPlayer(playerid, Zone10, color10);
- GangZoneShowForPlayer(playerid, Zone11, color11);
- GangZoneShowForPlayer(playerid, Zone12, color12);
- GangZoneShowForPlayer(playerid, Zone13, color13);
- PlayerAtacker[playerid] = 0;
- if(Gang[playerid] == TEAM_GAMER)
- {
- if(Spieler[playerid][gamer] == 0)
- {
- PlayerToSkinSelect(playerid);
- SendClientMessage(playerid,COLOR_RED,"You are not in the Gamer-Team!/gamerinfo to get more informations!");
- }
- else if (Spieler[playerid][gamer] == 1)
- {
- GivePlayerWeapon(playerid,29,1000);
- GivePlayerWeapon(playerid,16,5);
- GivePlayerWeapon(playerid,31,1000);
- GivePlayerWeapon(playerid,34,250);
- GivePlayerWeapon(playerid,24,200);
- SetPlayerColor(playerid,COLOR_LIGHTBLUE);
- }
- }
- //------------------------------------------------------------------------------
- if(IsDm[playerid] == 1){SniperDm(playerid);}
- if(IsDm[playerid] == 2){DeagleDm(playerid);}
- if(IsDm[playerid] == 3){GrenadeDm(playerid);}
- if(IsDm[playerid] == 4){AllinDm(playerid);}
- if(IsDm[playerid] == 5){StreetfightDm(playerid);}
- if(IsDm[playerid] == 6){TacticDm(playerid);}
- //------------------------------------------------------------------------------
- TextDrawShowForPlayer(playerid,txtTimeDisp);
- gettime(hour, minute);
- SetPlayerTime(playerid,hour,minute);
- return 1;
- }
- public StatsTimer()
- {
- for(new i=0;i<MAX_PLAYERS;i++)
- {
- if (IsPlayerConnected(i))
- {
- new str[128];
- TextDrawHideForPlayer(i,RankTextdraw[i]);
- //--------
- if(Spieler[i][rang] == 1){
- format(str, sizeof(str), "Rank: BabyKiller");
- TextDrawSetString(RankTextdraw[i],str);
- TextDrawShowForPlayer(i,RankTextdraw[i]);
- }
- if(Spieler[i][rang] == 2){
- format(str, sizeof(str), "Rank: Outlaw");
- TextDrawSetString(RankTextdraw[i],str);
- TextDrawShowForPlayer(i,RankTextdraw[i]);
- }
- if(Spieler[i][rang] == 3){
- format(str, sizeof(str), "Rank: Newcomer");
- TextDrawSetString(RankTextdraw[i],str);
- TextDrawShowForPlayer(i,RankTextdraw[i]);
- }
- if(Spieler[i][rang] == 4){
- format(str, sizeof(str), "Rank: Associate");
- TextDrawSetString(RankTextdraw[i],str);
- TextDrawShowForPlayer(i,RankTextdraw[i]);
- }
- if(Spieler[i][rang] == 5){
- format(str, sizeof(str), "Rank: Soldier");
- TextDrawSetString(RankTextdraw[i],str);
- TextDrawShowForPlayer(i,RankTextdraw[i]);
- }
- if(Spieler[i][rang] == 6){
- format(str, sizeof(str), "Rank: Killer");
- TextDrawSetString(RankTextdraw[i],str);
- TextDrawShowForPlayer(i,RankTextdraw[i]);
- }
- if(Spieler[i][rang] == 7){
- format(str, sizeof(str), "Rank: Capo");
- TextDrawSetString(RankTextdraw[i],str);
- TextDrawShowForPlayer(i,RankTextdraw[i]);
- }
- if(Spieler[i][rang] == 8){
- format(str, sizeof(str), "Rank: StreetBoss");
- TextDrawSetString(RankTextdraw[i],str);
- TextDrawShowForPlayer(i,RankTextdraw[i]);
- }
- if(Spieler[i][rang] == 9){
- format(str, sizeof(str), "Rank: Underboss");
- TextDrawSetString(RankTextdraw[i],str);
- TextDrawShowForPlayer(i,RankTextdraw[i]);
- }
- if(Spieler[i][rang] == 10){
- format(str, sizeof(str), "Rank: Godfather");
- TextDrawSetString(RankTextdraw[i],str);
- TextDrawShowForPlayer(i,RankTextdraw[i]);
- }
- /*1*/ if(!IsPlayerInArea(i,-2799.996093, -173.397064, -2463.996093, 154.602935)){TextDrawSetString(ZonesTextdraw[i],"*");TextDrawShowForPlayer(i,ZonesTextdraw[i]);}
- /*2*/ if(!IsPlayerInArea(i,-2799.354492, 232.376708, -2615.354492, 696.376708)){TextDrawSetString(ZonesTextdraw[i],"*");TextDrawShowForPlayer(i,ZonesTextdraw[i]);}
- /*3*/ if(!IsPlayerInArea(i,-2276.547119, -86.489639, -2004.547119, 169.510360)){TextDrawSetString(ZonesTextdraw[i],"*");TextDrawShowForPlayer(i,ZonesTextdraw[i]);}
- /*4*/ if(!IsPlayerInArea(i,-2445.138183, -232.113327, -2293.138183, 223.886672)){TextDrawSetString(ZonesTextdraw[i],"*");TextDrawShowForPlayer(i,ZonesTextdraw[i]);}
- /*5*/ if(!IsPlayerInArea(i,-2328.167480, 337.696594, -1944.167480, 681.696594)){TextDrawSetString(ZonesTextdraw[i],"*");TextDrawShowForPlayer(i,ZonesTextdraw[i]);}
- /*6*/ if(!IsPlayerInArea(i,-1824.531494, 624.765625, -1496.531494, 920.765625)){TextDrawSetString(ZonesTextdraw[i],"*");TextDrawShowForPlayer(i,ZonesTextdraw[i]);}
- /*7*/ if(!IsPlayerInArea(i,-2439.947753, 1035.557861, -2119.947753, 1307.557861)){TextDrawSetString(ZonesTextdraw[i],"*");TextDrawShowForPlayer(i,ZonesTextdraw[i]);}
- /*8*/ if(!IsPlayerInArea(i,-1854.087280, 1178.869628, -1622.087280, 1410.869628)){TextDrawSetString(ZonesTextdraw[i],"*");TextDrawShowForPlayer(i,ZonesTextdraw[i]);}
- /*9*/ if(!IsPlayerInArea(i,-2213.718750, 710.110534, -1949.718750, 982.110534)){TextDrawSetString(ZonesTextdraw[i],"*");TextDrawShowForPlayer(i,ZonesTextdraw[i]);}
- /*10*/ if(!IsPlayerInArea(i,-2765.796386, 784.332397, -2437.796386, 1104.332397)){TextDrawSetString(ZonesTextdraw[i],"*");TextDrawShowForPlayer(i,ZonesTextdraw[i]);}
- /*11*/ if(!IsPlayerInArea(i,-1922.631958, -28.333175, -1706.631958, 403.666809)){TextDrawSetString(ZonesTextdraw[i],"*");TextDrawShowForPlayer(i,ZonesTextdraw[i]);}
- /*12*/ if(!IsPlayerInArea(i,-1957.691406, -758.583618, -1645.691406, -430.5836182)){TextDrawSetString(ZonesTextdraw[i],"*");TextDrawShowForPlayer(i,ZonesTextdraw[i]);}
- /*13*/ if(!IsPlayerInArea(i,-2518.000000, -602.239868, -2246.000000, -306.239868)){TextDrawSetString(ZonesTextdraw[i],"*");TextDrawShowForPlayer(i,ZonesTextdraw[i]);}
- if(IsPlayerInArea(i,-2799.996093, -173.397064, -2463.996093, 154.602935))
- {
- new color = dini_Int("/zones/zones.ini","Zone1");
- if(color == 13369540){ZoneTextLcn(i);}
- else if(color == -1439485014){ZoneTextRus(i);}
- else if(color == -86){ZoneTextTriad(i);}
- else if(color == 3407768){ZoneTextYugo(i);}
- else if(color == -65366){ZoneTextGerman(i);}
- else if(color ==1714618567){ZoneTextCuban(i);}
- }
- if(IsPlayerInArea(i,-2799.354492, 232.376708, -2615.354492, 696.376708))
- {
- new color = dini_Int("/zones/zones.ini","Zone2");
- if(color == 13369540){ZoneTextLcn(i);}
- else if(color == -1439485014){ZoneTextRus(i);}
- else if(color == -86){ZoneTextTriad(i);}
- else if(color == 3407768){ZoneTextYugo(i);}
- else if(color == -65366){ZoneTextGerman(i);}
- else if(color ==1714618567){ZoneTextCuban(i);}
- }
- if(IsPlayerInArea(i,-2276.547119, -86.489639, -2004.547119, 169.510360))
- {
- new color = dini_Int("/zones/zones.ini","Zone3");
- if(color == 13369540){ZoneTextLcn(i);}
- else if(color == -1439485014){ZoneTextRus(i);}
- else if(color == -86){ZoneTextTriad(i);}
- else if(color == 3407768){ZoneTextYugo(i);}
- else if(color == -65366){ZoneTextGerman(i);}
- else if(color ==1714618567){ZoneTextCuban(i);}
- }
- if(IsPlayerInArea(i,-2445.138183, -232.113327, -2293.138183, 223.886672))
- {
- new color = dini_Int("/zones/zones.ini","Zone4");
- if(color == 13369540){ZoneTextLcn(i);}
- else if(color == -1439485014){ZoneTextRus(i);}
- else if(color == -86){ZoneTextTriad(i);}
- else if(color == 3407768){ZoneTextYugo(i);}
- else if(color == -65366){ZoneTextGerman(i);}
- else if(color ==1714618567){ZoneTextCuban(i);}
- }
- if(IsPlayerInArea(i,-2328.167480, 337.696594, -1944.167480, 681.696594))
- {
- new color = dini_Int("/zones/zones.ini","Zone5");
- if(color == 13369540){ZoneTextLcn(i);}
- else if(color == -1439485014){ZoneTextRus(i);}
- else if(color == -86){ZoneTextTriad(i);}
- else if(color == 3407768){ZoneTextYugo(i);}
- else if(color == -65366){ZoneTextGerman(i);}
- else if(color ==1714618567){ZoneTextCuban(i);}
- }
- if(IsPlayerInArea(i,-1824.531494, 624.765625, -1496.531494, 920.765625))
- {
- new color = dini_Int("/zones/zones.ini","Zone6");
- if(color == 13369540){ZoneTextLcn(i);}
- else if(color == -1439485014){ZoneTextRus(i);}
- else if(color == -86){ZoneTextTriad(i);}
- else if(color == 3407768){ZoneTextYugo(i);}
- else if(color == -65366){ZoneTextGerman(i);}
- else if(color ==1714618567){ZoneTextCuban(i);}
- }
- if(IsPlayerInArea(i,-2439.947753, 1035.557861, -2119.947753, 1307.557861))
- {
- new color = dini_Int("/zones/zones.ini","Zone7");
- if(color == 13369540){ZoneTextLcn(i);}
- else if(color == -1439485014){ZoneTextRus(i);}
- else if(color == -86){ZoneTextTriad(i);}
- else if(color == 3407768){ZoneTextYugo(i);}
- else if(color == -65366){ZoneTextGerman(i);}
- else if(color ==1714618567){ZoneTextCuban(i);}
- }
- if(IsPlayerInArea(i,-1854.087280, 1178.869628, -1622.087280, 1410.869628))
- {
- new color = dini_Int("/zones/zones.ini","Zone8");
- if(color == 13369540){ZoneTextLcn(i);}
- else if(color == -1439485014){ZoneTextRus(i);}
- else if(color == -86){ZoneTextTriad(i);}
- else if(color == 3407768){ZoneTextYugo(i);}
- else if(color == -65366){ZoneTextGerman(i);}
- else if(color ==1714618567){ZoneTextCuban(i);}
- }
- if(IsPlayerInArea(i,-2213.718750, 710.110534, -1949.718750, 982.110534))
- {
- new color = dini_Int("/zones/zones.ini","Zone9");
- if(color == 13369540){ZoneTextLcn(i);}
- else if(color == -1439485014){ZoneTextRus(i);}
- else if(color == -86){ZoneTextTriad(i);}
- else if(color == 3407768){ZoneTextYugo(i);}
- else if(color == -65366){ZoneTextGerman(i);}
- else if(color ==1714618567){ZoneTextCuban(i);}
- }
- if(IsPlayerInArea(i,-2765.796386, 784.332397, -2437.796386, 1104.332397))
- {
- new color = dini_Int("/zones/zones.ini","Zone10");
- if(color == 13369540){ZoneTextLcn(i);}
- else if(color == -1439485014){ZoneTextRus(i);}
- else if(color == -86){ZoneTextTriad(i);}
- else if(color == 3407768){ZoneTextYugo(i);}
- else if(color == -65366){ZoneTextGerman(i);}
- else if(color ==1714618567){ZoneTextCuban(i);}
- }
- if(IsPlayerInArea(i,-1922.631958, -28.333175, -1706.631958, 403.666809))
- {
- new color = dini_Int("/zones/zones.ini","Zone11");
- if(color == 13369540){ZoneTextLcn(i);}
- else if(color == -1439485014){ZoneTextRus(i);}
- else if(color == -86){ZoneTextTriad(i);}
- else if(color == 3407768){ZoneTextYugo(i);}
- else if(color == -65366){ZoneTextGerman(i);}
- else if(color ==1714618567){ZoneTextCuban(i);}
- }
- if(IsPlayerInArea(i,-1957.691406, -758.583618, -1645.691406, -430.5836182))
- {
- new color = dini_Int("/zones/zones.ini","Zone12");
- if(color == 13369540){ZoneTextLcn(i);}
- else if(color == -1439485014){ZoneTextRus(i);}
- else if(color == -86){ZoneTextTriad(i);}
- else if(color == 3407768){ZoneTextYugo(i);}
- else if(color == -65366){ZoneTextGerman(i);}
- else if(color ==1714618567){ZoneTextCuban(i);}
- }
- if(IsPlayerInArea(i,-2518.000000, -602.239868, -2246.000000, -306.239868))
- {
- new color = dini_Int("/zones/zones.ini","Zone13");
- if(color == 13369540){ZoneTextLcn(i);}
- else if(color == -1439485014){ZoneTextRus(i);}
- else if(color == -86){ZoneTextTriad(i);}
- else if(color == 3407768){ZoneTextYugo(i);}
- else if(color == -65366){ZoneTextGerman(i);}
- else if(color ==1714618567){ZoneTextCuban(i);}
- }
- new str2[128];
- format(str2, sizeof(str2), "Kills:%d Deaths:%d Ratio:%0.2f",Spieler[i][Kills],Spieler[i][Deaths],Float:Spieler[i][Kills]/Float:Spieler[i][Deaths]);
- TextDrawSetString(StatsTextdraw[i],str2);
- TextDrawShowForPlayer(i,StatsTextdraw[i]);
- }
- }
- return 1;
- }
- public OnPlayerDeath(playerid, killerid, reason)
- {
- //---
- TextDrawHideForPlayer(playerid,txtTimeDisp);
- //---
- if(killerid==INVALID_PLAYER_ID){
- GameTextForPlayer(playerid,"---WASTED---",2000,3);
- }
- //----
- if(killerid != INVALID_PLAYER_ID)
- {
- if(Gang[killerid] == Gang[playerid] && IsDm[killerid] == 0)
- {
- teamkills[killerid]++;
- if (teamkills[killerid] > 2){Kick(killerid);}
- SendClientMessage(killerid,hellrot,"You have been punished for teamkillng (3 Teamkills and you get a kick)");
- GivePlayerMoney(killerid,-1000);
- ResetPlayerWeapons(killerid);
- GivePlayerWeapon(killerid,23,100);
- }
- //------------------------------------------------------------------------------
- else if(killerid != INVALID_PLAYER_ID && isAtRob[playerid])
- {
- GivePlayerMoney(killerid,6000);
- GivePlayerMoney(playerid,-6000);
- SendClientMessage(killerid, gruen, "The Robber is killed. You get 6.000$");
- isAtRob[playerid] = 0;
- }
- //------------------------------------------------------------------------------
- else if(killerid !=INVALID_PLAYER_ID && drugjob[playerid] == 1)
- {
- new StealName[MAX_PLAYER_NAME],LoserName[MAX_PLAYER_NAME];
- new akischwul[128];
- GetPlayerName(playerid,LoserName,sizeof(LoserName));
- GetPlayerName(killerid,StealName,sizeof(StealName));
- SendClientMessageToAll(COLOR_DARKRED, "|______San Francisco-News______|");
- SendClientMessageToAll(hellrot, " ");
- format(akischwul,sizeof(akischwul),"%s has stolen the drugs of %s ",StealName,LoserName);
- SendClientMessageToAll(weiss,akischwul);
- SendClientMessageToAll(weiss, "Stop him! And you get his Drugs !");
- SendClientMessageToAll(weiss, "You find him on the Mini-map(the Red Point)");
- SendClientMessageToAll(hellrot, " ");
- SendClientMessageToAll(COLOR_DARKRED, "|______San Francisco-News______|");
- SetPlayerCheckpoint(killerid,DeliverCheck,3.0);
- SendClientMessage(playerid,COLOR_RED,"You have lost your Drugs");
- drugjob[playerid] = 0;
- drugjob[killerid] = 1;
- SendClientMessage(killerid,COLOR_GREEN,"You have stolen the drugs bring them to the red point on the map");
- SetPlayerColor(killerid,COLOR_RED);
- }
- new kname[MAX_PLAYER_NAME],str3[128];
- GetPlayerName(killerid,kname,sizeof(kname));
- if(KillSpree[killerid] == 2){
- format(str3, sizeof(str3),"~r~ %s ~g~ IS DOMINATING",kname);
- GameTextForAll(str3,5000,4);
- SendClientMessage(killerid,COLOR_GREEN,"You have a KillingSpree of 3 You get 500$");
- GivePlayerMoney(killerid,500);
- }
- else if(KillSpree[killerid] == 4){
- format(str3, sizeof(str3),"~r~ %s ~g~ IS ON KILLING SPREE",kname);
- GameTextForAll(str3,5000,4);
- SendClientMessage(killerid,COLOR_GREEN,"You have a KillingSpree of 5 You get 800$ and Aromour for free");
- GivePlayerMoney(killerid,800);
- SetPlayerArmour(killerid,100);
- }
- else if(KillSpree[killerid] == 11){
- format(str3, sizeof(str3),"~r~ %s ~g~ HAS A MONSTER KILL",kname);
- GameTextForAll(str3,5000,4);
- SendClientMessage(killerid,COLOR_GREEN,"You have a KillingSpree of 10 You get 2000$ and Armour+Health for free");
- SetPlayerArmour(killerid,100);
- SetPlayerHealth(killerid,100);
- GivePlayerMoney(killerid,2000);
- }
- else if(KillSpree[killerid] == 15){
- format(str3, sizeof(str3),"~r~ %s ~g~ GODLIKE",kname);
- GameTextForAll(str3,5000,4);
- SendClientMessage(killerid,COLOR_GREEN,"You have a KillingSpree of 16 You get 2500$ and M4,MP5,Sniper,Deagle for free");
- GivePlayerWeapon(killerid,34,1000);
- GivePlayerWeapon(killerid,29,1000);
- GivePlayerWeapon(killerid,24,1000);
- GivePlayerWeapon(killerid,31,1000);
- GivePlayerMoney(killerid,2500);
- }
- else if(KillSpree[killerid] == 19){
- format(str3, sizeof(str3),"~r~ %s ~g~ WICKED SICK",kname);
- GameTextForAll(str3,5000,4);
- SendClientMessage(killerid,COLOR_GREEN,"You have a KillingSpree of 20 You get 3500$ and M4,MP5,Sniper,Deagle,Health,Armour for free");
- GivePlayerWeapon(killerid,34,1000);
- GivePlayerWeapon(killerid,29,1000);
- GivePlayerWeapon(killerid,24,1000);
- GivePlayerWeapon(killerid,31,1000);
- GivePlayerMoney(killerid,3500);
- SetPlayerArmour(killerid,100);
- SetPlayerHealth(killerid,100);
- }
- else if(KillSpree[killerid] >= 24){
- format(str3, sizeof(str3),"~g~ HOLY SHIT ~r~ %s with %d KILLS",kname,KillSpree[playerid]);
- GameTextForAll(str3,5000,4);
- SendClientMessage(killerid,COLOR_GREEN,"You have a ENOURMOUS KILLING SPREE for every kill while the Spree you will get 1000$");
- GivePlayerMoney(killerid,100);
- }
- if(Induel[playerid] == 1)
- {
- new string[256];
- new killername[MAX_PLAYER_NAME];
- new playername[MAX_PLAYER_NAME];
- GetPlayerName(killerid, killername, sizeof(killername));
- GetPlayerName(playerid, playername, sizeof(playername));
- if(duelRoom1 == playerid || duelRoom1 == killerid)
- {
- Inventation[playerid] = -1;
- InventationSent[playerid] = -1;
- Inventation[killerid] = -1;
- InventationSent[killerid] = -1;
- Induel[playerid] = 0;
- Induel[killerid] = 0;
- format(string, sizeof(string), "%s defeated %s in a duel and wins $%d", killername, playername, duelRoom1price);
- SendClientMessageToAll(GREEN, string);
- GivePlayerMoney(killerid, (duelRoom1price*2));
- SpawnPlayer(killerid);
- duelRoom1 = -1;
- return 1;
- }
- if(duelRoom2 == playerid || duelRoom2 == killerid)
- {
- Inventation[playerid] = -1;
- InventationSent[playerid] = -1;
- Inventation[killerid] = -1;
- InventationSent[killerid] = -1;
- Induel[playerid] = 0;
- Induel[killerid] = 0;
- format(string, sizeof(string), "%s defeated %s in a duel and wins $%d", killername, playername, duelRoom2price);
- SendClientMessageToAll(GREEN, string);
- GivePlayerMoney(killerid, (duelRoom2price*2));
- SpawnPlayer(killerid);
- duelRoom2 = -1;
- return 1;
- }
- if(duelRoom3 == playerid || duelRoom3 == killerid)
- {
- Inventation[playerid] = -1;
- InventationSent[playerid] = -1;
- Inventation[killerid] = -1;
- InventationSent[killerid] = -1;
- Induel[playerid] = 0;
- Induel[killerid] = 0;
- format(string, sizeof(string), "%s defeated %s in a duel and wins $%d", killername, playername, duelRoom3price);
- SendClientMessageToAll(GREEN, string);
- GivePlayerMoney(killerid, (duelRoom3price*2));
- SpawnPlayer(killerid);
- duelRoom3 = -1;
- return 1;
- }
- if(duelRoom4 == playerid || duelRoom4 == killerid)
- {
- Inventation[playerid] = -1;
- InventationSent[playerid] = -1;
- Inventation[killerid] = -1;
- InventationSent[killerid] = -1;
- Induel[playerid] = 0;
- Induel[killerid] = 0;
- format(string, sizeof(string), "%s defeated %s in a duel and wins $%d", killername, playername, duelRoom4price);
- SendClientMessageToAll(GREEN, string);
- GivePlayerMoney(killerid, (duelRoom4price*2));
- SpawnPlayer(killerid);
- duelRoom4 = -1;
- return 1;
- }
- return 1;
- }
- //------------------------------------------------------------------------------
- SetPlayerScore(killerid,GetPlayerScore(killerid)+1);
- new name[MAX_PLAYER_NAME],deathstring[128];
- GetPlayerName(killerid,name,sizeof(name));
- format(deathstring,sizeof(deathstring),"~r~Owned by %s",name);
- GameTextForPlayer(playerid,deathstring,2000,3);
- KillSpree[killerid]++;
- }
- SendDeathMessage(killerid,playerid,reason);
- KillSpree[playerid] = 0;
- DisablePlayerCheckpoint(playerid);
- Spieler[playerid][Deaths]++;
- Spieler[killerid][Kills]++;
- return 1;
- }
- public OnVehicleSpawn(vehicleid)
- {
- return 1;
- }
- public OnVehicleDeath(vehicleid, killerid)
- {
- return 1;
- }
- public OnPlayerText(playerid, text[])
- {
- // TEAM CHATS ==================================================================
- if (text[0] == '!')
- {
- new playerTeam = Gang[playerid];
- new string[128];
- new color;
- GetPlayerName(playerid, string, sizeof string);
- format(string,sizeof(string),"((**TEAMCHAT %s: %s. **))",string,text[1]);
- switch (playerTeam)
- {
- case TEAM_LCN: color = aqua;
- case TEAM_RUS: color = aqua;
- case TEAM_TRIADS: color = aqua;
- case TEAM_YUGO: color = aqua;
- case TEAM_GERMAN: color = aqua;
- case TEAM_CUBAN: color = aqua;
- case TEAM_GAMER: color = aqua;
- }
- for(new i; i < MAX_PLAYERS; i++)
- {
- if (Gang[i] == playerTeam)
- {
- SendClientMessage(i,color,string);
- }
- }
- return 0;
- }
- //--
- return 1;
- }
- public OnPlayerCommandText(playerid, cmdtext[])
- {
- // DMCDS BEGINN ================================================================
- dcmd(report,6,cmdtext);
- dcmd(kick,4,cmdtext);
- dcmd(ban,3,cmdtext);
- dcmd(seestats,8,cmdtext);
- dcmd(admins,6,cmdtext);
- dcmd(a,1,cmdtext);
- dcmd(dec,3,cmdtext);
- dcmd(makeadmin,9,cmdtext);
- dcmd(freeze,6,cmdtext);
- dcmd(unfreeze,8,cmdtext);
- dcmd(setkills,8,cmdtext);
- dcmd(setdeaths,9,cmdtext);
- dcmd(setscore,8,cmdtext);
- dcmd(givecash,8,cmdtext);
- dcmd(giveweapon,10,cmdtext);
- dcmd(explode,7,cmdtext);
- dcmd(spectate,8,cmdtext);
- dcmd(tele,4,cmdtext);
- dcmd(gethere,7,cmdtext);
- dcmd(pm,2,cmdtext);
- dcmd(setskin,7,cmdtext);
- dcmd(heal,4,cmdtext);
- dcmd(takeweaps,9,cmdtext);
- dcmd(setweather,10,cmdtext);
- dcmd(sethour,7,cmdtext);
- dcmd(veh,3,cmdtext);
- dcmd(seecash,7,cmdtext);
- dcmd(armour,6,cmdtext);
- dcmd(setcash,7,cmdtext);
- //dcmd duel
- dcmd(watchduels,10,cmdtext);
- dcmd(leavewatch,10,cmdtext);
- dcmd(duel,4,cmdtext);
- dcmd(acceptduel,10,cmdtext);
- dcmd(declineduel,11,cmdtext);
- //-------------------------------
- dcmd(givemoney,9,cmdtext);
- //------------------------------------------------------------------------------
- if(strcmp("/gbase",cmdtext,true,10)==0)
- {
- SetPlayerCheckpoint(playerid,GamerCheck,3.0);
- SendClientMessage(playerid,COLOR_GREEN,"Follow the red Point on your Mini-Map to come to the GamerBase");
- return 1;
- }
- if(strcmp("/join",cmdtext,true,10)==0)
- {
- if(Spieler[playerid][gamer] == 1)return SendClientMessage(playerid,COLOR_RED,"You are already in the Gamer-Team!");
- if(Spieler[playerid][Kills] < 500)return SendClientMessage(playerid,COLOR_RED,"You have not enough kills!/gamerinfo");
- if(GetPlayerMoney(playerid) < 200000)return SendClientMessage(playerid,COLOR_RED,"You have not enough money!/gamerinfo");
- if(IsPlayerInRangeOfPoint(playerid,10,-2282.1028,2349.4348,5.0961))
- {
- SendClientMessage(playerid,COLOR_GREEN,"You have sucsessfully joined the Gamer-Team have fun!");
- Spieler[playerid][gamer] = 1;
- GivePlayerMoney(playerid,-200000);
- }
- return 1;
- }
- if(strcmp("/o",cmdtext,true,10)==0)
- {
- if(IsPlayerInRangeOfPoint(playerid,10,-2273.7644042969, 2352.1525878906, 6.5936045646667) && Gang[playerid]==TEAM_GAMER)
- {
- MoveObject(Gamergate,-2273.7644042969, 2352.1525878906, -2.5936045646667,3.5);
- SetTimer("GamerTimer",5000,false);
- }
- return 1;
- }
- if(strcmp("/gamerinfo",cmdtext,true,10)==0)
- {
- SendClientMessage(playerid,COLOR_LIGHTBLUE,"***GAMER-INFO***");
- SendClientMessage(playerid,COLOR_YELLOW,"You must have 500 Kills and 200000$ to be able to join the Gamer team");
- SendClientMessage(playerid,COLOR_YELLOW,"In this team you will have better weapons,vehicles and a perfect base!");
- SendClientMessage(playerid,COLOR_YELLOW,"Type /gbase to know where their base is");
- return 1;
- }
- if (strcmp("/leave", cmdtext, true, 10) == 0)
- {
- if(IsDm[playerid] == 0) return SendClientMessage(playerid,COLOR_RED,"You are not in a DM Arena!");
- IsDm[playerid] =0 ;
- SendClientMessage(playerid,COLOR_GREEN,"You will spawn on the normal place after next death");
- return 1;
- }
- if (strcmp("/clear", cmdtext, true, 10) == 0)
- {
- if(Spieler[playerid][alvl] < 1)return SendClientMessage(playerid, COLOR_RED,"You must be a Moderator or higher to see clear the chat");
- for(new i=0;i<100;i++){
- SendClientMessageToAll(COLOR_RED," ");
- }
- new name[MAX_PLAYER_NAME],string[128];
- GetPlayerName(playerid,name,sizeof(name));
- format(string,sizeof(string),"Admin %s has cleared the chat",name);
- SendClientMessageToAll(COLOR_GREEN,string);
- return 1;
- }
- //------------------------------------------------------------------------------
- if (strcmp("/ahelp", cmdtext, true, 10) == 0)
- {
- if(Spieler[playerid][alvl] == 0)
- {
- SendClientMessage(playerid, COLOR_RED,"You must be a Moderator or higher to see admin commands");
- }
- if(Spieler[playerid][alvl] == 1)
- {
- SendClientMessage(playerid, COLOR_PURPLE,"[Moderator]: /a /dec /freeze /unfreeze /explode /spectate /kick /takeweaps /clear /seecash ");
- }
- if(Spieler[playerid][alvl] == 2)
- {
- SendClientMessage(playerid, COLOR_PURPLE,"[Moderator]: /a /dec /freeze /unfreeze /explode /spectate /kick /takeweaps /clear /seecash ");
- SendClientMessage(playerid, COLOR_PURPLE,"[Administrator]: /giveweapon /tele /gethere /setskin /heal /armour /sethour /setweather ");
- }
- if(Spieler[playerid][alvl] == 3)
- {
- SendClientMessage(playerid, COLOR_PURPLE,"[Moderator]: /a /dec /freeze /unfreeze /explode /spectate /kick /takeweaps /clear /seecash ");
- SendClientMessage(playerid, COLOR_PURPLE,"[Administrator]: /giveweapon /tele /gethere /setskin /heal /armour /sethour /setweather");
- SendClientMessage(playerid, COLOR_PURPLE,"[Super Admin]: /gmx /ban /setscore /setdeaths /setkills /givecash /setcash /veh");
- }
- if(Spieler[playerid][alvl] == 4)
- {
- SendClientMessage(playerid, COLOR_PURPLE,"[Moderator]: /a /dec /freeze /unfreeze /explode /spectate /kick /takeweaps /clear /seecash ");
- SendClientMessage(playerid, COLOR_PURPLE,"[Administrator]: /giveweapon /tele /gethere /setskin /heal /armour /sethour /setweather");
- SendClientMessage(playerid, COLOR_PURPLE,"[Super Admin]: /gmx /ban /setscore /setdeaths /setkills /givecash /setcash /veh");
- SendClientMessage(playerid, COLOR_PURPLE,"[ServerOwner]: /makeadmin");
- }
- return 1;
- }
- //------------------------------------------------------------------------------
- if (strcmp("/stats", cmdtext, true, 10) == 0)
- {
- new name[MAX_PLAYER_NAME], string[256], string2[256],string3[256];
- GetPlayerName(playerid, name, sizeof(name));
- format(string, sizeof(string), "|_________ Stats of %s __________|", name);
- format(string2, sizeof(string2), "[Kills: %d] [Deaths: %d] [Ratio: %0.2f]",Spieler[playerid][Kills], Spieler[playerid][Deaths],Float:Spieler[playerid][Kills]/Float:Spieler[playerid][Deaths]);
- format(string3, sizeof(string3), "[Cash: %d] [Score: %d] [Adminlevel: %d]",GetPlayerMoney(playerid),GetPlayerScore(playerid),Spieler[playerid][alvl]);
- SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
- SendClientMessage(playerid, COLOR_WHITE, string2);
- SendClientMessage(playerid, COLOR_WHITE, string3);
- SendClientMessage(playerid, COLOR_LIGHTBLUE, "|___________________________________|");
- return 1;
- }
- //------------------------------------------------------------------------------
- if (strcmp("/gmx",cmdtext,true,10) == 0)
- {
- if(Spieler[playerid][alvl] < 3){
- return SendClientMessage(playerid,COLOR_RED,"You must be Admin level 3 or higher to start a gmx");
- }
- new
- name[MAX_PLAYER_NAME],
- string[128];
- GetPlayerName(playerid,name,sizeof(name));
- format(string,sizeof(string),"[GMX] Admin %s has restarted the Server![GMX] ",name);
- SendClientMessageToAll(COLOR_LIGHTBLUE,string);
- SendRconCommand("gmx");
- return 1;
- }
- if (strcmp("/resetstats", cmdtext, true, 10) == 0)
- {
- Spieler[playerid][Deaths]=0;
- Spieler[playerid][Kills]=0;
- SetPlayerScore(playerid,0);
- SendClientMessage(playerid,hellrot,"You have reset your stats");
- return 1;
- }
- //------------------------------------------------------------------------------
- if (strcmp("/info", cmdtext, true) == 0)
- {
- ShowPlayerDialog(playerid, Rules, DIALOG_STYLE_MSGBOX, " ", "*** Information ***\n\n\n*This is a TeamDeathMatch Server you have to kill the Members of the other Mafias", "OK", " ");
- return 1;
- }
- if (strcmp("/startwar", cmdtext, true) == 0)
- {
- if(Gang[playerid]==TEAM_GAMER)return SendClientMessage(playerid,COLOR_RED,"Gamer Team can`t start Mafia-Wars");
- if(EnableAtack1 == 1)return SendClientMessage(playerid,COLOR_RED,"You can`t attack the Zone you must wait!(it can take 30 minutes)");
- if(Spieler[playerid][rang] < 4) return SendClientMessage(playerid,COLOR_RED,"You need the rank Associte to start a Mafia-War!");
- if(IsPlayerInArea(playerid,-2799.996093, -173.397064, -2463.996093, 154.602935))
- {
- new color = dini_Int("/zones/zones.ini","Zone1");
- if(color == 13369540){ZoneAtackLcn(playerid);}
- else if(color == -1439485014){ZoneAtackRus(playerid);}
- else if(color == -86){ZoneAtackTriad(playerid);}
- else if(color == 3407768){ZoneAtackYugo(playerid);}
- else if(color == -65366){ZoneAtackGerman(playerid);}
- else if(color ==1714618567){ZoneAtackCuban(playerid);}
- Zone1Atack = 1;
- }
- //Zone2=========================================================================
- else if(IsPlayerInArea(playerid,-2799.354492, 232.376708, -2615.354492, 696.376708))
- {
- new color = dini_Int("/zones/zones.ini","Zone2");
- if(color == 13369540){ZoneAtackLcn(playerid);}
- else if(color == -1439485014){ZoneAtackRus(playerid);}
- else if(color == -86){ZoneAtackTriad(playerid);}
- else if(color == 3407768){ZoneAtackYugo(playerid);}
- else if(color == -65366){ZoneAtackGerman(playerid);}
- else if(color ==1714618567){ZoneAtackCuban(playerid);}
- Zone2Atack = 1;
- }
- //ZONE3=========================================================================
- else if(IsPlayerInArea(playerid,-2276.547119, -86.489639, -2004.547119, 169.510360))
- {
- new color = dini_Int("/zones/zones.ini","Zone3");
- if(color == 13369540){ZoneAtackLcn(playerid);}
- else if(color == -1439485014){ZoneAtackRus(playerid);}
- else if(color == -86){ZoneAtackTriad(playerid);}
- else if(color == 3407768){ZoneAtackYugo(playerid);}
- else if(color == -65366){ZoneAtackGerman(playerid);}
- else if(color ==1714618567){ZoneAtackCuban(playerid);}
- Zone3Atack = 1;
- }
- //ZONE4=========================================================================
- else if(IsPlayerInArea(playerid,-2445.138183, -232.113327, -2293.138183, 223.886672))
- {
- new color = dini_Int("/zones/zones.ini","Zone4");
- if(color == 13369540){ZoneAtackLcn(playerid);}
- else if(color == -1439485014){ZoneAtackRus(playerid);}
- else if(color == -86){ZoneAtackTriad(playerid);}
- else if(color == 3407768){ZoneAtackYugo(playerid);}
- else if(color == -65366){ZoneAtackGerman(playerid);}
- else if(color ==1714618567){ZoneAtackCuban(playerid);}
- Zone4Atack = 1;
- }
- //ZONE5=========================================================================
- else if(IsPlayerInArea(playerid,-2328.167480, 337.696594, -1944.167480, 681.696594))
- {
- new color = dini_Int("/zones/zones.ini","Zone5");
- if(color == 13369540){ZoneAtackLcn(playerid);}
- else if(color == -1439485014){ZoneAtackRus(playerid);}
- else if(color == -86){ZoneAtackTriad(playerid);}
- else if(color == 3407768){ZoneAtackYugo(playerid);}
- else if(color == -65366){ZoneAtackGerman(playerid);}
- else if(color ==1714618567){ZoneAtackCuban(playerid);}
- Zone5Atack = 1;
- }
- //ZONE6=========================================================================
- else if(IsPlayerInArea(playerid,-1824.531494, 624.765625, -1496.531494, 920.765625))
- {
- new color = dini_Int("/zones/zones.ini","Zone6");
- if(color == 13369540){ZoneAtackLcn(playerid);}
- else if(color == -1439485014){ZoneAtackRus(playerid);}
- else if(color == -86){ZoneAtackTriad(playerid);}
- else if(color == 3407768){ZoneAtackYugo(playerid);}
- else if(color == -65366){ZoneAtackGerman(playerid);}
- else if(color ==1714618567){ZoneAtackCuban(playerid);}
- Zone6Atack = 1;
- }
- //ZONE7=========================================================================
- else if(IsPlayerInArea(playerid,-2439.947753, 1035.557861, -2119.947753, 1307.557861))
- {
- new color = dini_Int("/zones/zones.ini","Zone7");
- if(color == 13369540){ZoneAtackLcn(playerid);}
- else if(color == -1439485014){ZoneAtackRus(playerid);}
- else if(color == -86){ZoneAtackTriad(playerid);}
- else if(color == 3407768){ZoneAtackYugo(playerid);}
- else if(color == -65366){ZoneAtackGerman(playerid);}
- else if(color ==1714618567){ZoneAtackCuban(playerid);}
- Zone7Atack = 1;
- }
- //ZONE8=========================================================================
- else if(IsPlayerInArea(playerid,-1854.087280, 1178.869628, -1622.087280, 1410.869628))
- {
- new color = dini_Int("/zones/zones.ini","Zone8");
- if(color == 13369540){ZoneAtackLcn(playerid);}
- else if(color == -1439485014){ZoneAtackRus(playerid);}
- else if(color == -86){ZoneAtackTriad(playerid);}
- else if(color == 3407768){ZoneAtackYugo(playerid);}
- else if(color == -65366){ZoneAtackGerman(playerid);}
- else if(color ==1714618567){ZoneAtackCuban(playerid);}
- Zone8Atack = 1;
- }
- //ZONE9=========================================================================
- else if(IsPlayerInArea(playerid,-2213.718750, 710.110534, -1949.718750, 982.110534))
- {
- new color = dini_Int("/zones/zones.ini","Zone9");
- if(color == 13369540){ZoneAtackLcn(playerid);}
- else if(color == -1439485014){ZoneAtackRus(playerid);}
- else if(color == -86){ZoneAtackTriad(playerid);}
- else if(color == 3407768){ZoneAtackYugo(playerid);}
- else if(color == -65366){ZoneAtackGerman(playerid);}
- else if(color ==1714618567){ZoneAtackCuban(playerid);}
- Zone9Atack = 1;
- }
- //ZONE10=========================================================================
- else if(IsPlayerInArea(playerid,-2765.796386, 784.332397, -2437.796386, 1104.332397))
- {
- new color = dini_Int("/zones/zones.ini","Zone10");
- if(color == 13369540){ZoneAtackLcn(playerid);}
- else if(color == -1439485014){ZoneAtackRus(playerid);}
- else if(color == -86){ZoneAtackTriad(playerid);}
- else if(color == 3407768){ZoneAtackYugo(playerid);}
- else if(color == -65366){ZoneAtackGerman(playerid);}
- else if(color ==1714618567){ZoneAtackCuban(playerid);}
- Zone10Atack = 1;
- }
- //ZONE11=========================================================================
- else if(IsPlayerInArea(playerid,-1922.631958, -28.333175, -1706.631958, 403.666809))
- {
- new color = dini_Int("/zones/zones.ini","Zone11");
- if(color == 13369540){ZoneAtackLcn(playerid);}
- else if(color == -1439485014){ZoneAtackRus(playerid);}
- else if(color == -86){ZoneAtackTriad(playerid);}
- else if(color == 3407768){ZoneAtackYugo(playerid);}
- else if(color == -65366){ZoneAtackGerman(playerid);}
- else if(color ==1714618567){ZoneAtackCuban(playerid);}
- Zone11Atack = 1;
- }
- //ZONE12=========================================================================
- else if(IsPlayerInArea(playerid,-1957.691406, -758.583618, -1645.691406, -430.5836182))
- {
- new color = dini_Int("/zones/zones.ini","Zone12");
- if(color == 13369540){ZoneAtackLcn(playerid);}
- else if(color == -1439485014){ZoneAtackRus(playerid);}
- else if(color == -86){ZoneAtackTriad(playerid);}
- else if(color == 3407768){ZoneAtackYugo(playerid);}
- else if(color == -65366){ZoneAtackGerman(playerid);}
- else if(color ==1714618567){ZoneAtackCuban(playerid);}
- Zone12Atack = 1;
- }
- //ZONE13=========================================================================
- else if(IsPlayerInArea(playerid,-2518.000000, -602.239868, -2246.000000, -306.239868))
- {
- new color = dini_Int("/zones/zones.ini","Zone13");
- if(color == 13369540){ZoneAtackLcn(playerid);}
- else if(color == -1439485014){ZoneAtackRus(playerid);}
- else if(color == -86){ZoneAtackTriad(playerid);}
- else if(color == 3407768){ZoneAtackYugo(playerid);}
- else if(color == -65366){ZoneAtackGerman(playerid);}
- else if(color ==1714618567){ZoneAtackCuban(playerid);}
- Zone13Atack = 1;
- }
- return 1;
- }
- // Yugo Sniper ----------------------------------------------------------------
- if(!strcmp("/sniper",cmdtext))
- {
- //---Yugo
- if(IsPlayerInRangeOfPoint(playerid,2.0,-2629.3945,1403.8356,7.0938))
- {
- if(!CheckForSkin(playerid,125))return SendClientMessage(playerid,grau,"You are not in the Yugoslawian Sniper-Team!");
- SendClientMessage(playerid, purple, "SniperPlace");
- SetPlayerPos(playerid, -2661.7747,1377.8031,53.8972);
- SetPlayerFacingAngle(playerid,360.0);
- }
- //---Triads
- if(IsPlayerInRangeOfPoint(playerid,2.0,-2154.6587,641.8469,52.3672))//triads 118
- {
- if(!CheckForSkin(playerid,118))return SendClientMessage(playerid,grau,"You are not in the Triad Sniper-Team!");
- SendClientMessage(playerid, purple, "SniperPlace");
- SetPlayerPos(playerid, -2157.8088,662.8646,83.3784);
- SetPlayerFacingAngle(playerid,360.0);
- }
- //---Russians
- if(IsPlayerInRangeOfPoint(playerid,2.0,-2136.1626,-252.2975,35.3203)) //russians 112
- {
- if(!CheckForSkin(playerid,112))return SendClientMessage(playerid,grau,"You are not in the Russian Mafia Sniper-Team!");
- SendClientMessage(playerid, purple, "SniperPlace");
- SetPlayerPos(playerid, -2180.5122,-137.4114,50.3188);
- SetPlayerFacingAngle(playerid,360.0);
- }
- //----LCN
- if(IsPlayerInRangeOfPoint(playerid,2.0,-2723.2244,-320.9215,7.8438))
- {
- if(!CheckForSkin(playerid,126))return SendClientMessage(playerid,grau,"You are not in the LCN Sniper-Team!");
- SendClientMessage(playerid, purple, "SniperPlace");
- SetPlayerPos(playerid, -2718.6409,-319.2138,57.4873);
- SetPlayerFacingAngle(playerid,360.0);
- }
- //---Germans
- if(IsPlayerInRangeOfPoint(playerid,2.0,-2446.2515,528.8219,30.1906)) //Germans 165
- {
- if(!CheckForSkin(playerid,165))return SendClientMessage(playerid,grau,"You are not in the German Mafia Sniper-Team!");
- SendClientMessage(playerid, purple, "SniperPlace");
- SetPlayerPos(playerid, -2456.9453,456.0735,73.2578);
- SetPlayerFacingAngle(playerid,360.0);
- }
- //---Cubans
- if(IsPlayerInRangeOfPoint(playerid,2.0,-1866.9960,-219.3903,18.3750))
- {
- if(!CheckForSkin(playerid,46))return SendClientMessage(playerid,grau,"You are not in the Cuban Sniper-Team!");
- SendClientMessage(playerid, purple, "SniperPlace");
- SetPlayerPos(playerid, -1825.8037,-216.2334,30.3457);
- SetPlayerFacingAngle(playerid,360.0);
- }
- //Exits-------------------------------------------------------------------------
- //---LCN
- if(IsPlayerInRangeOfPoint(playerid,2.0,-2716.7261,-323.2274,57.4873))
- {
- if(!CheckForSkin(playerid,126))return SendClientMessage(playerid,grau,"You are not in the Sniper-Team!");
- SendClientMessage(playerid, purple, "Back to Base");
- SetPlayerPos(playerid,-2722.2542,-316.8507,7.6425);
- SetPlayerFacingAngle(playerid,360.0);
- }
- //---RUS
- if(IsPlayerInRangeOfPoint(playerid,2.0,-2179.8376,-148.2017,50.3188))
- {
- if(!CheckForSkin(playerid,112))return SendClientMessage(playerid,grau,"You are not in the Sniper-Team!");
- SendClientMessage(playerid, purple, "Back to Base");
- SetPlayerPos(playerid,-2134.8318,-247.8439,35.7980);
- SetPlayerFacingAngle(playerid,360.0);
- }
- //---Triad
- if(IsPlayerInRangeOfPoint(playerid,2.0,-2158.2214,675.8184,83.1719))
- {
- if(!CheckForSkin(playerid,118))return SendClientMessage(playerid,grau,"You are not in the Sniper-Team!");
- SendClientMessage(playerid, purple, "Back to Base");
- SetPlayerPos(playerid,-2154.9038,645.6788,52.3672);
- SetPlayerFacingAngle(playerid,360.0);
- }
- //---German
- if(IsPlayerInRangeOfPoint(playerid,2.0,-2456.9453,456.0735,73.2578))
- {
- if(!CheckForSkin(playerid,165)) return SendClientMessage(playerid,grau,"You are not in the Sniper-Team!");
- SendClientMessage(playerid, purple, "Back to Base");
- SetPlayerPos(playerid,-2446.2515,528.8219,30.1906);
- SetPlayerFacingAngle(playerid,360.0);
- }
- //---Cubans
- if(IsPlayerInRangeOfPoint(playerid,2.0,-1825.9111,-219.4470,30.3516))
- {
- if(!CheckForSkin(playerid,46)) return SendClientMessage(playerid,grau,"You are not in the Sniper-Team!!");
- SendClientMessage(playerid, purple, "Back to Base");
- SetPlayerPos(playerid,-1872.5337,-218.0692,18.3750);
- SetPlayerFacingAngle(playerid,360.0);
- }
- return 1;
- }
- //------------------------------------------------------------------------------
- if(!strcmp(cmdtext, "/help"))
- {
- SendClientMessage(playerid, hellblau, "***HELP***");
- SendClientMessage(playerid, gelb, "[GENERAL]: /report /admins /dm /leave /me");
- SendClientMessage(playerid, gelb, "[GENERAL]: /fstyle /kill /givemoney /gamerinfo");
- SendClientMessage(playerid, gelb, "[JOB]: /druginfo /getdrugs /deliver /rob");
- SendClientMessage(playerid, gelb, "[BOMB]: /buybomb /plant /expbomb");
- SendClientMessage(playerid, gelb, "[ACCOUNT]: /stats /resetstats /seestats /pm");
- SendClientMessage(playerid, gelb, "[RANK]: /rankstats /rinfo");
- SendClientMessage(playerid, gelb, "[TEAM]: ![TEXT] /sniper /shop /startwar /warhelp");
- SendClientMessage(playerid, gelb, "[DUEL]: /duel /acceptduel /declineduel /watchduels /leavewatch");
- SendClientMessage(playerid, gelb, "[ABOUT SERVER]: /credits /rules /forum");
- return 1;
- }
- //------------------------------------------------------------------------------
- if (strcmp("/forum", cmdtext, true) == 0)
- {
- SendClientMessage (playerid, hellblau, "Forum: www.gta-dm.de");
- return 1;
- }
- //------------------------------------------------------------------------------
- if (strcmp("/rinfo", cmdtext, true) == 0)
- {
- ShowPlayerDialog(playerid, RInfo, DIALOG_STYLE_MSGBOX, " ","Rank Info:\n\n-Rank: BabyKiller = 0 Kills, 500$\n-Rank: Outlaw = 25 Kills, 800$\n-Rank: Newcomer = 50 Kills, 1500$\n-Rank: Associate = 100 Kills, 2500$\n-Rank: Soldier = 150 Kills, 3500$\n-Rank: Killer = 250 Kills, 4500$\n-Rank: Capo = 400 Kills, 5000$\n-Rank: Streetboss = 600 Kills, 6000$\n-Rank: Underboss = 900 Kills, 8000$\n-Rank: Godfather = 1500 Kills, 10000$","OK","Cancel");
- return 1;
- }
- if (strcmp("/warhelp", cmdtext, true) == 0)
- {
- SendClientMessage(playerid,hellblau,"***TURF HELP***");
- SendClientMessage(playerid,gelb,"You can start a Mafia-War between two mafias when you have the rank Associate");
- SendClientMessage(playerid,gelb,"Note: You must be in enemys Mafia zone to be able to start the war.");
- SendClientMessage(playerid,gelb,"You can start the mafia war with the cmd /startwar.");
- return 1;
- }
- //------------------------------------------------------------------------------
- if (strcmp("/rankstats", cmdtext, true) == 0)
- {
- if(Spieler[playerid][rang] == 1 ) // BabyKiller
- {
- SendClientMessage(playerid,hellblau," Your Rank Stats");
- SendClientMessage(playerid,grau,"Your Mafia Rank: BabyKiller || Next Rank: Outlaw || Your Gage: [500$]");
- SendClientMessage(playerid,weiss,"For the rank infos type /rinfo");
- }
- if(Spieler[playerid][rang] == 2 ) //Newcomer
- {
- SendClientMessage(playerid,hellblau," Your Rank Stats");
- SendClientMessage(playerid,grau,"Your Mafia Rank: Outlaw || Next Rank: Newcomer || Your Gage: [800$]");
- SendClientMessage(playerid,weiss,"For the rank infos type /rinfo");
- }
- if(Spieler[playerid][rang] == 3 ) // Outlaw
- {
- SendClientMessage(playerid,hellblau," Your Rank Stats");
- SendClientMessage(playerid,grau,"Your Mafia Rank: Newcomer || Next Rank: Associate || Your Gage: [1500$]");
- }
- if(Spieler[playerid][rang] == 4 ) // Associate
- {
- SendClientMessage(playerid,hellblau," Your Rank Stats");
- SendClientMessage(playerid,grau,"Your Mafia Rank: Associate || Next Rank: Soldier || Your Gage: [2500$]");
- }
- if(Spieler[playerid][rang] == 5 ) // Soldier
- {
- SendClientMessage(playerid,hellblau," Your Rank Stats");
- SendClientMessage(playerid,grau,"Your Mafia Rank: Soldier || Next Rank: Killer || Your Gage: [4000$]");
- }
- if(Spieler[playerid][rang] == 6 ) // killer
- {
- SendClientMessage(playerid,hellblau," Your Rank Stats");
- SendClientMessage(playerid,grau,"Your Mafia Rank: Killer || Next Rank: Capo || Your Gage: [6000$]");
- }
- if(Spieler[playerid][rang] == 7 ) // capo
- {
- SendClientMessage(playerid,hellblau," Your Rank Stats");
- SendClientMessage(playerid,grau,"Your Mafia Rank: Capo || Next Rank: StreetBoss || Your Gage: [8500$]");
- }
- if(Spieler[playerid][rang] == 8 ) // sTreetBoss
- {
- SendClientMessage(playerid,hellblau," Your Rank Stats");
- SendClientMessage(playerid,grau,"Your Mafia Rank: StreetBoss || Next Rank: UnderBoss || Your Gage: [11000$]");
- }
- if(Spieler[playerid][rang] == 9 ) //UnderBOss
- {
- SendClientMessage(playerid,hellblau," Your Rank Stats");
- SendClientMessage(playerid,grau,"Your Mafia Rank: UnderBoss || Next Rank: GodFather || Your Gage: [15000$]");
- }
- if(Spieler[playerid][rang] == 10 ) // GodFather
- {
- SendClientMessage(playerid,hellblau," Your Rank Stats");
- SendClientMessage(playerid,grau,"Your Mafia Rank: GodFather || Your Gage: [30000$]");
- }
- return 1;
- }
- //------------------------------------------------------------------------------
- if (strcmp("/shop", cmdtext, true) == 0)
- {
- if(IsPlayerInRangeOfPoint(playerid,2.0,-2717.8010,-315.7959,7.8438))//lcn
- {
- if(Gang[playerid] != TEAM_LCN) return SendClientMessage(playerid,COLOR_RED,"You are not in the La Cosa Nostra Family");
- ShowDialog(playerid);
- }
- if(IsPlayerInRangeOfPoint(playerid,2.0,-2136.3655,-244.4974,35.3203))//rus
- {
- if(Gang[playerid] != TEAM_RUS) return SendClientMessage(playerid,COLOR_RED,"You are not in the Russian Mafia");
- ShowDialog(playerid);
- }
- if(IsPlayerInRangeOfPoint(playerid,2.0,-2154.7065,647.1374,52.3672))//triad
- {
- if(Gang[playerid] != TEAM_TRIADS) return SendClientMessage(playerid,COLOR_RED,"You are not in the Triad Family");
- ShowDialog(playerid);
- }
- if(IsPlayerInRangeOfPoint(playerid,2.0,-2627.5317,1408.6331,7.0938))//yugo
- {
- if(Gang[playerid] != TEAM_YUGO) return SendClientMessage(playerid,COLOR_RED,"You are not in the Yogoslawian Mafia");
- ShowDialog(playerid);
- }
- if(IsPlayerInRangeOfPoint(playerid,2.0,-2446.0503,517.9012,30.1604))// german
- {
- if(Gang[playerid] != TEAM_GERMAN) return SendClientMessage(playerid,COLOR_RED,"You are not in the German Mafia");
- ShowDialog(playerid);
- }
- if(IsPlayerInRangeOfPoint(playerid,2.0,-1868.9342,-219.5195,18.3750))//cuban
- {
- if(Gang[playerid] != TEAM_CUBAN) return SendClientMessage(playerid,COLOR_RED,"You are not in the Cuban Mafia");
- ShowDialog(playerid);
- }
- return 1;
- }
- //------------------------------------------------------------------------------
- if (strcmp("/fstyle", cmdtext, true) == 0)
- {
- ShowPlayerDialog(playerid, Fight, DIALOG_STYLE_LIST, "Fight styles", "Kneehead \nBoxing \nGrabkick \nKungfu ", "Select", "Cancel");
- return 1;
- }
- //------------------------------------------------------------------------------
- if (strcmp("/credits", cmdtext, true, 10) == 0)
- {
- ShowPlayerDialog(playerid, Credits, DIALOG_STYLE_MSGBOX, "Credits of the Gamemode", "San Francisco Mafia Wars\n\nSpecial Thanks to:\nBlackFoX_UD_ - For support\nM4rciii - For Support\n[NeS]Fischer - For Support \nInternetInk aka Benjamin - For Support\nDouble-O-Seven - For JunkBuster\nwww.samp.breadfish.de\n Special Thanks to NoTime\n\nDeveloped & Scripted by Hustler & Shukaz ©", "OK", " ");
- return 1;
- }
- //------------------------------------------------------------------------------
- if (strcmp("/rules", cmdtext, true) == 0)
- {
- ShowPlayerDialog(playerid, Rules, DIALOG_STYLE_MSGBOX, " ", "***Rules***\n\n\n*Respect: We didn`t tolerate any racist remarks on this Server!\n*Driver drive-by on player without vehicle = -1000$&Death\n*If you make advertising on this Server, you get banned!\n*You can also be banned for cheating or bugusing\n*When you have 3 teamkills you will be KICKED automatically \n\nOtherwise, we wish you much fun on this Server!", "OK", "OK");
- return 1;
- }
- //------------------------------------------------------------------------------
- if(!strcmp(cmdtext, "/me", true, 3))
- {
- if(!cmdtext[3])return SendClientMessage(playerid, grau, "USAGE: /me [action]");
- new str[128];
- GetPlayerName(playerid, str, sizeof(str));
- format(str, sizeof(str), "* %s %s", str, cmdtext[4]);
- SendClientMessageToAll(0xC2A2DAAA, str);
- return 1;
- }
- //------------------------------------------------------------------------------
- if (strcmp("/kill", cmdtext, true) == 0)
- {
- IsDm[playerid] = 0;
- SetPlayerHealth(playerid,0.0);
- return 1;
- }
- //------------------------------------------------------------------------------
- if(strcmp(cmdtext, "/rob", true) == 0)
- {
- if(!IsPlayerInRangeOfPoint(playerid,20.0,-2026.4122,156.4898,29.0391))
- {
- SendClientMessage(playerid,grau,"You are not at the Gas-Station!");
- return 1;
- }
- if(rob)
- {
- SendClientMessage(playerid,grau,"The Gas-Station has been robbed!");
- return 1;
- }
- TogglePlayerControllable(playerid,0);
- rob = 1;
- SetTimer("robtimer",robtime,0);
- SetTimerEx("freezetimer",freezetime,0,"i",playerid);
- SendClientMessageToAll(COLOR_DARKRED, "|______San Francisco-News______|");
- SendClientMessageToAll(hellrot, " ");
- new name[MAX_PLAYER_NAME],string2[128];
- GetPlayerName(playerid,name,sizeof(name));
- format(string2,sizeof(string2),"%s is robing the Gas-Station",name);
- SendClientMessageToAll(weiss,string2);
- SendClientMessageToAll(weiss, "Stop him! And you get 6.000$");
- SendClientMessageToAll(hellrot, " ");
- SendClientMessageToAll(COLOR_DARKRED, "|______San Francisco-News______|");
- SendClientMessage(playerid,COLOR_GREEN,"You are robbing the Gas-Station wait 1 Minutes!");
- SetPlayerHealth(playerid,999999999);
- return 1;
- }
- //------------------------------------------------------------------------------
- if(!strcmp("/buybomb", cmdtext))
- {
- if(!IsPlayerInRangeOfPoint(playerid,5.0,-2033.7944,148.7538,28.8359))
- {
- SendClientMessage(playerid,hellrot,"You are not at the Bomb-Shop!");
- return 1;
- }
- if(GetPlayerMoney(playerid) < 5000)
- {
- SendClientMessage(playerid,hellrot,"You have not enough Money for a Bomb!");
- return 1;
- }
- SendClientMessage(playerid,aqua,"You have sucsessful buyed a Bomb! (type /plant to plant the bomb)");
- PlayerHasBomb[playerid] = 1;
- GivePlayerMoney(playerid,-5000);
- return 1;
- }
- if(!strcmp("/plant", cmdtext))
- {
- if(PlayerHasBomb[playerid] == 0)
- {
- SendClientMessage(playerid,hellrot,"You have not a Bomb");
- return 1;
- }
- ApplyAnimation(playerid, "BOMBER", "BOM_Plant", 4.0, 0, 0, 0, 0, 0);
- new Float:plX,Float:plY,Float:plZ;
- GetPlayerPos(playerid,plX,plY,plZ);
- BombenObject[playerid] = CreateObject(1252,plX,plY,plZ-0.85,0.0,0.0,0.0);
- PlayerHasBomb[playerid] = 0;
- IsBombPlanted[playerid] = 1;
- SendClientMessage(playerid,blau,"Bomb is planted! /expbomb to explode it");
- ApplyAnimation(playerid, "BOMBER", "BOM_Plant", 4.0, 0, 0, 0, 0, 0);//Animation
- return 1;
- }
- if(!strcmp("/expbomb",cmdtext))
- {
- if(IsBombPlanted[playerid] == 0)
- {
- SendClientMessage(playerid,grau,"You havent planted the bomb!");
- return 1;
- }
- BombExplode(playerid);
- IsBombPlanted[playerid]= 0;
- return 1;
- }
- if (!strcmp("/dm",cmdtext))
- {
- if(IsDm[playerid] >=1)return SendClientMessage(playerid,COLOR_RED,"You are already in a /dm arena !");
- ShowPlayerDialog(playerid, DIALOG_DM, DIALOG_STYLE_LIST, "Aviable DM Arenas", "Sniper-DeathMatch\nDeagle-DeathMatch \nGrenade-DeathMatch \nAll Inclusive-DeathMatch \nStreet Fight-DeathMatch\nTactic-DeathMatch", "Select", "Cancel");
- return 1;
- }
- //------------------------------------------------------------------------------
- if(!strcmp(cmdtext, "/druginfo"))
- {
- SetPlayerCheckpoint(playerid, Checkpoint1, 3.0);
- SendClientMessage(playerid,COLOR_GREEN,"Follow the red point on the Mini-map to buy the drugs");
- return 1;
- }
- // -----------------------------------------------------------------------------
- if(!strcmp(cmdtext, "/getdrugs"))
- {
- if(IsPlayerInRangeOfPoint(playerid,5.0,-1890.8228,-1698.6608,21.7500))
- {
- if(DrugsStolen == 1) return SendClientMessage(playerid,COLOR_RED,"You must wait because the drugs are not here jet(It can take 2 Hours)");
- if(drugjob[playerid] == 1)return SendClientMessage(playerid,COLOR_RED,"You have already buyed Drugs!");
- SetTimer("DrugTimer",7000000,false);
- DrugsStolen = 1;
- drugjob[playerid] = 1;
- SendClientMessage(playerid, COLOR_GREEN, "Sucsesfull get the Drugs now follow the red point on the map and /deliver it!");
- DisablePlayerCheckpoint(playerid);
- SetPlayerColor(playerid,COLOR_RED);
- SetPlayerCheckpoint(playerid,DeliverCheck,3.0);
- new pname[MAX_PLAYER_NAME],dakigay2[128];
- GetPlayerName(playerid,pname,sizeof(pname));
- SendClientMessageToAll(COLOR_DARKRED, "|______San Francisco-News______|");
- SendClientMessageToAll(hellrot, " ");
- format(dakigay2,sizeof(dakigay2),"%s has get the Drugs",pname);
- SendClientMessageToAll(weiss,dakigay2);
- SendClientMessageToAll(weiss, "Stop him! And you get his Drugs !");
- SendClientMessageToAll(weiss, "You find him on the Mini-map(the Red Point)");
- SendClientMessageToAll(hellrot, " ");
- SendClientMessageToAll(COLOR_DARKRED, "|______San Francisco-News______|");
- }
- return 1;
- }
- //------------------------------------------------------------------------------
- if(!strcmp(cmdtext, "/deliver"))
- {
- if(IsPlayerInRangeOfPoint(playerid,5.0,-1372.3959,1491.3230,11.0391))
- {
- if(drugjob[playerid] == 0) return SendClientMessage(playerid,COLOR_RED,"You have not the drugs!");
- GameTextForPlayer(playerid, "~g~You Completed the job, well done! +10000$", 3000, 3);
- GivePlayerMoney(playerid,10000);
- DisablePlayerCheckpoint(playerid);
- drugjob[playerid] = 0;
- SendClientMessageToAll(rot,"The Drus have been deliverd");
- if (Gang[playerid] == TEAM_LCN) { SetPlayerColor(playerid,gruen);}//LCN COLOR GREEN
- else if (Gang[playerid] == TEAM_RUS) { SetPlayerColor(playerid,rot);}//RUSSIA COLOR RED
- else if (Gang[playerid] == TEAM_TRIADS) { SetPlayerColor(playerid,weiss);}//TRIADS YELLOW
- else if (Gang[playerid] == TEAM_YUGO) { SetPlayerColor(playerid,yugoblau);}//YUGOS GREY
- else if (Gang[playerid] == TEAM_GERMAN) { SetPlayerColor(playerid,gelb);}//GERMANS
- else if (Gang[playerid] == TEAM_CUBAN) { SetPlayerColor(playerid,braun);}//CUBANS
- }
- return 1;
- //------------------------------------------------------------------------------
- }
- return 0;
- }
- public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
- {
- if(PlayerAtacker[playerid] == 1){RemovePlayerFromVehicle(playerid);}
- return 1;
- }
- stock IsPlayerInArea(playerid,Float:minX,Float:minY,Float:maxX,Float:maxY)
- {
- new Float:pX,Float:pY,Float:pZ;
- GetPlayerPos(playerid,pX,pY,pZ);
- if(pX >= minX && pX <= maxX && pY >= minY && pY <= maxY) return 1;
- return 0;
- }
- public OnPlayerExitVehicle(playerid, vehicleid)
- {
- return 1;
- }
- public OnPlayerStateChange(playerid, newstate, oldstate)
- {
- new getcar = GetPlayerVehicleID(playerid);
- if(IsItLcnCar(getcar))
- {
- if(Gang[playerid]==TEAM_LCN) { }
- else
- {
- RemovePlayerFromVehicle(playerid);
- SendClientMessage(playerid,COLOR_RED, "You are not a part of the La Cosa Nostra family");
- }
- }
- else if(IsItRusCar(getcar))
- {
- if(Gang[playerid]==TEAM_RUS) { }
- else
- {
- RemovePlayerFromVehicle(playerid);
- SendClientMessage(playerid,COLOR_RED, "You are not a part of the Russian Mafia family");
- }
- }
- else if(IsItTriadCar(getcar))
- {
- if(Gang[playerid]==TEAM_TRIADS) { }
- else
- {
- RemovePlayerFromVehicle(playerid);
- SendClientMessage(playerid,COLOR_RED, "You are not a part of the Triad family");
- }
- }
- else if(IsItYugoCar(getcar))
- {
- if(Gang[playerid]==TEAM_YUGO) { }
- else
- {
- RemovePlayerFromVehicle(playerid);
- SendClientMessage(playerid,COLOR_RED, "You are not a part of the Yugoslawian Mafia family");
- }
- }
- else if(IsItGermanCar(getcar))
- {
- if(Gang[playerid]==TEAM_GERMAN) { }
- else
- {
- RemovePlayerFromVehicle(playerid);
- SendClientMessage(playerid,COLOR_RED, "You are not a part of the German Mafia family");
- }
- }
- else if(IsItCubanCar(getcar))
- {
- if(Gang[playerid]==TEAM_CUBAN) { }
- else
- {
- RemovePlayerFromVehicle(playerid);
- SendClientMessage(playerid,COLOR_RED, "You are not a part of the Cuban Mafia family");
- }
- }
- else if(IsItGamerCar(getcar))
- {
- if(Gang[playerid] == TEAM_GAMER){}
- else
- {
- RemovePlayerFromVehicle(playerid);
- SendClientMessage(playerid,COLOR_RED,"You are not in the Gamer-Team /gamerifno to get informations");
- }
- }
- if(newstate == PLAYER_STATE_DRIVER)
- {
- if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 447 && Spieler[playerid][rang] < 7)
- {
- RemovePlayerFromVehicle(playerid);
- SendClientMessage(playerid,COLOR_RED,"You must have the Rank Capo or higher to be able to fly with Sparrow");
- }
- }
- return 1;
- }
- public OnPlayerEnterCheckpoint(playerid)
- {
- return 1;
- }
- public OnPlayerLeaveCheckpoint(playerid)
- {
- return 1;
- }
- public OnPlayerEnterRaceCheckpoint(playerid)
- {
- return 1;
- }
- public OnPlayerLeaveRaceCheckpoint(playerid)
- {
- return 1;
- }
- public OnRconCommand(cmd[])
- {
- return 1;
- }
- public OnPlayerRequestSpawn(playerid)
- {
- return 1;
- }
- public OnObjectMoved(objectid)
- {
- return 1;
- }
- public OnPlayerObjectMoved(playerid, objectid)
- {
- return 1;
- }
- public OnPlayerPickUpPickup(playerid, pickupid)
- {
- //Sniper Story------------------------------------------------------------------
- if(pickupid == lcnteleportpickup && CheckForSkin(playerid,126)){GameTextForPlayer(playerid,"~g~ Type /sniper to come to lcn sniperplace",2000,3);}
- if(pickupid == yugoteleportpickup && CheckForSkin(playerid,125)){GameTextForPlayer(playerid,"~w~ Type /sniper to come to yugo sniperplace",2000,3);}
- if(pickupid == russteleportpickup && CheckForSkin(playerid,112)){GameTextForPlayer(playerid,"~r~ Type /sniper to come to russian sniperplace",2000,3);}
- if(pickupid == triadteleportpickup && CheckForSkin(playerid,117)){GameTextForPlayer(playerid,"~y~ Type /sniper to come to triad sniperplace",2000,3);}
- if(pickupid == cubanteleportpickup && CheckForSkin(playerid,46)){GameTextForPlayer(playerid,"~r~ Type /sniper to come to russian sniperplace",2000,3);}
- if(pickupid == germanteleportpickup && CheckForSkin(playerid,165)){GameTextForPlayer(playerid,"~y~ Type /sniper to come to german sniperplace",2000,3);}
- //--------
- if(pickupid == lcnteleportpickup2 && CheckForSkin(playerid,126)){GameTextForPlayer(playerid,"~g~ Type /sniper to go back to the base",2000,3);}
- if(pickupid == russteleportpickup2 && CheckForSkin(playerid,112)){GameTextForPlayer(playerid,"~r~ Type /sniper to go back to the base",2000,3);}
- if(pickupid == triadteleportpickup2 && CheckForSkin(playerid,117)){GameTextForPlayer(playerid,"~y~ Type /sniper to go back to the base",2000,3);}
- if(pickupid == germanteleportpickup2 && CheckForSkin(playerid,165)){GameTextForPlayer(playerid,"~r~ Type /sniper to go back to the base",2000,3);}
- if(pickupid == cubanteleportpickup2 && CheckForSkin(playerid,46)){GameTextForPlayer(playerid,"~y~ Type /sniper to go back to the base",2000,3);}
- //Shop Story--------------------------------------------------------------------
- if(pickupid == lcnwaffenpickup){GameTextForPlayer(playerid,"~g~ Type /shop to buy weapons etc.",2000,3);}
- if(pickupid == russenwaffenpickup){GameTextForPlayer(playerid,"~r~ Type /shop to buy weapons etc.",2000,3);}
- if(pickupid == triadenwaffenpickup){GameTextForPlayer(playerid,"~w~ Type /shop to buy weapons etc.",2000,3);}
- if(pickupid == yugowaffenpickup){GameTextForPlayer(playerid,"~b~ Type /shop to buy weapons etc.",2000,3);}
- if(pickupid == germanwaffenpickup){GameTextForPlayer(playerid,"~y~ Type /shop to buy weapons etc.",2000,3);}
- if(pickupid == cubanwaffenpickup){GameTextForPlayer(playerid,"~b~ Type /shop to buy weapons etc.",2000,3);}
- // Minijob --------------------------------------------------------------------
- if(pickupid == lcndeliver){GameTextForPlayer(playerid,"~g~ Type /deliver to sell your products",2000,3);}
- if(pickupid == buydrugpick){GameTextForPlayer(playerid,"~w~ Type /getdrugs to buy products",2000,3);}
- //StreetFithg -----------------------------------------------------------------
- if(pickupid == GolfPick){GivePlayerWeapon(playerid,2,1);}
- if(pickupid == KnifePick){GivePlayerWeapon(playerid,4,1);}
- if(pickupid == BasiPick){GivePlayerWeapon(playerid,5,1);}
- if(pickupid == ShovelPick){GivePlayerWeapon(playerid,6,1);}
- if(pickupid == PoolPick){GivePlayerWeapon(playerid,7,1);}
- if(pickupid == AkPick){new w=0; GivePlayerWeapon(playerid,30,w);}
- if(pickupid == GamerInfo){GameTextForPlayer(playerid,"~g~ /JOIN FOR JOINING THE GAMER TEAM",2000,3);}
- return 1;
- }
- public OnVehicleMod(playerid, vehicleid, componentid)
- {
- return 1;
- }
- public OnVehiclePaintjob(playerid, vehicleid, paintjobid)
- {
- return 1;
- }
- public OnVehicleRespray(playerid, vehicleid, color1, color2)
- {
- return 1;
- }
- public OnPlayerSelectedMenuRow(playerid, row)
- {
- return 1;
- }
- public OnPlayerExitedMenu(playerid)
- {
- return 1;
- }
- public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
- {
- return 1;
- }
- public OnRconLoginAttempt(ip[], password[], success)
- {
- return 1;
- }
- public OnPlayerUpdate(playerid)
- {
- return 1;
- }
- public OnPlayerStreamIn(playerid, forplayerid)
- {
- return 1;
- }
- public OnPlayerStreamOut(playerid, forplayerid)
- {
- return 1;
- }
- public OnVehicleStreamIn(vehicleid, forplayerid)
- {
- return 1;
- }
- public OnVehicleStreamOut(vehicleid, forplayerid)
- {
- return 1;
- }
- public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
- {
- // REGISTER SYSTEM =============================================================
- new pname[MAX_PLAYERS],accFormat[128];
- GetPlayerName(playerid,pname,sizeof pname);
- format(accFormat,sizeof accFormat,"acc/%s.sav",pname);
- if(response)
- {
- switch(dialogid)
- {
- case DIALOG_LOGIN:
- {
- if(!strlen(inputtext))
- {
- ShowPlayerDialog(playerid,DIALOG_LOGIN,1,"Login","Hello!\nYor Account has been founded!\nPlease log in!","Cancel","Next");
- return SendClientMessage(playerid,0xFFFFFFFF,"No password!");
- }
- if(strcmp(inputtext,dini_Get(accFormat,"Passwort")) == 0)
- {
- Spieler[playerid][rang] = dini_Int(accFormat,"rang");
- Spieler[playerid][alvl] = dini_Int(accFormat,"AdminLvl");
- Spieler[playerid][Kills] = dini_Int(accFormat,"Kills");
- Spieler[playerid][Deaths] = dini_Int(accFormat,"Deaths");
- GivePlayerMoney(playerid,dini_Int(accFormat,"Geld"));
- SetPlayerScore(playerid,dini_Int(accFormat,"Score"));
- Spieler[playerid][gamer] = dini_Int(accFormat,"gamer");
- Spieler[playerid][eingeloggt] = 1;
- SendClientMessage(playerid,COLOR_GREEN,"You have been sucessfully logged in.");
- }
- else
- {
- ShowPlayerDialog(playerid,DIALOG_LOGIN,1,"Login","Hello!\nYor Account has been founded!\nPlease log in!","Cancel","Next");
- SendClientMessage(playerid,COLOR_RED,"This password is wrong!");
- }
- }
- case DIALOG_REG:
- {
- if(!strlen(inputtext))
- {
- ShowPlayerDialog(playerid,DIALOG_REG,1,"Register","You have not an Account on this Server\nPlease Register!","Cancel","Next");
- return SendClientMessage(playerid,COLOR_RED,"This password ist too short!");
- }
- dini_Create(accFormat);
- dini_Set(accFormat,"Passwort",inputtext);
- Spieler[playerid][rang] = 0 ;
- Spieler[playerid][alvl] = 0 ;
- Spieler[playerid][Kills] = 0;
- Spieler[playerid][Deaths]= 0;
- Spieler[playerid][gamer]= 0;
- SetPlayerMoney(playerid,1000);
- Spieler[playerid][eingeloggt] = 1;
- SendClientMessage(playerid,COLOR_GREEN,"Your account has been registred and you have been automatically logged in");
- }
- }
- }
- else
- {
- switch(dialogid)
- {
- case DIALOG_LOGIN:ShowPlayerDialog(playerid,DIALOG_LOGIN,1,"Login","Hello!\nYor Account has been founded!\nPlease log in!","Cancel","Next");
- case DIALOG_REG:ShowPlayerDialog(playerid,DIALOG_REG,1,"Register","You have not an Account on this Server\nPlease Register!","Cancel","Next");
- }
- }
- // GUI SHOP ====================================================================
- if(dialogid == Waffenmenu)
- {
- if(response)
- {
- if(listitem == 0) // AK47
- {
- if(preise[listitem] >= GetPlayerMoney(playerid))return SendClientMessage(playerid,rot,"You need more money for this Weapon!");// abfrage ob man das geld hat
- GivePlayerWeapon(playerid,30,300);
- GivePlayerMoney(playerid, -400);
- ShowDialog(playerid);
- }
- if(listitem == 1) // Desert Eagle
- {
- if(preise[listitem] >= GetPlayerMoney(playerid))return SendClientMessage(playerid,rot,"You need more money for this Weapon!");
- if(Spieler[playerid][rang] < 2) return SendClientMessage(playerid,rot,"You must have the rank Outlaw or higher for this Weapon!(/rinfo for more Rank infos!)");//rankabfrage
- GivePlayerWeapon(playerid,24,100);
- GivePlayerMoney(playerid, -1000);
- ShowDialog(playerid);
- }
- if(listitem == 2) // M4
- {
- if(preise[listitem] >= GetPlayerMoney(playerid))return SendClientMessage(playerid,rot,"You need more money for this Weapon!");
- if(Spieler[playerid][rang] < 4) return SendClientMessage(playerid,rot,"You must have the rank Associate or higher for this Weapon(/rinfo for more Rank infos!)!");//rankabfrage
- GivePlayerWeapon(playerid,31,300);
- GivePlayerMoney(playerid, -800);
- ShowDialog(playerid);
- }
- if(listitem == 3) // Sniper Rifle
- {
- if(preise[listitem] >= GetPlayerMoney(playerid))return SendClientMessage(playerid,rot,"You need more money for this Weapon!");
- if(Spieler[playerid][rang] < 5) return SendClientMessage(playerid,rot,"You must have the rank Soldier or higher for this Weapon(/rinfo for more Rank infos!)!");//rankabfrage
- GivePlayerWeapon(playerid,34,100);
- GivePlayerMoney(playerid, -1000);
- ShowDialog(playerid);
- }
- if(listitem == 4) // Rifle
- {
- if(preise[listitem] >= GetPlayerMoney(playerid))return SendClientMessage(playerid,rot,"You need more money for this Weapon!");
- if(Spieler[playerid][rang] < 3) return SendClientMessage(playerid,rot,"You must have the rank Newcomer or higher for this Weapon!(/rinfo for more Rank infos!)");//rankabfrage
- GivePlayerWeapon(playerid,33,130);
- GivePlayerMoney(playerid, -600);
- ShowDialog(playerid);
- }
- if(listitem == 5) // Grenade
- {
- if(preise[listitem] >= GetPlayerMoney(playerid))return SendClientMessage(playerid,rot,"You need more money for this Weapon!");
- if(Spieler[playerid][rang] < 5) return SendClientMessage(playerid,rot,"You must have the rank Soldier or higher for this Weapon(/rinfo for more Rank infos!)!");//rankabfrage
- GivePlayerWeapon(playerid,16,5);
- GivePlayerMoney(playerid, -1000);
- ShowDialog(playerid);
- }
- if(listitem == 6) //Molotovs
- {
- if(preise[listitem] >= GetPlayerMoney(playerid))return SendClientMessage(playerid,rot,"You need more money for this Weapon!");
- if(Spieler[playerid][rang] < 2) return SendClientMessage(playerid,rot,"You must have the rank Outlaw or higher for this Weapon(/rinfo for more Rank infos!)!");//rankabfrage
- GivePlayerWeapon(playerid,18,5);
- GivePlayerMoney(playerid, -900);
- ShowDialog(playerid);
- }
- if(listitem == 7)// MP5
- {
- if(preise[listitem] >= GetPlayerMoney(playerid))return SendClientMessage(playerid,rot,"You need more money for this Weapon!");
- GivePlayerWeapon(playerid,29,200);
- GivePlayerMoney(playerid, -400);
- ShowDialog(playerid);
- }
- if(listitem == 8) //RocketLauncher
- {
- if(preise[listitem] >= GetPlayerMoney(playerid))return SendClientMessage(playerid,rot,"You need more money for this Weapon!");
- if(Spieler[playerid][rang] < 7) return SendClientMessage(playerid,rot,"You must have the rank Capo or higher for this Weapon(/rinfo for more Rank infos!)!");//rankabfrage
- GivePlayerWeapon(playerid,35,18);
- GivePlayerMoney(playerid, -10000);
- ShowDialog(playerid);
- }
- if(listitem == 9) //Flamethrower
- {
- if(preise[listitem] >= GetPlayerMoney(playerid))return SendClientMessage(playerid,rot,"You need more money for this Weapon!");
- if(Spieler[playerid][rang] < 6) return SendClientMessage(playerid,rot,"You must have the rank Killer or higher for this Weapon(/rinfo for more Rank infos!)!");//rankabfrage
- GivePlayerWeapon(playerid,37,500);
- GivePlayerMoney(playerid, -9000);
- ShowDialog(playerid);
- }
- if(listitem == 10) //Armour
- {
- if(preise[listitem] >= GetPlayerMoney(playerid))return SendClientMessage(playerid,rot,"You need more money for Armour!!");
- SetPlayerArmour(playerid,100.0);
- GivePlayerMoney(playerid, -500);
- ShowDialog(playerid);
- }
- if(listitem == 11) //Drugs
- {
- if(preise[listitem] >= GetPlayerMoney(playerid))return SendClientMessage(playerid,rot,"You need more money for Drugs!");
- SetPlayerHealth(playerid,100.0);
- GivePlayerMoney(playerid, -250);
- ShowDialog(playerid);
- }
- }
- }
- //Gui Fight---------------------------------------------------------------------
- if(dialogid == Fight)
- {
- if(response)
- {
- if(listitem == 0){SetPlayerFightingStyle (playerid, FIGHT_STYLE_KNEEHEAD);}
- if(listitem == 1){SetPlayerFightingStyle (playerid, FIGHT_STYLE_BOXING);}
- if(listitem == 2){SetPlayerFightingStyle (playerid, FIGHT_STYLE_GRABKICK);}
- if(listitem == 3){SetPlayerFightingStyle (playerid, FIGHT_STYLE_KUNGFU);
- }
- }
- }
- //DM Arenas---------------------------------------------------------------------
- if(dialogid == DIALOG_DM)
- {
- if(response)
- {
- if(listitem == 0){SniperDm(playerid);}
- if(listitem == 1){DeagleDm(playerid);}
- if(listitem == 2){GrenadeDm(playerid);}
- if(listitem == 3){AllinDm(playerid);}
- if(listitem == 4){StreetfightDm(playerid);}
- if(listitem == 5){TacticDm(playerid);}
- }
- }
- return 1;
- }
- public OnPlayerClickPlayer(playerid, clickedplayerid, source)
- {
- return 1;
- }
- //PayDay System-----------------------------------------------------------------
- forward payday();
- public payday()
- {
- for (new i = 0; i < MAX_PLAYERS; i++)
- {
- if(Spieler[i][rang] == 1 ) // BabyKiller
- {
- SendClientMessage(i,hellblau,"|__PAYDAY__|");
- SendClientMessage(i,weiss,"============================");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,grau,"|Your Mafia Rank is |");
- SendClientMessage(i,grau,"| ~ BabyKiller ~ |");
- SendClientMessage(i,grau,"|You get 500$|");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,weiss,"============================");
- SendClientMessage(i,weiss,"(Type /rinfo to get more Informations about our Ranksystem)");
- GivePlayerMoney(i,500);
- }
- if(Spieler[i][rang] == 2 ) // Outlaw
- {
- SendClientMessage(i,hellblau,"|__PAYDAY__|");
- SendClientMessage(i,weiss,"============================");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,grau,"|Your Mafia Rank is |");
- SendClientMessage(i,grau,"| ~ Outlaw ~ |");
- SendClientMessage(i,grau,"|You get 800$|");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,weiss,"============================");
- GivePlayerMoney(i,800);
- }
- if(Spieler[i][rang] == 3 ) //newcomer
- {
- SendClientMessage(i,hellblau,"|__PAYDAY__|");
- SendClientMessage(i,weiss,"============================");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,grau,"|Your Mafia Rank is |");
- SendClientMessage(i,grau,"| ~ Newcomer ~ |");
- SendClientMessage(i,grau,"|You get 1500$|");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,weiss,"============================");
- GivePlayerMoney(i,1500);
- }
- if(Spieler[i][rang] == 4 ) //Associate
- {
- SendClientMessage(i,hellblau,"|__PAYDAY__|");
- SendClientMessage(i,weiss,"============================");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,grau,"|Your Mafia Rank is |");
- SendClientMessage(i,grau,"| ~ Associate ~ |");
- SendClientMessage(i,grau,"|You get 2500$|");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,weiss,"============================");
- GivePlayerMoney(i,2500);
- }
- if(Spieler[i][rang] == 5 ) // Solidier
- {
- SendClientMessage(i,hellblau,"|__PAYDAY__|");
- SendClientMessage(i,weiss,"============================");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,grau,"|Your Mafia Rank is |");
- SendClientMessage(i,grau,"| ~ Soldier ~ |");
- SendClientMessage(i,grau,"|You get 3500$|");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,weiss,"============================");
- GivePlayerMoney(i,3500);
- }
- if(Spieler[i][rang] == 6 ) // Killer
- {
- SendClientMessage(i,hellblau,"|__PAYDAY__|");
- SendClientMessage(i,weiss,"============================");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,grau,"|Your Mafia Rank is |");
- SendClientMessage(i,grau,"| ~ Killer ~ |");
- SendClientMessage(i,grau,"|You get 4500$|");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,weiss,"============================");
- GivePlayerMoney(i,4500);
- }
- if(Spieler[i][rang] == 7 ) // Capo
- {
- SendClientMessage(i,hellblau,"|__PAYDAY__|");
- SendClientMessage(i,weiss,"============================");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,grau,"|Your Mafia Rank is |");
- SendClientMessage(i,grau,"| ~ Capo ~ |");
- SendClientMessage(i,grau,"|You get 5000$|");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,weiss,"============================");
- GivePlayerMoney(i,5000);
- }
- if(Spieler[i][rang] == 8 ) // StreetBoss
- {
- SendClientMessage(i,hellblau,"|__PAYDAY__|");
- SendClientMessage(i,weiss,"============================");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,grau,"|Your Mafia Rank is |");
- SendClientMessage(i,grau,"| ~ StreetBoss ~ |");
- SendClientMessage(i,grau,"|You get 6500$|");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,weiss,"============================");
- GivePlayerMoney(i,6500);
- }
- if(Spieler[i][rang] == 9 ) // UnderBoss
- {
- SendClientMessage(i,hellblau,"|__PAYDAY__|");
- SendClientMessage(i,weiss,"============================");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,grau,"|Your Mafia Rank is |");
- SendClientMessage(i,grau,"| ~ UnderBoss ~ |");
- SendClientMessage(i,grau,"|You get 8000$|");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,weiss,"============================");
- GivePlayerMoney(i,8000);
- }
- if(Spieler[i][rang] == 10 ) // GodFather
- {
- SendClientMessage(i,hellblau,"|__PAYDAY__|");
- SendClientMessage(i,weiss,"============================");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,grau,"|Your Mafia Rank is |");
- SendClientMessage(i,grau,"| ~ GodFather ~ |");
- SendClientMessage(i,grau,"|You get 10000$|");
- SendClientMessage(i,grau,"|----------------------------|");
- SendClientMessage(i,weiss,"============================");
- GivePlayerMoney(i,10000);
- }
- }
- return 1;
- }
- //Auto Message System-----------------------------------------------------------
- forward AutoNaricht();
- public AutoNaricht()
- {
- SendClientMessageToAll(purple, "======================== SERVER INFORMATION ========================");
- SendClientMessageToAll(weiss, "You want to see the mostly all commands? Type /help !");
- SendClientMessageToAll(weiss, "You need Weapons or Heal? Just type /shop in your Base !");
- SendClientMessageToAll(weiss, "Don't make Teamkill this is a TEAM DM Server!");
- SendClientMessageToAll(weiss, "For the Rank infos type /rinfo");
- SendClientMessageToAll(weiss, "You have ideas how to make this server better? ~~> gta-dm.de");
- SendClientMessageToAll(purple, "======================== SERVER INFORMATION ========================");
- return 1;
- }
- //Anti Spawnkill==--------------------------------------------------------------
- forward GiveWeapons(playerid);
- public GiveWeapons(playerid)
- {
- SendClientMessage(playerid,COLOR_WHITE, "*** ANTI SPAWNKILL OFF ***");
- SetPlayerHealth(playerid, 100.0);
- return 1;
- }
- stock SendAdminMessagebyM(color,const message[])
- {
- for(new i = 0; i < GetMaxPlayers(); i++)
- {
- if(IsPlayerConnected(i) && IsPlayerAdmin(i))
- {
- SendClientMessage(i,color,message);
- }
- }
- }
- stock ShowDialog(playerid)
- {
- ShowPlayerDialog(playerid,Waffenmenu,DIALOG_STYLE_LIST,"Weapons","AK47 - 400$ - Rank: BabyKiller\nD.Eagle - 800$ - Rank: Outlaw\nM4 - 800$ - Rank: Associate\nSniper - 1000$ - Rank: Soldier\nRifle - 600$ - Rank: Newcomer\nGrenade - 1000$ - Rank: Soldier\nMolotov - 900$ - Rank: Newcomer\nMP5 - 400$ - Rank: BabyKiller\nRocketLauncher - 10000$ - Rank: Capo\nFlamethrower - 9000$ - Rank: Killer\nArmour - 500$ - Rank: BabyKiller\nDrug - 250$ - Rank: BabyKiller","Select","Back");
- }
- //Anti Weapon Cheat system======================================================
- public Cheattimer()
- {
- for (new i = 0; i < MAX_PLAYERS; i++)
- {
- new name[MAX_PLAYER_NAME],cstring[64];
- GetPlayerName(i,name,sizeof(name));
- if(IsPlayerConnected(i) && GetPlayerState(i) == PLAYER_STATE_ONFOOT)// THATS IMPORTANT WITHOUT THIS we can get BUGS
- {
- if(GetPlayerWeapon(i) == 38 )//Minigun
- {
- format(cstring,sizeof cstring," %s was banned for Minigun cheating",name);
- SendClientMessageToAll(hellrot,cstring);//
- Kick(i);
- }
- if(GetPlayerWeapon(i) == 35 && Spieler[i][rang] < 7)//bazooke
- {
- format(cstring,sizeof cstring," %s was banned for Bazooka cheating",name);
- SendClientMessageToAll(hellrot,cstring);//
- Kick(i);
- }
- if(GetPlayerWeapon(i) == 36 )// Bessere bazooke
- {
- format(cstring,sizeof cstring," %s was banned for Selfaim Bazooka cheating",name);
- SendClientMessageToAll(hellrot,cstring);//
- Kick(i);
- }
- if(GetPlayerWeapon(i) ==37 && Spieler[i][rang] < 6)// flammenwerfer
- {
- format(cstring,sizeof cstring," %s was banned for Flamethrower cheating",name);
- SendClientMessageToAll(hellrot,cstring);//
- Kick(i);
- }
- if(GetPlayerWeapon(i) == 39 )//BOmben by detonator
- {
- format(cstring,sizeof cstring," %s was banned for Bomb+Detonator cheating",name);
- SendClientMessageToAll(hellrot,cstring);//
- Kick(i);
- }
- if(GetPlayerWeapon(i) == 42 )//feurloscher
- {
- format(cstring,sizeof cstring," %s was banned for cheating",name);
- SendClientMessageToAll(hellrot,cstring);//
- Kick(i);
- }
- if(GetPlayerWeapon(i) ==41 )//spary
- {
- format(cstring,sizeof cstring," %s was banned for spray cheating",name);
- SendClientMessageToAll(hellrot,cstring);//
- Kick(i);
- }
- if(GetPlayerWeapon(i) ==43 )//kamera
- {
- format(cstring,sizeof cstring," %s was banned for Camera cheating",name);
- SendClientMessageToAll(hellrot,cstring);//
- Kick(i);
- }
- if(GetPlayerWeapon(i) ==44 )//nightgoogles
- {
- format(cstring,sizeof cstring," %s was banned for nightgoogles cheating",name);
- SendClientMessageToAll(hellrot,cstring);//
- Kick(i);
- }
- if(GetPlayerWeapon(i) ==45 )//warmebrillen
- {
- format(cstring,sizeof cstring," %s was banned for Hotgoogles cheating",name);
- SendClientMessageToAll(hellrot,cstring);//
- Kick(i);
- }
- if(GetPlayerWeapon(i) ==22 )//9mm
- {
- format(cstring,sizeof cstring," %s was banned for 9mm cheating",name);
- SendClientMessageToAll(hellrot,cstring);//
- Kick(i);
- }
- if(GetPlayerWeapon(i) ==26 )//sawnoffshotgun
- {
- format(cstring,sizeof cstring," %s was banned for Sawnoffshotgun cheating",name);
- SendClientMessageToAll(hellrot,cstring);//
- Kick(i);
- }
- if(GetPlayerWeapon(i) ==28 )//uzi
- {
- format(cstring,sizeof cstring," %s was banned for Uzi cheating",name);
- SendClientMessageToAll(hellrot,cstring);//
- Kick(i);
- }
- if(GetPlayerWeapon(i) ==32 )//tec9
- {
- format(cstring,sizeof cstring," %s was banned for Tec9 cheating",name);
- SendClientMessageToAll(hellrot,cstring);//
- Kick(i);
- }
- }
- }
- }
- public rangtimer()
- {
- for (new i = 0; i < MAX_PLAYERS; i++)
- {
- if(Spieler[i][Kills] >= 0 ) // BabyKiller
- {
- Spieler[i][rang] = 1;
- }
- if(Spieler[i][Kills] >= 25 ) // Outlaw
- {
- Spieler[i][rang] = 2;
- }
- if(Spieler[i][Kills] >= 50 ) // newcomer
- {
- Spieler[i][rang] = 3;
- }
- if(Spieler[i][Kills] >= 100 )//associate
- {
- Spieler[i][rang] = 4;
- }
- if(Spieler[i][Kills] >= 150 ) // soldier
- {
- Spieler[i][rang] = 5;
- }
- if(Spieler[i][Kills] >= 250 )//killerer
- {
- Spieler[i][rang] = 6;
- }
- if(Spieler[i][Kills] >= 400 ) // capo
- {
- Spieler[i][rang] = 7;
- }
- if(Spieler[i][Kills] >= 600 ) // streetboss
- {
- Spieler[i][rang] = 8;
- }
- if(Spieler[i][Kills] >= 900 ) // underboss
- {
- Spieler[i][rang] = 9;
- }
- if(Spieler[i][Kills] >= 1500 ) // godfather
- {
- Spieler[i][rang] = 10;
- }
- }
- }
- //------------------------------------------------------------------------------
- stock CheckForSkin(playerid,skin)
- {
- return (GetPlayerSkin(playerid) == skin);
- }
- public robtimer()
- {
- rob = 0;
- }
- public freezetimer(playerid)
- {
- TogglePlayerControllable(playerid,1);
- SendClientMessage(playerid,dunkelgruen,"Sucsessful robbed the Gas Station!");
- SetTimerEx("resetRob",600000,0,"i",playerid);
- new randmoney = 2000 + random (6000);
- GivePlayerMoney(playerid,randmoney);
- SetPlayerHealth(playerid, 80);
- isAtRob[playerid] = 1;
- }
- public resetRob(playerid)isAtRob[playerid] = 0;
- //Bomb System-----------------------------------------------------------
- stock BombExplode(playerid)
- {
- new Float:bX,Float:bY,Float:bZ;
- GetObjectPos(BombenObject[playerid],bX,bY,bZ);
- CreateExplosion(bX+3,bY+3,bZ,10,10.0);
- CreateExplosion(bX+5,bY+5,bZ,10,10.0);
- CreateExplosion(bX+3,bY+3,bZ,10,10.0);
- CreateExplosion(bX+5,bY+5,bZ,10,10.0);
- CreateExplosion(bX+10,bY+10,bZ,10,10.0);
- CreateExplosion(bX+6,bY+6,bZ,10,10.0);
- CreateExplosion(bX+10,bY+10,bZ,10,10.0);
- CreateExplosion(bX+9,bY+9,bZ,10,10.0);
- CreateExplosion(bX+15,bY+15,bZ,10,10.0);
- CreateExplosion(bX+9,bY+9,bZ,10,10.0);
- CreateExplosion(bX+20,bY+20,bZ,10,10.0);
- CreateExplosion(bX+15,bY+15,bZ,10,10.0);
- CreateExplosion(bX+20,bY+20,bZ,10,10.0);
- CreateExplosion(bX+15,bY+15,bZ,10,10.0);
- CreateExplosion(bX+20,bY+20,bZ,10,10.0);
- CreateExplosion(bX,bY,bZ,10,5.0);
- CreateExplosion(bX,bY,bZ,10,5.0);
- CreateExplosion(bX,bY,bZ,10,5.0);
- CreateExplosion(bX,bY,bZ,10,5.0);
- DestroyObject(BombenObject[playerid]);
- return 1;
- }
- //DcMDs CMDS====================================================================
- dcmd_report(playerid,params[])
- {
- new
- sReason[128],
- pID;
- if(sscanf(params,"s",sReason)) {
- return SendClientMessage(playerid,grau,"USAGE: /report [reason]");
- }
- new
- Tplayer[MAX_PLAYER_NAME],
- string[128];
- GetPlayerName(pID,Tplayer,sizeof(Tplayer));
- format(string,sizeof(string),"%s has writen report with the reason : %s",Tplayer,sReason[0] ? sReason : "<No Reason>");
- SendAdminMessage(blau,string);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_kick(playerid,params[])
- {
- new
- Reason[256],
- pID;
- if(Spieler[playerid][alvl] < 1){
- return SendClientMessage(playerid,grau,"You are not a Moderator/Admin!");
- }
- if(sscanf(params,"us",pID,Reason)){
- return SendClientMessage(playerid,grau,"USAGE: /kick [playerid] [reason]");
- }
- if(!IsPlayerConnected(pID)) {
- return SendClientMessage(playerid,grau,"Nobody is connected with this ID!");
- }
- new
- name[MAX_PLAYER_NAME],
- string[256];
- GetPlayerName(pID,name,sizeof(name));
- new
- Aname[MAX_PLAYER_NAME];
- GetPlayerName(playerid,Aname,sizeof(Aname));
- format(string,sizeof(string)," %s has kicked %s, Reason: %s",Aname,name,Reason);
- SendClientMessageToAll(hellrot,string);
- Kick(pID);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_ban(playerid,params[])
- {
- new
- Reason[256],
- pID;
- if(Spieler[playerid][alvl] < 3){
- return SendClientMessage(playerid,grau,"You are not a Admin!");
- }
- if(sscanf(params,"us",pID,Reason)){
- return SendClientMessage(playerid,grau,"USAGE: /ban [playerid] [reason]");
- }
- if(!IsPlayerConnected(pID)) {
- return SendClientMessage(playerid,grau,"Nobody is connected with this ID!");
- }
- new
- name[MAX_PLAYER_NAME],
- string[256];
- GetPlayerName(pID,name,sizeof(name));
- new
- Aname[MAX_PLAYER_NAME];
- GetPlayerName(playerid,Aname,sizeof(Aname));
- format(string,sizeof(string)," %s has banned %s Reason: %s",Aname,name,Reason);
- SendClientMessageToAll(COLOR_GREEN,string);
- Ban(pID);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_seestats(playerid,params[])
- {
- new pID;
- if(sscanf(params,"u",pID)){
- return SendClientMessage(playerid,grau,"USAGE: /seestats [playerid]");
- }
- if(!IsPlayerConnected(pID)) {
- return SendClientMessage(playerid,grau,"Nobody is connected with this ID!");
- }
- new
- name[MAX_PLAYER_NAME],
- string[256],string2[256];
- GetPlayerName(pID,name,sizeof(name));
- format(string, sizeof(string), "| Stats of[%s] |", name);
- format(string2, sizeof(string2), "[Kills: %d] [Deaths: %d] [Ratio: %0.2f] [Score: %d] ", Spieler[pID][Kills], Spieler[pID][Deaths],Float:Spieler[pID][Kills]/Float:Spieler[pID][Deaths],GetPlayerScore(pID));
- SendClientMessage(playerid,COLOR_LIGHTBLUE,string);
- SendClientMessage(playerid,COLOR_WHITE,string2);
- SendClientMessage(playerid,COLOR_LIGHTBLUE,"|_____________________________________________|");
- new
- pname[MAX_PLAYER_NAME],string3[256];
- GetPlayerName(playerid,pname,sizeof(pname));
- format(string3, sizeof(string3), "%s has typed /seestas to see your stats", pname);
- SendClientMessage(pID,COLOR_YELLOW,string3);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_admins(playerid,params[])
- {
- #pragma unused params
- SendClientMessage(playerid, aqua, "Admins/Mods Online:");
- SendClientMessage(playerid, grau, "ServerGuard: JunkBuster");
- new i = 0, aname[256], string[256];
- for(; i < MAX_PLAYERS; i++)
- {
- if(IsPlayerConnected(i))
- {
- if(Spieler[i][alvl] == 1)
- {
- GetPlayerName(i, aname, sizeof(aname));
- format(string, 256, " Moderator: %s", aname);
- SendClientMessage(playerid, grau, string);
- }
- else if(Spieler[i][alvl] == 2)
- {
- GetPlayerName(i, aname, sizeof(aname));
- format(string, 256, " Admin: %s", aname);
- SendClientMessage(playerid, grau, string);
- }
- else if(Spieler[i][alvl] == 3)
- {
- GetPlayerName(i, aname, sizeof(aname));
- format(string, 256, " SuperAdmin: %s", aname);
- SendClientMessage(playerid, grau, string);
- }
- else if(Spieler[i][alvl] == 4)
- {
- GetPlayerName(i, aname, sizeof(aname));
- format(string, 256, " ServerOwner: %s", aname);
- SendClientMessage(playerid, grau, string);
- }
- }
- }
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_a(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 1) {
- return SendClientMessage(playerid,grau,"You must be a Mod/Admin to be able to write in admin chat");
- }
- new atext[128];
- if(sscanf(params,"s",atext)){
- return SendClientMessage(playerid,grau,"USAGE: /a [text]");
- }
- new name[MAX_PLAYER_NAME];
- new string[128];
- GetPlayerName(playerid,name,sizeof(name));
- format(string,sizeof(string),"Level %d Admin (%s): %s" ,Spieler[playerid][alvl],name,atext);
- SendAdminMessage(COLOR_YELLOW,string);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_dec(playerid,params[])
- {
- new dtext[128];
- if(Spieler[playerid][alvl] <1) {
- return SendClientMessage (playerid,grau,"You must be a Mod/Admin to write a declaration");
- }
- if(sscanf(params,"s",dtext)){
- return SendClientMessage(playerid,grau,"USAGE: /dec [text]");
- }
- GameTextForAll(dtext,3*1000,3);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_makeadmin(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 4){
- return SendClientMessage (playerid,grau,"You must be a ServerOwner to set admin Levels");
- }
- new pID,alevel;
- if(sscanf(params,"ud",pID,alevel)){
- return SendClientMessage (playerid,grau,"USAGE: /makeadmin [playerid] [adminlevel]");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage (playerid,grau,"Nobody is connected with this ID!");
- }
- new string[128],string2[128],aname[MAX_PLAYER_NAME],name[MAX_PLAYER_NAME];
- Spieler[pID][alvl] = alevel;
- GetPlayerName(playerid,aname,sizeof(aname));
- GetPlayerName(pID,name,sizeof(name));
- format(string,sizeof(string),"You have set the admin level of %s to %d",name,alevel);
- format(string2,sizeof(string2),"ServerOwner %s has set your admin level to %d",aname,alevel);
- SendClientMessage(playerid,COLOR_GREEN,string);
- SendClientMessage(pID,COLOR_GREEN,string2);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_freeze(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 1){
- return SendClientMessage (playerid,grau,"You must be a Mod/Admin to freeze Players");
- }
- new pID;
- if(sscanf(params,"u",pID)){
- return SendClientMessage(playerid,grau,"USAGE: /freeze [playerid]");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage(playerid,COLOR_RED,"Nobody is connected with this ID!");
- }
- new string[128],string2[128],adminname[MAX_PLAYER_NAME],name[MAX_PLAYER_NAME];
- GetPlayerName(playerid,adminname,sizeof(adminname));
- GetPlayerName(pID,name,sizeof(name));
- format(string,sizeof(string),"You have frozen %s",name);
- format(string2,sizeof(string2),"You was been frozen by %s",adminname);
- SendClientMessage(playerid,hellrot,string);
- SendClientMessage(pID,hellrot,string2);
- TogglePlayerControllable(pID, 0);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_unfreeze(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 1){
- return SendClientMessage (playerid,grau,"You must be a Mod/Admin to freeze Players");
- }
- new pID;
- if(sscanf(params,"u",pID)){
- return SendClientMessage(playerid,grau,"USAGE: /freeze [playerid]");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage(playerid,grau,"Nobody is connected with this ID!");
- }
- new string[128],string2[128],adminname[MAX_PLAYER_NAME],name[MAX_PLAYER_NAME];
- GetPlayerName(playerid,adminname,sizeof(adminname));
- GetPlayerName(pID,name,sizeof(name));
- format(string,sizeof(string),"You have unfrozen %s",name);
- format(string2,sizeof(string2),"You was been unfrozen by %s",adminname);
- SendClientMessage(playerid,COLOR_GREEN,string);
- SendClientMessage(pID,COLOR_GREEN,string2);
- TogglePlayerControllable(pID, 1);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_setkills(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 3){
- return SendClientMessage (playerid,grau,"You must be a SuperAdmin or ServerOwner to set Kills");
- }
- new pID,kills;
- if(sscanf(params,"ud",pID,kills)){
- return SendClientMessage(playerid,grau,"USAGE: /setkills [playerid] [kills]");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage(playerid,grau,"Nobody is connected with this ID!");
- }
- new string[128],string2[128],aname[MAX_PLAYER_NAME],name[MAX_PLAYER_NAME];
- Spieler[pID][Kills] = kills;
- GetPlayerName(playerid,aname,sizeof(aname));
- GetPlayerName(pID,name,sizeof(name));
- format(string,sizeof(string),"You have set the kills of %s to %d",name,kills);
- format(string2,sizeof(string2),"Admin %s has set your kills to %d",aname,kills);
- SendClientMessage(playerid,COLOR_GREEN,string);
- SendClientMessage(pID,COLOR_GREEN,string2);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_setdeaths(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 3){
- return SendClientMessage (playerid,grau,"You must be a SuperAdmin or ServerOwner to set Deaths");
- }
- new pID,deaths;
- if(sscanf(params,"ud",pID,deaths)){
- return SendClientMessage(playerid,grau,"USAGE: /setkills [playerid] [kills]");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage(playerid,COLOR_RED,"Nobody is connected with this ID!");
- }
- new string[128],string2[128],aname[MAX_PLAYER_NAME],name[MAX_PLAYER_NAME];
- Spieler[pID][Deaths] = deaths;
- GetPlayerName(playerid,aname,sizeof(aname));
- GetPlayerName(pID,name,sizeof(name));
- format(string,sizeof(string),"You have set the Deaths of %s to %d",name,deaths);
- format(string2,sizeof(string2),"Admin %s has set your Deaths to %d",aname,deaths);
- SendClientMessage(playerid,COLOR_GREEN,string);
- SendClientMessage(pID,COLOR_GREEN,string2);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_setscore(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 3){
- return SendClientMessage (playerid,grau,"You must be a SuperAdmin or ServerOwner to set Scores");
- }
- new pID,scores;
- if(sscanf(params,"ud",pID,scores)){
- return SendClientMessage(playerid,grau,"USAGE: /setscore [playerid] [score]");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage(playerid,grau,"Nobody is connected with this ID!");
- }
- new string[128],string2[128],aname[MAX_PLAYER_NAME],name[MAX_PLAYER_NAME];
- SetPlayerScore(pID,scores);
- GetPlayerName(playerid,aname,sizeof(aname));
- GetPlayerName(pID,name,sizeof(name));
- format(string,sizeof(string),"You have set the Score of %s to %d",name,scores);
- format(string2,sizeof(string2),"Admin %s has set your Score to %d",aname,scores);
- SendClientMessage(playerid,COLOR_GREEN,string);
- SendClientMessage(pID,COLOR_GREEN,string2);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_givecash(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 3){
- return SendClientMessage (playerid,grau,"You must be a SuperAdmin or a ServerOwner to give money");
- }
- new pID,cash;
- if(sscanf(params,"ud",pID,cash)){
- return SendClientMessage(playerid,grau,"USAGE: /givecash [playerid] [amount]");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage(playerid,grau,"Nobody is connected with this ID!");
- }
- new string[128],string2[128],aname[MAX_PLAYER_NAME],name[MAX_PLAYER_NAME];
- GivePlayerMoney(pID,cash);
- GetPlayerName(playerid,aname,sizeof(aname));
- GetPlayerName(pID,name,sizeof(name));
- format(string,sizeof(string),"You have given %s %d $",name,cash);
- format(string2,sizeof(string2),"Admin %s has given you %d $",aname,cash);
- SendClientMessage(playerid,COLOR_GREEN,string);
- SendClientMessage(pID,COLOR_GREEN,string2);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_giveweapon(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 2){
- return SendClientMessage (playerid,grau,"You must be a Admin or higher to give weapons");
- }
- new pID,weapon,ammo;
- if(sscanf(params,"udd",pID,weapon,ammo)){
- return SendClientMessage(playerid,grau,"USAGE: /giveweapon [playerid][weaponID] [ammo]");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage(playerid,grau,"Nobody is connected with this ID!");
- }
- new string[128],string2[128],aname[MAX_PLAYER_NAME],name[MAX_PLAYER_NAME];
- GivePlayerWeapon(pID,weapon,ammo);
- GetPlayerName(playerid,aname,sizeof(aname));
- GetPlayerName(pID,name,sizeof(name));
- format(string,sizeof(string),"You have given the player %s weapon ID:%d with %d ammo",name,weapon,ammo);
- format(string2,sizeof(string2),"Admin %s has give you weapon ID:%d with %d ammo",aname,weapon,ammo);
- SendClientMessage(playerid,COLOR_GREEN,string);
- SendClientMessage(pID,COLOR_GREEN,string2);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_explode(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 1){
- return SendClientMessage (playerid,COLOR_RED,"You must be a Moderator or higher to explode players");
- }
- new pID;
- if(sscanf(params,"u",pID)){
- return SendClientMessage (playerid,COLOR_RED,"USAGE: /explode [playerid]");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage (playerid,COLOR_RED,"Nobody is connected with this ID!");
- }
- new string[128],string2[128],aname[MAX_PLAYER_NAME],name[MAX_PLAYER_NAME];
- GetPlayerName(playerid,aname,sizeof(aname));
- GetPlayerName(pID,name,sizeof(name));
- format(string,sizeof(string),"You have explode %s ",name);
- format(string2,sizeof(string2),"Admin %s has explode you",aname);
- new Float:x,Float:y,Float:z;
- GetPlayerPos(pID,x,y,z);
- CreateExplosion(x,y,z,7,15);
- CreateExplosion(x,y,z,7,15);
- CreateExplosion(x,y,z,7,15);
- CreateExplosion(x,y,z,7,15);
- CreateExplosion(x,y,z,7,15);
- SendClientMessage(playerid,COLOR_GREEN,string);
- SendClientMessage(pID,COLOR_GREEN,string2);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_spectate(playerid,params[]) {
- if(Spieler[playerid][alvl] < 1){
- return SendClientMessage (playerid,grau,"You must be a Moderator or higher to spectate players");
- }
- new pID;
- if(sscanf(params,"u",pID)){
- return SendClientMessage (playerid,grau,"USAGE: /spectate [playerid]");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage (playerid,grau,"Nobody is connected with this ID!");
- }
- new string[128],name[MAX_PLAYER_NAME];
- GetPlayerName(pID,name,sizeof(name));
- format(string,sizeof(string),"You are spectating %s",name);
- SetCameraBehindPlayer(pID);
- SendClientMessage(playerid,COLOR_GREEN,string);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_tele(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 2){
- return SendClientMessage (playerid,grau,"You must be a Admin or higher to teleport to players");
- }
- new pID;
- if(sscanf(params,"u",pID)){
- return SendClientMessage (playerid,grau,"USAGE: /tele [playerid]");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage (playerid,grau,"Nobody is connected with this ID!");
- }
- new string[128],name[MAX_PLAYER_NAME];
- GetPlayerName(pID,name,sizeof(name));
- format(string,sizeof(string),"You have been teleported to %s",name);
- new Float:x,Float:y,Float:z;
- GetPlayerPos(pID,x,y,z);
- SetPlayerPos(playerid,x,y,z);
- SendClientMessage(playerid,COLOR_GREEN,string);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_gethere(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 2){
- return SendClientMessage (playerid,grau,"You must be a Admin to teleport players ");
- }
- new pID;
- if(sscanf(params,"u",pID)){
- return SendClientMessage (playerid,grau,"USAGE: /gethere [playerid]");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage (playerid,grau,"Nobody is connected with this ID!");
- }
- new string[128],string2[128],aname[MAX_PLAYER_NAME],name[MAX_PLAYER_NAME];
- GetPlayerName(pID,name,sizeof(name));
- GetPlayerName(playerid,aname,sizeof(aname));
- format(string,sizeof(string),"You have been teleported to %s",aname);
- format(string2,sizeof(string2),"You have been teleported to %s",name);
- new Float:x,Float:y,Float:z;
- GetPlayerPos(playerid,x,y,z);
- SetPlayerPos(pID,x,y,z);
- SendClientMessage(pID,COLOR_GREEN,string);
- SendClientMessage(playerid,COLOR_GREEN,string2);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_pm(playerid,params[])
- {
- new
- pmtext[128],
- pID;
- if(sscanf(params,"ds",pID,pmtext)) {
- return SendClientMessage(playerid,grau,"USAGE: /pm [playerid] [text]");
- }
- if(!IsPlayerConnected(pID)) {
- return SendClientMessage(playerid,grau,"Nobody is connected with this ID");
- }
- new
- name[MAX_PLAYER_NAME],pmname[MAX_PLAYER_NAME],
- string[128],string2[128];
- GetPlayerName(playerid,name,sizeof(name));
- GetPlayerName(pID,pmname,sizeof(pmname));
- format(string,sizeof(string),"PM from %s : %s ",name,pmtext);
- format(string2,sizeof(string2),"You have sent the PM to %s ",pmname);
- SendClientMessage(pID,COLOR_YELLOW,string);
- SendClientMessage(playerid,COLOR_YELLOW,string2);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_setskin(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 2){
- return SendClientMessage (playerid,grau,"You must be a Admin or higher to set Skins");
- }
- new pID,skinid;
- if(sscanf(params,"ud",pID,skinid)){
- return SendClientMessage(playerid,grau,"USAGE: /setskin [playerid] [skinID(0-299!)]*");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage(playerid,grau,"Nobody is connected with this ID!");
- }
- if(skinid < 0){
- return SendClientMessage(playerid,grau,"INVALID ID!");
- }
- if(skinid > 299){
- return SendClientMessage(playerid,grau,"INVALID ID!");
- }
- new string[128],string2[128],aname[MAX_PLAYER_NAME],name[MAX_PLAYER_NAME];
- SetPlayerSkin(pID,skinid);
- GetPlayerName(playerid,aname,sizeof(aname));
- GetPlayerName(pID,name,sizeof(name));
- format(string,sizeof(string),"You have set the SkinID of %s to %d",name,skinid);
- format(string2,sizeof(string2),"Admin %s has set your SkinID to %d",aname,skinid);
- SendClientMessage(playerid,COLOR_GREEN,string);
- SendClientMessage(pID,COLOR_GREEN,string2);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_heal(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 2){
- return SendClientMessage (playerid,grau,"You must be a Admin or higher to set Health");
- }
- new pID,life;
- if(sscanf(params,"ud",pID,life)){
- return SendClientMessage(playerid,grau,"USAGE: /heal [playerid] [float(0-100!)]*");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage(playerid,grau,"Nobody is connected with this ID!");
- }
- if(life < 0){
- return SendClientMessage(playerid,grau,"INVALID FLOAT!");
- }
- if(life > 100){
- return SendClientMessage(playerid,grau,"INVALID FLOAT!");
- }
- new string[128],string2[128],aname[MAX_PLAYER_NAME],name[MAX_PLAYER_NAME];
- SetPlayerHealth(pID,life);
- GetPlayerName(playerid,aname,sizeof(aname));
- GetPlayerName(pID,name,sizeof(name));
- format(string,sizeof(string),"You have set the Health of %s to %d",name,life);
- format(string2,sizeof(string2),"Admin %s has set your Health to %d",aname,life);
- SendClientMessage(playerid,COLOR_GREEN,string);
- SendClientMessage(pID,COLOR_GREEN,string2);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_takeweaps(playerid,params[])
- {
- new
- Reason[256],
- pID;
- if(Spieler[playerid][alvl] < 1){
- return SendClientMessage(playerid,grau,"You must be a Moderator or higher to take weapons away");
- }
- if(sscanf(params,"us",pID,Reason)){
- return SendClientMessage(playerid,grau,"USAGE: /takeweaps [playerid] [reason]");
- }
- if(!IsPlayerConnected(pID)) {
- return SendClientMessage(playerid,grau,"Nobody is connected with this ID!");
- }
- new
- name[MAX_PLAYER_NAME],
- string[256];
- GetPlayerName(pID,name,sizeof(name));
- new
- Aname[MAX_PLAYER_NAME],string2[256];
- GetPlayerName(playerid,Aname,sizeof(Aname));
- format(string,sizeof(string),"Admin %s has taken your weapons with the reason: %s",Aname,Reason);
- format(string2,sizeof(string2),"You have taken the weapons of %s with the reason: %s",name,Reason);
- SendClientMessage(pID,COLOR_GREEN,string);
- ResetPlayerWeapons(pID);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_setweather(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 2){
- return SendClientMessage (playerid,grau,"You must be a Admin or higher to change Weather");
- }
- new wetter;
- if(sscanf(params,"d",wetter)){
- return SendClientMessage(playerid,grau,"USAGE: /setweather [WeatherID]");
- }
- new string2[128],aname[MAX_PLAYER_NAME];
- SetWeather(wetter);
- GetPlayerName(playerid,aname,sizeof(aname));
- format(string2,sizeof(string2),"Admin %s has set the weather ID to %d",aname,wetter);
- SendClientMessageToAll(COLOR_GREEN,string2);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_sethour(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 2){
- return SendClientMessage (playerid,grau,"You must be a Admin or higher to change time");
- }
- new hours;
- if(sscanf(params,"d",hours)){
- return SendClientMessage(playerid,grau,"USAGE: /sethour [hour]");
- }
- if(hours < 0){
- return SendClientMessage(playerid,grau,"INVALID HOUR![0-24]");
- }
- if(hours > 24){
- return SendClientMessage(playerid,grau,"INVALID HOUR![0-24]");
- }
- new string2[128],aname[MAX_PLAYER_NAME];
- SetWorldTime(hour);
- GetPlayerName(playerid,aname,sizeof(aname));
- format(string2,sizeof(string2),"Admin %s has set the time to %d",aname,hours);
- SendClientMessageToAll(COLOR_GREEN,string2);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_veh(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 3){
- return SendClientMessage (playerid,grau,"You must be a SuperAdmin or higher to spawn cars");
- }
- new veh,color1,color2;
- if(sscanf(params,"ddd",veh,color1,color2)){
- return SendClientMessage(playerid,grau,"USAGE: /veh [vehicleID] [color1] [color2]");
- }
- if(veh < 400){
- return SendClientMessage(playerid,grau,"INVALID vehID![400-611]");
- }
- if(veh > 611){
- return SendClientMessage(playerid,grau,"INVALID vehID![400-611]");
- }
- if(color1 < 0){
- return SendClientMessage(playerid,grau,"INVALID color1ID![0-126]");
- }
- if(color1 > 126){
- return SendClientMessage(playerid,grau,"INVALID color1ID![0-126]");
- }
- if(color2 < 0){
- return SendClientMessage(playerid,grau,"INVALID color2ID![0-126]");
- }
- if(color2 > 126){
- return SendClientMessage(playerid,grau,"INVALID color2ID![0-126]");
- }
- new Float:x , Float:y , Float: z;
- GetPlayerPos(playerid,x,y,z);
- CreateVehicle(veh, x, y, z, 0, color1, color2, 123456789);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_seecash(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 1){
- return SendClientMessage(playerid,grau,"You must be a Moderator or higher for this CMD");
- }
- new pID;
- if(sscanf(params,"u",pID)){
- return SendClientMessage(playerid,grau,"USAGE: /seecash [playerid]");
- }
- if(!IsPlayerConnected(pID)) {
- return SendClientMessage(playerid,grau,"Nobody is connected with this ID!");
- }
- new
- name[MAX_PLAYER_NAME],
- string2[256];
- GetPlayerName(pID,name,sizeof(name));
- format(string2, sizeof(string2), "[Cash of %s] : %d $",name,GetPlayerMoney(pID));
- SendClientMessage(playerid,COLOR_GREEN,string2);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_armour(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 2){
- return SendClientMessage (playerid,grau,"You must be a Admin or higher to set Armour");
- }
- new pID,arm;
- if(sscanf(params,"ud",pID,arm)){
- return SendClientMessage(playerid,grau,"USAGE: /armour [playerid] [float(0-100!)]*");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage(playerid,grau,"Nobody is connected with this ID!");
- }
- if(arm < 0){
- return SendClientMessage(playerid,grau,"INVALID FLOAT!");
- }
- if(arm > 100){
- return SendClientMessage(playerid,grau,"INVALID FLOAT!");
- }
- new string[128],string2[128],aname[MAX_PLAYER_NAME],name[MAX_PLAYER_NAME];
- SetPlayerArmour(pID,arm);
- GetPlayerName(playerid,aname,sizeof(aname));
- GetPlayerName(pID,name,sizeof(name));
- format(string,sizeof(string),"You have set the Armour of %s to %d",name,arm);
- format(string2,sizeof(string2),"Admin %s has set your Armour to %d",aname,arm);
- SendClientMessage(playerid,COLOR_GREEN,string);
- SendClientMessage(pID,COLOR_GREEN,string2);
- return 1;
- }
- //------------------------------------------------------------------------------
- dcmd_setcash(playerid,params[])
- {
- if(Spieler[playerid][alvl] < 3){
- return SendClientMessage (playerid,grau,"You must be a SuperAdmin or a ServerOwner to set money");
- }
- new pID,cash;
- if(sscanf(params,"ud",pID,cash)){
- return SendClientMessage(playerid,grau,"USAGE: /setcash [playerid] [amount]");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage(playerid,grau,"Nobody is connected with this ID!");
- }
- new string[128],string2[128],aname[MAX_PLAYER_NAME],name[MAX_PLAYER_NAME];
- SetPlayerMoney(pID,cash);
- GetPlayerName(playerid,aname,sizeof(aname));
- GetPlayerName(pID,name,sizeof(name));
- format(string,sizeof(string),"You have set the money of %s to %d $",name,cash);
- format(string2,sizeof(string2),"Admin %s has set your money to %d $",aname,cash);
- SendClientMessage(playerid,COLOR_GREEN,string);
- SendClientMessage(pID,COLOR_GREEN,string2);
- return 1;
- }
- //==============================================================================
- stock SendAdminMessage(farbe,msg[])
- {
- for(new i = 0; i < MAX_PLAYERS; i++)
- {
- if(Spieler[i][alvl] >= 1)
- {
- SendClientMessage(i,farbe,msg);
- }
- }
- }
- //==================================================SSCANF CODE ================
- stock sscanf(string[], format[], {Float,_}:...)
- {
- #if defined isnull
- if (isnull(string))
- #else
- if (string[0] == 0 || (string[0] == 1 && string[1] == 0))
- #endif
- {
- return format[0];
- }
- #pragma tabsize 4
- new
- formatPos = 0,
- stringPos = 0,
- paramPos = 2,
- paramCount = numargs(),
- delim = ' ';
- while (string[stringPos] && string[stringPos] <= ' ')
- {
- stringPos++;
- }
- while (paramPos < paramCount && string[stringPos])
- {
- switch (format[formatPos++])
- {
- case '\0':
- {
- return 0;
- }
- case 'i', 'd':
- {
- new
- neg = 1,
- num = 0,
- ch = string[stringPos];
- if (ch == '-')
- {
- neg = -1;
- ch = string[++stringPos];
- }
- do
- {
- stringPos++;
- if ('0' <= ch <= '9')
- {
- num = (num * 10) + (ch - '0');
- }
- else
- {
- return -1;
- }
- }
- while ((ch = string[stringPos]) > ' ' && ch != delim);
- setarg(paramPos, 0, num * neg);
- }
- case 'h', 'x':
- {
- new
- num = 0,
- ch = string[stringPos];
- do
- {
- stringPos++;
- switch (ch)
- {
- case 'x', 'X':
- {
- num = 0;
- continue;
- }
- case '0' .. '9':
- {
- num = (num << 4) | (ch - '0');
- }
- case 'a' .. 'f':
- {
- num = (num << 4) | (ch - ('a' - 10));
- }
- case 'A' .. 'F':
- {
- num = (num << 4) | (ch - ('A' - 10));
- }
- default:
- {
- return -1;
- }
- }
- }
- while ((ch = string[stringPos]) > ' ' && ch != delim);
- setarg(paramPos, 0, num);
- }
- case 'c':
- {
- setarg(paramPos, 0, string[stringPos++]);
- }
- case 'f':
- {
- new changestr[16], changepos = 0, strpos = stringPos;
- while(changepos < 16 && string[strpos] && string[strpos] != delim)
- {
- changestr[changepos++] = string[strpos++];
- }
- changestr[changepos] = '\0';
- setarg(paramPos,0,_:floatstr(changestr));
- }
- case 'p':
- {
- delim = format[formatPos++];
- continue;
- }
- case '\'':
- {
- new
- end = formatPos - 1,
- ch;
- while ((ch = format[++end]) && ch != '\'') {}
- if (!ch)
- {
- return -1;
- }
- format[end] = '\0';
- if ((ch = strfind(string, format[formatPos], false, stringPos)) == -1)
- {
- if (format[end + 1])
- {
- return -1;
- }
- return 0;
- }
- format[end] = '\'';
- stringPos = ch + (end - formatPos);
- formatPos = end + 1;
- }
- case 'u':
- {
- new
- end = stringPos - 1,
- id = 0,
- bool:num = true,
- ch;
- while ((ch = string[++end]) && ch != delim)
- {
- if (num)
- {
- if ('0' <= ch <= '9')
- {
- id = (id * 10) + (ch - '0');
- }
- else
- {
- num = false;
- }
- }
- }
- if (num && IsPlayerConnected(id))
- {
- setarg(paramPos, 0, id);
- }
- else
- {
- #if !defined foreach
- #define foreach(%1,%2) for (new %2 = 0; %2 < MAX_PLAYERS; %2++) if (IsPlayerConnected(%2))
- #define __SSCANF_FOREACH__
- #endif
- string[end] = '\0';
- num = false;
- new
- name[MAX_PLAYER_NAME];
- id = end - stringPos;
- foreach (Player, playerid)
- {
- GetPlayerName(playerid, name, sizeof (name));
- if (!strcmp(name, string[stringPos], true, id))
- {
- setarg(paramPos, 0, playerid);
- num = true;
- break;
- }
- }
- if (!num)
- {
- setarg(paramPos, 0, INVALID_PLAYER_ID);
- }
- string[end] = ch;
- #if defined __SSCANF_FOREACH__
- #undef foreach
- #undef __SSCANF_FOREACH__
- #endif
- }
- stringPos = end;
- }
- case 's', 'z':
- {
- new
- i = 0,
- ch;
- if (format[formatPos])
- {
- while ((ch = string[stringPos++]) && ch != delim)
- {
- setarg(paramPos, i++, ch);
- }
- if (!i)
- {
- return -1;
- }
- }
- else
- {
- while ((ch = string[stringPos++]))
- {
- setarg(paramPos, i++, ch);
- }
- }
- stringPos--;
- setarg(paramPos, i, '\0');
- }
- default:
- {
- continue;
- }
- }
- while (string[stringPos] && string[stringPos] != delim && string[stringPos] > ' ')
- {
- stringPos++;
- }
- while (string[stringPos] && (string[stringPos] == delim || string[stringPos] <= ' '))
- {
- stringPos++;
- }
- paramPos++;
- }
- do
- {
- if ((delim = format[formatPos++]) > ' ')
- {
- if (delim == '\'')
- {
- while ((delim = format[formatPos++]) && delim != '\'') {}
- }
- else if (delim != 'z')
- {
- return delim;
- }
- }
- }
- while (delim > ' ');
- return 0;
- }
- //================================================= SCANF CODE END =============
- public IsPlayerAdminCall(playerid)
- {
- if(Spieler[playerid][alvl] == 4)
- return 1;
- else
- return 0;
- }
- //CARS==========================================================================
- public IsItLcnCar(carid)
- {
- for(new i = 0; i < sizeof(LcnCar); i++)
- {
- if(carid == LcnCar[i])
- {
- return 1;
- }
- }
- return 0;
- }
- public IsItRusCar(carid)
- {
- for(new i = 0; i < sizeof(RusCar); i++)
- {
- if(carid == RusCar[i])
- {
- return 1;
- }
- }
- return 0;
- }
- public IsItTriadCar(carid)
- {
- for(new i = 0; i < sizeof(TriadCar); i++)
- {
- if(carid == TriadCar[i])
- {
- return 1;
- }
- }
- return 0;
- }
- public IsItYugoCar(carid)
- {
- for(new i = 0; i < sizeof(YugoCar); i++)
- {
- if(carid == YugoCar[i])
- {
- return 1;
- }
- }
- return 0;
- }
- public IsItGermanCar(carid)
- {
- for(new i = 0; i < sizeof(GermanCar); i++)
- {
- if(carid == GermanCar[i])
- {
- return 1;
- }
- }
- return 0;
- }
- public IsItCubanCar(carid)
- {
- for(new i = 0; i < sizeof(CubanCar); i++)
- {
- if(carid == CubanCar[i])
- {
- return 1;
- }
- }
- return 0;
- }
- public IsItGamerCar(carid)
- {
- for(new i = 0; i < sizeof(GamerCar); i++)
- {
- if(carid == GamerCar[i])
- {
- return 1;
- }
- }
- return 0;
- }
- //------------------------------------------------------------------------------
- public zonecheck()
- {
- for (new i = 0; i < MAX_PLAYERS; i++)
- {
- if(IsPlayerInRangeOfPoint(i,10.0,-2141.9912109375, 579.66644287109, 37.143802642822) && Gang[i] == TEAM_TRIADS)
- {
- SetTimer("TriadTimer",2000,0);
- }
- else if (IsPlayerInRangeOfPoint(i,10.0,-2655.1687011719, -220.49809265137, 5.9577760696411) && Gang[i] == TEAM_LCN)
- {
- SetTimer("LcnTimer",2000,0);
- }
- else if (IsPlayerInRangeOfPoint(i,10.0,-2127.2192382813, -80.924629211426, 36.953063964844) && Gang[i] == TEAM_RUS)
- {
- SetTimer("RusTimer",2000,0);
- }
- else if (IsPlayerInRangeOfPoint(i,10.0, -2607.9880371094, 1361.5688476563, 8.831916809082) && Gang[i] == TEAM_YUGO)
- {
- SetTimer("YugoTimer",2000,0);
- }
- else if (IsPlayerInRangeOfPoint(i,10.0, -2432.9150390625, 497.01708984375, 31.701232910156) && Gang[i] == TEAM_GERMAN)
- {
- SetTimer("GermanTimer",2000,0);
- }
- else if (IsPlayerInRangeOfPoint(i,10.0, -1851.3482666016, -226.4906463623, 19.694917678833) && Gang[i] == TEAM_CUBAN)
- {
- SetTimer("CubanTimer",2000,0);
- }
- }
- }
- //Triad-------------------------------------------------------------------------
- forward TriadTimer();
- public TriadTimer()
- {
- MoveObject(Triadgate,-2241.9912109375,579.66644287109,37.143802642822,3.5);
- SetTimer("TriadTimer2",5000,false);
- }
- forward TriadTimer2();
- public TriadTimer2(){MoveObject(Triadgate,-2141.9912109375,579.66644287109,37.143802642822,3.5);}
- //LCN---------------------------------------------------------------------------
- forward LcnTimer();
- public LcnTimer()
- {
- MoveObject(Lcngate,-2655.1687011719, -220.49809265137, -2.9577760696411,3.5);
- SetTimer("LcnTimer2",5000,false);
- }
- forward LcnTimer2();
- public LcnTimer2(){MoveObject(Lcngate,-2655.1687011719, -220.49809265137, 5.9577760696411,3.5);}
- //RUS---------------------------------------------------------------------------
- forward RusTimer();
- public RusTimer()
- {
- MoveObject(Rusgate,-2117.2192382813, -80.924629211426, 36.953063964844,3.5);
- SetTimer("RusTimer2",5000,false);
- }
- forward RusTimer2();
- public RusTimer2(){MoveObject(Rusgate,-2127.2192382813, -80.924629211426, 36.953063964844,3.5);}
- //Yugo--------------------------------------------------------------------------
- forward YugoTimer();
- public YugoTimer()
- {
- MoveObject(Yugogate,-2607.9880371094, 1361.5688476563, 1.831916809082,3.5);
- SetTimer("YugoTimer2",5000,false);
- }
- forward YugoTimer2();
- public YugoTimer2(){MoveObject(Yugogate,-2607.9880371094, 1361.5688476563, 8.831916809082,3.5);}
- //German------------------------------------------------------------------------
- forward GermanTimer();
- public GermanTimer()
- {
- MoveObject(Germangate,-2432.9150390625, 497.01708984375, 23.701232910156,3.5);
- SetTimer("GermanTimer2",5000,false);
- }
- forward GermanTimer2();
- public GermanTimer2(){MoveObject(Germangate,-2432.9150390625, 497.01708984375, 31.701232910156,3.5);}
- //Cuban-------------------------------------------------------------------------
- forward CubanTimer();
- public CubanTimer()
- {
- MoveObject(Cubangate,-1851.3482666016, -226.4906463623, 10.694917678833,3.5);
- SetTimer("CubanTimer2",5000,false);
- }
- forward CubanTimer2();
- public CubanTimer2(){MoveObject(Cubangate,-1851.3482666016, -226.4906463623, 19.694917678833,3.5);}
- forward GamerTimer();
- public GamerTimer(){MoveObject(Gamergate,-2273.7644042969, 2352.1525878906, 6.5936045646667,3.5);}
- //NotTImeDuel===================================================================
- public CountDown(playerid, seconds)
- {
- new string[256];
- if(seconds > 0)
- {
- new Float:X, Float:Y, Float:Z;
- GetPlayerPos(playerid, X, Y, Z);
- PlayerPlaySound(playerid, 1056, X, Y, Z);
- format(string, sizeof(string), "~R~%d", seconds);
- GameTextForPlayer(playerid, string, 1000, 3);
- seconds = seconds -1;
- SetTimerEx("CountDown", 1000, 0, "ii", playerid, seconds);
- return 1;
- }
- if(seconds == 0)
- {
- new Float:X, Float:Y, Float:Z;
- GetPlayerPos(playerid, X, Y, Z);
- PlayerPlaySound(playerid, 1057, X, Y, Z);
- GameTextForPlayer(playerid, "~G~Start!!!", 1000, 3);
- TogglePlayerControllable(playerid, 1);
- return 1;
- }
- return 1;
- }
- public inventationremove(playerid)
- {
- if(Induel[playerid] == 0)
- {
- SendClientMessage(playerid, RED, "30 seconds passed after your duel inventation without a response");
- SendClientMessage(InventationSent[playerid], RED, "30 seconds passed after your duel inventation without a response");
- Inventation[InventationSent[playerid]] = -1;
- InventationSent[playerid] = -1;
- if(duelRoom1 == playerid)
- {
- duelRoom1 = -1;
- }
- if(duelRoom2 == playerid)
- {
- duelRoom2 = -1;
- }
- if(duelRoom3 == playerid)
- {
- duelRoom3 = -1;
- }
- if(duelRoom3 == playerid)
- {
- duelRoom4 = -1;
- }
- return 1;
- }
- return 1;
- }
- //noTimeDcmdDuel----------------------------------------------------------------
- dcmd_watchduels(playerid, params[])
- {
- #pragma unused params
- if(PlayerduelWatching[playerid] == 0)
- {
- SetPlayerPos(playerid, 1731.8315,-2864.7705,6.5554);
- SetPlayerFacingAngle(playerid, 1.8901);
- ResetPlayerWeapons(playerid);
- SetPlayerHealth(playerid, 1000000000);
- PlayerduelWatching[playerid] = 1;
- SendClientMessage(playerid, COLOR_YELLOW, "You are now watching the player duels, Death Match is NOT allowed in this area, /leavewatch to leave.");
- return 1;
- }
- else return SendClientMessage(playerid, RED, "[VT ERROR] You are already watching the duel fights, /leavewatch to leave this place.");
- }
- dcmd_leavewatch(playerid, params[])
- {
- #pragma unused params
- if(PlayerduelWatching[playerid] == 1)
- {
- SetPlayerHealth(playerid, 100);
- SpawnPlayer(playerid);
- SendClientMessage(playerid, COLOR_YELLOW, "You left the player duel watching");
- PlayerduelWatching[playerid] = 0;
- return 1;
- }
- else return SendClientMessage(playerid, RED, "[VT ERROR] You are not watching the duel fights, /watchduels to watch.");
- }
- dcmd_duel(playerid, params[])
- {
- new
- giveplayerid,
- weapon[128],
- price;
- new string[256];
- new sendername[MAX_PLAYER_NAME];
- new giveplayername[MAX_PLAYER_NAME];
- if (sscanf(params, "usd", giveplayerid,weapon,price))
- {
- SendClientMessage(playerid, COLOR_YELLOW, "[VT ERROR] Right Usage: /duel [playerid] [weapon] [amount]");
- SendClientMessage(playerid, COLOR_YELLOW, "Duel weapons: deagle, mp5, chainsaw, silpist, combatsg, shotgun");
- return 1;
- }
- else
- {
- if(playerid != giveplayerid)
- {
- GetPlayerName(playerid, sendername, sizeof(sendername));
- GetPlayerName(giveplayerid, giveplayername, sizeof(giveplayername));
- if(strcmp("deagle", weapon, true, 6) == 0)
- {
- if(GetPlayerMoney(playerid) >= price)
- {
- if(price < -1){
- return SendClientMessage(playerid,RED,"Ammount can`t be -");
- }
- if(Inventation[giveplayerid] == -1)
- {
- if(InventationSent[playerid] == -1)
- {
- if(Induel[playerid] == 0)
- {
- if(Induel[giveplayerid] == 0)
- {
- if(duelRoom1 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a desert eagle for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a desert eagle for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- Inventationprice[giveplayerid] = price;
- duelRoom1price = price;
- duelRoom1 = playerid;
- WeaponduelRoom1 = 24;
- return 1;
- }
- else if(duelRoom2 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a desert eagle for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a desert eagle for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom2price = price;
- duelRoom2 = playerid;
- WeaponduelRoom2 = 24;
- return 1;
- }
- else if(duelRoom3 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a desert eagle for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a desert eagle for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom3price = price;
- duelRoom3 = playerid;
- WeaponduelRoom3 = 24;
- return 1;
- }
- else if(duelRoom4 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a desert eagle for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a desert eagle for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom4price = price;
- duelRoom4 = playerid;
- WeaponduelRoom4 = 24;
- return 1;
- }
- else return SendClientMessage(playerid, RED, "there are no duel rooms free, wait till a duel ends");
- }
- else return SendClientMessage(playerid, RED, "This player is already in a duel");
- }
- else return SendClientMessage(playerid, RED, "you are still in a duel, end it first");
- }
- else return SendClientMessage(playerid, RED, "You already sent an inventation, wait 30 seconds or wait till the other player declines");
- }
- else return SendClientMessage(playerid, RED, "This player already got an inventation");
- }
- else return SendClientMessage(playerid, RED, "You can't afford the duel fee");
- }
- if(strcmp("mp5", weapon, true, 3) == 0)
- {
- if(GetPlayerMoney(playerid) >= price)
- {
- if(price < -1){
- return SendClientMessage(playerid,RED,"Ammount can`t be -");
- }
- if(Inventation[giveplayerid] == -1)
- {
- if(InventationSent[playerid] == -1)
- {
- if(Induel[playerid] == 0)
- {
- if(Induel[giveplayerid] == 0)
- {
- if(duelRoom1 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a mp5 for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a mp5 for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- Inventationprice[giveplayerid] = price;
- duelRoom1price = price;
- duelRoom1 = playerid;
- WeaponduelRoom1 = 29;
- return 1;
- }
- else if(duelRoom2 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a mp5 for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a mp5 for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom2price = price;
- duelRoom2 = playerid;
- WeaponduelRoom2 = 29;
- return 1;
- }
- else if(duelRoom3 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a mp5 for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a mp5 for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom3price = price;
- duelRoom3 = playerid;
- WeaponduelRoom3 = 29;
- return 1;
- }
- else if(duelRoom4 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a mp5 for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a mp5 for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom4price = price;
- duelRoom4 = playerid;
- WeaponduelRoom4 = 29;
- return 1;
- }
- else return SendClientMessage(playerid, RED, "there are no duel rooms free, wait till a duel ends");
- }
- else return SendClientMessage(playerid, RED, "This player is already in a duel");
- }
- else return SendClientMessage(playerid, RED, "you are still in a duel, end it first");
- }
- else return SendClientMessage(playerid, RED, "You already sent an inventation, wait 30 seconds or wait till the other player declines");
- }
- else return SendClientMessage(playerid, RED, "This player already got an inventation");
- }
- else return SendClientMessage(playerid, RED, "You can't afford the duel fee");
- }
- if(strcmp("chainsaw", weapon, true, 8) == 0)
- {
- if(GetPlayerMoney(playerid) >= price)
- {
- if(price < -1){
- return SendClientMessage(playerid,RED,"Ammount can`t be -");
- }
- if(Inventation[giveplayerid] == -1)
- {
- if(InventationSent[playerid] == -1)
- {
- if(Induel[playerid] == 0)
- {
- if(Induel[giveplayerid] == 0)
- {
- if(duelRoom1 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a chainsaw for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a chainsaw for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- Inventationprice[giveplayerid] = price;
- duelRoom1price = price;
- duelRoom1 = playerid;
- WeaponduelRoom1 = 9;
- return 1;
- }
- else if(duelRoom2 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a chainsaw for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a chainsaw for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom2price = price;
- duelRoom2 = playerid;
- WeaponduelRoom2 = 9;
- return 1;
- }
- else if(duelRoom3 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a chainsaw for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a chainsaw for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom3price = price;
- duelRoom3 = playerid;
- WeaponduelRoom3 = 9;
- return 1;
- }
- else if(duelRoom4 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a chainsaw for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a chainsaw for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom4price = price;
- duelRoom4 = playerid;
- WeaponduelRoom4 = 9;
- return 1;
- }
- else return SendClientMessage(playerid, RED, "there are no duel rooms free, wait till a duel ends");
- }
- else return SendClientMessage(playerid, RED, "This player is already in a duel");
- }
- else return SendClientMessage(playerid, RED, "you are still in a duel, end it first");
- }
- else return SendClientMessage(playerid, RED, "You already sent an inventation, wait 30 seconds or wait till the other player declines");
- }
- else return SendClientMessage(playerid, RED, "This player already got an inventation");
- }
- else return SendClientMessage(playerid, RED, "You can't afford the duel fee");
- }
- if(strcmp("silpist", weapon, true, 7) == 0)
- {
- if(GetPlayerMoney(playerid) >= price)
- {
- if(price < -1){
- return SendClientMessage(playerid,RED,"Ammount can`t be -");
- }
- if(Inventation[giveplayerid] == -1)
- {
- if(InventationSent[playerid] == -1)
- {
- if(Induel[playerid] == 0)
- {
- if(Induel[giveplayerid] == 0)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- if(duelRoom1 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a slipist for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a slipist for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- Inventationprice[giveplayerid] = price;
- duelRoom1price = price;
- duelRoom1 = playerid;
- WeaponduelRoom1 = 23;
- return 1;
- }
- else if(duelRoom2 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a slipist for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a slipist for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom2price = price;
- duelRoom2 = playerid;
- WeaponduelRoom2 = 23;
- return 1;
- }
- else if(duelRoom3 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a slipist for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a slipist for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom3price = price;
- duelRoom3 = playerid;
- WeaponduelRoom3 = 23;
- return 1;
- }
- else if(duelRoom4 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a slipist for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a slipist for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom4price = price;
- duelRoom4 = playerid;
- WeaponduelRoom4 = 23;
- return 1;
- }
- else return SendClientMessage(playerid, RED, "there are no duel rooms free, wait till a duel ends");
- }
- else return SendClientMessage(playerid, RED, "This player is already in a duel");
- }
- else return SendClientMessage(playerid, RED, "you are still in a duel, end it first");
- }
- else return SendClientMessage(playerid, RED, "You already sent an inventation, wait 30 seconds or wait till the other player declines");
- }
- else return SendClientMessage(playerid, RED, "This player already got an inventation");
- }
- else return SendClientMessage(playerid, RED, "You can't afford the duel fee");
- }
- if(strcmp("combatsg", weapon, true, 8) == 0)
- {
- if(GetPlayerMoney(playerid) >= price)
- {
- if(price < -1){
- return SendClientMessage(playerid,RED,"Ammount can`t be -");
- }
- if(Inventation[giveplayerid] == -1)
- {
- if(InventationSent[playerid] == -1)
- {
- if(Induel[playerid] == 0)
- {
- if(Induel[giveplayerid] == 0)
- {
- if(duelRoom1 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a combatsg for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a combatsg for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- Inventationprice[giveplayerid] = price;
- duelRoom1price = price;
- duelRoom1 = playerid;
- WeaponduelRoom1 = 27;
- return 1;
- }
- else if(duelRoom2 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a combatsg for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a combatsg for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom2price = price;
- duelRoom2 = playerid;
- WeaponduelRoom2 = 27;
- return 1;
- }
- else if(duelRoom3 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a combatsg for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a combatsg for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom3price = price;
- duelRoom3 = playerid;
- WeaponduelRoom3 = 27;
- return 1;
- }
- else if(duelRoom4 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a combatsg for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a combatsg for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom4price = price;
- duelRoom4 = playerid;
- WeaponduelRoom4 = 27;
- return 1;
- }
- else return SendClientMessage(playerid, RED, "there are no duel rooms free, wait till a duel ends");
- }
- else return SendClientMessage(playerid, RED, "This player is already in a duel");
- }
- else return SendClientMessage(playerid, RED, "you are still in a duel, end it first");
- }
- else return SendClientMessage(playerid, RED, "You already sent an inventation, wait 30 seconds or wait till the other player declines");
- }
- else return SendClientMessage(playerid, RED, "This player already got an inventation");
- }
- else return SendClientMessage(playerid, RED, "You can't afford the duel fee");
- }
- if(strcmp("shotgun", weapon, true, 7) == 0)
- {
- if(GetPlayerMoney(playerid) >= price)
- {
- if(price < -1){
- return SendClientMessage(playerid,RED,"Ammount can`t be -");
- }
- if(Inventation[giveplayerid] == -1)
- {
- if(InventationSent[playerid] == -1)
- {
- if(Induel[playerid] == 0)
- {
- if(Induel[giveplayerid] == 0)
- {
- if(duelRoom1 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a shotgun for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a shotgun for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- Inventationprice[giveplayerid] = price;
- duelRoom1price = price;
- duelRoom1 = playerid;
- WeaponduelRoom1 = 25;
- return 1;
- }
- else if(duelRoom2 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a shotgun for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a shotgun for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom2price = price;
- duelRoom2 = playerid;
- WeaponduelRoom2 = 25;
- return 1;
- }
- else if(duelRoom3 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a shotgun for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a shotgun for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom3price = price;
- duelRoom3 = playerid;
- WeaponduelRoom3 = 25;
- return 1;
- }
- else if(duelRoom4 == -1)
- {
- SetTimerEx("inventationremove", 30000, 0, "i", playerid);
- format(string, sizeof(string), "%s has sent you a 1 vs. 1 duel with a shotgun for $%d, /acceptduel or /declineduel", sendername, price);
- SendClientMessage(giveplayerid, GREEN, string);
- format(string, sizeof(string), "you sent %s a 1 vs. 1 duel with a shotgun for $%d", giveplayername, price);
- SendClientMessage(playerid, GREEN, string);
- InventationSent[playerid] = giveplayerid;
- Inventation[giveplayerid] = playerid;
- duelRoom4price = price;
- duelRoom4 = playerid;
- WeaponduelRoom4 = 25;
- return 1;
- }
- else return SendClientMessage(playerid, RED, "there are no duel rooms free, wait till a duel ends");
- }
- else return SendClientMessage(playerid, RED, "This player is already in a duel");
- }
- else return SendClientMessage(playerid, RED, "you are still in a duel, end it first");
- }
- else return SendClientMessage(playerid, RED, "You already sent an inventation, wait 30 seconds or wait till the other player declines");
- }
- else return SendClientMessage(playerid, RED, "This player already got an inventation");
- }
- else return SendClientMessage(playerid, RED, "You can't afford the duel fee");
- }
- else return SendClientMessage(playerid, COLOR_YELLOW, "Right Usage: /duel [playerid] [weapon] [amount]");
- }
- else return SendClientMessage(playerid, RED, "You cant duel yourself");
- }
- }
- dcmd_acceptduel(playerid, params[])
- {
- #pragma unused params
- if(Inventation[playerid] >= 0)
- {
- if(GetPlayerMoney(playerid) >= Inventationprice[playerid])
- {
- if(duelRoom1 == Inventation[playerid])
- {
- SetPlayerTeam(playerid, 1);
- SetPlayerTeam(Inventation[playerid], 2);
- Induel[Inventation[playerid]] = 1;
- Induel[playerid] = 1;
- ResetPlayerWeapons(playerid);
- ResetPlayerWeapons(Inventation[playerid]);
- GivePlayerWeapon(playerid, WeaponduelRoom1, 500);
- GivePlayerWeapon(Inventation[playerid], WeaponduelRoom1, 500);
- SetPlayerPos(playerid, 1715.5034,-2865.0405,6.5554);
- SetPlayerFacingAngle(playerid,317.1064);
- SetPlayerPos(Inventation[playerid], 1723.2203,-2856.0315,6.5554);
- SetPlayerFacingAngle(Inventation[playerid],140.0715);
- SetPlayerHealth(playerid, 100);
- SetPlayerArmour(playerid, 100);
- SetPlayerHealth(Inventation[playerid], 100);
- SetPlayerArmour(Inventation[playerid], 100);
- GivePlayerMoney(playerid, -duelRoom1price);
- GivePlayerMoney(Inventation[playerid], -duelRoom1price);
- SendClientMessage(playerid, GREEN, "LET THE BATTLE BEGIN!");
- SendClientMessage(Inventation[playerid], GREEN, "LET THE BATTLE BEGIN!");
- TogglePlayerControllable(playerid, 0);
- TogglePlayerControllable(Inventation[playerid], 0);
- CountDown(playerid, 3);
- CountDown(Inventation[playerid], 3);
- }
- if(duelRoom2 == Inventation[playerid])
- {
- SetPlayerTeam(playerid, 1);
- SetPlayerTeam(Inventation[playerid], 2);
- Induel[Inventation[playerid]] = 1;
- Induel[playerid] = 1;
- ResetPlayerWeapons(playerid);
- ResetPlayerWeapons(Inventation[playerid]);
- GivePlayerWeapon(playerid, WeaponduelRoom2, 500);
- GivePlayerWeapon(Inventation[playerid], WeaponduelRoom2, 500);
- SetPlayerPos(playerid, 1747.7878,-2864.6843,6.5554);
- SetPlayerFacingAngle(playerid,47.0340);
- SetPlayerPos(Inventation[playerid], 1740.1650,-2858.3879,6.5554);
- SetPlayerFacingAngle(Inventation[playerid],228.1190);
- SetPlayerHealth(playerid, 100);
- SetPlayerArmour(playerid, 100);
- SetPlayerHealth(Inventation[playerid], 100);
- SetPlayerArmour(Inventation[playerid], 100);
- GivePlayerMoney(playerid, -duelRoom2price);
- GivePlayerMoney(Inventation[playerid], -duelRoom2price);
- SendClientMessage(playerid, GREEN, "LET THE BATTLE BEGIN!");
- SendClientMessage(Inventation[playerid], GREEN, "LET THE BATTLE BEGIN!");
- TogglePlayerControllable(playerid, 0);
- TogglePlayerControllable(Inventation[playerid], 0);
- CountDown(playerid, 3);
- CountDown(Inventation[playerid], 3);
- return 1;
- }
- if(duelRoom3 == Inventation[playerid])
- {
- SetPlayerTeam(playerid, 1);
- SetPlayerTeam(Inventation[playerid], 2);
- Induel[Inventation[playerid]] = 1;
- Induel[playerid] = 1;
- ResetPlayerWeapons(playerid);
- ResetPlayerWeapons(Inventation[playerid]);
- GivePlayerWeapon(playerid, WeaponduelRoom3, 500);
- GivePlayerWeapon(Inventation[playerid], WeaponduelRoom3, 500);
- SetPlayerPos(playerid, 1748.3942,-2832.6250,6.5554);
- SetPlayerFacingAngle(playerid,141.3482);
- SetPlayerPos(Inventation[playerid], 1741.1982,-2839.9243,6.5554);
- SetPlayerFacingAngle(Inventation[playerid],315.8531);
- SetPlayerHealth(playerid, 100);
- SetPlayerArmour(playerid, 100);
- SetPlayerHealth(Inventation[playerid], 100);
- SetPlayerArmour(Inventation[playerid], 100);
- GivePlayerMoney(playerid, -duelRoom3price);
- GivePlayerMoney(Inventation[playerid], -duelRoom3price);
- SendClientMessage(playerid, GREEN, "LET THE BATTLE BEGIN!");
- SendClientMessage(Inventation[playerid], GREEN, "LET THE BATTLE BEGIN!");
- TogglePlayerControllable(playerid, 0);
- TogglePlayerControllable(Inventation[playerid], 0);
- CountDown(playerid, 3);
- CountDown(Inventation[playerid], 3);
- return 1;
- }
- if(duelRoom4 == Inventation[playerid])
- {
- SetPlayerTeam(playerid, 1);
- SetPlayerTeam(Inventation[playerid], 2);
- Induel[Inventation[playerid]] = 1;
- Induel[playerid] = 1;
- ResetPlayerWeapons(playerid);
- ResetPlayerWeapons(Inventation[playerid]);
- GivePlayerWeapon(playerid, WeaponduelRoom4, 500);
- GivePlayerWeapon(Inventation[playerid], WeaponduelRoom4, 500);
- SetPlayerPos(playerid, 1716.7450,-2832.7969,6.5554);
- SetPlayerFacingAngle(playerid,229.7091);
- SetPlayerPos(Inventation[playerid], 1722.3630,-2840.2034,6.5554);
- SetPlayerFacingAngle(Inventation[playerid],45.7807);
- SetPlayerHealth(playerid, 100);
- SetPlayerArmour(playerid, 100);
- SetPlayerHealth(Inventation[playerid], 100);
- SetPlayerArmour(Inventation[playerid], 100);
- GivePlayerMoney(playerid, -duelRoom4price);
- GivePlayerMoney(Inventation[playerid], -duelRoom4price);
- SendClientMessage(playerid, GREEN, "LET THE BATTLE BEGIN!");
- SendClientMessage(Inventation[playerid], GREEN, "LET THE BATTLE BEGIN!");
- TogglePlayerControllable(playerid, 0);
- TogglePlayerControllable(Inventation[playerid], 0);
- CountDown(playerid, 3);
- CountDown(Inventation[playerid], 3);
- return 1;
- }
- return 1;
- }
- else return SendClientMessage(playerid, RED, "You dont have enough money to accept the duel use /declineduel please.");
- }
- else return SendClientMessage(playerid, RED, "You didnt receive a duel inventation");
- }
- dcmd_declineduel(playerid, params[])
- {
- #pragma unused params
- SendClientMessage(playerid, RED, "You decline the duel inventation");
- SendClientMessage(Inventation[playerid], RED, "your duel inventation got declined.");
- Inventation[InventationSent[playerid]] = -1;
- InventationSent[playerid] = -1;
- if(duelRoom1 == playerid)
- {
- duelRoom1 = -1;
- }
- if(duelRoom2 == playerid)
- {
- duelRoom2 = -1;
- }
- if(duelRoom3 == playerid)
- {
- duelRoom3 = -1;
- }
- if(duelRoom3 == playerid)
- {
- duelRoom4 = -1;
- }
- return 1;
- }
- dcmd_givemoney(playerid, params[])
- {
- new pID,cash;
- if(sscanf(params,"ud",pID,cash)){
- return SendClientMessage(playerid,grau,"USAGE: /givemoney [playerid] [amount]");
- }
- if(!IsPlayerConnected(pID)){
- return SendClientMessage(playerid,grau,"Nobody is connected with this ID!");
- }
- if(GetPlayerMoney(playerid) < cash) return SendClientMessage(playerid,COLOR_RED,"You have not enough money!");
- if(playerid == pID) return SendClientMessage(playerid,COLOR_RED,"You cant give money to yourself!");
- new string[128],string2[128],aname[MAX_PLAYER_NAME],name[MAX_PLAYER_NAME];
- GivePlayerMoney(pID,cash);
- GivePlayerMoney(playerid,-cash);
- GetPlayerName(playerid,aname,sizeof(aname));
- GetPlayerName(pID,name,sizeof(name));
- format(string,sizeof(string),"You have given %s %d $",name,cash);
- format(string2,sizeof(string2),"Player %s has given you %d $",aname,cash);
- SendClientMessage(playerid,COLOR_YELLOW,string);
- SendClientMessage(pID,COLOR_LIGHTBLUE,string2);
- return 1;
- }
- //------------------------------------------------------------------------------
- public DrugTimer()
- {
- SendClientMessageToAll(COLOR_RED,"You can rob drugs now /druginfo ");
- DrugsStolen = 0;
- return 1;
- }
- public EnableAtack()
- {
- SendClientMessageToAll(COLOR_ORANGE,"|______MAFIA-WAR-NEWS______|");
- SendClientMessageToAll(COLOR_ORANGE,"You can atack Gangzones now");
- EnableAtack1 = 0;
- KillTimer(Enable);
- return 1;
- }
- //DM STOCKS=====================================================================
- stock SniperDm(playerid)
- {
- new sniper = random(8);
- switch(sniper)
- {
- case 0: SetPlayerPos(playerid,2682.5110,2783.8494,61.7891);
- case 1: SetPlayerPos(playerid,2614.2383,2728.3306,36.5386);
- case 2: SetPlayerPos(playerid,2575.7756,2840.6538,19.9922);
- case 3: SetPlayerPos(playerid,2627.6262,2809.0125,36.3222);
- case 4: SetPlayerPos(playerid,2630.0256,2829.7188,64.3359);
- case 5: SetPlayerPos(playerid,2580.8792,2714.9214,28.1953);
- case 6: SetPlayerPos(playerid,2576.3464,2826.2939,10.8203);
- case 7: SetPlayerPos(playerid,2618.8142,2707.7351,25.8222);
- }
- new name[MAX_PLAYER_NAME],string[128];
- GetPlayerName(playerid,name,sizeof(name));
- SendClientMessage(playerid,COLOR_WHITE,"/leave to leave the Arena.Feel free in DM Arena ,you can kill your own Team-Members");
- format(string,sizeof(string)," %s has been teleported to Sniper-DM type /dm to join him",name);
- SendClientMessageToAll(COLOR_LIGHTBLUE,string);
- ResetPlayerWeapons(playerid);
- GivePlayerWeapon(playerid,34,777);
- GivePlayerWeapon(playerid,46,1);
- SetPlayerHealth(playerid,100);
- SetPlayerArmour(playerid,100);
- IsDm[playerid] = 1;
- return 1;
- }
- stock DeagleDm(playerid)
- {
- new deagle = random(10);
- switch(deagle)
- {
- case 0: SetPlayerPos(playerid,-1356.2256,2497.0430,87.6755);
- case 1: SetPlayerPos(playerid,-1338.0901,2521.8582,87.0469);
- case 2: SetPlayerPos(playerid,-1319.9596,2546.1216,87.4976);
- case 3: SetPlayerPos(playerid,-1275.1669,2548.0293,87.2330);
- case 4: SetPlayerPos(playerid,-1280.8994,2508.5693,87.0355);
- case 5: SetPlayerPos(playerid,-1280.2076,2470.8438,87.5280);
- case 6: SetPlayerPos(playerid,-1318.3882,2486.6592,87.0469);
- case 7: SetPlayerPos(playerid,-1345.1329,2458.4866,87.1831);
- case 8: SetPlayerPos(playerid,-1335.5486,2506.2288,87.0469);
- case 9: SetPlayerPos(playerid,-1312.5459,2526.7815,87.5624);
- }
- new name[MAX_PLAYER_NAME],string[128];
- GetPlayerName(playerid,name,sizeof(name));
- SendClientMessage(playerid,COLOR_WHITE,"/leave to leave the Arena.Feel free in DM Arena ,you can kill your own Team-Members");
- format(string,sizeof(string)," %s has been teleported to Deagle-DM type /dm to join him",name);
- SendClientMessageToAll(COLOR_LIGHTBLUE,string);
- ResetPlayerWeapons(playerid);
- SetPlayerHealth(playerid,100);
- SetPlayerArmour(playerid,100);
- GivePlayerWeapon(playerid,24,777);
- IsDm[playerid] = 2;
- return 1;
- }
- stock GrenadeDm(playerid)
- {
- new grenade = random(8);
- switch(grenade)
- {
- case 0: SetPlayerPos(playerid,-2494.2400,2512.1038,18.4071);
- case 1: SetPlayerPos(playerid,-2454.8713,2499.4910,15.7657);
- case 2: SetPlayerPos(playerid,-2397.9727,2499.2690,11.6562);
- case 3: SetPlayerPos(playerid,-2397.3997,2476.0596,10.1992);
- case 4: SetPlayerPos(playerid,-2436.9753,2476.8511,13.7891);
- case 5: SetPlayerPos(playerid,-2484.4177,2476.6230,18.0284);
- case 6: SetPlayerPos(playerid,-2461.5310,2513.2615,18.2554);
- case 7: SetPlayerPos(playerid,-2449.5845,2510.7532,18.2554);
- }
- new name[MAX_PLAYER_NAME],string[128];
- GetPlayerName(playerid,name,sizeof(name));
- SendClientMessage(playerid,COLOR_WHITE,"/leave to leave the Arena.Feel free in DM Arena ,you can kill your own Team-Members");
- format(string,sizeof(string)," %s has been teleported to Grenade-DM type /dm to join him",name);
- SendClientMessageToAll(COLOR_LIGHTBLUE,string);
- ResetPlayerWeapons(playerid);
- SetPlayerHealth(playerid,100);
- SetPlayerArmour(playerid,100);
- GivePlayerWeapon(playerid,16,777);
- IsDm[playerid] = 3;
- return 1;
- }
- stock AllinDm(playerid)
- {
- new allin = random(10);
- switch(allin)
- {
- case 0: SetPlayerPos(playerid,283.9653,1477.9188,10.5859);
- case 1: SetPlayerPos(playerid,279.5573,1343.6293,10.5859);
- case 2: SetPlayerPos(playerid,115.5945,1343.6865,10.5859);
- case 3: SetPlayerPos(playerid,113.7964,1482.5033,10.6296);
- case 4: SetPlayerPos(playerid,170.3064,1414.4402,10.5859);
- case 5: SetPlayerPos(playerid,217.4453,1453.3802,10.5859);
- case 6: SetPlayerPos(playerid,215.3884,1385.6682,10.5859);
- case 7: SetPlayerPos(playerid,154.7420,1376.5007,10.5859);
- case 8: SetPlayerPos(playerid,151.3914,1450.0488,10.5912);
- case 9: SetPlayerPos(playerid,247.9790,1410.0133,23.3703);
- }
- new name[MAX_PLAYER_NAME],string[128];
- GetPlayerName(playerid,name,sizeof(name));
- SendClientMessage(playerid,COLOR_WHITE,"/leave to leave the Arena.Feel free in DM Arena ,you can kill your own Team-Members");
- format(string,sizeof(string)," %s has been teleported to All Inclusive-DM type /dm to join him",name);
- SendClientMessageToAll(COLOR_LIGHTBLUE,string);
- ResetPlayerWeapons(playerid);
- SetPlayerHealth(playerid,100);
- SetPlayerArmour(playerid,100);
- GivePlayerWeapon(playerid,24,777);
- GivePlayerWeapon(playerid,29,777);
- GivePlayerWeapon(playerid,34,777);
- GivePlayerWeapon(playerid,31,777);
- IsDm[playerid] = 4;
- return 1;
- }
- stock StreetfightDm(playerid)
- {
- new Streetfight = random(8);
- switch(Streetfight)
- {
- case 0: SetPlayerPos(playerid,2491.2002,2396.9971,10.8203);
- case 1: SetPlayerPos(playerid,2513.8740,2353.3318,10.8203);
- case 2: SetPlayerPos(playerid,2516.3733,2400.8567,10.8203);
- case 3: SetPlayerPos(playerid,2477.5942,2382.7888,7.9531);
- case 4: SetPlayerPos(playerid,2484.5007,2357.4360,4.2109);
- case 5: SetPlayerPos(playerid,2540.8926,2375.5400,4.2109);
- case 6: SetPlayerPos(playerid,2491.0117,2396.4392,4.2109);
- case 7: SetPlayerPos(playerid,2522.4294,2377.6006,4.2109);
- }
- new name[MAX_PLAYER_NAME],string[128];
- GetPlayerName(playerid,name,sizeof(name));
- SendClientMessage(playerid,COLOR_WHITE,"Type /fstyle to choose the fighting style,/leave to leave the Arena.Feel free in DM Arena ,you can kill your own Team-Members");
- format(string,sizeof(string)," %s has been teleported to StreetFight-DM type /dm to join him",name);
- SendClientMessageToAll(COLOR_LIGHTBLUE,string);
- ResetPlayerWeapons(playerid);
- SetPlayerArmour(playerid,0);
- SetPlayerHealth(playerid,100);
- IsDm[playerid] = 5;
- return 1;
- }
- stock TacticDm(playerid)
- {
- new tactic = random(5);
- switch(tactic)
- {
- case 0: SetPlayerPos(playerid,-395.0324,1250.5519,6.8073);
- case 1: SetPlayerPos(playerid,-402.6543,1299.0596,10.4422);
- case 2: SetPlayerPos(playerid,-414.3020,1349.9525,12.9641);
- case 3: SetPlayerPos(playerid,-424.7974,1387.2543,14.6024);
- case 4: SetPlayerPos(playerid,-439.7584,1435.5499,20.5175);
- }
- new name[MAX_PLAYER_NAME],string[128];
- GetPlayerName(playerid,name,sizeof(name));
- SendClientMessage(playerid,COLOR_WHITE,"/leave to leave the Arena.Feel free in DM Arena ,you can kill your own Team-Members");
- format(string,sizeof(string)," %s has been teleported to Tactic-DM type /dm to join him",name);
- SendClientMessageToAll(COLOR_LIGHTBLUE,string);
- ResetPlayerWeapons(playerid);
- SetPlayerArmour(playerid,100);
- SetPlayerHealth(playerid,100);
- GivePlayerWeapon(playerid,29,7777);
- IsDm[playerid] = 6;
- return 1;
- }
- //ZONE STOCKES==================================================================
- stock ZoneAtackLcn(playerid)
- {
- new name[MAX_PLAYER_NAME],string[128];
- GetPlayerName(playerid,name,sizeof(name));
- if(Gang[playerid]==TEAM_LCN) return SendClientMessage(playerid,COLOR_RED,"You can`t attack a friendly Zone!");
- SendClientMessageToAll(COLOR_ORANGE,"|______MAFIA-WAR-NEWS______|");
- SendClientMessageToAll(COLOR_ORANGE," ");
- format(string, sizeof(string),"%s has started a MafiaWar against LaCosaNostra",name);
- SendClientMessageToAll(COLOR_ORANGE,string);
- SendClientMessage(playerid,COLOR_BLUE,"MESSAGE: You have started a Mafia-War!You must be in this zone for 4 Minutes");
- SendClientMessage(playerid,COLOR_BLUE,"MESSAGE: If you die in the zone your team will loose the Mafia war");
- SendLcnMessage(COLOR_RED,"TEAMMESSAGE: One of our Zones is under attack, defend the FlashingZone!");
- SendClientMessageToAll(COLOR_ORANGE," ");
- SendClientMessageToAll(COLOR_ORANGE,"|______MAFIA-WAR-NEWS______|");
- ZoneTimer1 = SetTimer("ZoneAtack",2000,1);
- PlayerAtacker[playerid] = 1;
- return 1;
- }
- stock ZoneAtackRus(playerid)
- {
- new name[MAX_PLAYER_NAME],string[128];
- GetPlayerName(playerid,name,sizeof(name));
- if(Gang[playerid]==TEAM_RUS) return SendClientMessage(playerid,COLOR_RED,"You can`t attack a friendly Zone!");
- SendClientMessageToAll(COLOR_ORANGE,"|______MAFIA-WAR-NEWS______|");
- SendClientMessageToAll(COLOR_ORANGE," ");
- format(string, sizeof(string),"%s has started a MafiaWar against Russian Mafia",name);
- SendClientMessageToAll(COLOR_ORANGE,string);
- SendClientMessage(playerid,COLOR_BLUE,"MESSAGE: You have started a Mafia-War!You must be in this zone for 4 Minutes");
- SendClientMessage(playerid,COLOR_BLUE,"MESSAGE: If you die in the zone your team will loose the Mafia war");
- SendRusMessage(COLOR_RED,"TEAMMESSAGE: One of our Zones is under attack, defend the FlashingZone!");
- SendClientMessageToAll(COLOR_ORANGE," ");
- SendClientMessageToAll(COLOR_ORANGE,"|______MAFIA-WAR-NEWS______|");
- ZoneTimer1 = SetTimer("ZoneAtack",2000,1);
- PlayerAtacker[playerid] = 1;
- return 1;
- }
- stock ZoneAtackTriad(playerid)
- {
- new name[MAX_PLAYER_NAME],string[128];
- GetPlayerName(playerid,name,sizeof(name));
- if(Gang[playerid]==TEAM_TRIADS) return SendClientMessage(playerid,COLOR_RED,"You can`t attack a friendly Zone!");
- SendClientMessageToAll(COLOR_ORANGE,"|______MAFIA-WAR-NEWS______|");
- SendClientMessageToAll(COLOR_ORANGE," ");
- format(string, sizeof(string),"%s has started a MafiaWar against Triads",name);
- SendClientMessageToAll(COLOR_ORANGE,string);
- SendClientMessage(playerid,COLOR_BLUE,"MESSAGE: You have started a Mafia-War!You must be in this zone for 4 Minutes");
- SendClientMessage(playerid,COLOR_BLUE,"MESSAGE: If you die in the zone your team will loose the Mafia war");
- SendTriadMessage(COLOR_RED,"TEAMMESSAGE: One of our Zones is under attack, defend the FlashingZone!");
- SendClientMessageToAll(COLOR_ORANGE," ");
- SendClientMessageToAll(COLOR_ORANGE,"|______MAFIA-WAR-NEWS______|");
- ZoneTimer1 = SetTimer("ZoneAtack",2000,1);
- PlayerAtacker[playerid] = 1;
- return 1;
- }
- stock ZoneAtackYugo(playerid)
- {
- new name[MAX_PLAYER_NAME],string[128];
- GetPlayerName(playerid,name,sizeof(name));
- if(Gang[playerid]==TEAM_YUGO) return SendClientMessage(playerid,COLOR_RED,"You can`t attack a friendly Zone!");
- SendClientMessageToAll(COLOR_ORANGE,"|______MAFIA-WAR-NEWS______|");
- SendClientMessageToAll(COLOR_ORANGE," ");
- format(string, sizeof(string),"%s has started a MafiaWar against Yugoslawian Mafia",name);
- SendClientMessageToAll(COLOR_ORANGE,string);
- SendClientMessage(playerid,COLOR_BLUE,"MESSAGE: You have started a Mafia-War!You must be in this zone for 4 Minutes");
- SendClientMessage(playerid,COLOR_BLUE,"MESSAGE: If you die in the zone your team will loose the Mafia war");
- SendYugoMessage(COLOR_RED,"TEAMMESSAGE: One of our Zones is under attack, defend the FlashingZone!");
- SendClientMessageToAll(COLOR_ORANGE," ");
- SendClientMessageToAll(COLOR_ORANGE,"|______MAFIA-WAR-NEWS______|");
- ZoneTimer1 = SetTimer("ZoneAtack",2000,1);
- PlayerAtacker[playerid] = 1;
- return 1;
- }
- stock ZoneAtackGerman(playerid)
- {
- new name[MAX_PLAYER_NAME],string[128];
- GetPlayerName(playerid,name,sizeof(name));
- if(Gang[playerid]==TEAM_GERMAN) return SendClientMessage(playerid,COLOR_RED,"You can`t attack a friendly Zone!");
- SendClientMessageToAll(COLOR_ORANGE,"|______MAFIA-WAR-NEWS______|");
- SendClientMessageToAll(COLOR_ORANGE," ");
- format(string, sizeof(string),"%s has started a MafiaWar against German Mafia",name);
- SendClientMessageToAll(COLOR_ORANGE,string);
- SendClientMessage(playerid,COLOR_BLUE,"MESSAGE: You have started a Mafia-War!You must be in this zone for 4 Minutes");
- SendClientMessage(playerid,COLOR_BLUE,"MESSAGE: If you die in the zone your team will loose the Mafia war");
- SendGermanMessage(COLOR_RED,"TEAMMESSAGE: One of our Zones is under attack, defend the FlashingZone!");
- SendClientMessageToAll(COLOR_ORANGE," ");
- SendClientMessageToAll(COLOR_ORANGE,"|______MAFIA-WAR-NEWS______|");
- ZoneTimer1 = SetTimer("ZoneAtack",2000,1);
- PlayerAtacker[playerid] = 1;
- return 1;
- }
- stock ZoneAtackCuban(playerid)
- {
- new name[MAX_PLAYER_NAME],string[128];
- GetPlayerName(playerid,name,sizeof(name));
- if(Gang[playerid]==TEAM_CUBAN) return SendClientMessage(playerid,COLOR_RED,"You can`t attack a friendly Zone!");
- SendCubanMessage(COLOR_RED,"One of our ZONES is under attack, defend the Zone!");
- SendClientMessageToAll(COLOR_ORANGE,"|______MAFIA-WAR-NEWS______|");
- format(string, sizeof(string),"%s has started a MafiaWar against the Cuban-Mafia",name);
- SendClientMessage(playerid,COLOR_BLUE,"MESSAGE: You have started a Mafia-War!You must be in this zone for 4 Minutes");
- SendClientMessage(playerid,COLOR_BLUE,"MESSAGE: If you die in the zone your team will loose the Mafia war");
- SendClientMessageToAll(COLOR_ORANGE,string);
- SendCubanMessage(COLOR_RED,"TEAMMESSAGE: One of our ZONES is under attack, defend the FlashinZone!");
- ZoneTimer1 = SetTimer("ZoneAtack",2000,1);
- PlayerAtacker[playerid] = 1;
- return 1;
- }
- //Messages----------------------------------------------------------------------
- stock SendLcnMessage(color,const message[])
- {
- for(new i = 0; i < GetMaxPlayers(); i++)
- {
- if(IsPlayerConnected(i) && Gang[i]==TEAM_LCN)
- {
- SendClientMessage(i,color,message);
- }
- }
- }
- stock SendRusMessage(color,const message[])
- {
- for(new i = 0; i < GetMaxPlayers(); i++)
- {
- if(IsPlayerConnected(i) && Gang[i]==TEAM_RUS)
- {
- SendClientMessage(i,color,message);
- }
- }
- }
- stock SendTriadMessage(color,const message[])
- {
- for(new i = 0; i < GetMaxPlayers(); i++)
- {
- if(IsPlayerConnected(i) && Gang[i]==TEAM_TRIADS)
- {
- SendClientMessage(i,color,message);
- }
- }
- }
- stock SendYugoMessage(color,const message[])
- {
- for(new i = 0; i < GetMaxPlayers(); i++)
- {
- if(IsPlayerConnected(i) && Gang[i]==TEAM_YUGO)
- {
- SendClientMessage(i,color,message);
- }
- }
- }
- stock SendGermanMessage(color,const message[])
- {
- for(new i = 0; i < GetMaxPlayers(); i++)
- {
- if(IsPlayerConnected(i) && Gang[i]==TEAM_GERMAN)
- {
- SendClientMessage(i,color,message);
- }
- }
- }
- stock SendCubanMessage(color,const message[])
- {
- for(new i = 0; i < GetMaxPlayers(); i++)
- {
- if(IsPlayerConnected(i) && Gang[i]==TEAM_CUBAN)
- {
- SendClientMessage(i,color,message);
- }
- }
- }
- stock GiveLcnMoney(amount)
- {
- for(new i = 0; i < GetMaxPlayers(); i++)
- {
- if(IsPlayerConnected(i) && Gang[i]==TEAM_LCN)
- {
- GivePlayerMoney(i,amount);
- }
- }
- }
- stock GiveRusMoney(amount)
- {
- for(new i = 0; i < GetMaxPlayers(); i++)
- {
- if(IsPlayerConnected(i) && Gang[i]==TEAM_RUS)
- {
- GivePlayerMoney(i,amount);
- }
- }
- }
- stock GiveTriadMoney(amount)
- {
- for(new i = 0; i < GetMaxPlayers(); i++)
- {
- if(IsPlayerConnected(i) && Gang[i]==TEAM_TRIADS)
- {
- GivePlayerMoney(i,amount);
- }
- }
- }
- stock GiveYugoMoney(amount)
- {
- for(new i = 0; i < GetMaxPlayers(); i++)
- {
- if(IsPlayerConnected(i) && Gang[i]==TEAM_YUGO)
- {
- GivePlayerMoney(i,amount);
- }
- }
- }
- stock GiveGermanMoney(amount)
- {
- for(new i = 0; i < GetMaxPlayers(); i++)
- {
- if(IsPlayerConnected(i) && Gang[i]==TEAM_GERMAN)
- {
- GivePlayerMoney(i,amount);
- }
- }
- }
- stock GiveCubanMoney(amount)
- {
- for(new i = 0; i < GetMaxPlayers(); i++)
- {
- if(IsPlayerConnected(i) && Gang[i]==TEAM_CUBAN)
- {
- GivePlayerMoney(i,amount);
- }
- }
- }
- //==============================================================================
- stock ZoneTextLcn(i)
- {
- new str[64];
- format(str, sizeof(str), "mafiazone of: ~g~La Cosa Nostra");
- TextDrawSetString(ZonesTextdraw[i],str);
- TextDrawShowForPlayer(i,ZonesTextdraw[i]);
- }
- stock ZoneTextRus(i)
- {
- new str[64];
- format(str, sizeof(str), "mafiazone of: ~r~Russian Mafia");
- TextDrawSetString(ZonesTextdraw[i],str);
- TextDrawShowForPlayer(i,ZonesTextdraw[i]);
- }
- stock ZoneTextTriad(i)
- {
- new str[64];
- format(str, sizeof(str), "mafiazone of: ~w~Triads");
- TextDrawSetString(ZonesTextdraw[i],str);
- TextDrawShowForPlayer(i,ZonesTextdraw[i]);
- }
- stock ZoneTextYugo(i)
- {
- new str[64];
- format(str, sizeof(str), "mafiazone of: ~b~Yugoslawian-Maifa");
- TextDrawSetString(ZonesTextdraw[i],str);
- TextDrawShowForPlayer(i,ZonesTextdraw[i]);
- }
- stock ZoneTextGerman(i)
- {
- new str[64];
- format(str, sizeof(str), "mafiazone of: ~y~German-Mafia");
- TextDrawSetString(ZonesTextdraw[i],str);
- TextDrawShowForPlayer(i,ZonesTextdraw[i]);
- }
- stock ZoneTextCuban(i)
- {
- new str[64];
- format(str, sizeof(str), "mafiazone of: ~p~Cuban-Mafia");
- TextDrawSetString(ZonesTextdraw[i],str);
- TextDrawShowForPlayer(i,ZonesTextdraw[i]);
- }
- //------------------------------------------------------------------------------
- public ZoneAtack()
- {
- TakeOverTime += 2;
- EnableAtack1 = 1;
- for(new i=0; i<MAX_PLAYERS; i++)
- {
- if(IsPlayerConnected(i))
- {
- if(PlayerAtacker[i]== 1)
- {
- new FlashColor = GetPlayerColor(i);
- new name[MAX_PLAYER_NAME],string[128];
- GetPlayerName(i,name,sizeof(name));
- {
- if(Zone1Atack == 1){
- GangZoneFlashForAll(Zone1,FlashColor);
- if(!IsPlayerInArea(i,-2799.996093, -173.397064, -2463.996093, 154.602935)){LeftArea();}
- }
- else if(Zone2Atack == 1){
- GangZoneFlashForAll(Zone2,FlashColor);
- if(!IsPlayerInArea(i,-2799.354492, 232.376708, -2615.354492, 696.376708)){LeftArea();}
- }
- else if(Zone3Atack == 1){
- GangZoneFlashForAll(Zone3,FlashColor);
- if(!IsPlayerInArea(i,-2276.547119, -86.489639, -2004.547119, 169.510360)){LeftArea();}
- }
- else if(Zone4Atack == 1){
- GangZoneFlashForAll(Zone4,FlashColor);
- if(!IsPlayerInArea(i,-2445.138183, -232.113327, -2293.138183, 223.886672)){LeftArea();}
- }
- else if(Zone5Atack == 1){
- GangZoneFlashForAll(Zone5,FlashColor);
- if(!IsPlayerInArea(i,-2328.167480, 337.696594, -1944.167480, 681.696594)){LeftArea();}
- }
- else if(Zone6Atack == 1){
- GangZoneFlashForAll(Zone6,FlashColor);
- if(!IsPlayerInArea(i,-1824.531494, 624.765625, -1496.531494, 920.765625)){LeftArea();}
- }
- else if(Zone7Atack == 1){
- GangZoneFlashForAll(Zone7,FlashColor);
- if(!IsPlayerInArea(i,-2439.947753, 1035.557861, -2119.947753, 1307.557861)){LeftArea();}
- }
- else if(Zone8Atack == 1){
- GangZoneFlashForAll(Zone8,FlashColor);
- if(!IsPlayerInArea(i,-1854.087280, 1178.869628, -1622.087280, 1410.869628)){LeftArea();}
- }
- else if(Zone9Atack == 1){
- GangZoneFlashForAll(Zone9,FlashColor);
- if(!IsPlayerInArea(i,-2213.718750, 710.110534, -1949.718750, 982.110534)){LeftArea();}
- }
- else if(Zone10Atack == 1){
- GangZoneFlashForAll(Zone10,FlashColor);
- if(!IsPlayerInArea(i,-2765.796386, 784.332397, -2437.796386, 1104.332397)){LeftArea();}
- }
- else if(Zone11Atack == 1){
- GangZoneFlashForAll(Zone11,FlashColor);
- if(!IsPlayerInArea(i,-1922.631958, -28.333175, -1706.631958, 403.666809)){LeftArea();}
- }
- else if(Zone12Atack == 1){
- GangZoneFlashForAll(Zone12,FlashColor);
- if(!IsPlayerInArea(i,-1957.691406, -758.583618, -1645.691406, -430.5836182)){LeftArea();}
- }
- else if(Zone13Atack == 1){
- GangZoneFlashForAll(Zone13,FlashColor);
- if(!IsPlayerInArea(i,-2518.000000, -602.239868, -2246.000000, -306.239868)){LeftArea();}
- }
- }
- if(GetPlayerState(i) == PLAYER_STATE_WASTED)
- {
- return
- SendClientMessageToAll(COLOR_ORANGE,"|______MAFIA-WAR-NEWS______|"),
- format(string, sizeof(string),"%s failed because he died in the Mafia-War",name),
- SendClientMessageToAll(COLOR_ORANGE,string),
- SendClientMessage(i,COLOR_RED,"You died in the Mafia-War..."),
- LooseWar(),
- PlayerAtacker[i] = 0,
- TakeOverTime = 0,
- KillTimer(ZoneTimer1);
- }
- else if(TakeOverTime > 180)
- {
- return
- SendClientMessageToAll(COLOR_ORANGE,"|______MAFIA-WAR-NEWS______|"),
- format(string, sizeof(string),"%s and his team have won the Mafia-War",name),
- SendClientMessageToAll(COLOR_ORANGE,string),
- SendClientMessage(i,COLOR_GREEN,"You have sucsessfull taken the Zone +5000$"),
- GivePlayerMoney(i,4000),
- WonMessage(),
- PlayerAtacker[i] = 0,
- TakeOverTime = 0,
- KillTimer(ZoneTimer1);
- }
- }
- }
- }
- return 1;
- }
- forward LeftArea();
- public LeftArea()
- {
- for(new i=0; i<MAX_PLAYERS; i++)
- {
- if(IsPlayerConnected(i))
- {
- if(PlayerAtacker[i]== 1)
- {
- new name[MAX_PLAYER_NAME],string[128];
- GetPlayerName(i,name,sizeof(name));
- return
- SendClientMessageToAll(COLOR_ORANGE,"|______MAFIA-WAR-NEWS______|"),
- format(string, sizeof(string),"%s failed because he left the Mafia-War",name),
- SendClientMessageToAll(COLOR_ORANGE,string),
- SendClientMessage(i,COLOR_RED,"You have left the zone...fail!"),
- LooseWar(),
- PlayerAtacker[i] = 0,
- TakeOverTime = 0,
- KillTimer(ZoneTimer1);
- }
- }
- }
- return 1;
- }
- forward WonMessage();
- public WonMessage()
- {
- for(new i=0; i<MAX_PLAYERS; i++)
- {
- if(IsPlayerConnected(i))
- {
- if(PlayerAtacker[i]== 1)
- {
- if(Gang[i] == TEAM_LCN){SendLcnMessage(COLOR_GREEN,"We won have won a Mafia-War every member gets 1000$!");GiveLcnMoney(1000); }
- else if(Gang[i] == TEAM_RUS){SendRusMessage(COLOR_GREEN,"We won have won a Mafia-War every member gets 1000$!");GiveRusMoney(1000); }
- else if(Gang[i] == TEAM_TRIADS){SendTriadMessage(COLOR_GREEN,"We won have won a Mafia-War every member gets 1000$!");GiveTriadMoney(1000); }
- else if(Gang[i] == TEAM_YUGO){SendYugoMessage(COLOR_GREEN,"We won have won a Mafia-War every member gets 1000$!");GiveYugoMoney(1000); }
- else if(Gang[i] == TEAM_GERMAN){SendGermanMessage(COLOR_GREEN,"We won have won a Mafia-War every member gets 1000$!");GiveGermanMoney(1000); }
- else if(Gang[i] == TEAM_CUBAN){SendCubanMessage(COLOR_GREEN,"We won have won a Mafia-War every member gets 1000$!");GiveCubanMoney(1000); }
- new color = GetPlayerColor(i);
- if(Zone1Atack == 1)
- {
- dini_IntSet("/zones/zones.ini", "Zone1",color);
- GangZoneStopFlashForAll(Zone1);
- GangZoneShowForAll(Zone1,color);
- Zone1Atack = 0;
- }
- else if(Zone2Atack == 1)
- {
- dini_IntSet("/zones/zones.ini", "Zone2",color);
- GangZoneStopFlashForAll(Zone1);
- GangZoneShowForAll(Zone2,color);
- Zone2Atack = 0;
- }
- else if(Zone3Atack == 1)
- {
- dini_IntSet("/zones/zones.ini", "Zone3",color);
- GangZoneStopFlashForAll(Zone1);
- GangZoneShowForAll(Zone3,color);
- Zone3Atack = 0;
- }
- else if(Zone4Atack == 1)
- {
- dini_IntSet("/zones/zones.ini", "Zone4",color);
- GangZoneStopFlashForAll(Zone1);
- GangZoneShowForAll(Zone4,color);
- Zone4Atack = 0;
- }
- else if(Zone5Atack == 1)
- {
- dini_IntSet("/zones/zones.ini", "Zone5",color);
- GangZoneStopFlashForAll(Zone1);
- GangZoneShowForAll(Zone5,color);
- Zone5Atack = 0;
- }
- else if(Zone6Atack == 1)
- {
- dini_IntSet("/zones/zones.ini", "Zone6",color);
- GangZoneStopFlashForAll(Zone1);
- GangZoneShowForAll(Zone6,color);
- Zone1Atack = 0;
- }
- else if(Zone7Atack == 1)
- {
- dini_IntSet("/zones/zones.ini", "Zone7",color);
- GangZoneStopFlashForAll(Zone1);
- GangZoneShowForAll(Zone7,color);
- Zone7Atack = 0;
- }
- else if(Zone8Atack == 1)
- {
- dini_IntSet("/zones/zones.ini", "Zone8",color);
- GangZoneStopFlashForAll(Zone1);
- GangZoneShowForAll(Zone8,color);
- Zone8Atack = 0;
- }
- else if(Zone9Atack == 1)
- {
- dini_IntSet("/zones/zones.ini", "Zone9",color);
- GangZoneStopFlashForAll(Zone1);
- GangZoneShowForAll(Zone9,color);
- Zone9Atack = 0;
- }
- else if(Zone10Atack == 1)
- {
- dini_IntSet("/zones/zones.ini", "Zone10",color);
- GangZoneStopFlashForAll(Zone1);
- GangZoneShowForAll(Zone10,color);
- Zone10Atack = 0;
- }
- else if(Zone11Atack == 1)
- {
- dini_IntSet("/zones/zones.ini", "Zone11",color);
- GangZoneStopFlashForAll(Zone1);
- GangZoneShowForAll(Zone11,color);
- Zone11Atack = 0;
- }
- else if(Zone12Atack == 1)
- {
- dini_IntSet("/zones/zones.ini", "Zone12",color);
- GangZoneStopFlashForAll(Zone1);
- GangZoneShowForAll(Zone12,color);
- Zone12Atack = 0;
- }
- else if(Zone13Atack == 1)
- {
- dini_IntSet("/zones/zones.ini", "Zone13",color);
- GangZoneStopFlashForAll(Zone1);
- GangZoneShowForAll(Zone13,color);
- Zone13Atack = 0;
- }
- Enable = SetTimer("EnableAtack",1800000,1);
- }
- }
- }
- return 1;
- }
- forward LooseWar();
- public LooseWar()
- {
- if(Zone1Atack == 1)
- {
- new color = dini_Int("/zones/zones.ini","Zone1");
- GangZoneStopFlashForAll(Zone1);
- GangZoneShowForAll(Zone1,color);
- Zone1Atack = 0;
- }
- else if(Zone2Atack == 1)
- {
- GangZoneStopFlashForAll(Zone2);
- new color = dini_Int("/zones/zones.ini","Zone2");
- GangZoneShowForAll(Zone2,color);
- Zone2Atack = 0;
- }
- else if(Zone3Atack == 1)
- {
- GangZoneStopFlashForAll(Zone3);
- new color = dini_Int("/zones/zones.ini","Zone3");
- GangZoneShowForAll(Zone3,color);
- Zone3Atack = 0;
- }
- else if(Zone4Atack == 1)
- {
- GangZoneStopFlashForAll(Zone4);
- new color = dini_Int("/zones/zones.ini","Zone4");
- GangZoneShowForAll(Zone4,color);
- Zone4Atack = 0;
- }
- else if(Zone5Atack == 1)
- {
- GangZoneStopFlashForAll(Zone5);
- new color = dini_Int("/zones/zones.ini","Zone5");
- GangZoneShowForAll(Zone5,color);
- Zone5Atack = 0;
- }
- else if(Zone6Atack == 1)
- {
- GangZoneStopFlashForAll(Zone6);
- new color = dini_Int("/zones/zones.ini","Zone6");
- GangZoneShowForAll(Zone6,color);
- Zone1Atack = 0;
- }
- else if(Zone7Atack == 1)
- {
- GangZoneStopFlashForAll(Zone7);
- new color = dini_Int("/zones/zones.ini","Zone7");
- GangZoneShowForAll(Zone7,color);
- Zone7Atack = 0;
- }
- else if(Zone8Atack == 1)
- {
- GangZoneStopFlashForAll(Zone8);
- new color = dini_Int("/zones/zones.ini","Zone8");
- GangZoneShowForAll(Zone8,color);
- Zone8Atack = 0;
- }
- else if(Zone9Atack == 1)
- {
- GangZoneStopFlashForAll(Zone9);
- new color = dini_Int("/zones/zones.ini","Zone9");
- GangZoneShowForAll(Zone9,color);
- Zone9Atack = 0;
- }
- else if(Zone10Atack == 1)
- {
- GangZoneStopFlashForAll(Zone10);
- new color = dini_Int("/zones/zones.ini","Zone10");
- GangZoneShowForAll(Zone10,color);
- Zone10Atack = 0;
- }
- else if(Zone11Atack == 1)
- {
- GangZoneStopFlashForAll(Zone11);
- new color = dini_Int("/zones/zones.ini","Zone11");
- GangZoneShowForAll(Zone11,color);
- Zone11Atack = 0;
- }
- else if(Zone12Atack == 1)
- {
- GangZoneStopFlashForAll(Zone12);
- new color = dini_Int("/zones/zones.ini","Zone12");
- GangZoneShowForAll(Zone12,color);
- Zone12Atack = 0;
- }
- else if(Zone13Atack == 1)
- {
- GangZoneStopFlashForAll(Zone13);
- new color = dini_Int("/zones/zones.ini","Zone13");
- GangZoneShowForAll(Zone13,color);
- Zone13Atack = 0;
- }
- Enable = SetTimer("EnableAtack",1800000,1);
- return 1;
- }
- //RealTime
- public UpdateTime()
- {
- gettime(hour, minute);
- format(timestr,32,"%02d:%02d",hour,minute);
- TextDrawSetString(txtTimeDisp,timestr);
- SetWorldTime(hour);
- new x=0;
- while(x!=MAX_PLAYERS) {
- if(IsPlayerConnected(x) && GetPlayerState(x) != PLAYER_STATE_NONE) {
- SetPlayerTime(x,hour,minute);
- }
- x++;
- }
- }
- stock PlayerToSkinSelect(playerid)
- {
- ForceClassSelection(playerid);
- SetPlayerHealth(playerid,0);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement