COMMAND:announce(playerid, params[]) { // Send the command to all admins so they can see it SendAdminText(playerid, "/announce", params); // Check if the player has logged in if (APlayerData[playerid][LoggedIn] == true) { // Check if the player's admin-level is at least 1 if (APlayerData[playerid][PlayerLevel] >= 1) { if(sscanf(params)) return SendClientMessage(playerid,0x0000BBAA, "USAGE: /an(nounce) [message]"); else { GameTextForAll(params, 3800, 6); return 1; } } else return 0; } else return 0; // Let the server know that this was a valid command return 1; } |
COMMAND:announce(playerid,params[])
{
SendAdminText(playerid, "/announce", params);
if(APlayerData[playerid][LoggedIn] == true)
{
if(APlayerData[playerid][PlayerLevel] >= 1)
{
new message[64];
if(sscanf(params,"s[64]",message)) return SendClientMessage(playerid,-1,"USAGE:/announce [message]");
GameTextForAll(message, 3800, 6);
}
}
return 1;
}