have you tried making a wrap box and using a loop to add widgets?
make 2 widget blueprints, and delete their canvases. add a wrap box to one, and an image to the other. bind the image’s brush to a function. make a SlateBrush variable that is set to editable and exposed on spawn, and connect it to the GetBrush function’s return value.
then in the other widget, the one with the wrap box, you can use forloops to create the image widgets, and add them each as a child of the wrap box.
if you add your wrap box widget to your main HUD widget, with dimensions of 335 x 100, it should look like this:
and if for some reason you want to convert health from a percentage of 100 to a range of 5 hearts, you could just divide the health by 100, then multiply by 5, and round down.
( Health / 100 ) * MaxHealth = NewHealth
( 60 / 100 ) * 5 = 3
