public void OnLevelClicked(GameSettings.LevelInfo level)
 {
     if (isClicked == false)
     {
         transition.LoadLevel(level);
         isClicked = true;
     }
 }
    public void LoadLevel(GameSettings.LevelInfo level)
    {
        /*
         * // Play sound
         * Sound.Play();
         *
         * // Set the next level
         * nextLevel = level.SceneName;
         *
         * // Start fading in
         * StartCoroutine(FadeIn());
         *
         * // Check what level we're loading to
         * fullScreenText.text = level.DisplayName;
         * */

        // Not sure why the scene transition script is now broken...
        Application.LoadLevel(level.SceneName);
        Singleton.Get <PoolingManager>().DestroyAll();
    }
Beispiel #3
0
    public void LoadLevel(GameSettings.LevelInfo level)
    {
        // FIXME: Not sure why the scene transition script is now broken...

        /*
         * // Play sound
         * Sound.Play();
         *
         * // Set the next level
         * nextLevel = level.SceneName;
         *
         * // Start fading in
         * StartCoroutine(FadeIn());
         *
         * // Check what level we're loading to
         * fullScreenText.text = level.DisplayName;
         * */

        // Indicate the next scene was loaded
        Singleton.Get <PoolingManager>().DestroyAll();

        // FIXME: Using load level for now.  Once above is fixed, take this line out
        Application.LoadLevel(level.SceneName);
    }