Beispiel #1
0
 public void ContinueGame()
 {
     mIsPaused = false;
     //Event aufrufen
     OnPauseChange.Invoke(mIsPaused);
     mPausePanel.SetActive(mIsPaused);
 }
        public async Task OnPauseEventHandler(string currentSrc)
        {
            PlayerState.CurrentSrc = new Uri(currentSrc);
            PlayerState.PlayState  = BulMediaPlayState.Paused;
            await OnPauseChange.InvokeAsync(PlayerState);

            StateHasChanged();
        }
Beispiel #3
0
 void Update()
 {
     if (Input.GetKeyDown(KeyCode.Escape))
     {
         mIsPaused = !mIsPaused;
         //Event aufrufen
         OnPauseChange.Invoke(mIsPaused);
         mPausePanel.SetActive(mIsPaused);
     }
 }
Beispiel #4
0
        private void Update()
        {
            if (Current.Game == null)
            {
                return;
            }

            bool currentPaused = Find.TickManager?.Paused ?? false;

            if (lastPaused != currentPaused)
            {
                OnPauseChange?.Invoke(currentPaused);
                lastPaused = currentPaused;
            }
        }
Beispiel #5
0
        private void Update()
        {
            if (Current.Game != null)
            {
                bool currentPaused = Find.TickManager?.Paused ?? false;
                if (lastPaused != currentPaused)
                {
                    OnPauseChange?.Invoke(currentPaused);
                    lastPaused = currentPaused;
                }
            }

            bool removeAll = Current.ProgramState != ProgramState.Playing;

            AudioSourceManager.Tick(removeAll);
        }