feat: add pauzing of the running game
This commit is contained in:
@@ -304,6 +304,14 @@ namespace {
|
||||
check(counter->updates == 1 && counter->fixedUpdates == 1 && counter->lateUpdates == 1,
|
||||
"play mode must tick components");
|
||||
|
||||
sceneManager.SetPaused(true);
|
||||
sceneManager.Update(0.1f);
|
||||
sceneManager.FixedUpdate(0.1f);
|
||||
sceneManager.LateUpdate(0.1f);
|
||||
sceneManager.SetPaused(false);
|
||||
check(counter->updates == 1 && counter->fixedUpdates == 1 && counter->lateUpdates == 1,
|
||||
"a paused game must not tick components");
|
||||
|
||||
sceneManager.Destroy();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user