Make health bar with various levels (boss)

Hi, I’m making a health bar for bosses using a slider, and because those bosses have a large amount of HP, I want that bar have levels, something like this:

https://dl.dropboxusercontent.com/u/108692101/BAR1.png

So, when I damage the boss, the bar depletes:

https://dl.dropboxusercontent.com/u/108692101/BAR2.png

And when that level is gone, the bar reverts its size and one of the spheres dissapear:

https://dl.dropboxusercontent.com/u/108692101/BAR3.png

Every level equals 100 HP, and when it decreases or increases over its limit, its level changes. I need help with this please.

I don’t know what you have tried, or how you have implemented the way the damage is done. But you can create the health bar and sphere as a prefab, and put it in a folder named “Resources” then you can load both the health bar and the sphere runtime:

GameObject bar = Instantiate(Resources.Load("BAR", typeof(GameObject)));
GameObject sphere = Instantiate(Resources.Load("SPHERE", typeof(GameObject)));

Another approach could be to create a public reference to both the bar and sphere form your script as a GameObject, and load them runtime:

var bar = Instantiate(BAR) as GameObject;
var sphere = Instantiate(SPHERE) as GameObject;

And end up something like this:
public int Health;
public int Levels;

public GameObject BarHolder;
public GameObject Bar;
public GameObject Sphere;

// Update is called once per frame
void Update () 
{
    if (Health <= 0)
    {
        Levels--;
    }
    if (Health >= 100)
    {
        Levels++;
    }
}

private void RemoveLevel()
{
    var bar = Instantiate(Bar) as GameObject;

    // This moves the bar to the right place, of the GameObject is placed right
    bar.transform.parent = BarHolder.transform;
    Destroy(Sphere);
}

private void AddLevel()
{
    // TODO same as Remove just 
}

When you need to remove the gameobject just call Destory(BAR) or Destroy(SPHERE). Here’s some more reading: