aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CHANGELOG.md84
-rw-r--r--FEATURES.md35
-rw-r--r--README.md50
-rw-r--r--gradle.properties4
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/dwarven/DwarvenHud.java5
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/fancybars/StatusBarsConfigScreen.java2
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/garden/FarmingHud.java5
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/garden/FarmingHudWidget.java5
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/slottext/SlotTextManager.java6
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/AttributeShardAdder.java4
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/CatacombsLevelAdder.java6
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/CollectionAdder.java3
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/EnchantmentLevelAdder.java4
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/EssenceShopAdder.java51
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/MinionLevelAdder.java2
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PetLevelAdder.java3
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PotionLevelAdder.java13
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PowerStonesGuideAdder.java38
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PrehistoricEggAdder.java2
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/RancherBootsSpeedAdder.java2
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/SkillLevelAdder.java2
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/SkyblockLevelAdder.java6
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/StatsTuningAdder.java42
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/YourEssenceAdder.java46
-rw-r--r--src/main/java/de/hysky/skyblocker/skyblock/item/tooltip/TooltipInfoType.java11
-rw-r--r--src/main/resources/fabric.mod.json2
26 files changed, 395 insertions, 38 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 55d92e6e..8b7abf98 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,87 @@
+# Release 1.21.0
+
+## Highlight
+* Chocolate factory helper
+* Calendar Event Notifications
+* Glacite Tunnels Cold Overlay
+* Add onscreen info for specific items and menus like pet level (slot text)
+* Config reordering
+* Waypoints for commissions in dwarven mines and glacite
+* Sign calculator
+* Block Incorrect Terminal Clicks
+* Hide Soulweaver Skulls
+* Compact damage
+* 2 Extra Tabs in Quick Nav
+* Vanilla health/xp and fancy bar shown in parallel now possible
+* Highlight chest in three weirdos
+* Visitor helper copy amount to clipboard
+* Search overlay improvement (better pet search, dungeon stars)
+* Farming hud improvement (coins per hour)
+* Waypoints UI config
+
+## What's Changed
+* Fixes and things by @viciscat in https://github.com/SkyblockerMod/Skyblocker/pull/675
+* Fixes to Garden UI by @BigloBot in https://github.com/SkyblockerMod/Skyblocker/pull/682
+* 1.20.5 & 1.20.6 by @AzureAaron in https://github.com/SkyblockerMod/Skyblocker/pull/669
+* Ultimate config reconfiguration by @LifeIsAParadox in https://github.com/SkyblockerMod/Skyblocker/pull/697
+* Nothing to see here, part 2 by @kevinthegreat1 in https://github.com/SkyblockerMod/Skyblocker/pull/698
+* ??? by @AzureAaron in https://github.com/SkyblockerMod/Skyblocker/pull/699
+* Add a way to show all ordered waypoints at once by @AzureAaron in https://github.com/SkyblockerMod/Skyblocker/pull/688
+* Adds Mines Slayer starter commission and deprecates the classic hud for removal by @AzureAaron in https://github.com/SkyblockerMod/Skyblocker/pull/692
+* Fix accessories helper not working with only 1 accessory bag page by @AzureAaron in https://github.com/SkyblockerMod/Skyblocker/pull/693
+* Config Data Fixer by @AzureAaron in https://github.com/SkyblockerMod/Skyblocker/pull/701
+* Fix quite important AH bug by @viciscat in https://github.com/SkyblockerMod/Skyblocker/pull/689
+* add waypoints for commissions in dwarven mines and glacite. by @olim88 in https://github.com/SkyblockerMod/Skyblocker/pull/690
+* Add line smoothener by @Emirlol in https://github.com/SkyblockerMod/Skyblocker/pull/711
+* Sign calculator by @olim88 in https://github.com/SkyblockerMod/Skyblocker/pull/686
+* Block Incorrect Terminal Clicks by @AzureAaron in https://github.com/SkyblockerMod/Skyblocker/pull/710
+* Hide Soulweaver Skulls by @AzureAaron in https://github.com/SkyblockerMod/Skyblocker/pull/702
+* Add compact damage by @Emirlol in https://github.com/SkyblockerMod/Skyblocker/pull/696
+* Clarify the regex in CompactDamage by @Emirlol in https://github.com/SkyblockerMod/Skyblocker/pull/712
+* Internal Staging by @AzureAaron in https://github.com/SkyblockerMod/Skyblocker/pull/715
+* Add LOCATION_CHANGE event, fired upon parsing /locraw by @Emirlol in https://github.com/SkyblockerMod/Skyblocker/pull/716
+* Quick Nav Refactor and Clean Up, 2 Extra Tabs, Config Version 3, Config Data Fixer Refactor, Debug Dump Hovered Item Tool by @VeritasDL in https://github.com/SkyblockerMod/Skyblocker/pull/643
+* Fancy status bars bits and pieces by @viciscat in https://github.com/SkyblockerMod/Skyblocker/pull/704
+* Migrate ThreeWeirdos to DungeonPuzzle and highlight chest by @kevinthegreat1 in https://github.com/SkyblockerMod/Skyblocker/pull/705
+* fix bugs by @olim88 in https://github.com/SkyblockerMod/Skyblocker/pull/720
+* Make TerminalSolver interface & ExperimentSolver class sealed by @AzureAaron in https://github.com/SkyblockerMod/Skyblocker/pull/722
+* Add chocolate factory helper by @Emirlol in https://github.com/SkyblockerMod/Skyblocker/pull/683
+* Glacite Overlay (Oops) by @f3shqt in https://github.com/SkyblockerMod/Skyblocker/pull/703
+* chat rules - fix bugs + refactor by @olim88 in https://github.com/SkyblockerMod/Skyblocker/pull/719
+* Remove extended quicknav string by @AzureAaron in https://github.com/SkyblockerMod/Skyblocker/pull/725
+* Debug class? More like Rebug class lmao gottem by @viciscat in https://github.com/SkyblockerMod/Skyblocker/pull/730
+* Update chocolate factory for chocolate factory 2 by @Emirlol in https://github.com/SkyblockerMod/Skyblocker/pull/734
+* Fix egg found message being sent twice by @Emirlol in https://github.com/SkyblockerMod/Skyblocker/pull/729
+* Fix off-by-one on cf by @Emirlol in https://github.com/SkyblockerMod/Skyblocker/pull/741
+* Fix entrance (0) not being in the map by @Julienraptor01 in https://github.com/SkyblockerMod/Skyblocker/pull/732
+* VisitorHelper Tweak by @UpFault in https://github.com/SkyblockerMod/Skyblocker/pull/736
+* Improve search overlay by @olim88 in https://github.com/SkyblockerMod/Skyblocker/pull/739
+* Calendar Event Notifications by @viciscat in https://github.com/SkyblockerMod/Skyblocker/pull/691
+* add locations to egg hunt by @BigloBot in https://github.com/SkyblockerMod/Skyblocker/pull/746
+* Farming hud improvements by @kevinthegreat1 in https://github.com/SkyblockerMod/Skyblocker/pull/685
+* Tooltip refactors by @Emirlol in https://github.com/SkyblockerMod/Skyblocker/pull/735
+* Misc Changes by @kevinthegreat1 in https://github.com/SkyblockerMod/Skyblocker/pull/755
+* Refactor Tooltips and Slot Texts by @kevinthegreat1 in https://github.com/SkyblockerMod/Skyblocker/pull/750
+* Update jar name and add build type by @kevinthegreat1 in https://github.com/SkyblockerMod/Skyblocker/pull/757
+* Fix CatacombsLevelAdder not working at max class levels by @Emirlol in https://github.com/SkyblockerMod/Skyblocker/pull/756
+* A couple of chocolate factory fixes by @Emirlol in https://github.com/SkyblockerMod/Skyblocker/pull/749
+* Waypoints by @kevinthegreat1 in https://github.com/SkyblockerMod/Skyblocker/pull/713
+* Add event notifications criterion by @kevinthegreat1 in https://github.com/SkyblockerMod/Skyblocker/pull/763
+* Fix egg finder sharing nonsense by @Julienraptor01 in https://github.com/SkyblockerMod/Skyblocker/pull/771
+* Switch metal detector regex from matches to find by @kevinthegreat1 in https://github.com/SkyblockerMod/Skyblocker/pull/767
+* Add docs to ItemTooltip#getNeuName and ItemRepository#getItemStack and fix farming hud icon stack id by @kevinthegreat1 in https://github.com/SkyblockerMod/Skyblocker/pull/772
+* Switch colour check for exotic tooltip by @kevinthegreat1 in https://github.com/SkyblockerMod/Skyblocker/pull/773
+* YetAnotherChocoFactoFix by @Emirlol in https://github.com/SkyblockerMod/Skyblocker/pull/774
+* Use NPC price if its higher by @AzureAaron in https://github.com/SkyblockerMod/Skyblocker/pull/775
+* Fix Search Overlay NPE by @AzureAaron in https://github.com/SkyblockerMod/Skyblocker/pull/778
+
+## New Contributors
+* @BigloBot made their first contribution in https://github.com/SkyblockerMod/Skyblocker/pull/682
+* @f3shqt made their first contribution in https://github.com/SkyblockerMod/Skyblocker/pull/703
+* @UpFault made their first contribution in https://github.com/SkyblockerMod/Skyblocker/pull/736
+
+**Full Changelog**: https://github.com/SkyblockerMod/Skyblocker/compare/v1.20.2...v1.21.0
+___
# Release 1.20.2
## Highlight
diff --git a/FEATURES.md b/FEATURES.md
index ff0f0bb6..b4214eec 100644
--- a/FEATURES.md
+++ b/FEATURES.md
@@ -32,6 +32,8 @@
- **Resourcepack recoloring textures in dungeons**
- **score title and sound**
- **Prevent teammates glow during Livid**
+- **Block Incorrect Terminal Clicks**
+- **Hide Soulweaver Skulls**
### Kuudra Features
- **Kuudra waypoints**
@@ -55,6 +57,7 @@
- *Mana*
- *Defense*
- *XP*
+- **Vanilla health/xp and fancy bar shown in parallel**
### Dwarven Mines / Crystal Hollows / Glacite Mining:
- **Dwarven Mines Solver:**
@@ -69,6 +72,8 @@
- *Find locations in chat messages*
- *Share waypoints*
- Metal detector helper
+- **Glacite Tunnels**
+ - **Cold Overlay**
- **Commission HUD**
- *Provides information on Dwarven Mines / Crystal Hollows / Glacite Mining quests*
- **Powder HUD**
@@ -95,12 +100,22 @@
### Garden Features:
- **Farming HUD**
+ - Counter
+ - Crops/min
+ - Coins/h
+ - Blocks/s
+ - Farming Level
+ - Farming XP/h
+ - Yaw and Pitch
- **Visitor Helper**
- Buy items that visitors require from bazaar by clicking the text
+ - Copy amount to clipboard
- **Disable title and chat messages for Melon/Pumpkin Dicer**
- **Basic garden mouse locking feature (set mouse sensitivity to 0)**
### Visual Enhancements:
+- **Compact damage**
+- **Waypoints for commissions in dwarven mines and glacite tunnels**
- **Fancy Tab HUD:** Fully configurable with a resource pack.
- **1.8 Hitbox for Lever and Farmland**
- **Hide Status Effect Overlay**
@@ -122,7 +137,22 @@
### User Interface Enhancements:
- **Search overlays for bz and ah**
-- **Attribute Shard Info Display**
+- **Slot Text**
+ - **Attribute Shard Info Display**
+ - **Catacombs level**
+ - **Collection level**
+ - **Enchantment book level**
+ - **Minion level**
+ - **Pet level**
+ - **Potion level**
+ - **Prehistoric egg blocks walked**
+ - **Rancher's boots speed cap**
+ - **Skill level**
+ - **Skyblock level**
+ - **Essence Shop**
+ - **Your Essence**
+ - **Power Stone Guide**
+ - **Stats Tuning**
- **Drill Fuel and Pickonimbus 2000 in Item Durability Bar**
- **Hotbar Slot Lock Keybind:** Select the hotbar slot you want to lock/unlock and press the lock button.
- **Item Tooltip:** (Provides information on)
@@ -141,6 +171,8 @@
- **Fancy Crafting Table**
- **Info Screen**
- **Fancy Auctions Browser**
+- **Calendar Event Notifications**
+- **Sign calculator**
### Barn Features:
- **Barn Solver:**
@@ -167,6 +199,7 @@
- Fishing rod timer (change color after 20 seconds)
- Hide other rods
- **Mythological Ritual Helper**
+- **Chocolate factory Helper**
### Miscellaneous Features:
- **[Roughly Enough Items (REI)](https://modrinth.com/mod/rei) and [EMI](https://modrinth.com/mod/emi) Support**
diff --git a/README.md b/README.md
index a65125d3..21467588 100644
--- a/README.md
+++ b/README.md
@@ -52,6 +52,8 @@ Installation guide is [here](https://github.com/SkyblockerMod/Skyblocker/wiki/in
- **Resourcepack recoloring textures in dungeons**
- **score title and sound**
- **Prevent teammates glow during Livid**
+- **Block Incorrect Terminal Clicks**
+- **Hide Soulweaver Skulls**
### Kuudra Features
- **Kuudra waypoints**
@@ -75,6 +77,7 @@ Installation guide is [here](https://github.com/SkyblockerMod/Skyblocker/wiki/in
- *Mana*
- *Defense*
- *XP*
+- **Vanilla health/xp and fancy bar shown in parallel**
### Dwarven Mines / Crystal Hollows / Glacite Mining:
- **Dwarven Mines Solver:**
@@ -89,6 +92,8 @@ Installation guide is [here](https://github.com/SkyblockerMod/Skyblocker/wiki/in
- *Find locations in chat messages*
- *Share waypoints*
- Metal detector helper
+- **Glacite Tunnels**
+ - **Cold Overlay**
- **Commission HUD**
- *Provides information on Dwarven Mines / Crystal Hollows / Glacite Mining quests*
- **Powder HUD**
@@ -115,12 +120,22 @@ Installation guide is [here](https://github.com/SkyblockerMod/Skyblocker/wiki/in
### Garden Features:
- **Farming HUD**
+ - Counter
+ - Crops/min
+ - Coins/h
+ - Blocks/s
+ - Farming Level
+ - Farming XP/h
+ - Yaw and Pitch
- **Visitor Helper**
- Buy items that visitors require from bazaar by clicking the text
+ - Copy amount to clipboard
- **Disable title and chat messages for Melon/Pumpkin Dicer**
- **Basic garden mouse locking feature (set mouse sensitivity to 0)**
### Visual Enhancements:
+- **Compact damage**
+- **Waypoints for commissions in dwarven mines and glacite tunnels**
- **Fancy Tab HUD:** Fully configurable with a resource pack.
- **1.8 Hitbox for Lever and Farmland**
- **Hide Status Effect Overlay**
@@ -142,7 +157,22 @@ Installation guide is [here](https://github.com/SkyblockerMod/Skyblocker/wiki/in
### User Interface Enhancements:
- **Search overlays for bz and ah**
-- **Attribute Shard Info Display**
+- **Slot Text**
+ - **Attribute Shard Info Display**
+ - **Catacombs level**
+ - **Collection level**
+ - **Enchantment book level**
+ - **Minion level**
+ - **Pet level**
+ - **Potion level**
+ - **Prehistoric egg blocks walked**
+ - **Rancher's boots speed cap**
+ - **Skill level**
+ - **Skyblock level**
+ - **Essence Shop**
+ - **Your Essence**
+ - **Power Stone Guide**
+ - **Stats Tuning**
- **Drill Fuel and Pickonimbus 2000 in Item Durability Bar**
- **Hotbar Slot Lock Keybind:** Select the hotbar slot you want to lock/unlock and press the lock button.
- **Item Tooltip:** (Provides information on)
@@ -161,6 +191,8 @@ Installation guide is [here](https://github.com/SkyblockerMod/Skyblocker/wiki/in
- **Fancy Crafting Table**
- **Info Screen**
- **Fancy Auctions Browser**
+- **Calendar Event Notifications**
+- **Sign calculator**
### Barn Features:
- **Barn Solver:**
@@ -187,6 +219,7 @@ Installation guide is [here](https://github.com/SkyblockerMod/Skyblocker/wiki/in
- Fishing rod timer (change color after 20 seconds)
- Hide other rods
- **Mythological Ritual Helper**
+- **Chocolate factory Helper**
### Miscellaneous Features:
- **[Roughly Enough Items (REI)](https://modrinth.com/mod/rei) and [EMI](https://modrinth.com/mod/emi) Support**
@@ -284,9 +317,9 @@ information.
|----------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------|
| [Ghost-3](https://github.com/Ghost-3) | [esteban4567890](https://github.com/esteban4567890) | [Fluboxer](https://github.com/Fluboxer) | [VeritasDL](https://github.com/VeritasDL) |
-| [<img alt="TheDearbear" src="https://github.com/TheDearbear.png" width="100">](https://github.com/TheDearbear) |
-|----------------------------------------------------------------------------------------------------------------|
-| [TheDearbear](https://github.com/TheDearbear) |
+| [<img alt="TheDearbear" src="https://github.com/TheDearbear.png" width="100">](https://github.com/TheDearbear) | [<img alt="BigloBot" src="https://github.com/BigloBot.png" width="100">](https://github.com/BigloBot) | [<img alt="f3shqt" src="https://github.com/f3shqt.png" width="100">](https://github.com/f3shqt) | [<img alt="UpFault" src="https://github.com/UpFault.png" width="100">](https://github.com/UpFault) |
+|----------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------|
+| [TheDearbear](https://github.com/TheDearbear) | [BigloBot](https://github.com/BigloBot) | [f3shqt](https://github.com/f3shqt) | [UpFault](https://github.com/UpFault) |
### Translators
@@ -294,9 +327,9 @@ German ([LifeIsAParadox](https://github.com/LifeIsAParadox) & [msg-programs](htt
Indonesian ([null2264](https://github.com/null2264)) \
Russian ([HyperSoop](https://github.com/HyperSoop) & [CrimsonIsle](https://github.com/CrimsonIsle) & [Ghost-3](https://github.com/Ghost-3) & [wilson-wtf](https://github.com/wilson-wtf) & [R2kip](https://github.com/R2kip) & [Kolobok125040](https://github.com/Kolobok125040))\
French ([edgarogh](https://github.com/edgarogh) & [Julienraptor01](https://github.com/Julienraptor01) & [viciscat](https://github.com/viciscat) & [Kiverty](https://github.com/Kiverty) & [maDU59](https://github.com/maDU59)) \
-Japanese ([hirochisan](https://github.com/hirochisan)) \
-Chinese ([catandA](https://github.com/catandA)) \
-Chinese (Simplified) ([catandA](https://github.com/catandA) & [PumpkinXD](https://github.com/PumpkinXD) & [user123321111](https://github.com/user123321111) & [sunnytia](https://github.com/sunnytia) & [AC19970](https://github.com/AC19970)) \
+Japanese ([hirochisan](https://github.com/hirochisan) & [AC19970](https://github.com/AC19970)) \
+Chinese ([catandA](https://github.com/catandA) & [AC19970](https://github.com/AC19970)) \
+Chinese (Simplified) ([catandA](https://github.com/catandA) & [PumpkinXD](https://github.com/PumpkinXD) & [user123321111](https://github.com/user123321111) & [sunnytia](https://github.com/sunnytia) & [AC19970](https://github.com/AC19970) & [x-yingcan-x](https://github.com/x-yingcan-x)) \
Korean ([lantice3720](https://github.com/lantice3720)) \
Spanish ([IngeSebastian](https://github.com/IngeSebastian)) \
Norwegian Bokmål ([KdGaming0](https://github.com/KdGaming0)) \
@@ -305,4 +338,5 @@ Turkish ([Fix3dll](https://github.com/Fix3dll) & [Emirlol](https://github.com/Em
Canadian English ([AzureAaron](https://github.com/AzureAaron)) \
Portuguese (Brazil) ([OhRetro](https://github.com/OhRetro) & [AurinVPK](https://github.com/AurinVPK) & [yFelipeMC](https://github.com/yFelipeMC)) \
Dutch ([mitch030504](https://github.com/mitch030504)) \
-Italian ([Vricken](https://github.com/Vricken)) \ No newline at end of file
+Italian ([Vricken](https://github.com/Vricken)) \
+Polish ([danehcan](https://github.com/danehcan)) \ No newline at end of file
diff --git a/gradle.properties b/gradle.properties
index 77075ae7..5eb4a8fe 100644
--- a/gradle.properties
+++ b/gradle.properties
@@ -13,7 +13,7 @@ fabric_api_version=0.100.0+1.20.6
# Minecraft Mods
## YACL (https://github.com/isXander/YetAnotherConfigLib)
-yacl_version=3.4.4+1.20.6
+yacl_version=3.5.0+1.20.6
## Mod Menu (https://modrinth.com/mod/modmenu/versions)
mod_menu_version = 10.0.0-beta.1
## REI (https://modrinth.com/mod/rei/versions?l=fabric)
@@ -34,7 +34,7 @@ jgit_version = 6.9.0.202403050737-r
commons_math_version = 3.6.1
# Mod Properties
-mod_version = 1.20.2
+mod_version = 1.21.0
maven_group = de.hysky
archives_base_name = skyblocker
modrinth_id=y6DuFGwJ
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/dwarven/DwarvenHud.java b/src/main/java/de/hysky/skyblocker/skyblock/dwarven/DwarvenHud.java
index 2cf0ea9d..9ca9953b 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/dwarven/DwarvenHud.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/dwarven/DwarvenHud.java
@@ -1,6 +1,7 @@
package de.hysky.skyblocker.skyblock.dwarven;
import de.hysky.skyblocker.config.SkyblockerConfigManager;
+import de.hysky.skyblocker.config.configs.MiningConfig;
import de.hysky.skyblocker.events.HudRenderEvents;
import de.hysky.skyblocker.mixins.accessors.PlayerListHudAccessor;
import de.hysky.skyblocker.skyblock.tabhud.util.Colors;
@@ -164,7 +165,9 @@ public class DwarvenHud {
public static void update() {
if (CLIENT.player == null || CLIENT.getNetworkHandler() == null
- || !SkyblockerConfigManager.get().mining.dwarvenHud.enabledCommissions && !SkyblockerConfigManager.get().mining.dwarvenHud.enabledPowder
+ || !SkyblockerConfigManager.get().mining.dwarvenHud.enabledCommissions
+ && !SkyblockerConfigManager.get().mining.dwarvenHud.enabledPowder
+ && SkyblockerConfigManager.get().mining.commissionWaypoints.mode == MiningConfig.CommissionWaypointMode.OFF
|| !Utils.isInCrystalHollows() && !Utils.isInDwarvenMines()) {
return;
}
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/fancybars/StatusBarsConfigScreen.java b/src/main/java/de/hysky/skyblocker/skyblock/fancybars/StatusBarsConfigScreen.java
index df072710..0a9b2b7a 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/fancybars/StatusBarsConfigScreen.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/fancybars/StatusBarsConfigScreen.java
@@ -293,6 +293,7 @@ public class StatusBarsConfigScreen extends Screen {
if (button == 0) {
cursorBar = statusBar;
cursorBar.inMouse = true;
+ currentInsertLocation = BarLocation.of(cursorBar);
if (statusBar.anchor != null)
FancyStatusBars.barPositioner.removeBar(statusBar.anchor, statusBar.gridY, statusBar);
FancyStatusBars.updatePositions();
@@ -322,6 +323,7 @@ public class StatusBarsConfigScreen extends Screen {
public boolean mouseReleased(double mouseX, double mouseY, int button) {
if (cursorBar != null) {
cursorBar.inMouse = false;
+ currentInsertLocation = BarLocation.of(cursorBar);
cursorBar = null;
FancyStatusBars.updatePositions();
checkNullAnchor(FancyStatusBars.statusBars.values());
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/garden/FarmingHud.java b/src/main/java/de/hysky/skyblocker/skyblock/garden/FarmingHud.java
index b845e07a..5837ea20 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/garden/FarmingHud.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/garden/FarmingHud.java
@@ -135,7 +135,7 @@ public class FarmingHud {
}
public enum CounterType {
- NONE("", "No Counter: "),
+ NONE("", "No Counter"),
COUNTER("mined_crops", "Counter: "),
CULTIVATING("farmed_cultivating", "Cultivating Counter: ");
@@ -146,5 +146,8 @@ public class FarmingHud {
this.nbtKey = nbtKey;
this.text = text;
}
+ public boolean matchesText(String textToMatch) {
+ return this.text.equals(textToMatch);
+ }
}
}
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/garden/FarmingHudWidget.java b/src/main/java/de/hysky/skyblocker/skyblock/garden/FarmingHudWidget.java
index c413ad44..84013f0b 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/garden/FarmingHudWidget.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/garden/FarmingHudWidget.java
@@ -66,7 +66,10 @@ public class FarmingHudWidget extends Widget {
String cropItemId = FARMING_TOOLS.get(ItemUtils.getItemId(farmingToolStack));
ItemStack cropStack = ItemRepository.getItemStack(ItemTooltip.getNeuName(cropItemId, cropItemId)); // The cropItemId is being used as the api id in the second parameter because the skyblock id and api id are the same for all crops.
- addSimpleIcoText(cropStack, FarmingHud.counterText(), Formatting.YELLOW, FarmingHud.NUMBER_FORMAT.format(FarmingHud.counter()));
+ String counterText = FarmingHud.counterText();
+ String counterNumber = FarmingHud.NUMBER_FORMAT.format(FarmingHud.counter());
+ if (FarmingHud.CounterType.NONE.matchesText(counterText)) counterNumber = "";
+ addSimpleIcoText(cropStack, counterText, Formatting.YELLOW, counterNumber);
float cropsPerMinute = FarmingHud.cropsPerMinute();
addSimpleIcoText(cropStack, "Crops/min: ", Formatting.YELLOW, FarmingHud.NUMBER_FORMAT.format((int) cropsPerMinute / 10 * 10));
addSimpleIcoText(Ico.GOLD, "Coins/h: ", Formatting.GOLD, getPriceText(cropItemId, cropsPerMinute));
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/SlotTextManager.java b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/SlotTextManager.java
index 18131527..d3941d77 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/SlotTextManager.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/SlotTextManager.java
@@ -13,6 +13,7 @@ import java.util.List;
public class SlotTextManager {
private static final SlotTextAdder[] adders = new SlotTextAdder[]{
+ new EssenceShopAdder(),
new EnchantmentLevelAdder(),
new MinionLevelAdder(),
new PetLevelAdder(),
@@ -26,7 +27,10 @@ public class SlotTextManager {
new PrehistoricEggAdder(),
new PotionLevelAdder(),
new CollectionAdder(),
- new CommunityShopAdder()
+ new CommunityShopAdder(),
+ new YourEssenceAdder(),
+ new PowerStonesGuideAdder(),
+ new StatsTuningAdder()
};
private static final ArrayList<SlotTextAdder> currentScreenAdders = new ArrayList<>();
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/AttributeShardAdder.java b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/AttributeShardAdder.java
index 811677d7..81f543f8 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/AttributeShardAdder.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/AttributeShardAdder.java
@@ -85,8 +85,8 @@ public class AttributeShardAdder extends SlotTextAdder {
String attributeInitials = ID_2_SHORT_NAME.getOrDefault(attributeId, "");
return List.of(
- SlotText.bottomRight(Text.literal(String.valueOf(attributeLevel)).withColor(0x34eb77)),
- SlotText.topLeft(Text.literal(attributeInitials).formatted(Formatting.AQUA))
+ SlotText.bottomRight(Text.literal(String.valueOf(attributeLevel)).withColor(0xFFDDC1)),
+ SlotText.topLeft(Text.literal(attributeInitials).withColor(0xCFF8F8))
);
}
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/CatacombsLevelAdder.java b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/CatacombsLevelAdder.java
index da12e867..6c99ebf9 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/CatacombsLevelAdder.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/CatacombsLevelAdder.java
@@ -44,7 +44,7 @@ public class CatacombsLevelAdder {
level = String.valueOf(RomanNumerals.romanToDecimal(roman));
}
- return List.of(SlotText.bottomLeft(Text.literal(level).formatted(Formatting.RED)));
+ return List.of(SlotText.bottomLeft(Text.literal(level).withColor(0xFFDDC1)));
}
default -> {
return List.of();
@@ -65,7 +65,7 @@ public class CatacombsLevelAdder {
case 11, 12, 13, 14, 15 -> {
String level = getBracketedLevelFromName(slot.getStack());
if (!NumberUtils.isDigits(level)) return List.of();
- return List.of(SlotText.bottomLeft(Text.literal(level).formatted(Formatting.RED)));
+ return List.of(SlotText.bottomLeft(Text.literal(level).withColor(0xFFDDC1)));
}
default -> {
return List.of();
@@ -86,7 +86,7 @@ public class CatacombsLevelAdder {
case 29, 30, 31, 32, 33 -> {
String level = getBracketedLevelFromName(slot.getStack());
if (!NumberUtils.isDigits(level)) return List.of();
- return List.of(SlotText.bottomLeft(Text.literal(level).formatted(Formatting.RED)));
+ return List.of(SlotText.bottomLeft(Text.literal(level).withColor(0xFFDDC1)));
}
default -> {
return List.of();
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/CollectionAdder.java b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/CollectionAdder.java
index e577f0d8..207190c2 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/CollectionAdder.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/CollectionAdder.java
@@ -6,7 +6,6 @@ import de.hysky.skyblocker.utils.RomanNumerals;
import net.minecraft.item.ItemStack;
import net.minecraft.screen.slot.Slot;
import net.minecraft.text.Text;
-import net.minecraft.util.Formatting;
import org.jetbrains.annotations.NotNull;
import java.util.List;
@@ -26,7 +25,7 @@ public class CollectionAdder extends SlotTextAdder {
Matcher matcher = COLLECTION.matcher(stack.getName().getString());
if (matcher.matches()) {
int level = RomanNumerals.romanToDecimal(matcher.group("level"));
- return List.of(SlotText.bottomRight(Text.literal(String.valueOf(level)).formatted(Formatting.YELLOW)));
+ return List.of(SlotText.bottomRight(Text.literal(String.valueOf(level)).withColor(0xFFDDC1)));
}
return List.of();
}
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/EnchantmentLevelAdder.java b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/EnchantmentLevelAdder.java
index 9c85ae61..5530035d 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/EnchantmentLevelAdder.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/EnchantmentLevelAdder.java
@@ -31,11 +31,11 @@ public class EnchantmentLevelAdder extends SlotTextAdder {
NbtCompound enchantments = nbt.getCompound("enchantments");
if (enchantments.getSize() != 1) return List.of(); //Only makes sense to display the level when there's one enchant.
int level = enchantments.getInt(enchantments.getKeys().iterator().next());
- return List.of(SlotText.bottomLeft(Text.literal(String.valueOf(level)).formatted(Formatting.GREEN)));
+ return List.of(SlotText.bottomLeft(Text.literal(String.valueOf(level)).withColor(0xFFDDC1)));
} else { //In bazaar, the books have the enchantment level in the name
int level = getEnchantLevelFromString(name);
if (level == 0) return List.of();
- return List.of(SlotText.bottomLeft(Text.literal(String.valueOf(level)).formatted(Formatting.GREEN)));
+ return List.of(SlotText.bottomLeft(Text.literal(String.valueOf(level)).withColor(0xFFDDC1)));
}
}
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/EssenceShopAdder.java b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/EssenceShopAdder.java
new file mode 100644
index 00000000..65574a5a
--- /dev/null
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/EssenceShopAdder.java
@@ -0,0 +1,51 @@
+package de.hysky.skyblocker.skyblock.item.slottext.adders;
+
+import de.hysky.skyblocker.skyblock.item.slottext.SlotText;
+import de.hysky.skyblocker.skyblock.item.slottext.SlotTextAdder;
+import de.hysky.skyblocker.utils.ItemUtils;
+import de.hysky.skyblocker.utils.RomanNumerals;
+import net.minecraft.item.ItemStack;
+import net.minecraft.screen.slot.Slot;
+import net.minecraft.text.Text;
+import org.jetbrains.annotations.NotNull;
+
+import java.text.NumberFormat;
+import java.util.List;
+import java.util.Locale;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+
+public class EssenceShopAdder extends SlotTextAdder {
+ private static final Pattern ESSENCELEVEL = Pattern.compile("^[\\w ]+ (?<level>[IVXLCDM]+)$");
+ private static final Pattern UNLOCKED = Pattern.compile("UNLOCKED");
+ private static final Pattern ESSENCE = Pattern.compile("Your \\w+ Essence: (?<essence>[\\d,]+)");
+
+ public EssenceShopAdder() {
+ super("Essence Shop");
+ }
+
+ @Override
+ public @NotNull List<SlotText> getText(Slot slot) {
+ final ItemStack stack = slot.getStack();
+
+ Matcher essenceLevelMatcher = ESSENCELEVEL.matcher(stack.getName().getString());
+ Matcher essenceAmountMatcher = ItemUtils.getLoreLineIfMatch(stack, ESSENCE);
+
+ if (essenceLevelMatcher.matches()) {
+ int level = RomanNumerals.romanToDecimal(essenceLevelMatcher.group("level"));
+ Matcher unlockedMatcher = ItemUtils.getLoreLineIfMatch(stack, UNLOCKED);
+ if (unlockedMatcher == null) {
+ level -= 1;
+ }
+ return List.of(SlotText.bottomRight(Text.literal(String.valueOf(level)).withColor(0xFFDDC1)));
+ }
+ if (essenceAmountMatcher == null) return List.of();
+ String essenceAmount = essenceAmountMatcher.group("essence").replace(",", "");
+ if (!essenceAmount.matches("-?\\d+")) return List.of();
+ NumberFormat NUMBER_FORMATTER_S = NumberFormat.getCompactNumberInstance(Locale.CANADA, NumberFormat.Style.SHORT);
+ NUMBER_FORMATTER_S.setMinimumFractionDigits(1);
+ int amount = Integer.parseInt(essenceAmount);
+
+ return List.of(SlotText.bottomRight(Text.literal(NUMBER_FORMATTER_S.format(amount)).withColor(0xFFDDC1)));
+ }
+}
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/MinionLevelAdder.java b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/MinionLevelAdder.java
index b9fe130f..fc46f153 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/MinionLevelAdder.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/MinionLevelAdder.java
@@ -29,6 +29,6 @@ public class MinionLevelAdder extends SlotTextAdder {
String romanNumeral = matcher.group(1);
if (!RomanNumerals.isValidRomanNumeral(romanNumeral)) return List.of();
int level = RomanNumerals.romanToDecimal(romanNumeral);
- return List.of(SlotText.topRight(Text.literal(String.valueOf(level)).formatted(Formatting.AQUA)));
+ return List.of(SlotText.topRight(Text.literal(String.valueOf(level)).withColor(0xFFDDC1)));
}
}
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PetLevelAdder.java b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PetLevelAdder.java
index 3813563a..88d48fbf 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PetLevelAdder.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PetLevelAdder.java
@@ -23,6 +23,7 @@ public class PetLevelAdder extends SlotTextAdder {
if (!itemStack.isOf(Items.PLAYER_HEAD)) return List.of();
String level = CatacombsLevelAdder.getBracketedLevelFromName(itemStack);
if (!NumberUtils.isDigits(level)) return List.of();
- return List.of(SlotText.topLeft(Text.literal(level).formatted(Formatting.GOLD)));
+ if ("100".equals(level) || "200".equals(level)) return List.of();
+ return List.of(SlotText.topLeft(Text.literal(level).withColor(0xFFDDC1)));
}
}
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PotionLevelAdder.java b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PotionLevelAdder.java
index 457d2964..1c3ef4bc 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PotionLevelAdder.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PotionLevelAdder.java
@@ -8,7 +8,6 @@ import net.minecraft.nbt.NbtCompound;
import net.minecraft.nbt.NbtElement;
import net.minecraft.screen.slot.Slot;
import net.minecraft.text.Text;
-import net.minecraft.util.Formatting;
import org.jetbrains.annotations.NotNull;
import java.util.List;
@@ -18,9 +17,15 @@ public class PotionLevelAdder extends SlotTextAdder {
public @NotNull List<SlotText> getText(Slot slot) {
final ItemStack stack = slot.getStack();
NbtCompound customData = ItemUtils.getCustomData(stack);
- if (customData.contains("potion_level", NbtElement.INT_TYPE)) {
- int level = customData.getInt("potion_level");
- return List.of(SlotText.bottomRight(Text.literal(String.valueOf(level)).formatted(Formatting.AQUA)));
+ String title = stack.getName().getString();
+ if (customData.contains("potion_level", NbtElement.INT_TYPE) && !title.contains("Healer Class") && !title.contains("Class Passives")) {
+ if (title.contains("Healer Level ")){
+ String level = title.replaceAll("[^0-9]", "");
+ return List.of(SlotText.bottomRight(Text.literal(level).withColor(0xFFFFFF)));
+ } else {
+ int level = customData.getInt("potion_level");
+ return List.of(SlotText.bottomRight(Text.literal(String.valueOf(level)).withColor(0xFFDDC1)));
+ }
}
return List.of();
}
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PowerStonesGuideAdder.java b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PowerStonesGuideAdder.java
new file mode 100644
index 00000000..0bb37165
--- /dev/null
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PowerStonesGuideAdder.java
@@ -0,0 +1,38 @@
+package de.hysky.skyblocker.skyblock.item.slottext.adders;
+
+import de.hysky.skyblocker.skyblock.item.slottext.SlotText;
+import de.hysky.skyblocker.skyblock.item.slottext.SlotTextAdder;
+import de.hysky.skyblocker.utils.ItemUtils;
+import net.minecraft.item.ItemStack;
+import net.minecraft.screen.slot.Slot;
+import net.minecraft.text.Text;
+import org.jetbrains.annotations.NotNull;
+
+import java.util.List;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+
+public class PowerStonesGuideAdder extends SlotTextAdder {
+ private static final Pattern LEARNED = Pattern.compile("Learned: (Yes|Not Yet) (?<symbol>[✖✔])");
+
+ public PowerStonesGuideAdder() {
+ super("^Power Stones Guide");
+ }
+
+ @Override
+ public @NotNull List<SlotText> getText(Slot slot) {
+ final ItemStack stack = slot.getStack();
+
+ Matcher match = ItemUtils.getLoreLineIfMatch(stack, LEARNED);
+ if (match == null) return List.of();
+ String symbol = match.group("symbol");
+ Text text;
+ if (symbol.equals("✖")) {
+ text = Text.literal("✖").withColor(0xFF7276);
+ } else {
+ text = Text.literal("✔").withColor(0x90ee90);
+ }
+
+ return List.of(SlotText.bottomRight(text));
+ }
+}
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PrehistoricEggAdder.java b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PrehistoricEggAdder.java
index a157efee..ce29297e 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PrehistoricEggAdder.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/PrehistoricEggAdder.java
@@ -29,6 +29,6 @@ public class PrehistoricEggAdder extends SlotTextAdder {
else if (walked < 10000) walkedstr = String.format("%.1fk", walked/1000.0f);
else walkedstr = walked / 1000 + "k";
- return List.of(SlotText.bottomLeft(Text.literal(walkedstr).formatted(Formatting.GOLD)));
+ return List.of(SlotText.bottomLeft(Text.literal(walkedstr).withColor(0xFFDDC1)));
}
}
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/RancherBootsSpeedAdder.java b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/RancherBootsSpeedAdder.java
index 1f92fb8a..7de5a5be 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/RancherBootsSpeedAdder.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/RancherBootsSpeedAdder.java
@@ -31,6 +31,6 @@ public class RancherBootsSpeedAdder extends SlotTextAdder {
if (matcher == null) return List.of();
String speed = matcher.group(2);
if (speed == null) speed = matcher.group(1); //2nd group only matches when the speed cap is set to a number beyond the player's actual speed cap.
- return List.of(SlotText.bottomLeft(Text.literal(speed).formatted(Formatting.GREEN)));
+ return List.of(SlotText.bottomLeft(Text.literal(speed).withColor(0xFFDDC1)));
}
}
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/SkillLevelAdder.java b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/SkillLevelAdder.java
index 095982af..07b8dd9b 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/SkillLevelAdder.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/SkillLevelAdder.java
@@ -24,7 +24,7 @@ public class SkillLevelAdder extends SlotTextAdder {
if (lastIndex == -1) return List.of(SlotText.bottomLeft(Text.literal("0").formatted(Formatting.LIGHT_PURPLE))); //Skills without any levels don't display any roman numerals. Probably because 0 doesn't exist.
String romanNumeral = name.substring(lastIndex + 1); //+1 because we don't need the space itself
//The "romanNumeral" might be a latin numeral, too. There's a skyblock setting for this, so we have to do it this way V
- return List.of(SlotText.bottomLeft(Text.literal(String.valueOf(RomanNumerals.isValidRomanNumeral(romanNumeral) ? RomanNumerals.romanToDecimal(romanNumeral) : Integer.parseInt(romanNumeral))).formatted(Formatting.LIGHT_PURPLE)));
+ return List.of(SlotText.bottomLeft(Text.literal(String.valueOf(RomanNumerals.isValidRomanNumeral(romanNumeral) ? RomanNumerals.romanToDecimal(romanNumeral) : Integer.parseInt(romanNumeral))).withColor(0xFFDDC1)));
}
default -> {
return List.of();
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/SkyblockLevelAdder.java b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/SkyblockLevelAdder.java
index 8b528508..0fc07922 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/SkyblockLevelAdder.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/SkyblockLevelAdder.java
@@ -22,8 +22,8 @@ public class SkyblockLevelAdder extends SlotTextAdder {
if (lore.isEmpty()) return List.of();
List<Text> siblings = lore.getFirst().getSiblings();
if (siblings.size() < 3) return List.of();
- Text levelText = siblings.get(2); //The 3rd child is the level text itself
- if (!NumberUtils.isDigits(levelText.getString())) return List.of();
- return List.of(SlotText.bottomLeft(levelText));
+ String levelText = siblings.get(2).getString(); //The 3rd child is the level text itself
+ if (!NumberUtils.isDigits(levelText)) return List.of();
+ return List.of(SlotText.bottomLeft(Text.literal(levelText).withColor(0xFFDDC1)));
}
}
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/StatsTuningAdder.java b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/StatsTuningAdder.java
new file mode 100644
index 00000000..3079d8f2
--- /dev/null
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/StatsTuningAdder.java
@@ -0,0 +1,42 @@
+package de.hysky.skyblocker.skyblock.item.slottext.adders;
+
+import de.hysky.skyblocker.skyblock.item.slottext.SlotText;
+import de.hysky.skyblocker.skyblock.item.slottext.SlotTextAdder;
+import de.hysky.skyblocker.utils.ItemUtils;
+import net.minecraft.item.ItemStack;
+import net.minecraft.screen.slot.Slot;
+import net.minecraft.text.Text;
+import org.jetbrains.annotations.NotNull;
+
+import java.util.List;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+
+public class StatsTuningAdder extends SlotTextAdder {
+ private static final Pattern STATHAS = Pattern.compile("Stat has: (?<points>\\d+) (points|point)");
+ private static final Pattern UNASSIGNEDPOINTS = Pattern.compile("Unassigned Points: (?<points>\\d+)!!!");
+
+ public StatsTuningAdder() {
+ super("^Stats Tuning");
+ }
+
+ @Override
+ public @NotNull List<SlotText> getText(Slot slot) {
+ final ItemStack stack = slot.getStack();
+
+ Matcher statMatcher = ItemUtils.getLoreLineIfMatch(stack, STATHAS);
+ Matcher unassignedMatcher = ItemUtils.getLoreLineIfMatch(stack, UNASSIGNEDPOINTS);
+
+ if (stack.getName().getString().equals("Stats Tuning")) {
+ if (unassignedMatcher == null) return List.of();
+ String unassignedPoints = unassignedMatcher.group("points");
+ return List.of(SlotText.bottomRight(Text.literal(unassignedPoints).withColor(0xFFDDC1)));
+ }
+
+ if (statMatcher == null) return List.of();
+ String assignedPoints = statMatcher.group("points");
+ if (assignedPoints.equals("0")) return List.of();
+ return List.of(SlotText.bottomRight(Text.literal(assignedPoints).withColor(0xFFDDC1)));
+
+ }
+}
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/YourEssenceAdder.java b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/YourEssenceAdder.java
new file mode 100644
index 00000000..ec1bd561
--- /dev/null
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/slottext/adders/YourEssenceAdder.java
@@ -0,0 +1,46 @@
+package de.hysky.skyblocker.skyblock.item.slottext.adders;
+
+import de.hysky.skyblocker.skyblock.item.slottext.SlotText;
+import de.hysky.skyblocker.skyblock.item.slottext.SlotTextAdder;
+import de.hysky.skyblocker.utils.ItemUtils;
+import net.minecraft.item.ItemStack;
+import net.minecraft.screen.slot.Slot;
+import net.minecraft.text.Text;
+import org.jetbrains.annotations.NotNull;
+
+import java.text.NumberFormat;
+import java.util.List;
+import java.util.Locale;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+
+public class YourEssenceAdder extends SlotTextAdder {
+ private static final Pattern ESSENCE = Pattern.compile("You currently own (?<essence>[\\d,]+)");
+
+ public YourEssenceAdder() {
+ super("^Your Essence");
+ }
+
+ @Override
+ public @NotNull List<SlotText> getText(Slot slot) {
+ final ItemStack stack = slot.getStack();
+ String name = stack.getName().getString();
+ if (name.contains("Essence")) {
+ List<Text> lore = ItemUtils.getLore(stack);
+ if (lore.isEmpty()) return List.of();
+ String essenceAmountText = lore.getFirst().getString();
+
+ Matcher essenceAmountMatcher = ESSENCE.matcher(essenceAmountText);
+ if (essenceAmountMatcher.find()) {
+ String essenceAmount = essenceAmountMatcher.group("essence").replace(",", "");
+ if (!essenceAmount.matches("-?\\d+")) return List.of();
+ NumberFormat NUMBER_FORMATTER_S = NumberFormat.getCompactNumberInstance(Locale.CANADA, NumberFormat.Style.SHORT);
+ NUMBER_FORMATTER_S.setMinimumFractionDigits(1);
+ int amount = Integer.parseInt(essenceAmount);
+
+ return List.of(SlotText.bottomRight(Text.literal(NUMBER_FORMATTER_S.format(amount)).withColor(0xFFDDC1)));
+ }
+ }
+ return List.of();
+ }
+} \ No newline at end of file
diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/tooltip/TooltipInfoType.java b/src/main/java/de/hysky/skyblocker/skyblock/item/tooltip/TooltipInfoType.java
index 88f09496..d82b2682 100644
--- a/src/main/java/de/hysky/skyblocker/skyblock/item/tooltip/TooltipInfoType.java
+++ b/src/main/java/de/hysky/skyblocker/skyblock/item/tooltip/TooltipInfoType.java
@@ -1,6 +1,9 @@
package de.hysky.skyblocker.skyblock.item.tooltip;
+import com.google.gson.JsonElement;
import com.google.gson.JsonObject;
+import com.google.gson.JsonPrimitive;
+import com.google.gson.stream.JsonReader;
import de.hysky.skyblocker.SkyblockerMod;
import de.hysky.skyblocker.config.SkyblockerConfig;
import de.hysky.skyblocker.config.SkyblockerConfigManager;
@@ -8,6 +11,7 @@ import de.hysky.skyblocker.config.configs.GeneralConfig;
import de.hysky.skyblocker.utils.Http;
import de.hysky.skyblocker.utils.Utils;
+import java.io.StringReader;
import java.net.http.HttpHeaders;
import java.util.List;
import java.util.concurrent.CompletableFuture;
@@ -160,7 +164,12 @@ public enum TooltipInfoType implements Runnable {
if (this.hash == hash) return;
else this.hash = hash;
}
- data = SkyblockerMod.GSON.fromJson(Http.sendGetRequest(address), JsonObject.class);
+ String response = Http.sendGetRequest(address);
+ if (response.trim().startsWith("<!DOCTYPE") || response.trim().startsWith("<html")) {
+ ItemTooltip.LOGGER.warn("[Skyblocker] Received HTML content for " + this.name() + ". Expected JSON.");
+ return;
+ }
+ data = SkyblockerMod.GSON.fromJson(response, JsonObject.class);
if (callback != null) callback.accept(data);
} catch (Exception e) {
diff --git a/src/main/resources/fabric.mod.json b/src/main/resources/fabric.mod.json
index f75159f5..5a7732a0 100644
--- a/src/main/resources/fabric.mod.json
+++ b/src/main/resources/fabric.mod.json
@@ -5,7 +5,7 @@
"name": "Skyblocker",
"description": "Hypixel Skyblock Mod",
"authors": ["LifeIsAParadox/wohlhabend", "kevinthegreat1", "AzureAaron"],
- "contributors": ["xMrVizzy", "d3dx9", "ExternalTime", "Zailer43", "TacoMonkey", "KonaeAkira", "Fix3dll", "null2264", "HyperSoop", "edgarogh", "TheColdPot", "Julienraptor01", "ADON15c", "catandA", "msg-programs", "lantice3720", "Futuremappermydud", "koloiyolo", "viciscat", "Grayray75", "alexiayaa", "KhafraDev", "btwonion", "Kaluub", "Emirlol", "LegendaryLilac", "olim88", "Ghost-3", "esteban4567890", "Fluboxer", "VeritasDL", "TheDearbear"],
+ "contributors": ["xMrVizzy", "d3dx9", "ExternalTime", "Zailer43", "TacoMonkey", "KonaeAkira", "Fix3dll", "null2264", "HyperSoop", "edgarogh", "TheColdPot", "Julienraptor01", "ADON15c", "catandA", "msg-programs", "lantice3720", "Futuremappermydud", "koloiyolo", "viciscat", "Grayray75", "alexiayaa", "KhafraDev", "btwonion", "Kaluub", "Emirlol", "LegendaryLilac", "olim88", "Ghost-3", "esteban4567890", "Fluboxer", "VeritasDL", "TheDearbear", "BigloBot", "f3shqt", "UpFault"],
"contact": {
"homepage": "https://hysky.de",
"sources": "https://github.com/SkyblockerMod/Skyblocker",