Hey guys! I’m going to try to not make this a novel and keep it as intelligible as possible, but I’m really at a loss and there’s a lot of information in there so here goes nothing:
Essentially, we’re making this game and I’m trying to make the UI for it. As part of the UI, I’m trying to display the characters’ health on health bars that work in percentages.
I managed to make the game’s main character’s one work perfectly fine, like so:
The character has 300 health, you see. That’s a part of the Widget graph I’m showing. The character’s blueprint part that takes care of health looks like this:
Essentially it has a base of 300, and whenever he makes contact with a source that causes damage, it received the value of that damage, deals it, then goes back to null until new damage is applied. Following this, and the first picture, the health bar works perfectly fine.
However, when it comes to the boss, nothing works.
It’s based on the same model, and I’ve tried connecting many types of sources (you see them on the left) without success. The health bar is always at a 100% without fail, and even when the monster takes damage and the game acknowledges it, the health bar just won’t go down like the main character’s will.
The boss has his own Blueprint as well, like so:
He has 1000 health, and takes 15 damage per hit, but his health bar is permanently full all the time. For some reason, casting to the boss’ blueprint fails all the time no matter what I try and since the same logic works in the main character’s hands, I’m at a complete loss as to why this isn’t working. I’ve lost 5 hours over this “simple” thing now, and I’m almost ready to give up, which I can’t afford to do.
Anyone got an idea? If anyone’s got any questions to try and clarify it let me know I’ll do everything I can to provide info! Thank you!
Sorry for the novel and for the possibly simple issue, I’ve picked up Blueprints only very recently. I hope someone can help!!!
Thanks!