Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

Delay when changing Scene

Discussion in 'Scripting' started by Alef_Ribeiro, May 11, 2015.

  1. Alef_Ribeiro

    Alef_Ribeiro

    Joined:
    May 11, 2015
    Posts:
    5
    I hum problem in my game it takes some annoying Seconds To change scene ( do pro game menu, the pro game over Game ) Since the Computer the transition is normal

    My code is relatively simple ( C # )

    public void TryAgain()
    {
    Application.LoadLevel ("PlayGame");
    }

    public void GoMenu()
    {
    Application.LoadLevel ("Menu");
    }

    public void Quit ()
    {
    Application.Quit ();
    }

    I call functions in the very basic Canvas buttons and do not know why delay
     
    Last edited: May 11, 2015
  2. 5vStudios

    5vStudios

    Joined:
    May 9, 2015
    Posts:
    106
    Last edited: May 11, 2015
  3. Alef_Ribeiro

    Alef_Ribeiro

    Joined:
    May 11, 2015
    Posts:
    5
    I tried to do so and also could not

    Code (CSharp):
    1. public void TentarNovamente () {
    2.         Application.backgroundLoadingPriority = ThreadPriority.Low;
    3.         AsyncOperation async = Application.LoadLevelAsync ("PlayGame");
    4.     }
    5.  
    6.     public void VaiMenu () {
    7.         AsyncOperation async = Application.LoadLevelAsync ("Menu");
    8.         Application.backgroundLoadingPriority = ThreadPriority.High;
    9.     }