WBP_LPSP_Healthbar

Introduction

The Healthbar Widget Blueprint (WBP_LPSP_Healthbar) is the blueprint in the asset that represents the health bar. It holds the visual representation and the nodes required to make everything function properly for it.

If you seek to access the WBP_LPSP_Healthbar, it is conveniently located at the following path: InfimaGames/LowPolyShooterPack/Core/Widgets/WBP_LPSP_Healthbar.

Functions

Get Percent:

Returns the owning character’s remaining health percentage.

Get Percent Text:

Returns the owning character’s remaining health percentage, as text.

Get Percent Visibility:

This function tells us how visible this health bar is from an actual player character. This is important so we can hide it locally when it is not needed.

Private Variables

Owning Actor:

This variable stores a reference to this widget’s owning actor. That’s it. Cool stuff.

Hidden:

This variable lets us know whether this widget is hidden or currently visible.

Update Scale Timer:

This variable stores the Timer Handle for the health bar scaling back up functionality timer.

Editable Variables

Hide Delay:

This variable determines the amount of time it takes for the widget to fade out after it has been set to be hidden.

Requires Visibility Changes:

This variable determines whether this widget needs to change its visibility based on factors such as whether the owning character is dead or other similar conditions.

Show Numbers:

This variable determines whether the widget should display the percentage of health numbers.

Requires Scale Changes:

This variable determines whether the widget's size should change based on how far it is from the player client that is viewing it.

Start Hidden:

This variable determines if this health bar should start the game hidden. If false, the health bar will be fully visible from the start.


Last updated

Was this helpful?