From d2cdb6574ec2a9f66d0cca146a199f3f091cf340 Mon Sep 17 00:00:00 2001 From: syeyoung Date: Tue, 13 Apr 2021 00:27:55 +0900 Subject: new feature --- .../dungeon/doorfinder/DungeonSpecificDataProviderRegistry.java | 4 ++-- .../features/impl/etc/ability/FeatureAbilityCooldown.java | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) (limited to 'src/main') diff --git a/src/main/java/kr/syeyoung/dungeonsguide/dungeon/doorfinder/DungeonSpecificDataProviderRegistry.java b/src/main/java/kr/syeyoung/dungeonsguide/dungeon/doorfinder/DungeonSpecificDataProviderRegistry.java index 9695c06e..5d8e78b4 100755 --- a/src/main/java/kr/syeyoung/dungeonsguide/dungeon/doorfinder/DungeonSpecificDataProviderRegistry.java +++ b/src/main/java/kr/syeyoung/dungeonsguide/dungeon/doorfinder/DungeonSpecificDataProviderRegistry.java @@ -8,8 +8,8 @@ public class DungeonSpecificDataProviderRegistry { private static final Map doorFinders = new HashMap(); static { - doorFinders.put(Pattern.compile("The Catacombs (?:F[0-9]|E)"), new CatacombDataProvider()); - doorFinders.put(Pattern.compile("The Catacombs (?:M[0-9]|E)"), new CatacombMasterDataProvider()); + doorFinders.put(Pattern.compile("The Catacombs (?:F[0-9]|E0)"), new CatacombDataProvider()); + doorFinders.put(Pattern.compile("The Catacombs (?:M[0-9])"), new CatacombMasterDataProvider()); } public static DungeonSpecificDataProvider getDoorFinder(String dungeonName) { diff --git a/src/main/java/kr/syeyoung/dungeonsguide/features/impl/etc/ability/FeatureAbilityCooldown.java b/src/main/java/kr/syeyoung/dungeonsguide/features/impl/etc/ability/FeatureAbilityCooldown.java index a2208844..469290e4 100644 --- a/src/main/java/kr/syeyoung/dungeonsguide/features/impl/etc/ability/FeatureAbilityCooldown.java +++ b/src/main/java/kr/syeyoung/dungeonsguide/features/impl/etc/ability/FeatureAbilityCooldown.java @@ -3,6 +3,7 @@ package kr.syeyoung.dungeonsguide.features.impl.etc.ability; import kr.syeyoung.dungeonsguide.SkyblockStatus; import kr.syeyoung.dungeonsguide.config.types.AColor; import kr.syeyoung.dungeonsguide.e; +import kr.syeyoung.dungeonsguide.features.FeatureParameter; import kr.syeyoung.dungeonsguide.features.listener.ChatListener; import kr.syeyoung.dungeonsguide.features.listener.TickListener; import kr.syeyoung.dungeonsguide.features.text.StyledText; @@ -30,11 +31,12 @@ public class FeatureAbilityCooldown extends TextHUDFeature implements ChatListen getStyles().add(new TextStyle("number", new AColor(0x55, 0xFF,0xFF,255), new AColor(0, 0,0,0), false)); getStyles().add(new TextStyle("unit",new AColor(0x00, 0xAA,0xAA,255), new AColor(0, 0,0,0), false)); getStyles().add(new TextStyle("ready",new AColor(0xDF, 0x00,0x67,255), new AColor(0, 0,0,0), false)); + this.parameters.put("disable", new FeatureParameter("disable", "Disable outside of dungeon", "Disable the feature when out of dungeon", false, "boolean")); } @Override public boolean isHUDViewable() { - return skyblockStatus.isOnSkyblock(); + return skyblockStatus.isOnSkyblock() && (!this.getParameter("disable").getValue() || (this.getParameter("disable").getValue() && skyblockStatus.isOnDungeon())); } @Override -- cgit