From d99c4cb609bc9ca7c627701b0b3f551df03db66f Mon Sep 17 00:00:00 2001 From: trivernis Date: Sun, 20 Nov 2022 13:32:56 +0100 Subject: [PATCH] Fix win prompt --- core/src/main/kotlin/com/last/commit/screen/FirstScreen.kt | 7 +++++-- core/src/main/kotlin/com/last/commit/stages/PromptStage.kt | 1 + 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/core/src/main/kotlin/com/last/commit/screen/FirstScreen.kt b/core/src/main/kotlin/com/last/commit/screen/FirstScreen.kt index fd72b07..c0cb359 100644 --- a/core/src/main/kotlin/com/last/commit/screen/FirstScreen.kt +++ b/core/src/main/kotlin/com/last/commit/screen/FirstScreen.kt @@ -78,9 +78,12 @@ class FirstScreen(private val parent: Game) : TimeTravelScreen() { """.trimIndent()) promptStage.addText(""" You can use , , and to walk around the map. - Some doors require keys to be opened. """.trimIndent()) promptStage.addText(""" + Doors can be opened and items picked up with . + Some doors require keys to be opened. + """) + promptStage.addText(""" At some locations you can press to travel to a random spot in time. The top left indicates where you traveled to. """.trimIndent()) @@ -147,9 +150,9 @@ class FirstScreen(private val parent: Game) : TimeTravelScreen() { override fun render(delta: Float) { if (gameState.inventory.checkVictoryCondition()) { promptStage.visible = true - promptStage.act(delta) promptStage.clearText() promptStage.addText("You won!") + promptStage.act(delta) promptStage.draw() } else if (!pause) { uiStage.act(delta) diff --git a/core/src/main/kotlin/com/last/commit/stages/PromptStage.kt b/core/src/main/kotlin/com/last/commit/stages/PromptStage.kt index 8f0f2d3..1cc2171 100644 --- a/core/src/main/kotlin/com/last/commit/stages/PromptStage.kt +++ b/core/src/main/kotlin/com/last/commit/stages/PromptStage.kt @@ -70,6 +70,7 @@ class PromptStage(skin: Skin?): Stage(ExtendViewport(300f, 300f)) { val text = text.removeAt(0).trimIndent() textArea.text = text } else { + textArea.text = "" visible = false } }