Boolean not casting properly inside UMG Blueprint

Hi! Im trying to cast a simple Boolean that I set in my character blueprint to my UMG to let my widget know when my key is no longer held, so that it can destroy itself.
However, the Boolean in the UMG seems to disregard how it’s set in the character BP, and gets set to True in the UMG blueprint regardless. What am I doing wrong?

nzCddAp.jpg

I would like to set up my blueprint in a way that the Widget would destroy itself without finishing when I let go of the input key, I haven’t had much luck in achieving this yet.

I’ve uploaded my blueprints here so its easier to see

Seems to me that you’re testing it in the wrong place. “Event Construct” will run when the widget is constructed only so the variable will always be true. You would need to check if it’s false on another function, it would work on Tick for instance. Though what I really suggest is for you to create a “Remove” function in your widget and call that when the key is released.

Thank you for the super detailed answer @franktech

I decided to go with custom events instead of a boolean and that works to an extent. Im still not able to get my radial load to function how I want it to for some reason. When the alpha parameter fills up, or when the space bar is not pressed, I want the alpha to be set to Zero and the widget removed.

That way if the player spams the space bar, there wont be multiple instances of the radial load widget. Wont there be multiple instances running with toggle visibility? Not sure what Im doing wrong.

Solved it! I ended up toggling the visibility in the widget BP. Thanks again!