How to open a Gate when there's movement input, and close it when there isn't?
Hi! I'm trying to make a directional dash function that can only be activated when there's movement input (eg. player can only dash forward when W key is pressed). This is what I have so far:
I'm not entirely sure how to do the Gate here - I could of course get all four WASD keys to Pressed=Open and Released=Close, though I feel like it would probably break something when doing rapid movement inputs. Not mentioning that I haven't even added controller input yet.
Is there any way to do it more elegantly and more bug-proof? Thanks! (criticism to the BP itself is also welcomed)
EDIT: I figured it out! Using AND Bool -
Perhaps you do not need a gate at all, maybe it's just enough to ask the controller whether W is being pressed:
And launch character after this check.
Or plug in the W input Pressed / Released into the gate's Open / Close
Follow this question
Once you sign in you will be able to subscribe for any updates here