diff --git a/asteroids/View.cc b/asteroids/View.cc index c2cbc3a..046ff90 100644 --- a/asteroids/View.cc +++ b/asteroids/View.cc @@ -733,12 +733,6 @@ void View::DrawUiLevelComplete() { if(Engine::GUI::Button (1, "Next level ...", (screen_right - button_width) * 0.5, screen_bottom * 0.5 + 60, button_width, button_height)) { PopViewState(); - PushViewState(ViewStateLevelIntro); - Engine::StartTimer ("LevelIntroLevelNumber", 0.4); - Engine::StartTimer ("LevelIntroLevelTitle", 0.6); - Engine::StartTimer ("LevelIntroLevelAuthor", 0.8); - Engine::StartTimer ("LevelIntroLevelStart", 1.0); - // we have to take care when we are testing the level to not proceed to // the next level... if (GetViewState() == ViewStateEditor) { @@ -749,6 +743,12 @@ void View::DrawUiLevelComplete() { mEditorState = EditorStateUnknown; } } else { + PushViewState(ViewStateLevelIntro); + Engine::StartTimer ("LevelIntroLevelNumber", 0.4); + Engine::StartTimer ("LevelIntroLevelTitle", 0.6); + Engine::StartTimer ("LevelIntroLevelAuthor", 0.8); + Engine::StartTimer ("LevelIntroLevelStart", 1.0); + GetModel()->ProceedToNextLevel(); GetModel()->SetGameState(GameStatePaused); }