I want to create something like this energy bar in this picture, but the maximum size is dynamic, for example max health is 60 and i want 6 square, and when max health is 100, i need 10 square. i don’t know how to implement this, should i make material and custom progress bar?
Off the top of my head, I don’t know of any other way to easily get what you’re looking for. A UMG widget should be sufficient though.
The health bar that I outlined above is dynamic. You can add 10 images (10 health squares) to a horizontal box. You would then use the widget’s graph tab to toggle the visibility of these images according to how much health you have.
- Your character has 100 (Max) health.
You would display all 10 squares of
health in your UMG widget.
- You get hurt down to 60 health. You
would hide the last 4 squares of
health to match that.
thanks for your answer.
do you have other idea for this, because i want to create health bar that max health is dynamic and if i have 100 for max health, i need 10 square. and 60 health, just 6 square.