Faction Chat help for dynamic factions
#1

ok, So I'm trying to make it so that when a player types /f it sends the message to players in his faction I can make it work with my non Dynamic faction system but when I try make it with the dynamic system it doesn't work.

code dynamic:
pawn Код:
forward SendMessageToOfficialFaction(color,const string[]);
public SendMessageToOfficialFaction(color,const string[])
{
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(i) == 1)
        if(PlayerInfo[i][pFaction] == PlayerInfo[playerid][pFaction])
        SendClientMessage(i, color, string);
    }
    return 1;
}
Error Message Dynamic:

Код:
C:\Users\nathan\Desktop\Sa-mp v2\gamemodes\hrp.pwn(1114) : error 017: undefined symbol "playerid"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Error.
Code non dynamic:
pawn Код:
forward SendMessageToPoliceFaction(color,const string[]);
public SendMessageToPoliceFaction(color,const string[])
{
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(i) == 1) //the admin gotta be connected
        if(PlayerInfo[i][pFaction] == 30)
        SendClientMessage(i, color, string);
    }
    return 1;
}
Reply


Messages In This Thread
Faction Chat help for dynamic factions - by jueix - 11.02.2014, 09:44
Re: Faction Chat help for dynamic factions - by $Marco$ - 11.02.2014, 09:49
Re: Faction Chat help for dynamic factions - by Flake. - 11.02.2014, 09:49
Re: Faction Chat help for dynamic factions - by DaniceMcHarley - 11.02.2014, 09:54

Forum Jump:


Users browsing this thread: 2 Guest(s)