How can I make a HUD collectible item counter? Can print to screen, but not to HUD.

I managed to make the game count the items collected (here I call them Life) and print the number to screen. However, I want to have it add the number to a HUD.

this is what I have in the Life actor blueprint (the adding function)

this is what’s on the pawn character blueprint

this is the event graph for the HUD

and something I tried to do to get it to read the variable and bind it to an empty text box on the HUD (it doesn’t work)

Any help is really appreciated! I’m pretty new to this and can’t figure it out. Thanks!
welp

PS. If you know how to stop the counter from resetting every time I leave the level, and come back in, please share as well, it would really help.

It would probably be more efficient to handle the variable stuff in the pawn’s BP.

As far as printing to your HUD goes, change the binding to a new variable (i.e. Life) in the widget, and during the tick even cast to the pawn and set the widget’s Life variable to the pawn’s variable. I’ve personally only ever had problems with binding functions on widgets.

you are a beautiful human being! haha thank you so much, this worked.
Just in case, any idea on how to stop it from resetting?

oh nvm! I managed to use Game Instance to stop it from resetting.