Tank health bars broken after adding mortar healthbar

Hi All,

Somehow my tank healthbars are grey’d out since adding one for the mortar. I am so sure that I have got it right in the code, but for some reason it comes up like this:

I’ve tried deleting derived files and regenerating my project in case of caching problem but the problem persists (maybe I’m not doing it right?)

In case you are wondering whether it is not set up properly, casting is definitely working as I tested by printing to screen:

I’m not too sure how to test the UI code with a string as the key code doesnt have the pins for it?, so this is all I could do here:

Any thoughts?

Sorry I know I have a habit of doing this, but I have fixed it mysefl.

Originally I had created a seperate mortar c++ file and set up the healthbar seperately for it and for some reason this meant that the UI would only present the mortar’s health bar (not sure why it should be this way though).

Since then I have reparented the mortar_BP to the Tank C++ class (ass its all the same code) and changed to one healthbar for both running off the “Tank Health” variable. Now it shows fine for all :slight_smile:

Still not sure why I cant have 2 different progress bars set up though!

Privacy & Terms