示例#1
0
    //PUSH UP
    public void PushUp()
    {
        if (m_player.hasLightBulb)
        {
            Node EnemyNode = m_board.FindNodeAt(transform.position);

            if (m_board.playerNode.transform.position.x == EnemyNode.transform.position.x && Vector3.Distance(EnemyNode.transform.position, m_board.playerNode.transform.position) < 3f && m_board.playerNode.transform.position.z < EnemyNode.transform.position.z)
            {
                Debug.Log("MoveUp");
                m_enemyMover.MoveForward();

                m_enemyMover.destination = m_player.transform.position;
                m_enemyMover.FaceDestination();
                m_player.clearPlayerPath();
                m_enemyMover.firstChaserMove = false;
            }
        }
    }