//setplayerteamfromclass
case 4 .. 9:
{
gTeam[playerid] = GROVES;
cS_Show(playerid);
cS_Update(playerid, 0x4682B4FF, "~g~Grove Family", "~g~]~w~ The Grove members are to protect there turfs. ~s~~n~~g~]~w~ Kill there enemies.");
SetPlayerPos(playerid,2500.6060,-1672.1453,13.3512);
SetPlayerCameraPos(playerid,2507.0615,-1674.3574,13.3732);
SetPlayerCameraLookAt(playerid,2500.6060,-1672.1453,13.3512);
SetPlayerFacingAngle(playerid,252.4717);
ApplyAnimation(playerid, "PED", "FUCKU", 4.0, 1, 0, 0, 0, 0);
}
// now this is what i use to check if player is in the faction if not it should send them this message.. but is sends the message and stills spawns them
if(gTeam[playerid] == POLICE)
{
if(pInfo[playerid][Faction] != 1)
{
SendClientMessage(playerid, red, "You are not a member of this faction");
}
}
if(gTeam[playerid] == POLICE)
{
if(pInfo[playerid][Faction] != 1)
{
SendClientMessage(playerid, red, "You are not a member of this faction");
return 1;
}
}
Do not trust me on this one but do this
PHP код:
|
if(gTeam[playerid] == POLICE && pInfo[playerid][pFaction] != 1)
{
SendClientMessage(playerid, red, "You are not a member of this faction");
return 0;
}