#1

Bug Showing Player Team Withe its Color Withe Showing it Blue Lol And Color Blue its Cyan And Color Cyan Blue any one can help me
PHP код:
#include <a_samp>
#define COLOR_Withe 0xFFFFFF
#define COLOR_Blue 0x0099FF
#define COLOR_Cyan 0x99FFFF
// Define the teams so its easier to use later
#define TEAM_BLUE 1
#define TEAM_Withe 2
#define TEAM_Cyan 3
// Define the colours you want each team to be, its easier for later on
#define TEAM_BLUE_COLOUR 0x0099FF // blue duh
#define TEAM_Withe_COLOUR 0xFFFFFF // Withe duh
#define TEAM_Cyan_COLOUR 0x99FFFF // Cyan duh
// Tracks what team a player is in
new gTeam[MAX_PLAYERS];
main()
{
    print(
"\n----------------------------------");
    print(
" Cops And Robbers");
    print(
"----------------------------------\n");
}
public 
OnGameModeInit()
{
SetGameModeText("Cops And Robbers");
AddPlayerClass(266,2303.9497,2439.0103,3.2734,19.1234,3,1,22,50,29,500); // blue team
AddPlayerClass(211,2303.9497,2439.0103,3.2734,19.1234,3,1,22,50,29,500); // blue team
AddPlayerClass(265,2303.9497,2439.0103,3.2734,19.1234,3,1,22,50,29,500); // blue team
AddPlayerClass(267,2303.9497,2439.0103,3.2734,19.1234,3,1,22,50,29,500); // blue team
AddPlayerClass(283,2303.9497,2439.0103,3.2734,19.1234,3,1,22,50,29,500); // blue team
AddPlayerClass(284,2303.9497,2439.0103,3.2734,19.1234,3,1,22,50,29,500); // blue team
AddPlayerClass(285,2303.9497,2439.0103,3.2734,19.1234,3,1,22,50,29,500); // Cyan team
AddPlayerClass(71,-1261.6409,38.9104,14.1387,226.4688,3,1,22,50,29,500); // Withe team
AddPlayerClass(50,2006.1929,2295.9451,10.8203,177.4306,22,50,0,0,0,0); // Withe team
AddPlayerClass(133,1151.7200,1399.4144,5.8203,0.9030,22,50,0,0,0,0); // Withe team
AddPlayerClass(151,1151.7200,1399.4144,5.8203,0.9030,22,50,0,0,0,0); // Withe team
AddPlayerClass(12,2090.1008,2078.2600,10.8203,263.0699,0,0,0,0,0,0); // Withe team
AddPlayerClass(23,2090.1008,2078.2600,10.8203,263.0699,0,0,0,0,0,0); // Withe team
AddPlayerClass(29,2815.0498,2254.1252,10.8203,158.6954,0,0,0,0,0,0); // Withe team
AddPlayerClass(294,2814.0542,2253.4043,10.8203,315.9051,0,0,0,0,0,0); // Withe team
AddPlayerClass(214,2812.1963,2247.7256,10.8203,352.8735,0,0,0,0,0,0); // Withe team
AddPlayerClass(1,2634.0793,1072.6293,10.8203,88.4012,0,0,0,0,0,0); // Withe team
AddPlayerClass(15,2634.0793,1072.6293,10.8203,88.4012,0,0,0,0,0,0); // Withe team
AddPlayerClass(34,2634.0793,1072.6293,10.8203,88.4012,0,0,0,0,0,0); // Withe team
AddPlayerClass(2,2193.6528,2007.7402,12.2894,1.8574,0,0,0,0,0,0); // Withe team
AddPlayerClass(9,2193.6528,2007.7402,12.2894,1.8574,0,0,0,0,0,0); // Withe team
AddPlayerClass(19,2193.6528,2007.7402,12.2894,1.8574,0,0,0,0,0,0); // Withe team
AddPlayerClass(22,2193.6528,2007.7402,12.2894,1.8574,0,0,0,0,0,0); // Withe team
AddPlayerClass(26,2082.0784,2480.8333,10.8203,182.0390,0,0,0,0,0,0); // Withe team
AddPlayerClass(31,2082.0784,2480.8333,10.8203,182.0390,0,0,0,0,0,0); // Withe team
AddPlayerClass(45,2082.0784,2480.8333,10.8203,182.0390,0,0,0,0,0,0); // Withe team
AddPlayerClass(46,2082.0784,2480.8333,10.8203,182.0390,0,0,0,0,0,0); // Withe team
AddPlayerClass(9,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(13,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(14,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(24,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(33,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(36,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(38,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(160,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(82,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(107,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(59,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(127,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(128,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(138,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(28,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(147,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(299,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(123,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(204,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(249,2193.7366,2007.4865,12.2894,358.2378,15,1,15,500,28,500); // Withe team
AddPlayerClass(264,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(269,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(270,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(293,2193.5884,2007.4149,12.2894,355.9373,0,0,0,0,0,0); // Withe team
AddPlayerClass(271,2193.7366,2007.4865,12.2894,358.2378,0,0,0,0,0,0); // Withe team
AddPlayerClass(298,2193.5884,2007.4149,12.2894,355.9373,0,0,0,0,0,0); // Withe team
AddPlayerClass(137,2193.5884,2007.4149,12.2894,355.9373,0,0,0,0,0,0); // Withe team 
PHP код:
public OnPlayerRequestClass(playeridclassid)
{
    
SetPlayerTeamFromClass(playeridclassid); // calls the custom function
    
return 1;
}
public 
OnPlayerSpawn(playerid)
{
    
SetPlayerToTeamColour(playerid); // calls the custom function
    
return 1;
}
forward SetPlayerTeamFromClass(playeridclassid);
public 
SetPlayerTeamFromClass(playeridclassid)
{
    if(
classid == 0)
    {
        
gTeam[playerid] = TEAM_BLUE// using the defines at the top
    
}
    else if(
classid == 1)
    {
        
gTeam[playerid] = TEAM_Withe// same ^^
    
}
    else if(
classid == 3)
    {
        
gTeam[playerid] = TEAM_Cyan// same ^^
    
}
}
forward SetPlayerToTeamColour(playerid);
public 
SetPlayerToTeamColour(playerid)
{
    if(
gTeam[playerid] == TEAM_BLUE)
    {
        
SetPlayerColor(playerid,TEAM_BLUE_COLOUR); // Blue
    
}
    else if(
gTeam[playerid] == TEAM_Withe)
    {
        
SetPlayerColor(playerid,TEAM_Withe_COLOUR); // Withe
    
}
    else if(
gTeam[playerid] == TEAM_Cyan)
    {
        
SetPlayerColor(playerid,TEAM_Cyan_COLOUR); // Cyan
    
}
    return 
1;

Reply


Messages In This Thread
Bug - by nightday - 03.09.2014, 18:23
Re: Bug - by HyDrAtIc - 03.09.2014, 18:25
Re: Bug - by Stinged - 03.09.2014, 18:30
Re: Bug - by LeroyII - 03.09.2014, 18:38
Re: Bug - by nightday - 03.09.2014, 18:39
Re: Bug - by Stinged - 03.09.2014, 18:54
Re: Bug - by Rifa4life - 03.09.2014, 19:22
Re: Bug - by nightday - 03.09.2014, 20:28
Re: Bug - by nightday - 03.09.2014, 20:52
Re: Bug - by Stinged - 03.09.2014, 21:05

Forum Jump:


Users browsing this thread: 1 Guest(s)