rendered paste body//---------------------------------------------------------
// Server Script and Gamemode Homepage - www.gtarp.co.nr
// Well here it is, My first ever gamemode made all by me
// First of all i want to thank allan for /lock, and /unlock and driving school licences
// Also thank Whitestrom for /night and /day
// Must not forget Y_Less for Zones part of this
// And Finally [TuG]dragsta for the buissneses/orginisations
// If i Missed you then please post at http://forum.sa-mp.com/index.php?topic=18323.0
// I will add credit for any 1 i missed
// Thanks, Now enjoy my first ever script
//---------------------------------------------------------
#include <a_samp>
#include <float>
#include <dprop>
#include <dini>
#include <dudb>
#include <dutils>
#include <core>
#define COLOR_VIOLET 0x9955DEEE
#define COLOR_LIGHTRED 0xFF99AADD
#define COLOR_SEAGREEN 0x00EEADDF
#define COLOR_GRAYWHITE 0xEEEEFFC4
#define COLOR_LIGHTNEUTRALBLUE 0xabcdef66
#define COLOR_GREENISHGOLD 0xCCFFDD56
#define COLOR_LIGHTBLUEGREEN 0x0FFDD349
#define COLOR_NEUTRALBLUE 0xABCDEF01
#define COLOR_LIGHTCYAN 0xAAFFCC33
#define COLOR_LEMON 0xDDDD2357
#define COLOR_MEDIUMBLUE 0x63AFF00A
#define COLOR_NEUTRAL 0xABCDEF97
#define COLOR_BLACK 0x00000000
#define COLOR_NEUTRALGREEN 0x81CFAB00
#define COLOR_DARKGREEN 0x12900BBF
#define COLOR_LIGHTGREEN 0x24FF0AB9
#define COLOR_DARKBLUE 0x300FFAAB
#define COLOR_BLUEGREEN 0x46BBAA00
#define COLOR_PINK 0xFF66FFAA
#define COLOR_BLUE 0x0000BBAA
#define COLOR_LIGHTBLUE 0x33CCFFAA
#define COLOR_DARKRED 0x660000AA
#define COLOR_ORANGE 0xFF9900AA
#define COLOR_GREY 0xAFAFAFAA
#define COLOR_GREEN 0x33AA33AA
#define COLOR_RED 0xAA3333AA
#define COLOR_YELLOW 0xFFFF00AA
#define COLOR_WHITE 0xFFFFFFAA
#define COLOR_PURPLE 0x800080AA
#define COLOR_GRAD1 0xB4B5B7FF
#define COLOR_GRAD2 0xBFC0C2FF
#define COLOR_RED1 0xFF0000AA
#define TEAM_COP 1
#define TEAM_BISTRO 2
#define TEAM_TAXI 3
#define TEAM_DISCON 4
#define TEAM_PILOT 5
#define TEAM_DRIVER 6
#define TEAM_DRIVER2
new jailed[MAX_PLAYERS];
static gTeam[MAX_PLAYERS]; // Tracks the team assignment for each player
#define TEAM_CIV 0
#define TEAM_COP 1
#define TEAM_SECRETSERVICE 2
#define TEAM_BG 3
#define TEAM_CIV_COLOR 0xFFFFFFAA //white
#define TEAM_COP_COLOR 0x0000BBAA //blue
#define TEAM_PILOT_COLOR 0xAA3333AA //red
#define TEAM_TAXI_COLOR 0xFFFF00AA //yellow
#define TEAM_BG_COLOR 0xFF9900AA //orange
/*================
/back Cmd Define
================*/
static Float:posx = 0.0;
static Float:posy = 0.0;
static Float:posz = 0.0;
//Driving School Defines:
#pragma unused TimerDST
#define TooFast 0
#define TooSlow 1000
new File:DSchool;
/*Format: X,Y,Z,CheckpointSize*/
new Float:CPDSchoolData[24][4] =
{
{-2047.2,-83.0,34.8,3.0}, // DT1 and 24
{-2026.6925,-70.1228,34.8783,3.0}, // DT2
{-2004.7513,189.6104,27.2453,3.0}, // DT3
{-2005.5742,445.2907,34.7222,3.0}, // DT4
{-2004.9156,657.1252,41.4480,3.0}, // DT5
{-2003.5272,958.6751,45.0033,3.0}, // DT6
{-2002.3400,1074.9663,55.2773,3.0}, // DT7
{-2160.8247,1070.2000,55.2843,3.0},// DT8
{-2166.7864,1047.6621,55.3587,3.0},// DT9
{-2106.8022,1051.5979,55.2844,3.0}, // DT10
{-2015.2802,1051.7932,55.2764,3.0}, // DT11
{-2006.7701,1022.1216,54.4400,3.0}, // DT12
{-2009.5132,932.4048,45.0042,3.0},// DT13
{-2008.8276,749.4720,44.9973,3.0}, // DT14
{-2008.6039,657.2002,41.4607,3.0}, // DT15
{-2007.3783,557.6398,34.7220,3.0}, // DT16
{-2009.1946,291.6661,33.8823,3.0}, // DT17
{-2009.2443,148.1573,27.2452,3.0}, // DT18
{-2009.5765,78.9214,27.2453,3.0}, // DT19
{-2009.7845,34.7367,32.5174,3.0}, // DT20
{-2009.8560,-55.1156,34.8721,3.0}, // DT21
{-2033.1410,-68.0971,34.8788,3.0}, // DT22
{-2042.7212,-69.9372,35.0068,3.0}, // DT23
{-2047.2,-83.0,34.8,3.0} // DT1 and 24
};
new TimerCD,TimerDSTime;
new TimerDST;
new PID;
new DriverTakingTest;
new DSCP[MAX_PLAYERS];
main()
{
print("\n----------------------------------");
print(" San Andreas: Role Playing Server");
print("----------------------------------\n");
}
// ZONES
enum zoneinfo {
zone_name[27],
Float:zone_minx,
Float:zone_miny,
Float:zone_minz,
Float:zone_maxx,
Float:zone_maxy,
Float:zone_maxz
}
new Float:zones[][zoneinfo] = {
{ "'The Big Ear'", -410.00, 1403.30, -3.00, -137.90, 1681.20, 200.00},
{ "Aldea Malvada", -1372.10, 2498.50, 0.00, -1277.50, 2615.30, 200.00},
{ "Angel Pine", -2324.90, -2584.20, -6.10, -1964.20, -2212.10, 200.00},
{ "Arco del Oeste", -901.10, 2221.80, 0.00, -592.00, 2571.90, 200.00},
{ "Avispa Country Club", -2646.40, -355.40, 0.00, -2270.00, -222.50, 200.00},
{ "Avispa Country Club", -2831.80, -430.20, -6.10, -2646.40, -222.50, 200.00},
{ "Avispa Country Club", -2361.50, -417.10, 0.00, -2270.00, -355.40, 200.00},
{ "Avispa Country Club", -2667.80, -302.10, -28.80, -2646.40, -262.30, 71.10},
{ "Avispa Country Club", -2470.00, -355.40, 0.00, -2270.00, -318.40, 46.10},
{ "Avispa Country Club", -2550.00, -355.40, 0.00, -2470.00, -318.40, 39.70},
{ "Back o Beyond", -1166.90, -2641.10, 0.00, -321.70, -1856.00, 200.00},
{ "Battery Point", -2741.00, 1268.40, -4.50, -2533.00, 1490.40, 200.00},
{ "Bayside", -2741.00, 2175.10, 0.00, -2353.10, 2722.70, 200.00},
{ "Bayside Marina", -2353.10, 2275.70, 0.00, -2153.10, 2475.70, 200.00},
{ "Beacon Hill", -399.60, -1075.50, -1.40, -319.00, -977.50, 198.50},
{ "Blackfield", 964.30, 1203.20, -89.00, 1197.30, 1403.20, 110.90},
{ "Blackfield", 964.30, 1403.20, -89.00, 1197.30, 1726.20, 110.90},
{ "Blackfield Chapel", 1375.60, 596.30, -89.00, 1558.00, 823.20, 110.90},
{ "Blackfield Chapel", 1325.60, 596.30, -89.00, 1375.60, 795.00, 110.90},
{ "Blackfield Intersection", 1197.30, 1044.60, -89.00, 1277.00, 1163.30, 110.90},
{ "Blackfield Intersection", 1166.50, 795.00, -89.00, 1375.60, 1044.60, 110.90},
{ "Blackfield Intersection", 1277.00, 1044.60, -89.00, 1315.30, 1087.60, 110.90},
{ "Blackfield Intersection", 1375.60, 823.20, -89.00, 1457.30, 919.40, 110.90},
{ "Blueberry", 104.50, -220.10, 2.30, 349.60, 152.20, 200.00},
{ "Blueberry", 19.60, -404.10, 3.80, 349.60, -220.10, 200.00},
{ "Blueberry Acres", -319.60, -220.10, 0.00, 104.50, 293.30, 200.00},
{ "Caligula's Palace", 2087.30, 1543.20, -89.00, 2437.30, 1703.20, 110.90},
{ "Caligula's Palace", 2137.40, 1703.20, -89.00, 2437.30, 1783.20, 110.90},
{ "Calton Heights", -2274.10, 744.10, -6.10, -1982.30, 1358.90, 200.00},
{ "Chinatown", -2274.10, 578.30, -7.60, -2078.60, 744.10, 200.00},
{ "City Hall", -2867.80, 277.40, -9.10, -2593.40, 458.40, 200.00},
{ "Come-A-Lot", 2087.30, 943.20, -89.00, 2623.10, 1203.20, 110.90},
{ "Commerce", 1323.90, -1842.20, -89.00, 1701.90, -1722.20, 110.90},
{ "Commerce", 1323.90, -1722.20, -89.00, 1440.90, -1577.50, 110.90},
{ "Commerce", 1370.80, -1577.50, -89.00, 1463.90, -1384.90, 110.90},
{ "Commerce", 1463.90, -1577.50, -89.00, 1667.90, -1430.80, 110.90},
{ "Commerce", 1583.50, -1722.20, -89.00, 1758.90, -1577.50, 110.90},
{ "Commerce", 1667.90, -1577.50, -89.00, 1812.60, -1430.80, 110.90},
{ "Conference Center", 1046.10, -1804.20, -89.00, 1323.90, -1722.20, 110.90},
{ "Conference Center", 1073.20, -1842.20, -89.00, 1323.90, -1804.20, 110.90},
{ "Cranberry Station", -2007.80, 56.30, 0.00, -1922.00, 224.70, 100.00},
{ "Creek", 2749.90, 1937.20, -89.00, 2921.60, 2669.70, 110.90},
{ "Dillimore", 580.70, -674.80, -9.50, 861.00, -404.70, 200.00},
{ "Doherty", -2270.00, -324.10, -0.00, -1794.90, -222.50, 200.00},
{ "Doherty", -2173.00, -222.50, -0.00, -1794.90, 265.20, 200.00},
{ "Wangs", -1982.30, 744.10, -6.10, -1871.70, 1274.20, 200.00},
{ "Wangs", -1871.70, 1176.40, -4.50, -1620.30, 1274.20, 200.00},
{ "Wangs", -1700.00, 744.20, -6.10, -1580.00, 1176.50, 200.00},
{ "Wangs", -1580.00, 744.20, -6.10, -1499.80, 1025.90, 200.00},
{ "Wangs", -2078.60, 578.30, -7.60, -1499.80, 744.20, 200.00},
{ "Wangs", -1993.20, 265.20, -9.10, -1794.90, 578.30, 200.00},
{ "Downtown Los Santos", 1463.90, -1430.80, -89.00, 1724.70, -1290.80, 110.90},
{ "Downtown Los Santos", 1724.70, -1430.80, -89.00, 1812.60, -1250.90, 110.90},
{ "Downtown Los Santos", 1463.90, -1290.80, -89.00, 1724.70, -1150.80, 110.90},
{ "Downtown Los Santos", 1370.80, -1384.90, -89.00, 1463.90, -1170.80, 110.90},
{ "Downtown Los Santos", 1724.70, -1250.90, -89.00, 1812.60, -1150.80, 110.90},
{ "Downtown Los Santos", 1370.80, -1170.80, -89.00, 1463.90, -1130.80, 110.90},
{ "Downtown Los Santos", 1378.30, -1130.80, -89.00, 1463.90, -1026.30, 110.90},
{ "Downtown Los Santos", 1391.00, -1026.30, -89.00, 1463.90, -926.90, 110.90},
{ "Downtown Los Santos", 1507.50, -1385.20, 110.90, 1582.50, -1325.30, 335.90},
{ "East Beach", 2632.80, -1852.80, -89.00, 2959.30, -1668.10, 110.90},
{ "East Beach", 2632.80, -1668.10, -89.00, 2747.70, -1393.40, 110.90},
{ "East Beach", 2747.70, -1668.10, -89.00, 2959.30, -1498.60, 110.90},
{ "East Beach", 2747.70, -1498.60, -89.00, 2959.30, -1120.00, 110.90},
{ "East Los Santos", 2421.00, -1628.50, -89.00, 2632.80, -1454.30, 110.90},
{ "East Los Santos", 2222.50, -1628.50, -89.00, 2421.00, -1494.00, 110.90},
{ "East Los Santos", 2266.20, -1494.00, -89.00, 2381.60, -1372.00, 110.90},
{ "East Los Santos", 2381.60, -1494.00, -89.00, 2421.00, -1454.30, 110.90},
{ "East Los Santos", 2281.40, -1372.00, -89.00, 2381.60, -1135.00, 110.90},
{ "East Los Santos", 2381.60, -1454.30, -89.00, 2462.10, -1135.00, 110.90},
{ "East Los Santos", 2462.10, -1454.30, -89.00, 2581.70, -1135.00, 110.90},
{ "Easter Basin", -1794.90, 249.90, -9.10, -1242.90, 578.30, 200.00},
{ "Easter Basin", -1794.90, -50.00, -0.00, -1499.80, 249.90, 200.00},
{ "Easter Bay Airport", -1499.80, -50.00, -0.00, -1242.90, 249.90, 200.00},
{ "Easter Bay Airport", -1794.90, -730.10, -3.00, -1213.90, -50.00, 200.00},
{ "Easter Bay Airport", -1213.90, -730.10, 0.00, -1132.80, -50.00, 200.00},
{ "Easter Bay Airport", -1242.90, -50.00, 0.00, -1213.90, 578.30, 200.00},
{ "Easter Bay Airport", -1213.90, -50.00, -4.50, -947.90, 578.30, 200.00},
{ "Easter Bay Airport", -1315.40, -405.30, 15.40, -1264.40, -209.50, 25.40},
{ "Easter Bay Airport", -1354.30, -287.30, 15.40, -1315.40, -209.50, 25.40},
{ "Easter Bay Airport", -1490.30, -209.50, 15.40, -1264.40, -148.30, 25.40},
{ "Easter Bay Chemicals", -1132.80, -768.00, 0.00, -956.40, -578.10, 200.00},
{ "Easter Bay Chemicals", -1132.80, -787.30, 0.00, -956.40, -768.00, 200.00},
{ "El Castillo del Diablo", -464.50, 2217.60, 0.00, -208.50, 2580.30, 200.00},
{ "El Castillo del Diablo", -208.50, 2123.00, -7.60, 114.00, 2337.10, 200.00},
{ "El Castillo del Diablo", -208.50, 2337.10, 0.00, 8.40, 2487.10, 200.00},
{ "El Corona", 1812.60, -2179.20, -89.00, 1970.60, -1852.80, 110.90},
{ "El Corona", 1692.60, -2179.20, -89.00, 1812.60, -1842.20, 110.90},
{ "El Quebrados", -1645.20, 2498.50, 0.00, -1372.10, 2777.80, 200.00},
{ "Esplanade East", -1620.30, 1176.50, -4.50, -1580.00, 1274.20, 200.00},
{ "Esplanade East", -1580.00, 1025.90, -6.10, -1499.80, 1274.20, 200.00},
{ "Esplanade East", -1499.80, 578.30, -79.60, -1339.80, 1274.20, 20.30},
{ "Esplanade North", -2533.00, 1358.90, -4.50, -1996.60, 1501.20, 200.00},
{ "Esplanade North", -1996.60, 1358.90, -4.50, -1524.20, 1592.50, 200.00},
{ "Esplanade North", -1982.30, 1274.20, -4.50, -1524.20, 1358.90, 200.00},
{ "Fallen Tree", -792.20, -698.50, -5.30, -452.40, -380.00, 200.00},
{ "Fallow Bridge", 434.30, 366.50, 0.00, 603.00, 555.60, 200.00},
{ "Fern Ridge", 508.10, -139.20, 0.00, 1306.60, 119.50, 200.00},
{ "Financial", -1871.70, 744.10, -6.10, -1701.30, 1176.40, 300.00},
{ "Fisher's Lagoon", 1916.90, -233.30, -100.00, 2131.70, 13.80, 200.00},
{ "Flint Intersection", -187.70, -1596.70, -89.00, 17.00, -1276.60, 110.90},
{ "Flint Range", -594.10, -1648.50, 0.00, -187.70, -1276.60, 200.00},
{ "Fort Carson", -376.20, 826.30, -3.00, 123.70, 1220.40, 200.00},
{ "Foster Valley", -2270.00, -430.20, -0.00, -2178.60, -324.10, 200.00},
{ "Foster Valley", -2178.60, -599.80, -0.00, -1794.90, -324.10, 200.00},
{ "Foster Valley", -2178.60, -1115.50, 0.00, -1794.90, -599.80, 200.00},
{ "Foster Valley", -2178.60, -1250.90, 0.00, -1794.90, -1115.50, 200.00},
{ "Frederick Bridge", 2759.20, 296.50, 0.00, 2774.20, 594.70, 200.00},
{ "Gant Bridge", -2741.40, 1659.60, -6.10, -2616.40, 2175.10, 200.00},
{ "Gant Bridge", -2741.00, 1490.40, -6.10, -2616.40, 1659.60, 200.00},
{ "Ganton", 2222.50, -1852.80, -89.00, 2632.80, -1722.30, 110.90},
{ "Ganton", 2222.50, -1722.30, -89.00, 2632.80, -1628.50, 110.90},
{ "Garcia", -2411.20, -222.50, -0.00, -2173.00, 265.20, 200.00},
{ "Garcia", -2395.10, -222.50, -5.30, -2354.00, -204.70, 200.00},
{ "Garver Bridge", -1339.80, 828.10, -89.00, -1213.90, 1057.00, 110.90},
{ "Garver Bridge", -1213.90, 950.00, -89.00, -1087.90, 1178.90, 110.90},
{ "Garver Bridge", -1499.80, 696.40, -179.60, -1339.80, 925.30, 20.30},
{ "Glen Park", 1812.60, -1449.60, -89.00, 1996.90, -1350.70, 110.90},
{ "Glen Park", 1812.60, -1100.80, -89.00, 1994.30, -973.30, 110.90},
{ "Glen Park", 1812.60, -1350.70, -89.00, 2056.80, -1100.80, 110.90},
{ "Green Palms", 176.50, 1305.40, -3.00, 338.60, 1520.70, 200.00},
{ "Greenglass College", 964.30, 1044.60, -89.00, 1197.30, 1203.20, 110.90},
{ "Greenglass College", 964.30, 930.80, -89.00, 1166.50, 1044.60, 110.90},
{ "Hampton Barns", 603.00, 264.30, 0.00, 761.90, 366.50, 200.00},
{ "Hankypanky Point", 2576.90, 62.10, 0.00, 2759.20, 385.50, 200.00},
{ "Harry Gold Parkway", 1777.30, 863.20, -89.00, 1817.30, 2342.80, 110.90},
{ "Hashbury", -2593.40, -222.50, -0.00, -2411.20, 54.70, 200.00},
{ "Hilltop Farm", 967.30, -450.30, -3.00, 1176.70, -217.90, 200.00},
{ "Hunter Quarry", 337.20, 710.80, -115.20, 860.50, 1031.70, 203.70},
{ "Idlewood", 1812.60, -1852.80, -89.00, 1971.60, -1742.30, 110.90},
{ "Idlewood", 1812.60, -1742.30, -89.00, 1951.60, -1602.30, 110.90},
{ "Idlewood", 1951.60, -1742.30, -89.00, 2124.60, -1602.30, 110.90},
{ "Idlewood", 1812.60, -1602.30, -89.00, 2124.60, -1449.60, 110.90},
{ "Idlewood", 2124.60, -1742.30, -89.00, 2222.50, -1494.00, 110.90},
{ "Idlewood", 1971.60, -1852.80, -89.00, 2222.50, -1742.30, 110.90},
{ "Jefferson", 1996.90, -1449.60, -89.00, 2056.80, -1350.70, 110.90},
{ "Jefferson", 2124.60, -1494.00, -89.00, 2266.20, -1449.60, 110.90},
{ "Jefferson", 2056.80, -1372.00, -89.00, 2281.40, -1210.70, 110.90},
{ "Jefferson", 2056.80, -1210.70, -89.00, 2185.30, -1126.30, 110.90},
{ "Jefferson", 2185.30, -1210.70, -89.00, 2281.40, -1154.50, 110.90},
{ "Jefferson", 2056.80, -1449.60, -89.00, 2266.20, -1372.00, 110.90},
{ "Julius Thruway East", 2623.10, 943.20, -89.00, 2749.90, 1055.90, 110.90},
{ "Julius Thruway East", 2685.10, 1055.90, -89.00, 2749.90, 2626.50, 110.90},
{ "Julius Thruway East", 2536.40, 2442.50, -89.00, 2685.10, 2542.50, 110.90},
{ "Julius Thruway East", 2625.10, 2202.70, -89.00, 2685.10, 2442.50, 110.90},
{ "Julius Thruway North", 2498.20, 2542.50, -89.00, 2685.10, 2626.50, 110.90},
{ "Julius Thruway North", 2237.40, 2542.50, -89.00, 2498.20, 2663.10, 110.90},
{ "Julius Thruway North", 2121.40, 2508.20, -89.00, 2237.40, 2663.10, 110.90},
{ "Julius Thruway North", 1938.80, 2508.20, -89.00, 2121.40, 2624.20, 110.90},
{ "Julius Thruway North", 1534.50, 2433.20, -89.00, 1848.40, 2583.20, 110.90},
{ "Julius Thruway North", 1848.40, 2478.40, -89.00, 1938.80, 2553.40, 110.90},
{ "Julius Thruway North", 1704.50, 2342.80, -89.00, 1848.40, 2433.20, 110.90},
{ "Julius Thruway North", 1377.30, 2433.20, -89.00, 1534.50, 2507.20, 110.90},
{ "Julius Thruway South", 1457.30, 823.20, -89.00, 2377.30, 863.20, 110.90},
{ "Julius Thruway South", 2377.30, 788.80, -89.00, 2537.30, 897.90, 110.90},
{ "Julius Thruway West", 1197.30, 1163.30, -89.00, 1236.60, 2243.20, 110.90},
{ "Julius Thruway West", 1236.60, 2142.80, -89.00, 1297.40, 2243.20, 110.90},
{ "Juniper Hill", -2533.00, 578.30, -7.60, -2274.10, 968.30, 200.00},
{ "Juniper Hollow", -2533.00, 968.30, -6.10, -2274.10, 1358.90, 200.00},
{ "K.A.C.C. Military Fuels", 2498.20, 2626.50, -89.00, 2749.90, 2861.50, 110.90},
{ "Kincaid Bridge", -1339.80, 599.20, -89.00, -1213.90, 828.10, 110.90},
{ "Kincaid Bridge", -1213.90, 721.10, -89.00, -1087.90, 950.00, 110.90},
{ "Kincaid Bridge", -1087.90, 855.30, -89.00, -961.90, 986.20, 110.90},
{ "Wangs", -2329.30, 458.40, -7.60, -1993.20, 578.30, 200.00},
{ "Wangs", -2411.20, 265.20, -9.10, -1993.20, 373.50, 200.00},
{ "Wangs", -2253.50, 373.50, -9.10, -1993.20, 458.40, 200.00},
{ "LVA Freight Depot", 1457.30, 863.20, -89.00, 1777.40, 1143.20, 110.90},
{ "LVA Freight Depot", 1375.60, 919.40, -89.00, 1457.30, 1203.20, 110.90},
{ "LVA Freight Depot", 1277.00, 1087.60, -89.00, 1375.60, 1203.20, 110.90},
{ "LVA Freight Depot", 1315.30, 1044.60, -89.00, 1375.60, 1087.60, 110.90},
{ "LVA Freight Depot", 1236.60, 1163.40, -89.00, 1277.00, 1203.20, 110.90},
{ "Las Barrancas", -926.10, 1398.70, -3.00, -719.20, 1634.60, 200.00},
{ "Las Brujas", -365.10, 2123.00, -3.00, -208.50, 2217.60, 200.00},
{ "Las Colinas", 1994.30, -1100.80, -89.00, 2056.80, -920.80, 110.90},
{ "Las Colinas", 2056.80, -1126.30, -89.00, 2126.80, -920.80, 110.90},
{ "Las Colinas", 2185.30, -1154.50, -89.00, 2281.40, -934.40, 110.90},
{ "Las Colinas", 2126.80, -1126.30, -89.00, 2185.30, -934.40, 110.90},
{ "Las Colinas", 2747.70, -1120.00, -89.00, 2959.30, -945.00, 110.90},
{ "Las Colinas", 2632.70, -1135.00, -89.00, 2747.70, -945.00, 110.90},
{ "Las Colinas", 2281.40, -1135.00, -89.00, 2632.70, -945.00, 110.90},
{ "Las Payasadas", -354.30, 2580.30, 2.00, -133.60, 2816.80, 200.00},
{ "Las Venturas Airport", 1236.60, 1203.20, -89.00, 1457.30, 1883.10, 110.90},
{ "Las Venturas Airport", 1457.30, 1203.20, -89.00, 1777.30, 1883.10, 110.90},
{ "Las Venturas Airport", 1457.30, 1143.20, -89.00, 1777.40, 1203.20, 110.90},
{ "Las Venturas Airport", 1515.80, 1586.40, -12.50, 1729.90, 1714.50, 87.50},
{ "Last Dime Motel", 1823.00, 596.30, -89.00, 1997.20, 823.20, 110.90},
{ "Leafy Hollow", -1166.90, -1856.00, 0.00, -815.60, -1602.00, 200.00},
{ "Lil' Probe Inn", -90.20, 1286.80, -3.00, 153.80, 1554.10, 200.00},
{ "Linden Side", 2749.90, 943.20, -89.00, 2923.30, 1198.90, 110.90},
{ "Linden Station", 2749.90, 1198.90, -89.00, 2923.30, 1548.90, 110.90},
{ "Linden Station", 2811.20, 1229.50, -39.50, 2861.20, 1407.50, 60.40},
{ "Little Mexico", 1701.90, -1842.20, -89.00, 1812.60, -1722.20, 110.90},
{ "Little Mexico", 1758.90, -1722.20, -89.00, 1812.60, -1577.50, 110.90},
{ "Los Flores", 2581.70, -1454.30, -89.00, 2632.80, -1393.40, 110.90},
{ "Los Flores", 2581.70, -1393.40, -89.00, 2747.70, -1135.00, 110.90},
{ "Los Santos International", 1249.60, -2394.30, -89.00, 1852.00, -2179.20, 110.90},
{ "Los Santos International", 1852.00, -2394.30, -89.00, 2089.00, -2179.20, 110.90},
{ "Los Santos International", 1382.70, -2730.80, -89.00, 2201.80, -2394.30, 110.90},
{ "Los Santos International", 1974.60, -2394.30, -39.00, 2089.00, -2256.50, 60.90},
{ "Los Santos International", 1400.90, -2669.20, -39.00, 2189.80, -2597.20, 60.90},
{ "Los Santos International", 2051.60, -2597.20, -39.00, 2152.40, -2394.30, 60.90},
{ "Marina", 647.70, -1804.20, -89.00, 851.40, -1577.50, 110.90},
{ "Marina", 647.70, -1577.50, -89.00, 807.90, -1416.20, 110.90},
{ "Marina", 807.90, -1577.50, -89.00, 926.90, -1416.20, 110.90},
{ "Taxi HQ", 787.40, -1416.20, -89.00, 1072.60, -1310.20, 110.90},
{ "Taxi HQ", 952.60, -1310.20, -89.00, 1072.60, -1130.80, 110.90},
{ "Taxi HQ", 1072.60, -1416.20, -89.00, 1370.80, -1130.80, 110.90},
{ "Taxi HQ", 926.90, -1577.50, -89.00, 1370.80, -1416.20, 110.90},
{ "Market Station", 787.40, -1410.90, -34.10, 866.00, -1310.20, 65.80},
{ "Martin Bridge", -222.10, 293.30, 0.00, -122.10, 476.40, 200.00},
{ "Missionary Hill", -2994.40, -811.20, 0.00, -2178.60, -430.20, 200.00},
{ "Montgomery", 1119.50, 119.50, -3.00, 1451.40, 493.30, 200.00},
{ "Montgomery", 1451.40, 347.40, -6.10, 1582.40, 420.80, 200.00},
{ "Montgomery Intersection", 1546.60, 208.10, 0.00, 1745.80, 347.40, 200.00},
{ "Montgomery Intersection", 1582.40, 347.40, 0.00, 1664.60, 401.70, 200.00},
{ "Mulholland", 1414.00, -768.00, -89.00, 1667.60, -452.40, 110.90},
{ "Mulholland", 1281.10, -452.40, -89.00, 1641.10, -290.90, 110.90},
{ "Mulholland", 1269.10, -768.00, -89.00, 1414.00, -452.40, 110.90},
{ "Mulholland", 1357.00, -926.90, -89.00, 1463.90, -768.00, 110.90},
{ "Mulholland", 1318.10, -910.10, -89.00, 1357.00, -768.00, 110.90},
{ "Mulholland", 1169.10, -910.10, -89.00, 1318.10, -768.00, 110.90},
{ "Mulholland", 768.60, -954.60, -89.00, 952.60, -860.60, 110.90},
{ "Mulholland", 687.80, -860.60, -89.00, 911.80, -768.00, 110.90},
{ "Mulholland", 737.50, -768.00, -89.00, 1142.20, -674.80, 110.90},
{ "Mulholland", 1096.40, -910.10, -89.00, 1169.10, -768.00, 110.90},
{ "Mulholland", 952.60, -937.10, -89.00, 1096.40, -860.60, 110.90},
{ "Mulholland", 911.80, -860.60, -89.00, 1096.40, -768.00, 110.90},
{ "Mulholland", 861.00, -674.80, -89.00, 1156.50, -600.80, 110.90},
{ "Mulholland Intersection", 1463.90, -1150.80, -89.00, 1812.60, -768.00, 110.90},
{ "North Rock", 2285.30, -768.00, 0.00, 2770.50, -269.70, 200.00},
{ "Ocean Docks", 2373.70, -2697.00, -89.00, 2809.20, -2330.40, 110.90},
{ "Ocean Docks", 2201.80, -2418.30, -89.00, 2324.00, -2095.00, 110.90},
{ "Ocean Docks", 2324.00, -2302.30, -89.00, 2703.50, -2145.10, 110.90},
{ "Ocean Docks", 2089.00, -2394.30, -89.00, 2201.80, -2235.80, 110.90},
{ "Ocean Docks", 2201.80, -2730.80, -89.00, 2324.00, -2418.30, 110.90},
{ "Ocean Docks", 2703.50, -2302.30, -89.00, 2959.30, -2126.90, 110.90},
{ "Ocean Docks", 2324.00, -2145.10, -89.00, 2703.50, -2059.20, 110.90},
{ "Ocean Flats", -2994.40, 277.40, -9.10, -2867.80, 458.40, 200.00},
{ "Ocean Flats", -2994.40, -222.50, -0.00, -2593.40, 277.40, 200.00},
{ "Ocean Flats", -2994.40, -430.20, -0.00, -2831.80, -222.50, 200.00},
{ "Octane Springs", 338.60, 1228.50, 0.00, 664.30, 1655.00, 200.00},
{ "Old Venturas Strip", 2162.30, 2012.10, -89.00, 2685.10, 2202.70, 110.90},
{ "Palisades", -2994.40, 458.40, -6.10, -2741.00, 1339.60, 200.00},
{ "Palomino Creek", 2160.20, -149.00, 0.00, 2576.90, 228.30, 200.00},
{ "Paradiso", -2741.00, 793.40, -6.10, -2533.00, 1268.40, 200.00},
{ "Pershing Square", 1440.90, -1722.20, -89.00, 1583.50, -1577.50, 110.90},
{ "Pilgrim", 2437.30, 1383.20, -89.00, 2624.40, 1783.20, 110.90},
{ "Pilgrim", 2624.40, 1383.20, -89.00, 2685.10, 1783.20, 110.90},
{ "Pilson Intersection", 1098.30, 2243.20, -89.00, 1377.30, 2507.20, 110.90},
{ "Pirates in Men's Pants", 1817.30, 1469.20, -89.00, 2027.40, 1703.20, 110.90},
{ "Playa del Seville", 2703.50, -2126.90, -89.00, 2959.30, -1852.80, 110.90},
{ "Prickle Pine", 1534.50, 2583.20, -89.00, 1848.40, 2863.20, 110.90},
{ "Prickle Pine", 1117.40, 2507.20, -89.00, 1534.50, 2723.20, 110.90},
{ "Prickle Pine", 1848.40, 2553.40, -89.00, 1938.80, 2863.20, 110.90},
{ "Prickle Pine", 1938.80, 2624.20, -89.00, 2121.40, 2861.50, 110.90},
{ "Queens", -2533.00, 458.40, 0.00, -2329.30, 578.30, 200.00},
{ "Queens", -2593.40, 54.70, 0.00, -2411.20, 458.40, 200.00},
{ "Queens", -2411.20, 373.50, 0.00, -2253.50, 458.40, 200.00},
{ "Randolph Industrial Estate", 1558.00, 596.30, -89.00, 1823.00, 823.20, 110.90},
{ "Redsands East", 1817.30, 2011.80, -89.00, 2106.70, 2202.70, 110.90},
{ "Redsands East", 1817.30, 2202.70, -89.00, 2011.90, 2342.80, 110.90},
{ "Redsands East", 1848.40, 2342.80, -89.00, 2011.90, 2478.40, 110.90},
{ "Redsands West", 1236.60, 1883.10, -89.00, 1777.30, 2142.80, 110.90},
{ "Redsands West", 1297.40, 2142.80, -89.00, 1777.30, 2243.20, 110.90},
{ "Redsands West", 1377.30, 2243.20, -89.00, 1704.50, 2433.20, 110.90},
{ "Redsands West", 1704.50, 2243.20, -89.00, 1777.30, 2342.80, 110.90},
{ "Regular Tom", -405.70, 1712.80, -3.00, -276.70, 1892.70, 200.00},
{ "Richman", 647.50, -1118.20, -89.00, 787.40, -954.60, 110.90},
{ "Richman", 647.50, -954.60, -89.00, 768.60, -860.60, 110.90},
{ "Richman", 225.10, -1369.60, -89.00, 334.50, -1292.00, 110.90},
{ "Richman", 225.10, -1292.00, -89.00, 466.20, -1235.00, 110.90},
{ "Richman", 72.60, -1404.90, -89.00, 225.10, -1235.00, 110.90},
{ "Richman", 72.60, -1235.00, -89.00, 321.30, -1008.10, 110.90},
{ "Richman", 321.30, -1235.00, -89.00, 647.50, -1044.00, 110.90},
{ "Richman", 321.30, -1044.00, -89.00, 647.50, -860.60, 110.90},
{ "Richman", 321.30, -860.60, -89.00, 687.80, -768.00, 110.90},
{ "Richman", 321.30, -768.00, -89.00, 700.70, -674.80, 110.90},
{ "Robada Intersection", -1119.00, 1178.90, -89.00, -862.00, 1351.40, 110.90},
{ "Cop HQ", 2237.40, 2202.70, -89.00, 2536.40, 2542.50, 110.90},
{ "Cop HQ", 2536.40, 2202.70, -89.00, 2625.10, 2442.50, 110.90},
{ "Rockshore East", 2537.30, 676.50, -89.00, 2902.30, 943.20, 110.90},
{ "Rockshore West", 1997.20, 596.30, -89.00, 2377.30, 823.20, 110.90},
{ "Rockshore West", 2377.30, 596.30, -89.00, 2537.30, 788.80, 110.90},
{ "Rodeo", 72.60, -1684.60, -89.00, 225.10, -1544.10, 110.90},
{ "Rodeo", 72.60, -1544.10, -89.00, 225.10, -1404.90, 110.90},
{ "Rodeo", 225.10, -1684.60, -89.00, 312.80, -1501.90, 110.90},
{ "Rodeo", 225.10, -1501.90, -89.00, 334.50, -1369.60, 110.90},
{ "Rodeo", 334.50, -1501.90, -89.00, 422.60, -1406.00, 110.90},
{ "Rodeo", 312.80, -1684.60, -89.00, 422.60, -1501.90, 110.90},
{ "Rodeo", 422.60, -1684.60, -89.00, 558.00, -1570.20, 110.90},
{ "Rodeo", 558.00, -1684.60, -89.00, 647.50, -1384.90, 110.90},
{ "Rodeo", 466.20, -1570.20, -89.00, 558.00, -1385.00, 110.90},
{ "Rodeo", 422.60, -1570.20, -89.00, 466.20, -1406.00, 110.90},
{ "Rodeo", 466.20, -1385.00, -89.00, 647.50, -1235.00, 110.90},
{ "Rodeo", 334.50, -1406.00, -89.00, 466.20, -1292.00, 110.90},
{ "Royal Casino", 2087.30, 1383.20, -89.00, 2437.30, 1543.20, 110.90},
{ "San Andreas Sound", 2450.30, 385.50, -100.00, 2759.20, 562.30, 200.00},
{ "Santa Flora", -2741.00, 458.40, -7.60, -2533.00, 793.40, 200.00},
{ "Santa Maria Beach", 342.60, -2173.20, -89.00, 647.70, -1684.60, 110.90},
{ "Santa Maria Beach", 72.60, -2173.20, -89.00, 342.60, -1684.60, 110.90},
{ "Shady Cabin", -1632.80, -2263.40, -3.00, -1601.30, -2231.70, 200.00},
{ "Shady Creeks", -1820.60, -2643.60, -8.00, -1226.70, -1771.60, 200.00},
{ "Shady Creeks", -2030.10, -2174.80, -6.10, -1820.60, -1771.60, 200.00},
{ "Sobell Rail Yards", 2749.90, 1548.90, -89.00, 2923.30, 1937.20, 110.90},
{ "Spinybed", 2121.40, 2663.10, -89.00, 2498.20, 2861.50, 110.90},
{ "Starfish Casino", 2437.30, 1783.20, -89.00, 2685.10, 2012.10, 110.90},
{ "Starfish Casino", 2437.30, 1858.10, -39.00, 2495.00, 1970.80, 60.90},
{ "Starfish Casino", 2162.30, 1883.20, -89.00, 2437.30, 2012.10, 110.90},
{ "Temple", 1252.30, -1130.80, -89.00, 1378.30, -1026.30, 110.90},
{ "Temple", 1252.30, -1026.30, -89.00, 1391.00, -926.90, 110.90},
{ "Temple", 1252.30, -926.90, -89.00, 1357.00, -910.10, 110.90},
{ "Temple", 952.60, -1130.80, -89.00, 1096.40, -937.10, 110.90},
{ "Temple", 1096.40, -1130.80, -89.00, 1252.30, -1026.30, 110.90},
{ "Temple", 1096.40, -1026.30, -89.00, 1252.30, -910.10, 110.90},
{ "The Camel's Toe", 2087.30, 1203.20, -89.00, 2640.40, 1383.20, 110.90},
{ "The Clown's Pocket", 2162.30, 1783.20, -89.00, 2437.30, 1883.20, 110.90},
{ "The Emerald Isle", 2011.90, 2202.70, -89.00, 2237.40, 2508.20, 110.90},
{ "The Farm", -1209.60, -1317.10, 114.90, -908.10, -787.30, 251.90},
{ "The Four Dragons Casino", 1817.30, 863.20, -89.00, 2027.30, 1083.20, 110.90},
{ "The High Roller", 1817.30, 1283.20, -89.00, 2027.30, 1469.20, 110.90},
{ "The Mako Span", 1664.60, 401.70, 0.00, 1785.10, 567.20, 200.00},
{ "The Panopticon", -947.90, -304.30, -1.10, -319.60, 327.00, 200.00},
{ "The Pink Swan", 1817.30, 1083.20, -89.00, 2027.30, 1283.20, 110.90},
{ "The Sherman Dam", -968.70, 1929.40, -3.00, -481.10, 2155.20, 200.00},
{ "The Strip", 2027.40, 863.20, -89.00, 2087.30, 1703.20, 110.90},
{ "The Strip", 2106.70, 1863.20, -89.00, 2162.30, 2202.70, 110.90},
{ "The Strip", 2027.40, 1783.20, -89.00, 2162.30, 1863.20, 110.90},
{ "The Strip", 2027.40, 1703.20, -89.00, 2137.40, 1783.20, 110.90},
{ "The Visage", 1817.30, 1863.20, -89.00, 2106.70, 2011.80, 110.90},
{ "The Visage", 1817.30, 1703.20, -89.00, 2027.40, 1863.20, 110.90},
{ "Unity Station", 1692.60, -1971.80, -20.40, 1812.60, -1932.80, 79.50},
{ "Valle Ocultado", -936.60, 2611.40, 2.00, -715.90, 2847.90, 200.00},
{ "Verdant Bluffs", 930.20, -2488.40, -89.00, 1249.60, -2006.70, 110.90},
{ "Verdant Bluffs", 1073.20, -2006.70, -89.00, 1249.60, -1842.20, 110.90},
{ "Verdant Bluffs", 1249.60, -2179.20, -89.00, 1692.60, -1842.20, 110.90},
{ "Pilot HQ", 37.00, 2337.10, -3.00, 435.90, 2677.90, 200.00},
{ "Verona Beach", 647.70, -2173.20, -89.00, 930.20, -1804.20, 110.90},
{ "Verona Beach", 930.20, -2006.70, -89.00, 1073.20, -1804.20, 110.90},
{ "Verona Beach", 851.40, -1804.20, -89.00, 1046.10, -1577.50, 110.90},
{ "Verona Beach", 1161.50, -1722.20, -89.00, 1323.90, -1577.50, 110.90},
{ "Verona Beach", 1046.10, -1722.20, -89.00, 1161.50, -1577.50, 110.90},
{ "Vinewood", 787.40, -1310.20, -89.00, 952.60, -1130.80, 110.90},
{ "Vinewood", 787.40, -1130.80, -89.00, 952.60, -954.60, 110.90},
{ "Vinewood", 647.50, -1227.20, -89.00, 787.40, -1118.20, 110.90},
{ "Vinewood", 647.70, -1416.20, -89.00, 787.40, -1227.20, 110.90},
{ "Whitewood Estates", 883.30, 1726.20, -89.00, 1098.30, 2507.20, 110.90},
{ "Whitewood Estates", 1098.30, 1726.20, -89.00, 1197.30, 2243.20, 110.90},
{ "Willowfield", 1970.60, -2179.20, -89.00, 2089.00, -1852.80, 110.90},
{ "Willowfield", 2089.00, -2235.80, -89.00, 2201.80, -1989.90, 110.90},
{ "Willowfield", 2089.00, -1989.90, -89.00, 2324.00, -1852.80, 110.90},
{ "Willowfield", 2201.80, -2095.00, -89.00, 2324.00, -1989.90, 110.90},
{ "Willowfield", 2541.70, -1941.40, -89.00, 2703.50, -1852.80, 110.90},
{ "Willowfield", 2324.00, -2059.20, -89.00, 2541.70, -1852.80, 110.90},
{ "Willowfield", 2541.70, -2059.20, -89.00, 2703.50, -1941.40, 110.90},
{ "Yellow Bell Station", 1377.40, 2600.40, -21.90, 1492.40, 2687.30, 78.00},
// Main Zones
{ "Los Santos", 44.60, -2892.90, -242.90, 2997.00, -768.00, 900.00},
{ "Las Venturas", 869.40, 596.30, -242.90, 2997.00, 2993.80, 900.00},
{ "Admin Island", -480.50, 596.30, -242.90, 869.40, 2993.80, 900.00},
{ "Tierra Robada", -2997.40, 1659.60, -242.90, -480.50, 2993.80, 900.00},
{ "Tierra Robada", -1213.90, 596.30, -242.90, -480.50, 1659.60, 900.00},
{ "San Fierro", -2997.40, -1115.50, -242.90, -1213.90, 1659.60, 900.00},
{ "Red County", -1213.90, -768.00, -242.90, 2997.00, 596.30, 900.00},
{ "Flint County", -1213.90, -2892.90, -242.90, 44.60, -768.00, 900.00},
{ "Whetstone", -2997.40, -2892.90, -242.90, -1213.90, -1115.50, 900.00}};
new zoneupdates[MAX_PLAYERS];
new player_zone[MAX_PLAYERS];
new zoneupdate;
public update_zones() {
new line1[10];
new line2[10];
for(new i=0; i<MAX_PLAYERS; i++) {
if(IsPlayerConnected(i) && zoneupdates[i] == 1) {
if(IsPlayerInZone(i,player_zone[i])) { }
else {
new player_zone_before;
player_zone_before = player_zone[i];
player_zone[i] = -1;
for(new j=0; j<sizeof(zones);j++) {
if(IsPlayerInZone(i,j) && player_zone[i] == -1) {
if(player_zone_before == -1) GameTextForPlayer(i,zones[j][zone_name],1500,1);
else if(strcmp(zones[j][zone_name],zones[player_zone_before][zone_name],true) != 0) GameTextForPlayer(i,zones[j][zone_name],1500,1);
player_zone[i] = j;
format(line1,10,"p%dzone",i);
format(line2,10,"%d",j);
PropertySet(line1,line2);
}
}
if(player_zone[i] == -1) player_zone[i] = player_zone_before;
}
}
}
}
IsPlayerInZone(playerid, zoneid) {
if(zoneid == -1) return 0;
new Float:x, Float:y, Float:z;
GetPlayerPos(playerid,x,y,z);
if(x >= zones[zoneid][zone_minx] && x < zones[zoneid][zone_maxx]
&& y >= zones[zoneid][zone_miny] && y < zones[zoneid][zone_maxy]
&& z >= zones[zoneid][zone_minz] && z < zones[zoneid][zone_maxz]
&& z < 900.0) return 1;
return 0;
}
/*
public GetPlayerZone(playerid) {
new line[10];
format(line,10,"p%dzone",playerid);
new zoneid = strval(PropertyGet(line));
return zoneid;
}
*/
public OnGameModeInit()
{
SetGameModeText("Freeroam RPG by David_Tiger");
SetWorldTime(15);
ShowNameTags(1);
ShowPlayerMarkers(0);
SetTimer("AdminArea",250,1);
//civillians
AddPlayerClass(0,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(100,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(101,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(106,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(181,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(217,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(247,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(248,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(254,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(292,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(293,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(297,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(299,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
//secret rervice
AddPlayerClass(163,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(164,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(165,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(166,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // player spawn
//cops
AddPlayerClass(280,2295.0293,2459.4961,10.8203,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(281,2295.0293,2459.4961,10.8203,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(282,2295.0293,2459.4961,10.8203,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(283,2295.0293,2459.4961,10.8203,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(284,2295.0293,2459.4961,10.8203,98.9467,0,0,0,0,0,0); // player spawn
AddPlayerClass(288,2295.0293,2459.4961,10.8203,98.9467,0,0,0,0,0,0); // player spawn
//pilot
AddPlayerClass(61,414.4737,2532.6807,19.1484,98.9467,0,0,0,0,0,0); // pilot spawn
//taxi
AddPlayerClass(253,1101.1538,-1216.8552,17.8047,354.5516,0,0,0,0,0,0); // player spawn
AddPlayerClass(255,1101.1538,-1216.8552,17.8047,354.5516,0,0,0,0,0,0); // player spawn
//admin
AddPlayerClass(164,-1967.9170,294.1474,35.1719,98.9467,0,0,0,0,0,0); // ADMIN DAVID_TIGER
//cars lv
AddStaticVehicleEx(522,-1989.9324,274.3901,34.7471,269.6304,-1,-1,120); // nrg1
AddStaticVehicleEx(522,-1990.0535,269.8973,34.7399,260.0235,-1,-1,120); // nrg2
AddStaticVehicleEx(522,-1987.2076,300.8147,34.7413,79.0707,-1,-1,120); // nrg3
AddStaticVehicleEx(522,-1986.7488,306.6445,34.7492,82.9782,-1,-1,120); // nrg4
AddStaticVehicleEx(603,-1969.5558,305.6595,35.0101,180.8600,-1,-1,120); // phoenix
AddStaticVehicleEx(570,-1992.2002,242.3342,34.7367,270.0039,-1,-1,120); // patriot
AddStaticVehicleEx(542,2440.1167,1992.0309,10.5634,178.1650,-1,-1,120); // clover1
AddStaticVehicleEx(402,2490.9629,1992.0100,10.6521,3.2257,-1,-1,120); // buffalo1
AddStaticVehicleEx(482,2441.8877,2017.1289,10.9442,89.5066,-1,-1,120); // burrito1
AddStaticVehicleEx(468,2474.1323,2041.7799,10.7311,90.9242,-1,-1,120); // sanchez1
AddStaticVehicleEx(462,2516.9043,1444.7236,10.5033,281.6854,-1,-1,120); // faggio
AddStaticVehicleEx(542,2503.7634,1416.4042,10.5636,90.7507,-1,-1,120); // clover2
AddStaticVehicleEx(482,2503.4973,1419.5972,10.9363,88.4263,-1,-1,120); // burrito2
AddStaticVehicleEx(468,2451.0598,1430.9286,10.4970,245.3595,-1,-1,120); // sanchez2
AddStaticVehicleEx(468,1878.2520,2109.8489,10.7316,95.9723,-1,-1,120); // sanchez3
AddStaticVehicleEx(462,1911.0220,2088.6548,10.6613,18.6789,-1,-1,120); // faggio2
AddStaticVehicleEx(542,1907.2496,2105.4336,10.5641,90.7505,-1,-1,120); // clover3
AddStaticVehicleEx(482,1853.7372,2103.1135,10.9436,176.0086,-1,-1,120); // burrito3
AddStaticVehicleEx(602,1890.5381,1657.5551,9.9253,1.9391,-1,-1,120); // alpha1
AddStaticVehicleEx(481,1840.9409,1575.3737,8.6724,77.3734,-1,-1,120); // bmx1
AddStaticVehicleEx(468,1917.7131,1558.9285,10.4893,68.8209,-1,-1,120); // sanchez3
AddStaticVehicleEx(481,1877.6287,1572.2153,10.2636,266.5254,-1,-1,120); // bmx2
AddStaticVehicleEx(404,1867.4939,1588.1974,10.4691,91.4545,-1,-1,120); // perennial1
AddStaticVehicleEx(549,1831.9963,1466.8021,9.4686,86.8890,-1,-1,120); // tampa1
AddStaticVehicleEx(404,1189.6990,697.6075,9.7671,186.4321,-1,-1,120); // perennial2
AddStaticVehicleEx(509,1125.9105,747.8792,10.2625,72.7491,-1,-1,120); // bike1
AddStaticVehicleEx(510,1099.8079,775.3589,10.3473,93.4480,-1,-1,120); // mtb1
AddStaticVehicleEx(549,1200.3702,882.7040,12.2488,296.8070,-1,-1,120); // tampa1
AddStaticVehicleEx(476,991.4990,715.4919,13.8442,309.2903,-1,-1,120); // rustler1
AddStaticVehicleEx(554,1436.1705,677.6408,10.9087,149.0173,-1,-1,120); // yosemite1
AddStaticVehicleEx(404,1413.6185,777.9838,10.5514,89.6878,-1,-1,120); // perennial3
AddStaticVehicleEx(422,1541.4001,786.7277,10.8092,182.5127,-1,-1,120); // bobcat1
AddStaticVehicleEx(581,1493.7365,789.5236,10.6190,133.7390,-1,-1,120); // bf4001
AddStaticVehicleEx(468,1544.9095,680.4714,10.4969,78.1518,-1,-1,120); // sanchez1
AddStaticVehicleEx(549,2101.8308,940.7130,10.5169,267.9866,-1,-1,120); // tampa2
AddStaticVehicleEx(554,2076.8804,1089.1979,10.8270,353.5555,-1,-1,120); // yosemite2
AddStaticVehicleEx(404,2049.0476,1179.3359,10.4035,249.9666,-1,-1,120); // perennial3
AddStaticVehicleEx(422,2075.0215,1284.0444,10.6641,21.9327,-1,-1,120); // bobcat2
AddStaticVehicleEx(549,2039.7627,1388.3386,10.3694,182.2256,-1,-1,120); // tampa5
AddStaticVehicleEx(581,2075.4939,1540.8351,10.2531,359.2672,-1,-1,120); // bf4002
AddStaticVehicleEx(510,2038.9860,1686.7429,12.3246,3.9052,-1,-1,120); // mtb2
AddStaticVehicleEx(509,2119.3267,1786.8014,10.2547,311.0523,-1,-1,120); // bike2
AddStaticVehicleEx(468,2118.9019,1955.6251,10.3788,193.9026,-1,-1,120); // sanchez2
AddStaticVehicleEx(402,2184.9141,2004.7444,10.6521,271.7715,-1,-1,120); // buffalo3
AddStaticVehicleEx(603,2103.1541,2052.4468,10.6588,87.8080,-1,-1,120); // pheonix1
AddStaticVehicleEx(603,2119.2903,2204.8872,10.5093,180.0581,-1,-1,120); // pheonix2
AddStaticVehicleEx(402,2129.4326,2356.5083,10.5036,88.6166,-1,-1,120); // buffalo1
AddStaticVehicleEx(600,2139.3870,1408.8169,10.5749,178.3355,-1,-1,120); // picador1
AddStaticVehicleEx(554,2103.9907,1398.2170,10.9102,179.2315,-1,-1,120); // yosemite434
AddStaticVehicleEx(600,2352.0833,1423.3623,42.5291,270.1491,-1,-1,120); // picador4
AddStaticVehicleEx(603,2352.8667,1494.2738,42.6586,88.5006,-1,-1,120); // pheonix3
AddStaticVehicleEx(402,1581.3326,778.4402,10.6516,89.2942,-1,-1,120); // buffalosoemeoida
AddStaticVehicleEx(402,1942.0264,697.1700,10.6758,359.5399,-1,-1,120); // buffalo334
AddStaticVehicleEx(468,1909.2229,701.2566,10.8020,87.2436,-1,-1,120); // sanchez3
AddStaticVehicleEx(468,2085.3584,655.5243,11.0892,0.1447,-1,-1,120); // sanchez5
AddStaticVehicleEx(468,2269.1245,733.1391,11.1303,182.4752,-1,-1,120); // sanchez6
AddStaticVehicleEx(600,2405.4829,648.7670,10.9811,179.7621,-1,-1,120); // picador67
AddStaticVehicleEx(554,2610.4399,738.0954,10.9981,104.9980,-1,-1,120); // yosemite78
AddStaticVehicleEx(603,2782.0808,1294.2045,10.5881,179.9280,-1,-1,120); // pheonix1523
AddStaticVehicleEx(402,2805.4749,1348.5940,10.5817,88.8076,-1,-1,120); // buffalo93
AddStaticVehicleEx(602,2827.0627,2349.3438,10.6194,90.1497,-1,-1,120); // alpha1
AddStaticVehicleEx(603,2814.6199,2406.5295,10.6589,315.2202,-1,-1,120); // pheonix3r
AddStaticVehicleEx(554,2347.1802,2770.3794,10.9076,271.3507,-1,-1,120); // yosemite1
AddStaticVehicleEx(602,2190.4905,2787.0723,10.6548,181.7489,-1,-1,120); // alpha321
AddStaticVehicleEx(471,1964.7085,2754.5332,10.3028,188.9139,-1,-1,120); // quad1111
AddStaticVehicleEx(402,1547.9299,2665.2605,10.6593,5.3525,-1,-1,120); // buffalo1
AddStaticVehicleEx(603,1368.1654,2578.8425,10.6592,180.7460,-1,-1,120); // pheonix33411
AddStaticVehicleEx(471,1231.4731,2618.8186,10.3023,246.2279,-1,-1,120); // quad103948
AddStaticVehicleEx(600,989.5035,2178.6638,10.5395,181.2449,-1,-1,120); // picador1
AddStaticVehicleEx(496,993.3367,1982.6422,10.8501,224.1632,-1,-1,120); // blistacompact1324
AddStaticVehicleEx(581,1103.4470,1798.6262,10.4247,273.5026,-1,-1,120); // bf4001332
AddStaticVehicleEx(402,1032.8871,1062.8911,10.3482,178.3436,-1,-1,120); // buffalos102394u
AddStaticVehicleEx(400,-1973.0146,306.1925,35.0100,178.6679,-1,-1,120); // 1
AddStaticVehicleEx(402,-1976.6715,306.4128,35.0096,181.0471,-1,-1,120); // 2
AddStaticVehicleEx(411,-1989.7607,265.4881,35.0154,261.7554,-1,-1,120); // 4
AddStaticVehicleEx(415,-1989.4701,260.8035,35.0161,266.7193,-1,-1,120); // 5
AddStaticVehicleEx(424,-1990.8715,255.3794,35.0098,260.3663,-1,-1,120); // 6
AddStaticVehicleEx(451,-1991.1246,250.3146,35.0099,261.9730,-1,-1,120); // 8
AddStaticVehicleEx(470,-1991.8043,243.4530,35.0099,259.5751,-1,-1,120); // 9
AddStaticVehicleEx(434,-2020.2263,281.0631,33.5855,270.8403,-1,-1,120); // 10
AddStaticVehicleEx(402,1626.3939,1962.9758,10.6518,334.6588,-1,-1,120); // buffalo13098
AddStaticVehicleEx(462,1695.7133,2134.1992,10.5540,282.5669,-1,-1,120); // fagbike13
AddStaticVehicleEx(581,1514.6746,2259.0430,10.4101,229.0663,-1,-1,120); // bf400132
AddStaticVehicleEx(471,1705.0887,1447.8778,15.6158,20.7256,-1,-1,120); // quadbikezr1
AddStaticVehicleEx(478,1915.7882,2398.9534,10.8106,307.2623,-1,-1,120); // walton113
AddStaticVehicleEx(542,1880.1188,2160.4976,10.5614,25.2271,-1,-1,120); // clover134098
AddStaticVehicleEx(478,2188.8562,1857.3870,10.8175,260.7978,-1,-1,120); // waltoni1390
AddStaticVehicleEx(603,2433.1831,2148.7041,10.5115,249.5167,-1,-1,120); // pheonix029384
AddStaticVehicleEx(602,2627.1931,2206.5022,10.6260,3.1335,-1,-1,120); // alphagaicarlululu111oneone
AddStaticVehicleEx(542,2580.6221,2292.1536,12.9686,90.1052,-1,-1,120); // clover0101010
//cars waste
AddStaticVehicleEx(422,-2458.6104,2224.2869,4.8581,359.3479,-1,-1,120); // bobcat1
AddStaticVehicleEx(554,-2554.3030,2271.4404,5.1426,336.4141,-1,-1,120); // yosemite1
AddStaticVehicleEx(487,-2227.3813,2326.0244,7.7238,182.3384,-1,-1,120); // maverick1
AddStaticVehicleEx(581,-2473.3047,2509.6353,17.3664,187.2565,-1,-1,120); // bf4001
AddStaticVehicleEx(402,-2617.1125,2403.6682,11.8840,168.9047,-1,-1,120); // buffalo1
AddStaticVehicleEx(402,-1563.1969,2690.7749,55.5325,182.6249,-1,-1,120); // buffalo2
AddStaticVehicleEx(568,-1668.0374,2563.3652,85.0405,269.9609,-1,-1,120); // bandito1
AddStaticVehicleEx(404,-1525.4774,2524.9832,55.4985,0.5570,-1,-1,120); // perennial3
AddStaticVehicleEx(570,-1992.2002,242.3342,34.7367,270.0039,-1,-1,120); // patriot
AddStaticVehicleEx(403,-1925.2540,2358.6448,49.6511,293.4803,-1,-1,120); // linerunner1
AddStaticVehicleEx(403,-493.2936,1063.2283,11.6370,150.7722,-1,-1,120); // linerunner2
AddStaticVehicleEx(403,-176.4227,1216.9926,20.3476,269.1562,-1,-1,120); // linerunner3
AddStaticVehicleEx(468,113.3753,1048.0426,13.2784,180.1087,-1,-1,120); // sanchez1
AddStaticVehicleEx(518,102.0420,1078.1395,13.2804,182.4435,-1,-1,120); // buccaner2
AddStaticVehicleEx(470,239.6718,1885.3267,18.2071,98.7971,-1,-1,120); // admin patriot
AddStaticVehicleEx(470,239.2680,1878.2131,18.2919,93.8965,-1,-1,120); // pat 2
AddStaticVehicleEx(470,239.2086,1872.1827,18.2213,94.4569,-1,-1,120); // pat 3
AddStaticVehicleEx(470,185.8296,1869.3086,18.7252,270.4274,-1,-1,120); // pat 4
AddStaticVehicleEx(470,186.4270,1878.2654,18.4112,276.9236,-1,-1,120); // pat 5
AddStaticVehicleEx(470,186.7550,1883.5729,18.3028,272.0026,-1,-1,120); // pat 6
AddStaticVehicleEx(468,-37.7844,1165.6926,19.1556,357.2925,-1,-1,120); // sanchez2
AddStaticVehicleEx(518,-94.6694,1338.3793,10.1249,8.9369,-1,-1,120); // buccaner3
AddStaticVehicleEx(592,1700.0554,1610.4097,11.4910,88.1776,-1,-1,120); // andromeada
AddStaticVehicleEx(519,1329.3020,1607.6007,11.7437,269.2944,-1,-1,120); // shamal1
AddStaticVehicleEx(519,1326.2069,1569.3939,11.7301,269.3150,-1,-1,120); // shamal2
AddStaticVehicleEx(495,204.6369,1899.2637,17.6327,2.6209,-1,-1,120); // other
AddStaticVehicleEx(495,222.4810,1898.8455,17.6382,354.3526,-1,-1,120); // other1
AddStaticVehicleEx(471,2163.4546,1025.5143,10.3011,88.9232,-1,-1,120); // quad2
AddStaticVehicleEx(471,2163.7451,1022.6242,10.3018,90.2317,-1,-1,120); // quad3
AddStaticVehicleEx(471,2163.5703,1028.8292,10.3021,88.3722,-1,-1,120); // quad4
AddStaticVehicleEx(468,225.0490,1117.5273,12.9580,268.3571,-1,-1,120); // sanchez3
AddStaticVehicleEx(468,-302.6169,1779.3776,42.3567,269.4230,-1,-1,120); // sanchez4
AddStaticVehicleEx(542,-290.5254,1749.0854,42.4349,89.4847,-1,-1,120); // clover2
AddStaticVehicleEx(468,-372.0559,2235.1438,42.1535,104.4282,-1,-1,120); // sanchez4
AddStaticVehicleEx(568,-392.0485,2198.0771,42.2890,282.3193,-1,-1,120); // bandito3
AddStaticVehicleEx(402,-441.6526,2232.7988,42.2231,48.2674,-1,-1,120); // buffalo3
AddStaticVehicleEx(603,-783.2940,2769.7734,45.4926,179.1096,-1,-1,120); // pheonix2
AddStaticVehicleEx(510,-752.4396,2765.0818,45.3820,171.9255,-1,-1,120); // mountainbike1
AddStaticVehicleEx(568,-618.0806,2716.3970,72.1968,183.9667,-1,-1,120); // bandito3
AddStaticVehicleEx(510,-244.4430,2593.2969,62.3091,181.2123,-1,-1,120); // mountainbike2
AddStaticVehicleEx(603,-206.9322,2609.4111,62.5415,0.0699,-1,-1,120); // pheonix3
AddStaticVehicleEx(468,-540.5938,2549.4678,53.0825,266.6190,-1,-1,120); // sanchez5
AddStaticVehicleEx(510,-507.3808,2633.4299,53.0225,273.8445,-1,-1,120); // mountainbike3
AddStaticVehicleEx(542,385.3909,2600.7302,16.2280,194.4501,-1,-1,120); // clover3
AddStaticVehicleEx(603,208.9666,2578.2739,16.1459,48.2374,-1,-1,120); // pheonix4
AddStaticVehicleEx(471,375.1734,2471.6575,15.9642,353.3204,-1,-1,120); // quadbike4
AddStaticVehicleEx(568,-17.9334,2361.0522,24.0041,179.6273,-1,-1,120); // bandito4
AddStaticVehicleEx(469,256.4927,2907.6216,6.4201,276.0251,-1,-1,120); // sparrow1
AddStaticVehicleEx(469,1303.5033,1322.3326,10.8314,271.7457,-1,-1,120); // sparro2
AddStaticVehicleEx(469,1304.1399,1362.0220,10.8397,273.6127,-1,-1,120); // sparrow3
AddStaticVehicleEx(487,2091.8362,2415.4680,74.7540,88.3441,-1,-1,120); // maverick2
AddStaticVehicleEx(487,2885.7031,931.4672,17.8557,178.0785,-1,-1,120); // maverick2
AddStaticVehicleEx(402,649.5997,1702.1992,6.8238,130.1012,-1,-1,120); // buffalo3
AddStaticVehicleEx(542,667.3462,1727.8740,6.7357,220.1699,-1,-1,120); // clover4
AddStaticVehicleEx(406,607.1327,842.8998,-41.7120,315.2971,-1,-1,120); // dumper1
AddStaticVehicleEx(471,718.5313,1961.4197,5.0215,90.0650,-1,-1,120); // quadbike5
AddStaticVehicleEx(598,2277.5569,2477.5068,10.5669,181.4602,-1,-1,120); // polcecar1
AddStaticVehicleEx(599,2281.8411,2477.9314,11.0073,179.9048,-1,-1,120); // policecar2
AddStaticVehicleEx(599,-1398.9111,2634.6836,55.9025,92.2155,-1,-1,120); // policecar3
AddStaticVehicleEx(411,-2845.5723,2806.5571,243.0738,181.9193,-1,-1,120); // Admin Car 1
AddStaticVehicleEx(522,-2842.8101,2806.7507,243.0612,184.2256,-1,-1,120); // Admin Bike
AddStaticVehicleEx(503,-2839.7581,2805.5308,243.3805,180.5257,-1,-1,120); // Admin Car 2
AddStaticVehicleEx(495,-2869.7156,2802.3479,250.2632,238.7511,-1,-1,120); // Admin 4x4
AddStaticVehicleEx(447,-2832.4448,2802.7512,242.7789,173.7751,-1,-1,120); // Admin Heli
AddStaticVehicleEx(599,2273.1145,2476.7012,11.0120,181.0262,-1,-1,120); // cop 1
AddStaticVehicleEx(599,2273.4019,2460.6201,11.0169,181.0271,-1,-1,120); // cop2
AddStaticVehicleEx(599,2273.8823,2442.6807,11.0138,358.6244,-1,-1,120); // cop 3
AddStaticVehicleEx(598,2277.4849,2461.0034,10.5645,183.9988,-1,-1,120); // cop car 1
AddStaticVehicleEx(598,2277.4629,2443.2810,10.5680,2.4102,-1,-1,120); // cop car 3
AddStaticVehicleEx(598,2251.1899,2444.0933,10.5666,0.3395,-1,-1,120); // cop bike
AddStaticVehicleEx(444,-1951.5079,267.2635,35.0461,87.2007,-1,-1,120); // change to 444
AddStaticVehicleEx(444,-2018.9050,287.5350,33.7973,270.7104,-1,-1,120); // 444
// weapons
AddStaticPickup(372,2,-1966.5564,305.8892,35.4688); // tec9 pos1
AddStaticPickup(373,2,-1967.1572,304.5973,35.2808); // tec9 pos2
AddStaticPickup(370,2,-1966.7906,303.1341,35.4688); // tec9 pos3
AddStaticPickup(356,2,-1967.2345,301.4471,35.2370); // tec9 pos4
AddStaticPickup(353,2,-1967.0028,289.0927,35.3684); // tec9 pos5
AddStaticPickup(352,2,-1966.8899,286.2454,35.4324); // tec9 pos6
AddStaticPickup(351,2,-1967.0852,283.8254,35.3217); // tec9 pos7
AddStaticPickup(341,2,-1967.6503,280.7254,35.1719); // tec9 pos8
AddStaticPickup(1242,2,-1991.5116,295.5918,34.6129); // tec9 pos9
AddStaticPickup(362,2,1104.5823,-827.2032,86.9453); // /minigun
AddStaticPickup(370,2,211.8597,1921.7445,17.6406); //admin jetpack
DriverTakingTest=-1;
if(!fopen("DSchool",io_read))
{
print("\r\n\r\nError: No driving school data found. Creating new data file.");
DSchool=fopen("DSchool",io_readwrite);
}
else
{
print("\r\n\r\nDriving School data found. Now loading data...");
DSchool=fopen("DSchool",io_readwrite);
}
fclose(DSchool);
return 1;
}
public OnPlayerRequestClass(playerid, classid)
{
SetPlayerPos(playerid, -2080.4209, 304.9722, 105.7115);
SetPlayerCameraPos(playerid, -2080.2900, 301.6452, 105.7115);
SetPlayerCameraLookAt(playerid, -2080.4209, 304.9722, 105.7115);
SetPlayerFacingAngle(playerid, 180.0);
PlayerPlaySound(playerid,1097,-2080.4209,304.9722,105.7115);
SetPlayerTeamFromClass(playerid, classid);
gTeam[playerid] = classid;
switch (classid) {
case 0: //Civs
{
GameTextForPlayer(playerid, "~g~Civillian",1000,3);
}
case 1: //civ
{
GameTextForPlayer(playerid, "~g~Civillian",1000,3);
}
case 2: //civ
{
GameTextForPlayer(playerid, "~g~Civillian",1000,3);
}
case 3: //civ
{
GameTextForPlayer(playerid, "~g~Civillian",1000,3);
}
case 4: //civ
{
GameTextForPlayer(playerid, "~g~Civillian",1000,3);
}
case 5: //civ
{
GameTextForPlayer(playerid, "~g~Civillian",1000,3);
}
case 6: //civ
{
GameTextForPlayer(playerid, "~g~Civillian",1000,3);
}
case 7: //civ
{
GameTextForPlayer(playerid, "~g~Civillian",1000,3);
}
case 8: //civ
{
GameTextForPlayer(playerid, "~g~Civillian",1000,3);
}
case 9: //civ
{
GameTextForPlayer(playerid, "~g~Civillian",1000,3);
}
case 10: //civ
{
GameTextForPlayer(playerid, "~g~Civillian",1000,3);
}
case 11: //civ
{
GameTextForPlayer(playerid, "~g~Civillian",1000,3);
}
case 12: //civ
{
GameTextForPlayer(playerid, "~g~Civillian",1000,3);
}
case 13: //civ
{
GameTextForPlayer(playerid, "~g~Secret Service",1000,3);
}
case 14: //secretservice
{
GameTextForPlayer(playerid, "~g~Secret Service",1000,3);
}
case 15: //secretservice
{
GameTextForPlayer(playerid, "~g~Secret Service",1000,3);
}
case 16: //secretservice
{
GameTextForPlayer(playerid, "~g~Secret Service",1000,3);
}
case 17: //secretservice
{
GameTextForPlayer(playerid, "~g~Cops",1000,3);
}
case 18: //cop
{
GameTextForPlayer(playerid, "~g~Cops",1000,3);
}
case 19: //cop
{
GameTextForPlayer(playerid, "~g~Cops",1000,3);
}
case 20: //cop
{
GameTextForPlayer(playerid, "~g~Cops",1000,3);
}
case 21: //cop
{
GameTextForPlayer(playerid, "~g~Cops",1000,3);
}
case 22: //cop
{
GameTextForPlayer(playerid, "~g~Cops",1000,3);
}
case 23: //cop
{
GameTextForPlayer(playerid, "~g~Pilot",1000,3);
}
case 24: //cop
{
GameTextForPlayer(playerid, "~g~Taxi Driver",1000,3);
}
case 25: //cop
{
GameTextForPlayer(playerid, "~g~Taxi Driver",1000,3);
}
case 26: //cop
{
GameTextForPlayer(playerid, "~g~David Tiger",1000,3);
}
}
return 1;
}
public SetPlayerTeamFromClass(playerid, classid)
{
if (classid == 0 || classid == 100 || classid == 101 || classid == 106 || classid == 181 || classid == 217 || classid == 247 || classid == 248 || classid == 254 || classid == 292 || classid == 293 || classid == 297 || classid == 299)
{
gTeam[playerid] = TEAM_CIV;
}
if (classid == 280 || classid == 281 || classid == 282 || classid == 283 || classid == 284 || classid == 288)
{
gTeam[playerid] = TEAM_COP;
}
if (classid == 163 || classid == 164 || classid == 165 || classid == 166)
{
gTeam[playerid] = TEAM_BG;
}
}
public OnPlayerConnect(playerid)
{
jailed[playerid] = 0;
zoneupdates[playerid] = 0;
player_zone[playerid] = -1;
GivePlayerMoney(playerid, 10000);
SetPlayerTeam(playerid, TEAM_CIV);
SendClientMessage(playerid,COLOR_LIGHTGREEN,"Welcome to San Andreas Multiplayer Server");
SendClientMessage(playerid,COLOR_LIGHTGREEN,"Created by David_Tiger");
SendClientMessage(playerid,COLOR_ORANGE,"** Please /register your nickname, If So /login.");
SendClientMessage(playerid,COLOR_ORANGE,"** To be a cop type /logincop | For taxi driver /logintaxi");
SendClientMessage(playerid,COLOR_ORANGE,"** For pilot type /loginpilot.");
SendClientMessage(playerid,COLOR_RED,"** ===================================");
SendClientMessage(playerid,COLOR_ORANGE,"** Type /commands to see the server commands.");
SendClientMessage(playerid,COLOR_ORANGE,"** Type /rules to read the server rules.");
new PName[MAX_PLAYER_NAME];
GetPlayerName(playerid,PName,sizeof(PName));
DSchool=fopen("DSchool",io_readwrite);
if(strcmp(dini_Get("DSchool",PName),"Y",false)==0)
{
if(strlen(dini_Get("DSchool",PName))==1) // seems streams with no data also run through this part.
{
fclose(DSchool);
}
else // If there is no data present,
{
Dschool_No(playerid); // Make some!
}
}
else if(strcmp(dini_Get("DSchool",PName),"N",false)==0)
{
fclose(DSchool);
}
else if(strcmp(dini_Get("DSchool",PName),"D",false)==0)
{
fclose(DSchool);
}
else
{
Dschool_No(playerid);
}
return 1;
}
public OnPlayerDisconnect(playerid)
{
zoneupdates[playerid] = 0;
player_zone[playerid] = -1;
QuitSchool(playerid);
return 1;
}
public OnPlayerSpawn(playerid)
{
PlayerPlaySound(playerid,1098,-2080.4209,304.9722,105.7115);
zoneupdates[playerid] = 1;
player_zone[playerid] = -1;
if(!zoneupdate) zoneupdate = SetTimer("update_zones",1000,4);
SendClientMessage(playerid, COLOR_YELLOW, "Welcome To Freeroam RPG!");
SendClientMessage(playerid, COLOR_YELLOW, "Roam around the city, do what you want!");
SendClientMessage(playerid, COLOR_YELLOW, "BUT...Remember no DMing, have some flowers!");
GivePlayerWeapon(playerid, 14, 200);
new message[64],playername[24]; //put 24 instead of MAX_PLAYER_NAME if you don't have this constant defined
GetPlayerName(playerid, playername, sizeof(playername));
format(message, sizeof(message), "~g~Welcome back ~b~%s,~n~~r~Please Login", playername);
GameTextForPlayer(playerid, message, 6000, 0);
QuitSchool(playerid);
return 1;
}
public OnPlayerDeath(playerid, killerid, reason)
{
GameTextForPlayer(playerid, "~w~OWNED", 2000, 2);
printf("OnPlayerDeath(%d, %d, %d)", playerid, killerid, reason);
SendDeathMessage(killerid, playerid, reason);
SetPlayerScore(killerid, GetPlayerScore(killerid) + 1);
zoneupdates[playerid] = 0;
player_zone[playerid] = -1;
QuitSchool(playerid);
return 1;
}
public OnPlayerCommandText(playerid,cmdtext[])
{
new tmp[256];
new name[256];
new string[256];
new sendername[MAX_PLAYER_NAME];
new giveplayer[MAX_PLAYER_NAME];
new cmd[256];
new idx;
new giveplayerid;
new Float:PlayerHP;
cmd = strtok(cmdtext, idx);
if(strcmp(cmd,"/l-suspend",true)==0)
{
new tracedID;
new tracedIDName[MAX_PLAYER_NAME];
new PName[MAX_PLAYER_NAME];
tmp = strtok(cmdtext, idx);
if(strlen(tmp)==0)
{
SendClientMessage(playerid, 0xFF000000, "USAGE: /l-suspend (playerid)");
return 1;
}
tracedID = strval(tmp);
if(tracedID!=INVALID_PLAYER_ID)
{
if(IsPlayerConnected(tracedID))
{
GetPlayerName(tracedID, tracedIDName, sizeof(tracedIDName));
GetPlayerName(playerid, PName, sizeof(PName));
DSchool=fopen("DSchool",io_readwrite);
if(strcmp(dini_Get("DSchool",tracedIDName),"Y",true)==0)
{
format(string, sizeof(string), "%s (ID:%d) has had their licence suspended.",tracedIDName,tracedID);
printf("%s (ID:%d) has been licence suspended.",tracedIDName,tracedID);
SendClientMessage(playerid,0xFF000000,string);
format(string, sizeof(string), "%s (ID:%d) has had their licence suspended by %s (ID:%d).",tracedIDName,tracedID,PName,playerid);
SendClientMessageToAll(0xFF800000,string);
Dschool_Dis(tracedID);
fclose(DSchool);
return 1;
}
else if(strcmp(dini_Get("DSchool",tracedIDName),"N",true)==0)
{
format(string, sizeof(string), "%s (ID:%d) have a licence to suspend!",tracedIDName,tracedID);
SendClientMessage(playerid,0xFF000000,string);
printf("%s (ID:%d) is being licence suspended, but doesn't have a licence.",tracedIDName,tracedID);
fclose(DSchool);
return 1;
}
else if(strcmp(dini_Get("DSchool",tracedIDName),"D",true)==0)
{
format(string, sizeof(string), "%s (ID:%d) is already disqualified from driving.",tracedIDName,tracedID);
SendClientMessage(playerid,0xFF000000,string);
printf("%s (ID:%d) is being licence suspended, but the licence is already suspended.",tracedIDName,tracedID);
fclose(DSchool);
return 1;
}
else
{
SendClientMessage(playerid,0xFF000000,"Error: Unable to establish licence status.");
fclose(DSchool);
return 1;
}
}
else
{
SendClientMessage(playerid,0xFF000000,"That player is not in the server.");
}
}
else
{
SendClientMessage(playerid,0xFF000000,"You have specified an invalid Player ID.");
}
return 1;
}
//=======================================
// Renew a Licence.
//=======================================
if(strcmp(cmd,"/l-renew",true)==0)
{
new tracedID;
new tracedIDName[MAX_PLAYER_NAME];
new PName[MAX_PLAYER_NAME];
tmp = strtok(cmdtext, idx);
if(strlen(tmp)==0)
{
SendClientMessage(playerid, 0xFF000000, "USAGE: /l-renew (playerid)");
return 1;
}
tracedID = strval(tmp);
if(tracedID!=INVALID_PLAYER_ID)
{
if(IsPlayerConnected(tracedID))
{
GetPlayerName(tracedID, tracedIDName, sizeof(tracedIDName));
GetPlayerName(playerid, PName, sizeof(PName));
DSchool=fopen("DSchool",io_readwrite);
if(strcmp(dini_Get("DSchool",tracedIDName),"D",true)==0)
{
format(string, sizeof(string), "%s (ID:%d) has had their licence renewed.",tracedIDName,tracedID);
SendClientMessage(playerid,0xFF000000,string);
printf("%s (ID:%d) is being licence suspended, but the licence is already suspended.",tracedIDName,tracedID);
format(string, sizeof(string), "%s (ID:%d) has had their licence suspended by %s (ID:%d).",tracedIDName,tracedID,PName,playerid);
SendClientMessageToAll(0xFF800000,string);
Dschool_Yes(tracedID);
fclose(DSchool);
return 1;
}
else
{
SendClientMessage(playerid,0xFF000000,"Error: Unable to establish licence status.");
fclose(DSchool);
return 1;
}
}
else
{
SendClientMessage(playerid,0xFF000000,"That player is not in the server.");
}
}
else
{
SendClientMessage(playerid,0xFF000000,"You have specified an invalid Player ID.");
}
return 1;
}
//=======================================
// Go to Driving School.
//=======================================
if (strcmp(cmdtext, "/dschool", true)==0)
{
new tracedIDName[MAX_PLAYER_NAME];
new strn[255];
if(DriverTakingTest==-1)
{
if(GetPlayerMoney(playerid)>=500)
{
GetPlayerName(playerid,tracedIDName,sizeof(tracedIDName));
if(strcmp(dini_Get("DSchool",tracedIDName),"Y",true)==0)
{
SendClientMessage(playerid, 0xFF000000, "Error: You already have a valid licence!");
return 1;
}
DriverTakingTest=playerid;
GivePlayerMoney(playerid,-500);
SetPlayerCheckpoint(playerid,CPDSchoolData[0][0],CPDSchoolData[0][1],CPDSchoolData[0][2],CPDSchoolData[0][3]);
DSCP[playerid]=0;
SetPlayerPos(playerid,-2077.3,-81.4,34.8);
SendClientMessage(playerid, 0xFF000000, "You are now on the Driving School program. Drive safe, yet speedy.");
return 1;
}
else
{
SendClientMessage(playerid, 0xFF000000, "Error: Insufficient funds to take the test.");
return 1;
}
}
else
{
GetPlayerName(DriverTakingTest,tracedIDName,sizeof(tracedIDName));
format(strn, sizeof(strn), "%s(ID:%d) is currently taking the Driving School Test. Try again later.",tracedIDName,DriverTakingTest);
SendClientMessage(playerid, 0xFF000000, strn);
return 1;
}
}
//=======================================
// Licence Checker.
//=======================================
if(strcmp(cmd,"/licence",true)==0)
{
new tracedID;
new tracedIDName[MAX_PLAYER_NAME];
tmp = strtok(cmdtext, idx);
if(strlen(tmp)==0)
{
SendClientMessage(playerid, 0xFF000000, "USAGE: /licence (playerid)");
return 1;
}
tracedID = strval(tmp);
if(tracedID!=INVALID_PLAYER_ID)
{
if(IsPlayerConnected(tracedID))
{
GetPlayerName(tracedID, tracedIDName, sizeof(tracedIDName));
DSchool=fopen("DSchool",io_readwrite);
if(strcmp(dini_Get("DSchool",tracedIDName),"Y",true)==0)
{
format(string, sizeof(string), "%s (ID:%d) has a valid drivers licence.",tracedIDName,tracedID);
printf("%s (ID:%d) has been licence checked. Status: Clean licence.",tracedIDName,tracedID);
SendClientMessage(playerid,0xFF000000,string);
fclose(DSchool);
return 1;
}
else if(strcmp(dini_Get("DSchool",tracedIDName),"N",true)==0)
{
format(string, sizeof(string), "%s (ID:%d) doesn't carry a drivers licence.",tracedIDName,tracedID);
SendClientMessage(playerid,0xFF000000,string);
SendClientMessage(playerid,0xFF000000,"COA: Jail them, or send them to driving school.");
printf("%s (ID:%d) has been licence checked. Status: No licence.",tracedIDName,tracedID);
fclose(DSchool);
return 1;
}
else if(strcmp(dini_Get("DSchool",tracedIDName),"D",true)==0)
{
format(string, sizeof(string), "%s (ID:%d) has been disqualified from driving.",tracedIDName,tracedID);
SendClientMessage(playerid,0xFF000000,string);
SendClientMessage(playerid,0xFF000000,"COA: Jail them, at reasonable cost.");
printf("%s (ID:%d) has been licence checked. Status: Disqualified licence.",tracedIDName,tracedID);
fclose(DSchool);
return 1;
}
else
{
SendClientMessage(playerid,0xFF000000,"Error: Unable to establish licence status.");
fclose(DSchool);
return 1;
}
}
else
{
SendClientMessage(playerid,0xFF000000,"That player is not in the server.");
}
}
else
{
SendClientMessage(playerid,0xFF000000,"You have specified an invalid Player ID.");
}
return 1;
}
if(strcmp(cmd, "/commands", true) == 0)
{
SendClientMessage(playerid,COLOR_GREEN,"* SA:MP Commands");
SendClientMessage(playerid,COLOR_ORANGE,"* /Register | /Login | /admins");
SendClientMessage(playerid,COLOR_ORANGE,"* /Rules | /credits | /health");
SendClientMessage(playerid,COLOR_ORANGE,"* /kill | /Commands | /tele");
SendClientMessage(playerid,COLOR_ORANGE,"* Please do not abuse the commands");
return 1;
}
if(strcmp(cmd, "/credits", true) == 0)
{
SendClientMessage(playerid,COLOR_GREEN,"* SA:MP Credits");
SendClientMessage(playerid,COLOR_ORANGE,"* Credits Go To David_Tiger For Script");
SendClientMessage(playerid,COLOR_ORANGE,"* I'll Start With allan for /lock, /unlock");
SendClientMessage(playerid,COLOR_ORANGE,"* Also Whitestrom for /day, /night");
SendClientMessage(playerid,COLOR_ORANGE,"* Y_Less and Makabo for Zones");
SendClientMessage(playerid,COLOR_ORANGE,"* And Finally [TuG]dragsta for");
SendClientMessage(playerid,COLOR_ORANGE,"* Buissness/Orginisations and adding driving school");
SendClientMessage(playerid,COLOR_ORANGE,"* IF I MISSED YOU CONTACT ME ON SA_MP FORUMS");
return 1;
}
if(strcmp(cmd, "/tele", true) == 0)
{
SendClientMessage(playerid,COLOR_GREEN,"* SA:MP Teleports");
SendClientMessage(playerid,COLOR_ORANGE,"* /airport | Los Santos Airport");
SendClientMessage(playerid,COLOR_ORANGE,"* /trans | Transfender");
SendClientMessage(playerid,COLOR_ORANGE,"* /arch | Wheel Arch Angels");
SendClientMessage(playerid,COLOR_ORANGE,"* /coast | The Coastline");
SendClientMessage(playerid,COLOR_ORANGE,"* /vine | Vinewood");
SendClientMessage(playerid,COLOR_ORANGE,"* /wang | wangs");
SendClientMessage(playerid,COLOR_RED,"* There are 2 secret /tele");
return 1;
}
if(strcmp(cmdtext, "/colours", true) ==0)
{
SendClientMessage(playerid, 0xFF9900AA, "for colour commands type /lightgreen, /lightblue, /medgreen");
SendClientMessage(playerid, 0xFF9900AA, "/lightred, /pink, /orange, /black, /violet, /orangered");
SendClientMessage(playerid, 0xFF9900AA, "/lightcyan, /red, /lightbluegreen, /bluegreen, /magenta");
SendClientMessage(playerid, 0xFF9900AA, "/neutralblue, /white, /darkpurple, /lightbrown, /grayblue");
SendClientMessage(playerid, 0xFF9900AA, "/gold, /lemon, /yellow, /darkgreen, /medblue, /darkmagenta");
return 1;
}
if(strcmp(cmdtext, "/weapons", true) ==0)
{
SendClientMessage(playerid, COLOR_GREEN, "To Get Weapons Use The Following Commands");
SendClientMessage(playerid, COLOR_ORANGE, "/getbat, /getchainsaw, /getpistol, /getdesert");
SendClientMessage(playerid, COLOR_ORANGE, "/getsawnoff, /getak47, /getm4, /gettec9");
SendClientMessage(playerid, COLOR_ORANGE, "/getpara, /getuzi, /getflame, /getshotgun");
SendClientMessage(playerid, COLOR_RED, "Remember Only Deathmatch people who want to Deathmatch");
return 1;
}
if(strcmp(cmd, "/help", true) == 0)
{
SendClientMessage(playerid,COLOR_GREEN,"*SA:MP Help");
SendClientMessage(playerid,COLOR_ORANGE,"**Welcome to Grand Theft Auto: Multiplayer Server");
SendClientMessage(playerid,COLOR_ORANGE,"**/Commands /rules will help you through");
SendClientMessage(playerid,COLOR_ORANGE,"**Enjoy");
return 1;
}
if (strcmp(cmdtext, "/health", true)==0)
{
if(GetPlayerMoney(playerid) > 1){
GivePlayerMoney(playerid, GetPlayerMoney(playerid) - 1);
SetPlayerHealth(playerid,100);
GetPlayerHealth(playerid,PlayerHP);
format(string, sizeof(string), "You're health is: %.0f", PlayerHP);
SendClientMessage(playerid,COLOR_RED,string);
SendClientMessage(playerid,COLOR_RED,"You're cash increased: $9999");
}
return 1;
}
if(strcmp(cmd, "/rules", true) == 0)
{
SendClientMessage(playerid,COLOR_GREEN,"*SA:MP Help");
SendClientMessage(playerid,COLOR_RED,"*RULES*");
SendClientMessage(playerid,COLOR_RED,"*1. Always Role Play.*");
SendClientMessage(playerid,COLOR_RED,"*2. Do not Deathmatch unless the person wants to!.*");
SendClientMessage(playerid,COLOR_RED,"*3. Obey all admins.*");
SendClientMessage(playerid,COLOR_RED,"*4. No flaming, take it to the forums.*");
SendClientMessage(playerid,COLOR_RED,"*5. On www.tigerserver.co.nr.*");
SendClientMessage(playerid,COLOR_RED,"*6. Do not steal cars without non-rp.*");
SendClientMessage(playerid,COLOR_GREEN,"*Enjoy And Have Fun ! !*");
return 1;
}
if (strcmp(cmdtext, "/airport", true)==0)
{
printf("ID: %d Has Been Teleported to the Los Santos Airport!", playerid);
SendClientMessage(playerid, COLOR_GREEN, "Welcome to Los Santos Airport!");
QuitSchool(playerid);
if(IsPlayerInAnyVehicle(playerid))
{
new VehicleID;
VehicleID = GetPlayerVehicleID(playerid);
GetVehiclePos(VehicleID, posx, posy, posz);
SetVehiclePos(VehicleID,2010.5697,-2182.8313,13.5469);
} else {
SendClientMessage(playerid, COLOR_GREEN, "Enjoy!");
GetPlayerPos(playerid, posx, posy, posz);
SetPlayerPos(playerid,2010.5697,-2182.8313,13.5469);
}
return 1;
}
if (strcmp(cmdtext, "/area51", true)==0)
{
printf("ID: %d Has Been Teleported to the Area 51!", playerid);
SendClientMessage(playerid, COLOR_GREEN, "Welcome to Area 51!");
QuitSchool(playerid);
if(IsPlayerInAnyVehicle(playerid))
{
new VehicleID;
VehicleID = GetPlayerVehicleID(playerid);
GetVehiclePos(VehicleID, posx, posy, posz);
SetVehiclePos(VehicleID,204.0505,1921.0018,17.6406);
} else {
SendClientMessage(playerid, COLOR_GREEN, "Enjoy!");
GetPlayerPos(playerid, posx, posy, posz);
SetPlayerPos(playerid,204.0505,1921.0018,17.6406);
}
return 1;
}
if (strcmp(cmdtext, "/trans", true)==0)
{
printf("ID: %d Has Been Teleported to the TransFender!", playerid);
SendClientMessage(playerid, COLOR_GREEN, "Welcome to Trans Fender!");
QuitSchool(playerid);
if(IsPlayerInAnyVehicle(playerid))
{
new VehicleID;
VehicleID = GetPlayerVehicleID(playerid);
GetVehiclePos(VehicleID, posx, posy, posz);
SetVehiclePos(VehicleID,-1992.3516,228.2994,28.5172);
} else {
SendClientMessage(playerid, COLOR_GREEN, "Enjoy!");
GetPlayerPos(playerid, posx, posy, posz);
SetPlayerPos(playerid,-1992.3516,228.2994,28.5172);
}
return 1;
}
if (strcmp(cmdtext, "/arch", true)==0)
{
printf("ID: %d Has Been Teleported to the Wheel Archs!", playerid);
SendClientMessage(playerid, COLOR_GREEN, "Welcome to the Wheel Archs!");
QuitSchool(playerid);
if(IsPlayerInAnyVehicle(playerid))
{
new VehicleID;
VehicleID = GetPlayerVehicleID(playerid);
GetVehiclePos(VehicleID, posx, posy, posz);
SetVehiclePos(VehicleID,-2701.7092,232.6693,4.1797);
} else {
SendClientMessage(playerid, COLOR_GREEN, "Enjoy!");
GetPlayerPos(playerid, posx, posy, posz);
SetPlayerPos(playerid,-2701.7092,232.6693,4.1797);
}
return 1;
}
if (strcmp(cmdtext, "/coast", true)==0)
{
printf("ID: %d Has Been Teleported to Coast Line!", playerid);
SendClientMessage(playerid, COLOR_GREEN, "Welcome to the Coast Line!");
QuitSchool(playerid);
if(IsPlayerInAnyVehicle(playerid))
{
new VehicleID;
VehicleID = GetPlayerVehicleID(playerid);
GetVehiclePos(VehicleID, posx, posy, posz);
SetVehiclePos(VehicleID,-2249.8025,2370.4424,4.9989);
} else {
SendClientMessage(playerid, COLOR_GREEN, "Enjoy!");
GetPlayerPos(playerid, posx, posy, posz);
SetPlayerPos(playerid,-2249.8025,2370.4424,4.9989);
}
return 1;
}
if (strcmp(cmdtext, "/vine", true)==0)
{
printf("ID: %d Has Been Teleported to Vinewood!", playerid);
SendClientMessage(playerid, COLOR_GREEN, "Welcome to the Vinewood (LS)!");
QuitSchool(playerid);
if(IsPlayerInAnyVehicle(playerid))
{
new VehicleID;
VehicleID = GetPlayerVehicleID(playerid);
GetVehiclePos(VehicleID, posx, posy, posz);
SetVehiclePos(VehicleID,1298.6920,-711.9091,92.9810);
} else {
SendClientMessage(playerid, COLOR_GREEN, "Enjoy!");
GetPlayerPos(playerid, posx, posy, posz);
SetPlayerPos(playerid,1298.6920,-711.9091,92.9810);
}
return 1;
}
if (strcmp(cmdtext, "/wang", true)==0)
{
printf("ID: %d Has Been Teleported to the Wang Garage!", playerid);
SendClientMessage(playerid, COLOR_GREEN, "Welcome to Wangs!");
QuitSchool(playerid);
if(IsPlayerInAnyVehicle(playerid))
{
new VehicleID;
VehicleID = GetPlayerVehicleID(playerid);
GetVehiclePos(VehicleID, posx, posy, posz);
SetVehiclePos(VehicleID, -1967.4937,293.7480,35.1719);
} else {
SendClientMessage(playerid, COLOR_GREEN, "Enjoy!");
GetPlayerPos(playerid, posx, posy, posz);
SetPlayerPos(playerid, -1967.4937,293.7480,35.1719);
}
return 1;
}
if (strcmp(cmdtext, "/minigun", true)==0)
{
printf("ID: %d Has Been Teleported to the Secret Minigun!", playerid);
SendClientMessage(playerid, COLOR_GREEN, "Welcome to Minigun!");
QuitSchool(playerid);
if(IsPlayerInAnyVehicle(playerid))
{
new VehicleID;
VehicleID = GetPlayerVehicleID(playerid);
GetVehiclePos(VehicleID, posx, posy, posz);
SetVehiclePos(VehicleID, 1103.2175,-818.4562,86.9453);
} else {
SendClientMessage(playerid, COLOR_GREEN, "Kill them all!");
GetPlayerPos(playerid, posx, posy, posz);
SetPlayerPos(playerid, 1103.2175,-818.4562,86.9453);
}
return 1;
}
if (strcmp(cmdtext, "/lock", true)==0)
{
if(IsPlayerInAnyVehicle(playerid))
{
new State=GetPlayerState(playerid);
if(State!=PLAYER_STATE_DRIVER)
{
SendClientMessage(playerid,0xFFFF00AA,"You can only lock the doors as the driver.");
return 1;
}
new i;
for(i=0;i<MAX_PLAYERS;i++)
{
if(i != playerid)
{
SetVehicleParamsForPlayer(GetPlayerVehicleID(playerid),i, 0, 1);
}
}
SendClientMessage(playerid, 0xFFFF00AA, "Vehicle locked!");
new Float:pX, Float:pY, Float:pZ;
GetPlayerPos(playerid,pX,pY,pZ);
PlayerPlaySound(playerid,1056,pX,pY,pZ);
}
else
{
SendClientMessage(playerid, 0xFFFF00AA, "You're not in a vehicle!");
}
return 1;
}
if (strcmp(cmdtext, "/unlock", true)==0)
{
if(IsPlayerInAnyVehicle(playerid))
{
new State=GetPlayerState(playerid);
if(State!=PLAYER_STATE_DRIVER)
{
SendClientMessage(playerid,0xFFFF00AA,"You can only unlock the doors as the driver.");
return 1;
}
new i;
for(i=0;i<MAX_PLAYERS;i++)
{
SetVehicleParamsForPlayer(GetPlayerVehicleID(playerid),i, 0, 0);
}
SendClientMessage(playerid, 0xFFFF00AA, "Vehicle unlocked!");
new Float:pX, Float:pY, Float:pZ;
GetPlayerPos(playerid,pX,pY,pZ);
PlayerPlaySound(playerid,1057,pX,pY,pZ);
}
else
{
SendClientMessage(playerid, 0xFFFF00AA, "You're not in a vehicle!");
}
return 1;
}
if (strcmp(cmdtext, "/night", true)==0)
{
SetWorldTime(0);
GameTextForPlayer(playerid,"Nighty Night",5000,5);
return 1;
}
if (strcmp(cmdtext, "/day", true)==0)
{
/* Do something here */
SetWorldTime(12);
GameTextForPlayer(playerid,"Good Morning",5000,5);
return 1;
}
if (strcmp(cmdtext, "/cash", true)==0)
{
GivePlayerMoney(playerid, 100000);
return 1;
}
if(strcmp(cmdtext, "/magenta", true) == 0)
{
SetPlayerColor(playerid, 0xA587DE0BA354);
return 1;
}
if(strcmp(cmdtext, "/medgreen", true) == 0)
{
SetPlayerColor(playerid, 0x9CDE7180);
return 1;
}
if(strcmp(cmdtext, "/lightred", true) == 0)
{
SetPlayerColor(playerid, 0xFF99AADD);
return 1;
}
if(strcmp(cmd, "/darkmagenta", true) == 0)
{
SetPlayerColor(playerid, 0xA7105DEF);
return 1;
}
if(strcmp(cmdtext, "/lightblue", true) == 0)
{
SetPlayerColor(playerid, 0x33CCFFAA);
return 1;
}
if(strcmp(cmdtext, "/lightgreen", true) == 0)
{
SetPlayerColor(playerid, 0x24FF0AB9);
return 1;
}
if(strcmp(cmdtext, "/lemon", true) == 0)
{
SetPlayerColor(playerid, 0xDDDD2357);
return 1;
}
if(strcmp(cmdtext, "/orangered", true) == 0)
{
SetPlayerColor(playerid, 0xE9370DFC);
return 1;
}
if(strcmp(cmdtext, "/yellow", true) == 0)
{
SetPlayerColor(playerid, 0xFFFF00AA);
return 1;
}
if(strcmp(cmdtext, "/darkgreen", true) == 0)
{
SetPlayerColor(playerid, 0x12900BBF);
return 1;
}
if(strcmp(cmdtext, "/medblue", true) == 0)
{
SetPlayerColor(playerid, 0x63AFF00A);
return 1;
}
if(strcmp(cmdtext, "/darkpurple", true) == 0)
{
SetPlayerColor(playerid, 0x800080AA);
return 1;
}
if(strcmp(cmdtext, "/lightbrown", true) == 0)
{
SetPlayerColor(playerid, 0x99934EFA);
return 1;
}
if(strcmp(cmdtext, "/pink", true) == 0)
{
SetPlayerColor(playerid, 0xFF66FFAA);
return 1;
}
if(strcmp(cmdtext, "/orange", true) == 0)
{
SetPlayerColor(playerid, 0xFF9900AA);
return 1;
}
if(strcmp(cmdtext, "/black", true) == 0)
{
SetPlayerColor(playerid, 0x00000000);
return 1;
}
if(strcmp(cmdtext, "/violet", true) == 0)
{
SetPlayerColor(playerid, 0x9955DEEE);
return 1;
}
if(strcmp(cmdtext, "/lightcyan", true) == 0)
{
SetPlayerColor(playerid, 0xAAFFCC33);
return 1;
}
if(strcmp(cmdtext, "/red", true) == 0)
{
SetPlayerColor(playerid, 0xAA3333AA);
return 1;
}
if(strcmp(cmdtext, "/lightbluegreen", true) == 0)
{
SetPlayerColor(playerid, 0x0FFDD349);
return 1;
}
if(strcmp(cmdtext, "/gold", true) == 0)
{
SetPlayerColor(playerid, 0xDEAD4370);
return 1;
}
if(strcmp(cmdtext, "/grayblue", true) == 0)
{
SetPlayerColor(playerid, 0x456EAF67);
return 1;
}
if(strcmp(cmdtext, "/bluegreen", true) == 0)
{
SetPlayerColor(playerid, 0x46BBAA00);
return 1;
}
if(strcmp(cmdtext, "/neutralblue", true) == 0)
{
SetPlayerColor(playerid, 0xABCDEF01);
return 1;
}
if(strcmp(cmdtext, "/white", true) == 0)
{
SetPlayerColor(playerid, 0xFFFFFFAA);
return 1;
}
new command[256];
new space;
space = strfind(cmdtext, " ", true, 0);
if(space == -1)
{
space = strlen(cmdtext);
}
strmid(command, cmdtext, 0, space, sizeof(command));
if(strcmp(command, "/invisible", true) == 0)
{
SetPlayerColor(playerid, 0xFFFFFF00);
SendClientMessage(playerid, COLOR_WHITE, "Done.");
return 1;
}
if (strcmp(cmdtext, "/drag", true)==0)
{
printf("ID: %d Has Been Teleported to the Bridge Drag!", playerid);
SendClientMessage(playerid, COLOR_GREEN, "Welcome to Bridge Drag Races!");
QuitSchool(playerid);
if(IsPlayerInAnyVehicle(playerid))
{
new VehicleID;
VehicleID = GetPlayerVehicleID(playerid);
GetVehiclePos(VehicleID, posx, posy, posz);
SetVehiclePos(VehicleID, -2688.0652,2156.0234,55.4297);
} else {
SendClientMessage(playerid, COLOR_GREEN, "Let Em' Race!");
GetPlayerPos(playerid, posx, posy, posz);
SetPlayerPos(playerid, -2688.0652,2156.0234,55.4297);
}
return 1;
}
if (strcmp(cmdtext, "/drift", true)==0)
{
printf("ID: %d Has Been Teleported to the Drift!", playerid);
SendClientMessage(playerid, COLOR_GREEN, "Welcome to Big Ear Drift Races!");
QuitSchool(playerid);
if(IsPlayerInAnyVehicle(playerid))
{
new VehicleID;
VehicleID = GetPlayerVehicleID(playerid);
GetVehiclePos(VehicleID, posx, posy, posz);
SetVehiclePos(VehicleID, -296.8765,1564.4945,75.3594);
} else {
SendClientMessage(playerid, COLOR_GREEN, "Let Em' Drift!");
GetPlayerPos(playerid, posx, posy, posz);
SetPlayerPos(playerid, -296.8765,1564.4945,75.3594);
}
return 1;
}
if (strcmp(cmdtext, "/spray", true)==0)
{
printf("ID: %d Has Been Teleported to the Spray!", playerid);
SendClientMessage(playerid, COLOR_GREEN, "Welcome to Pay and Spray!");
QuitSchool(playerid);
if(IsPlayerInAnyVehicle(playerid))
{
new VehicleID;
VehicleID = GetPlayerVehicleID(playerid);
GetVehiclePos(VehicleID, posx, posy, posz);
SetVehiclePos(VehicleID, -1904.5582,285.0222,40.7046);
} else {
SendClientMessage(playerid, COLOR_GREEN, "Fix Your Ride!");
GetPlayerPos(playerid, posx, posy, posz);
SetPlayerPos(playerid, -1904.5582,285.0222,40.7046);
}
return 1;
}
if(strcmp(cmd, "/logincop", true) == 0) {
SendClientMessage(playerid, COLOR_RED1, "You Are logged into cops!! You have a deagle And A nightstick!!");
SendClientMessage(playerid, COLOR_RED1, "Your Cmd's Are: /pu /jail /unjail, /polheli, /cophq, /copcmds and /cc (cop chat)");
SendClientMessage(playerid, COLOR_RED1, "SKINS: /cop1 /cop2 /cop3 /cop4");
gTeam[playerid] = TEAM_COP;
SetPlayerColor(playerid, COLOR_BLUE);
SetPlayerPos(playerid, 2295.0293,2459.4961,10.8203);
GivePlayerWeapon(playerid, 24, 400);
GivePlayerWeapon(playerid, 3, 1);
SetPlayerSkin(playerid, 280);
QuitSchool(playerid);
return 1;
}
if(strcmp(cmd, "/copcmds", true) == 0) {
if (gTeam[playerid] == TEAM_COP) {
SendClientMessage(playerid, COLOR_RED1, "Your Cmd's Are: /pu /jail /unjail, /polheli, /cophq, /copcmds and /cc (cop chat)");
SendClientMessage(playerid, COLOR_RED1, "SKINS: /cop1 /cop2 /cop3 /cop4");
}else{
SendClientMessage(playerid, COLOR_RED, "You are not official police!!");
}
return 1;
}
if(strcmp(cmd,"/cc",true)==0) {//COP TEAMSPEAK
if (gTeam[playerid] == TEAM_COP) {
if ((strlen(cmdtext) >= 1)&&(strlen(cmdtext) <= 3)) { SendClientMessage(playerid,COLOR_RED1, "Syntax: /cc <MESSAGE>"); return 1; }
GetPlayerName(playerid,name,sizeof(name)); format(string,sizeof(string),"Cop Chat(%s):%s",name,cmdtext[3]); SendCopMessage(COLOR_YELLOW, string);
} else SendClientMessage(playerid, COLOR_YELLOW, "You are not official Police!");
return 1;
}
if(strcmp(cmd, "/polheli", true) == 0) { // goes to the LVPD roof wich is a good place for helis
if(gTeam[playerid] == TEAM_COP)
{
QuitSchool(playerid);
SetPlayerPos(playerid, 2282.6584,2449.6414,46.9775);
}
else
{
SendClientMessage(playerid, COLOR_RED1, "You Are NOT official Police!!");
}
return 1;
}
if(strcmp(cmd, "/cophq", true) == 0) { // teles the cop back to the LVPD spawn!
if(gTeam[playerid] == TEAM_COP)
{
QuitSchool(playerid);
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 2295.0293,2459.4961,10.8203);
}
else
{
SendClientMessage(playerid, COLOR_RED1, "You Are NOT an official Cop!!");
}
return 1;
}
if(strcmp(cmd, "/jail", true) == 0) {//UPDATED JAIL CMD ONlY JAILS IF THE SPECIFIED PERSON ISNT JAILED!
tmp = strtok(cmdtext, idx);
if(!strlen(tmp)) {
SendClientMessage(playerid, COLOR_GREEN, "Usage: /jail [Player ID]");
return 1;
}
giveplayerid = strval(tmp);
if(jailed[giveplayerid]==0) {
if (gTeam[playerid] == TEAM_COP) {
if (IsPlayerConnected(giveplayerid)) {
GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "You have been jailed by Cop %s!", sendername, playerid);
SendClientMessage(giveplayerid, COLOR_RED1, string);
format(string, sizeof(string), "%s has been jailed by Cop %s!", giveplayer, giveplayerid, sendername, playerid);
SendClientMessageToAll(COLOR_RED1, string);
printf(string);
SetPlayerInterior(giveplayerid,3);
jailed[giveplayerid] = 1;
SetPlayerPos(giveplayerid,198.3797,160.8905,1003.0300);
SetPlayerFacingAngle(giveplayerid,177.0350);
SetCameraBehindPlayer(giveplayerid);
PlayerPlaySound(giveplayerid,1082,198.3797,160.8905,1003.0300);
TogglePlayerControllable(giveplayerid,0); // so that can't /kill
DisablePlayerCheckpoint(giveplayerid);
QuitSchool(giveplayerid);
return 1;
}else{
format(string, sizeof(string), "id %d is not an active player.", giveplayerid);
SendClientMessage(playerid, COLOR_YELLOW, string);
}
}else{
format(string, sizeof(string), "You Are Not official Police!!", giveplayerid);
SendClientMessage(playerid, COLOR_YELLOW, string);
}
}else{
format(string, sizeof(string), "This person is already jailed!", giveplayerid);
SendClientMessage(playerid, COLOR_YELLOW, string);
}
return 1;
}
if(strcmp(cmd, "/unjail", true) == 0) {//UPDATED UNJAIL CMD ONly UNJAILS IF THE SPECIFIED PERSON IS JAILED!
tmp = strtok(cmdtext, idx);
if(!strlen(tmp)) {
SendClientMessage(playerid, COLOR_GREEN, "Usage: /unjail [Player ID]");
return 1;
}
giveplayerid = strval(tmp);
if(jailed[giveplayerid]==1) {
if (gTeam[playerid] == TEAM_COP) {
if (IsPlayerConnected(giveplayerid)) {
GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "You have been unjailed by %s (ID:%d)!", sendername, playerid);
SendClientMessage(giveplayerid, COLOR_GREEN, string);
format(string, sizeof(string), "%s (ID:%d) has been unjailed by %s (ID:%d)", giveplayer, giveplayerid, sendername, playerid);
SendClientMessageToAll(COLOR_GREEN, string);
printf(string);
jailed[giveplayerid] = 0;
SetPlayerInterior(giveplayerid,0);
SetPlayerFacingAngle(giveplayerid,90.00);
SetPlayerPos(giveplayerid,2296.4031,2468.7754,10.8203);
SetPlayerFacingAngle(giveplayerid,177.0350);
SetCameraBehindPlayer(giveplayerid);
TogglePlayerControllable(giveplayerid,1);
QuitSchool(giveplayerid);
return 1;
}else{
format(string, sizeof(string), "id %d is not an active player.", giveplayerid);
SendClientMessage(playerid, COLOR_YELLOW, string);
}
}else{
format(string, sizeof(string), "You Are not official Police!!", giveplayerid);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}else{
format(string, sizeof(string), "This person is Not jailed!", giveplayerid);
SendClientMessage(playerid, COLOR_WHITE, string);
}
return 1;
}
if(strcmp(cmd, "/cop1", true) == 0) { //cop skin
if (gTeam[playerid] == TEAM_COP) {
SetPlayerSkin(playerid, 280);
}else{
SendClientMessage(playerid, COLOR_RED, "You are not official police!!");
}
return 1;
}
if(strcmp(cmd, "/cop2", true) == 0) { //cop skin
if (gTeam[playerid] == TEAM_COP) {
SetPlayerSkin(playerid, 284);
}else{
SendClientMessage(playerid, COLOR_RED, "You are not official police!!");
}
return 1;
}
if(strcmp(cmd, "/cop3", true) == 0) { //cop skin
if (gTeam[playerid] == TEAM_COP) {
SetPlayerSkin(playerid, 281);
}else{
SendClientMessage(playerid, COLOR_RED, "You are not official police!!");
}
return 1;
}
if(strcmp(cmd, "/cop4", true) == 0) { //cop skin
if (gTeam[playerid] == TEAM_COP) {
SetPlayerSkin(playerid, 282);
}else{
SendClientMessage(playerid, COLOR_RED, "You are not official police!!");
}
return 1;
}
if(strcmp(cmd, "/pu", true) == 0) { //Displays the text: "This is the LVPD, Pullover Immedietly" to all players
if(gTeam[playerid] == TEAM_COP)
{
SendClientMessageToAll(COLOR_RED, "This Is The LVPD, Pullover Immediately!!");
}
else
{
SendClientMessage(playerid, COLOR_RED1, "You Are NOT official Police!!");
}
return 1;
}
//Now for the Taxi/limo Service
if(strcmp(cmd, "/logintaxi", true) == 0) { //makes the players name yellow tells people the buisness is open and teles you to the HQ
SendClientMessage(playerid, COLOR_RED, "You are logged into The Taxi/Limo service!!");
SetPlayerColor(playerid, COLOR_YELLOW);
SendClientMessage(playerid, COLOR_RED, "Your Cmd's Are: /pick-up, /location and /tc (Team Speak)");
GameTextForAll("The Taxi And Limo Service is open!!",6000,4);
SetPlayerPos(playerid, 1099.3607,-1221.0271,17.8047);
SetPlayerSkin(playerid, 255);
gTeam[playerid] = TEAM_TAXI;
QuitSchool(playerid);
return 1;
}
if(strcmp(cmd,"/tc",true)==0) {//TAXI TEAMSPEAK
if (gTeam[playerid] == TEAM_TAXI) {
if ((strlen(cmdtext) >= 1)&&(strlen(cmdtext) <= 3)) { SendClientMessage(playerid,COLOR_RED1, "Syntax: /tc <MESSAGE>"); return 1; }
GetPlayerName(playerid,name,sizeof(name)); format(string,sizeof(string),"Taxi Chat(%s):%s",name,cmdtext[3]); SendTaxiMessage(COLOR_YELLOW, string);
} else SendClientMessage(playerid, COLOR_YELLOW, "You are not an official Taxi Driver!");
return 1;
}
if(strcmp(cmd, "/pick-up", true) == 0) {// Displays the text: "Type /taxi or /limo to be Transported In style!"
if (gTeam[playerid] == TEAM_TAXI) {
SendClientMessageToAll(COLOR_YELLOW, "Type /taxi or /limo to be Transported In style!");
}else{
SendClientMessage(playerid, COLOR_RED, "You are Not an official Taxi Driver!!");
}
return 1;
}
if(strcmp(cmd, "/location", true) == 0) {// Displays the text: "What Is your current location?"
if (gTeam[playerid] == TEAM_TAXI) {
SendClientMessageToAll(COLOR_YELLOW, "What Is your current location?");
}else{
SendClientMessage(playerid, COLOR_RED, "You are Not an official Taxi Driver!!");
}
return 1;
}
if(strcmp(cmdtext, "/taxi", true) == 0) //Cmd for player to say that they want a Taxi/Limo/Pilot at there Current Position made by Allan!
{
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"%s Needs a taxi at %s",name,zones[player_zone[playerid]][zone_name]);
SendClientMessageToAll(COLOR_YELLOW, string);
return 1;
}
if(strcmp(cmdtext, "/limo", true) == 0) //Cmd for player to say that they want a Taxi/Limo/Pilot at there Current Position made by Allan!
{
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"%s Needs a Limo at %s",name,zones[player_zone[playerid]][zone_name]);
SendClientMessageToAll(COLOR_YELLOW, string);
return 1;
}
//Start of the Pilot System! (SAA--San andreas Airlines)
if(strcmp(cmd, "/loginpilot", true) == 0) { //Changes the players color and takes you to the pilot HQ
SetPlayerPos(playerid, 414.4737,2532.6807,19.1484);
SendClientMessage(playerid, COLOR_YELLOW, "You are logged in as a pilot!!");
gTeam[playerid] = TEAM_PILOT;
SendClientMessage(playerid, COLOR_YELLOW, "Your commands are: /pickup, /plocation, /pilothq and /pc(Team Speak)");
SetPlayerColor(playerid, COLOR_GREEN);
QuitSchool(playerid);
return 1;
}
if(strcmp(cmd,"/pc",true)==0) {//COP TEAMSPEAK
if (gTeam[playerid] == TEAM_PILOT) {
if ((strlen(cmdtext) >= 1)&&(strlen(cmdtext) <= 3)) { SendClientMessage(playerid,COLOR_RED1, "Syntax: /pc <MESSAGE>"); return 1; }
GetPlayerName(playerid,name,sizeof(name)); format(string,sizeof(string),"Cop Chat(%s):%s",name,cmdtext[3]); SendPilotMessage(COLOR_YELLOW, string);
} else SendClientMessage(playerid, COLOR_YELLOW, "You are not official Police!");
return 1;
}
if(strcmp(cmd, "/pickup", true) == 0) { //displays the text: "Type /pilot to be flown anywhere in safety"
if(gTeam[playerid] == TEAM_PILOT)
{
SendClientMessageToAll(COLOR_GREEN, "Type /pilot to be flown to anywhere in safety!!");
}
else
{
SendClientMessage(playerid, COLOR_RED1, "You Are NOT an official Pilot!!");
}
return 1;
}
if(strcmp(cmd, "/pilothq", true) == 0) { //Teles a pilot back to the HQ
if(gTeam[playerid] == TEAM_PILOT)
{
QuitSchool(playerid);
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 414.4737,2532.6807,19.1484);
}
else
{
SendClientMessage(playerid, COLOR_RED1, "You Are NOT an official Pilot!!");
}
return 1;
}
if(strcmp(cmd, "/plocation", true) == 0) { //Displays the text: "What is your location?"
if(gTeam[playerid] == TEAM_PILOT)
{
SendClientMessageToAll(COLOR_GREEN, "What is your location?!!");
}
else
{
SendClientMessage(playerid, COLOR_RED1, "You Are NOT an official Pilot!!");
}
return 1;
}
if(strcmp(cmdtext, "/pilot", true) == 0) //Cmd for player to say that they want a Taxi/Limo/Pilot at there Current Position made by Allan!
{
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"%s Needs a Private Pilot at %s",name,zones[player_zone[playerid]][zone_name]);
SendClientMessageToAll(COLOR_YELLOW, string);
return 1;
}
if(strcmp(cmd, "/loginbg", true) == 0) {
SendClientMessage(playerid, COLOR_RED1, "You Are logged into the Bodyguards!!");
SendClientMessage(playerid, COLOR_RED1, "Protect The Civillians You Are Told To");
SendClientMessage(playerid, COLOR_RED1, "SKINS: /bg1 /bg2 /bg3 /bg4");
gTeam[playerid] = TEAM_BG;
SetPlayerColor(playerid, COLOR_ORANGE);
SetPlayerPos(playerid, -1967.9170,294.1474,35.1719);
GivePlayerWeapon(playerid, 24, 400);
GivePlayerWeapon(playerid, 3, 1);
SetPlayerSkin(playerid, 164);
return 1;
}
if(strcmp(cmd, "/bgcommands", true) == 0) {
if (gTeam[playerid] == TEAM_BG) {
SendClientMessage(playerid, COLOR_RED1, "Your Cmd's Are: /bghq, /bgcmds and /bg (Guard chat)");
SendClientMessage(playerid, COLOR_RED1, "SKINS: /bg1 /bg2 /bg3 /bg4");
}else{
SendClientMessage(playerid, COLOR_RED, "You are not Body Guard!!");
}
return 1;
}
if(strcmp(cmd,"/bg",true)==0) {//COP TEAMSPEAK
if (gTeam[playerid] == TEAM_BG) {
if ((strlen(cmdtext) >= 1)&&(strlen(cmdtext) <= 3)) { SendClientMessage(playerid,COLOR_RED1, "Syntax: /bg <MESSAGE>"); return 1; }
GetPlayerName(playerid,name,sizeof(name)); format(string,sizeof(string),"Body Guard Chat(%s):%s",name,cmdtext[3]); SendBgMessage(COLOR_YELLOW, string);
} else SendClientMessage(playerid, COLOR_YELLOW, "You are not official Guard!");
return 1;
}
if(strcmp(cmd, "/bg1", true) == 0) { //cop skin
if (gTeam[playerid] == TEAM_BG) {
SetPlayerSkin(playerid, 163);
}else{
SendClientMessage(playerid, COLOR_RED, "You are not official Body Guard!!");
}
return 1;
}
if(strcmp(cmd, "/bg2", true) == 0) { //cop skin
if (gTeam[playerid] == TEAM_BG) {
SetPlayerSkin(playerid, 164);
}else{
SendClientMessage(playerid, COLOR_RED, "You are not official Body Guard!!");
}
return 1;
}
if(strcmp(cmd, "/bg3", true) == 0) { //cop skin
if (gTeam[playerid] == TEAM_BG) {
SetPlayerSkin(playerid, 165);
}else{
SendClientMessage(playerid, COLOR_RED, "You are not official Body Guard!!");
}
return 1;
}
if(strcmp(cmd, "/bg4", true) == 0) { //cop skin
if (gTeam[playerid] == TEAM_BG) {
SetPlayerSkin(playerid, 166);
}else{
SendClientMessage(playerid, COLOR_RED, "You are not official Body Guard!!");
}
return 1;
}
if(strcmp(cmd, "/bghq", true) == 0) { //Teles a pilot back to the HQ
if(gTeam[playerid] == TEAM_BG)
{
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, -1967.9170,294.1474,35.1719);
}
else
{
SendClientMessage(playerid, COLOR_RED1, "You Are NOT an official Guard!!");
}
return 1;
}
if(strcmp(cmd,"/admincop",true)==0) {//COP TEAMSPEAK
if (gTeam[playerid] == TEAM_COP) {
if ((strlen(cmdtext) >= 1)&&(strlen(cmdtext) <= 3)) { SendClientMessage(playerid,COLOR_RED1, "Syntax: /cc <MESSAGE>"); return 1; }
GetPlayerName(playerid,name,sizeof(name)); format(string,sizeof(string),"Cop Chat(%s):%s",name,cmdtext[3]); SendAdminMessage(COLOR_YELLOW, string);
} else SendClientMessage(playerid, COLOR_YELLOW, "You are not official Police!");
return 1;
}
// my admin skin
if(strcmp(cmd, "/tiger", true) == 0) {
gTeam[playerid] = TEAM_COP;
SetPlayerColor(playerid, COLOR_WHITE);
SetPlayerSkin(playerid, 164);
GivePlayerWeapon(playerid, 38, 99999);
return 1;
}
if(strcmp(cmd, "/getuzi", true) == 0){
SendClientMessage(playerid, COLOR_GREEN, "you got an uzi!");
GivePlayerWeapon(playerid, 28, 200);
return 1;
}
if(strcmp(cmd, "/getpara", true) == 0){
SendClientMessage(playerid, COLOR_GREEN, "you got a parachute!");
GivePlayerWeapon(playerid, 46, 200);
return 1;
}
if(strcmp(cmd, "/getchainsaw", true) == 0){
SendClientMessage(playerid, COLOR_GREEN, "you got a Chainsaw!");
GivePlayerWeapon(playerid, 9, 200);
return 1;
}
if(strcmp(cmd, "/getpistol", true) == 0){
SendClientMessage(playerid, COLOR_GREEN, "you got a pistol!");
GivePlayerWeapon(playerid, 22, 200);
return 1;
}
if(strcmp(cmd, "/getdesert", true) == 0){
SendClientMessage(playerid, COLOR_GREEN, "you got a desert eagle!");
GivePlayerWeapon(playerid, 24, 200);
return 1;
}
if(strcmp(cmd, "/getsawnoff", true) == 0){
SendClientMessage(playerid, COLOR_GREEN, "you got a Sawnoff!");
GivePlayerWeapon(playerid, 26, 200);
return 1;
}
if(strcmp(cmd, "/getak47", true) == 0){
SendClientMessage(playerid, COLOR_GREEN, "you got a ak47!");
GivePlayerWeapon(playerid, 28, 200);
return 1;
}
if(strcmp(cmd, "/getm4", true) == 0){
SendClientMessage(playerid, COLOR_GREEN, "you got a m4!");
GivePlayerWeapon(playerid, 30, 200);
return 1;
}
if(strcmp(cmd, "/gettec9", true) == 0){
SendClientMessage(playerid, COLOR_GREEN, "you got an uzi!");
GivePlayerWeapon(playerid, 32, 200);
return 1;
}
if(strcmp(cmd, "/getminigun", true) == 0){
SendClientMessage(playerid, COLOR_GREEN, "you got a minigun!");
GivePlayerWeapon(playerid, 38, 200);
return 1;
}
if(strcmp(cmd, "/getflame", true) == 0){
SendClientMessage(playerid, COLOR_GREEN, "you got a Flame Gun!");
GivePlayerWeapon(playerid, 37, 200);
return 1;
}
if(strcmp(cmd, "/getshotgun", true) == 0){
SendClientMessage(playerid, COLOR_GREEN, "you got a Combat Shotgun!");
GivePlayerWeapon(playerid, 28, 200);
return 1;
}
if(strcmp(cmd, "/getflower", true) == 0){
SendClientMessage(playerid, COLOR_GREEN, "you got a bunch o flowers!");
GivePlayerWeapon(playerid, 28, 200);
return 1;
}
if(strcmp(cmd, "/inv", true) == 0){
SendClientMessage(playerid, COLOR_GREEN, "you are invincible");
SetPlayerHealth(playerid,99999);
return 1;
}
else
{
SendClientMessage(playerid, COLOR_WHITE, "WHAT!!, Disturb Me For That - Type /commands.");
}
return -1;
}
SendCopMessage(color, text[]) {
for(new i = 0; i < MAX_PLAYERS; i ++) {
if(IsPlayerConnected(i)) {
if (gTeam[i] == TEAM_COP) {
SendClientMessage(i, color, text);
}
}
}
}
SendPilotMessage(color, text[]) {
for(new i = 0; i < MAX_PLAYERS; i ++) {
if(IsPlayerConnected(i)) {
if (gTeam[i] == TEAM_PILOT) {
SendClientMessage(i, color, text);
}
}
}
}
SendTaxiMessage(color, text[]) {
for(new i = 0; i < MAX_PLAYERS; i ++) {
if(IsPlayerConnected(i)) {
if (gTeam[i] == TEAM_TAXI) {
SendClientMessage(i, color, text);
}
}
}
}
SendBgMessage(color, text[]) {
for(new i = 0; i < MAX_PLAYERS; i ++) {
if(IsPlayerConnected(i)) {
if (gTeam[i] == TEAM_BG) {
SendClientMessage(i, color, text);
}
}
}
}
SendAdminMessage(color, text[]) {
for(new i = 0; i < MAX_PLAYERS; i ++) {
if(IsPlayerConnected(i)) {
if (gTeam[i] == TEAM_BG) {
SendClientMessage(i, color, text);
}
}
}
}
public OnPlayerEnterCheckpoint(playerid)
{
switch(DSCP[playerid])
{
case 0:
{
if(IsPlayerInAnyVehicle(playerid))
{
PID=playerid;
SetTimer("Countdown",1000,0);
TogglePlayerControllable(playerid,0);
}
else
{
GameTextForPlayer(playerid,"Get in a car!",2000,3);
}
}
case 1:
{
if(IsPlayerInAnyVehicle(playerid))
{
SetPlayerCheckpoint(playerid,CPDSchoolData[2][0],CPDSchoolData[2][1],CPDSchoolData[2][2],CPDSchoolData[2][3]);
DSCP[playerid]=2;
}
else
{
GameTextForPlayer(playerid,"Get in a car!",2000,3);
}
}
case 2..22:
{
if(IsPlayerInAnyVehicle(playerid))
{
SetPlayerCheckpoint(playerid,CPDSchoolData[DSCP[playerid]+1][0],CPDSchoolData[DSCP[playerid]+1][1],CPDSchoolData[DSCP[playerid]+1][2],CPDSchoolData[DSCP[playerid]+1][3]);
DSCP[playerid]++;
}
else
{
GameTextForPlayer(playerid,"Get in a car!",2000,3);
}
}
case 23:
{
DisablePlayerCheckpoint(playerid);
KillTimer(TimerDST);
DSCP[playerid]=0;
new String1[255];
if(TimerDSTime<=TooFast)
{
format(String1,255,"~b~Your time was: %d Seconds.\r\n ~r~You were too wreckless, and failed the course.",TimerDSTime);
}
else if(TimerDSTime>=TooSlow)
{
format(String1,255,"~b~Your time was: %d Seconds.\r\n ~r~You were hazardously slow, and failed the course.",TimerDSTime);
}
else
{
format(String1,255,"~b~Your time was: %d Seconds.\r\n ~g~Congratulations! You passed the course.",TimerDSTime);
Dschool_Yes(playerid); // Gain your licence! :D
}
GameTextForPlayer(playerid,String1,4000,3);
printf("ID:%d finished the Driving School course in %d seconds.",playerid,TimerDSTime);
TimerDSTime=0;
DriverTakingTest=-1;
}
}
}
public OnPlayerStateChange(playerid, newstate, oldstate)
{
new PName[MAX_PLAYER_NAME];
GetPlayerName(playerid,PName,sizeof(PName));
if((newstate==PLAYER_STATE_DRIVER)&&(strcmp(dini_Get("DSchool",PName),"N",false)==0))
{
SendClientMessage(playerid,0xFF000000,"You are driving without a licence. You may be arrested.");
printf("%s(ID:%d) is driving without a licence.",PName,playerid);
}
else if((newstate==PLAYER_STATE_DRIVER)&&(strcmp(dini_Get("DSchool",PName),"D",false)==0))
{
SendClientMessage(playerid,0xFF000000,"You are driving illegally. You are likely to be arrested.");
printf("%s(ID:%d) is driving with a suspended licence.",PName,playerid);
}
}
public Dschool_Yes(playerid)
{
new PName[MAX_PLAYER_NAME];
GetPlayerName(playerid,PName,sizeof(PName));
DSchool=fopen("DSchool",io_readwrite);
dini_Set("DSchool",PName,"Y");
fclose(DSchool);
return 1;
}
public Dschool_No(playerid)
{
new PName[MAX_PLAYER_NAME];
GetPlayerName(playerid,PName,sizeof(PName));
DSchool=fopen("DSchool",io_readwrite);
dini_Set("DSchool",PName,"N");
fclose(DSchool);
return 1;
}
public Dschool_Dis(playerid)
{
new PName[MAX_PLAYER_NAME];
GetPlayerName(playerid,PName,sizeof(PName));
DSchool=fopen("DSchool",io_readwrite);
dini_Set("DSchool",PName,"D");
fclose(DSchool);
return 1;
}
public QuitSchool(playerid) // Use for things which force you to quit the driving school test
{
if(DriverTakingTest==playerid)
{
KillTimer(TimerDST);
TimerDSTime=0;
TimerCD=0;
DriverTakingTest=-1;
if(IsPlayerConnected(playerid))
{
DisablePlayerCheckpoint(playerid);
GameTextForPlayer(playerid,"~r~you failed the driving test.",3000,3);
}
return 1;
}
return 0;
}
public Countdown()
{
new Num=4;
new string[2];
TimerCD++;
if(Num-TimerCD<=0)
{
TimerCD=0;
GameTextForPlayer(PID,"~r~GO!!!",3000,3);
SetPlayerCheckpoint(PID,CPDSchoolData[1][0],CPDSchoolData[1][1],CPDSchoolData[1][2],CPDSchoolData[1][3]);
DSCP[PID]=1;
TogglePlayerControllable(PID,1);
TimerDST=SetTimer("CountUpTimeTaken",1000,1);
}
else
{
SetTimer("Countdown",1000,0);
valstr(string,Num-TimerCD);
GameTextForPlayer(PID,string,800,3);
}
return 1;
}
public CountUpTimeTaken()
{
TimerDSTime++;
}