21.05.2016, 17:17
I want when the player do /stopserviceadmin he take the colour before the /service admin
there is the code :
there is the code :
PHP код:
COMMAND:serviceadmin(playerid, params[])
{
SendAdminText(playerid, "/serviceadmin", params);
if (APlayerData[playerid][LoggedIn] == false) return 0;
if (APlayerData[playerid][PlayerLevel] < 1) return 0;
new AdminName[24];
new string[128];
GetPlayerName(playerid, AdminName, sizeof(AdminName));
format(string, sizeof(string),"L'administrateur %s c'est mis en service !", AdminName);
SendClientMessageToAll(0xFFFFFF, string);
SetPlayerSkin(playerid, 217);
SendClientMessage(playerid,0xFFFFFFFF, "Vous etes passez en admin en service !");
SetPlayerColor(playerid, 0xFF0000FF);
return 1;
}
COMMAND:stopserviceadmin(playerid, params[])
{
SendAdminText(playerid, "/stopserviceadmin", params);
if (APlayerData[playerid][LoggedIn] == false) return 0;
if (APlayerData[playerid][PlayerLevel] < 1) return 0;
new AdminName[24];
new string[128];
GetPlayerName(playerid, AdminName, sizeof(AdminName));
format(string, sizeof(string),"L'administrateur %s c'est mis en hors service admin !", AdminName);
SendClientMessageToAll(0xFFFFFF, string);
SetPlayerSkin(playerid, 48);
SendClientMessage(playerid,0xFFFFFFFF, "Vous etes maintenant en hors service admin !");
return 1;
}