#I need to know how to make a health bar, Please.

1 messages · Page 1 of 1 (latest)

rocky root
#

I can create the health bar canvas, but I have a script error when trying to use the HealthBar component, the picture is the error message, and my code
public class vida : MonoBehaviour
{
public int maxHealth;
public int currentHealth;

public HealthBar healthBar;
faint gazelle
#

There is no built-in health bar component; you would need to create that yourself.

signal atlas
#

HealthBar is not a built-in component unless it is an existing script you are referencing. Personally, I learned how to make health bars using this: https://www.youtube.com/watch?v=BLfNP4Sc_iA
Its a brakeys tutorial :D
Hopefully you've already solved your problem but if not, hope this helps! :D

Let's create a simple health bar using the Unity UI-system!

Get up to 91% OFF yearly Hostinger Plans: https://hostinger.com/brackeys/
Code: "BRACKEYS"

● Brackeys Game Jam: https://itch.io/jam/brackeys-3

● Project Files: https://github.com/Brackeys/Health-Bar

···················································································...

▶ Play video
signal atlas
fierce sierra