diff options
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni')
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/config/features/inventory/InventoryConfig.java | 3 | ||||
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/features/inventory/ItemDisplayOverlayFeatures.kt | 21 |
2 files changed, 21 insertions, 3 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/InventoryConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/InventoryConfig.java index 0c7556c30..e7609135e 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/InventoryConfig.java +++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/InventoryConfig.java @@ -146,9 +146,10 @@ public class InventoryConfig { BOTTLE_OF_JYRRE("§bBottle Of Jyrre", 15), DARK_CACAO_TRUFFLE("§bDark Cacao Truffle"), EDITION_NUMBER("§bEdition Number", 16), + ENCHANTING_EXP("§bEnchanting EXP (Superpairs)"), BINGO_GOAL_RANK("§bBingo Goal Rank"), SKYBLOCK_LEVEL("§bSkyblock Level"), - BESTIARY_LEVEL("§bBestiary Level") + BESTIARY_LEVEL("§bBestiary Level"), ; private final String str; diff --git a/src/main/java/at/hannibal2/skyhanni/features/inventory/ItemDisplayOverlayFeatures.kt b/src/main/java/at/hannibal2/skyhanni/features/inventory/ItemDisplayOverlayFeatures.kt index 2cb5632f1..43448f8d8 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/inventory/ItemDisplayOverlayFeatures.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/inventory/ItemDisplayOverlayFeatures.kt @@ -5,6 +5,7 @@ import at.hannibal2.skyhanni.api.CollectionAPI import at.hannibal2.skyhanni.api.SkillAPI import at.hannibal2.skyhanni.config.ConfigUpdaterMigrator import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry +import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.BESTIARY_LEVEL import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.BINGO_GOAL_RANK import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.BOTTLE_OF_JYRRE import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.COLLECTION_LEVEL @@ -12,6 +13,7 @@ import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumbe import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.DUNGEON_HEAD_FLOOR_NUMBER import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.DUNGEON_POTION_LEVEL import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.EDITION_NUMBER +import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.ENCHANTING_EXP import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.KUUDRA_KEY import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.LARVA_HOOK import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.MASTER_SKULL_TIER @@ -23,7 +25,6 @@ import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumbe import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.SKILL_LEVEL import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.SKYBLOCK_LEVEL import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.VACUUM_GARDEN -import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.BESTIARY_LEVEL import at.hannibal2.skyhanni.data.PetAPI import at.hannibal2.skyhanni.events.RenderItemTipEvent import at.hannibal2.skyhanni.features.garden.GardenAPI @@ -96,7 +97,16 @@ object ItemDisplayOverlayFeatures { ) private val bestiaryStackPattern by patternGroup.pattern( "bestiarystack", - "§7Progress to Tier (?<tier>[\\dIVXC]+): §b[\\d.]+%" + "§7Progress to Tier (?<tier>[\\dIVXC]+): §b[\\d.]+%", + ) + + /** + * REGEX-TEST: 5k Enchanting Exp + * REGEX-TEST: 5.5k Enchanting Exp + */ + private val enchantingExpPattern by patternGroup.pattern( + "enchantingexp", + "(?<exp>.*)k Enchanting Exp", ) @SubscribeEvent @@ -299,6 +309,13 @@ object ItemDisplayOverlayFeatures { } } + if (ENCHANTING_EXP.isSelected() && chestName.startsWith("Superpairs")) { + enchantingExpPattern.matchMatcher(item.cleanName()) { + val exp = group("exp").formatLong() + return "§b${exp.shortFormat()}" + } + } + return null } |