Exemplo n.º 1
0
    // Update is called once per frame
    protected virtual void Update()
    {
        switch (currentState)
        {
        case EnemystateMachine.Idle:
            m_Idle.Execute(this.gameObject);
            break;

        case EnemystateMachine.Move:
            m_Move.Execute(this.gameObject);
            break;

        case EnemystateMachine.Attack:
            m_Attack.Execute(this.gameObject);
            break;

        case EnemystateMachine.Death:
            m_Death.Execute(this.gameObject);
            break;
        }
    }