SA-MP Forums Archive
Mute systems error.Help pelase (Sscanf2) - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Server (https://sampforum.blast.hk/forumdisplay.php?fid=6)
+--- Forum: Server Support (https://sampforum.blast.hk/forumdisplay.php?fid=19)
+--- Thread: Mute systems error.Help pelase (Sscanf2) (/showthread.php?tid=512371)



Mute systems error.Help pelase (Sscanf2) - Firstaction - 10.05.2014

Hi,in the mute system error output./mute id Can not we make silence.Sorry bad english,please help.


Re: Mute systems error.Help pelase (Sscanf2) - TheSnaKe - 10.05.2014

Hmm show the fucking codes?


Re: Mute systems error.Help pelase (Sscanf2) - Parallex - 10.05.2014

Show us the code.
Quote:
Originally Posted by ******
"And we are meant to guess your code?"



Re: Mute systems error.Help pelase (Sscanf2) - Firstaction - 10.05.2014

all mute systems.

pawn Код:
CMD:mute(playerid, params[])
{
    if(PlayerInfo[playerid][pAdmin] >= 1)
    {
        new targetid, reason[128], string[128];
        if(sscanf(params, "us[128]", targetid)) SendClientMessage(playerid, C_GREY, "USAGE: /mute [playerid] [reason]");

        format(string, sizeof(string), "ADMIN: %s has been muted. [REASON: %s]", Name(targetid), reason);
        SendClientMessageToAll(C_YELLOW, string);
        PlayerInfo[targetid][pMuted] = 1;
    }
    else SendClientMessage(playerid, C_RED, "You do not have access to this command!");
    return 1;
}

CMD:unmute(playerid, params[])
{
    if(PlayerInfo[playerid][pAdmin] >= 1)
    {
        new targetid, string[128];
        if(sscanf(params, "u", targetid)) SendClientMessage(playerid, C_GREY, "USAGE: /unmute [playerid]");

        format(string, sizeof(string), "ADMIN: %s has been un-muted.", Name(targetid));
        SendClientMessageToAll(C_YELLOW, string);
        PlayerInfo[targetid][pMuted] = 0;
    }
    else SendClientMessage(playerid, C_RED, "You do not have access to this command!");
    return 1;
}



Re: Mute systems error.Help pelase (Sscanf2) - biker122 - 10.05.2014

Add this inside your public OnPlayerText
pawn Код:
if(PlayerInfo[playerid][pMuted] == 1)
{
       SendClientMessage(playerid,C_RED,"You are muted!");
       return 0;
}



Re: Mute systems error.Help pelase (Sscanf2) - Firstaction - 10.05.2014

Quote:
Originally Posted by biker122
Посмотреть сообщение
Add this inside your public OnPlayerText
pawn Код:
if(PlayerInfo[playerid][pMuted] == 1)
{
       SendClientMessage(playerid,C_RED,"You are muted!");
       return 0;
}
It did not.