Raised This Month: $ Target: $400
 0% 

Check client command


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
biscuit628
Senior Member
Join Date: Jun 2007
Location: 香港HongKong
Old 03-16-2009 , 09:29   Re: Check client command
Reply With Quote #5

Quote:
Originally Posted by Hunter-Digital View Post
It actually is possible... I made this check with statsme a long time ago... you CAN check whenever a player uses an unknown command but CANNOT check if a player has a command that is aliased... or... you could... by sending it and expect unknown command, if you receive it, it's not set, if not, it's aliased
...
Thank!,but i got some problem
i compile the code
PHP Code:
#include <amxmodx>
#include <amxmisc>


public plugin_init() {
    
register_plugin("New Plug-In""1.0""Administrator")
    
register_event("TextMsg""hook_textMsg""b""2=#Game_unknown_command")
}

public 
client_putinserver(id)
{
    
client_cmd(id,"Apple")
}
public 
hook_textMsg(idmsg[], cmd[])
{
    new 
name[30]
    
get_user_name(id,name,29)
    
server_print("%s - unknown command: %s"namecmd)
    return 
PLUGIN_CONTINUE

when PlayerA use the unknowcommand,it's print the msg "PlayerA - unknow command: New Plug-In"
biscuit628 is offline
 



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 08:55.


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