Raised This Month: $ Target: $400
 0% 

How to hide players say?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
GarbageBox
Senior Member
Join Date: Feb 2010
Old 08-01-2010 , 09:15   Re: How to hide players say?
Reply With Quote #1

It's same, still show /admin.
__________________
You can be a SUPER coder but you Haven't to say such as "stupid, etc." words to the others
GarbageBox is offline
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 08-01-2010 , 09:21   Re: How to hide players say?
Reply With Quote #2

Quote:
Originally Posted by GarbageBox View Post
It's same, still show /admin.
Worked perfectly for me.

__________________
Bugsy is offline
GarbageBox
Senior Member
Join Date: Feb 2010
Old 08-01-2010 , 09:26   Re: How to hide players say?
Reply With Quote #3

Can you show the full code?
I have changed it by also don`t work..
__________________
You can be a SUPER coder but you Haven't to say such as "stupid, etc." words to the others
GarbageBox is offline
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 08-01-2010 , 09:28   Re: How to hide players say?
Reply With Quote #4

I did not change anything else. Keep in mind, this only works if a player says only one of the trigger words: "who" , "admin" , or "/admin" (will not trigger if these words are said with other text).
PHP Code:
#include <amxmodx>

/*---------------EDIT ME------------------*/
#define ADMIN_CHECK ADMIN_KICK

static const COLOR[] = "^x04" //green
static const CONTACT[] = ""
/*----------------------------------------*/

new maxplayers
new gmsgSayText

public plugin_init() {
    
register_plugin("Admin Check""1.51""OneEyed")
    
maxplayers get_maxplayers()
    
gmsgSayText get_user_msgid("SayText")
    
register_clcmd("say""handle_say")
    
register_cvar("amx_contactinfo"CONTACTFCVAR_SERVER)
}

public 
handle_say(id
{
    new 
szSaid16 ];
    
read_argsszSaid charsmaxszSaid ) );
    
parseszSaid szSaid charsmaxszSaid ) );
    
    if( 
equaliszSaid "who") || equaliszSaid "admin") || equaliszSaid "/admin") ) 
    {
        
print_adminlistid );
        return 
PLUGIN_HANDLED;
    }
    
    return 
PLUGIN_CONTINUE
}  

public 
print_adminlistuser 
{
    new 
adminnames[33][32]
    new 
message[256]
    new 
contactinfo[256], contact[112]
    new 
idcountxlen
    
    
for(id id <= maxplayers id++)
        if(
is_user_connected(id))
            if(
get_user_flags(id) & ADMIN_CHECK)
                
get_user_name(idadminnames[count++], 31)

    
len format(message255"%s ADMINS ONLINE: ",COLOR)
    if(
count 0) {
        for(
count x++) {
            
len += format(message[len], 255-len"%s%s "adminnames[x], < (count-1) ? ", ":"")
            if(
len 96 ) {
                
print_message(usermessage)
                
len format(message255"%s ",COLOR)
            }
        }
        
print_message(usermessage)
    }
    else {
        
len += format(message[len], 255-len"No admins online.")
        
print_message(usermessage)
    }
    
    
get_cvar_string("amx_contactinfo"contact63)
    if(
contact[0])  {
        
format(contactinfo111"%s Contact Server Admin -- %s"COLORcontact)
        
print_message(usercontactinfo)
    }
}

print_message(idmsg[]) 
{
    
message_begin(MSG_ONEgmsgSayText, {0,0,0}, id)
    
write_byte(id)
    
write_string(msg)
    
message_end()

__________________
Bugsy is offline
GarbageBox
Senior Member
Join Date: Feb 2010
Old 08-01-2010 , 09:31   Re: How to hide players say?
Reply With Quote #5

Thank for all help.
I know what`s the problems.
I have fixed it.
Now Okay!
__________________
You can be a SUPER coder but you Haven't to say such as "stupid, etc." words to the others
GarbageBox is offline
Lulu the hero
Senior Member
Join Date: Oct 2009
Location: Budapest, Hungary
Old 08-02-2010 , 01:07   Re: How to hide players say?
Reply With Quote #6

Shouldn't this be in the plugin suggestion part?

Give him a simple code:
PHP Code:
#include <amxmodx>

public plugin_init(){
  
register_plugin("No speaking","1.0","Lulu the hero");

  
register_clcmd("say","say_hook");
  
register_clcmd("say_team","say_hook");
}

//lets hook the say/say_team
public say_hook(id){
  
//stop plugin from going further, eg. block chatmsg from being displayed
  
return PLUGIN_HANDLED;

Lulu the hero is offline
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 08-02-2010 , 08:38   Re: How to hide players say?
Reply With Quote #7

Quote:
Originally Posted by Lulu the hero View Post
Shouldn't this be in the plugin suggestion part?
His problem is solved, he was trying to replicate the online admins say cmd. Read the entire thread, specifically post #5. The code you posted was already provided by Jack86 in the beginning of the thread.
__________________

Last edited by Bugsy; 08-02-2010 at 08:44.
Bugsy 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 00:13.


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