if(APlayerData[playerid][PlayerLevel] == 0) return SendClientMessage(playerid,0xff0000ff,"You aren't an admin");
public OnPlayerText(playerid, text[])
{
 switch (APlayerData[playerid][PlayerLevel])
 {
  case 0:
  {
      new string[128];
      format(string,sizeof(string),"%s[%i]: {FFFFFF}%s",PlayerName2(playerid),playerid,text);
      printf(string);
      SendClientMessageToAll(GetPlayerColor(playerid),string);
    }
    case 1:
    {
      new aName[MAX_PLAYER_NAME], string2[128];
      GetPlayerName(playerid, aName,sizeof(aName));
      format(string2,sizeof(string2),"Admin %s[%i]: %s",aName,playerid,text);
      printf(string2);
      SendClientMessageToAll(0xF600F6FF,string2);
    }
  }
  return 0;
}
and also when they spawn It says Admin blaa has come on duty |
OnPlayerSpawn(playerid){
if(APlayerData[playerid][PlayerLevel] == 1)SendClientMessageToAll(0xff0000ff, "Admin blaa has come on duty");
}
CMD:adminchat(playerid, params[]) { new str[185], aname[MAX_PLAYER_NAME] ; GetPlayerName(playerid, aname, MAX_PLAYER_NAME); if(PInfo[playerid][pAdmin] >= 1)//if admin level is greater than 1 { if(sscanf(params, "s", str)) return SendClientMessage(playerid, -1, "USAGE: /adminchat [text]"); format(str, 185, "Admin %s says: %s", aname, params); } else SendClientMessage(playerid, -1, "You are not authorized to use that command!"); return 1; }