Exemplo n.º 1
0
 // Use this for initialization
 void Start()
 {
     Debug.Log(main);
     main = true;
     Application.targetFrameRate = 60;
     PenghargaanContainer.load();
     PenghargaanController.load();
     AudioController.Load();
     acc = AccountContainer.load().accounts;
     if (!AudioController.getInstance().containKey("MainMenu"))
     {
         AudioSource audio = AudioController.getInstance().registerSound("Audio/Intro insyaAllah fix", "MainMenu");
         DontDestroyOnLoad(audio);
         audio.loop = true;
         audio.Play();
     }
     else
     {
         AudioSource audio = AudioController.getInstance().getAudioSource("MainMenu");
         audio.UnPause();
     }
     restartOption();
     SaveGameUI.SetActive(false);
     Scene.moveOut();
 }
Exemplo n.º 2
0
    // Use this for initialization
    void Start()
    {
        Time.timeScale = 1;
        self.moveOut();
        AudioSource main = AudioController.getInstance().getAudioSource("MainMenu");

        if (main != null)
        {
            if (!main.isPlaying)
            {
                main.Play();
            }
        }
        else
        {
            AudioSource audio = AudioController.getInstance().registerSound("Audio/Intro insyaAllah fix", "MainMenu");
            DontDestroyOnLoad(audio);
            audio.loop = true;
            audio.Play();
        }
    }