Accessing Float From Blueprint and adding it to widget text

I want to have a percentage next to the pitcher to show the percentage of the thirst I have set up the floats in my character and make the widget and added the bind on the text and in blueprint converted float to text but it doesnt seem to work. im trying to achieve a image with the percent next to it and get that percent from the my character.

The variable “MyCharacter” in your widget is private - do you set this variable anywhere? Because if not, than you’d always be reading the thirst level of a non-existing character, which will result in 0.

Also I would recommend you use a float value of 0 … 1 instead of 0 … 100. This is easier to do math with, and there is a built-in function “AsPercent”, which you can use to convert a float percentage value to a number (e.g. 0.35 → 35%).

You need to assign a value to the variable, as it currently stands, the variable can hold a character, but it’s not pointing at anything. Probably the easiest way to do what you want, is to add the following in the Event Construct of your widget:

Of course you should replace the “Cast to Character” with a cast node to your custom character class (in your case probably ThirdPerson Character).