 |
|
Veteran Member
|

01-09-2015
, 12:39
Re: [Check] Jailbreak Voice
|
#3
|
Quote:
Originally Posted by yan1255
I don't know why your's crashes the server but here's something I Just built.
Its not tested and supposed to block dead prisoners voice.
PHP Code:
#include < amxmodx > #include < fakemeta >
#define TALK_ACCESS ADMIN_LEVEL_F
enum _:Teams { FM_TEAM_UNASSIGNED, FM_TEAM_T, FM_TEAM_CT, FM_TEAM_SPECTATOR };
new gH_LRCanSpeak;
public plugin_init() { register_plugin( "JailBreak Voice Manager", "1.0", "Rejack" ); register_forward( FM_Voice_SetClientListening, "FwdVoiceSetClientListening" ); gH_LRCanSpeak = register_cvar( "amx_jailbreak_lr_can_speak", "1" ); }
public FwdVoiceSetClientListening( Rec, Sender, bool:bListen ) { if ( !is_user_connected( Sender ) || !is_user_connected( Rec ) ) return 1; if ( get_user_flags( Sender ) & TALK_ACCESS ) return 1; if ( fm_get_user_team( Sender ) == FM_TEAM_CT && is_user_alive( Sender ) ) return 1; if ( get_pcvar_num( gH_LRCanSpeak ) && TeamCount() == 1 && is_user_alive( Sender ) && fm_get_user_team( Sender ) == FM_TEAM_T ) return 1; engfunc( EngFunc_SetClientListening, Rec, Sender, 0 ); return FMRES_SUPERCEDE; }
stock TeamCount() { static Players[ 32 ], iNum; get_players( Players, iNum, "aceh", "TERRORIST" ); return iNum; }
stock fm_get_user_team( const index ) return get_pdata_int( index, 114 );
|
I think, once you have given me this code, and i use it and it dropped (crashed) my server
So I tried to build one myself, but Dead Prisoner Talking.
Check your code and tell me if working
|
|
|
|