[REQUEST] Reporting mute command
#1

I need a report mute command for admins, use please [pAdmin].


Thanks, do this and have from me a reputation
Reply
#2

I did not understand what you want.
Reply
#3

I want a command for admins only that mute the player from reporting like /rmute
Reply
#4

enum
pawn Код:
pReportmute
Load User
pawn Код:
INI_Int("Report Muted",PlayerInfo[playerid][pReportMute]);
On Disconnect
pawn Код:
INI_WriteInt(File,"Report Muted",PlayerInfo[playerid][pReportMute]);
The Command
pawn Код:
CMD:rmute(playerid, params[])
{
    new rmutedmessage[600],globalmessage[700],mid,pname[MAX_PLAYER_NAME],reason[700];
    if(PlayerInfo[playerid][pAdmin] >= 1){
    if(sscanf(params, "s[100]", params)) return SendClientMessage(playerid,-1,"Usage: /rmute [playerid] [reason]");
    GetPlayerName(mid, pname, sizeof(pname));
    format(rmutedmessage, sizeof(rmutedmessage), "You Have Been Muted By Admin: %s For: %s", GetName(playerid),reason);
    format(globalmessage, sizeof(globalmessage), "Admin: %s Has Report Muted: %s", GetName(playerid),mid);
    SendClientMessage(mid,-1,rmutedmessage);
    SendClientMessageToAll(-1,globalmessage);
    PlayerInfo[mid][pReportMute] = 1;
    }
    else if(PlayerInfo[mid][pReportMute] == 1){
    PlayerInfo[mid][pPhone] = 0;
    format(globalmessage, sizeof(globalmessage), "[ADMIN ACTION] Admin: %s Has Un-Muted (REPORTS): %s", GetName(playerid),mid);
    format(rmutedmessage, sizeof(rmutedmessage), "You Are Now Able To Report Again ( Un-Report Muted By: %s For: %s )", GetName(playerid),reason);
    SendClientMessage(mid,-1,rmutedmessage);
    SendClientMessageToAll(-1,globalmessage);
    }
    else{
    SendClientMessage(playerid,-1,"Your Not The Correct Admin Level To Use This Command");
    }
    return 1;
}

Also Add this to your report command at the top
pawn Код:
if(PlayerInfo[playerid][pReportMute] == 1){
SendClientMessage(playerid,-1,"Sorry You Have Been Muted From Sending Report's By A Server Admin");
}
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)