Health UI

Health

To display vehicle health in the HUD:

  1. Add a Health Fill Bar Controller component somewhere on the vehicle.

  2. Set the Health field to the vehicle's Health component and set the Health Type you want to display

  3. Create an Image for the health bar and make sure its Image Type > Fill Method is set to Filled (you will need to add a sprite of some kind to the Image for this setting to appear)

  4. Drag the health bar image into the Bar Fill field in the inspector of the Health Fill Bar Controller component

Now the bar will fill proportionally to the health remaining on the vehicle.

Last updated