Problem with team colors
#1

Hello,i have little problem.I've defined teams and team colors,there is no errors,warnings , but when i spawn as any skin i get lightblue (team_cop) color.I read my script many times,but always it was correct.Please help.
Here is script:
Код:
// This is a comment
// uncomment the line below if you want to write a filterscript
//#define FILTERSCRIPT

#include <a_samp>
#include <streamer>



#define TEAM_COP 1
#define TEAM_ARMY 2
#define TEAM_PARAMEDIC 3
#define TEAM_TRIAD 4
#define TEAM_MAFIA 5
#define TEAM_MEMBER 6
#define TEAM_STREET_RACER 7
#define TEAM_BIKER 8
#define TEAM_PROSTITUTE 9
#define TEAM_FIREWORKER 10
#define TEAM_DRIVER 11
#define TEAM_PILOT 12
#define TEAM_CIVIL 13


#define TEAM_COP_COLOR 0xADD8E6FF // blue
#define TEAM_ARMY_COLOR 0x008000FF // green
#define TEAM_PARAMEDIC_COLOR 0xFFFFFFFF // white
#define TEAM_TRIAD_COLOR 0xFFFFFFFF // white
#define TEAM_MAFIA_COLOR 0xFFFFFFFF // white
#define TEAM_MEMBER_COLOR 0xFFFFFFFF // white
#define TEAM_STREET_RACER_COLOR 0xFFFFFFFF // white
#define TEAM_BIKER_COLOR 0xFFFFFFFF // white
#define TEAM_PROSTITUTE_COLOR 0xFFFFFFFF // white
#define TEAM_FIREWORKER_COLOR 0xFFFFFFFF // white
#define TEAM_DRIVER_COLOR 0xFFFFFFFF // white
#define TEAM_PILOT_COLOR 0xFFFFFFFF // white
#define TEAM_CIVIL_COLOR 0xFFFFFFFF // white

//colors
#define COLOR_GREY 0xAFAFAFAA
#define COLOR_ACTIVEBORDER 0xB4B4B4FF
#define COLOR_ACTIVECAPTION 0x99B4D1FF
#define COLOR_ACTIVECAPTIONTEXT 0x000000FF
#define COLOR_ALICEBLUE 0xF0F8FFFF
#define COLOR_ANTIQUEWHITE 0xFAEBD7FF
#define COLOR_APPWORKSPACE 0xABABABFF
#define COLOR_AQUA 0x00FFFFFF
#define COLOR_AQUAMARINE 0x7FFFD4FF
#define COLOR_AZURE 0xF0FFFFFF
#define COLOR_BEIGE 0xF5F5DCFF
#define COLOR_BISQUE 0xFFE4C4FF
#define COLOR_BLACK 0x000000FF
#define COLOR_BLANCHEDALMOND 0xFFEBCDFF
#define COLOR_BLUE 0x0000FFFF
#define COLOR_BLUEVIOLET 0x8A2BE2FF
#define COLOR_BROWN 0xA52A2AFF
#define COLOR_BURLYWOOD 0xDEB887FF
#define COLOR_BUTTONFACE 0xF0F0F0FF
#define COLOR_BUTTONHIGHLIGHT 0xFFFFFFFF
#define COLOR_BUTTONSHADOW 0xA0A0A0FF
#define COLOR_CADETBLUE 0x5F9EA0FF
#define COLOR_CHARTREUSE 0x7FFF00FF
#define COLOR_CHOCOLATE 0xD2691EFF
#define COLOR_CONTROL 0xF0F0F0FF
#define COLOR_CONTROLDARK 0xA0A0A0FF
#define COLOR_CONTROLDARKDARK 0x696969FF
#define COLOR_CONTROLLIGHT 0xE3E3E3FF
#define COLOR_CONTROLLIGHTLIGHT 0xFFFFFFFF
#define COLOR_CONTROLTEXT 0x000000FF
#define COLOR_CORAL 0xFF7F50FF
#define COLOR_CORNFLOWERBLUE 0x6495EDFF
#define COLOR_CORNSILK 0xFFF8DCFF
#define COLOR_CRIMSON 0xDC143CFF
#define COLOR_CYAN 0x00FFFFFF
#define COLOR_DARKBLUE 0x00008BFF
#define COLOR_DARKCYAN 0x008B8BFF
#define COLOR_DARKGOLDENROD 0xB8860BFF
#define COLOR_DARKGRAY 0xA9A9A9FF
#define COLOR_DARKGREEN 0x006400FF
#define COLOR_DARKKHAKI 0xBDB76BFF
#define COLOR_DARKMAGENTA 0x8B008BFF
#define COLOR_DARKOLIVEGREEN 0x556B2FFF
#define COLOR_DARKORANGE 0xFF8C00FF
#define COLOR_DARKORCHID 0x9932CCFF
#define COLOR_DARKRED 0x8B0000FF
#define COLOR_DARKSALMON 0xE9967AFF
#define COLOR_DARKSEAGREEN 0x8FBC8BFF
#define COLOR_DARKSLATEBLUE 0x483D8BFF
#define COLOR_DARKSLATEGRAY 0x2F4F4FFF
#define COLOR_DARKTURQUOISE 0x00CED1FF
#define COLOR_DARKVIOLET 0x9400D3FF
#define COLOR_DEEPPINK 0xFF1493FF
#define COLOR_DEEPSKYBLUE 0x00BFFFFF
#define COLOR_DESKTOP 0x000000FF
#define COLOR_DIMGRAY 0x696969FF
#define COLOR_DODGERBLUE 0x1E90FFFF
#define COLOR_FIREBRICK 0xB22222FF
#define COLOR_FLORALWHITE 0xFFFAF0FF
#define COLOR_FORESTGREEN 0x228B22FF
#define COLOR_FUCHSIA 0xFF00FFFF
#define COLOR_GAINSBORO 0xDCDCDCFF
#define COLOR_GHOSTWHITE 0xF8F8FFFF
#define COLOR_GOLD 0xFFD700FF
#define COLOR_GOLDENROD 0xDAA520FF
#define COLOR_GRADIENTACTIVECAPTION 0xB9D1EAFF
#define COLOR_GRADIENTINACTIVECAPTION 0xD7E4F2FF
#define COLOR_GRAY 0x808080FF
#define COLOR_GRAYTEXT 0x808080FF
#define COLOR_GREEN 0x008000FF
#define COLOR_GREENYELLOW 0xADFF2FFF
#define COLOR_HIGHLIGHT 0x3399FFFF
#define COLOR_HIGHLIGHTTEXT 0xFFFFFFFF
#define COLOR_HONEYDEW 0xF0FFF0FF
#define COLOR_HOTPINK 0xFF69B4FF
#define COLOR_HOTTRACK 0x0066CCFF
#define COLOR_INACTIVEBORDER 0xF4F7FCFF
#define COLOR_INACTIVECAPTION 0xBFCDDBFF
#define COLOR_INACTIVECAPTIONTEXT 0x434E54FF
#define COLOR_INDIANRED 0xCD5C5CFF
#define COLOR_INDIGO 0x4B0082FF
#define COLOR_INFO 0xFFFFE1FF
#define COLOR_INFOTEXT 0x000000FF
#define COLOR_IVORY 0xFFFFF0FF
#define COLOR_KHAKI 0xF0E68CFF
#define COLOR_LAVENDER 0xE6E6FAFF
#define COLOR_LAVENDERBLUSH 0xFFF0F5FF
#define COLOR_LAWNGREEN 0x7CFC00FF
#define COLOR_LEMONCHIFFON 0xFFFACDFF
#define COLOR_LIGHTBLUE 0xADD8E6FF
#define COLOR_LIGHTCORAL 0xF08080FF
#define COLOR_LIGHTCYAN 0xE0FFFFFF
#define COLOR_LIGHTGOLDENRODYELLOW 0xFAFAD2FF
#define COLOR_LIGHTGRAY 0xD3D3D3FF
#define COLOR_LIGHTGREEN 0x90EE90FF
#define COLOR_LIGHTPINK 0xFFB6C1FF
#define COLOR_LIGHTSALMON 0xFFA07AFF
#define COLOR_LIGHTSEAGREEN 0x20B2AAFF
#define COLOR_LIGHTSKYBLUE 0x87CEFAFF
#define COLOR_LIGHTSLATEGRAY 0x778899FF
#define COLOR_LIGHTSTEELBLUE 0xB0C4DEFF
#define COLOR_LIGHTYELLOW 0xFFFFE0FF
#define COLOR_LIME 0x00FF00FF
#define COLOR_LIMEGREEN 0x32CD32FF
#define COLOR_LINEN 0xFAF0E6FF
#define COLOR_MAGENTA 0xFF00FFFF
#define COLOR_MAROON 0x800000FF
#define COLOR_MEDIUMAQUAMARINE 0x66CDAAFF
#define COLOR_MEDIUMBLUE 0x0000CDFF
#define COLOR_MEDIUMORCHID 0xBA55D3FF
#define COLOR_MEDIUMPURPLE 0x9370DBFF
#define COLOR_MEDIUMSEAGREEN 0x3CB371FF
#define COLOR_MEDIUMSLATEBLUE 0x7B68EEFF
#define COLOR_MEDIUMSPRINGGREEN 0x00FA9AFF
#define COLOR_MEDIUMTURQUOISE 0x48D1CCFF
#define COLOR_MEDIUMVIOLETRED 0xC71585FF
#define COLOR_MENU 0xF0F0F0FF
#define COLOR_MENUBAR 0xF0F0F0FF
#define COLOR_MENUHIGHLIGHT 0x3399FFFF
#define COLOR_MENUTEXT 0x000000FF
#define COLOR_MIDNIGHTBLUE 0x191970FF
#define COLOR_MINTCREAM 0xF5FFFAFF
#define COLOR_MISTYROSE 0xFFE4E1FF
#define COLOR_MOCCASIN 0xFFE4B5FF
#define COLOR_NAVAJOWHITE 0xFFDEADFF
#define COLOR_NAVY 0x000080FF
#define COLOR_OLDLACE 0xFDF5E6FF
#define COLOR_OLIVE 0x808000FF
#define COLOR_OLIVEDRAB 0x6B8E23FF
#define COLOR_ORANGE 0xFFA500FF
#define COLOR_ORANGERED 0xFF4500FF
#define COLOR_ORCHID 0xDA70D6FF
#define COLOR_PALEGOLDENROD 0xEEE8AAFF
#define COLOR_PALEGREEN 0x98FB98FF
#define COLOR_PALETURQUOISE 0xAFEEEEFF
#define COLOR_PALEVIOLETRED 0xDB7093FF
#define COLOR_PAPAYAWHIP 0xFFEFD5FF
#define COLOR_PEACHPUFF 0xFFDAB9FF
#define COLOR_PERU 0xCD853FFF
#define COLOR_PINK 0xFFC0CBFF
#define COLOR_PLUM 0xDDA0DDFF
#define COLOR_POWDERBLUE 0xB0E0E6FF
#define COLOR_PURPLE 0x800080FF
#define COLOR_RED 0xFF0000FF
#define COLOR_ROSYBROWN 0xBC8F8FFF
#define COLOR_ROYALBLUE 0x4169E1FF
#define COLOR_SADDLEBROWN 0x8B4513FF
#define COLOR_SALMON 0xFA8072FF
#define COLOR_SANDYBROWN 0xF4A460FF
#define COLOR_SCROLLBAR 0xC8C8C8FF
#define COLOR_SEAGREEN 0x2E8B57FF
#define COLOR_SEASHELL 0xFFF5EEFF
#define COLOR_SIENNA 0xA0522DFF
#define COLOR_SILVER 0xC0C0C0FF
#define COLOR_SKYBLUE 0x87CEEBFF
#define COLOR_SLATEBLUE 0x6A5ACDFF
#define COLOR_SLATEGRAY 0x708090FF
#define COLOR_SNOW 0xFFFAFAFF
#define COLOR_SPRINGGREEN 0x00FF7FFF
#define COLOR_STEELBLUE 0x4682B4FF
#define COLOR_TAN 0xD2B48CFF
#define COLOR_TEAL 0x008080FF
#define COLOR_THISTLE 0xD8BFD8FF
#define COLOR_TOMATO 0xFF6347FF
#define COLOR_TRANSPARENT 0xFFFFFF00
#define COLOR_TURQUOISE 0x40E0D0FF
#define COLOR_VIOLET 0xEE82EEFF
#define COLOR_WHEAT 0xF5DEB3FF
#define COLOR_WHITE 0xFFFFFFFF
#define COLOR_WHITESMOKE 0xF5F5F5FF
#define COLOR_WINDOW 0xFFFFFFFF
#define COLOR_WINDOWFRAME 0x646464FF
#define COLOR_WINDOWTEXT 0x000000FF
#define COLOR_YELLOW 0xFFFF00FF
#define COLOR_YELLOWGREEN 0x9ACD32FF
#define STEALTH_ORANGE 0xFF880000
#define STEALTH_OLIVE 0x66660000
#define STEALTH_GREEN 0x33DD1100
#define STEALTH_PINK 0xFF22EE00
#define STEALTH_BLUE 0x0077BB00


new gTeam[MAX_PLAYERS];
new pClass[MAX_PLAYERS];


#if defined FILTERSCRIPT

public OnFilterScriptInit()
{
	print("\n--------------------------------------");
	print(" Blank Filterscript by your name here");
	print("--------------------------------------\n");
	return 1;
}

public OnFilterScriptExit()
{
	return 1;
}

#else

main()
{
	print("\n----------------------------------");
	print(" THB v1.0");
	print("----------------------------------\n");
}

#endif

public OnGameModeInit()
{
	// Don't use these lines if it's a filterscript
	SetGameModeText("Blank Script");
    AddPlayerClass(280,-1589.0317,716.2036,-5.2422,270.6419, 5, 0, 22, 100, 32, 50); // Police spawn
    AddPlayerClass(281,-1589.0317,716.2036,-5.2422,270.6419, 5, 0, 22, 100, 32, 50); // Police spawn
    AddPlayerClass(282,-1589.0317,716.2036,-5.2422,270.6419,0,0,0,0,0,0); // Police spawn
    AddPlayerClass(283,-1589.0317,716.2036,-5.2422,270.6419,0,0,0,0,0,0); // Police spawn
    AddPlayerClass(284,-1589.0317,716.2036,-5.2422,270.6419,0,0,0,0,0,0); // Police spawn
    AddPlayerClass(285,-1589.0317,716.2036,-5.2422,270.6419,0,0,0,0,0,0); // Police spawn
    AddPlayerClass(286,-1589.0317,716.2036,-5.2422,270.6419,0,0,0,0,0,0); // Police spawn
    AddPlayerClass(288,-1589.0317,716.2036,-5.2422,270.6419,0,0,0,0,0,0); // Police spawn
    AddPlayerClass(287,-1589.0317,716.2036,-5.2422,270.6419,0,0,0,0,0,0); // Police spawn.
    AddPlayerClass(274,-2685.1360,638.4354,14.4531,182.1717,0,0,0,0,0,0); // Paramedic spawn
    AddPlayerClass(275,-2685.1360,638.4354,14.4531,182.1717,0,0,0,0,0,0); // Paramedic spawn
    AddPlayerClass(276,-2685.1360,638.4354,14.4531,182.1717,0,0,0,0,0,0); // Paramedic spawn
    AddPlayerClass(117,-2154.9688,645.6683,52.3672,274.3693,0,0,0,0,0,0); // Triad spawn
    AddPlayerClass(118,-2154.9688,645.6683,52.3672,274.3693,0,0,0,0,0,0); // Triad spawn
    AddPlayerClass(120,-2154.9688,645.6683,52.3672,274.3693,0,0,0,0,0,0); // Triad spawn
    AddPlayerClass(169,-2154.9688,645.6683,52.3672,274.3693,0,0,0,0,0,0); // Triad spawn
    AddPlayerClass(12,-2154.9688,645.6683,52.3672,274.3693,0,0,0,0,0,0); // Triad spawn
    AddPlayerClass(111,-2552.2500,52.6841,16.4219,179.4348,0,0,0,0,0,0); // Mafia spawn
    AddPlayerClass(112,-2552.2500,52.6841,16.4219,179.4348,0,0,0,0,0,0); // Mafia spawn
    AddPlayerClass(113,-2552.2500,52.6841,16.4219,179.4348,0,0,0,0,0,0); // Mafia spawn
    AddPlayerClass(98,-2552.2500,52.6841,16.4219,179.4348,0,0,0,0,0,0); // Mafia spawn
    AddPlayerClass(93,-2552.2500,52.6841,16.4219,179.4348,0,0,0,0,0,0); // Mafia spawn
    AddPlayerClass(122,-2552.2500,52.6841,16.4219,179.4348,0,0,0,0,0,0); // Mafia spawn
    AddPlayerClass(123,-2552.2500,52.6841,16.4219,179.4348,0,0,0,0,0,0); // Mafia spawn
    AddPlayerClass(195,-1854.4158,-169.1735,9.2154,275.7945,0,0,0,0,0,0); // Gang Member spawn
    AddPlayerClass(102,-1854.4158,-169.1735,9.2154,275.7945,0,0,0,0,0,0); // Gang Member spawn
    AddPlayerClass(103,-1854.4158,-169.1735,9.2154,275.7945,0,0,0,0,0,0); // Gang Member spawn
    AddPlayerClass(104,-1854.4158,-169.1735,9.2154,275.7945,0,0,0,0,0,0); // Gang Member spawn
    AddPlayerClass(105,-1854.4158,-169.1735,9.2154,275.7945,0,0,0,0,0,0); // Gang Member spawn
    AddPlayerClass(106,-1854.4158,-169.1735,9.2154,275.7945,0,0,0,0,0,0); // Gang Member spawn
    AddPlayerClass(107,-1854.4158,-169.1735,9.2154,275.7945,0,0,0,0,0,0); // Gang Member spawn
    AddPlayerClass(108,-1854.4158,-169.1735,9.2154,275.7945,0,0,0,0,0,0); // Gang Member spawn
    AddPlayerClass(109,-1854.4158,-169.1735,9.2154,275.7945,0,0,0,0,0,0); // Gang Member spawn
    AddPlayerClass(110,-1854.4158,-169.1735,9.2154,275.7945,0,0,0,0,0,0); // Gang Member spawn
    AddPlayerClass(114,-1854.4158,-169.1735,9.2154,275.7945,0,0,0,0,0,0); // Gang Member spawn
    AddPlayerClass(115,-1854.4158,-169.1735,9.2154,275.7945,0,0,0,0,0,0); // Gang Member spawn
    AddPlayerClass(116,-1854.4158,-169.1735,9.2154,275.7945,0,0,0,0,0,0); // Gang Member spawn
    AddPlayerClass(60,-2716.4021,195.2331,4.3359,270.2579,0,0,0,0,0,0); // Street Racer spawn
    AddPlayerClass(299,-2716.4021,195.2331,4.3359,270.2579,0,0,0,0,0,0); // Street Racer spawn
    AddPlayerClass(298,-2716.4021,195.2331,4.3359,270.2579,0,0,0,0,0,0); // Street Racer spawn
    AddPlayerClass(233,-2716.4021,195.2331,4.3359,270.2579,0,0,0,0,0,0); // Street Racer spawn
    AddPlayerClass(247,-1871.0201,-218.3014,18.3750,274.5897, 5, 0, 22, 100, 32, 50); // Biker spawn
    AddPlayerClass(55,-1871.0201,-218.3014,18.3750,274.5897,0,0,0,0,0,0); // Biker spawn
    AddPlayerClass(56,-1871.0201,-218.3014,18.3750,274.5897,0,0,0,0,0,0); // Biker spawn
    AddPlayerClass(248,-1871.0201,-218.3014,18.3750,274.5897,0,0,0,0,0,0); // Biker spawn
    AddPlayerClass(63,-2666.3130,1418.9774,906.2734,248.8613,0,0,0,0,0,0); // ProstituteSpawn
    AddPlayerClass(87,-2666.3130,1418.9774,906.2734,248.8613,0,0,0,0,0,0); // ProstituteSpawn
    AddPlayerClass(246,-2666.3130,1418.9774,906.2734,248.8613,0,0,0,0,0,0); // ProstituteSpawn
    AddPlayerClass(277,-2023.0736,66.9676,28.4642,264.6785,0,0,0,0,0,0); // Fireworker spawn
    AddPlayerClass(278,-2023.0736,66.9676,28.4642,264.6785,0,0,0,0,0,0); // Fireworker spawn
    AddPlayerClass(279,-2023.0736,66.9676,28.4642,264.6785,0,0,0,0,0,0); // Fireworker spawn
    AddPlayerClass(7,-2026.5653,-96.8660,35.1641,0.9079,0,0,0,0,0,0); // Driver spawn
    AddPlayerClass(9,-2026.5653,-96.8660,35.1641,0.9079,0,0,0,0,0,0); // Driver spawn
    AddPlayerClass(17,-2026.5653,-96.8660,35.1641,0.9079,0,0,0,0,0,0); // Driver spawn
    AddPlayerClass(41,-2026.5653,-96.8660,35.1641,0.9079,0,0,0,0,0,0); // Driver spawn
    AddPlayerClass(61,-1260.5909,37.9605,14.1394,221.1225,0,0,0,0,0,0); // Pilot spawn
    AddPlayerClass(10,-1946.3760,559.5967,35.1719,356.5349,0,0,0,0,0,0); // First Civilian spawn
    AddPlayerClass(11,-1946.3760,559.5967,35.1719,356.5349,0,0,0,0,0,0); // First Civilian spawn
    AddPlayerClass(20,-1946.3760,559.5967,35.1719,356.5349,0,0,0,0,0,0); // First Civilian spawn
    AddPlayerClass(27,-1946.3760,559.5967,35.1719,356.5349,0,0,0,0,0,0); // First Civilian spawn
    AddPlayerClass(28,-1946.3760,559.5967,35.1719,356.5349,0,0,0,0,0,0); // First Civilian spawn
    AddPlayerClass(40,-2424.3425,336.6029,36.9955,240.9191,0,0,0,0,0,0); // Secound Civilian spawn
    AddPlayerClass(70,-2424.3425,336.6029,36.9955,240.9191,0,0,0,0,0,0); // Secound Civilian spawn
    AddPlayerClass(79,-2424.3425,336.6029,36.9955,240.9191,0,0,0,0,0,0); // Secound Civilian spawn
    AddPlayerClass(91,-2424.3425,336.6029,36.9955,240.9191,0,0,0,0,0,0); // Secound Civilian spawn
    AddPlayerClass(137,-2424.3425,336.6029,36.9955,240.9191,0,0,0,0,0,0); // Secound Civilian spawn
    AddPlayerClass(142,-2717.6240,127.4913,5.7783,271.3702,0,0,0,0,0,0); // Third Civilan spawn
    AddPlayerClass(80,-2717.6240,127.4913,5.7783,271.3702,0,0,0,0,0,0); // Third Civilan spawn
    AddPlayerClass(172,-2717.6240,127.4913,5.7783,271.3702,0,0,0,0,0,0); // Third Civilan spawn
    AddPlayerClass(193,-2717.6240,127.4913,5.7783,271.3702,0,0,0,0,0,0); // Third Civilan spawn
    AddPlayerClass(264,-2717.6240,127.4913,5.7783,271.3702,0,0,0,0,0,0); // Third Civilan spawn
    
    
    AddStaticVehicle(496,-1793.1188,-274.5789,21.4861,0.6531,66,72);
    AddStaticVehicle(597,-1581.0028,674.3399,6.9580,0.5826,0,1); // SFPolice
    AddStaticVehicle(597,-1589.4272,674.5446,6.9554,0.4139,0,1); // SFPolice
    
    

    
	return 1;
}

public OnGameModeExit()
{
	return 1;
}

public OnPlayerRequestClass(playerid, classid)
{
    SetPlayerTeamFromClass(playerid, classid);
    SetPlayerPos(playerid, 1491.4349,-871.7689,60.0094);
    SetPlayerFacingAngle(playerid,311.0488);
    SetPlayerCameraPos(playerid, 1496.0518,-867.3990,60.9751);
    SetPlayerCameraLookAt(playerid, 1491.4349,-871.7689,60.0094);
    pClass[playerid] = classid;
    switch(classid)
    {
    case 0,1,2,3,4,5,6,7:
    {
    GameTextForPlayer(playerid, "~b~POLICE OFFICER", 3000, 4);
    }
    case 8:
	{
	GameTextForPlayer(playerid, "~g~ARMY", 3000, 4);
	}
	case 9,10,11:
	{
	GameTextForPlayer(playerid, "~y~PARAMEDIC", 3000, 4);
	}
	case 12,13,14,15,16:
	{
	GameTextForPlayer(playerid, "~r~TRIAD", 3000, 4);
	}
	case 17,18,19,20,21,22,23:
	{
	GameTextForPlayer(playerid, "~r~MAFIA", 3000, 4);
	}
	case 24,25,26,27,28,29,30,31,32,33,34,35,36:
	{
	GameTextForPlayer(playerid, "~y~GANG MEMBER", 3000, 4);
	}
	case 37,38,39,40:
	{
	GameTextForPlayer(playerid, "~p~STREET RACER", 3000, 4);
	}
	case 41,42,43,44:
	{
	GameTextForPlayer(playerid, "~p~BIKER", 3000, 4);
	}
	case 45,46,47:
	{
	GameTextForPlayer(playerid, "~p~PROSTITUTE", 3000, 4);
	}
	case 48,49,50:
	{
    GameTextForPlayer(playerid, "~p~FIRE WORKER", 3000, 4);
    }
    case 51,52,53,54:
    {
    GameTextForPlayer(playerid, "~p~DRIVER", 3000, 4);
    }
    case 55:
	{
	GameTextForPlayer(playerid, "~w~PILOT", 3000, 4);
	}
	case 56,57,58,59,60,61,62,63,64:
	{
	GameTextForPlayer(playerid, "~w~CIVIL", 3000, 4);
	}
	case 65,66,67,68,69,70:
	{
	GameTextForPlayer(playerid, "~w~CIVIL", 3000, 4);
	}
	}
	return 1;
}


SetPlayerTeamFromClass(playerid, classid)
{
    if(classid == 0||1||2||3||4||5||6||7)
    {
        gTeam[playerid] = TEAM_COP;
        
    }
    else if(classid == 8)
    {
        gTeam[playerid] = TEAM_ARMY; 
        
    }
    else if(classid == 9 ||10 || 11)
    {
        gTeam[playerid] = TEAM_PARAMEDIC;
        
    }
    else if(classid == 12||13||14||15||16)
    {
        gTeam[playerid] = TEAM_TRIAD;
        
    }
    else if(classid == 17||18||19||20||21||22||23)
    {
        gTeam[playerid] = TEAM_MAFIA;
        
    }
    else if(classid == 24||25||26||27||28||29||30||31||32||33||34||35||36)
    {
        gTeam[playerid] = TEAM_MEMBER;
        
    }
    else if(classid == 37||38||39||40)
    {
        gTeam[playerid] = TEAM_STREET_RACER;
        
    }
    else if(classid == 41||42||43||44)
    {
        gTeam[playerid] = TEAM_BIKER;
        
    }
    else if(classid == 45||46||47)
    {
        gTeam[playerid] = TEAM_PROSTITUTE;
        
    }
    else if(classid == 48||49||50)
    {
        gTeam[playerid] = TEAM_FIREWORKER;
        
    }
    else if(classid == 51||52||53||54)
    {
        gTeam[playerid] = TEAM_DRIVER;
        
    }
    else if(classid == 55)
    {
        gTeam[playerid] = TEAM_PILOT;
        
    }
    else if(classid == 56||57||58||59||60||61||62||63||64||65||66||67||68||69||70)
    {
        gTeam[playerid] = TEAM_CIVIL;
        
    }
   
}

SetPlayerToTeamColor(playerid)
{
    if(gTeam[playerid] == TEAM_COP)
    {
        SetPlayerColor(playerid,TEAM_COP_COLOR);
    }
    else if(gTeam[playerid] == TEAM_ARMY)
    {
        SetPlayerColor(playerid,TEAM_ARMY_COLOR);
    }
    else if(gTeam[playerid] == TEAM_PARAMEDIC)
    {
        SetPlayerColor(playerid,TEAM_PARAMEDIC_COLOR);
    }
    else if(gTeam[playerid] == TEAM_TRIAD)
    {
        SetPlayerColor(playerid,TEAM_TRIAD_COLOR);
    }
    else if(gTeam[playerid] == TEAM_MAFIA)
    {
        SetPlayerColor(playerid,TEAM_MAFIA_COLOR);
    }
    else if(gTeam[playerid] == TEAM_MEMBER)
    {
        SetPlayerColor(playerid,TEAM_MEMBER_COLOR);
    }
    else if(gTeam[playerid] == TEAM_STREET_RACER)
    {
        SetPlayerColor(playerid,TEAM_STREET_RACER_COLOR);
    }
    else if(gTeam[playerid] == TEAM_BIKER)
    {
        SetPlayerColor(playerid,TEAM_BIKER_COLOR);
    }
    else if(gTeam[playerid] == TEAM_PROSTITUTE)
    {
        SetPlayerColor(playerid,TEAM_PROSTITUTE_COLOR);
    }
    else if(gTeam[playerid] == TEAM_FIREWORKER)
    {
        SetPlayerColor(playerid,TEAM_FIREWORKER_COLOR);
    }
    else if(gTeam[playerid] == TEAM_DRIVER)
    {
        SetPlayerColor(playerid,TEAM_DRIVER_COLOR);
    }
    else if(gTeam[playerid] == TEAM_PILOT)
    {
        SetPlayerColor(playerid,TEAM_PILOT_COLOR);
    }
    else if(gTeam[playerid] == TEAM_CIVIL)
    {
        SetPlayerColor(playerid,TEAM_CIVIL_COLOR);
    }
}
public OnPlayerConnect(playerid)
{
    GameTextForPlayer(playerid,"~p~ Welcome to THB CnR server",5000,5);
    
	return 1;
}

public OnPlayerDisconnect(playerid, reason)
{
	return 1;
}

public OnPlayerSpawn(playerid)
{
    SetPlayerToTeamColor(playerid);
	return 1;
}
Reply


Messages In This Thread
Problem with team colors - by Djumza - 06.06.2012, 13:05
Re: Problem with team colors - by MadeMan - 06.06.2012, 13:12
Re: Problem with team colors - by Nirzor - 06.06.2012, 13:21
Re: Problem with team colors - by Djumza - 06.06.2012, 13:29
Re: Problem with team colors - by MadeMan - 06.06.2012, 13:33
Re: Problem with team colors - by Djumza - 06.06.2012, 13:47

Forum Jump:


Users browsing this thread: 1 Guest(s)