Hi all, - sorry i’m new to UE so not sure if i’m missing something obvious here but any help would be greatly appreciated.
I have a struct that stores the LIF value of a monster. that struct is then called in an onclick event that updates the LIF value and stores it (i think correctly?) the print debug is correctly updating the value:
I have a simple UI widget where i just want to display the updated value - however it’s only showing the default value - and when i press the onclick event - it doesn’t update the UI widget value:
What if you use a simple float variable instead, temporarily, for testing?
This will isolate whether it’s a logic problem, or a “structs are values, kinda” problem.
ah so - i’ve noticed a problem - the button to update the LIF has a “back” button underneath it. when i press the back button to go to the prior menu, and then click to update the LIF value again, it resets to 220 - so the issue isn’t with the widget, its that the struct is being reset when i exit the menu to update the LIF - but i have no idea why!
These are the only two buttons being pressed that’s causing the LIF stat to reset: