HUD Binding doesn't seem to get called

Hi there, after scouring the internet, I decided to just ask the question myself instead of banging my head against this problem as I cannot figure it out by myself.

I’m trying to make a progress bar in UMG which fills up when the player interacts with an actor in my scene. Once the player isn’t interacting with the actor anymore I want the progress bar to stop filling up and stay at the value until the player interacts with the actor again.

I Started with creating the HUD and binding a function to my progress bar which should fill up.
Then I created a variable called Studypoints in the actor BP. I let it gradually increase with a simple deltaseconds added to the value if the player has interacted with the actor.
In my function I made a variable of my actor BP and call the Studypoints variable from it, then divide it by 100 to get a percentage which I output into the return node on the function.

I know my calculations in my Actor BP are working because the printfunction shows the value increasing when the player interacts with the actor.
I also know that my HUD is enabled and it updates as I’ve already successfully added a “Press E to interact” prompt when close to the actor.
When I incorporate a printfunction inside my progressbar function, nothing will show which leads me to believe that my bound function never even gets called.

I’m pretty new to unreal so it might just be me overlooking a simple checkbox. But any help would be appreciated!

244188-hud-example4.gif

Hi I’m not the best in english but if you dont understand why your progress bar are not moving… 0 mean empty and 1 = full bar. So be sure the studypoint value stay between 0 and 1. Hope thats what you’re looking for

Thanks Denis for the quick response! In my bpwidget picture I made sure to divide my float value for the studypoint by 100 so it should always be between 0.0 and 1.0. Do you think it’s necessary to add a clamp to make sure it doesn’t go below or beyond 0.0 and 1.0? And if so should I clamp the value in my widget function or in my blueprint?
Thanks anyway. I think it has more to do with either the studypoint value never getting called by the function or the entire function never being executed as the hello world string also never shows up which I placed inside the widgetfunction. Do you have any idea as to why that may be?

1 Like

This same thing is happening to me. I have a health , mana , and stamina progress bar. All three are bound but when I used a print string, only the stamina bind function is being called. and its being called every frame. However the health and mana functions are not being called at all. they are all using the same character reference which cast to at the construct of the widget. So weird. I can’t figure this out.