Raised This Month: $ Target: $400
 0% 

Solved how to block this MSGs ?


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
abdobiskra
Veteran Member
Join Date: Jul 2014
Location: Algeria
Old 04-06-2017 , 10:42   Re: how to block this MSGs ?
Reply With Quote #10

thx to Lev aghl.ru for Help :

PHP Code:
public plugin_init() {
    
    
//register_message( get_user_msgid( "TextMsg" ), "msg_TextMsg" );
    
register_message(get_user_msgid("SayText"), "msg_TextMsg");
}


public 
msg_TextMsg(msg_idmsg_destmsg_entity)
{
   
server_print("************ ^nmsg_TextMsg(%d, %d, %d)^n************ "msg_idmsg_destmsg_entity);

   new 
dest get_msg_arg_int(1);
   
server_print("=================== ^ndest: %i^n=================== "dest);

   if (
dest != print_notify)
      return 
PLUGIN_CONTINUE;
   
   new 
text[1024];
   
get_msg_arg_string(2textcharsmax(text));
   
server_print("-------------------- ^ntext: %s^n----------------"text);

   if (
text[0] == '*' &&
   (
contain(text"Can't change team to") > ||
   
contain(text"Server limits teams to") > 0))
   {
      
server_print("-------------------- ^nPLUGIN_HANDLED^n----------------");
      return 
PLUGIN_HANDLED;
   }
   return 
PLUGIN_CONTINUE;

__________________
abdobiskra is offline
Send a message via Skype™ to abdobiskra
 



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 17:50.


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