+command wont work
Im trying to get a feature in my plugin to be triggered when the user is firing his weapon but +attack don't work. In fact nothing with "+" in front of a command works. What causes +commands to fail?
Here's what I have. PHP Code:
|
Re: +command wont work
You cannot hook all commands that way. You have to either hook command start or prethink and check if a user's button field contains IN_ATTACK.
|
Re: +command wont work
Im not sure how to do that. Would get_clcmd make it work? client_PreThink, get_user_button, get_usercmd only has one parameter. Idk where to start.
|
Re: +command wont work
Code:
|
Re: +command wont work
Ok, I tried that but wont up causing the feature no to work at all.
I have register_forward( FM_CmdStart, "speed_task"); register_event("Spectator", "speed", "abcde"); The way I have it is when the HW looses health below 40 he gets a speed rush untill his heath is back above 40. But set_user_maxspeed over rides the slow down speed when firing his minigun so the speed never differs. So this needs to be fixed so when minigun is firing the HWguy slows down like he should. I also have set_task to keep the code responding down to the milliseconds in a way where caping the flag dont glitch amxx and forget the players index. Register_event is to start running the tasks because it only seems to index players (individually to be specific) by the player him self triggers the code block. Im having a heck of a time applying a fix for this minor game play issue along with the pre existing code. |
| All times are GMT -4. The time now is 14:33. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.