コード例 #1
0
ファイル: RuntimeManager.cs プロジェクト: Eelazar/AGJ19
        /* iOS alarm interruptions do not trigger OnApplicationPause
         * Sending the app to the background does trigger OnApplicationFocus
         * We don't want to use this on Android as other things (like the keyboard)
         * can steal focus.
         * https://docs.unity3d.com/ScriptReference/MonoBehaviour.OnApplicationFocus.html */

        void OnApplicationFocus(bool focus)
        {
            if (studioSystem.isValid())
            {
                // Strings bank is always loaded
                if (loadedBanks.Count > 1)
                {
                    PauseAllEvents(!focus);
                }

                if (focus)
                {
                    lowlevelSystem.mixerResume();
                }
                else
                {
                    lowlevelSystem.mixerSuspend();
                }
            }
        }
コード例 #2
0
 void OnApplicationPause(bool pauseStatus)
 {
     if (studioSystem != null && studioSystem.isValid())
     {
         if (pauseStatus)
         {
             lowlevelSystem.mixerSuspend();
         }
         else
         {
             lowlevelSystem.mixerResume();
         }
     }
 }
コード例 #3
0
        void OnApplicationPause(bool pauseStatus)
        {
            if (studioSystem.isValid())
            {
                PauseAllEvents(pauseStatus);

                if (pauseStatus)
                {
                    coreSystem.mixerSuspend();
                }
                else
                {
                    coreSystem.mixerResume();
                }
            }
        }