Xperl health bar not updating
I am also trying to setup a percent display showing current health vs. Not exactly sure how to get this to function correctly. Tested with recently released 4.6 Mr Grins answer solves the problem, go for it.I don't know where it can't get the value and properly convert since this function is supposed to return any value in percentage.
The idea is that once the value of the blood variable dips below certain point numbers it a effects how the health regenerates, for example; if the blood value has decreased to less than 150 the health will only regenerate half as fast as it did when the blood was higher than 150.
I think I've got the hang of the basic math, but when I try to link the variable to a progress bar the best I've got is that the bar is empty or 100% full.
I can't get the bar to gradually decrease to reflect the two second decay.
Attached is an image of my "blood blueprint", which I should mention is in the Third Person Character Blueprint. I'm trying to create a blood variable (default value 200) that will decrease by 1 point every 2 seconds.
Attached is an image of my "blood blueprint", which I should mention is in the Third Person Character Blueprint.
I have followed the UMG tutorial and generated a hud.
When I press the button assigned to simulate health loss the bar does not update until it is empty.
I set up text blocks to show the health as text just like the ammo setup.
My health counts down correctly yet the bar does not empty until the health value reaches 0.