aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2
diff options
context:
space:
mode:
authorhannibal2 <24389977+hannibal00212@users.noreply.github.com>2023-02-07 22:47:47 +0100
committerhannibal2 <24389977+hannibal00212@users.noreply.github.com>2023-02-07 22:47:47 +0100
commitd1c02e2c71a81057c5ad0975e754c419728d9ebc (patch)
tree9799331c37a5f2355c6c7be5b556245f71a9494a /src/main/java/at/hannibal2
parent48de5556d823f4bd0bf47f5e247c3a7d3f8c1a58 (diff)
downloadskyhanni-d1c02e2c71a81057c5ad0975e754c419728d9ebc.tar.gz
skyhanni-d1c02e2c71a81057c5ad0975e754c419728d9ebc.tar.bz2
skyhanni-d1c02e2c71a81057c5ad0975e754c419728d9ebc.zip
Fixed Bingo display rules.
Diffstat (limited to 'src/main/java/at/hannibal2')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/config/features/Bingo.java3
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/bingo/BingoCardDisplay.kt18
2 files changed, 10 insertions, 11 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/Bingo.java b/src/main/java/at/hannibal2/skyhanni/config/features/Bingo.java
index 3395dfb8e..5701be9a1 100644
--- a/src/main/java/at/hannibal2/skyhanni/config/features/Bingo.java
+++ b/src/main/java/at/hannibal2/skyhanni/config/features/Bingo.java
@@ -1,7 +1,6 @@
package at.hannibal2.skyhanni.config.features;
import at.hannibal2.skyhanni.config.core.config.Position;
-import at.hannibal2.skyhanni.config.core.config.annotations.ConfigAccordionId;
import at.hannibal2.skyhanni.config.core.config.annotations.ConfigEditorBoolean;
import at.hannibal2.skyhanni.config.core.config.annotations.ConfigEditorButton;
import at.hannibal2.skyhanni.config.core.config.annotations.ConfigOption;
@@ -18,12 +17,10 @@ public class Bingo {
@Expose
@ConfigOption(name = "Bingo Card", desc = "Show the bingo card.")
@ConfigEditorBoolean
- @ConfigAccordionId(id = 0)
public boolean bingoCard = false;
@Expose
@ConfigOption(name = "Bingo Card Position", desc = "")
@ConfigEditorButton(runnableId = "bingoCardPos", buttonText = "Edit")
- @ConfigAccordionId(id = 0)
public Position bingoCardPos = new Position(10, 10, false, true);
}
diff --git a/src/main/java/at/hannibal2/skyhanni/features/bingo/BingoCardDisplay.kt b/src/main/java/at/hannibal2/skyhanni/features/bingo/BingoCardDisplay.kt
index ad1e138a8..2666cab01 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/bingo/BingoCardDisplay.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/bingo/BingoCardDisplay.kt
@@ -127,7 +127,7 @@ class BingoCardDisplay {
}
private var lastSneak = false
- private var showHelp = false
+ private var displayMode = 0
@SubscribeEvent
fun onRenderOverlay(event: RenderGameOverlayEvent.Post) {
@@ -141,16 +141,19 @@ class BingoCardDisplay {
if (lastSneak != sneaking) {
lastSneak = sneaking
if (sneaking) {
- showHelp = !showHelp
+ displayMode++
+ if (displayMode == 3) {
+ displayMode = 0
+ }
}
}
}
- if (showHelp) {
- SkyHanniMod.feature.bingo.bingoCardPos.renderStrings(BingoNextStepHelper.currentHelp)
- } else {
+ if (displayMode == 0) {
if (Minecraft.getMinecraft().currentScreen !is GuiChat) {
- SkyHanniMod.feature.dev.debugPos.renderStrings(display)
+ SkyHanniMod.feature.bingo.bingoCardPos.renderStrings(display)
}
+ } else if (displayMode == 1) {
+ SkyHanniMod.feature.bingo.bingoCardPos.renderStrings(BingoNextStepHelper.currentHelp)
}
}
@@ -170,8 +173,7 @@ class BingoCardDisplay {
for (goal in personalGoals) {
println("goal: '" + goal.displayName + "'")
}
- personalGoals
- .filter { it.displayName == name }
+ personalGoals.filter { it.displayName == name }
.forEach {
it.done = true
update()