different
whats the diffrent between
Code:
get_user_button(id)Code:
get_user_oldbutton(id) |
Re: different
button = button player holding in current frame
oldbutton = button player was holding in previous frame button && oldbutton = player holding button button && !oldbutton = player pressed button (not holding) !button && oldbutton = player released button For use with Code:
#define IN_ATTACK (1<<0) |
Re: different
So this is right?
Code:
if ((button & IN_USE) && (oldbutton && IN_USE)) |
Re: different
Use button is being held (make sure you replace the && with & in the oldbutton condition.
if ((button & IN_USE) && (oldbutton && IN_USE)) Use button released if ((!button & IN_USE) && (oldbutton & IN_USE)) |
| All times are GMT -4. The time now is 00:06. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.