Ejemplo n.º 1
0
    // Start is called before the first frame update
    void Start()
    {
        text = this.gameObject.GetComponent <TextMeshProUGUI>();
        TouchInputManager touchInputManager = TouchInputManager.getInstance();

        touchInputManager.SubscribeSwipeListener(this, 0);
        touchInputManager.SubscribeTapListener(this, 0);
        touchInputManager.SubscribeDragListener(this, 0);
    }
    void Start()
    {
        donnaManager.gameObject.SetActive(duoTrapeze);
        if (gradedPerformance)
        {
            timerText.gameObject.SetActive(true);
            exitBtn.SetActive(false);
        }
        duoTrapeze = false;
        TouchInputManager t = TouchInputManager.getInstance();

        if (t == null)
        {
            Destroy(this);
        }
        trickGUI = TrickGUI.GetInstance();
        t.SubscribeTapListener(this, 0);
        t.SubscribeSwipeListener(this, 0);
        if (playerAvatar == null)
        {
            Debug.Log("Player Avatar is null");
            Destroy(this);
        }
        pmt = playerAvatar.GetComponent <PlayerManager_Trapeze>();
        if (pmt == null)
        {
            Debug.Log("Player Avatar is missing PlayerManager_Trapeze script");
            Destroy(this);
        }
        if (scriptToLoad != null)
        {
            dialogueRunner.Add(scriptToLoad);
        }
        if (canTutorial)
        {
            tutorialManager.SetActive(true);
        }
    }