SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help > Help Archive

 
 
Thread Tools Display Modes
Old 12/08/2011, 07:57 PM   #11
MadeMan
High-roller
 
MadeMan's Avatar
 
Join Date: Jun 2007
Posts: 3,488
Reputation: 256
Default Re: All teams are green!!!!!!!!

Your teams were wrongly set in SetPlayerTeamFromClass.
MadeMan is offline  
Old 12/08/2011, 08:00 PM   #12
samtey
Gangsta
 
samtey's Avatar
 
Join Date: Jul 2011
Posts: 528
Reputation: 12
Default AW: All teams are green!!!!!!!!

Does this also improve the Localchat? Is the localchat right now, too?
__________________
Dear USER! If I helped you in one of your posts, then please give me reputation! I also will give you if you help me!

samtey is offline  
Old 12/08/2011, 08:01 PM   #13
MadeMan
High-roller
 
MadeMan's Avatar
 
Join Date: Jun 2007
Posts: 3,488
Reputation: 256
Default Re: All teams are green!!!!!!!!

Should be.
MadeMan is offline  
Old 12/08/2011, 08:06 PM   #14
samtey
Gangsta
 
samtey's Avatar
 
Join Date: Jul 2011
Posts: 528
Reputation: 12
Default AW: All teams are green!!!!!!!!

Hmm, we tested it, still all names are green and the dots on the map, too!
Also the chat!
__________________
Dear USER! If I helped you in one of your posts, then please give me reputation! I also will give you if you help me!

samtey is offline  
Old 12/08/2011, 08:15 PM   #15
Zonoya
Gangsta
 
Zonoya's Avatar
 
Join Date: Jul 2011
Location: Am I in Rio de Janeiro or the Amazon, you tell me?
Posts: 664
Reputation: 19
Default Re: All teams are green!!!!!!!!

simple to fix look at my code this works PERFECTLY all u have to do is add the classes and do this


if(GetPlayerSkin(playerid, 116))
if(GetPlayerSkin(playerid, 115))
if(GetPlayerSkin(playerid, 114))
SetPlayerColor(playerid, Purpley);
SetPlayerMarkerForPlayer( i, playerid, Purpley );


thats all u do so say its Balla's u use if(getPlayerSkin(playerid, Balla skin 1))
then after SetPlayerColor(playerid, (Balla Purple);

same with vangos and Grove
if it works give me +rep plz
__________________
Code:
public OnRconLoginAttempt(ip[], password[], success)
{
    if(!success) //If the password was incorrect
    {
        printf("FAILED RCON LOGIN BY IP %s USING PASSWORD %s",ip, password);
        new pip[16];
        for(new i=0; i<MAX_PLAYERS; i++) //Loop through all players
        {
            GetPlayerIp(i, pip, sizeof(pip));
            if(!strcmp(ip, pip, true)) //If a player's IP is the IP that failed the login
            {
                SendClientMessage(i, 0xFFFFFFFF, "Wrong Password. Bye!"); //Send a message
                Ban(i); //They are now banned.
            }
        }
    }
    return 1;
}
Zonoya is offline  
Old 12/08/2011, 08:23 PM   #16
samtey
Gangsta
 
samtey's Avatar
 
Join Date: Jul 2011
Posts: 528
Reputation: 12
Default AW: All teams are green!!!!!!!!

Omg, where to add this?^^
__________________
Dear USER! If I helped you in one of your posts, then please give me reputation! I also will give you if you help me!

samtey is offline  
Old 12/08/2011, 10:48 PM   #17
Zonoya
Gangsta
 
Zonoya's Avatar
 
Join Date: Jul 2011
Location: Am I in Rio de Janeiro or the Amazon, you tell me?
Posts: 664
Reputation: 19
Default Re: All teams are green!!!!!!!!

under OnPlayerSpawn so if they have the skin when they spawn they get the color
__________________
Code:
public OnRconLoginAttempt(ip[], password[], success)
{
    if(!success) //If the password was incorrect
    {
        printf("FAILED RCON LOGIN BY IP %s USING PASSWORD %s",ip, password);
        new pip[16];
        for(new i=0; i<MAX_PLAYERS; i++) //Loop through all players
        {
            GetPlayerIp(i, pip, sizeof(pip));
            if(!strcmp(ip, pip, true)) //If a player's IP is the IP that failed the login
            {
                SendClientMessage(i, 0xFFFFFFFF, "Wrong Password. Bye!"); //Send a message
                Ban(i); //They are now banned.
            }
        }
    }
    return 1;
}
Zonoya is offline  
Old 13/08/2011, 08:41 AM   #18
samtey
Gangsta
 
samtey's Avatar
 
Join Date: Jul 2011
Posts: 528
Reputation: 12
Default AW: All teams are green!!!!!!!!

Oh man, I'm such too stupid, can you do it in the callback please?

PHP Code:
public OnPlayerSpawn(playerid)
    {
        
GangZoneShowForPlayer(playeridballas1, -2147418167);
        
GangZoneShowForPlayer(playeridballas2, -2147418167);
        
GangZoneShowForPlayer(playeridballas3, -2147418167);
        
GangZoneShowForPlayer(playeridgrove116711888);
        
GangZoneShowForPlayer(playeridgrove216711888);
        
GangZoneShowForPlayer(playeridgrove316711888);
        
GangZoneShowForPlayer(playeridvagos1, -65332);
        
GangZoneShowForPlayer(playeridvagos2, -65332);
        
        
        
PlayerPlaySound(playerid11860.00.00.0);
        
SetPlayerToTeamColor(playerid);
        
PlayerInfo[playerid][pDead] = false;
        
//PreloadAnimLib(playerid,animlib[]);
        
return 1;
    } 
__________________
Dear USER! If I helped you in one of your posts, then please give me reputation! I also will give you if you help me!

samtey is offline  
Old 13/08/2011, 10:58 AM   #19
MadeMan
High-roller
 
MadeMan's Avatar
 
Join Date: Jun 2007
Posts: 3,488
Reputation: 256
Default Re: All teams are green!!!!!!!!

Remove this

pawn Code:
new GROVE,BALLA,VAGOS;

add this

pawn Code:
#define GROVE 1
#define BALLA 2
#define VAGOS 3

change this

pawn Code:
SetPlayerToTeamColor(playerid)
{
    switch(gTeam[playerid])
    {
        case GROVE:
        {
            SetPlayerColor(playerid, TEAM_GROVE_COLOR);
        }
        case BALLA:
        {
            SetPlayerColor(playerid, TEAM_BALLA_COLOR);
        }
        case VAGOS:
        {
            SetPlayerColor(playerid, TEAM_VAGOS_COLOR);
        }
    }
}
MadeMan is offline  
Old 13/08/2011, 12:50 PM   #20
Zonoya
Gangsta
 
Zonoya's Avatar
 
Join Date: Jul 2011
Location: Am I in Rio de Janeiro or the Amazon, you tell me?
Posts: 664
Reputation: 19
Default Re: All teams are green!!!!!!!!

yeah thats a good way
__________________
Code:
public OnRconLoginAttempt(ip[], password[], success)
{
    if(!success) //If the password was incorrect
    {
        printf("FAILED RCON LOGIN BY IP %s USING PASSWORD %s",ip, password);
        new pip[16];
        for(new i=0; i<MAX_PLAYERS; i++) //Loop through all players
        {
            GetPlayerIp(i, pip, sizeof(pip));
            if(!strcmp(ip, pip, true)) //If a player's IP is the IP that failed the login
            {
                SendClientMessage(i, 0xFFFFFFFF, "Wrong Password. Bye!"); //Send a message
                Ban(i); //They are now banned.
            }
        }
    }
    return 1;
}
Zonoya is offline  
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Green screen DaneAMattie Help Archive 5 22/02/2011 09:55 PM
How to make the lock green? Ihsan_Cingisiz Help Archive 5 07/06/2010 01:35 PM


All times are GMT. The time now is 09:18 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.