From 0480067cbb8602709671af55cc2ff5a7436eabce Mon Sep 17 00:00:00 2001 From: falsycat Date: Mon, 14 Oct 2019 00:00:00 +0000 Subject: [PATCH] [fix] Fixed timing of showing a description text of SelectScene. --- src/sj/SelectScene.d | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/src/sj/SelectScene.d b/src/sj/SelectScene.d index fafa1b4..5686f0d 100644 --- a/src/sj/SelectScene.d +++ b/src/sj/SelectScene.d @@ -90,10 +90,7 @@ class SelectScene : SceneInterface { } override void Draw() { lobby_.Draw(); - - const view = lobby_.view.Create(); - description_text_.Draw(lobby_.Projection, view); - title_text_ .Draw(lobby_.Projection, view); + status_.Draw(); } private: @@ -152,6 +149,9 @@ private abstract class AbstractSceneState { abstract UpdateResult Update(KeyInput input); + void Draw() { + } + @property SelectScene owner() { return owner_; } @@ -269,6 +269,11 @@ private class MusicAppearState : AbstractSceneState { } return CreateResult(this); } + override void Draw() { + const view = owner.lobby_.view.Create(); + owner.description_text_.Draw(owner.lobby_.Projection, view); + owner.title_text_ .Draw(owner.lobby_.Projection, view); + } private: MusicWaitState music_wait_state_; @@ -321,6 +326,11 @@ private class MusicWaitState : AbstractSceneState { return CreateResult(this); } + override void Draw() { + const view = owner.lobby_.view.Create(); + owner.description_text_.Draw(owner.lobby_.Projection, view); + owner.title_text_ .Draw(owner.lobby_.Projection, view); + } private: @property Music music() {