Minor bug fix

set animation dt back to default when retry or quit
This commit is contained in:
Glence 2023-03-11 21:25:56 +08:00
parent 0be385c6bd
commit d0067b09c9
1 changed files with 4 additions and 0 deletions

View File

@ -70,6 +70,8 @@ public class PauseMenu : Script
GameManager.Instance.GamePause = false;
GameManager.Instance.stealFoodPopUpDone = false;
GameManager.Instance.PreviewLevelDone = false;
Application.FixDeltaTime = Time.DefaultFixDeltaTime;
AnimationSystem.TimeScale = AnimationSystem.DefaultTimeScale;
});
}
else
@ -83,6 +85,8 @@ public class PauseMenu : Script
quit.OnRelease.RegisterAction(() =>
{
Audio.StopAllSounds();
Application.FixDeltaTime = Time.DefaultFixDeltaTime;
AnimationSystem.TimeScale = AnimationSystem.DefaultTimeScale;
//go to main menu
SceneManager.ChangeScene(97158628);
});