Get netname of message
Is there a way to get the netname of a hooked message? I need this because the message I am hooking has the netname of the player it is affecting, but doesn't have an argument for the player.
Also, what is the difference between a register_event and register_message? |
Re: Get netname of message
As for first part i'm not quite sure what are you talking about.
As for second part. The first one is a post version of forward and the second one is a pre version of forward and therefore it is allow to block or alter the whole message. |
Re: Get netname of message
Ok thanks a ton, that really cleared things up.
For what you didn't understand: I am hooking a message that doesn't have the users id in it. I notice that it says "Netname <playername>" in the message though. Is there a way to get that netname from the message to use in my plugin, or some other way to find out which player the message is affecting. |
Re: Get netname of message
Use Message Logging plugin by Damaged Soul then copy/paste the result for that message here.
|
Re: Get netname of message
Quote:
This works to get the players id with register_event. Would I be able to do something like that with register_message? Code:
Edit: Are there tags for amxx code besides the [ small][ /small]? |
Re: Get netname of message
Yes hook prototype for register_message would be function(msgid, dest, id). You can find more info in amxmodx/scripting/include/ also you can refer to functions reference.
|
| All times are GMT -4. The time now is 10:41. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.