Exemplo n.º 1
0
    private void EndGame()
    {
        //Calculate score
        ScoreManager.instance.score = score;

        //Go to score screen
        gameOver = true;
        //SceneManager.LoadScene("GameOver");
        SimpleSceneFader.ChangeSceneWithFade("GameOver", 1f);
        SoundManager.instance.musicSource.Stop();
    }
Exemplo n.º 2
0
    public void MoveToNextFrame()
    {
        frameIndex++;

        pageTurnSource.Play();

        if (frameIndex >= cinemachineVirtualCameras.Length)
        {
            SimpleSceneFader.ChangeSceneWithFade("Main", 1f);
            return;
            //SceneManager.LoadScene("Main");
            //frameIndex = 0;
        }

        previousPriority *= 2;
        cinemachineVirtualCameras[frameIndex].Priority = previousPriority;
    }
Exemplo n.º 3
0
 public void RestartGame()
 {
     //SceneManager.LoadScene("Main");
     SoundManager.instance.musicSource.Stop();
     SimpleSceneFader.ChangeSceneWithFade("Main", 1f);
 }
Exemplo n.º 4
0
 public void SceneTransition()
 {
     SimpleSceneFader.ChangeSceneWithFade("Main Menu");
 }
Exemplo n.º 5
0
 public void LoadSceneWithFade(string sceneName)
 {
     SimpleSceneFader.ChangeSceneWithFade(sceneName);
 }
 public void GoToGame()
 {
     SimpleSceneFader.ChangeSceneWithFade("Game");
 }
Exemplo n.º 7
0
    // STEPS

    // 1) Drag prefab named "SSF" from the prefab folder in your FIRST scene.
    // 2) Open tag manager & add "SceneFader" as a new tag
    // 3) Use the code given below to load your scene.
    // 4) Make sure that scene you are loading is added in your build settings.

    public void OpenScene2Button()
    {
        SimpleSceneFader.ChangeSceneWithFade("Scene 2");
    }
 public void ChangeScene()
 {
     SimpleSceneFader.ChangeSceneWithFade("mixcharwithforest");
 }