From c20e817af5cd0e297c2414adab6ffee46b88bb90 Mon Sep 17 00:00:00 2001 From: ILike2WatchMemes Date: Sat, 14 Sep 2024 09:04:56 +0200 Subject: Fix: Zombie Shootout QOL (#2507) Co-authored-by: CalMWolfs <94038482+CalMWolfs@users.noreply.github.com> Co-authored-by: hannibal2 <24389977+hannibal00212@users.noreply.github.com> --- .../config/features/event/carnival/ZombieShootoutConfig.java | 8 ++++---- .../features/event/carnival/CarnivalZombieShootout.kt | 11 +++++++---- 2 files changed, 11 insertions(+), 8 deletions(-) (limited to 'src/main/java') diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/carnival/ZombieShootoutConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/carnival/ZombieShootoutConfig.java index 5709e7e58..e65fc4c8a 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/features/event/carnival/ZombieShootoutConfig.java +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/carnival/ZombieShootoutConfig.java @@ -21,14 +21,14 @@ public class ZombieShootoutConfig { public boolean coloredHitboxes = true; @Expose - @ConfigOption(name = "Colored Lines", desc = "Display a colored line to lamps.") + @ConfigOption(name = "Highest Only", desc = "Only draw colored hitboxes for the highest scoring zombies.") @ConfigEditorBoolean - public boolean coloredLines = true; + public boolean highestOnly = false; @Expose - @ConfigOption(name = "Highest Only", desc = "Only draw colored hitboxes/lines for the highest scoring zombies.") + @ConfigOption(name = "Colored Line", desc = "Display a colored line to lamps.") @ConfigEditorBoolean - public boolean highestOnly = false; + public boolean coloredLines = true; @Expose @ConfigOption(name = "Lamp Timer", desc = "Show time until current lamp disappears.") diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/carnival/CarnivalZombieShootout.kt b/src/main/java/at/hannibal2/skyhanni/features/event/carnival/CarnivalZombieShootout.kt index cae5cbda1..d57903a57 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/event/carnival/CarnivalZombieShootout.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/event/carnival/CarnivalZombieShootout.kt @@ -61,9 +61,9 @@ object CarnivalZombieShootout { ) enum class ZombieType(val points: Int, val helmet: String, val color: Color) { - LEATHER(30, "Leather Cap", Color(165, 42, 42)), //Brown - IRON(50, "Iron Helmet", Color(192, 192, 192)), //Silver - GOLD(80, "Golden Helmet", Color(255, 215, 0)), //Gold + LEATHER(30, "Leather Cap", Color(165, 42, 42)), //Brown + IRON(50, "Iron Helmet", Color(192, 192, 192)), //Silver + GOLD(80, "Golden Helmet", Color(255, 215, 0)), //Gold DIAMOND(120, "Diamond Helmet", Color(185, 242, 255)) //Diamond } @@ -86,7 +86,10 @@ object CarnivalZombieShootout { zombie to type }.toMap() - drawZombies = nearbyZombies.filterValues { it == nearbyZombies.values.maxByOrNull { it.points } } + drawZombies = + if (config.highestOnly) nearbyZombies.filterValues { zombieType -> zombieType == nearbyZombies.values.maxByOrNull { it.points } } + else nearbyZombies + lastUpdate.zombie = SimpleTimeMark.now() } -- cgit