Raised This Month: $48 Target: $400

[L4D/L4D2/CS:GO] VoiceHook

Post New Thread Reply   
Thread Tools Display Modes
Author Message
AlliedModders Donor
Join Date: Dec 2010
Location: Russia
Old 02-18-2016 , 11:18   [L4D/L4D2/CS:GO] VoiceHook
Reply With Quote #1

This extension adds a function of capture events the player who at the moment speak.

Example to use:
#include <sourcemod>

forward OnClientSpeaking(client);

public Extension:__ext_voice = 
	name = "VoiceHook",
	file = "VoiceHook.ext",
	autoload = 1,
	required = 1,

bool ClientSpeaking[MAXPLAYERS+1];
int iCount;
char SpeakingPlayers[128];

public void OnPluginStart()
	CreateTimer(0.7, UpdateSpeaking, _, TIMER_REPEAT);

public OnClientSpeaking(client)
	ClientSpeaking[client] = true;

public Action UpdateSpeaking(Handle timer)
	iCount = 0;
	SpeakingPlayers[0] = '\0';
	for (int i = 1; i <= MaxClients; i++)
		if (ClientSpeaking[i])
			if (!IsClientInGame(i)) continue;
			Format(SpeakingPlayers, sizeof(SpeakingPlayers), "%s\n%N", SpeakingPlayers, i);
		ClientSpeaking[i] = false;
	if (iCount > 0)
		for (int i = 1; i <= MaxClients; i++)
			PrintCenterText(i, "Players Speaking:%s", SpeakingPlayers);

Last edited by Accelerator74; 12-25-2016 at 05:48.
Accelerator74 is offline
Send a message via ICQ to Accelerator74
Veteran Member
Join Date: Oct 2010
Location: Spain (Madrid)
Old 02-18-2016 , 12:13   Re: [L4D/L4D2/CS:GO] VoiceHook
Reply With Quote #2

This plugin does the same that your extension -> https://forums.alliedmods.net/showthread.php?t=245384

And now I updated the gamedata for update support for L4D and L4D2 -> https://forums.alliedmods.net/showpo...5&postcount=47
Veteran SourceMod Coder
Taking paid requests -> Add me in TELEGRAM or STEAM
or Discord Franc1sco#7876
| You like my work? donate me

Franc1sco is offline
Send a message via MSN to Franc1sco Send a message via Skype™ to Franc1sco

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 14:25.

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