[Help]how to make a tag.
#4

pawn Код:
COMMAND:announce(playerid, params[])
{
    new string[256], text[256]; // Strings
    if(sscanf(params, "s[256]", text)) SendClientMessage(playerid, COLOR_GREY, "USAGE: /announce [Message]"); // If you type in /announce with a space it will send you this message <
    else
    {
        if(PlayerInfo[playerid][pAdmin] >= 1) // If admin is level 1 or above.
        {
            format(string, sizeof(string), "[ANNOUNCEMENT] %s %s: "COL_WHITE"%s", GetAdminLvlName(playerid), GetName(playerid), text); // When using the command /announce [Message] it will come up as [Announcement] Admin Level X, The players name that used the command, and then the text will be white.
            SendClientMessageToAll(COLOR_GREY, string); // Send the message to all the players.
        }
        else SendClientMessage(playerid, COLOR_LIGHTRED, "WARNING: You do not have access to this command!"); // If you are not an admin it will send you the message above.
    }
    return 1;
}
NOTE: You will need to make stocks "GetAdminLvlName", "GetName"!
Reply


Messages In This Thread
[Help]how to make a tag. - by [A]ndrei - 25.06.2012, 19:26
Re: [Help]how to make a tag. - by Kindred - 25.06.2012, 19:30
Re: [Help]how to make a tag. - by [A]ndrei - 25.06.2012, 20:49
Re: [Help]how to make a tag. - by .Wicked - 25.06.2012, 20:56
Re: [Help]how to make a tag. - by Dubya - 25.06.2012, 20:57
Re: [Help]how to make a tag. - by Kindred - 25.06.2012, 21:00
Re: [Help]how to make a tag. - by .Wicked - 25.06.2012, 21:03
Re: [Help]how to make a tag. - by Kindred - 25.06.2012, 21:06
Re: [Help]how to make a tag. - by [A]ndrei - 26.06.2012, 04:22
Re: [Help]how to make a tag. - by [A]ndrei - 27.06.2012, 02:15

Forum Jump:


Users browsing this thread: 2 Guest(s)