Hi everyone,
I am attempting to continue my learning/add functionality to the games like BattleTank now that I’ve finished the Unreal course. On BattleTank, for example, I’ve redone the scenery with a height map, changed to new meshes, and added a firing sound with attenuation.
But at the moment I’m wanting to ditch the health bar on the player controlled tank for a visual indicator on the HUD. I’ve got a tank silhouette .png that I’m going to change the color of depending on damage taken. I’ve run into some problems accomplishing this. In the course we reworked the Player controller, and now a found event for the AimingComponent creates the PlayerUI, with no reference to the tank itself.
As far as I can tell, I need to get a reference to the tank so I can set a variable for the UI BP to get the tank health value or health percent. I’m not sure what the right way to do this would be. My failed attempts so far have returned a warning in the log on play that the variable returns “none” in the PlayerUI_BP. I would appreciate any help