Exemplo n.º 1
0
    public Healthbar CreateHealthBar(Unit unit)
    {
        Healthbar newBar = Instantiate(healthbar, this.transform).GetComponent <Healthbar>();

        newBar.transform.SetAsFirstSibling();

        newBar.SetTarget(unit);

        return(newBar);
    }