protected override void Update()
    {
        if (!isBirdDie)
        {
            State = StateBird.Fly;
        }
        else
        {
            State = StateBird.Die;
        }

        Move();

        /* if(transform.position.y < -10)
         *   ReceiveDamage();*/
    }
Exemple #2
0
    protected override void Update()
    {
        UIHP.fillAmount = HP / 100;

        if (HP <= 0)
        {
            isBossDie = true;
        }

        if (!isBossDie)
        {
            State = StateBird.Fly;
        }
        else
        {
            State = StateBird.Die;
        }

        if (System.Math.Abs(transform.position.x - character.CharacterPosition) <= System.Math.Abs(11))
        {
            Move();
        }
    }