Raised This Month: $51 Target: $400
 12% 

Removing clientside mutes against admins


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Joeakuaku
Junior Member
Join Date: Sep 2013
Old 07-18-2019 , 01:09   Removing clientside mutes against admins
Reply With Quote #1

So I'm trying to hack something together that's able to remove clientside mutes towards admins, in case they need to communicate to everyone - but I've had little luck getting it working as a novice to this.

Code:
public Action unmuteMeV(client, args) {

	char attArg[65];
	GetCmdArg(1, attArg, sizeof(attArg));
	
	int target = FindTarget(client, attArg, false, false);
	
	PrintToChat(client, "[DEBUG] GetListenOverride(%N, %N): %d", target, client, GetListenOverride(target, client));
	SetListenOverride(target, client, Listen_Yes);
	SetClientListening(target, client, true);
	PrintToChat(client, "[DEBUG] GetListenOverride(%N, %N): %d", target, client, GetListenOverride(target, client));
	PrintToChat(client, "[SM] You can now be heard by %N", target);
	
	return Plugin_Handled;

}
That's the main function I'm using - but GetListenOveride always ends up reporting 1, whereas 2 is the correct number, I believe, for unmuted.

Ideally I'd have it loop through every player and have them unmute the issuing admin, but right now I'm just trying to get it working at all.

Depicted is me running a mute-check, attempting to unmute "cringe patrol", then checking again.
Joeakuaku is offline
 



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 20:40.


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