plugins/basecomm.sp
changeset 4262 c2836eb6c34a
parent 4120 4b581bb374c8
     1.1 --- a/plugins/basecomm.sp	Thu Feb 27 23:46:51 2014 -0500
     1.2 +++ b/plugins/basecomm.sp	Fri Feb 28 10:38:36 2014 -0500
     1.3 @@ -98,22 +98,6 @@
     1.4  	{
     1.5  		OnAdminMenuReady(topmenu);
     1.6  	}
     1.7 -	
     1.8 -	// Normally, OnClientSayCommand would be aqequate and more appropirate here, but it does
     1.9 -	// not catch attempted chat triggers, which we also want to be blocked if a player is gagged.
    1.10 -	AddCommandListener(Command_Say, "say");
    1.11 -	AddCommandListener(Command_Say, "say_team");
    1.12 -	
    1.13 -	new String:gameDir[64];
    1.14 -	GetGameFolderName(gameDir, sizeof(gameDir));
    1.15 -	if (StrEqual(gameDir, "insurgency", false))
    1.16 -	{
    1.17 -		AddCommandListener(Command_Say, "say2");
    1.18 -	}
    1.19 -	else if (StrEqual(gameDir, "nucleardawn", false))
    1.20 -	{
    1.21 -		AddCommandListener(Command_Say, "say_squad");
    1.22 -	}
    1.23  }
    1.24  
    1.25  public OnAdminMenuReady(Handle:topmenu)
    1.26 @@ -167,14 +151,11 @@
    1.27  	return true;
    1.28  }
    1.29  
    1.30 -public Action:Command_Say(client, const String:command[], argc)
    1.31 +public Action:OnClientSayCommand(client, const String:command[], const String:sArgs[])
    1.32  {
    1.33 -	if (client)
    1.34 +	if (client && g_Gagged[client])
    1.35  	{
    1.36 -		if (g_Gagged[client])
    1.37 -		{
    1.38 -			return Plugin_Stop;		
    1.39 -		}
    1.40 +		return Plugin_Stop;
    1.41  	}
    1.42  	
    1.43  	return Plugin_Continue;