Mute Bug
#1

When I type /mute 0 warning
it just comes back up with "USAGE: /warn [id] [reason]"
Can anyone help?


Код:
	if(strcmp("/warn", cmd, true) == 0)
{
		if(PlayerInfo[playerid][AdminLevel] < 1) return 0;
        {
                new i, reason[50];
                new name[50];
                new string[100];
                new params[100];
                if(sscanf(params, "us[50]", i, reason)) SendClientMessage(playerid, BLANCO, "USAGE: /warn [id] [reason]");
                else if(i == INVALID_PLAYER_ID) SendClientMessage(playerid, ROJO, "Player is not connected!");
                else
                {
                    GetPlayerName(i, name, sizeof(name));
                        if(playerid!=i)
                    {
                            if(WarnTimes[i]>=2)
                                {
                                    format(string, 100,"[AUTO-KICK]: %s[%d] Has Been Kicked From The Server, [3/3 Warnings]", name, i);
                                        SendClientMessageToAll(AC, string);
                                        SetPlayerHealth(i, 999999999);
                                SetPlayerInterior(i, 10);
                                SetPlayerPos(i,226.9807,111.1730,999.0156);
                                    format(string, sizeof(string), "~W~You Have Been ~R~Kicked ~W~From The Server");
                                    GameTextForPlayer(i ,string, 99999999999999999999999, 3);
                                    Kick(i);
                                }
                                else
                                {
                                    WarnTimes[i]+=1;
                                    if(WarnTimes[i]==1)
                                    {
                                            format(string, 256,"[ADMIN-WARN]: You Have Received A Warning, Reason: %s, [1/3 Warnings]", reason);
                                            SendClientMessage(i, AC, string);
                                    }
                                        else if(WarnTimes[i]==2)
                                        {
                                            format(string, 256,"[ADMIN-WARN]: You Have Received A Warning, Reason: %s, [2/3 Warnings]", reason);
                                            SendClientMessage(i, AC, string);
                                        }
                                    format(string, 256,"[ADMIN-WARN]: %s[%d] Has Received A Warning, Reason: %s", name, i, reason);
                                    SendClientMessageToAll(AC, string);
                                        GameTextForPlayer(i,"~W~You Have Received A ~n~  ~R~Warning",5000,3);
                                }
                        }
                        else SendClientMessage(playerid, COLOR_RED, "You Can't Warn Your Self");
                }
		}
        return 1;
}
Reply


Messages In This Thread
Mute Bug - by MikeMike1997 - 22.03.2013, 19:07
Re: Mute Bug - by dusk - 22.03.2013, 19:12
Re: Mute Bug - by MikeMike1997 - 22.03.2013, 19:29
Re: Mute Bug - by HurtLocker - 22.03.2013, 22:14

Forum Jump:


Users browsing this thread: 3 Guest(s)