04.01.2015, 18:16
Hello,
Is there a better way to restrict faction skins on skin selection than as follows?
I have this set under OnPlayerRequestSpawn:
The annoying issue with this is that when someone press spawn the error mesage will spam the player while they keep the spawn key pressed. Other than that, it works relatively good. But like I said, better way to restrict faction skins?
Is there a better way to restrict faction skins on skin selection than as follows?
I have this set under OnPlayerRequestSpawn:
pawn Код:
if(GetPlayerSkin(playerid) == 280 || GetPlayerSkin(playerid) == 281 || GetPlayerSkin(playerid) == 265 || GetPlayerSkin(playerid) == 266 || GetPlayerSkin(playerid) == 267 || GetPlayerSkin(playerid) == 284 || GetPlayerSkin(playerid) == 285)
{
if(PlayerInfo[playerid][pFaction] != 1)
{
SendClientMessage(playerid, COLOR_LIGHTRED, " {FF6347}ERROR:{FF6347} {F0F8FF}Locked faction skin.{F0F8FF}");
return 0;
}
else
{
return 1;
}
}