[HELP] View all team-members online
#2

if(strcmp(cmd,"/faction",true)==0)
{
if(IsPlayerConnected(playerid))
{
new teamnumber;
if (PlayerInfo[playerid][pLeader] != 0) teamnumber = PlayerInfo[playerid][pLeader];
else if (PlayerInfo[playerid][pMember] != 0) teamnumber = PlayerInfo[playerid][pMember];
else
{
SendClientMessage(playerid, COLOR_GRAD1, "you are not in any faction!");
return 1;
}
SendClientMessage(playerid, 0x808000AA, "**Membre online**");
for(new i = 0; i < MAX_PLAYERS; i++)
{
if (IsPlayerConnected(i))
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, sizeof(string), "");
if (PlayerInfo[i][pLeader] == teamnumber) format(string, sizeof(string), "%s (LEADER)",sendername);
else if (PlayerInfo[i][pMember] == teamnumber) format(string, sizeof(string), "%s, Rang: %d.",sendername, PlayerInfo[i][pRank]);
if (strlen(string) > 1) SendClientMessage(playerid, 0xF5DEB3AA, string);
}
}
}
return 1;
}

try to make some copy
Reply


Messages In This Thread
[HELP] View all team-members online - by Fredden1993 - 25.12.2011, 21:40
Re : [HELP] View all team-members online - by BigBaws - 25.12.2011, 22:53
Re: Re : [HELP] View all team-members online - by Fredden1993 - 25.12.2011, 23:06
Re: [HELP] View all team-members online - by BrandyPenguin - 26.12.2011, 00:08

Forum Jump:


Users browsing this thread: 2 Guest(s)