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

[REQ][CS:GO] Info after death.


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
SlayeR
Member
Join Date: Jan 2009
Location: Poland
Old 09-25-2012 , 16:13   [REQ][CS:GO] Info after death.
Reply With Quote #1

Hi.

I need and searching for sourcemod plugin for cs:go that will allow a player to speak or chat to teammates after death for few seconds (glad, if it can be defined). When player will chat it would look like this:

[INFO from (playername)] Message.

Is it exist? Or maybe someone can make this one? Would be amazing.

Regards.

Last edited by SlayeR; 09-25-2012 at 23:42.
SlayeR is offline
SlayeR
Member
Join Date: Jan 2009
Location: Poland
Old 09-26-2012 , 11:01   Re: [REQ][CS:GO] Info after death.
Reply With Quote #2

Here's this plugin for amxx cs 1.6. Can someone remake it to sourcemod cs:go?

Code:
#include <amxmodx>
#include <colorchat>
#include <fakemeta>

#define PLUGIN "Info po smierci"
#define VERSION "1.0"
#define AUTHOR "DarkGL"

#define MAX 32
#define IsPlayer(%1) (1<=%1<=32)

new bool:bCan[MAX+1]
new pTime

public plugin_init() {
	register_plugin(PLUGIN, VERSION, AUTHOR)
	
	pTime = register_cvar("info_smierci_czas","5");
	
	register_event("DeathMsg", "DeathMsg", "a")
	
	register_clcmd("say","sayHandle")
	register_clcmd("say_team","sayHandle")
	
	register_forward(FM_Voice_SetClientListening, "Forward_SetClientListening");
}

public sayHandle(id){
	if(!bCan[id]){
		return PLUGIN_CONTINUE;
	}
	new szTmp[128],szPrint[190],szName[64];
	
	read_argv(1,szTmp,charsmax(szTmp));
	trim(szTmp)
	
	get_user_name(id,szName,charsmax(szName));
	
	formatex(szPrint,charsmax(szPrint),"[Info od %s] ^x01 %s",szName,szTmp);
	
	ColorChat(id,GREEN,szPrint);
	
	for(new i = 1;i<=MAX;i++){
		if(!is_user_alive(i) || get_user_team(i) != get_user_team(id)){
			continue;
		}
		ColorChat(i,GREEN,szPrint);
	}
	bCan[id] = false;
	return PLUGIN_HANDLED;
}

public DeathMsg()
{	
	new vid = read_data(2)
	
	if(IsPlayer(vid) && !is_user_alive(vid)){
		bCan[vid] = true;
		remove_task(vid);
		set_task(float(get_pcvar_num(pTime)),"stopInfo",vid)
	}
}

public client_connect(id){
	bCan[id] = false;
}

public stopInfo(id){
	if(is_user_connected(id)){
		client_cmd(id,"-voicerecord")
	}
	bCan[id] = false;
}

public Forward_SetClientListening( iReceiver, iSender, bool:bListen ) {
	if(!is_user_connected(iSender) || !bCan[iSender] || get_user_team(iSender) != get_user_team(iReceiver) ){
		return FMRES_IGNORED;
	}
	
	engfunc(EngFunc_SetClientListening, iReceiver, iSender, true);
	forward_return(FMV_CELL, true)
	return FMRES_SUPERCEDE
}
SlayeR is offline
SlayeR
Member
Join Date: Jan 2009
Location: Poland
Old 09-30-2012 , 17:07   Re: [REQ][CS:GO] Info after death.
Reply With Quote #3

Bump.
SlayeR is offline
Reply



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 18:42.


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