Я хочу перехватить сообщения типа "Say @" от сервера, но блокировать их не получается. Сообщение просто дублируется. Возможно ли это? Кто может что подскажет?
Код прилагается.
Код прилагается.
public OnPluginStart()
{
AddCommandListener(HookServerChat, "say");
}
public Action:HookServerChat(client, const String:command[], args)
{
if (client == 0)
{
if (args < 1)
{
ReplyToCommand(client, "[SM] Usage: say <message>");
return Plugin_Handled;
}
decl String:text[192];
GetCmdArgString(text, sizeof(text));
CPrintToChatAll("{white}[{lime}FoxWorld{white}] %s", text);
return Plugin_Handled;
}
return Plugin_Continue;
}
{
AddCommandListener(HookServerChat, "say");
}
public Action:HookServerChat(client, const String:command[], args)
{
if (client == 0)
{
if (args < 1)
{
ReplyToCommand(client, "[SM] Usage: say <message>");
return Plugin_Handled;
}
decl String:text[192];
GetCmdArgString(text, sizeof(text));
CPrintToChatAll("{white}[{lime}FoxWorld{white}] %s", text);
return Plugin_Handled;
}
return Plugin_Continue;
}