message_begin seem do not work
I want to force a player using knife and wrote such code
Code:
I got "Weapon Knife msg is sent to 1" in chat message,but Can not recive the knife message ... How to resolve this problem? Thanks.... |
Just use client_cmd instead of engclient_cmd.
|
thank you,XxAvalanchexX, I have tried the function client_cmd(), it will send the CurWeapon message. but there is a little problem, if I press 1 and press fire(mouse left button) fast enough, one bullit will be fired...
and this is the reason why I use engclient_cmd.. |
That would mean that there is enough time to play the gun cocking animation, which takes at least half a second. Are you 100% sure? Try removing the first parameter check in register_event.
|
It's not only an animation, but a bullit is fired really...
|
maybe this is due to that register_event is called when the action happened
try hooking the message itself register_message(get_user_msgid("CurWeapon"), "your_func_name") and replace read_date with get_msg_art_* (int / str or float , depends on what type it is, here it is int) |
| All times are GMT -4. The time now is 19:19. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.