I have kind of a problem though. Why the hell does the deathevent happen BEFORE the dmgevent? -- is that just something AMX isn't handling correctly?
Is there a way to make sure it handles dmg events before deathevents? |
just block the tk deathmessage with register_message...u can catch the message before the event is sent....I tried it b4 and it worked like a charm....only 1 problem....I got crashes every map change when I had the register_message in my plugin
|
Yes ts2do I also had that problem. A temporary fix (temporary because BAILOPAN has rewritten the Engine module, the bug should be fixed) is to block the message and register_event it. Works nicely for me :)
|
Someone mind showing me an example of the register_message event? This is a relatively new function and not many plugins out there that use it.
and how to pass or not pass altered data? and how to find out what events I can register?...this sounds VERY interesting and VERY useful. |
Code:
That will effectively dump the contents of any message... it's broken in 0.16, fixed in 0.20 Using the other functions you can find the definitive types and make new messages or edit the current one in real time. That way you can actively block a message, for example: if (get_msg_arg_int(2) == get_msg_arg_int(1)) return PLUGIN_HANDLED block the message if the killer and victim are the same person |
does returning it 1 actually block it? I thot u had to use set_msg_block( get_user_msgid ( "Damage" ), BLOCK_ONCE )
|
wow, THANK YOU BAILO!
Thats some pretty sweet schtuff... Can't wait for .20 |
yes that blocks it
|
| All times are GMT -4. The time now is 15:16. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.