コード例 #1
0
 public override void Update()
 {
     timer += Time.deltaTime;
     if (timer > 3)
     {
         WorldSceneManager.LoadBreakRoom();
     }
 }
コード例 #2
0
 public void BossDeath()
 {
     currentStage = 4;
     FindObjectOfType <PlayerMovement>().currentState = 4;
     bossAnimator.Play("BossDeathAnimation");
     deathSounds[2].Play();
     deathSounds[0].Play();
     WorldSceneManager.LoadBreakRoom();
 }
コード例 #3
0
    public void Phase1()
    {
        //if player is pulled by hook sets colliders in cols off
        if (playerMovementScript.currentState == 1)
        {
            cols.gameObject.SetActive(false);
        }
        else
        {
            cols.gameObject.SetActive(true);
        }

        if (LeversActivated == 3)
        {
            WorldSceneManager.NextScene();
        }
    }
コード例 #4
0
    private void OnTriggerEnter2D(Collider2D collision)
    {
        if (IsStart == true)
        {
            if (collision.gameObject.tag == "Player")
            {
                //SceneManager.LoadScene("Main");
                WorldSceneManager.NextScene();
            }
        }

        if (IsQuit == true)
        {
            if (collision.gameObject.tag == "Player")
            {
                Application.Quit();
            }
        }
    }
コード例 #5
0
    void Awake()
    {
        if (instance != null && instance != this)
        {
            Destroy(this.gameObject);
            return;
        }
        else
        {
            instance = this;
        }
        DontDestroyOnLoad(this.gameObject);

        INTERACTIVEMENU  = "InteractiveMainMenu";
        BREAKROOM        = "BreakRoom";
        MAINMENU         = "MainMenu";
        SUBMITSCORESCENE = "SubmitScoreScene";
        WATERSTAGEPHASE1 = "Stage2Phase1";
        WATERSTAGEPHASE2 = "Stage2Phase2";
        FIRESTAGE        = "ThirdBoss";
        ELECTRICSTAGE    = "Main";
    }
コード例 #6
0
 /// <summary>
 /// Used for the quit button in deathcanvas, should be moved to load mainmenu once InteractiveMainMenu is done
 /// </summary>
 public void ToMenu()
 {
     WorldSceneManager.LoadInteractiveMenu();
 }
コード例 #7
0
 public void LoadNextScene()
 {
     WorldSceneManager.LoadNextScene();
 }
コード例 #8
0
 public void LoadSceneAgain()
 {
     WorldSceneManager.LoadCurrentRoom();
 }