i am doing this tutorial How To Create a Health and Damage System With a Health Bar in Unreal Engine 5 but the health bar updates only on death
Hey @cmpalkis how are you?
The best way to do this is to create an “update health bar” function in your Widget and then call it every time your character’s health is updated. You don’t need an event dispatcher for this!
To do that, when you create your widget in your cahracter, drag from the return node and promote it to variable (you can also remove the “Int Health Bar” calling there):
Then, in your widget, create a function which is exactly the same as you made in the following image, with same inputs and everything:
After that, you only need to Get the widget reference in your player and execute the new function from your character’s logic exactly where you are calling the Event Dispatcher right now:
With those changes, your health bar will update every time your character’s health is updated, as you are directly calling the function itself.
Hope this helps you! Let me know if you need more help!





