Raised This Month: $214 Target: $400
 53% 

[CSGO]SourceBans check if player is muted


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Sajmooooon
Senior Member
Join Date: Nov 2018
Location: Slovakia
Old 03-08-2021 , 09:48   [CSGO]SourceBans check if player is muted
Reply With Quote #1

Hi is there any sourcepawn command for sourcebans to check if player is muted/gaged ?

Thanks.
Sajmooooon is offline
azalty
AlliedModders Donor
Join Date: Feb 2020
Old 03-08-2021 , 09:54   Re: [CSGO]SourceBans check if player is muted
Reply With Quote #2

Afaik there is no command BUT you can get muted/gaged players through the /admin menu

I think there was also sm_listbans and sm_listblocks but you have to enter a username/steamid I think
__________________
azalty is offline
FAQU
Member
Join Date: Sep 2020
Location: Romania
Old 03-09-2021 , 00:03   Re: [CSGO]SourceBans check if player is muted
Reply With Quote #3

I've no idea if this will work with sourcebans, but it might be worth giving it a try:

PHP Code:
#include <sourcemod>
#include <basecomm>

#pragma semicolon 1
#pragma newdecls required

public void OnPluginStart()
{
    
LoadTranslations("common.phrases");
    
RegConsoleCmd("sm_comms"Command_Comms"Shows a players communications status");
}

public 
Action Command_Comms(int clientint args)
{
    if (
args != 1)
    {
        
ReplyToCommand(client"[SM] Usage: sm_comms <name|userid>");
        return 
Plugin_Handled;
    }
    
    
char arg1[MAX_NAME_LENGTH];
    
GetCmdArg(1arg1sizeof(arg1));
    
    
int target FindTarget(clientarg1truefalse);
    if (
target == -1)
    {
        return 
Plugin_Handled;
    }
    
    
bool gag BaseComm_IsClientGagged(target);
    
bool mute BaseComm_IsClientMuted(target);
    
    
ReplyToCommand(clientgag "%N is gagged":"%N is ungagged"target);
    
ReplyToCommand(clientmute "%N is muted":"%N is unmuted"target);
    
    return 
Plugin_Handled;

__________________
FAQU is offline
Sajmooooon
Senior Member
Join Date: Nov 2018
Location: Slovakia
Old 03-09-2021 , 03:27   Re: [CSGO]SourceBans check if player is muted
Reply With Quote #4

Thanks works great.
Sajmooooon is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 12:32.


Powered by vBulletin®
Copyright ©2000 - 2021, vBulletin Solutions, Inc.
Theme made by Freecode