OnPlayerRequestClass(playerid, classid) { for(new i = 0; i<MAX_PLAYERS; i++) { if(GetPlayerSkin(i) == 294) { if(IsPlayerLAdmin(playerid)) //i use LAdmin system thats why its LAdmin { return 1; SendClientMessage(playerid, "Welcome Admin"); } else { GameTextForPlayer(playerid, "You aren't an admin!", 5000, 5); ForceClassSelection() return 0; } }
public OnPlayerRequestSpawn(playerid)
{
if(GetPlayerSkin(playerid) == 294)
{
if(IsPlayerLAdmin(playerid)) //i use LAdmin system thats why its LAdmin
{
SendClientMessage(playerid, "Welcome Admin");
return 1;
}
else
{
GameTextForPlayer(playerid, "You aren't an admin!", 5000, 5);
return 0;
}
}
return 1;
}
}
public OnPlayerSpawn(playerid) { if(PlayerInfo[playerid][LoggedIn] == 1) { if(PlayerInfo[playerid][Level] >= 1) { SetPlayerColor(playerid,Admin color); SetPlayerSkin(playerid, Skin Id here); GameTextForPlayer(playerid,"~y~~n~~n~~n~Welcome ~r~Admin",4000,3); } } return 1; } |