Skip to content

Commit ee4eea1

Browse files
committed
feat: "Show only when Scorpius is mayor" FeatureSetting for Dark Auction Timer
1 parent 5999264 commit ee4eea1

File tree

4 files changed

+9
-2
lines changed

4 files changed

+9
-2
lines changed

src/main/java/com/fix3dll/skyblockaddons/core/feature/FeatureSetting.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,7 @@ public enum FeatureSetting {
138138
PRESSURE_TEXT_ICON("settings.pressureText.icon", Feature.PRESSURE_TEXT),
139139
PET_PANEL("settings.equipmentsInInventory.petPanel", Feature.EQUIPMENTS_IN_INVENTORY),
140140
BIGGER_WAKE("settings.coloredFishingParticles.biggerWake", Feature.COLORED_FISHING_PARTICLES),
141+
SHOW_ONLY_WHEN_SCORPIUS_IS_MAYOR("settings.showOnlyWhenScorpiusIsMayor", Feature.DARK_AUCTION_TIMER),
141142

142143

143144
DISCORD_RP_DETAILS("messages.firstStatus", Feature.DISCORD_RPC),

src/main/java/com/fix3dll/skyblockaddons/listeners/RenderListener.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -856,6 +856,10 @@ public void drawText(GuiGraphics graphics, Feature feature, float scale, ButtonL
856856
}
857857
}
858858
case DARK_AUCTION_TIMER -> {
859+
if (Feature.DARK_AUCTION_TIMER.isEnabled(FeatureSetting.SHOW_ONLY_WHEN_SCORPIUS_IS_MAYOR)
860+
&& !"Scorpius".equals(main.getUtils().getMayor())) {
861+
return;
862+
}
859863
// The timezone of the server, to avoid problems with like timezones that are 30 minutes ahead or whatnot.
860864
ZonedDateTime nowDA = SkyblockAddons.getHypixelZonedDateTime();
861865
ZonedDateTime nextDarkAuction = nowDA.withMinute(55).withSecond(0);

src/main/resources/defaults.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,8 @@
160160
],
161161
"color": -22016,
162162
"settings": {
163-
"DARK_AUCTION_TIMER_IN_OTHER_GAMES": true
163+
"DARK_AUCTION_TIMER_IN_OTHER_GAMES": true,
164+
"SHOW_ONLY_WHEN_SCORPIUS_IS_MAYOR": false
164165
}
165166
},
166167
"ITEM_PICKUP_LOG": {

src/main/resources/lang/en_US.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,8 @@
290290
"coloredFishingParticles": {
291291
"title": "Custom Colored Fishing Particles",
292292
"biggerWake": "Enlarge Wake Particles"
293-
}
293+
},
294+
"showOnlyWhenScorpiusIsMayor": "Show only when Scorpius is mayor"
294295
},
295296
"messages": {
296297
"enchants": "Enchants",

0 commit comments

Comments
 (0)