diff options
| author | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-11-30 12:09:30 +0100 |
|---|---|---|
| committer | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-11-30 12:09:30 +0100 |
| commit | 3c63e64faba2664ff1f75a6ef5156e2b7303ddba (patch) | |
| tree | 6dac35c7a8dc7fd46dfba00bd0e6011ef78d8909 /src/main/java/at/hannibal2/skyhanni/data | |
| parent | d17941f261b027f325615dc985b498380f1450c1 (diff) | |
| download | skyhanni-3c63e64faba2664ff1f75a6ef5156e2b7303ddba.tar.gz skyhanni-3c63e64faba2664ff1f75a6ef5156e2b7303ddba.tar.bz2 skyhanni-3c63e64faba2664ff1f75a6ef5156e2b7303ddba.zip | |
romanToDecimalIfNeeded -> romanToDecimalIfNecessary (See https://chat.openai.com/share/502571b5-8851-4047-b343-3b1475ca8a88)
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/data')
| -rw-r--r-- | src/main/java/at/hannibal2/skyhanni/data/GardenComposterUpgradesData.kt | 4 | ||||
| -rw-r--r-- | src/main/java/at/hannibal2/skyhanni/data/GardenCropMilestonesCommunityFix.kt | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/data/GardenComposterUpgradesData.kt b/src/main/java/at/hannibal2/skyhanni/data/GardenComposterUpgradesData.kt index 6b6d343aa..138158ccb 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/GardenComposterUpgradesData.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/GardenComposterUpgradesData.kt @@ -5,7 +5,7 @@ import at.hannibal2.skyhanni.events.InventoryFullyOpenedEvent import at.hannibal2.skyhanni.features.garden.GardenAPI import at.hannibal2.skyhanni.features.garden.composter.ComposterAPI import at.hannibal2.skyhanni.utils.ItemUtils.name -import at.hannibal2.skyhanni.utils.NumberUtil.romanToDecimalIfNeeded +import at.hannibal2.skyhanni.utils.NumberUtil.romanToDecimalIfNecessary import at.hannibal2.skyhanni.utils.StringUtils.matchMatcher import net.minecraftforge.fml.common.eventhandler.SubscribeEvent @@ -19,7 +19,7 @@ class GardenComposterUpgradesData { val itemName = item.name ?: continue ComposterUpgrade.regex.matchMatcher(itemName) { val name = group("name") - val level = group("level")?.romanToDecimalIfNeeded() ?: 0 + val level = group("level")?.romanToDecimalIfNecessary() ?: 0 val composterUpgrade = ComposterUpgrade.getByName(name)!! ComposterAPI.composterUpgrades?.put(composterUpgrade, level) } diff --git a/src/main/java/at/hannibal2/skyhanni/data/GardenCropMilestonesCommunityFix.kt b/src/main/java/at/hannibal2/skyhanni/data/GardenCropMilestonesCommunityFix.kt index 9a0864050..71398af27 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/GardenCropMilestonesCommunityFix.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/GardenCropMilestonesCommunityFix.kt @@ -13,7 +13,7 @@ import at.hannibal2.skyhanni.utils.LorenzUtils.editCopy import at.hannibal2.skyhanni.utils.LorenzUtils.nextAfter import at.hannibal2.skyhanni.utils.NumberUtil.addSeparators import at.hannibal2.skyhanni.utils.NumberUtil.formatNumber -import at.hannibal2.skyhanni.utils.NumberUtil.romanToDecimalIfNeeded +import at.hannibal2.skyhanni.utils.NumberUtil.romanToDecimalIfNecessary import at.hannibal2.skyhanni.utils.OSUtils import at.hannibal2.skyhanni.utils.StringUtils.matchMatcher import at.hannibal2.skyhanni.utils.StringUtils.matches @@ -75,7 +75,7 @@ object GardenCropMilestonesCommunityFix { ) { val name = stack.name ?: return val rawNumber = name.removeColor().replace(crop.cropName, "").trim() - val realTier = if (rawNumber == "") 0 else rawNumber.romanToDecimalIfNeeded() + val realTier = if (rawNumber == "") 0 else rawNumber.romanToDecimalIfNecessary() val lore = stack.getLore() val next = lore.nextAfter({ GardenCropMilestones.totalPattern.matches(it) }, 3) ?: return |
