diff --git a/.editorconfig b/.editorconfig index 28d8209de82f..8354a021e6fd 100644 --- a/.editorconfig +++ b/.editorconfig @@ -23,8 +23,10 @@ max_line_length = 120 # Java files should not use wildcard imports ij_java_names_count_to_use_import_on_demand = 999 ij_java_class_count_to_use_import_on_demand = 999 +ij_java_packages_to_use_import_on_demand = [*.kt] # Kotlin files should not use wildcard imports ij_kotlin_name_count_to_use_star_import = 999 ij_kotlin_name_count_to_use_star_import_for_members = 999 +ij_kotlin_packages_to_use_import_on_demand = diff --git a/.github/workflows/label-merge-conflict.yml b/.github/workflows/label-merge-conflict.yml new file mode 100644 index 000000000000..19e88ede7971 --- /dev/null +++ b/.github/workflows/label-merge-conflict.yml @@ -0,0 +1,26 @@ +name: "Merge Conflict Label" +on: + # So that PRs touching the same files as the push are updated + push: + branches: [ beta ] + # So that the `dirtyLabel` is removed if conflicts are resolve + # We recommend `pull_request_target` so that GitHub secrets are available. + # In `pull_request` we wouldn't be able to change labels of fork PRs + pull_request_target: + types: [ opened, synchronize ] + +jobs: + conflicts: + runs-on: ubuntu-latest + permissions: + contents: read + pull-requests: write + steps: + - name: Update PRs with conflict labels + uses: eps1lon/actions-label-merge-conflict@releases/2.x + with: + dirtyLabel: "Merge Conflicts" + #removeOnDirtyLabel: "PR: ready to ship" + repoToken: "${{ secrets.GITHUB_TOKEN }}" + commentOnDirty: "This pull request has conflicts with the base branch \"beta\". Please resolve those so we can test out your changes." + commentOnClean: "Conflicts have been resolved! 🎉" diff --git a/.github/workflows/remove-labels-on-pr-close.yml b/.github/workflows/remove-labels-on-pr-close.yml new file mode 100644 index 000000000000..fd73b7aab384 --- /dev/null +++ b/.github/workflows/remove-labels-on-pr-close.yml @@ -0,0 +1,16 @@ +# https://github.com/marketplace/actions/label-remover + +name: "Remove All Labels" + +on: + pull_request_target: + types: [closed] + +jobs: + remove_very_soon: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: rogerluan/label-remover@v1.0.1 + with: + github_token: ${{ secrets.github_token }} diff --git a/CHANGELOG.md b/CHANGELOG.md index a3a69d04b6fd..13fed9e41321 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,12 +1,271 @@ # SkyHanni - Change Log -## Version 0.21 (unreleased) +## Version 0.22 (Unreleased) ### New Features +#### Garden Features + ++ Added Garden Vacuum Pests in Pest bag to item number as stack size. - hannibal2 + + Enable via /sh vacuum. ++ Added Pests to Damage Indicator. - hannibal2 + + Enable Damage Indicator and select Garden Pests. ++ Change how the pest spawn chat message should be formatted. - hannibal2 + + Unchanged, compact or hide the message entirely. ++ Show a Title when a pest spawns. - hannibal2 ++ Show the time since the last pest spawned in your garden. - hannibal2 + + Option to only show the time while holding vacuum in the hand. ++ Show the pests that are attracted when changing the selected material of the Sprayanator. - hannibal2 ++ Added Garden only commands /home, /barn and /tp, and hotkeys. - hannibal2 ++ Showing a better plot name in the scoreboard. Updates faster and doesn't hide when pests are spawned. - hannibal2 ++ Show a display with all known pest locations. - hannibal2 + + Click to warp to the plot. + + Option to only show the time while holding vacuum in the hand. ++ Mark the plots with pests on them in the world. - hannibal2 ++ Press the key to warp to the nearest plot with pests on it. - hannibal2 ++ Draw plot borders when holding the Sprayonator. - HiZe + +#### Fishing Features + ++ Added Barn Fishing Timer to Jerry's Workshop and Crimson Isle. - martimavocado ++ Added Fishing Tracker and changed trackers in general. - hannibal2 + + This tracker GUI behaves the same way as the Slayer Tracker: Allows for single item remove or hide + + Counts coin drops from chat. + + Mark the amount in green when recently gained the item. + + Option to hide the Fishing Tracker while moving. + + Option to hide all Trackers while Estimated Item Value is visible. + + Option to change the default display mode for all trackers. + + The hidden flag for items in Item Trackers is now shared between total view and session view. + + Option to exclude hidden items in the total price calculation. + + Option to change the display mode that gets shown on default: Total, Current or remember last. + +#### Winter Features + ++ Added Unique Gifting Opportunities. - nea + + Highlight players who you haven't given gifts to yet. + + Only highlight ungifted players while holding a gift. + + Make use of armor stands to stop highlighting players. This is a bit inaccurate, but it can help with people you gifted before this feature was used. ++ Added Unique Gifted users counter. - hannibal2 + + Show in a display how many unique players you have given gifts to in the winter 2023 event. + + Run command /opengenerowmenu to sync up. + +#### Bingo Features + ++ Show the duration until the next hidden bingo goal tip gets revealed. - hannibal2 ++ Added support for tips in hidden bingo card display. - hannibal2 ++ Added support for 'found by' info in bingo card. - hannibal2 + +#### Inventory Features + ++ Added bottle of Jyrre time overlay in stack size feature. - HiZe ++ Added show special edition number as stack size when below 1k. - hannibal2 + +#### Minion Features + ++ Shows how much skill experience you will get when picking up items from the minion storage. - Thunderblade73 + +#### Chat Features + ++ Hide the repeating fire sale reminder chat messages. - hannibal2 + +### Changes + +#### Garden Changes + ++ Added option to enable/disable the vacuum bag item number being capped to 40. - hannibal2 ++ Automatic unlocking /shmouselock when teleporting in the garden. - hannibal2 ++ Don't hide messages from Jacob. - alexia + + This is a workaround for wrongly hidden Jakob messages. ++ Show the hint to open Configure Plot only if the pest display is incorrect. - hannibal2 ++ Added the "plot" word to the sidebar again (only if there are no pests in garden). - hannibal2 ++ Hide the Composter Overlay in composter inventory while the Estimated Item Value is visible. - hannibal2 ++ Made the wording of "no pest spawned yet" message more clear. - hannibal2 ++ Not only show the waypoint for infested plots, also show their waypoints in the world. - hannibal2 + +#### Fishing Changes + ++ Show the fishing tracker for a couple of seconds after catching something even while moving. - hannibal2 + +#### Winter Changes + ++ Hiding Unique Gifted Players Highlighting for ironman and bingo while not on those modes. - Thunderblade73 + +### Fixes + +#### Garden Fixes + ++ Fixed pest damage indicator not working for some pests. - hannibal2 ++ Fixed pest kill detection. - hannibal2 ++ Fixed /tp not working with uppercase characters. - hannibal2 ++ Fixed total equipment fortune in /ff. - alexia ++ Fixed Locust pest not getting detected in damage indicator. - hannibal2 ++ Fixed Pest Spray Display showing outside the garden. - hannibal2 ++ Fixed pest detection when more than 3 pests are spawned at once. - hannibal2 ++ Fixed showing on the scoreboard "garden outside" immediately after teleporting to a plot. - hannibal2 ++ Fixed visitor timer counting down too fast sometimes. - hannibal2 ++ Fixed Mooshroom cow Perk display not showing when maxed. - hannibal2 + +#### Misc Fixes + ++ Fixed Item Tracker not ignoring manual sack movements. - hannibal2 ++ Fixed showing yourself green with Unique Gifting Opportunities. - hannibal2 ++ Fixed NPC messages getting detected as player messages. - CalMWolfs + +#### Config Fixes + ++ Fixed a typo in config. - walker + +### Technical Details + ++ Code cleanup in many files. - walker & hannibal2 ++ Moved the JSON object files into another package. - walker ++ Replaced SkyHanniMod.feature.garden with GardenAPI.config. - hannibal2 ++ Added MessageSendToServerEvent. - hannibal2 ++ Added GardenPlotAPI, support for detecting the current slot of the player. - hannibal2 ++ Updated .editorconfig file to better support imports. - Thunderblade73 ++ Migrate Integer to Enums in Config. - walker ++ Using a broken config no longer resets the config in dev env. - hannibal2 ++ Auto-removing all labels of PRs on merging/closing. - hannibal2 ++ Changed OwnInventoryItemUpdateEvent to be called synced to the main thread. - hannibal2 ++ romanToDecimalIfNeeded -> romanToDecimalIfNecessary. - hannibal2 + + For more context: https://chat.openai.com/share/502571b5-8851-4047-b343-3b1475ca8a88 + +## Version 0.21.1 + +### New Features + ++ Organised the config into sub categories. - nea & walker ++ Wrong crop milestone step detection. - hannibal2 + + When opening the crop milestone menu, a chat message is sent if Hypixel's crops per milestone level data is + different from SkyHanni's. + + You can use this to share your hypixel data with SkyHanni via the discord. + + This will allow us to fix the crop milestone features quicker, as we currently do not have accurate data for this. + + If you don't want to share anything, you can disable the chat message in the config with /sh copy milestone data. + +### Changes + ++ /shtrackcollection now supports sack messages. - hannibal2 ++ Changed formatting of coin value to be more consistent over multiple features. - hannibal2 ++ Made skill level as item number no longer default enabled. - hannibal2 + +### Fixes + ++ Fixed the wrong colouring of hidden items in Slayer Profit Tracker. - hannibal2 ++ Added support for NEU Heavy Pearl TO-DO fix working without nether sacks as well. - hannibal2 ++ Fixed Estimated Item Value getting shown in pet rule creation wardrobe slot pick menu. - hannibal2 + +### Technical Details + ++ Added /shwhereami command to show the current island. - martimavocado ++ Tons of code clean-ups over the whole project. - walker & hannibal2 + + Added ItemAddEvent. - hannibal2 ++ Gets called when the user collects an item into inventory or sacks. ++ Created SkyHanniItemTracker. - hannibal2 + + This is a Special variant of SkyHanniTracker, that has item specific functions (hide or remove) and different price variants. ++ Migrated slayer profit data into SkyHanniTracker format. - hannibal2 + +#### Garden Changes + ++ Added mythic/Maeve visitor support. - walker & hannibal2 ++ Added option to use custom Blocks per Second value in some Garden GUIs instead of the real one. - hannibal2 ++ Added option to change the item scale of SkyMart Coins per Copper list. - hannibal2 ++ Added support for Sunder 6 in /ff upgrades. - hannibal2 ++ Added support for mythic in Visitor Drop Statistics. - hannibal2 ++ Use the crop fortune from tab in Farming Fortune HUD. - alexia ++ Shows the last saved ff value in gray while switching tools instead of the question mark. - hannibal2 ++ Removed chat message that your crop milestone data is correct. - hannibal2 ++ Removed the message when crop milestones look different in the menu than stored SkyHanni data. - hannibal2 + + We already have the correct data now, and Hypixel rounds the numbers in the menu poorly. + + Only show the Total Crop Milestone info in crop milestone inventory when below tier 20. - hannibal2 + + Hypixel now has their own line for the same information for tier 20+ ++ Make the FF Display only visible while holding a farming tool in hand. - hannibal2 ++ Hide in crop milestone display the line with time remaining entirely when the milestone is maxed. - hannibal2 + +#### Other Changes + ++ Added guess seconds to the Visitor Timer when the tab list doesn't show seconds. - hannibal2 ++ Add option to hide the chat message when toggling /shmouselock. - hannibal2 ++ Reminds to use the GUI Position Editor hotkey. - hannibal2 + + Reminds every 30 minutes after using /sh gui or clicking the GUI edit button. ++ Added Bookworm Book to the Estimated Item Value feature. - jani + +### Fixes + +#### Garden Fixes + ++ Fixed new visitor alerts triggering wrongly and constantly. - Cad ++ Fixed visitor timer. - hannibal2 ++ Fixed wrong Fungi Cutter mode warning not working. - walker ++ Fixed Maximum FF Needed display not showing in Jacob NPC menu. - hannibal2 ++ Fixed calendar contest detection failing. - hannibal2 ++ Fixed plot borders flickering and consistency errors when pressing the keybind - hannibal2 ++ Fixed wrong ff needed values in Time Needed for Gold Medal GUI. - hannibal2 ++ Fixed Farming Contest Medal Icons in Inventory not showing. - hannibal2 ++ Fixed /ff not detecting collection analyst fortune. - hannibal2 ++ Fixed Mushroom Cow Perk display not working. - hannibal2 ++ Fixed visitor timer error if the visitors aren't unlocked yet. - hannibal2 ++ Fixed farming weight no longer updating on block breaking. - hannibal2 ++ Added cooldown to prevent spam clicking on farming weight buttons to open many web pages. - hannibal2 ++ Fixed clickable farming weight GUI no longer opens #1000 in lb website. - hannibal2 ++ Fixed /ff upgrade suggests updating bustling reforge even when no farming armor is found. - hannibal2 ++ Fixed maxed sunder fortune in the /ff stats breakdown. - alexia ++ Fixed the farming contest summary not showing when the crop is buffed by Anita Talisman/Ring/Artifact. - hannibal2 ++ Fixed Farming Fortune Display not showing for non crop-specific tools. - hannibal2 ++ Fixed green thumb fortune in /ff to include Maeve. - hannibal2 ++ Fixed crops per second and time remaining not using the 100 base ff in their formula. - alexia + +#### Other Fixes + ++ Fixed showing "slayer boss spawn soon" message outside the correct slayer area. - hannibal2 ++ Fixed blocking clicks on bazaar with player name "wiki". - hannibal2 ++ Fixed highlighting some mobs in the dungeon wrongly as area mini bosses. - hannibal2 ++ Fixed opening the Pet menu no longer updating the current pet display. - hannibal2 ++ Fixed Archfiend Dice and High Class Archfiend Dice counting as slayer drops when rolled. - hannibal2 ++ Fixed dice roll profit counting as Mob Kill Coins in Slayer Tracker. - hannibal2 ++ Fixed Sack Display sometimes not formatting a million correctly. - Hize ++ Fixed Estimated Item Value getting shown in stats breakdown menu. - hannibal2 ++ Fixed a bug with the ender chest and SkyHanni GUI editor. - hannibal2 ++ Fixed crimson isle faction icon in tab list showing twice and not going away fully when enabling the "hide faction" + option of advanced player list. - hannibal2 + +### Technical Details + ++ Updated to a newer version of MoulConfig. - nea & walker + + This includes support for the new sub category part in the config. ++ Added TimeUtils.getDuration and deprecated TimeUtils.getMillis. - hannibal2 ++ Created PetAPI and deprecated String.matchRegex(). - hannibal2 ++ Extracted sacks, friends, known features and Jacob contests in to their separate files. - CalMWolfs ++ Add log clearing. - CalMWolfs ++ Add auto-prefix to chat message methods. - walker ++ Added support for extra data in error manager. - hannibal2 ++ Added /readcropmilestonefromclipboard. - hannibal2 + + This command reads the clipboard content, in the format of users sending crop milestone step data. + + The new data gets compared to the currently saved data, differences are getting replaced and the result gets put + into the clipboard. The clipboard context can be used to update the repo content. + +### Removed Features + ++ Removed 100 Farming Fortune from "Show As Drop Multiplier" from all displays (also known as "base ff"). - hannibal2 + + This can cause some numbers to show 100 FF too much. Simply update the values to fix it. + + Those "base FF" values were never really part of your farming fortune stats. They are just a result of looking at + the crop drop formula. SkyHanni used those values to be more comparable with other Discord Bots and spreadsheets. + This also caused confusion, so we have removed it entirely now. + +## Version 0.21 + +### New Features + +#### Inventory + + Added Quick Craft Confirmation. - Cad + Require Ctrl+Click to craft items that aren't often quick crafted (e.g. armor, weapons, accessories). + Sack items can be crafted normally. ++ Added Shift Click Equipment. - Thunderblade73 + + This removes the need to shift-click to swap the equipment items, without the annoying "pick up animation". ++ Added option to highlight items that are full in the sack inventory. + +#### GUI + + Added **Compact Tab List**. + Compacts the tablist to make it look much nicer (old SBA feature, but fewer bugs). - CalMWolfs + Option to hide Hypixel advertisment banners. - CalMWolfs @@ -16,21 +275,21 @@ party/friends/guild + Option to hide different parts of the player list: Player skins/icons, Hypixel rank color, Emblems, SkyBlock level -+ Added Kick Duration. - hannibal2 - + Show in the Hypixel lobby since when you were last kicked from SkyBlock. - + Useful if you get blocked because of 'You were kicked while joining that server!'. - + Send a warning and sound after a custom amount of seconds. -+ Added Time In Limbo. - hannibal2 - + Show the time since you entered limbo. - + Show a chat message for how long you were in limbo once you leave it. -+ Added Highlight Party Members. - Cad - + Marking party members with a bright outline to better find them in the world. -+ Added Shift Click Equipment. - Thunderblade73 - + This removes the need to shift-click to swap the equipment items, without the annoying "pick up animation". ++ Added AFK time to Discord RPC. - NetheriteMiner + +#### Chat + + Adds chat symbols such as iron man/bingo/nether faction like SBA had/has. - CalMWolfs + Will not break with emblems. + Optional if left or right side of name. + Should not break with other mods. ++ Added Chat **Translator** - NetheriteMiner + + After enabling, click on any chat message sent by another player to translate it to English. + +#### Rendering + ++ Added Highlight Party Members. - Cad + + Marking party members with a bright outline to better find them in the world. + Porting SBA's **chroma** into SkyHanni with many more options and chroma everything. - VixidDev + Options to change speed, size, saturation and direction. + Added Modify Visual Words (command /shwords). - CalMWolfs @@ -39,30 +298,48 @@ + Added In-Game Date display. - Erymanthus + Show the in-game date of SkyBlock (like in Apec, but with mild delays). + Includes the SkyBlock year. ++ Added **Arrow Trail Cosmetic** - Thunderblade73 + + Draw a colored line behind the arrows in the air. + + Options to change the color of the line, to only show own arrows or every arrow, to have own arrows in a different + color, to change the time alive, and the line width. + +#### Crimson Isle + + Added Quest Item Helper. - NetheriteMiner + When you open the fetch item quest in the town board, it shows a clickable chat message that will grab the items needed from the sacks. ++ Added Crimson Isle **Pablo NPC Helper**. - NetheriteMiner + + Similar to Quest Item Helper, shows a clickable message that grabs the flower needed from sacks. + +##### Fishing + + Added alerts when the player catches a Legendary Sea Creature. - Cad ++ Added **Fishing Bait Warnings.** - cimbraien + + Option to warn when no bait is used. + + Option to warn when used bait is changed. + +#### Dungeon + + Added Soulweaver Skull Hider to the Dungeon Object Hider. - nea + Hide the annoying soulweaver skulls that float around you if you have the soulweaver gloves equipped. -+ Added /shmouselock command to lock mouse rotation for farming. - Cad + Added **Dungeon party finder** QOL improvements - Cad + Floor stack size. + Mark Paid Carries red. + Mark Low-Class levels orange. + Mark groups you can't join dark red. + Mark groups without your current classes green. -+ Added shortcuts for **Party commands** and smart **tab complete**. - CalMWolfs - + /pw -> party warp - + /pk -> party kick - + /pt -> party transfer - + /pp -> party promote - + /pko -> party kickoffline + Added working **Livid Finder** (should work 100% of the time). - hannibal2 + Option to hide other/wrong/fake Livids (try this out and see if you really want this, it can be counter-productive in some cases). -+ Added AFK time to Discord RPC. - NetheriteMiner -+ Option to highlight items that are full in the sack inventory. + +#### Garden + ++ Added /shmouselock command to lock mouse rotation for farming. - Cad ++ Added Highlight Visitors in SkyBlock. - nea + + Highlights Visitors outside the Garden. ++ Block Interacting with Visitors. - nea + + Blocks you from interacting with / unlocking Visitors to allow for Dedication Cycling. ++ Added Auto-Detection of Expired Pumpkin farming fortune. - CalMWolfs #### Events @@ -74,6 +351,32 @@ + Help with the 2023 Halloween visitor challenge (ephemeral dingsibumsi or something) - nea + New Visitor Ping: Pings you when you are less than 10 seconds away from getting a new visitor. + Accept Hotkey: Accept a visitor when you press this keybind while in the visitor GUI. ++ Added support for showing the Primal Fear data from tab list as GUI elements. - Erymanthus ++ Play warning sound when the next Primal Fear can spawn. - thunderblade73 + +#### Commands + ++ Added shortcuts for **Party commands** and smart **tab complete**. - CalMWolfs + + /pw -> party warp + + /pk -> party kick + + /pt -> party transfer + + /pp -> party promote + + /pko -> party kickoffline ++ Added the option to change Hypixel Wiki to the fandom Wiki in more areas than just the /wiki command. - Erymanthus + + E.g. inside the SkyBlock leveling guide. ++ Added command **/shpumpkin** to toggle include/exclude Expired Pumpkin farming fortune in the /ff GUI and in the true + ff + display. - CalMWolfs + +#### Misc + ++ Added Kick Duration. - hannibal2 + + Show in the Hypixel lobby since when you were last kicked from SkyBlock. + + Useful if you get blocked because of 'You were kicked while joining that server!'. + + Send a warning and sound after a custom amount of seconds. ++ Added Time In Limbo. - hannibal2 + + Show the time since you entered limbo. + + Show a chat message for how long you were in limbo once you leave it. ### Changes @@ -84,8 +387,8 @@ + Made Fatal Tempo same as Chimera in Estimated Item Value. - jani + Added debug options for fishing hook display. - hannibal2 + This should help find values that the fishing hook display works 100% with. -+ Changed the color for the tab list Special Persons Mark. -+ Mark SkyHanni Devs in the tab list special. ++ Changed the color for the tab list Special Persons Mark. - hannibal2 ++ Mark SkyHanni Devs in the tab list special. - hannibal2 + Added buttons to change the format of the price and the number in the sack display. - HiZe + Made Smoldering same as Fatal Tempo and Chimera in Estimated Item Value. - jani + Added an option to change where to get the items from in the composter overlay: from the bazaar or from sacks. - HiZe @@ -110,7 +413,44 @@ + Only items with recipes are tab completed. + Added option to set the size of highlighted motes orbs in rift and make them smaller by default. - cimbraien + Disabled clicks on SkyHanni GUIs while inside NEU's or Skytils profile viewer. - hannibal2 -+ Removed armor stand checks for Trevor Solver. This fixes or nerfs the feature to not highlight mobs behind blocks sometimes. - hannibal2 ++ Removed armor stand checks for Trevor Solver. This fixes or nerfs the feature to not highlight mobs behind blocks + sometimes. - hannibal2 ++ Added diamond and gold essence support to PowderTracker. - walker ++ Change the fandom wiki search engine (under the /wiki command) from Google to the fandom wiki's built-in search + engine - Erymanthus ++ Added option to hide Chest Value while the Estimated Item Value display is showing. - hannibal2 ++ No longer merging same items with different prices in Chest Value together. - hannibal2 ++ Adding Great Spook support for Non God Pot Effect display. - hannibal2 ++ Added a title warning to the Worm Cap Alert ping sound. - Vahvl ++ Added support for detecting refreshed farming fortune century cake effect. - alexia ++ Show key to press below burrow warp. - hannibal2 ++ Makes the Compact Potion message open the Potion effects menu on click. - jani ++ Added option to show King Talisman Helper outside Dwarven Mines. - hannibal2 ++ In-Game Date: Adds support for reading the in-game scoreboard, and also allow sun/moon symbol customization. - + Erymanthus ++ Added Estimated Item Value support to NEU Profile Viewer - hannibal2 ++ Added support to import SBE Visual Words into SkyHanni. - HiZe ++ Add custom keybinds for Harp Helper. - Thunderblade73 ++ Show the custom hotkey name in the Harp inventory. - hannibal2 ++ Added a GUI element to remind you while /shmouselock is enabled. - CalMWolfs ++ Make Crimson Isle Quest Item Helper only get amount needed. - NetheriteMiner ++ Change config order to alphabetical. - walker ++ Added commands /shresetpowdertracker and /shresetdicertracker to reset the Powder Tracker and Dicer Drop Tracker - + hannibal2 ++ Added current session/total session switch for Dicer Drop Tracker. - hannibal2 ++ Added a button to reset the local session for Dicer Drop Tracker and for Powder Tracker. - hannibal2 ++ Added more features for Ender Node Tracker and Armor Drop Tracker. - hannibal2 + + Added session/display mode support, added a button to reset the current session, and added the commands + /shresetendernodetracker and /shresetarmordroptracker to reset the full data. ++ Added support for different current sessions per profile for all new trackers: Ender Node, Armor Drop, Dicer Drop, + Powder and Slayer Profit Tracker ++ Added the option to change the Blaze Slayer Dagger GUI positions. - hannibal2 ++ Added more features to the Frozen Treasure Tracker. - hannibal2 + + Added session/display mode support, added a button to reset the current session, and added the commands + /shresetfrozentreasuretracker to reset the full data. ++ Added Slayer Profit Tracker support for loot from area mini-bosses. - hannibal2 ++ No longer opening the empty /shdefaultoptions GUI. - walker ++ Added the SkyHanni icon and a link to the GitHub page for MC launchers like Prism to display. - hannibal2 ### Bug Fixes @@ -160,6 +500,51 @@ + Fixed Farming Weight Display shows 0 weight wrongly sometimes. - Kaeso + Fixed damage indicator errors during Enderman Slayer. - hannibal2 + Fixed weird error messages in the Damage Indicator. - hannibal2 ++ Fixed Enderman Slayer errors again. - hannibal2 ++ Fixed the Sack Display error again. - HiZe ++ Fixed the attribute Vitality getting wrongly labeled as Mending on attribute shards. - hannibal2 ++ Made Livid Solver great again. - hannibal2 ++ Fixed Damage Indicator in Dungeons for some floors. - hannibal2 ++ Fixed Damage Indicator "hide nametag" feature works even for disabled mobs. - hannibal2 ++ Fixed item rarity detection for pets. - hannibal2 ++ Fixed rare error message while disconnecting. - Thunderblade73 ++ Disabled the Daily Quest part of the Reputation Helper during the great spook. - hannibal2 ++ Fixed Diana warp key not working. - hannibal2 ++ SkyHanni Keybinds no longer work inside SkyHanni config. - hannibal2 ++ Fixed Great Spook potion not working in Non God Pot Effect feature. - jani ++ Fixed wrong Rhys (Deep Caverns NPC) items needed for Dwarven Mines unlock in Bingo Step Helper. - ReyMaratov ++ Fixed King Talisman Helper once again. - hannibal2 ++ Made the ESC -> Mod Options -> SkyHanni -> Config button not crash you. - hannibal2 ++ Disabled Diana Warp key and Inquis Share key while inside any GUI. - hannibal2 ++ Removed Diana warp data on world switch. - hannibal2 ++ Reset mouse sensitivity back to 100% if you log off with lock mouse look enabled. - hannibal2 ++ Fixed mouse sensitivity stuck after restarting by storing old sensitivity. - CalMWolfs ++ Fixed tool fortune. - CalMWolfs ++ Fixed Item Ability Cooldown display not activating for Sword of Bad Health. - hannibal2 ++ Fixed the crop name gets replaced to internal name in /shwords. - hannibal2 ++ Show obfuscated fish as bait instead of caught item. - cimbraien ++ Fixed Estimated Item Value that renders twice inside NEU PV, by not rendering anything when the cursor is exactly in + between two items. - hannibal2 ++ fixed more error messages with The Great Spook data getting stored in the Reputation Helper quest config + accidentally. - hannibal2 ++ Hopefully fixed resets of Visitor Drops stats. - hannibal2 ++ Fixed typo in The Art Of Peace. - walker ++ Fixed compatibility problems with ChatTriggers that caused flickering in the Estimated Item Value while inside the NEU + Profile Viewer. - hannibal2 ++ Fixed Quest Item Helper showing negative numbers. - hannibal2 ++ Fixed YouTuber and Admin ranks getting lost in the tab list. - walker ++ Added a cooldown to the current session tracker reset button to fix the chat spam. - hannibal2 ++ Changed the color of the "Slayer boss soon!" warning from red to yellow. - hannibal2 ++ Fixed a bug where some items were counted twice in the Slayer Profit Tracker. - hannibal2 ++ Fixed item rarity errors in the museum. - hannibal2 ++ Fixed mob highlighting problems with Blaze Slayer and Skytils. - hannibal2 ++ Pablo Helper: Fixed some messages not showing the "get from sack" clickable message. - hannibal2 ++ Fixed scoreboard date number suffixes are missing sometimes. - Erymanthus ++ Fixed the leftStronghold area not getting detected. - hannibal2 ++ Fixed error message with Ashfang Blazes. - hannibal2 ++ Fixed crash with pet exp tooltip. - hannibal2 ++ Fixed dungeoneering showing as 0 in the skill menu. - hannibal2 ++ Fixed showing minion level as 101 in some menus. - hannibal2 #### Config @@ -171,12 +556,47 @@ + Removed **Duplicate Hider**. + Hypixel now fixed the bug themselves and hides duplicate farming contests in the Jacob inventory. -#### Internal Changes +#### Technical Details + Add Repo TODOs to regex patterns. - walker + Moved many patterns from function scope to members. - hannibal2 + Avoid hardcoded dispatcher. - walker + Created and used Entity.canBeSeen and LorenzVec.canBeSeen. - hannibal2 ++ Reducing cognitive complexity in StatsTuning.kt - walker ++ Reducing indentations and line counts in StatsTuning.kt - hannibal2 ++ Mark functions around item utils and neu items as deprecated. - walker ++ Added debug command /shconfigmanagerreset. - hannibal2 ++ Reloads the config manager and rendering processors of MoulConfig. This WILL RESET your config, but also update the + java config files (names, description, orderings and stuff). ++ Adding 100 lines to MobFinder.kt and making it better readable in the process. - walker ++ Making ChatFiler.kt way better, storing regex objects for reuse and preparing future repo support. - walker ++ Added command /shkingfix to reset the internal King Talisman Helper offset. - hannibal2 ++ Updated dependency version of junixsocket in DiscordIPC so that antivirus websites no longer show false positives. - + NetheriteMiner ++ Changed wrong/missing neu version message to show NEU version 2.1.1-Pre-4 instead of beta versions. - CalMWolfs ++ Deleting the old "hidden" part of the config. - hannibal2 ++ This will reset parts of the config for users with 7-month-old SkyHanni versions that want to migrate into the + present. ++ Added a workaround for the NEU Profile Viewer bug where the ItemTooltipEvent gets called for two items when hovering + over the border between two items. - hannibal2 ++ Using visitorDrops.visitorRarities directly from the config instead of accessing the local field. Hopefully this will + prevent partial config resets in the future. - hannibal2 ++ Added a tracker API that can be used for all features in SkyHanni that currently track stuff that the user collects. - + hannibal2 ++ Added the slayer profit tracker logic (command to reset, toggle between total view and session view, and button to + delete session) to powder tracker and Dicer Drop Tracker. - hannibal2 ++ Added support for migrating parts of the player or session storage. - nea ++ Changed the config format for dicerRngDrops/dicerDropsTracker. - hannibal2 ++ Created SkyHanniTracker, the core API for working with tracker stuff. This should be used everywhere someday in the + future. - hannibal2 ++ Used SkyHanniTracker in FrozenTreasureTracker. - hannibal2 ++ Added /shdebugwaypoint as a test/debug command. - hannibal2 ++ Added debug messages to detect hot swaps. - hannibal2 ++ Added /shdebugtablist ++ Set your clipboard as a fake tab list. - hannibal2 ++ /shversion now copies the SkyHanni version into the clipboard as well. - hannibal2 ++ Moved location fixes to the repo. - hannibal2 ++ Added debug information for PetExpTooltip crash. - hannibal2 ## Version 0.20 @@ -222,8 +642,6 @@ + Option to send local contest data to elitebot.dev at the start of the new SkyBlock year. + Added SkyHanni **Installer** - NetheriteMiner + Double-clicking the mod jar file will open a window that asks you where to move the mod into. -+ Added Chat **Translator** - NetheriteMiner - + After enabling, click on any chat message sent by another player to translate it to English. + Show the progress bar until maxed crop milestone in the crop milestone inventory. - hannibal2 + Show a line to the enderman slayer beacon. - hannibal2 + Added **Default Option Settings:** - nea @@ -658,7 +1076,7 @@ ### Fixes + Fixed Pocket Sack-In-A-Sack Replace in lore -+ Fixed possible crash with broken neu repo when opening the desk inventory in garden (Contributed by CalMWolfs) ++ Fixed possible crash with broken neu repo when opening the desk inventory in the garden (Contributed by CalMWolfs) + Fixed frozen treasures per hour display being inaccurate (Contributed by CalMWolfs) + Fixed bug with ghost counter sometimes not detecting new kills (Contributed by CalMWolfs) + Fixed **Ghost Counter** - HiZe & ksipli @@ -971,7 +1389,7 @@ and show a preview how these stats change when hovering over an upgrade + Hide crop money display, crop milestone display and garden visitor list while inside anita show, SkyMart or the composter inventory -+ Hide chat messages from the visitors in garden. (Except Beth and Spaceman) ++ Hide chat messages from the visitors in the garden. (Except Beth and Spaceman) + Introduced a new command '/shcroptime ' that displays the estimated time it will take to gather the requested quantity of a particular item based on the current crop speed. + Show the average crop milestone in the crop milestone inventory. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 50fb6b668ecf..fb5a7e1e6c30 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -56,7 +56,7 @@ You can write in the description of the pr the wording for the changelog as well - All new classes should be written in Kotlin, with a few exceptions: - Config files in `at.hannibal2.skyhanni.config.features` - Mixin classes in `at.hannibal2.skyhanni.mixins.transformers` - - Java classes that represent JSON data objects in `at.hannibal2.skyhanni.utils.jsonobjects` + - Java classes that represent JSON data objects in `at.hannibal2.skyhanni.data.jsonobjects` - Please use the existing event system, or expand on it. Do not use Forge events. - (We inject the calls with Mixin) - Please use existing utils methods. @@ -125,13 +125,14 @@ SkyHanni uses a repo system to easily change static variables without the need f The repo is located at https://github.com/hannibal002/SkyHanni-REPO. A copy of all json files is stored on the computer under `.minecraft\config\skyhanni\repo`. On every game start, the copy gets updated (if outdated and if not manually disabled). -If you add stuff to the repo make sure it gets serialised. See the [jsonobjects](src/main/java/at/hannibal2/skyhanni/utils/jsonobjects) +If you add stuff to the repo make sure it gets serialised. See +the [jsonobjects](src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo) folder for how to properly do this. You also may have to disable repo auto update in game. ### Discord IPC DiscordIPC is a service that SkyHanni uses to send information from SkyBlock to Discord in Rich Presence.
-Specifically, we use [TirelessTraveler's Fork](https://github.com/ILikePlayingGames/DiscordIPC) of a fork of a fork of +Specifically, we use [NetheriteMiner's Fork](https://github.com/NetheriteMiner/DiscordIPC) of a fork of a fork of a fork of the [original](https://github.com/jagrosh/DiscordIPC). For info on usage, look at [DiscordRPCManager.kt](https://github.com/hannibal002/SkyHanni/blob/beta/src/main/java/at/hannibal2/skyhanni/features/misc/discordrpc/DiscordRPCManager.kt) diff --git a/FEATURES.md b/FEATURES.md index 6c0d616d9371..5cdb25031eee 100644 --- a/FEATURES.md +++ b/FEATURES.md @@ -28,6 +28,7 @@ Use `/sh` or `/skyhanni` to open the SkyHanni config in game. + Will not break with emblems. + Optional if left or right side of name. + Should not break with other mods. ++ Hide the repeating fire sale reminder chat messages. - hannibal2 #### Chat Filter @@ -174,6 +175,7 @@ Use `/sh` or `/skyhanni` to open the SkyHanni config in game. - Minion name display with minion tier. - **Minion Craft Helper** - Show how many more items you need to upgrade the minion in your inventory. Especially useful for bingo. ++ Shows how much skill experience you will get when picking up items from the minion storage. - Thunderblade73
@@ -224,6 +226,10 @@ Use `/sh` or `/skyhanni` to open the SkyHanni config in game. + Display the Hypixel timer until the fishing hook can be pulled out of the water/lava, only bigger and on your screen. + Alerts when the player catches a Legendary Sea Creature. - Cad ++ **Fishing Bait Warnings.** - cimbraien + + Option to warn when no bait is used. + + Option to warn when used bait is changed. +
@@ -241,6 +247,7 @@ Use `/sh` or `/skyhanni` to open the SkyHanni config in game. - Option to show the health of Voidgloom Seraph 4 during the laser phase (useful when trying to phase skip) - Show when Revenant Horror 5 is about to BOOM. - Hide the vanilla nametag of damage indicator bosses. +- Garden Pests in Damage Indicator - **Time to Kill** - Show the time it takes to kill the Slayer boss. @@ -335,6 +342,9 @@ Use `/sh` or `/skyhanni` to open the SkyHanni config in game. + Shortens chat messages about skill level ups, collection gains and new area discoveries while on bingo. + Bingo Card ++ Show the duration until the next hidden bingo goal tip gets revealed. - hannibal2 ++ Support for tips in hidden bingo card display. - hannibal2 ++ Support for 'found by' info in bingo card. - hannibal2
@@ -436,7 +446,7 @@ Use `/sh` or `/skyhanni` to open the SkyHanni config in game. is empty when fully filled and show a preview how these stats change when hovering over an upgrade + Hide crop money display, crop milestone display and garden visitor list while inside anita show, SkyMart or the composter inventory -+ Hide chat messages from the visitors in garden. (Except Beth and Spaceman) ++ Hide chat messages from the visitors in the garden. (Except Beth, Jacob and Spaceman) + Show the average crop milestone in the crop milestone inventory. + **FF for Contest** - Show the minimum needed Farming Fortune for reaching a medal in the Jacob's Farming Contest inventory. @@ -480,6 +490,40 @@ Use `/sh` or `/skyhanni` to open the SkyHanni config in game. + **Visual garden plot borders** - VixidDev + Press F3 + G to enable/disable the view. + /shmouselock command to lock mouse rotation for farming. - Cad ++ Added Highlight Visitors in SkyBlock. - nea + + Highlights Visitors outside the Garden. ++ Block Interacting with Visitors. - nea + + Blocks you from interacting with / unlocking Visitors to allow for Dedication Cycling. ++ Wrong crop milestone step detection. - hannibal2 + + When opening the crop milestone menu, a chat message is sent if Hypixel's crops per milestone level data is + different from SkyHanni's. + + You can use this to share your hypixel data with SkyHanni via the discord. + + This will allow us to fix the crop milestone features quicker, as we currently do not have accurate data for this. + + If you don't want to share anything, you can disable the chat message in the config with /sh copy milestone data. ++ Garden Vacuum Pests in Pest bag to item number as stack size. - hannibal2 + + Enable via /sh vacuum. + +### Garden Pests + ++ Added Garden Vacuum Pests in Pest bag to item number as stack size. - hannibal2 + + Enable via /sh vacuum. ++ Added Pests to Damage Indicator. - hannibal2 + + Enable Damage Indicator and select Garden Pests. ++ Change how the pest spawn chat message should be formatted. - hannibal2 + + Unchanged, compact or hide the message entirely. ++ Show a Title when a pest spawns. - hannibal2 ++ Show the time since the last pest spawned in your garden. - hannibal2 + + Option to only show the time while holding vacuum in the hand. ++ Show the pests that are attracted when changing the selected material of the Sprayanator. - hannibal2 ++ Added Garden only commands /home, /barn and /tp, and hotkeys. - hannibal2 ++ Showing a better plot name in the scoreboard. Updates faster and doesn't hide when pests are spawned. - hannibal2 ++ Show a display with all known pest locations. - hannibal2 + + Click to warp to the plot. + + Option to only show the time while holding vacuum in the hand. ++ Mark the plots with pests on them in the world. - hannibal2 ++ Press the key to warp to the nearest plot with pests on it. - hannibal2 ++ Draw plot borders when holding the Sprayonator. - HiZe +
@@ -582,6 +626,15 @@ Use `/sh` or `/skyhanni` to open the SkyHanni config in game. + Help with the 2023 Halloween visitor challenge (ephemeral dingsibumsi or something) - nea + New Visitor Ping: Pings you when you are less than 10 seconds away from getting a new visitor. + Accept Hotkey: Accept a visitor when you press this keybind while in the visitor GUI. ++ Added support for showing the primal fear data from tab list as GUI elements. - Erymanthus ++ Play warning sound when the next Primal Fear can spawn. - thunderblade73 ++ Unique Gifting Opportunities. - nea + + Highlight players who you haven't given gifts to yet. + + Only highlight ungifted players while holding a gift. + + Make use of armor stands to stop highlighting players. This is a bit inaccurate, but it can help with people you gifted before this feature was used. ++ Unique Gifted users counter. - hannibal2 + + Show in a display how many unique players you have given gifts to in the winter 2023 event. + + Run command /opengenerowmenu to sync up.
@@ -624,6 +677,8 @@ Use `/sh` or `/skyhanni` to open the SkyHanni config in game. + Quest Item Helper. (Crimson Isle) - NetheriteMiner + When you open the fetch item quest in the town board, it shows a clickable chat message that will grab the items needed from the sacks. ++ Crimson Isle **Pablo NPC Helper**. - NetheriteMiner + + Similar to Quest Item Helper, shows a clickable message that grabs the flower needed from sacks. + Red Scoreboard Numbers - Hides the red numbers in the scoreboard sidebar on the right side of the screen. + **Tia Relay Waypoint** - Show the next Relay waypoint for Tia The Fairy, where maintenance for the abiphone network needs to be done. @@ -774,6 +829,8 @@ Use `/sh` or `/skyhanni` to open the SkyHanni config in game. + Option to hide other/wrong/fake Livids (try this out and see if you really want this, it can be counter-productive in some cases). + Added AFK time to Discord RPC. - NetheriteMiner ++ Added the option to change Hypixel Wiki to the fandom Wiki in more areas than just the /wiki command. - Erymanthus + + E.g. inside the SkyBlock leveling guide.
@@ -783,4 +840,8 @@ Use `/sh` or `/skyhanni` to open the SkyHanni config in game. + **Following Line** - hannibal2 + Draws a colored line behind the player. + Change the color, width, and duration of the line. ++ **Arrow Trail cosmetic** - Thunderblade73 + + Draw a colored line behind the arrows in the air. + + Options to change the color of the line, to only show own arrows or every arrow, to have own arrows in a different + color, to change the time alive, and the line width.
diff --git a/README.md b/README.md index b026a076a0f9..6e1c95c8e83a 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,5 @@ + +

SkyHanni: Mod for Hypixel SkyBlock

@@ -11,7 +13,7 @@ SkyHanni is a Forge mod for Minecraft 1.8.9. It adds many features to Hypixel SkyBlock. The mod is filled with GUIs, extra chat messages, reminders, message hiders and entity highlighters. -The majority of these features are centered on the Garden, Slayer, Bingo, Diana, and Rift. +The majority of these features are centered in the Garden, Slayer, Bingo, Diana, and Rift. We have a [tutorial](https://github.com/hannibal002/SkyHanni/blob/beta/INSTALLING.md) for how to download and install the mod. @@ -24,4 +26,6 @@ For bug reports, feature requests, and other feedback, please visit our [Discord](https://discord.gg/skyhanni-997079228510117908). If you are interested in the technical side of SkyHanni, read -the [Contributing Guide](https://github.com/hannibal002/SkyHanni/blob/beta/CONTRIBUTING.md). \ No newline at end of file +the [Contributing Guide](https://github.com/hannibal002/SkyHanni/blob/beta/CONTRIBUTING.md). + +*Check out some other really cool 1.8.9 mods [here](https://sbmw.ca/mod-lists/skyblock-mod-list/)* diff --git a/build.gradle.kts b/build.gradle.kts index 992a12cd0d11..b240eb319b50 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -11,7 +11,7 @@ plugins { } group = "at.hannibal2.skyhanni" -version = "0.21.Beta.13" +version = "0.22.Beta.6" // Toolchains: java { @@ -57,7 +57,7 @@ dependencies { forge("net.minecraftforge:forge:1.8.9-11.15.1.2318-1.8.9") // Discord RPC client - shadowImpl("com.github.ILikePlayingGames:DiscordIPC:f91ed4b") { + shadowImpl("com.github.NetheriteMiner:DiscordIPC:3106be5") { exclude(module = "log4j") because("Different version conflicts with Minecraft's Log4J") exclude(module = "gson") @@ -81,18 +81,20 @@ dependencies { exclude(module = "unspecified") isTransitive = false } - devenvMod("com.github.NotEnoughUpdates:NotEnoughUpdates:v2.1.1-alpha22:all") { + devenvMod("com.github.NotEnoughUpdates:NotEnoughUpdates:v2.1.1-pre4:all") { exclude(module = "unspecified") isTransitive = false } shadowModImpl(libs.moulconfig) - devenvMod(variantOf(libs.moulconfig) { classifier("test") }) - shadowImpl(libs.libautoupdate) shadowImpl("org.jetbrains.kotlin:kotlin-reflect:1.9.0") // testImplementation(kotlin("test")) + testImplementation("com.github.NotEnoughUpdates:NotEnoughUpdates:v2.1.1-pre4:all") { + exclude(module = "unspecified") + isTransitive = false + } testImplementation("org.junit.jupiter:junit-jupiter:5.10.0") testImplementation("io.mockk:mockk:1.12.5") } @@ -120,6 +122,7 @@ loom { property("mixin.debug", "true") property("asmhelper.verbose", "true") arg("--tweakClass", "org.spongepowered.asm.launch.MixinTweaker") + arg("--tweakClass", "io.github.moulberry.moulconfig.tweaker.DevelopmentResourceTweaker") arg("--mods", devenvMod.resolve().joinToString(",") { it.relativeTo(file("run")).path }) } } @@ -184,7 +187,7 @@ tasks.shadowJar { } } exclude("META-INF/versions/**") - + mergeServiceFiles() relocate("io.github.moulberry.moulconfig", "at.hannibal2.skyhanni.deps.moulconfig") relocate("moe.nea.libautoupdate", "at.hannibal2.skyhanni.deps.libautoupdate") } diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index fe51b0357ef6..e29f8e72b1d7 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -1,7 +1,7 @@ [versions] libautoupdate = "1.0.3" -moulconfig = "1.3.0" +moulconfig = "2.5.0" [libraries] -moulconfig = { module = "org.notenoughupdates.moulconfig:MoulConfig", version.ref = "moulconfig" } +moulconfig = { module = "org.notenoughupdates.moulconfig:legacy", version.ref = "moulconfig" } libautoupdate = { module = "moe.nea:libautoupdate", version.ref = "libautoupdate" } diff --git a/src/main/java/SkyHanniInstallerFrame.java b/src/main/java/SkyHanniInstallerFrame.java index fa8868254b12..a9584dedfe31 100644 --- a/src/main/java/SkyHanniInstallerFrame.java +++ b/src/main/java/SkyHanniInstallerFrame.java @@ -166,8 +166,8 @@ private JLabel getPictureLabel() { margin = 5; BufferedImage myPicture = ImageIO.read(Objects.requireNonNull(getClass() - .getClassLoader() - .getResourceAsStream("assets/skyhanni/logo.png"), "Logo not found.")); + .getClassLoader() + .getResourceAsStream("assets/skyhanni/logo.png"), "Logo not found.")); Image scaled = myPicture.getScaledInstance(w - margin * 2, h - margin, Image.SCALE_SMOOTH); logo = new JLabel(new ImageIcon(scaled)); logo.setName("Logo"); @@ -222,8 +222,8 @@ private JTextArea getTextArea() { descriptionText.setOpaque(false); descriptionText.setPreferredSize(new Dimension(w - margin * 2, h - margin)); descriptionText.setText( - "This installer will copy SkyHanni into your forge mods folder for you, and replace any old versions that already exist. " + - "Close this if you prefer to do this yourself!"); + "This installer will copy SkyHanni into your forge mods folder for you, and replace any old versions that already exist. " + + "Close this if you prefer to do this yourself!"); descriptionText.setWrapStyleWord(true); y += h; @@ -251,7 +251,7 @@ private JTextArea getForgeTextArea() { forgeDescriptionText.setOpaque(false); forgeDescriptionText.setPreferredSize(new Dimension(w - margin * 2, h - margin)); forgeDescriptionText.setText( - "However, you still need to install Forge client in order to be able to run this mod. Click here to visit the download page for Forge 1.8.9!"); + "However, you still need to install Forge client in order to be able to run this mod. Click here to visit the download page for Forge 1.8.9!"); forgeDescriptionText.setForeground(Color.BLUE.darker()); forgeDescriptionText.setCursor(Cursor.getPredefinedCursor(Cursor.HAND_CURSOR)); forgeDescriptionText.setWrapStyleWord(true); @@ -315,8 +315,8 @@ private JButton getButtonFolder() { try { BufferedImage myPicture = ImageIO.read(Objects.requireNonNull(getClass() - .getClassLoader() - .getResourceAsStream("assets/skyhanni/folder.png"), "Folder icon not found.")); + .getClassLoader() + .getResourceAsStream("assets/skyhanni/folder.png"), "Folder icon not found.")); Image scaled = myPicture.getScaledInstance(w - 8, h - 6, Image.SCALE_SMOOTH); buttonChooseFolder = new JButton(new ImageIcon(scaled)); buttonChooseFolder.setName("ButtonFolder"); @@ -430,7 +430,7 @@ public void mouseClicked(MouseEvent e) { if (e.getSource() == getForgeTextArea()) { try { Desktop.getDesktop().browse(new URI( - "http://files.minecraftforge.net/maven/net/minecraftforge/forge/index_1.8.9.html")); + "http://files.minecraftforge.net/maven/net/minecraftforge/forge/index_1.8.9.html")); } catch (IOException | URISyntaxException ex) { showErrorPopup(ex); } @@ -519,10 +519,10 @@ private boolean findSkyHanniAndDelete(File[] files) { } catch (Exception ex) { ex.printStackTrace(); showErrorMessage("Was not able to delete the other SkyHanni files found in your mods folder!" + - System.lineSeparator() + - "Please make sure that your minecraft is currently closed and try again, or feel" + - System.lineSeparator() + - "free to open your mods folder and delete those files manually."); + System.lineSeparator() + + "Please make sure that your minecraft is currently closed and try again, or feel" + + System.lineSeparator() + + "free to open your mods folder and delete those files manually."); return true; } continue; @@ -667,10 +667,10 @@ private String getModIDFromInputStream(InputStream inputStream) { private File getThisFile() { try { return new File(SkyHanniInstallerFrame.class - .getProtectionDomain() - .getCodeSource() - .getLocation() - .toURI()); + .getProtectionDomain() + .getCodeSource() + .getLocation() + .toURI()); } catch (URISyntaxException ex) { showErrorPopup(ex); } @@ -700,4 +700,4 @@ public enum OperatingSystem { MACOS, UNKNOWN } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/SkyHanniMod.kt b/src/main/java/at/hannibal2/skyhanni/SkyHanniMod.kt index 7002ff0f53de..b4eb8593cc5f 100644 --- a/src/main/java/at/hannibal2/skyhanni/SkyHanniMod.kt +++ b/src/main/java/at/hannibal2/skyhanni/SkyHanniMod.kt @@ -1,12 +1,13 @@ package at.hannibal2.skyhanni import at.hannibal2.skyhanni.api.CollectionAPI +import at.hannibal2.skyhanni.api.DataWatcherAPI +import at.hannibal2.skyhanni.config.ConfigFileType import at.hannibal2.skyhanni.config.ConfigManager import at.hannibal2.skyhanni.config.Features import at.hannibal2.skyhanni.config.SackData import at.hannibal2.skyhanni.config.commands.Commands.init import at.hannibal2.skyhanni.data.ActionBarStatsData -import at.hannibal2.skyhanni.data.BingoAPI import at.hannibal2.skyhanni.data.BlockData import at.hannibal2.skyhanni.data.ChatManager import at.hannibal2.skyhanni.data.CropAccessoryData @@ -15,13 +16,16 @@ import at.hannibal2.skyhanni.data.EntityMovementData import at.hannibal2.skyhanni.data.FriendAPI import at.hannibal2.skyhanni.data.GardenComposterUpgradesData import at.hannibal2.skyhanni.data.GardenCropMilestones +import at.hannibal2.skyhanni.data.GardenCropMilestonesCommunityFix import at.hannibal2.skyhanni.data.GardenCropUpgrades import at.hannibal2.skyhanni.data.GuiEditManager import at.hannibal2.skyhanni.data.GuildAPI import at.hannibal2.skyhanni.data.HypixelData +import at.hannibal2.skyhanni.data.ItemAddManager import at.hannibal2.skyhanni.data.ItemClickData import at.hannibal2.skyhanni.data.ItemRenderBackground import at.hannibal2.skyhanni.data.ItemTipHelper +import at.hannibal2.skyhanni.data.LocationFixData import at.hannibal2.skyhanni.data.MayorElection import at.hannibal2.skyhanni.data.MinecraftData import at.hannibal2.skyhanni.data.OtherInventoryData @@ -37,6 +41,9 @@ import at.hannibal2.skyhanni.data.SlayerAPI import at.hannibal2.skyhanni.data.TitleData import at.hannibal2.skyhanni.data.TitleManager import at.hannibal2.skyhanni.data.ToolTipData +import at.hannibal2.skyhanni.data.jsonobjects.local.FriendsJson +import at.hannibal2.skyhanni.data.jsonobjects.local.JacobContestsJson +import at.hannibal2.skyhanni.data.jsonobjects.local.KnownFeaturesJson import at.hannibal2.skyhanni.data.repo.RepoManager import at.hannibal2.skyhanni.events.LorenzTickEvent import at.hannibal2.skyhanni.features.anvil.AnvilCombineHelper @@ -45,6 +52,7 @@ import at.hannibal2.skyhanni.features.bazaar.BazaarBestSellMethod import at.hannibal2.skyhanni.features.bazaar.BazaarCancelledBuyOrderClipboard import at.hannibal2.skyhanni.features.bazaar.BazaarOpenPriceWebsite import at.hannibal2.skyhanni.features.bazaar.BazaarOrderHelper +import at.hannibal2.skyhanni.features.bingo.BingoAPI import at.hannibal2.skyhanni.features.bingo.BingoCardDisplay import at.hannibal2.skyhanni.features.bingo.BingoCardTips import at.hannibal2.skyhanni.features.bingo.BingoNextStepHelper @@ -55,6 +63,7 @@ import at.hannibal2.skyhanni.features.chat.ChatFilter import at.hannibal2.skyhanni.features.chat.CompactBestiaryChatMessage import at.hannibal2.skyhanni.features.chat.CompactSplashPotionMessage import at.hannibal2.skyhanni.features.chat.PlayerDeathMessages +import at.hannibal2.skyhanni.features.chat.Translator import at.hannibal2.skyhanni.features.chat.WatchdogHider import at.hannibal2.skyhanni.features.chat.playerchat.PlayerChatFilter import at.hannibal2.skyhanni.features.chat.playerchat.PlayerChatModifier @@ -75,6 +84,7 @@ import at.hannibal2.skyhanni.features.commands.WikiManager import at.hannibal2.skyhanni.features.commands.tabcomplete.GetFromSacksTabComplete import at.hannibal2.skyhanni.features.commands.tabcomplete.PlayerTabComplete import at.hannibal2.skyhanni.features.commands.tabcomplete.WarpTabComplete +import at.hannibal2.skyhanni.features.cosmetics.ArrowTrail import at.hannibal2.skyhanni.features.cosmetics.CosmeticFollowingLine import at.hannibal2.skyhanni.features.dungeon.CroesusUnopenedChestTracker import at.hannibal2.skyhanni.features.dungeon.DungeonAPI @@ -92,6 +102,7 @@ import at.hannibal2.skyhanni.features.dungeon.DungeonMilestonesDisplay import at.hannibal2.skyhanni.features.dungeon.DungeonRankTabListColor import at.hannibal2.skyhanni.features.dungeon.DungeonTeammateOutlines import at.hannibal2.skyhanni.features.dungeon.HighlightDungeonDeathmite +import at.hannibal2.skyhanni.features.event.UniqueGiftingOpportunitiesFeatures import at.hannibal2.skyhanni.features.event.diana.BurrowWarpHelper import at.hannibal2.skyhanni.features.event.diana.GriffinBurrowHelper import at.hannibal2.skyhanni.features.event.diana.GriffinBurrowParticleFinder @@ -100,9 +111,13 @@ import at.hannibal2.skyhanni.features.event.diana.InquisitorWaypointShare import at.hannibal2.skyhanni.features.event.diana.SoopyGuessBurrow import at.hannibal2.skyhanni.features.event.jerry.HighlightJerries import at.hannibal2.skyhanni.features.event.jerry.frozentreasure.FrozenTreasureTracker +import at.hannibal2.skyhanni.features.event.spook.TheGreatSpook +import at.hannibal2.skyhanni.features.event.winter.UniqueGiftCounter import at.hannibal2.skyhanni.features.fame.AccountUpgradeReminder import at.hannibal2.skyhanni.features.fame.CityProjectFeatures import at.hannibal2.skyhanni.features.fishing.ChumBucketHider +import at.hannibal2.skyhanni.features.fishing.FishingAPI +import at.hannibal2.skyhanni.features.fishing.FishingBaitWarnings import at.hannibal2.skyhanni.features.fishing.FishingHookDisplay import at.hannibal2.skyhanni.features.fishing.FishingTimer import at.hannibal2.skyhanni.features.fishing.SeaCreatureFeatures @@ -111,6 +126,9 @@ import at.hannibal2.skyhanni.features.fishing.SeaCreatureMessageShortener import at.hannibal2.skyhanni.features.fishing.SharkFishCounter import at.hannibal2.skyhanni.features.fishing.ShowFishingItemName import at.hannibal2.skyhanni.features.fishing.ThunderSparksHighlight +import at.hannibal2.skyhanni.features.fishing.tracker.FishingProfitPlayerMoving +import at.hannibal2.skyhanni.features.fishing.tracker.FishingProfitTracker +import at.hannibal2.skyhanni.features.fishing.tracker.FishingTrackerCategoryManager import at.hannibal2.skyhanni.features.fishing.trophy.OdgerWaypoint import at.hannibal2.skyhanni.features.fishing.trophy.TrophyFishFillet import at.hannibal2.skyhanni.features.fishing.trophy.TrophyFishManager @@ -122,7 +140,9 @@ import at.hannibal2.skyhanni.features.garden.GardenCropMilestoneFix import at.hannibal2.skyhanni.features.garden.GardenLevelDisplay import at.hannibal2.skyhanni.features.garden.GardenNextJacobContest import at.hannibal2.skyhanni.features.garden.GardenOptimalSpeed +import at.hannibal2.skyhanni.features.garden.GardenPlotAPI import at.hannibal2.skyhanni.features.garden.GardenPlotBorders +import at.hannibal2.skyhanni.features.garden.GardenWarpCommands import at.hannibal2.skyhanni.features.garden.GardenYawAndPitch import at.hannibal2.skyhanni.features.garden.ToolTooltipTweaks import at.hannibal2.skyhanni.features.garden.composter.ComposterDisplay @@ -134,10 +154,10 @@ import at.hannibal2.skyhanni.features.garden.contest.JacobContestFFNeededDisplay import at.hannibal2.skyhanni.features.garden.contest.JacobContestStatsSummary import at.hannibal2.skyhanni.features.garden.contest.JacobContestTimeNeeded import at.hannibal2.skyhanni.features.garden.contest.JacobFarmingContestsInventory +import at.hannibal2.skyhanni.features.garden.farming.ArmorDropTracker import at.hannibal2.skyhanni.features.garden.farming.CropMoneyDisplay import at.hannibal2.skyhanni.features.garden.farming.CropSpeedMeter -import at.hannibal2.skyhanni.features.garden.farming.DicerRngDropCounter -import at.hannibal2.skyhanni.features.garden.farming.FarmingArmorDrops +import at.hannibal2.skyhanni.features.garden.farming.DicerDropTracker import at.hannibal2.skyhanni.features.garden.farming.FarmingWeightDisplay import at.hannibal2.skyhanni.features.garden.farming.GardenBurrowingSporesNotifier import at.hannibal2.skyhanni.features.garden.farming.GardenCropMilestoneDisplay @@ -154,10 +174,15 @@ import at.hannibal2.skyhanni.features.garden.inventory.GardenInventoryNumbers import at.hannibal2.skyhanni.features.garden.inventory.GardenNextPlotPrice import at.hannibal2.skyhanni.features.garden.inventory.GardenPlotIcon import at.hannibal2.skyhanni.features.garden.inventory.SkyMartCopperPrice +import at.hannibal2.skyhanni.features.garden.pests.PestFinder +import at.hannibal2.skyhanni.features.garden.pests.PestSpawn +import at.hannibal2.skyhanni.features.garden.pests.PestSpawnTimer +import at.hannibal2.skyhanni.features.garden.pests.SprayFeatures import at.hannibal2.skyhanni.features.garden.visitor.GardenVisitorColorNames import at.hannibal2.skyhanni.features.garden.visitor.GardenVisitorDropStatistics import at.hannibal2.skyhanni.features.garden.visitor.GardenVisitorFeatures import at.hannibal2.skyhanni.features.garden.visitor.GardenVisitorTimer +import at.hannibal2.skyhanni.features.garden.visitor.HighlightVisitorsOutsideOfGarden import at.hannibal2.skyhanni.features.garden.visitor.VisitorListener import at.hannibal2.skyhanni.features.inventory.AuctionsHighlighter import at.hannibal2.skyhanni.features.inventory.ChestValue @@ -184,6 +209,7 @@ import at.hannibal2.skyhanni.features.mining.crystalhollows.CrystalHollowsNamesI import at.hannibal2.skyhanni.features.mining.powdertracker.PowderTracker import at.hannibal2.skyhanni.features.minion.MinionCollectLogic import at.hannibal2.skyhanni.features.minion.MinionFeatures +import at.hannibal2.skyhanni.features.minion.MinionXp import at.hannibal2.skyhanni.features.misc.BrewingStandOverlay import at.hannibal2.skyhanni.features.misc.ButtonOnPause import at.hannibal2.skyhanni.features.misc.CollectionTracker @@ -231,6 +257,7 @@ import at.hannibal2.skyhanni.features.misc.trevor.TrevorSolver import at.hannibal2.skyhanni.features.misc.trevor.TrevorTracker import at.hannibal2.skyhanni.features.misc.update.UpdateManager import at.hannibal2.skyhanni.features.misc.visualwords.ModifyVisualWords +import at.hannibal2.skyhanni.features.nether.PabloHelper import at.hannibal2.skyhanni.features.nether.QuestItemHelper import at.hannibal2.skyhanni.features.nether.ashfang.AshfangBlazes import at.hannibal2.skyhanni.features.nether.ashfang.AshfangBlazingSouls @@ -241,7 +268,6 @@ import at.hannibal2.skyhanni.features.nether.ashfang.AshfangHideParticles import at.hannibal2.skyhanni.features.nether.ashfang.AshfangNextResetCooldown import at.hannibal2.skyhanni.features.nether.reputationhelper.CrimsonIsleReputationHelper import at.hannibal2.skyhanni.features.rift.RiftAPI -import at.hannibal2.skyhanni.features.rift.area.RiftLarva import at.hannibal2.skyhanni.features.rift.area.colosseum.BlobbercystsHighlight import at.hannibal2.skyhanni.features.rift.area.dreadfarm.RiftAgaricusCap import at.hannibal2.skyhanni.features.rift.area.dreadfarm.RiftWiltedBerberisHelper @@ -255,6 +281,7 @@ import at.hannibal2.skyhanni.features.rift.area.mirrorverse.RiftUpsideDownParkou import at.hannibal2.skyhanni.features.rift.area.mirrorverse.TubulatorParkour import at.hannibal2.skyhanni.features.rift.area.stillgorechateau.RiftBloodEffigies import at.hannibal2.skyhanni.features.rift.area.westvillage.KloonHacking +import at.hannibal2.skyhanni.features.rift.area.wyldwoods.RiftLarva import at.hannibal2.skyhanni.features.rift.area.wyldwoods.RiftOdonata import at.hannibal2.skyhanni.features.rift.area.wyldwoods.ShyCruxWarnings import at.hannibal2.skyhanni.features.rift.everywhere.CruxTalismanDisplay @@ -266,9 +293,9 @@ import at.hannibal2.skyhanni.features.rift.everywhere.motes.RiftMotesOrb import at.hannibal2.skyhanni.features.rift.everywhere.motes.ShowMotesNpcSellPrice import at.hannibal2.skyhanni.features.slayer.HideMobNames import at.hannibal2.skyhanni.features.slayer.SlayerBossSpawnSoon -import at.hannibal2.skyhanni.features.slayer.SlayerItemProfitTracker import at.hannibal2.skyhanni.features.slayer.SlayerItemsOnGround import at.hannibal2.skyhanni.features.slayer.SlayerMiniBossFeatures +import at.hannibal2.skyhanni.features.slayer.SlayerProfitTracker import at.hannibal2.skyhanni.features.slayer.SlayerQuestWarning import at.hannibal2.skyhanni.features.slayer.SlayerRngMeterDisplay import at.hannibal2.skyhanni.features.slayer.VampireSlayerFeatures @@ -282,6 +309,7 @@ import at.hannibal2.skyhanni.features.summonings.SummoningMobManager import at.hannibal2.skyhanni.features.summonings.SummoningSoulsName import at.hannibal2.skyhanni.mixins.hooks.RenderLivingEntityHelper import at.hannibal2.skyhanni.test.HighlightMissingRepoItems +import at.hannibal2.skyhanni.test.HotSwapDetection import at.hannibal2.skyhanni.test.PacketTest import at.hannibal2.skyhanni.test.ParkourWaypointSaver import at.hannibal2.skyhanni.test.ShowItemUuid @@ -318,7 +346,7 @@ import org.apache.logging.log4j.Logger clientSideOnly = true, useMetadata = true, guiFactory = "at.hannibal2.skyhanni.config.ConfigGuiForgeInterop", - version = "0.21.Beta.13", + version = "0.22.Beta.6", ) class SkyHanniMod { @Mod.EventHandler @@ -329,6 +357,7 @@ class SkyHanniMod { loadModule(this) loadModule(ChatManager) loadModule(HypixelData()) + loadModule(LocationFixData) loadModule(DungeonAPI()) loadModule(ScoreboardData()) loadModule(SeaCreatureFeatures()) @@ -348,10 +377,12 @@ class SkyHanniMod { loadModule(TabListData()) loadModule(RenderData()) loadModule(GardenCropMilestones) + loadModule(GardenCropMilestonesCommunityFix) loadModule(GardenCropUpgrades()) loadModule(VisitorListener()) loadModule(OwnInventoryData()) loadModule(ToolTipData()) + loadModule(HighlightVisitorsOutsideOfGarden()) loadModule(GuiEditManager()) loadModule(UpdateManager) loadModule(CropAccessoryData()) @@ -360,6 +391,7 @@ class SkyHanniMod { loadModule(ActionBarStatsData) loadModule(GardenCropMilestoneInventory()) loadModule(GardenCropSpeed) + loadModule(GardenWarpCommands()) loadModule(ProfileStorageData) loadModule(TitleData()) loadModule(BlockData()) @@ -367,13 +399,16 @@ class SkyHanniMod { loadModule(EntityOutlineRenderer) loadModule(KeyboardManager) loadModule(AdvancedPlayerList) + loadModule(ItemAddManager()) // APIs loadModule(BazaarApi()) loadModule(GardenAPI) + loadModule(GardenPlotAPI) + loadModule(DataWatcherAPI()) loadModule(CollectionAPI()) loadModule(FarmingContestAPI) - loadModule(FriendAPI()) + loadModule(FriendAPI) loadModule(PartyAPI) loadModule(GuildAPI) loadModule(SlayerAPI) @@ -381,6 +416,7 @@ class SkyHanniMod { loadModule(RiftAPI) loadModule(SackAPI) loadModule(BingoAPI) + loadModule(FishingAPI) // features loadModule(BazaarOrderHelper()) @@ -389,7 +425,7 @@ class SkyHanniMod { loadModule(PlayerChatModifier()) loadModule(DungeonChatFilter()) loadModule(HideNotClickableItems()) - loadModule(ItemDisplayOverlayFeatures()) + loadModule(ItemDisplayOverlayFeatures) loadModule(CurrentPetDisplay()) loadModule(ExpOrbsOnGroundHider()) loadModule(FandomWikiFromMenus()) @@ -401,6 +437,8 @@ class SkyHanniMod { loadModule(DungeonCleanEnd()) loadModule(DungeonBossMessages()) loadModule(DungeonBossHideDamageSplash()) + loadModule(UniqueGiftingOpportunitiesFeatures) + loadModule(UniqueGiftCounter) loadModule(TrophyFishManager) loadModule(TrophyFishFillet()) loadModule(TrophyFishMessages()) @@ -453,6 +491,7 @@ class SkyHanniMod { loadModule(NonGodPotEffectDisplay()) loadModule(SoopyGuessBurrow()) loadModule(HighlightJerries()) + loadModule(TheGreatSpook()) loadModule(GriffinBurrowHelper) loadModule(GriffinBurrowParticleFinder()) loadModule(BurrowWarpHelper()) @@ -482,6 +521,7 @@ class SkyHanniMod { loadModule(GardenVisitorFeatures()) loadModule(GardenInventoryNumbers()) loadModule(GardenVisitorTimer()) + loadModule(MinionXp()) loadModule(GardenNextPlotPrice()) loadModule(GardenCropMilestoneDisplay) loadModule(GardenCustomKeybinds) @@ -490,12 +530,12 @@ class SkyHanniMod { loadModule(GardenDeskInSBMenu()) loadModule(GardenLevelDisplay()) loadModule(FarmingWeightDisplay()) - loadModule(DicerRngDropCounter()) + loadModule(DicerDropTracker) loadModule(CropMoneyDisplay) loadModule(JacobFarmingContestsInventory()) loadModule(GardenNextJacobContest) loadModule(WrongFungiCutterWarning()) - loadModule(FarmingArmorDrops()) + loadModule(ArmorDropTracker) loadModule(JoinCrystalHollows()) loadModule(CrystalHollowsNamesInCore()) loadModule(GardenVisitorColorNames) @@ -544,13 +584,16 @@ class SkyHanniMod { loadModule(WarpTabComplete) loadModule(PlayerTabComplete) loadModule(GetFromSacksTabComplete) - loadModule(SlayerItemProfitTracker) + loadModule(SlayerProfitTracker) + loadModule(FishingProfitTracker) + loadModule(FishingTrackerCategoryManager) + loadModule(FishingProfitPlayerMoving) loadModule(SlayerItemsOnGround()) loadModule(RestorePieceOfWizardPortalLore()) loadModule(QuickModMenuSwitch) loadModule(ArachneChatMessageHider()) loadModule(ShowItemUuid()) - loadModule(FrozenTreasureTracker()) + loadModule(FrozenTreasureTracker) loadModule(SlayerRngMeterDisplay()) loadModule(GhostCounter) loadModule(RiftTimer()) @@ -585,17 +628,17 @@ class SkyHanniMod { loadModule(GriffinPetWarning()) loadModule(BestiaryData) loadModule(KingTalismanHelper()) - loadModule(HarpFeatures()) - loadModule(EnderNodeTracker()) + loadModule(HarpFeatures) + loadModule(EnderNodeTracker) loadModule(CompactBestiaryChatMessage()) loadModule(WatchdogHider()) loadModule(AccountUpgradeReminder()) loadModule(PetExpTooltip()) -// loadModule(Translator()) - loadModule(GardenPlotBorders()) + loadModule(Translator()) + loadModule(GardenPlotBorders) loadModule(CosmeticFollowingLine()) loadModule(SuperpairsClicksAlert()) - loadModule(PowderTracker()) + loadModule(PowderTracker) loadModule(ModifyVisualWords) loadModule(TabListReader) loadModule(TabListRenderer) @@ -609,9 +652,16 @@ class SkyHanniMod { loadModule(SkyBlockKickDuration()) loadModule(LimboTimeTracker()) loadModule(PartyMemberOutlines()) + loadModule(ArrowTrail()) loadModule(ShiftClickEquipment()) loadModule(LockMouseLook) loadModule(DungeonFinderFeatures()) + loadModule(PabloHelper()) + loadModule(FishingBaitWarnings()) + loadModule(PestSpawn()) + loadModule(PestSpawnTimer) + loadModule(PestFinder()) + loadModule(SprayFeatures()) init() @@ -626,6 +676,8 @@ class SkyHanniMod { loadModule(HighlightMissingRepoItems()) loadModule(ParkourWaypointSaver()) loadModule(TestShowSlotNumber()) + loadModule(SkyHanniDebugsAndTests) + loadModule(HotSwapDetection) } @Mod.EventHandler @@ -634,9 +686,9 @@ class SkyHanniMod { configManager.firstLoad() initLogging() Runtime.getRuntime().addShutdownHook(Thread { - configManager.saveConfig("shutdown-hook") + configManager.saveConfig(ConfigFileType.FEATURES, "shutdown-hook") }) - repo = RepoManager(configManager.configDirectory) + repo = RepoManager(ConfigManager.configDirectory) try { repo.loadRepoInformation() } catch (e: Exception) { @@ -654,6 +706,7 @@ class SkyHanniMod { if (screenToOpen != null) { screenTicks++ if (screenTicks == 5) { + Minecraft.getMinecraft().thePlayer.closeScreen() Minecraft.getMinecraft().displayGuiScreen(screenToOpen) screenTicks = 0 screenToOpen = null @@ -671,6 +724,10 @@ class SkyHanniMod { @JvmStatic val feature: Features get() = configManager.features val sackData: SackData get() = configManager.sackData + val friendsData: FriendsJson get() = configManager.friendsData + val knownFeaturesData: KnownFeaturesJson get() = configManager.knownFeaturesData + val jacobContestsData: JacobContestsJson get() = configManager.jacobContestData + lateinit var repo: RepoManager lateinit var configManager: ConfigManager val logger: Logger = LogManager.getLogger("SkyHanni") @@ -679,7 +736,7 @@ class SkyHanniMod { } val modules: MutableList = ArrayList() - val globalJob: Job = Job(null) + private val globalJob: Job = Job(null) val coroutineScope = CoroutineScope( CoroutineName("SkyHanni") + SupervisorJob(globalJob) ) diff --git a/src/main/java/at/hannibal2/skyhanni/api/CollectionAPI.kt b/src/main/java/at/hannibal2/skyhanni/api/CollectionAPI.kt index 2476cbe73870..ba9dc5327f83 100644 --- a/src/main/java/at/hannibal2/skyhanni/api/CollectionAPI.kt +++ b/src/main/java/at/hannibal2/skyhanni/api/CollectionAPI.kt @@ -2,6 +2,7 @@ package at.hannibal2.skyhanni.api import at.hannibal2.skyhanni.events.CollectionUpdateEvent import at.hannibal2.skyhanni.events.InventoryFullyOpenedEvent +import at.hannibal2.skyhanni.events.ItemAddEvent import at.hannibal2.skyhanni.events.ProfileJoinEvent import at.hannibal2.skyhanni.utils.ItemUtils.getLore import at.hannibal2.skyhanni.utils.ItemUtils.name @@ -11,6 +12,7 @@ import at.hannibal2.skyhanni.utils.NEUInternalName import at.hannibal2.skyhanni.utils.NEUItems import at.hannibal2.skyhanni.utils.NEUItems.getItemStackOrNull import at.hannibal2.skyhanni.utils.StringUtils.matchMatcher +import at.hannibal2.skyhanni.utils.StringUtils.matches import at.hannibal2.skyhanni.utils.StringUtils.removeColor import net.minecraftforge.fml.common.eventhandler.SubscribeEvent @@ -66,22 +68,27 @@ class CollectionAPI { } } + @SubscribeEvent + fun onItemAdd(event: ItemAddEvent) { + val internalName = event.internalName + val (_, amount) = NEUItems.getMultiplier(internalName) + if (amount > 1) return + + // TODO add support for replenish (higher collection than actual items in inv) + if (internalName.getItemStackOrNull() == null) { + LorenzUtils.debug("CollectionAPI.addFromInventory: item is null for '$internalName'") + return + } + collectionValue.addOrPut(internalName, event.amount.toLong()) + } + companion object { // TODO USE SH-REPO val collectionValue = mutableMapOf() private val collectionTier0Pattern = "§7Progress to .* I: .*".toPattern() - fun isCollectionTier0(lore: List) = lore.map { collectionTier0Pattern.matcher(it) }.any { it.matches() } + fun isCollectionTier0(lore: List) = lore.any { collectionTier0Pattern.matches(it) } fun getCollectionCounter(internalName: NEUInternalName): Long? = collectionValue[internalName] - - // TODO add support for replenish (higher collection than actual items in inv) - fun addFromInventory(internalName: NEUInternalName, amount: Int) { - if (internalName.getItemStackOrNull() == null) { - LorenzUtils.debug("CollectionAPI.addFromInventory: item is null for '$internalName'") - return - } - collectionValue.addOrPut(internalName, amount.toLong()) - } } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/api/DataWatcherAPI.kt b/src/main/java/at/hannibal2/skyhanni/api/DataWatcherAPI.kt new file mode 100644 index 000000000000..4eb107554791 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/api/DataWatcherAPI.kt @@ -0,0 +1,21 @@ +package at.hannibal2.skyhanni.api + +import at.hannibal2.skyhanni.events.DataWatcherUpdatedEvent +import at.hannibal2.skyhanni.events.EntityCustomNameUpdateEvent +import net.minecraftforge.fml.common.eventhandler.SubscribeEvent + +class DataWatcherAPI { + + private val DATA_VALUE_CUSTOM_NAME = 2 + + @SubscribeEvent + fun onDataWatcherUpdate(event: DataWatcherUpdatedEvent) { + for (updatedEntry in event.updatedEntries) { + if (updatedEntry.dataValueId == DATA_VALUE_CUSTOM_NAME) { + EntityCustomNameUpdateEvent(event.entity.customNameTag, event.entity).postAndCatch() + } + } + } + + // TODO move EntityHealthUpdateEvent logic from EntityData in here +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/ConfigGuiForgeInterop.kt b/src/main/java/at/hannibal2/skyhanni/config/ConfigGuiForgeInterop.kt index a8190ca5b91b..b0adea115446 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/ConfigGuiForgeInterop.kt +++ b/src/main/java/at/hannibal2/skyhanni/config/ConfigGuiForgeInterop.kt @@ -18,7 +18,8 @@ class ConfigGuiForgeInterop : IModGuiFactory { override fun getHandlerFor(element: RuntimeOptionCategoryElement): RuntimeOptionGuiHandler? = null - class WrappedSkyHanniConfig(private val parent: GuiScreen) : GuiScreenElementWrapper(ConfigGuiManager.editor) { + class WrappedSkyHanniConfig(private val parent: GuiScreen) : + GuiScreenElementWrapper(ConfigGuiManager.getEditorInstance()) { @Throws(IOException::class) override fun handleKeyboardInput() { if (Keyboard.getEventKeyState() && Keyboard.getEventKey() == Keyboard.KEY_ESCAPE) { @@ -28,4 +29,4 @@ class ConfigGuiForgeInterop : IModGuiFactory { super.handleKeyboardInput() } } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/ConfigGuiManager.kt b/src/main/java/at/hannibal2/skyhanni/config/ConfigGuiManager.kt index 37c2920a54e4..f6bcd3bbc89d 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/ConfigGuiManager.kt +++ b/src/main/java/at/hannibal2/skyhanni/config/ConfigGuiManager.kt @@ -5,14 +5,18 @@ import io.github.moulberry.moulconfig.gui.GuiScreenElementWrapper import io.github.moulberry.moulconfig.gui.MoulConfigEditor object ConfigGuiManager { - val editor by lazy { MoulConfigEditor(SkyHanniMod.configManager.processor) } + + var editor: MoulConfigEditor? = null + + fun getEditorInstance() = editor ?: MoulConfigEditor(SkyHanniMod.configManager.processor).also { editor = it } fun openConfigGui(search: String? = null) { + val editor = getEditorInstance() + if (search != null) { editor.search(search) } SkyHanniMod.screenToOpen = GuiScreenElementWrapper(editor) } - -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/ConfigManager.kt b/src/main/java/at/hannibal2/skyhanni/config/ConfigManager.kt index a05d2de5d224..9025703f5308 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/ConfigManager.kt +++ b/src/main/java/at/hannibal2/skyhanni/config/ConfigManager.kt @@ -1,15 +1,20 @@ package at.hannibal2.skyhanni.config import at.hannibal2.skyhanni.SkyHanniMod +import at.hannibal2.skyhanni.data.IslandType +import at.hannibal2.skyhanni.data.jsonobjects.local.FriendsJson +import at.hannibal2.skyhanni.data.jsonobjects.local.JacobContestsJson +import at.hannibal2.skyhanni.data.jsonobjects.local.KnownFeaturesJson import at.hannibal2.skyhanni.features.fishing.trophy.TrophyRarity -import at.hannibal2.skyhanni.features.garden.CropType import at.hannibal2.skyhanni.features.misc.update.UpdateManager import at.hannibal2.skyhanni.utils.LorenzLogger import at.hannibal2.skyhanni.utils.LorenzRarity +import at.hannibal2.skyhanni.utils.LorenzUtils import at.hannibal2.skyhanni.utils.LorenzVec import at.hannibal2.skyhanni.utils.NEUInternalName import at.hannibal2.skyhanni.utils.NEUInternalName.Companion.asInternalName import at.hannibal2.skyhanni.utils.NEUItems +import at.hannibal2.skyhanni.utils.tracker.SkyHanniTracker import com.google.gson.GsonBuilder import com.google.gson.JsonObject import com.google.gson.TypeAdapter @@ -34,6 +39,8 @@ import java.nio.file.StandardCopyOption import java.util.UUID import kotlin.concurrent.fixedRateTimer +typealias TrackerDisplayMode = SkyHanniTracker.DefaultDisplayMode + class ConfigManager { companion object { val gson = GsonBuilder().setPrettyPrinting() @@ -93,140 +100,140 @@ class ConfigManager { } override fun read(reader: JsonReader): LorenzRarity { - return LorenzRarity.valueOf(reader.nextString()) + return LorenzRarity.valueOf(reader.nextString().uppercase()) + } + }.nullSafe()) + .registerTypeAdapter(IslandType::class.java, object : TypeAdapter() { + override fun write(out: JsonWriter, value: IslandType) { + out.value(value.name) + } + + override fun read(reader: JsonReader): IslandType { + return IslandType.valueOf(reader.nextString().uppercase()) + } + }.nullSafe()) + .registerTypeAdapter(TrackerDisplayMode::class.java, object : TypeAdapter() { + override fun write(out: JsonWriter, value: TrackerDisplayMode) { + out.value(value.name) + } + + override fun read(reader: JsonReader): TrackerDisplayMode { + return TrackerDisplayMode.valueOf(reader.nextString()) } }.nullSafe()) .enableComplexMapKeySerialization() .create() + + var configDirectory = File("config/skyhanni") } - lateinit var features: Features - lateinit var sackData: SackData - private set + val features get() = jsonHolder[ConfigFileType.FEATURES] as Features + val sackData get() = jsonHolder[ConfigFileType.SACKS] as SackData + val friendsData get() = jsonHolder[ConfigFileType.FRIENDS] as FriendsJson + val knownFeaturesData get() = jsonHolder[ConfigFileType.KNOWN_FEATURES] as KnownFeaturesJson + val jacobContestData get() = jsonHolder[ConfigFileType.JACOB_CONTESTS] as JacobContestsJson + private val logger = LorenzLogger("config_manager") - var configDirectory = File("config/skyhanni") - private var configFile: File? = null - private var sackFile: File? = null + private val jsonHolder = mutableMapOf() + lateinit var processor: MoulConfigProcessor + private var disableSaving = false fun firstLoad() { - if (::features.isInitialized) { + if (jsonHolder.isNotEmpty()) { logger.log("Loading config despite config being already loaded?") } - configDirectory.mkdir() + configDirectory.mkdirs() + + + for (fileType in ConfigFileType.entries) { + jsonHolder[fileType] = firstLoadFile(fileType.file, fileType, fileType.clazz.newInstance()) + } - configFile = File(configDirectory, "config.json") - sackFile = File(configDirectory, "sacks.json") + fixedRateTimer(name = "skyhanni-config-auto-save", period = 60_000L, initialDelay = 60_000L) { + saveConfig(ConfigFileType.FEATURES, "auto-save-60s") + } - logger.log("Trying to load config from $configFile") + val features = SkyHanniMod.feature + processor = MoulConfigProcessor(SkyHanniMod.feature) + BuiltinMoulConfigGuis.addProcessors(processor) + UpdateManager.injectConfigProcessor(processor) + ConfigProcessorDriver.processConfig( + features.javaClass, + features, + processor + ) + } + + private fun firstLoadFile(file: File?, fileType: ConfigFileType, defaultValue: Any): Any { + val fileName = fileType.fileName + logger.log("Trying to load $fileName from $file") + var output: Any = defaultValue - if (configFile!!.exists()) { + if (file!!.exists()) { try { - val inputStreamReader = InputStreamReader(FileInputStream(configFile!!), StandardCharsets.UTF_8) + val inputStreamReader = InputStreamReader(FileInputStream(file), StandardCharsets.UTF_8) val bufferedReader = BufferedReader(inputStreamReader) - val builder = StringBuilder() - for (line in bufferedReader.lines()) { - val result = fixConfig(line) - builder.append(result) - builder.append("\n") - } + logger.log("load-$fileName-now") + + output = if (fileType == ConfigFileType.FEATURES) { + val jsonObject = gson.fromJson(bufferedReader.readText(), JsonObject::class.java) + val newJsonObject = ConfigUpdaterMigrator.fixConfig(jsonObject) + val run = { gson.fromJson(newJsonObject, defaultValue.javaClass) } + if (LorenzUtils.isInDevEnviromen()) { + try { + run() + } catch (e: Throwable) { + e.printStackTrace() + LorenzUtils.shutdownMinecraft("Config is corrupt inside developement enviroment.") + } + } else { + run() + } + } else { + gson.fromJson(bufferedReader.readText(), defaultValue.javaClass) + } - logger.log("load-config-now") - val jsonObject = gson.fromJson(builder.toString(), JsonObject::class.java) - val newJsonObject = ConfigUpdaterMigrator.fixConfig(jsonObject) - features = gson.fromJson( - newJsonObject, - Features::class.java - ) - logger.log("Loaded config from file") + logger.log("Loaded $fileName from file") } catch (error: Exception) { error.printStackTrace() - val backupFile = configFile!!.resolveSibling("config-${System.currentTimeMillis()}-backup.json") - logger.log("Exception while reading $configFile. Will load blank config and save backup to $backupFile") + val backupFile = file.resolveSibling("$fileName-${System.currentTimeMillis()}-backup.json") + logger.log("Exception while reading $file. Will load blank $fileName and save backup to $backupFile") logger.log("Exception was $error") try { - configFile!!.copyTo(backupFile) + file.copyTo(backupFile) } catch (e: Exception) { - logger.log("Could not create backup for config file") + logger.log("Could not create backup for $fileName file") e.printStackTrace() } } } - if (sackFile!!.exists()) { - try { - val inputStreamReader = InputStreamReader(FileInputStream(sackFile!!), StandardCharsets.UTF_8) - val bufferedReader = BufferedReader(inputStreamReader) - val builder = StringBuilder() - for (line in bufferedReader.lines()) { - builder.append(line) - builder.append("\n") - } - - - logger.log("load-sacks-now") - sackData = gson.fromJson( - builder.toString(), - SackData::class.java - ) - logger.log("Loaded sacks from file") - } catch (error: Exception) { - error.printStackTrace() - } - } - - if (!::features.isInitialized) { - logger.log("Creating blank config and saving to file") - features = Features() - saveConfig("blank config") + if (output == defaultValue) { + logger.log("Setting $fileName to be blank as it did not exist. It will be saved once something is written to it") } - fixedRateTimer(name = "skyhanni-config-auto-save", period = 60_000L, initialDelay = 60_000L) { - saveConfig("auto-save-60s") - } - - if (!::sackData.isInitialized) { - logger.log("Creating blank sack data and saving") - sackData = SackData() - saveSackData("blank config") - } - - val features = SkyHanniMod.feature - processor = MoulConfigProcessor(SkyHanniMod.feature) - BuiltinMoulConfigGuis.addProcessors(processor) - UpdateManager.injectConfigProcessor(processor) - ConfigProcessorDriver.processConfig( - features.javaClass, - features, - processor - ) + return output } - private fun fixConfig(line: String): String { - var result = line - for (type in CropType.entries) { - val normal = "\"${type.cropName}\"" - val enumName = "\"${type.name}\"" - while (result.contains(normal)) { - result = result.replace(normal, enumName) - } - } - return result + fun saveConfig(fileType: ConfigFileType, reason: String) { + val json = jsonHolder[fileType] ?: error("Could not find json object for $fileType") + saveFile(fileType.file, fileType.fileName, json, reason) } - fun saveConfig(reason: String) { + private fun saveFile(file: File?, fileName: String, data: Any, reason: String) { + if (disableSaving) return logger.log("saveConfig: $reason") - val file = configFile ?: throw Error("Can not save config, configFile is null!") + if (file == null) throw Error("Can not save $fileName, ${fileName}File is null!") try { - logger.log("Saving config file") + logger.log("Saving $fileName file") file.parentFile.mkdirs() - val unit = file.parentFile.resolve("config.json.write") + val unit = file.parentFile.resolve("$fileName.json.write") unit.createNewFile() BufferedWriter(OutputStreamWriter(FileOutputStream(unit), StandardCharsets.UTF_8)).use { writer -> - // TODO remove old "hidden" area - writer.write(gson.toJson(SkyHanniMod.feature)) + writer.write(gson.toJson(data)) } // Perform move — which is atomic, unlike writing — after writing is done. Files.move( @@ -236,24 +243,23 @@ class ConfigManager { StandardCopyOption.ATOMIC_MOVE ) } catch (e: IOException) { - logger.log("Could not save config file to $file") + logger.log("Could not save $fileName file to $file") e.printStackTrace() } } - fun saveSackData(reason: String) { - logger.log("saveSackData: $reason") - val file = sackFile ?: throw Error("Can not save sacks, sackFile is null!") - try { - logger.log("Saving sack file") - file.parentFile.mkdirs() - file.createNewFile() - BufferedWriter(OutputStreamWriter(FileOutputStream(file), StandardCharsets.UTF_8)).use { writer -> - writer.write(gson.toJson(SkyHanniMod.sackData)) - } - } catch (e: IOException) { - logger.log("Could not save sacks file to $file") - e.printStackTrace() - } + fun disableSaving() { + disableSaving = true } -} \ No newline at end of file +} + +enum class ConfigFileType(val fileName: String, val clazz: Class<*>) { + FEATURES("config", Features::class.java), + SACKS("sacks", SackData::class.java), + FRIENDS("friends", FriendsJson::class.java), + KNOWN_FEATURES("known_features", KnownFeaturesJson::class.java), + JACOB_CONTESTS("jacob_contests", JacobContestsJson::class.java), + ; + + val file by lazy { File(ConfigManager.configDirectory, "$fileName.json") } +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/ConfigUpdaterMigrator.kt b/src/main/java/at/hannibal2/skyhanni/config/ConfigUpdaterMigrator.kt index 69a77d6dfc78..6f5fe68edb24 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/ConfigUpdaterMigrator.kt +++ b/src/main/java/at/hannibal2/skyhanni/config/ConfigUpdaterMigrator.kt @@ -9,7 +9,7 @@ import com.google.gson.JsonPrimitive object ConfigUpdaterMigrator { val logger = LorenzLogger("ConfigMigration") - val configVersion = 6 + const val CONFIG_VERSION = 11 fun JsonElement.at(chain: List, init: Boolean): JsonElement? { if (chain.isEmpty()) return this if (this !is JsonObject) return null @@ -26,14 +26,21 @@ object ConfigUpdaterMigrator { val new: JsonObject, val oldVersion: Int, var movesPerformed: Int, + val dynamicPrefix: Map>, ) : LorenzEvent() { - fun move(since: Int, oldPath: String, newPath: String, transform: (JsonElement) -> JsonElement = { it }) { + init { + dynamicPrefix.entries.filter { it.value.isEmpty() }.forEach { + logger.log("Dynamic prefix ${it.key} does not resolve to anything.") + } + } + + fun move(since: Int, oldPath: String, newPath: String = oldPath, transform: (JsonElement) -> JsonElement = { it }) { if (since <= oldVersion) { logger.log("Skipping move from $oldPath to $newPath ($since <= $oldVersion)") return } - if (since > configVersion) { - error("Illegally new version $since > $configVersion") + if (since > CONFIG_VERSION) { + error("Illegally new version $since > $CONFIG_VERSION") } if (since > oldVersion + 1) { logger.log("Skipping move from $oldPath to $newPath (will be done in another pass)") @@ -41,51 +48,81 @@ object ConfigUpdaterMigrator { } val op = oldPath.split(".") val np = newPath.split(".") + if (op.first().startsWith("#")) { + require(np.first() == op.first()) + val realPrefixes = dynamicPrefix[op.first()] + if (realPrefixes == null) { + logger.log("Could not resolve dynamic prefix $oldPath") + return + } + for (realPrefix in realPrefixes) { + move( + since, + "$realPrefix.${oldPath.substringAfter('.')}", + "$realPrefix.${newPath.substringAfter('.')}", transform + ) + return + } + } val oldElem = old.at(op, false) if (oldElem == null) { logger.log("Skipping move from $oldPath to $newPath ($oldPath not present)") return } - val x = new.at(np.dropLast(1), true) - if (x !is JsonObject) { + val newParentElement = new.at(np.dropLast(1), true) + if (newParentElement !is JsonObject) { logger.log("Catastrophic: element at path $old could not be relocated to $new, since another element already inhabits that path") return } movesPerformed++ - x.add(np.last(), transform(oldElem)) + newParentElement.add(np.last(), transform(oldElem)) logger.log("Moved element from $oldPath to $newPath") } } - fun merge(a: JsonObject, b: JsonObject): Int { - var c = 0 - b.entrySet().forEach { - val e = a.get(it.key) - val n = it.value - if (e is JsonObject && n is JsonObject) { - c += merge(e, n) + private fun merge(originalObject: JsonObject, overrideObject: JsonObject): Int { + var count = 0 + overrideObject.entrySet().forEach { + val element = originalObject.get(it.key) + val newElement = it.value + if (element is JsonObject && newElement is JsonObject) { + count += merge(element, newElement) } else { - if (e != null) { - logger.log("Encountered destructive merge. Erasing $e in favour of $n.") - c++ + if (element != null) { + logger.log("Encountered destructive merge. Erasing $element in favour of $newElement.") + count++ } - a.add(it.key, n) + originalObject.add(it.key, newElement) } } - return c + return count } fun fixConfig(config: JsonObject): JsonObject { - val lV = (config.get("lastVersion") as? JsonPrimitive)?.asIntOrNull ?: -1 - if (lV > configVersion) { + val lastVersion = (config.get("lastVersion") as? JsonPrimitive)?.asIntOrNull ?: -1 + if (lastVersion > CONFIG_VERSION) { error("Cannot downgrade config") } - if (lV == configVersion) return config - return (lV until configVersion).fold(config) { acc, i -> + if (lastVersion == CONFIG_VERSION) return config + return (lastVersion until CONFIG_VERSION).fold(config) { accumulator, i -> logger.log("Starting config transformation from $i to ${i + 1}") - val migration = ConfigFixEvent(acc, JsonObject().also { + val storage = accumulator.get("storage")?.asJsonObject + val dynamicPrefix: Map> = mapOf( + "#profile" to + (storage?.get("players")?.asJsonObject?.entrySet() + ?.flatMap { player -> + player.value.asJsonObject.get("profiles")?.asJsonObject?.entrySet()?.map { + "storage.players.${player.key}.profiles.${it.key}" + } ?: listOf() + } + ?: listOf()), + "#player" to + (storage?.get("players")?.asJsonObject?.entrySet()?.map { "storage.players.${it.key}" } + ?: listOf()), + ) + val migration = ConfigFixEvent(accumulator, JsonObject().also { it.add("lastVersion", JsonPrimitive(i + 1)) - }, i, 0).also { it.postAndCatch() } + }, i, 0, dynamicPrefix).also { it.postAndCatch() } logger.log("Transformations scheduled: ${migration.new}") val mergesPerformed = merge(migration.old, migration.new) logger.log("Migration done with $mergesPerformed merges and ${migration.movesPerformed} moves performed") diff --git a/src/main/java/at/hannibal2/skyhanni/config/Features.java b/src/main/java/at/hannibal2/skyhanni/config/Features.java index f5916cda870b..bb0861e835d6 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/Features.java +++ b/src/main/java/at/hannibal2/skyhanni/config/Features.java @@ -2,27 +2,26 @@ import at.hannibal2.skyhanni.SkyHanniMod; import at.hannibal2.skyhanni.config.features.About; -import at.hannibal2.skyhanni.config.features.BazaarConfig; -import at.hannibal2.skyhanni.config.features.ChatConfig; -import at.hannibal2.skyhanni.config.features.ChromaConfig; -import at.hannibal2.skyhanni.config.features.CombatConfig; -import at.hannibal2.skyhanni.config.features.CommandsConfig; -import at.hannibal2.skyhanni.config.features.CrimsonIsleConfig; -import at.hannibal2.skyhanni.config.features.DevConfig; -import at.hannibal2.skyhanni.config.features.DungeonConfig; -import at.hannibal2.skyhanni.config.features.EventConfig; -import at.hannibal2.skyhanni.config.features.FishingConfig; -import at.hannibal2.skyhanni.config.features.GUIConfig; -import at.hannibal2.skyhanni.config.features.GardenConfig; -import at.hannibal2.skyhanni.config.features.InventoryConfig; -import at.hannibal2.skyhanni.config.features.ItemAbilityConfig; -import at.hannibal2.skyhanni.config.features.MarkedPlayerConfig; -import at.hannibal2.skyhanni.config.features.MiningConfig; -import at.hannibal2.skyhanni.config.features.MinionsConfig; -import at.hannibal2.skyhanni.config.features.MiscConfig; -import at.hannibal2.skyhanni.config.features.OldHidden; -import at.hannibal2.skyhanni.config.features.RiftConfig; -import at.hannibal2.skyhanni.config.features.SlayerConfig; +import at.hannibal2.skyhanni.config.features.bazaar.BazaarConfig; +import at.hannibal2.skyhanni.config.features.chat.ChatConfig; +import at.hannibal2.skyhanni.config.features.chroma.ChromaConfig; +import at.hannibal2.skyhanni.config.features.combat.CombatConfig; +import at.hannibal2.skyhanni.config.features.commands.CommandsConfig; +import at.hannibal2.skyhanni.config.features.crimsonisle.CrimsonIsleConfig; +import at.hannibal2.skyhanni.config.features.dev.DevConfig; +import at.hannibal2.skyhanni.config.features.dungeon.DungeonConfig; +import at.hannibal2.skyhanni.config.features.event.EventConfig; +import at.hannibal2.skyhanni.config.features.fishing.FishingConfig; +import at.hannibal2.skyhanni.config.features.gui.GUIConfig; +import at.hannibal2.skyhanni.config.features.garden.GardenConfig; +import at.hannibal2.skyhanni.config.features.inventory.InventoryConfig; +import at.hannibal2.skyhanni.config.features.itemability.ItemAbilityConfig; +import at.hannibal2.skyhanni.config.features.markedplayer.MarkedPlayerConfig; +import at.hannibal2.skyhanni.config.features.mining.MiningConfig; +import at.hannibal2.skyhanni.config.features.minion.MinionsConfig; +import at.hannibal2.skyhanni.config.features.misc.MiscConfig; +import at.hannibal2.skyhanni.config.features.rift.RiftConfig; +import at.hannibal2.skyhanni.config.features.slayer.SlayerConfig; import com.google.gson.annotations.Expose; import io.github.moulberry.moulconfig.Config; import io.github.moulberry.moulconfig.Social; @@ -45,14 +44,14 @@ public boolean shouldAutoFocusSearchbar() { @Override public List getSocials() { return Arrays.asList( - Social.forLink("Join our Discord", DISCORD, "https://discord.com/invite/skyhanni-997079228510117908"), - Social.forLink("Look at the code", GITHUB, "https://github.com/hannibal002/SkyHanni") + Social.forLink("Join our Discord", DISCORD, "https://discord.com/invite/skyhanni-997079228510117908"), + Social.forLink("Look at the code", GITHUB, "https://github.com/hannibal002/SkyHanni") ); } @Override public void saveNow() { - SkyHanniMod.configManager.saveConfig("close-gui"); + SkyHanniMod.configManager.saveConfig(ConfigFileType.FEATURES, "close-gui"); } @Override @@ -60,77 +59,83 @@ public String getTitle() { return "SkyHanni " + SkyHanniMod.getVersion() + " by §channibal2§r, config by §5Moulberry §rand §5nea89"; } + /* + * If you are adding a new category, please insert it alphabetically + * The only exceptions to this are About and GUI, which are pinned to the top + * and Misc and Dev, which are to be at the bottom. Thanks! + */ + @Expose - @Category(name = "About", desc = "Information about SkyHanni and updates") + @Category(name = "About", desc = "Information about SkyHanni and updates.") public About about = new About(); @Expose - @Category(name = "GUI", desc = "Change the locations of GUI elements. (§e/sh gui§7)") + @Category(name = "GUI", desc = "Change the locations of GUI elements (§e/sh gui§7).") public GUIConfig gui = new GUIConfig(); @Expose - @Category(name = "Chroma", desc = "Settings for Chroma text. (Credit to SBA)") - public ChromaConfig chroma = new ChromaConfig(); + @Category(name = "Bazaar", desc = "Bazaar settings.") + public BazaarConfig bazaar = new BazaarConfig(); @Expose @Category(name = "Chat", desc = "Change how the chat looks.") public ChatConfig chat = new ChatConfig(); @Expose - @Category(name = "Dungeon", desc = "Features that change the Dungeons experience in The Catacombs.") - public DungeonConfig dungeon = new DungeonConfig(); + @Category(name = "Chroma", desc = "Settings for Chroma text (Credit to SBA).") + public ChromaConfig chroma = new ChromaConfig(); @Expose - @Category(name = "Inventory", desc = "Change the behavior of items and the inventory.") - public InventoryConfig inventory = new InventoryConfig(); + @Category(name = "Combat", desc = "Everything combat and PvE related.") + public CombatConfig combat = new CombatConfig(); @Expose - @Category(name = "Item Abilities", desc = "Stuff about item abilities.") - public ItemAbilityConfig itemAbilities = new ItemAbilityConfig(); + @Category(name = "Commands", desc = "Enable or disable commands.") + public CommandsConfig commands = new CommandsConfig(); @Expose @Category(name = "Crimson Isle", desc = "Things to do on the Crimson Isle/Nether island.") public CrimsonIsleConfig crimsonIsle = new CrimsonIsleConfig(); @Expose - @Category(name = "Minion", desc = "The minions on your private island.") - public MinionsConfig minions = new MinionsConfig(); + @Category(name = "Dungeon", desc = "Features that change the Dungeons experience in The Catacombs.") + public DungeonConfig dungeon = new DungeonConfig(); @Expose - @Category(name = "Bazaar", desc = "Bazaar settings.") - public BazaarConfig bazaar = new BazaarConfig(); + @Category(name = "Events", desc = "Stuff that is not always available.") + public EventConfig event = new EventConfig(); @Expose @Category(name = "Fishing", desc = "Fishing stuff.") public FishingConfig fishing = new FishingConfig(); @Expose - @Category(name = "Combat", desc = "Everything combat and PvE related.") - public CombatConfig combat = new CombatConfig(); - - @Expose - @Category(name = "Slayer", desc = "Slayer features.") - public SlayerConfig slayer = new SlayerConfig(); + @Category(name = "Garden", desc = "Features for the Garden island.") + public GardenConfig garden = new GardenConfig(); @Expose - @Category(name = "Mining", desc = "Features that help you break blocks.") - public MiningConfig mining = new MiningConfig(); + @Category(name = "Inventory", desc = "Change the behavior of items and the inventory.") + public InventoryConfig inventory = new InventoryConfig(); @Expose - @Category(name = "Commands", desc = "Enable or disable commands.") - public CommandsConfig commands = new CommandsConfig(); + @Category(name = "Item Abilities", desc = "Stuff about item abilities.") + public ItemAbilityConfig itemAbilities = new ItemAbilityConfig(); @Expose @Category(name = "Marked Players", desc = "Players that got marked with §e/shmarkplayer§7.") public MarkedPlayerConfig markedPlayers = new MarkedPlayerConfig(); @Expose - @Category(name = "Events", desc = "Stuff that is not always available.") - public EventConfig event = new EventConfig(); + @Category(name = "Minions", desc = "The minions on your private island.") + public MinionsConfig minions = new MinionsConfig(); @Expose - @Category(name = "Garden", desc = "Features for the Garden island.") - public GardenConfig garden = new GardenConfig(); + @Category(name = "Mining", desc = "Features that help you break blocks.") + public MiningConfig mining = new MiningConfig(); + + @Expose + @Category(name = "Slayer", desc = "Slayer features.") + public SlayerConfig slayer = new SlayerConfig(); @Expose @Category(name = "The Rift", desc = "Features for The Rift dimension.") @@ -144,13 +149,10 @@ public String getTitle() { @Category(name = "Dev", desc = "Debug and test stuff. Developers are cool.") public DevConfig dev = new DevConfig(); - @Expose - public OldHidden hidden = new OldHidden(); - @Expose public Storage storage = new Storage(); @Expose - public int lastVersion = ConfigUpdaterMigrator.INSTANCE.getConfigVersion(); + public int lastVersion = ConfigUpdaterMigrator.CONFIG_VERSION; } diff --git a/src/main/java/at/hannibal2/skyhanni/config/HasLegacyId.java b/src/main/java/at/hannibal2/skyhanni/config/HasLegacyId.java new file mode 100644 index 000000000000..a867cb5702f2 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/HasLegacyId.java @@ -0,0 +1,26 @@ +package at.hannibal2.skyhanni.config; + +/** + * The interface HasLegacyId. + * To be used for config elements that are being migrated from ArrayLists to Enums. + * A legacyId is not needed for new elements. + */ +public interface HasLegacyId { + + /** + * Gets display string. + * + * @return the display string + */ + String toString(); + + /** + * Gets legacy id. This is used for legacy configs that are being migrated to enums. + * New elements do not need a legacyId, and should return -1 + * + * @return the legacy id + */ + default int getLegacyId() { + return -1; + } +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/Storage.java b/src/main/java/at/hannibal2/skyhanni/config/Storage.java index 21ed83b00a4b..52f10c40ea12 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/Storage.java +++ b/src/main/java/at/hannibal2/skyhanni/config/Storage.java @@ -1,29 +1,36 @@ package at.hannibal2.skyhanni.config; import at.hannibal2.skyhanni.data.model.ComposterUpgrade; +import at.hannibal2.skyhanni.features.combat.endernodetracker.EnderNodeTracker; +import at.hannibal2.skyhanni.features.combat.ghostcounter.GhostData; import at.hannibal2.skyhanni.features.dungeon.DungeonAPI; +import at.hannibal2.skyhanni.features.event.jerry.frozentreasure.FrozenTreasureTracker; +import at.hannibal2.skyhanni.features.fishing.tracker.FishingProfitTracker; import at.hannibal2.skyhanni.features.fishing.trophy.TrophyRarity; import at.hannibal2.skyhanni.features.garden.CropAccessory; import at.hannibal2.skyhanni.features.garden.CropType; -import at.hannibal2.skyhanni.features.garden.farming.FarmingArmorDrops; +import at.hannibal2.skyhanni.features.garden.GardenPlotAPI; +import at.hannibal2.skyhanni.features.garden.farming.ArmorDropTracker; +import at.hannibal2.skyhanni.features.garden.farming.DicerDropTracker; import at.hannibal2.skyhanni.features.garden.fortuneguide.FarmingItems; import at.hannibal2.skyhanni.features.garden.visitor.VisitorReward; -import at.hannibal2.skyhanni.features.combat.endernodetracker.EnderNode; -import at.hannibal2.skyhanni.features.event.jerry.frozentreasure.FrozenTreasure; -import at.hannibal2.skyhanni.features.combat.ghostcounter.GhostData; -import at.hannibal2.skyhanni.features.mining.powdertracker.PowderChestReward; +import at.hannibal2.skyhanni.features.mining.powdertracker.PowderTracker; import at.hannibal2.skyhanni.features.misc.trevor.TrevorTracker; import at.hannibal2.skyhanni.features.misc.visualwords.VisualWord; import at.hannibal2.skyhanni.features.rift.area.westvillage.KloonTerminal; +import at.hannibal2.skyhanni.features.slayer.SlayerProfitTracker; import at.hannibal2.skyhanni.utils.LorenzVec; import at.hannibal2.skyhanni.utils.NEUInternalName; +import at.hannibal2.skyhanni.utils.tracker.SkyHanniTracker; import com.google.gson.annotations.Expose; import net.minecraft.item.ItemStack; import java.util.ArrayList; import java.util.HashMap; +import java.util.HashSet; import java.util.List; import java.util.Map; +import java.util.Set; import java.util.UUID; public class Storage { @@ -32,17 +39,24 @@ public class Storage { public boolean hasPlayedBefore = false; @Expose - public Map> knownFeatureToggles = new HashMap<>(); + public Float savedMouseSensitivity = .5f; + @Deprecated @Expose - public Map> gardenJacobFarmingContestTimes = new HashMap<>(); + public Map> knownFeatureToggles = new HashMap<>(); @Expose public List modifiedWords = new ArrayList<>(); + @Expose + public boolean visualWordsImported = false; + @Expose public Boolean contestSendingAsked = false; + @Expose + public Map trackerDisplayModes = new HashMap<>(); + @Expose public Map players = new HashMap<>(); @@ -65,6 +79,19 @@ public static class PlayerSpecific { @Expose public List guildMembers = new ArrayList<>(); + + @Expose + public WinterStorage winter = new WinterStorage(); + + public static class WinterStorage { + + @Expose + public Set playersThatHaveBeenGifted = new HashSet<>(); + + @Expose + public int amountGifted = 0; + } + } public static class ProfileSpecific { @@ -86,9 +113,9 @@ public static class MinionConfig { @Override public String toString() { return "MinionConfig{" + - "displayName='" + displayName + '\'' + - ", lastClicked=" + lastClicked + - '}'; + "displayName='" + displayName + '\'' + + ", lastClicked=" + lastClicked + + '}'; } } @@ -137,7 +164,7 @@ public static class GardenStorage { public CropAccessory savedCropAccessory = null; @Expose - public Map dicerRngDrops = new HashMap<>(); + public DicerDropTracker.Data dicerDropTracker = new DicerDropTracker.Data(); @Expose public long informedAboutLowMatter = 0; @@ -152,7 +179,7 @@ public static class GardenStorage { public long nextSixthVisitorArrival = 0; @Expose - public Map farmArmorDrops = new HashMap<>(); + public ArmorDropTracker.Data armorDropTracker = new ArmorDropTracker.Data(); @Expose public Map composterUpgrades = new HashMap<>(); @@ -215,6 +242,9 @@ public static class PlotIcon { public Map plotList = new HashMap<>(); } + @Expose + public Map plotData = new HashMap<>(); + @Expose public Map cropStartLocations = new HashMap<>(); @@ -244,6 +274,9 @@ public static class Fortune { @Expose public boolean carrotFortune = false; + @Expose + public boolean pumpkinFortune = false; + @Expose public Map farmingItems = new HashMap<>(); } @@ -293,43 +326,13 @@ public static class GhostCounter { } @Expose - public Map powderTracker = new HashMap<>(); - - public static class PowderTracker { - @Expose - public int totalChestPicked = 0; - - @Expose - public Map rewards = new HashMap<>(); - } + public PowderTracker.Data powderTracker = new PowderTracker.Data(); @Expose - public FrozenTreasureTracker frozenTreasureTracker = new FrozenTreasureTracker(); - - public static class FrozenTreasureTracker { - @Expose - public int treasuresMined = 0; - - @Expose - public int compactProcs = 0; - - @Expose - public Map treasureCount = new HashMap<>(); - } + public FrozenTreasureTracker.Data frozenTreasureTracker = new FrozenTreasureTracker.Data(); @Expose - public EnderNodeTracker enderNodeTracker = new EnderNodeTracker(); - - public static class EnderNodeTracker { - @Expose - public int totalNodesMined = 0; - - @Expose - public int totalEndermiteNests = 0; - - @Expose - public Map lootCount = new HashMap<>(); - } + public EnderNodeTracker.Data enderNodeTracker = new EnderNodeTracker.Data(); @Expose public RiftStorage rift = new RiftStorage(); @@ -342,53 +345,7 @@ public static class RiftStorage { } @Expose - public Map slayerProfitData = new HashMap<>(); - - public static class SlayerProfitList { - - @Expose - public Map items = new HashMap<>(); - - @Expose - public long mobKillCoins = 0; - - @Expose - public long slayerSpawnCost = 0; - - @Expose - public int slayerCompletedCount = 0; - - public static class SlayerItemProfit { - @Expose - public NEUInternalName internalName; - @Expose - public long timesDropped; - @Expose - public long totalAmount; - @Expose - public boolean hidden; - - @Override - public String toString() { - return "SlayerItemProfit{" + - "internalName='" + internalName + '\'' + - ", timesDropped=" + timesDropped + - ", totalAmount=" + totalAmount + - ", hidden=" + hidden + - '}'; - } - } - - @Override - public String toString() { - return "SlayerProfitList{" + - "items=" + items + - ", mobKillCoins=" + mobKillCoins + - ", slayerSpawnCost=" + slayerSpawnCost + - ", slayerCompletedCount=" + slayerCompletedCount + - '}'; - } - } + public Map slayerProfitData = new HashMap<>(); @Expose public Map slayerRngMeter = new HashMap<>(); @@ -410,11 +367,11 @@ public static class SlayerRngMeterStorage { @Override public String toString() { return "SlayerRngMeterStorage{" + - "currentMeter=" + currentMeter + - ", gainPerBoss=" + gainPerBoss + - ", goalNeeded=" + goalNeeded + - ", itemGoal='" + itemGoal + '\'' + - '}'; + "currentMeter=" + currentMeter + + ", gainPerBoss=" + gainPerBoss + + ", goalNeeded=" + goalNeeded + + ", itemGoal='" + itemGoal + '\'' + + '}'; } } @@ -445,7 +402,7 @@ public static class TrapperData { public int selfKillingAnimals; @Expose - public Map animalRarities= new HashMap<>(); + public Map animalRarities = new HashMap<>(); } @Expose @@ -456,5 +413,15 @@ public static class DungeonStorage { @Expose public Map bosses = new HashMap<>(); } + + @Expose + public FishingStorage fishing = new FishingStorage(); + + public static class FishingStorage { + + @Expose + public FishingProfitTracker.Data fishingProfitTracker = new FishingProfitTracker.Data(); + + } } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt b/src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt index 3fdc56073367..f3bd559071dd 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt +++ b/src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt @@ -1,28 +1,38 @@ package at.hannibal2.skyhanni.config.commands import at.hannibal2.skyhanni.SkyHanniMod +import at.hannibal2.skyhanni.config.ConfigFileType import at.hannibal2.skyhanni.config.ConfigGuiManager import at.hannibal2.skyhanni.data.ChatManager +import at.hannibal2.skyhanni.data.GardenCropMilestonesCommunityFix import at.hannibal2.skyhanni.data.GuiEditManager import at.hannibal2.skyhanni.data.PartyAPI import at.hannibal2.skyhanni.features.bingo.BingoCardDisplay import at.hannibal2.skyhanni.features.bingo.BingoNextStepHelper +import at.hannibal2.skyhanni.features.chat.Translator +import at.hannibal2.skyhanni.features.combat.endernodetracker.EnderNodeTracker import at.hannibal2.skyhanni.features.combat.ghostcounter.GhostUtil import at.hannibal2.skyhanni.features.commands.PartyCommands import at.hannibal2.skyhanni.features.event.diana.BurrowWarpHelper import at.hannibal2.skyhanni.features.event.diana.InquisitorWaypointShare +import at.hannibal2.skyhanni.features.event.jerry.frozentreasure.FrozenTreasureTracker import at.hannibal2.skyhanni.features.fame.AccountUpgradeReminder import at.hannibal2.skyhanni.features.fame.CityProjectFeatures +import at.hannibal2.skyhanni.features.fishing.tracker.FishingProfitTracker import at.hannibal2.skyhanni.features.garden.GardenAPI import at.hannibal2.skyhanni.features.garden.GardenCropTimeCommand import at.hannibal2.skyhanni.features.garden.GardenNextJacobContest import at.hannibal2.skyhanni.features.garden.composter.ComposterOverlay +import at.hannibal2.skyhanni.features.garden.farming.ArmorDropTracker import at.hannibal2.skyhanni.features.garden.farming.CropMoneyDisplay import at.hannibal2.skyhanni.features.garden.farming.CropSpeedMeter +import at.hannibal2.skyhanni.features.garden.farming.DicerDropTracker import at.hannibal2.skyhanni.features.garden.farming.FarmingWeightDisplay import at.hannibal2.skyhanni.features.garden.farming.GardenStartLocation import at.hannibal2.skyhanni.features.garden.fortuneguide.CaptureFarmingGear import at.hannibal2.skyhanni.features.garden.fortuneguide.FFGuideGUI +import at.hannibal2.skyhanni.features.mining.KingTalismanHelper +import at.hannibal2.skyhanni.features.mining.powdertracker.PowderTracker import at.hannibal2.skyhanni.features.minion.MinionFeatures import at.hannibal2.skyhanni.features.misc.CollectionTracker import at.hannibal2.skyhanni.features.misc.LockMouseLook @@ -30,7 +40,7 @@ import at.hannibal2.skyhanni.features.misc.MarkedPlayerManager import at.hannibal2.skyhanni.features.misc.discordrpc.DiscordRPCManager import at.hannibal2.skyhanni.features.misc.massconfiguration.DefaultConfigFeatures import at.hannibal2.skyhanni.features.misc.visualwords.VisualWordGui -import at.hannibal2.skyhanni.features.slayer.SlayerItemProfitTracker +import at.hannibal2.skyhanni.features.slayer.SlayerProfitTracker import at.hannibal2.skyhanni.test.PacketTest import at.hannibal2.skyhanni.test.SkyHanniConfigSearchResetCommand import at.hannibal2.skyhanni.test.SkyHanniDebugsAndTests @@ -39,12 +49,12 @@ import at.hannibal2.skyhanni.test.command.CopyItemCommand import at.hannibal2.skyhanni.test.command.CopyNearbyEntitiesCommand import at.hannibal2.skyhanni.test.command.CopyNearbyParticlesCommand import at.hannibal2.skyhanni.test.command.CopyScoreboardCommand -import at.hannibal2.skyhanni.test.command.CopyTabListCommand import at.hannibal2.skyhanni.test.command.ErrorManager import at.hannibal2.skyhanni.test.command.TestChatCommand import at.hannibal2.skyhanni.utils.APIUtil import at.hannibal2.skyhanni.utils.LorenzUtils import at.hannibal2.skyhanni.utils.SoundUtils +import at.hannibal2.skyhanni.utils.TabListData import net.minecraft.client.Minecraft import net.minecraft.command.ICommandSender import net.minecraft.event.ClickEvent @@ -58,12 +68,11 @@ object Commands { private val openMainMenu: (Array) -> Unit = { if (it.isNotEmpty()) { if (it[0].lowercase() == "gui") { - GuiEditManager.openGuiPositionEditor() + GuiEditManager.openGuiPositionEditor(hotkeyReminder = true) } else { ConfigGuiManager.openConfigGui(it.joinToString(" ")) } } else { - val arr = mutableListOf() ConfigGuiManager.openConfigGui() } } @@ -147,7 +156,7 @@ object Commands { registerCommand( "shclearslayerprofits", "Clearing the total slayer profit for the current slayer type" - ) { SlayerItemProfitTracker.clearProfitCommand(it) } + ) { SlayerProfitTracker.clearProfitCommand(it) } registerCommand( "shimportghostcounterdata", "Manually importing the ghost counter data from GhostCounterV3" @@ -156,19 +165,28 @@ object Commands { "shclearfarmingitems", "Clear farming items saved for the Farming Fortune Guide" ) { clearFarmingItems() } - registerCommand("shresetghostcounter", "Resets the ghost counter stats") { GhostUtil.reset() } + registerCommand("shresetghostcounter", "Resets the ghost counter") { GhostUtil.reset() } + registerCommand("shresetpowdertracker", "Resets the Powder Tracker") { PowderTracker.resetCommand(it) } + registerCommand("shresetdicertracker", "Resets the Dicer Drop Tracker") { DicerDropTracker.resetCommand(it) } + registerCommand( + "shresetendernodetracker", + "Resets the Ender Node Tracker" + ) { EnderNodeTracker.resetCommand(it) } + registerCommand("shresetarmordroptracker", "Resets the Armor Drop Tracker") { ArmorDropTracker.resetCommand(it) } + registerCommand("shresetfrozentreasuretracker", "Resets the Frozen Treasure Tracker") { FrozenTreasureTracker.resetCommand(it) } + registerCommand("shresetfishingtracker", "Resets the Frozen Treasure Tracker") { FishingProfitTracker.resetCommand(it) } registerCommand("shbingotoggle", "Toggle the bingo card display mode") { BingoCardDisplay.toggleCommand() } registerCommand( "shfarmingprofile", "Look up the farming profile from yourself or another player on elitebot.dev" ) { FarmingWeightDisplay.lookUpCommand(it) } -// registerCommand( -// "shcopytranslation", -// " \n" + -// "Requires the Chat > Translator feature to be enabled.\n" + -// "Copies the translation for a given message to your clipboard. " + -// "Language codes are at the end of the translation when you click on a message." -// ) { Translator.fromEnglish(it) } + registerCommand( + "shcopytranslation", + " \n" + + "Requires the Chat > Translator feature to be enabled.\n" + + "Copies the translation for a given message to your clipboard. " + + "Language codes are at the end of the translation when you click on a message." + ) { Translator.fromEnglish(it) } registerCommand( "shmouselock", "Lock/Unlock the mouse so it will no longer rotate the player (for farming)" @@ -193,6 +211,10 @@ object Commands { "shclearminiondata", "Reset data about minion profit and the name display on the private island" ) { MinionFeatures.clearMinionData() } + registerCommand( + "shwhereami", + "Print current island in chat" + ) { SkyHanniDebugsAndTests.whereami() } registerCommand( "shconfig", "Search or reset config elements §c(warning, dangerous!)" @@ -213,10 +235,18 @@ object Commands { "shcarrot", "Toggles receiving the 12 fortune from carrots" ) { CaptureFarmingGear.reverseCarrotFortune() } + registerCommand( + "shpumpkin", + "Toggles receiving the 12 fortune from pumpkins" + ) { CaptureFarmingGear.reversePumpkinFortune() } registerCommand( "shrepostatus", "Shows the status of all the mods constants" ) { SkyHanniMod.repo.displayRepoStatus(false) } + registerCommand( + "shkingfix", + "Reseting the local King Talisman Helper offset." + ) { KingTalismanHelper.kingFix() } } private fun developersDebugFeatures() { @@ -231,11 +261,13 @@ object Commands { registerCommand( "shconfigsave", "Manually saving the config" - ) { SkyHanniMod.configManager.saveConfig("manual-command") } + ) { SkyHanniMod.configManager.saveConfig(ConfigFileType.FEATURES, "manual-command") } } private fun developersCodingHelp() { registerCommand("shtest", "Unused test command.") { SkyHanniDebugsAndTests.testCommand(it) } + registerCommand("shdebugwaypoint", "Mark a waypoint on that location") { SkyHanniDebugsAndTests.waypoint(it) } + registerCommand("shdebugtablist", "Set your clipboard as a fake tab list.") { TabListData.toggleDebugCommand() } registerCommand("shreloadlocalrepo", "Reloading the local repo data") { SkyHanniMod.repo.reloadLocalRepo() } registerCommand("shchathistory", "Show the unfiltered chat history") { ChatManager.openChatFilterGUI() } registerCommand( @@ -254,7 +286,7 @@ object Commands { "shcopyentities", "Copies entities in the specified radius around the player to the clipboard" ) { CopyNearbyEntitiesCommand.command(it) } - registerCommand("shcopytablist", "Copies the tab list data to the clipboard") { CopyTabListCommand.command(it) } + registerCommand("shcopytablist", "Copies the tab list data to the clipboard") { TabListData.copyCommand(it) } registerCommand( "shcopyscoreboard", "Copies the scoreboard data to the clipboard" @@ -284,6 +316,14 @@ object Commands { "shplaysound", "Play the specified sound effect at the given pitch and volume." ) { SoundUtils.command(it) } + registerCommand( + "shconfigmanagerreset", + "Reloads the config manager and rendering processors of MoulConfig. This §cWILL RESET §7your config, but also updating the java config files (names, description, orderings and stuff)." + ) { SkyHanniDebugsAndTests.configManagerResetCommand(it) } + registerCommand( + "readcropmilestonefromclipboard", + "Read crop milestone from clipboard. This helps fixing wrong crop milestone data" + ) { GardenCropMilestonesCommunityFix.readDataFromClipboard() } } private fun internalCommands() { @@ -293,10 +333,10 @@ object Commands { registerCommand("shsendcontests", "") { GardenNextJacobContest.shareContestConfirmed(it) } registerCommand("shwords", "Opens the config list for modifying visual words") { openVisualWords() } registerCommand("shstopaccountupgradereminder", "") { AccountUpgradeReminder.disable() } -// registerCommand( -// "shsendtranslation", -// "Respond with a translation of the message that the user clicks" -// ) { Translator.toEnglish(it) } + registerCommand( + "shsendtranslation", + "Respond with a translation of the message that the user clicks" + ) { Translator.toEnglish(it) } } private fun shortenedCommands() { @@ -346,7 +386,7 @@ object Commands { @JvmStatic fun openFortuneGuide() { if (!LorenzUtils.inSkyBlock) { - LorenzUtils.chat("§cJoin SkyBlock to open the fortune guide!") + LorenzUtils.userError("Join SkyBlock to open the fortune guide!") } else { CaptureFarmingGear.captureFarmingGear() SkyHanniMod.screenToOpen = FFGuideGUI() @@ -356,17 +396,18 @@ object Commands { @JvmStatic fun openVisualWords() { if (!LorenzUtils.onHypixel) { - LorenzUtils.chat("§cYou need to join Hypixel to use this feature!") + LorenzUtils.userError("You need to join Hypixel to use this feature!") } else { + if (VisualWordGui.sbeConfigPath.exists()) VisualWordGui.drawImport = true SkyHanniMod.screenToOpen = VisualWordGui() } } private fun clearFarmingItems() { - val config = GardenAPI.config?.fortune ?: return - LorenzUtils.chat("§e[SkyHanni] clearing farming items") - config.farmingItems.clear() - config.outdatedItems.clear() + val storage = GardenAPI.storage?.fortune ?: return + LorenzUtils.chat("clearing farming items") + storage.farmingItems.clear() + storage.outdatedItems.clear() } private fun registerCommand(name: String, description: String, function: (Array) -> Unit) { @@ -378,7 +419,7 @@ object Commands { name: String, description: String, function: (Array) -> Unit, - autoComplete: ((Array) -> List) = { listOf() } + autoComplete: ((Array) -> List) = { listOf() }, ) { val command = SimpleCommand( name, diff --git a/src/main/java/at/hannibal2/skyhanni/config/commands/SimpleCommand.kt b/src/main/java/at/hannibal2/skyhanni/config/commands/SimpleCommand.kt index 764f1243d583..bca46dbd6054 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/commands/SimpleCommand.kt +++ b/src/main/java/at/hannibal2/skyhanni/config/commands/SimpleCommand.kt @@ -39,10 +39,10 @@ class SimpleCommand : CommandBase { try { runnable.processCommand(sender, args) } catch (e: Throwable) { - ErrorManager.logError(e, "Error while running command /$commandName") + ErrorManager.logErrorWithData(e, "Error while running command /$commandName") } } override fun addTabCompletionOptions(sender: ICommandSender, args: Array, pos: BlockPos) = if (tabRunnable != null) tabRunnable!!.tabComplete(sender, args, pos) else null -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/core/config/Position.java b/src/main/java/at/hannibal2/skyhanni/config/core/config/Position.java index 329bcd028198..d8b2a7a99803 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/core/config/Position.java +++ b/src/main/java/at/hannibal2/skyhanni/config/core/config/Position.java @@ -31,6 +31,8 @@ public class Position { private int y; @Expose private float scale = 1F; + @Expose + private boolean center = false; @Expose private boolean centerX; @@ -52,6 +54,15 @@ public Position(int x, int y, float scale) { this.scale = scale; } + public Position(int x, int y, float scale, boolean center) { + this.x = x; + this.y = y; + this.centerX = false; + this.centerY = true; + this.scale = scale; + this.center = center; + } + public Position(int x, int y, boolean centerX, boolean centerY) { this.x = x; this.y = y; @@ -65,6 +76,7 @@ public void set(Position other) { this.centerX = other.centerX; this.centerY = other.centerY; this.scale = other.getScale(); + this.center = other.isCenter(); } public float getEffectiveScale() { @@ -76,6 +88,10 @@ public float getScale() { return scale; } + public boolean isCenter() { + return center; + } + public void setScale(float newScale) { scale = Math.max(Math.min(10F, newScale), 0.1f); } diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/About.java b/src/main/java/at/hannibal2/skyhanni/config/features/About.java index 349cb746697f..258ba69852fb 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/features/About.java +++ b/src/main/java/at/hannibal2/skyhanni/config/features/About.java @@ -81,4 +81,4 @@ public static class Licenses { @ConfigEditorButton(buttonText = "GitHub") public Runnable discordRPC = () -> OSUtils.openBrowser("https://github.com/jagrosh/DiscordIPC"); } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/ChatConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/ChatConfig.java deleted file mode 100644 index d400c279f6d0..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/ChatConfig.java +++ /dev/null @@ -1,199 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.FeatureToggle; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; -import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; -import io.github.moulberry.moulconfig.annotations.ConfigOption; -import org.lwjgl.input.Keyboard; - -public class ChatConfig { - - @Expose - @ConfigOption(name = "Peek Chat", desc = "Hold this key to keep the chat open.") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_Z) - public int peekChat = Keyboard.KEY_Z; - - @Expose - @ConfigOption(name = "Chat Filter Types", desc = "") - @Accordion - public FilterTypesConfig filterType = new FilterTypesConfig(); - - public static class FilterTypesConfig { - @Expose - @ConfigOption(name = "Hypixel Hub", desc = "Block messages outside SkyBlock in the Hypixel lobby: player joins, loot boxes, prototype lobby messages, radiating generosity and Hypixel tournaments.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hypixelHub = true; - - @Expose - @ConfigOption(name = "Empty", desc = "Hide all the empty messages from the chat.") - @ConfigEditorBoolean - @FeatureToggle - public boolean empty = true; - - @Expose - @ConfigOption(name = "Warping", desc = "Block 'Sending request to join...' and 'Warping...' messages.") - @ConfigEditorBoolean - @FeatureToggle - public boolean warping = true; - - @Expose - @ConfigOption(name = "Welcome", desc = "Hide the 'Welcome to SkyBlock' message.") - @ConfigEditorBoolean - @FeatureToggle - public boolean welcome = true; - - @Expose - @ConfigOption(name = "Guild Exp", desc = "Hide Guild EXP messages.") - @ConfigEditorBoolean - @FeatureToggle - public boolean guildExp = true; - - @Expose - @ConfigOption(name = "Friend Join Left", desc = "Hide friend join/left messages.") - @ConfigEditorBoolean - @FeatureToggle - public boolean friendJoinLeft = false; - - @Expose - @ConfigOption(name = "Winter Gifts", desc = "Hide useless Winter Gift messages.") - @ConfigEditorBoolean - @FeatureToggle - public boolean winterGift = false; - - @Expose - @ConfigOption(name = "Powder Mining", desc = "Hide messages while opening chests in the Crystal Hollows. " + - "(Except powder numbers over 1k, essence numbers over 2, Prehistoric Eggs, and Automaton Parts)") - @ConfigEditorBoolean - @FeatureToggle - public boolean powderMining = true; - - @Expose - @ConfigOption(name = "Kill Combo", desc = "Hide messages about the current Kill Combo from the Grandma Wolf Pet.") - @ConfigEditorBoolean - @FeatureToggle - public boolean killCombo = false; - - @Expose - @ConfigOption(name = "Watchdog", desc = "Hide the message where Hypixel is flexing how many players they have banned over the last week.") - @ConfigEditorBoolean - @FeatureToggle - public boolean watchDog = true; - - @Expose - @ConfigOption(name = "Profile Join", desc = "Hide 'You are playing on profile' and 'Profile ID' chat messages.") - @ConfigEditorBoolean - @FeatureToggle - public boolean profileJoin = true; - - //TODO remove - @Expose - @ConfigOption(name = "Others", desc = "Hide other annoying messages.") - @ConfigEditorBoolean - @FeatureToggle - public boolean others = false; - } - - @Expose - @ConfigOption(name = "Player Messages", desc = "") - @Accordion - public PlayerMessagesConfig playerMessage = new PlayerMessagesConfig(); - - public static class PlayerMessagesConfig { - @Expose - @ConfigOption(name = "Player Rank Hider", desc = "Hide player ranks in all chat messages.") - @ConfigEditorBoolean - @FeatureToggle - public boolean playerRankHider = false; - - @Expose - @ConfigOption(name = "Chat Filter", desc = "Scan messages sent by players for blacklisted words and gray out the message if any are found.") - @ConfigEditorBoolean - @FeatureToggle - public boolean chatFilter = false; - } - - @Expose - @ConfigOption(name = "Player Chat Symbols", desc = "") - @Accordion - public ChatSymbols chatSymbols = new ChatSymbols(); - - public static class ChatSymbols { - - @Expose - @ConfigOption(name = "Enabled", desc = "Adds extra symbols to the chat such as those from ironman, " + - "stranded, bingo or nether factions and places them next to your regular player emblems. " + - "§cDoes not work with hide rank hider!") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Chat Symbol Location", desc = "Determines where the symbols should go in chat in relation to the " + - "player's name. Hidden will hide all emblems from the chat. §eRequires above setting to be on to hide the symbols.") - @ConfigEditorDropdown(values = {"Left", "Right", "Hidden"}) - public int symbolLocation = 0; - } - - @Expose - @ConfigOption(name = "Dungeon Filter", desc = "Hide annoying messages in Dungeons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean dungeonMessages = true; - - @Expose - @ConfigOption(name = "Dungeon Boss Messages", desc = "Hide messages from the Watcher and bosses in the Dungeon.") - @ConfigEditorBoolean - @FeatureToggle - public boolean dungeonBossMessages = false; - - @Expose - @ConfigOption(name = "Hide Far Deaths", desc = "Hide other players' death messages, " + - "except for players who are nearby or during Dungeons/a Kuudra fight.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideFarDeathMessages = false; - //TODO jawbus + thunder - - @Expose - @ConfigOption(name = "Compact Potion Message", desc = "Shorten chat messages about player potion effects.") - @ConfigEditorBoolean - @FeatureToggle - public boolean compactPotionMessage = true; - - @Expose - @ConfigOption(name = "Compact Bestiary Message", desc = "Shorten the Bestiary level up message, showing additional information when hovering.") - @ConfigEditorBoolean - @FeatureToggle - public boolean compactBestiaryMessage = true; - - @Expose - @ConfigOption(name = "Arachne Hider", desc = "Hide chat messages about the Arachne Fight while outside of §eArachne's Sanctuary§7.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideArachneMessages = false; - - @Expose - @ConfigOption( - name = "Sacks Hider", - desc = "Hide the chat's sack change message with this, " + - "not in Hypixel settings, for mods to access sack data in new features." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean hideSacksChange = false; - -// @Expose -// @ConfigOption( -// name = "Translator", -// desc = "Click on a message to translate it into English. " + -// "Use §e/shcopytranslation§7 to get the translation from English. " + -// "§cTranslation is not guaranteed to be 100% accurate." -// ) -// @ConfigEditorBoolean -// @FeatureToggle -// public boolean translator = false; -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/CombatConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/CombatConfig.java deleted file mode 100644 index 458e3daf7de4..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/CombatConfig.java +++ /dev/null @@ -1,721 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.FeatureToggle; -import at.hannibal2.skyhanni.config.core.config.Position; -import at.hannibal2.skyhanni.features.combat.ghostcounter.GhostFormatting; -import at.hannibal2.skyhanni.features.combat.ghostcounter.GhostUtil; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorButton; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; -import io.github.moulberry.moulconfig.annotations.ConfigEditorInfoText; -import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; -import io.github.moulberry.moulconfig.annotations.ConfigEditorText; -import io.github.moulberry.moulconfig.annotations.ConfigOption; -import io.github.moulberry.moulconfig.observer.Property; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; - -public class CombatConfig { - - @Expose - @ConfigOption(name = "Damage Indicator", desc = "") - @Accordion - public DamageIndicatorConfig damageIndicator = new DamageIndicatorConfig(); - - public static class DamageIndicatorConfig { - - @Expose - @ConfigOption(name = "Damage Indicator Enabled", desc = "Show the boss' remaining health.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Healing Chat Message", desc = "Sends a chat message when a boss heals themself.") - @ConfigEditorBoolean - public boolean healingMessage = false; - - @Expose - @ConfigOption( - name = "Boss Name", - desc = "Change how the boss name should be displayed.") - @ConfigEditorDropdown(values = {"Hidden", "Full Name", "Short Name"}) - public int bossName = 1; - - @Expose - @ConfigOption( - name = "Select Boss", - desc = "Change what type of boss you want the damage indicator be enabled for." - ) - @ConfigEditorDraggableList( - exampleText = { - "§bDungeon All", - "§bNether Mini Bosses", - "§bVanquisher", - "§bEndstone Protector (not tested)", - "§bEnder Dragon (not finished)", - "§bRevenant Horror", - "§bTarantula Broodfather", - "§bSven Packmaster", - "§bVoidgloom Seraph", - "§bInferno Demonlord (only tier 1 yet)", - "§bHeadless Horseman (bugged)", - "§bDungeon Floor 1", - "§bDungeon Floor 2", - "§bDungeon Floor 3", - "§bDungeon Floor 4", - "§bDungeon Floor 5", - "§bDungeon Floor 6", - "§bDungeon Floor 7", - "§bDiana Mobs", - "§bSea Creatures", - "Dummy", - "§bArachne", - "§bThe Rift Bosses", - "§bRiftstalker Bloodfiend", - "§6Reindrake" - } - ) - //TODO only show currently working and tested features - public List bossesToShow = new ArrayList<>(Arrays.asList(0, 1, 2, 5, 6, 7, 8, 9, 18, 19, 21, 22, 23, 24)); - - @Expose - @ConfigOption(name = "Hide Damage Splash", desc = "Hiding damage splashes near the damage indicator.") - @ConfigEditorBoolean - public boolean hideDamageSplash = false; - - @Expose - @ConfigOption(name = "Damage Over Time", desc = "Show damage and health over time below the damage indicator.") - @ConfigEditorBoolean - public boolean showDamageOverTime = false; - - @Expose - @ConfigOption(name = "Hide Nametag", desc = "Hide the vanilla nametag of damage indicator bosses.") - @ConfigEditorBoolean - public boolean hideVanillaNametag = false; - - @Expose - @ConfigOption(name = "Time to Kill", desc = "Show the time it takes to kill the slayer boss.") - @ConfigEditorBoolean - public boolean timeToKillSlayer = true; - - - @Expose - @ConfigOption(name = "Ender Slayer", desc = "") - @Accordion - public EnderSlayerConfig enderSlayer = new EnderSlayerConfig(); - - public static class EnderSlayerConfig { - - @Expose - @ConfigOption(name = "Laser Phase Timer", desc = "Show a timer when the laser phase will end.") - @ConfigEditorBoolean - public boolean laserPhaseTimer = false; - - @Expose - @ConfigOption(name = "Health During Laser", desc = "Show the health of Voidgloom Seraph 4 during the laser phase.") - @ConfigEditorBoolean - public boolean showHealthDuringLaser = false; - } - - @Expose - @ConfigOption(name = "Vampire Slayer", desc = "") - @Accordion - public VampireSlayerConfig vampireSlayer = new VampireSlayerConfig(); - - public static class VampireSlayerConfig { - @Expose - @ConfigOption(name = "HP Until Steak", desc = "Show the amount of HP missing until the Steak can be used on the Vampire Slayer on top of the boss.") - @ConfigEditorBoolean - public boolean hpTillSteak = false; - - @Expose - @ConfigOption(name = "Mania Circles", desc = "Show a timer until the boss leaves the invincible Mania Circles state.") - @ConfigEditorBoolean - public boolean maniaCircles = false; - - @Expose - @ConfigOption(name = "Percentage HP", desc = "Show the percentage of HP next to the HP.") - @ConfigEditorBoolean - public boolean percentage = false; - } - } - - @Expose - @ConfigOption(name = "Ghost Counter", desc = "") - @Accordion - public GhostCounterConfig ghostCounter = new GhostCounterConfig(); - - public static class GhostCounterConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Enable the ghost counter (invisible creepers in the Dwarven Mines The Mist area).") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption( - name = "Display Text", - desc = "Drag text to change the appearance of the overlay." - ) - @ConfigEditorDraggableList( - exampleText = { - "§6Ghosts Counter", - " §bGhost Killed: 42", - " §bSorrow: 6", - " §bGhost since Sorrow: 1", - " §bGhosts/Sorrow: 5", - " §bVolta: 6", - " §bPlasma: 8", - " §bGhostly Boots: 1", - " §bBag Of Cash: 4", - " §bAvg Magic Find: 271", - " §bScavenger Coins: 15,000", - " §bKill Combo: 14", - " §bHighest Kill Combo: 96", - " §bSkill XP Gained: 145,648", - " §bBestiary 1: 0/10", - " §bXP/h: 810,410", - " §bKills/h: 420", - " §bETA: 14d", - " §bMoney/h: 13,420,069", - " §bMoney made: 14B" - } - ) - public List ghostDisplayText = new ArrayList<>(Arrays.asList(0, 1, 2, 3, 4, 9, 10, 11, 12)); - - @ConfigOption(name = "Text Formatting", desc = "") - @Accordion - @Expose - public TextFormattingConfig textFormatting = new TextFormattingConfig(); - - public static class TextFormattingConfig { - - @ConfigOption(name = "§eText Formatting Info", desc = "§e%session% §ris §e§lalways §rreplaced with\n" + - "§7the count for your current session.\n" + - "§7Reset when restarting the game.\n" + - "§7You can use §e&Z §7color code to use SBA chroma.") - @ConfigEditorInfoText - public boolean formatInfo = false; - - @ConfigOption(name = "Reset Formatting", desc = "Reset formatting to default text.") - @ConfigEditorButton(buttonText = "Reset") - public Runnable resetFormatting = GhostFormatting.INSTANCE::reset; - - @ConfigOption(name = "Export Formatting", desc = "Export current formatting to clipboard.") - @ConfigEditorButton(buttonText = "Export") - public Runnable exportFormatting = GhostFormatting.INSTANCE::export; - - @ConfigOption(name = "Import Formatting", desc = "Import formatting from clipboard.") - @ConfigEditorButton(buttonText = "Import") - public Runnable importFormatting = GhostFormatting.INSTANCE::importFormat; - - @Expose - @ConfigOption(name = "Title", desc = "Title Line.") - @ConfigEditorText - public String titleFormat = "&6Ghost Counter"; - - @Expose - @ConfigOption(name = "Ghost Killed", desc = "Ghost Killed line.\n§e%value% §ris replaced with\n" + - "Ghost Killed.\n" + - "§e%session% §7is replaced with Ghost killed") - @ConfigEditorText - public String ghostKilledFormat = " &6Ghost Killed: &b%value% &7(%session%)"; - - @Expose - @ConfigOption(name = "Sorrows", desc = "Sorrows drop line.\n" + - "§e%value% §7is replaced with\nsorrows dropped.") - @ConfigEditorText - public String sorrowsFormat = " &6Sorrow: &b%value% &7(%session%)"; - - @Expose - @ConfigOption(name = "Ghost Since Sorrow", desc = "Ghost Since Sorrow line.\n" + - "§e%value% §7is replaced with\nGhost since last sorrow drop.") - @ConfigEditorText - public String ghostSinceSorrowFormat = " &6Ghost since Sorrow: &b%value%"; - - @Expose - @ConfigOption(name = "Ghost Kill Per Sorrow", desc = "Ghost Kill Per Sorrow line.\n" + - "§e%value% §7is replaced with\naverage ghost kill per sorrow drop.") - @ConfigEditorText - public String ghostKillPerSorrowFormat = " &6Ghosts/Sorrow: &b%value%"; - - @Expose - @ConfigOption(name = "Voltas", desc = "Voltas drop line.\n" + - "§e%value% §7is replaced with\nvoltas dropped.") - @ConfigEditorText - public String voltasFormat = " &6Voltas: &b%value% &7(%session%)"; - - @Expose - @ConfigOption(name = "Plasmas", desc = "Plasmas drop line.\n" + - "§e%value% §7is replaced with\nplasmas dropped.") - @ConfigEditorText - public String plasmasFormat = " &6Plasmas: &b%value% &7(%session%)"; - - @Expose - @ConfigOption(name = "Ghostly Boots", desc = "Ghostly Boots drop line.\n" + - "§e%value% §7is replaced with\nGhostly Boots dropped.") - @ConfigEditorText - public String ghostlyBootsFormat = " &6Ghostly Boots: &b%value% &7(%session%)"; - - @Expose - @ConfigOption(name = "Bag Of Cash", desc = "Bag Of Cash drop line.\n" + - "§e%value% §7is replaced with\nBag Of Cash dropped.") - @ConfigEditorText - public String bagOfCashFormat = " &6Bag Of Cash: &b%value% &7(%session%)"; - - @Expose - @ConfigOption(name = "Average Magic Find", desc = "Average Magic Find line.\n" + - "§e%value% §7is replaced with\nAverage Magic Find.") - @ConfigEditorText - public String avgMagicFindFormat = " &6Avg Magic Find: &b%value%"; - - @Expose - @ConfigOption(name = "Scavenger Coins", desc = "Scavenger Coins line.\n" + - "§e%value% §7is replaced with\nCoins earned from kill ghosts.\nInclude: Scavenger Enchant, Scavenger Talismans, Kill Combo.") - @ConfigEditorText - public String scavengerCoinsFormat = " &6Scavenger Coins: &b%value% &7(%session%)"; - - @Expose - @ConfigOption(name = "Kill Combo", desc = "Kill Combo line.\n" + - "§e%value% §7is replaced with\nYour current kill combo.") - @ConfigEditorText - public String killComboFormat = " &6Kill Combo: &b%value%"; - - @Expose - @ConfigOption(name = "Highest Kill Combo", desc = "Highest Kill Combo line.\n" + - "§e%value% §7is replaced with\nYour current highest kill combo.") - @ConfigEditorText - public String highestKillComboFormat = " &6Highest Kill Combo: &b%value% &7(%session%)"; - - @Expose - @ConfigOption(name = "Skill XP Gained", desc = "Skill XP Gained line.\n" + - "§e%value% §7is replaced with\nSkill XP Gained from killing Ghosts.") - @ConfigEditorText - public String skillXPGainFormat = " &6Skill XP Gained: &b%value% &7(%session%)"; - - @ConfigOption(name = "Bestiary Formatting", desc = "") - @Accordion - @Expose - public BestiaryFormattingConfig bestiaryFormatting = new BestiaryFormattingConfig(); - - public static class BestiaryFormattingConfig { - - @Expose - @ConfigOption(name = "Bestiary", desc = "Bestiary Progress line.\n§e%value% §7is replaced with\n" + - "Your current progress to next level.\n" + - "§e%currentLevel% &7is replaced with your current bestiary level\n" + - "§e%nextLevel% §7is replaced with your current bestiary level +1.\n" + - "§e%value% §7is replaced with one of the text below.") - @ConfigEditorText - public String base = " &6Bestiary %display%: &b%value%"; - - @Expose - @ConfigOption(name = "No Data", desc = "Text to show when you need to open the\nBestiary Menu to gather data.") - @ConfigEditorText - public String openMenu = "§cOpen Bestiary Menu !"; - - @Expose - @ConfigOption(name = "Maxed", desc = "Text to show when your bestiary for ghost is at max level.\n" + - "§e%currentKill% §7is replaced with your current total kill.") - @ConfigEditorText - public String maxed = "%currentKill% (&c&lMaxed!)"; - - @Expose - @ConfigOption(name = "Progress to Max", desc = "Text to show progress when the §eMaxed Bestiary §7option is §aON\n" + - "§e%currentKill% §7is replaced with your current total kill.") - @ConfigEditorText - public String showMax_progress = "%currentKill%/250k (%percentNumber%%)"; - - @Expose - @ConfigOption(name = "Progress", desc = "Text to show progress when the §eMaxed Bestiary§7 option is §cOFF\n" + - "§e%currentKill% §7is replaced with how many kill you have to the next level.\n" + - "§e%killNeeded% §7is replaced with how many kill you need to reach the next level.") - @ConfigEditorText - public String progress = "%currentKill%/%killNeeded%"; - } - - - @ConfigOption(name = "XP Per Hour Formatting", desc = "") - @Accordion - @Expose - public XPHourFormattingConfig xpHourFormatting = new XPHourFormattingConfig(); - - public static class XPHourFormattingConfig { - - @Expose - @ConfigOption(name = "XP/h", desc = "XP Per Hour line.\n" + - "§e%value% §7is replaced with one of the text below.") - @ConfigEditorText - public String base = " &6XP/h: &b%value%"; - - @Expose - @ConfigOption(name = "No Data", desc = "XP Per Hour line.\n§e%value% §7is replaced with\nEstimated amount of combat xp you gain per hour.") - @ConfigEditorText - public String noData = "&bN/A"; - - @Expose - @ConfigOption(name = "Paused", desc = "Text displayed next to the time \n" + - "when you are doing nothing for a given amount of seconds") - @ConfigEditorText - public String paused = "&c(PAUSED)"; - } - - - @ConfigOption(name = "ETA Formatting", desc = "") - @Accordion - @Expose - public ETAFormattingConfig etaFormatting = new ETAFormattingConfig(); - - public static class ETAFormattingConfig { - @Expose - @ConfigOption(name = "ETA to next level", desc = "ETA To Next Level Line.\n" + - "§e%value% §7is replaced with one of the text below.") - @ConfigEditorText - public String base = " &6ETA: &b%value%"; - - @Expose - @ConfigOption(name = "Maxed!", desc = "So you really maxed ghost bestiary ?") - @ConfigEditorText - public String maxed = "&c&lMAXED!"; - - @Expose - @ConfigOption(name = "No Data", desc = "Start killing some ghosts !") - @ConfigEditorText - public String noData = "&bN/A"; - - @Expose - @ConfigOption(name = "Progress", desc = "Text to show progress to next level.") - @ConfigEditorText - public String progress = "&b%value%"; - - @Expose - @ConfigOption(name = "Paused", desc = "Text displayed next to the time \n" + - "when you are doing nothing for a given amount of seconds") - @ConfigEditorText - public String paused = "&c(PAUSED)"; - - @Expose - @ConfigOption(name = "Time", desc = "§e%days% §7is replaced with days remaining.\n" + - "§e%hours% §7is replaced with hours remaining.\n" + - "§e%minutes% §7is replaced with minutes remaining.\n" + - "§e%seconds% §7is replaced with seconds remaining.") - @ConfigEditorText - public String time = "&6%days%%hours%%minutes%%seconds%"; - } - - @ConfigOption(name = "Kill Per Hour Formatting", desc = "") - @Expose - @Accordion - public KillHourFormattingConfig killHourFormatting = new KillHourFormattingConfig(); - - public static class KillHourFormattingConfig { - @Expose - @ConfigOption(name = "Kill/h", desc = "Kill Per Hour line.\n§e%value% §7is replaced with\nEstimated kills per hour you get.") - @ConfigEditorText - public String base = " &6Kill/h: &b%value%"; - - @Expose - @ConfigOption(name = "No Data", desc = "Start killing some ghosts !") - @ConfigEditorText - public String noData = "&bN/A"; - - @Expose - @ConfigOption(name = "Paused", desc = "Text displayed next to the time \n" + - "when you are doing nothing for a given amount of seconds") - @ConfigEditorText - public String paused = "&c(PAUSED)"; - } - - - @Expose - @ConfigOption(name = "Money Per Hour", desc = "Money Per Hour.\n§e%value% §7is replaced with\nEstimated money you get per hour\n" + - "Calculated with your kill per hour and your average magic find.") - @ConfigEditorText - public String moneyHourFormat = " &6$/h: &b%value%"; - - @Expose - @ConfigOption(name = "Money made", desc = "Calculate the money you made.\nInclude §eSorrow§7, §ePlasma§7, §eVolta§7, §e1M coins drop\n" + - "§eGhostly Boots§7, §eScavenger coins.\n" + - "§cUsing current Sell Offer value.") - @ConfigEditorText - public String moneyMadeFormat = " &6Money made: &b%value%"; - } - - @Expose - @ConfigOption(name = "Extra space", desc = "Space between each line of text.") - @ConfigEditorSlider( - minValue = -5, - maxValue = 10, - minStep = 1) - public int extraSpace = 1; - - @Expose - @ConfigOption(name = "Pause Timer", desc = "How many seconds does it wait before pausing.") - @ConfigEditorSlider( - minValue = 1, - maxValue = 20, - minStep = 1 - ) - public int pauseTimer = 3; - - @Expose - @ConfigOption(name = "Show only in The Mist", desc = "Show the overlay only when you are in The Mist.") - @ConfigEditorBoolean - public boolean onlyOnMist = true; - - @Expose - @ConfigOption(name = "Maxed Bestiary", desc = "Show progress to max bestiary instead of next level.") - @ConfigEditorBoolean - public boolean showMax = false; - - @ConfigOption(name = "Reset", desc = "Reset the counter.") - @ConfigEditorButton(buttonText = "Reset") - public Runnable resetCounter = GhostUtil.INSTANCE::reset; - - @Expose - public Position position = new Position(50, 50, false, true); - } - - @Expose - @ConfigOption(name = "Summonings", desc = "") - @Accordion - public SummoningsConfig summonings = new SummoningsConfig(); - - public static class SummoningsConfig { - - @Expose - @ConfigOption(name = "Summoning Soul Display", desc = "Show the name of dropped Summoning Souls laying on the ground. " + - "§cNot working in Dungeons if Skytils' 'Hide Non-Starred Mobs Nametags' feature is enabled!") - @ConfigEditorBoolean - @FeatureToggle - public boolean summoningSoulDisplay = false; - - @Expose - @ConfigOption(name = "Summoning Mob Display", desc = "Show the health of your spawned summons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean summoningMobDisplay = false; - - @Expose - public Position summoningMobDisplayPos = new Position(10, 10, false, true); - - @Expose - @ConfigOption(name = "Summoning Mob Nametag", desc = "Hide the nametag of your spawned summons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean summoningMobHideNametag = false; - - @Expose - @ConfigOption(name = "Summoning Mob Color", desc = "Marks own summons green.") - @ConfigEditorBoolean - @FeatureToggle - public boolean summoningMobColored = false; - } - - @Expose - @ConfigOption(name = "Mobs", desc = "") - @Accordion - public MobsConfig mobs = new MobsConfig(); - - public static class MobsConfig { - - @Expose - @ConfigOption(name = "Highlighters", desc = "") - public boolean highlighters = false; - - @Expose - @ConfigOption(name = "Area Boss", desc = "Highlight Golden Ghoul, Old Wolf, Voidling Extremist and Millenia-Aged Blaze.") - @ConfigEditorBoolean - @FeatureToggle - public boolean areaBossHighlight = true; - - @Expose - @ConfigOption(name = "Arachne Keeper", desc = "Highlight the Arachne Keeper in the Spider's Den in purple color.") - @ConfigEditorBoolean - @FeatureToggle - public boolean arachneKeeperHighlight = true; - - @Expose - @ConfigOption(name = "Corleone", desc = "Highlight Boss Corleone in the Crystal Hollows.") - @ConfigEditorBoolean - @FeatureToggle - public boolean corleoneHighlighter = true; - - @Expose - @ConfigOption(name = "Zealot", desc = "Highlight Zealots and Bruisers in The End.") - @ConfigEditorBoolean - @FeatureToggle - public boolean zealotBruiserHighlighter = false; - - @Expose - @ConfigOption( - name = "Special Zealots", - desc = "Highlight Special Zealots (the ones that drop Summoning Eyes) in the End." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean specialZealotHighlighter = true; - - @Expose - @ConfigOption(name = "Corrupted Mob", desc = "Highlight corrupted mobs in purple color.") - @ConfigEditorBoolean - @FeatureToggle - public boolean corruptedMobHighlight = false; - - @Expose - @ConfigOption(name = "Arachne Boss", desc = "Highlight the Arachne boss in red and mini-bosses in orange.") - @ConfigEditorBoolean - @FeatureToggle - public boolean arachneBossHighlighter = true; - - @Expose - @ConfigOption(name = "Respawn Timers", desc = "") - public boolean timers = false; - - @Expose - @ConfigOption( - name = "Area Boss", - desc = "Show a timer when Golden Ghoul, Old Wolf, Voidling Extremist or Millenia-Aged Blaze respawns. " + - "§cSometimes it takes 20-30 seconds to calibrate correctly." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean areaBossRespawnTimer = false; - - @Expose - @ConfigOption( - name = "Arachne Spawn Timer", - desc = "Show a timer when Arachne fragments or crystals are placed to indicate how long " + - "until the boss will spawn. §cTimer may be 1-2 seconds off." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean showArachneSpawnTimer = true; - - @Expose - @ConfigOption(name = "Enderman TP Hider", desc = "Stops the Enderman Teleportation animation.") - @ConfigEditorBoolean - @FeatureToggle - public boolean endermanTeleportationHider = true; - - @Expose - @ConfigOption(name = "Arachne Minis Hider", desc = "Hides the nametag above Arachne minis.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideNameTagArachneMinis = true; - } - - @Expose - @ConfigOption(name = "Bestiary", desc = "") - @Accordion - public BestiaryConfig bestiary = new BestiaryConfig(); - - public static class BestiaryConfig { - @Expose - @ConfigOption(name = "Enable", desc = "Show Bestiary Data overlay in the Bestiary menu.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Number format", desc = "Short: 1.1k\nLong: 1.100") - @ConfigEditorDropdown(values = {"Short", "Long"}) - public int numberFormat = 0; - - @Expose - @ConfigOption(name = "Display type", desc = "Choose what the display should show") - @ConfigEditorDropdown(values = { - "Global to max", - "Global to next tier", - "Lowest total kills", - "Highest total kills", - "Lowest kills needed to max", - "Highest kills needed to max", - "Lowest kills needed to next tier", - "Highest kills needed to next tier" - }) - public int displayType = 0; - - @Expose - @ConfigOption(name = "Hide maxed", desc = "Hide maxed mobs.") - @ConfigEditorBoolean - public boolean hideMaxed = false; - - @Expose - @ConfigOption(name = "Replace Romans", desc = "Replace Roman numerals (IX) with regular numbers (9)") - @ConfigEditorBoolean - public boolean replaceRoman = false; - - @Expose - public Position position = new Position(100, 100, false, true); - } - - @Expose - @ConfigOption(name = "Ender Node Tracker", desc = "") - @Accordion - public EnderNodeConfig enderNodeTracker = new EnderNodeConfig(); - - public static class EnderNodeConfig { - @Expose - @ConfigOption( - name = "Enabled", - desc = "Tracks all of your drops from mining Ender Nodes in the End.\n" + - "Also tracks drops from Endermen." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption( - name = "Text Format", - desc = "Drag text to change the appearance of the overlay." - ) - @ConfigEditorDraggableList( - exampleText = { - "§5§lEnder Node Tracker", - "§d1,303 Ender Nodes Mined", - "§615.3M Coins Made", - " ", - "§b123 §cEndermite Nest", - "§b832 §aEnchanted End Stone", - "§b230 §aEnchanted Obsidian", - "§b1630 §aEnchanted Ender Pearl", - "§b85 §aGrand Experience Bottle", - "§b4 §9Titanic Experience Bottle", - "§b15 §9End Stone Shulker", - "§b53 §9End Stone Geode", - "§b10 §d◆ Magical Rune I", - "§b24 §5Ender Gauntlet", - "§b357 §5Mite Gel", - "§b2 §cShrimp The Fish", - " ", - "§b200 §5Ender Armor", - "§b24 §5Ender Helmet", - "§b24 §5Ender Chestplate", - "§b24 §5Ender Leggings", - "§b24 §5Ender Boots", - "§b24 §5Ender Necklace", - "§f10§7-§a8§7-§93§7-§52§7-§61 §fEnderman Pet", - " " - } - ) - public Property> textFormat = Property.of(new ArrayList<>(Arrays.asList(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 14, 15, 16, 17, 23))); - - @Expose - public Position position = new Position(10, 80, false, true); - } - - @Expose - @ConfigOption(name = "Hide Damage Splash", desc = "Hide all damage splashes anywhere in SkyBlock.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideDamageSplash = false; -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/CommandsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/CommandsConfig.java deleted file mode 100644 index cb127dc11435..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/CommandsConfig.java +++ /dev/null @@ -1,115 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.FeatureToggle; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; -import io.github.moulberry.moulconfig.annotations.ConfigOption; -import org.lwjgl.input.Keyboard; - -public class CommandsConfig { - - @ConfigOption(name = "Tab Complete", desc = "") - @Accordion - @Expose - public TabCompleteConfig tabComplete = new TabCompleteConfig(); - - public static class TabCompleteConfig { - - @Expose - @ConfigOption(name = "Warps", desc = "Tab complete the warp-point names when typing §e/warp §7.") - @ConfigEditorBoolean - @FeatureToggle - public boolean warps = true; - - @Expose - @ConfigOption(name = "Island Players", desc = "Tab complete other players on the same island.") - public boolean islandPlayers = true; - - @Expose - @ConfigOption(name = "Friends", desc = "Tab complete friends from your friends list.") - @ConfigEditorBoolean - @FeatureToggle - public boolean friends = true; - - @Expose - @ConfigOption(name = "Only Best Friends", desc = "Only Tab Complete best friends.") - @ConfigEditorBoolean - @FeatureToggle - public boolean onlyBestFriends = false; - - @Expose - @ConfigOption(name = "Party", desc = "Tab complete Party Members.") - @ConfigEditorBoolean - @FeatureToggle - public boolean party = true; - - @Expose - @ConfigOption(name = "VIP Visits", desc = "Tab complete the visit to special users with cake souls on it.") - @ConfigEditorBoolean - @FeatureToggle - public boolean vipVisits = true; - - @Expose - @ConfigOption(name = "/gfs Sack", desc = "Tab complete §e/gfs §7sack items.") - @ConfigEditorBoolean - @FeatureToggle - public boolean gfsSack = true; - - @Expose - @ConfigOption(name = "Party Commands", desc = "Tab complete commonly used party commands.") - @ConfigEditorBoolean - @FeatureToggle - public boolean partyCommands = true; - - @Expose - @ConfigOption(name = "View Recipe", desc = "Tab complete item IDs in the the Hypixel command §e/viewrecipe§7. Only items with recipes are tab completed.") - @ConfigEditorBoolean - @FeatureToggle - public boolean viewrecipeItems = true; - } - - @ConfigOption(name = "Fandom Wiki for §e/wiki", desc = "") - @Accordion - @Expose - public FandomWikiCommmandConfig fandomWiki = new FandomWikiCommmandConfig(); - - public static class FandomWikiCommmandConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Use Fandom Wiki (§ehypixel-skyblock.fandom.com§7) instead of the Hypixel wiki (§ewiki.hypixel.net§7) in most wiki-related chat messages.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Skip Chat", desc = "Directly opens the Fandom Wiki instead of sending the §e\"Click to search for this thing on the Fandom Wiki\"§7 message beforehand.") - @ConfigEditorBoolean - public boolean skipWikiChat = false; - - @Expose - @ConfigOption(name = "Fandom Wiki Key", desc = "Search for an item on Fandom Wiki with this keybind.\n§4For optimal experiences, do §lNOT§r §4bind this to a mouse button.") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) - public int fandomWikiKeybind = Keyboard.KEY_NONE; - } - - @ConfigOption(name = "Party Commands", desc = "Shortens party commands and allows tab-completing for them. " + - "\n§eCommands: /pt /pp /pko /pk §7SkyBlock command §e/pt §7to check the play time still works.") - @Expose - @ConfigEditorBoolean - @FeatureToggle - public boolean shortCommands = true; - - @Expose - @ConfigOption(name = "Replace Warp Is", desc = "Adds §e/warp is §7alongside §e/is§7. Idk why. Ask §cKaeso") - @ConfigEditorBoolean - @FeatureToggle - public boolean replaceWarpIs = false; - - @Expose - @ConfigOption(name = "/viewrecipe Lower Case", desc = "Adds support for lower case item IDs to the Hypixel command §e/viewrecipe§7.") - @ConfigEditorBoolean - @FeatureToggle - public boolean viewRecipeLowerCase = true; -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/CrimsonIsleConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/CrimsonIsleConfig.java deleted file mode 100644 index b9d00f8cdf28..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/CrimsonIsleConfig.java +++ /dev/null @@ -1,151 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.FeatureToggle; -import at.hannibal2.skyhanni.config.core.config.Position; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; -import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; -import io.github.moulberry.moulconfig.annotations.ConfigOption; -import org.lwjgl.input.Keyboard; - -public class CrimsonIsleConfig { - - @ConfigOption(name = "Ashfang", desc = "") - @Accordion - @Expose - public AshfangConfig ashfang = new AshfangConfig(); - - public static class AshfangConfig { - - @ConfigOption(name = "Gravity Orbs", desc = "") - @Accordion - @Expose - public GravityOrbsConfig gravityOrbs = new GravityOrbsConfig(); - - public static class GravityOrbsConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Shows the Gravity Orbs more clearly.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Color", desc = "Color of the Gravity Orbs.") - @ConfigEditorColour - public String color = "0:120:255:85:85"; - } - - @ConfigOption(name = "Blazing Souls", desc = "") - @Accordion - @Expose - public BlazingSoulsColor blazingSouls = new BlazingSoulsColor(); - - public static class BlazingSoulsColor { - - @Expose - @ConfigOption(name = "Enabled", desc = "Shows the Blazing Souls more clearly.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Souls Color", desc = "Color of the Blazing Souls.") - @ConfigEditorColour - public String color = "0:245:85:255:85"; - } - - @ConfigOption(name = "Hide Stuff", desc = "") - @Accordion - @Expose - public HideAshfangConfig hide = new HideAshfangConfig(); - - public static class HideAshfangConfig { - - @Expose - @ConfigOption(name = "Hide Particles", desc = "Hide particles around the Ashfang boss.") - @ConfigEditorBoolean - @FeatureToggle - public boolean particles = false; - - @Expose - @ConfigOption(name = "Hide Full Names", desc = "Hide the names of full health blazes around Ashfang (only useful when highlight blazes is enabled)") - @ConfigEditorBoolean - @FeatureToggle - public boolean fullNames = false; - - @Expose - @ConfigOption(name = "Hide Damage Splash", desc = "Hide damage splashes around Ashfang.") - @ConfigEditorBoolean - @FeatureToggle - public boolean damageSplash = false; - } - - @Expose - @ConfigOption(name = "Highlight Blazes", desc = "Highlight the different blazes in their respective colors.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlightBlazes = false; - - @Expose - @ConfigOption(name = "Freeze Cooldown", desc = "Show the cooldown for how long Ashfang blocks your abilities.") - @ConfigEditorBoolean - @FeatureToggle - public boolean freezeCooldown = false; - - @Expose - public Position freezeCooldownPos = new Position(10, 10, false, true); - - @Expose - @ConfigOption(name = "Reset Time", desc = "Show the cooldown until Ashfang pulls his underlings back.") - @ConfigEditorBoolean - @FeatureToggle - public boolean nextResetCooldown = false; - - @Expose - public Position nextResetCooldownPos = new Position(10, 10, false, true); - } - - @ConfigOption(name = "Reputation Helper", desc = "") - @Accordion - @Expose - public ReputationHelperConfig reputationHelper = new ReputationHelperConfig(); - - public static class ReputationHelperConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Enable features around Reputation features in the Crimson Isle.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Use Hotkey", desc = "Only show the Reputation Helper while pressing the hotkey.") - @ConfigEditorBoolean - public boolean useHotkey = false; - - @Expose - @ConfigOption(name = "Hotkey", desc = "Press this hotkey to show the Reputation Helper.") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) - public int hotkey = Keyboard.KEY_NONE; - - - @Expose - public Position position = new Position(10, 10, false, true); - - @Expose - @ConfigOption(name = "Show Locations", desc = "Crimson Isles waypoints for locations to get reputation.") - @ConfigEditorDropdown(values = {"Always", "Only With Hotkey", "Never"}) - public int showLocation = 1; - } - - @Expose - @ConfigOption(name = "Quest Item Helper", desc = "When you open the fetch item quest in the town board, " + - "it shows a clickable chat message that will grab the items needed from the sacks.") - @ConfigEditorBoolean - @FeatureToggle - public boolean questItemHelper = false; -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/DevConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/DevConfig.java deleted file mode 100644 index be43a7526e04..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/DevConfig.java +++ /dev/null @@ -1,220 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.core.config.Position; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; -import io.github.moulberry.moulconfig.annotations.ConfigOption; -import org.lwjgl.input.Keyboard; - -public class DevConfig { - - @Expose - @ConfigOption(name = "Repo Auto Update", desc = "Update the repository on every startup.\n" + - "§cOnly disable this if you know what you are doing!") - @ConfigEditorBoolean - public boolean repoAutoUpdate = true; - - @Expose - @ConfigOption(name = "Debug", desc = "") - @Accordion - public DebugConfig debug = new DebugConfig(); - - public static class DebugConfig { - @Expose - @ConfigOption(name = "Enable Debug", desc = "Enable Test logic") - @ConfigEditorBoolean - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Command Logging", desc = "Logs stack trace information into the console when a command gets sent to Hypixel. (by any mod or the player)") - @ConfigEditorBoolean - public boolean commandLogs = false; - - @Expose - @ConfigOption( - name = "Mod Menu Log", - desc = "Enables debug messages when the currently opened GUI changes, with the path to the gui class. " + - "Useful for adding more mods to quick mod menu switch." - ) - @ConfigEditorBoolean - public boolean modMenuLog = false; - - @Expose - @ConfigOption(name = "Show Internal Name", desc = "Show internal names in item lore.") - @ConfigEditorBoolean - public boolean showInternalName = false; - - @Expose - @ConfigOption(name = "Show Empty Internal Names", desc = "Shows internal name even for items with none.") - @ConfigEditorBoolean - public boolean showEmptyNames = false; - - @Expose - @ConfigOption(name = "Show Item Rarity", desc = "Show item rarities in item lore.") - @ConfigEditorBoolean - public boolean showItemRarity = false; - - @Expose - @ConfigOption(name = "Copy Internal Name", desc = "Copies the internal name of an item on key press in the clipboard.") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) - public int copyInternalName = Keyboard.KEY_NONE; - - @Expose - @ConfigOption(name = "Show NPC Price", desc = "Show NPC price in item lore.") - @ConfigEditorBoolean - public boolean showNpcPrice = false; - - @Expose - @ConfigOption(name = "Show Item UUID", desc = "Show the Unique Identifier of items in the lore.") - @ConfigEditorBoolean - public boolean showItemUuid = false; - - @Expose - @ConfigOption(name = "Copy Item Data", desc = "Copies item NBT data on key press in a GUI to clipboard.") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) - public int copyItemData = Keyboard.KEY_NONE; - - @Expose - @ConfigOption(name = "Copy Compressed Item Data", desc = "Copies compressed item NBT data on key press in a GUI to clipboard.") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) - public int copyItemDataCompressed = Keyboard.KEY_NONE; - - @Expose - @ConfigOption(name = "Copy RNG Meter", desc = "Copies internal names and maxed XP needed from RNG meter inventories as json to clipboard.") - @ConfigEditorBoolean - public boolean copyRngMeter = false; - - @Expose - @ConfigOption(name = "Copy Bestiary Data", desc = "Copies the bestiary data from the inventory as json to clipboard.") - @ConfigEditorBoolean - public boolean copyBestiaryData = false; - - @Expose - @ConfigOption(name = "Highlight Missing Repo Items", desc = "Highlights each item in the current inventory that is not in your current NEU repo.") - @ConfigEditorBoolean - public boolean highlightMissingRepo = false; - } - - @Expose - @ConfigOption(name = "Slot Number", desc = "Show slot number in inventory while pressing this key.") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) - public int showSlotNumberKey = Keyboard.KEY_NONE; - - @ConfigOption(name = "Parkour Waypoints", desc = "") - @Accordion - @Expose - public WaypointsConfig waypoint = new WaypointsConfig(); - - public static class WaypointsConfig { - - @Expose - @ConfigOption(name = "Save Hotkey", desc = "Saves block location to a temporarily parkour and copies everything to your clipboard.") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) - public int saveKey = Keyboard.KEY_NONE; - - @Expose - @ConfigOption(name = "Delete Hotkey", desc = "Deletes the last saved location for when you make a mistake.") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) - public int deleteKey = Keyboard.KEY_NONE; - - @Expose - @ConfigOption(name = "Show Platform Number", desc = "Show the index number over the platform for every parkour.") - @ConfigEditorBoolean - public boolean showPlatformNumber = false; - - } - - @Expose - public Position debugPos = new Position(10, 10, false, true); - - @Expose - public Position debugLocationPos = new Position(1, 160, false, true); - - @Expose - @ConfigOption(name = "Minecraft Console", desc = "") - @Accordion - public MinecraftConsoleConfig minecraftConsoles = new MinecraftConsoleConfig(); - - public static class MinecraftConsoleConfig { - @Expose - @ConfigOption(name = "Unfiltered Debug", desc = "Print the debug information for unfiltered console messages.") - @ConfigEditorBoolean - public boolean printUnfilteredDebugs = false; - - @Expose - @ConfigOption(name = "Unfiltered Debug File", desc = "Print the debug information into log files instead of into the console for unfiltered console messages.") - @ConfigEditorBoolean - public boolean logUnfilteredFile = false; - - @Expose - @ConfigOption( - name = "Outside SkyBlock", - desc = "Print the debug information for unfiltered console messages outside SkyBlock too." - ) - @ConfigEditorBoolean - public boolean printUnfilteredDebugsOutsideSkyBlock = false; - - @Expose - @ConfigOption( - name = "Log Filtered", - desc = "Log the filtered messages into the console." - ) - @ConfigEditorBoolean - public boolean printFilteredReason = false; - - @Expose - @ConfigOption(name = "Console Filters", desc = "") - @Accordion - public ConsoleFiltersConfig consoleFilter = new ConsoleFiltersConfig(); - - public static class ConsoleFiltersConfig { - @Expose - @ConfigOption(name = "Filter Chat", desc = "Filter chat messages.") - @ConfigEditorBoolean - public boolean filterChat = false; - - @Expose - @ConfigOption(name = "Filter Grow Buffer", desc = "Filter 'Needed to grow BufferBuilder buffer:'") - @ConfigEditorBoolean - public boolean filterGrowBuffer = true; - - @Expose - @ConfigOption(name = "Filter Sound Error", desc = "Filter 'Unable to play unknown soundEvent'.") - @ConfigEditorBoolean - public boolean filterUnknownSound = true; - - @Expose - @ConfigOption(name = "Filter Scoreboard Errors", desc = "Filter error messages with Scoreboard: removeTeam, createTeam, " + - "removeObjective and 'scoreboard team already exists'.") - @ConfigEditorBoolean - public boolean filterScoreboardErrors = true; - - @Expose - @ConfigOption(name = "Filter Particle", desc = "Filter message 'Could not spawn particle effect VILLAGER_HAPPY'.") - @ConfigEditorBoolean - public boolean filterParticleVillagerHappy = true; - - @Expose - @ConfigOption(name = "Filter OptiFine", desc = "Filter OptiFine messages CustomItems and ConnectedTextures during loading.") - @ConfigEditorBoolean - public boolean filterOptiFine = true; - - @Expose - @ConfigOption(name = "Filter AsmHelper Transformer", desc = "Filter messages when AsmHelper is Transforming a class during loading.") - @ConfigEditorBoolean - public boolean filterAmsHelperTransformer = true; - - @Expose - @ConfigOption(name = "Filter Applying AsmWriter", desc = "Filter messages when AsmHelper is applying AsmWriter ModifyWriter.") - @ConfigEditorBoolean - public boolean filterAsmHelperApplying = true; - - @Expose - @ConfigOption(name = "Filter Biome ID Bounds", desc = "Filter message 'Biome ID is out of bounds'.") - @ConfigEditorBoolean - public boolean filterBiomeIdBounds = true; - } - } -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/DungeonConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/DungeonConfig.java deleted file mode 100644 index 90eee882a5f3..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/DungeonConfig.java +++ /dev/null @@ -1,256 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.FeatureToggle; -import at.hannibal2.skyhanni.config.core.config.Position; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; -import io.github.moulberry.moulconfig.annotations.ConfigOption; - -public class DungeonConfig { - - @Expose - @ConfigOption(name = "Clicked Blocks", desc = "Highlight levers, chests, and Wither Essence when clicked in Dungeons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlightClickedBlocks = false; - - @Expose - @ConfigOption(name = "Milestones Display", desc = "Show the current milestone in Dungeons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean showMilestonesDisplay = false; - - @Expose - public Position showMileStonesDisplayPos = new Position(10, 10, false, true); - - @Expose - @ConfigOption(name = "Death Counter Display", desc = "Display the total amount of deaths in the current Dungeon.") - @ConfigEditorBoolean - @FeatureToggle - public boolean deathCounterDisplay = false; - - @Expose - public Position deathCounterPos = new Position(10, 10, false, true); - - @Expose - @ConfigOption(name = "Clean End", desc = "") - @Accordion - public CleanEndConfig cleanEnd = new CleanEndConfig(); - public static class CleanEndConfig { - @Expose - @ConfigOption(name = "Enabled", desc = "After the last Dungeon boss has died, all entities and " + - "particles are no longer displayed and the music stops playing, but the loot chests are still displayed.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Ignore Guardians", desc = "Ignore F3 and M3 Guardians from the clean end feature when " + - "sneaking. Makes it easier to kill them after the boss died already. Thanks Hypixel.") - @ConfigEditorBoolean - public boolean F3IgnoreGuardians = false; - } - - @Expose - @ConfigOption(name = "Boss Damage Splash", desc = "Hides damage splashes while inside the boss room (fixes a Skytils feature).") - @ConfigEditorBoolean - @FeatureToggle - public boolean damageSplashBoss = false; - - @Expose - @ConfigOption(name = "Highlight Deathmites", desc = "Highlight Deathmites in Dungeons in red color.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlightDeathmites = true; - - @Expose - @ConfigOption(name = "Highlight Teammates", desc = "Highlight Dungeon teammates with a glowing outline.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlightTeammates = true; - - - @Expose - @ConfigOption(name = "Object Hider", desc = "Hide various things in Dungeons.") - @Accordion - public ObjectHiderConfig objectHider = new ObjectHiderConfig(); - public static class ObjectHiderConfig { - @Expose - @ConfigOption(name = "Hide Superboom TNT", desc = "Hide Superboom TNT laying around in Dungeons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideSuperboomTNT = false; - - @Expose - @ConfigOption(name = "Hide Blessings", desc = "Hide Blessings laying around in Dungeons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideBlessing = false; - - @Expose - @ConfigOption(name = "Hide Revive Stones", desc = "Hide Revive Stones laying around in Dungeons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideReviveStone = false; - - @Expose - @ConfigOption(name = "Hide Premium Flesh", desc = "Hide Premium Flesh laying around in Dungeons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hidePremiumFlesh = false; - - @Expose - @ConfigOption(name = "Hide Journal Entry", desc = "Hide Journal Entry pages laying around in Dungeons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideJournalEntry = false; - - @Expose - @ConfigOption(name = "Hide Skeleton Skull", desc = "Hide Skeleton Skulls laying around in Dungeons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideSkeletonSkull = true; - - @Expose - @ConfigOption(name = "Hide Healer Orbs", desc = "Hides the damage, ability damage and defensive orbs that spawn when the Healer kills mobs.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideHealerOrbs = false; - - @Expose - @ConfigOption(name = "Hide Healer Fairy", desc = "Hide the Golden Fairy that follows the Healer in Dungeons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideHealerFairy = false; - - @Expose - @ConfigOption( - name = "Hide Soulweaver Skulls", - desc = "Hide the annoying soulweaver skulls that float around you if you have the soulweaver gloves equipped.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideSoulweaverSkulls = false; - - } - - @Expose - @ConfigOption(name = "Message Filter", desc = "") - @Accordion - public MessageFilterConfig messageFilter = new MessageFilterConfig(); - - public static class MessageFilterConfig{ - @Expose - @ConfigOption(name = "Keys and Doors", desc = "Hides the chat message when picking up keys or opening doors in Dungeons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean keysAndDoors = false; - } - - @Expose - @ConfigOption(name = "Dungeon Copilot", desc = "") - @Accordion - public DungeonCopilotConfig dungeonCopilot = new DungeonCopilotConfig(); - - public static class DungeonCopilotConfig{ - @Expose - @ConfigOption(name = "Copilot Enabled", desc = "Suggests what to do next in Dungeons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - public Position pos = new Position(10, 10, false, true); - } - - - @Expose - @ConfigOption(name = "Party Finder", desc = "") - @Accordion - public PartyFinderConfig partyFinder = new PartyFinderConfig(); - - public static class PartyFinderConfig { - @Expose - @ConfigOption(name = "Colored Class Level", desc = "Color class levels in Party Finder.") - @ConfigEditorBoolean - @FeatureToggle - public boolean coloredClassLevel = true; - - @Expose - @ConfigOption(name = "Floor Stack Size", desc = "Display the party finder floor as the item stack size.") - @ConfigEditorBoolean - @FeatureToggle - public boolean floorAsStackSize = true; - - @Expose - @ConfigOption(name = "Mark Paid Carries", desc = "Highlight paid carries with a red background to make them easier to find/skip.") - @ConfigEditorBoolean - @FeatureToggle - public boolean markPaidCarries = true; - - @Expose - @ConfigOption(name = "Mark Low Levels", desc = "Highlight groups with players at or below the specified class level to make them easier to find/skip.") - @ConfigEditorSlider(minValue = 0, maxValue = 50, minStep = 1) - public int markBelowClassLevel = 0; - - @Expose - @ConfigOption(name = "Mark Ineligible Groups", desc = "Highlight groups with requirements that you do not meet.") - @ConfigEditorBoolean - @FeatureToggle - public boolean markIneligibleGroups = true; - - @Expose - @ConfigOption(name = "Mark Missing Class", desc = "Highlight groups that don't currently have any members of your selected dungeon class.") - @ConfigEditorBoolean - @FeatureToggle - public boolean markMissingClass = true; - } - - @Expose - @ConfigOption(name = "Tab List", desc = "") - @Accordion - public TabListConfig tabList = new TabListConfig(); - - public static class TabListConfig { - - @Expose - @ConfigOption(name = "Colored Class Level", desc = "Color class levels in tab list. (Also hides rank colors and emblems, because who needs that in Dungeons anyway?)") - @ConfigEditorBoolean - @FeatureToggle - public boolean coloredClassLevel = true; - } - - @Expose - @ConfigOption(name = "Livid Finder", desc = "") - @Accordion - public LividFinderConfig lividFinder = new LividFinderConfig(); - - public static class LividFinderConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Helps find the correct livid in F5 and in M5.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Hide Wrong Livids", desc = "Hide wrong livids entirely.") - @ConfigEditorBoolean - public boolean hideWrong = false; - } - - @Expose - @ConfigOption(name = "Moving Skeleton Skulls", desc = "Highlight Skeleton Skulls when combining into an " + - "orange Skeletor (not useful when combined with feature Hide Skeleton Skull).") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlightSkeletonSkull = true; - - @Expose - @ConfigOption(name = "Croesus Chest", desc = "Adds a visual highlight to the Croesus inventory that " + - "shows unopened chests.") - @ConfigEditorBoolean - @FeatureToggle - public boolean croesusUnopenedChestTracker = true; -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/EventConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/EventConfig.java deleted file mode 100644 index 7b4d0211f3cc..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/EventConfig.java +++ /dev/null @@ -1,379 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.FeatureToggle; -import at.hannibal2.skyhanni.config.core.config.Position; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; -import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; -import io.github.moulberry.moulconfig.annotations.ConfigOption; -import io.github.moulberry.moulconfig.observer.Property; -import org.lwjgl.input.Keyboard; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; - -public class EventConfig { - - @ConfigOption(name = "Monthly Bingo", desc = "") - @Accordion - @Expose - public BingoConfig bingo = new BingoConfig(); - - public static class BingoConfig { - - @Expose - @ConfigOption(name = "Bingo Card", desc = "") - @Accordion - public BingoCardConfig bingoCard = new BingoCardConfig(); - - public static class BingoCardConfig { - @Expose - @ConfigOption(name = "Enable", desc = "Displays the Bingo Card.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - @Expose - @ConfigOption(name = "Quick Toggle", desc = "Quickly toggle the Bingo Card or the step helper by sneaking with SkyBlock Menu in hand.") - @ConfigEditorBoolean - public boolean quickToggle = true; - - @Expose - @ConfigOption(name = "Bingo Steps", desc = "Show help with the next step in Bingo instead of the Bingo Card. " + - "§cThis feature is in early development. Expect bugs and missing goals.") - @ConfigEditorBoolean - public boolean stepHelper = false; - - @Expose - @ConfigOption(name = "Hide Community Goals", desc = "Hide Community Goals from the Bingo Card display.") - @ConfigEditorBoolean - public Property hideCommunityGoals = Property.of(false); - - @Expose - @ConfigOption( - name = "Show Guide", - desc = "Show tips and difficulty for bingo goals inside the Bingo Card inventory.\n" + - "These tips are made from inspirations and guides from the community,\n"+ - "aiming to help you to complete the bingo card." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean bingoSplashGuide = true; - - @Expose - public Position bingoCardPos = new Position(10, 10, false, true); - } - - @Expose - @ConfigOption(name = "Compact Chat Messages", desc = "") - @Accordion - public CompactChatConfig compactChat = new CompactChatConfig(); - - public static class CompactChatConfig { - - @Expose - @ConfigOption(name = "Enable", desc = "Shortens chat messages about skill level ups, collection gains, " + - "new area discoveries and SkyBlock level up messages while on Bingo.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Hide Border", desc = "Hide the border messages before and after the compact level up messages.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideBorder = true; - - @Expose - @ConfigOption(name = "Outside Bingo", desc = "Compact the level up chat messages outside of an Bingo profile as well.") - @ConfigEditorBoolean - public boolean outsideBingo = false; - } - - @Expose - @ConfigOption(name = "Minion Craft Helper", desc = "Show how many more items you need to upgrade the minion in your inventory. Especially useful for Bingo.") - @ConfigEditorBoolean - @FeatureToggle - public boolean minionCraftHelperEnabled = true; - - @Expose - public Position minionCraftHelperPos = new Position(10, 10, false, true); - } - - @ConfigOption(name = "Diana's Mythological Burrows", desc = "") - @Accordion - @Expose - public DianaConfig diana = new DianaConfig(); - - public static class DianaConfig { - - - @Expose - @ConfigOption(name = "Soopy Guess", desc = "Uses §eSoopy's Guess Logic §7to find the next burrow. Does not require SoopyV2 or ChatTriggers to be installed.") - @ConfigEditorBoolean - @FeatureToggle - public boolean burrowsSoopyGuess = false; - - @Expose - @ConfigOption(name = "Nearby Detection", desc = "Show burrows near you.") - @ConfigEditorBoolean - @FeatureToggle - public boolean burrowsNearbyDetection = false; - - @Expose - @ConfigOption(name = "Smooth Transition", desc = "Show the way from one burrow to another smoothly.") - @ConfigEditorBoolean - public boolean burrowSmoothTransition = false; - - @Expose - @ConfigOption(name = "Nearest Warp", desc = "Warps to the nearest warp point on the hub, if closer to the next burrow.") - @ConfigEditorBoolean - public boolean burrowNearestWarp = false; - - @Expose - @ConfigOption(name = "Warp Key", desc = "Press this key to warp to nearest burrow waypoint.") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) - public int keyBindWarp = Keyboard.KEY_NONE; - - @Expose - @ConfigOption(name = "Ignored Warps", desc = "") - @Accordion - public IgnoredWarpsConfig ignoredWarps = new IgnoredWarpsConfig(); - - public static class IgnoredWarpsConfig { - - @Expose - @ConfigOption(name = "Crypt", desc = "Ignore the Crypt warp point (Because it takes a long time to leave).") - @ConfigEditorBoolean - public boolean crypt = false; - - @Expose - @ConfigOption(name = "Wizard", desc = "Ignore the Wizard Tower warp point (Because it is easy to fall into the rift).") - @ConfigEditorBoolean - public boolean wizard = false; - - } - - @Expose - @ConfigOption(name = "Inquisitor Waypoint Sharing", desc = "") - @Accordion - public InquisitorSharingConfig inquisitorSharing = new InquisitorSharingConfig(); - - public static class InquisitorSharingConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Shares your Inquisitor and receiving other Inquisitors via Party Chat.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Focus", desc = "Hide other waypoints when your Party finds an Inquisitor.") - @ConfigEditorBoolean - public boolean focusInquisitor = false; - - @Expose - @ConfigOption(name = "Instant Share", desc = "Share the waypoint as soon as you find an Inquisitor. As an alternative, you can share it only via key press.") - @ConfigEditorBoolean - public boolean instantShare = true; - - @Expose - @ConfigOption(name = "Share Key", desc = "Press this key to share your Inquisitor Waypoint.") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_Y) - public int keyBindShare = Keyboard.KEY_Y; - - @Expose - @ConfigOption(name = "Show Despawn Time", desc = "Show the time until the shared Inquisitor will despawn.") - @ConfigEditorBoolean - public boolean showDespawnTime = true; - } - - @Expose - @ConfigOption(name = "Griffin Pet Warning", desc = "Warn when holding an Ancestral Spade if a Griffin Pet is not equipped.") - @ConfigEditorBoolean - @FeatureToggle - public boolean petWarning = true; - - @Expose - @ConfigOption(name = "Always Diana", desc = "Forcefully set the Diana event to be active. This is useful if the auto mayor detection fails.") - @ConfigEditorBoolean - public boolean alwaysDiana = false; - } - - @ConfigOption(name = "Winter Season on Jerry's Island", desc = "") - @Accordion - @Expose - public WinterConfig winter = new WinterConfig(); - - public static class WinterConfig { - - @Expose - @ConfigOption(name = "Frozen Treasure Tracker", desc = "") - @Accordion - public FrozenTreasureConfig frozenTreasureTracker = new FrozenTreasureConfig(); - - public static class FrozenTreasureConfig { - - @Expose - @ConfigOption( - name = "Enabled", - desc = "Tracks all of your drops from Frozen Treasure in the Glacial Caves.\n" + - "§eIce calculations are an estimate but are relatively accurate." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption( - name = "Text Format", - desc = "Drag text to change the appearance of the overlay." - ) - @ConfigEditorDraggableList( - exampleText = { - "§1§lFrozen Treasure Tracker", - "§61,636 Treasures Mined", - "§33.2m Total Ice", - "§3342,192 Ice/hr", - "§81,002 Compact Procs", - " ", - "§b182 §fWhite Gift", - "§b94 §aGreen Gift", - "§b17 §9§cRed Gift", - "§b328 §fPacked Ice", - "§b80 §aEnchanted Ice", - "§b4 §9Enchanted Packed Ice", - "§b182 §aIce Bait", - "§b3 §aGlowy Chum Bait", - "§b36 §5Glacial Fragment", - "§b6 §fGlacial Talisman", - " ", - } - ) - public List textFormat = new ArrayList<>(Arrays.asList(0, 1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 14, 15)); - - @Expose - @ConfigOption(name = "Only in Glacial Cave", desc = "Only shows the overlay while in the Glacial Cave.") - @ConfigEditorBoolean - public boolean onlyInCave = true; - - @Expose - @ConfigOption(name = "Show as Drops", desc = "Multiplies the numbers on the display by the base drop. \n" + - "E.g. 3 Ice Bait -> 48 Ice Bait") - @ConfigEditorBoolean - public boolean showAsDrops = false; - - @Expose - @ConfigOption(name = "Hide Chat Messages", desc = "Hides the chat messages from Frozen Treasures.") - @ConfigEditorBoolean - public boolean hideMessages = false; - - @Expose - public Position position = new Position(10, 80, false, true); - } - - @Expose - @ConfigOption(name = "Island Close Time", desc = "While on the Winter Island, show a timer until Jerry's Workshop closes.") - @ConfigEditorBoolean - @FeatureToggle - public boolean islandCloseTime = true; - - @Expose - public Position islandCloseTimePosition = new Position(10, 10, false, true); - - } - - @ConfigOption(name = "City Project", desc = "") - @Accordion - @Expose - public CityProjectConfig cityProject = new CityProjectConfig(); - - public static class CityProjectConfig { - - @Expose - @ConfigOption(name = "Show Materials", desc = "Show materials needed for contributing to the City Project.") - @ConfigEditorBoolean - @FeatureToggle - public boolean showMaterials = true; - - @Expose - @ConfigOption(name = "Show Ready", desc = "Mark contributions that are ready to participate.") - @ConfigEditorBoolean - @FeatureToggle - public boolean showReady = true; - - @Expose - @ConfigOption(name = "Daily Reminder", desc = "Remind every 24 hours to participate.") - @ConfigEditorBoolean - @FeatureToggle - public boolean dailyReminder = true; - - @Expose - public Position pos = new Position(150, 150, false, true); - } - - @ConfigOption(name = "Mayor Jerry's Jerrypocalypse", desc = "") - @Accordion - @Expose - public MayorJerryConfig jerry = new MayorJerryConfig(); - - public static class MayorJerryConfig { - - @Expose - @ConfigOption(name = "Highlight Jerries", desc = "Highlights Jerries found from the Jerrypocalypse perk. Highlight color is based on color of the Jerry.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlightJerries = true; - - } - - // comment in if the event is needed again -// @ConfigOption(name = "300þ Anniversary Celebration", desc = "Features for the 300þ year of SkyBlock") - @Accordion - @Expose - public CenturyConfig century = new CenturyConfig(); - - public static class CenturyConfig { - - @ConfigOption(name = "Enable Active Player Timer", desc = "Show a HUD telling you how much longer you have to wait to be eligible for another free ticket.") - @Expose - @ConfigEditorBoolean - @FeatureToggle - public boolean enableActiveTimer = true; - - @Expose - public Position activeTimerPosition = new Position(100, 100, false, true); - - @ConfigOption(name = "Enable Active Player Alert", desc = "Loudly proclaim when it is time to break some wheat.") - @Expose - @ConfigEditorBoolean - public boolean enableActiveAlert = false; - } - - @Expose - @ConfigOption(name = "Main Lobby Halloween Basket Waypoints", desc = "") - @Accordion - public halloweenBasketConfig halloweenBasket = new halloweenBasketConfig(); - - public static class halloweenBasketConfig { - - @Expose - @ConfigOption(name = "Basket Waypoints", desc = "Show all Halloween Basket waypoints.\nShoutout to §bTobbbb §7for the coordinates.\n(AS OF 2023)") - @ConfigEditorBoolean - @FeatureToggle - public boolean allWaypoints = false; - - @Expose - @ConfigOption(name = "Entrance Waypoints", desc = "Show helper waypoints to Baskets #23, #24, and #25. Coordinates by §bErymanthus§7.") - @ConfigEditorBoolean - public boolean allEntranceWaypoints = false; - - @Expose - @ConfigOption(name = "Only Closest", desc = "Only show the closest waypoint") - @ConfigEditorBoolean - public boolean onlyClosest = true; - } - -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/FishingConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/FishingConfig.java deleted file mode 100644 index 56dfc021ec74..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/FishingConfig.java +++ /dev/null @@ -1,290 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.FeatureToggle; -import at.hannibal2.skyhanni.config.core.config.Position; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; -import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; -import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; -import io.github.moulberry.moulconfig.annotations.ConfigOption; -import io.github.moulberry.moulconfig.observer.Property; -import org.lwjgl.input.Keyboard; - -public class FishingConfig { - - @Expose - @ConfigOption(name = "Trophy Fishing", desc = "") - @Accordion - public TrophyFishingConfig trophyFishing = new TrophyFishingConfig(); - - public static class TrophyFishingConfig { - - @Expose - @ConfigOption(name = "Trophy Fishing Chat Messages", desc = "") - @Accordion - public ChatMessagesConfig chatMessages = new ChatMessagesConfig(); - - public static class ChatMessagesConfig { - - @Expose - @ConfigOption( - name = "Trophy Counter", - desc = "Counts Trophy messages from chat and tells you how many you have found." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption( - name = "Trophy Counter Design", - desc = "§fStyle 1: §72. §6§lGOLD §5Moldfin\n" + - "§fStyle 2: §bYou caught a §5Moldfin §6§lGOLD§b. §7(2)\n" + - "§fStyle 3: §bYou caught your 2nd §6§lGOLD §5Moldfin§b." - ) - @ConfigEditorDropdown(values = {"Style 1", "Style 2", "Style 3"}) - public int design = 0; - - @Expose - @ConfigOption(name = "Show Total Amount", desc = "Show total amount of all rarities at the end of the chat message.") - @ConfigEditorBoolean - public boolean totalAmount = false; - - @Expose - @ConfigOption(name = "Trophy Fish Info", desc = "Show information and stats about a Trophy Fish when hovering over a catch message in chat.") - @ConfigEditorBoolean - @FeatureToggle - public boolean tooltip = true; - - @Expose - @ConfigOption(name = "Hide Repeated Catches", desc = "Delete past catches of the same Trophy Fish from chat.") - @ConfigEditorBoolean - @FeatureToggle - public boolean duplicateHider = false; - - @Expose - @ConfigOption(name = "Bronze Duplicates", desc = "Hide duplicate messages for bronze Trophy Fishes from chat.") - @ConfigEditorBoolean - public boolean bronzeHider = false; - - @Expose - @ConfigOption(name = "Silver Duplicates", desc = "Hide duplicate messages for silver Trophy Fishes from chat.") - @ConfigEditorBoolean - public boolean silverHider = false; - } - - @Expose - @ConfigOption(name = "Fillet Tooltip", desc = "Show fillet value of Trophy Fish in tooltip.") - @ConfigEditorBoolean - @FeatureToggle - public boolean filletTooltip = true; - - @Expose - @ConfigOption(name = "Odger Waypoint", desc = "Show the Odger waypoint when Trophy Fishes are in the inventory and no lava rod in hand.") - @ConfigEditorBoolean - @FeatureToggle - public boolean odgerLocation = true; - } - - @Expose - @ConfigOption(name = "Thunder Spark", desc = "") - @Accordion - public ThunderSparkConfig thunderSpark = new ThunderSparkConfig(); - - public static class ThunderSparkConfig { - @Expose - @ConfigOption(name = "Thunder Spark Highlight", desc = "Highlight Thunder Sparks after killing a Thunder.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlight = false; - - @Expose - @ConfigOption(name = "Thunder Spark Color", desc = "Color of the Thunder Sparks.") - @ConfigEditorColour - public String color = "0:255:255:255:255"; - } - - @Expose - @ConfigOption(name = "Barn Fishing Timer", desc = "") - @Accordion - public BarnTimerConfig barnTimer = new BarnTimerConfig(); - - public static class BarnTimerConfig { - @Expose - @ConfigOption( - name = "Barn Fishing Timer", - desc = "Show the time and amount of sea creatures while fishing on the barn via hub." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption( - name = "Worm Fishing", - desc = "Show the Barn Fishing Timer even for worms or other sea creatures in the Crystal Hollows." - ) - @ConfigEditorBoolean - public boolean crystalHollows = true; - - @Expose - @ConfigOption( - name = "Stranded Fishing", - desc = "Show the Barn Fishing Timer even on all the different islands Stranded players can visit." - ) - @ConfigEditorBoolean - public boolean forStranded = true; - - @Expose - @ConfigOption( - name = "Worm Cap Alert", - desc = "Alerts you with sound if you hit the Worm Sea Creature limit of 60." - ) - @ConfigEditorBoolean - public boolean wormLimitAlert = true; - - @Expose - @ConfigOption(name = "Reset Timer Hotkey", desc = "Press this key to reset the timer manualy") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) - public int manualResetTimer = Keyboard.KEY_NONE; - - @Expose - @ConfigOption(name = "Fishing Timer Alert", desc = "Change the amount of time in seconds until the timer dings.") - @ConfigEditorSlider( - minValue = 240, - maxValue = 360, - minStep = 10 - ) - public int alertTime = 330; - - @Expose - public Position pos = new Position(10, 10, false, true); - } - - @Expose - @ConfigOption(name = "Chum/Chumcap Bucket Hider", desc = "") - @Accordion - public ChumBucketHiderConfig chumBucketHider = new ChumBucketHiderConfig(); - - public static class ChumBucketHiderConfig { - - @Expose - @ConfigOption(name = "Enable", desc = "Hide the Chum/Chumcap Bucket name tags for other players.") - @ConfigEditorBoolean - @FeatureToggle - public Property enabled = Property.of(true); - - @Expose - @ConfigOption(name = "Hide Bucket", desc = "Hide the Chum/Chumcap Bucket.") - @ConfigEditorBoolean - public Property hideBucket = Property.of(false); - - @Expose - @ConfigOption(name = "Hide Own", desc = "Hides your own Chum/Chumcap Bucket.") - @ConfigEditorBoolean - public Property hideOwn = Property.of(false); - } - - @Expose - @ConfigOption(name = "Fished Item Name", desc = "") - @Accordion - public FishedItemNameConfig fishedItemName = new FishedItemNameConfig(); - - public static class FishedItemNameConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Show the fished item name above the item when fishing.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Show Bait", desc = "Also show the name of the consumed bait.") - @ConfigEditorBoolean - public boolean showBaits = false; - - } - - @Expose - @ConfigOption(name = "Fishing Hook Display", desc = "") - @Accordion - public FishingHookDisplayConfig fishingHookDisplay = new FishingHookDisplayConfig(); - - public static class FishingHookDisplayConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Display the Hypixel timer until the fishing hook can be pulled out of the water/lava, only bigger and on your screen.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption( - name = "Hide Armor Stand", - desc = "Hide the original armor stand from Hypixel when the SkyHanni display is enabled." - ) - @ConfigEditorBoolean - public boolean hideArmorStand = true; - - @Expose - public Position position = new Position(460, -240, 3.4f); - } - - @Expose - @ConfigOption(name = "Rare Sea Creatures", desc = "") - @Accordion - public RareCatches rareCatches = new RareCatches(); - - public static class RareCatches { - - @Expose - @ConfigOption(name = "Alert (Own Sea Creatures)", desc = "Show an alert on screen when you catch a rare sea creature.") - @ConfigEditorBoolean - @FeatureToggle - public boolean alertOwnCatches = true; - - @Expose - @ConfigOption(name = "Alert (Other Sea Creatures)", desc = "Show an alert on screen when other players nearby catch a rare sea creature.") - @ConfigEditorBoolean - public boolean alertOtherCatches = false; - - @Expose - @ConfigOption(name = "Play Sound Alert", desc = "Play a sound effect when rare sea creature alerts are displayed.") - @ConfigEditorBoolean - public boolean playSound = true; - - @Expose - @ConfigOption(name = "Highlight", desc = "Highlight nearby rare sea creatures.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlight = false; - - } - - @Expose - @ConfigOption( - name = "Shark Fish Counter", - desc = "Counts how many Sharks have been caught." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean sharkFishCounter = false; - - @Expose - public Position sharkFishCounterPos = new Position(10, 10, false, true); - - @Expose - @ConfigOption(name = "Shorten Fishing Message", desc = "Shortens the chat message that says what type of Sea Creature you have fished.") - @ConfigEditorBoolean - @FeatureToggle - public boolean shortenFishingMessage = false; - - @Expose - @ConfigOption(name = "Compact Double Hook", desc = "Adds Double Hook to the Sea Creature chat message instead of in a previous line.") - @ConfigEditorBoolean - @FeatureToggle - public boolean compactDoubleHook = true; -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/GUIConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/GUIConfig.java deleted file mode 100644 index d7fd4625d40d..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/GUIConfig.java +++ /dev/null @@ -1,146 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.FeatureToggle; -import at.hannibal2.skyhanni.config.commands.Commands; -import at.hannibal2.skyhanni.config.core.config.Position; -import at.hannibal2.skyhanni.data.GuiEditManager; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorButton; -import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; -import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; -import io.github.moulberry.moulconfig.annotations.ConfigEditorText; -import io.github.moulberry.moulconfig.annotations.ConfigOption; -import io.github.moulberry.moulconfig.observer.Property; -import org.lwjgl.input.Keyboard; - -public class GUIConfig { - - @ConfigOption(name = "Edit GUI Locations", desc = "Change the position of SkyHanni's overlays.") - @ConfigEditorButton(buttonText = "Edit") - public Runnable positions = GuiEditManager::openGuiPositionEditor; - - @Expose - @ConfigOption(name = "Open Hotkey", desc = "Press this key to open the GUI Editor.") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) - public int keyBindOpen = Keyboard.KEY_NONE; - - @Expose - @ConfigOption(name = "Global GUI Scale", desc = "Globally scale all SkyHanni GUIs.") - @ConfigEditorSlider(minValue = 0.1F, maxValue = 10, minStep = 0.05F) - public float globalScale = 1F; - - - @Expose - @ConfigOption(name = "Modify Visual Words", desc = "") - @Accordion - public ModifyWords modifyWords = new ModifyWords(); - - public static class ModifyWords { - - @Expose - @ConfigOption(name = "Enabled", desc = "Enables replacing all instances of a word or phrase with another word or phrase.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Work Outside SkyBlock", desc = "Allows modifying visual words anywhere on Hypixel.") - @ConfigEditorBoolean - @FeatureToggle - public boolean workOutside = false; - - @ConfigOption(name = "Open Config", desc = "Opens the menu to setup the visual words.\n§eCommand: /shwords") - @ConfigEditorButton(buttonText = "Open") - public Runnable open = Commands::openVisualWords; - - } - - @Expose - @ConfigOption(name = "Custom Text Box", desc = "") - @Accordion - public TextBoxConfig customTextBox = new TextBoxConfig(); - - public static class TextBoxConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Enables showing the textbox while in SkyBlock.") - @ConfigEditorBoolean - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Text", desc = "Enter text you want to display here.\n" + - "§eUse '&' as the colour code character.\n" + - "§eUse '\\n' as the line break character.") - @ConfigEditorText - public Property text = Property.of("&aYour Text Here\\n&bYour new line here"); - - @Expose - public Position position = new Position(10, 80, false, true); - } - - @Expose - @ConfigOption(name = "Real Time", desc = "Display the current computer time, a handy feature when playing in full-screen mode.") - @ConfigEditorBoolean - @FeatureToggle - public boolean realTime = false; - - @Expose - @ConfigOption(name = "Real Time 12h Format", desc = "Display the current computer time in 12hr Format rather than 24h Format.") - @ConfigEditorBoolean - public boolean realTimeFormatToggle = false; - - @Expose - public Position realTimePosition = new Position(10, 10, false, true); - - - @Expose - @ConfigOption(name = "In-Game Date", desc = "") - @Accordion - public InGameDateConfig inGameDateConfig = new InGameDateConfig(); - - public static class InGameDateConfig { - - @Expose - @ConfigOption( - name = "Enabled", - desc = "Show the in-game date of SkyBlock (like in Apec, §ebut with mild delays§7).\n" + - "(Though this one includes the SkyBlock year!)" - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - public Position position = new Position(10, 10, false, true); - - @Expose - @ConfigOption( - name = "Refresh Rate", - desc = "Change the time in seconds you would like to refresh the In-Game Date Display." - ) - @ConfigEditorSlider( - minValue = 1, - maxValue = 60, - minStep = 1 - ) - public int RefreshSeconds = 10; - } - - - @Expose - @ConfigOption(name = "TPS Display", desc = "Show the TPS of the current server, like in Soopy.") - @ConfigEditorBoolean - @FeatureToggle - public boolean tpsDisplay = false; - - @Expose - public Position tpsDisplayPosition = new Position(10, 10, false, true); - - @Expose - @ConfigOption(name = "Config Button", desc = "Add a button to the pause menu to configure SkyHanni.") - @ConfigEditorBoolean - @FeatureToggle - public boolean configButtonOnPause = true; -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/GardenConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/GardenConfig.java deleted file mode 100644 index d550d3f72ac8..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/GardenConfig.java +++ /dev/null @@ -1,1433 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.FeatureToggle; -import at.hannibal2.skyhanni.config.commands.Commands; -import at.hannibal2.skyhanni.config.core.config.Position; -import at.hannibal2.skyhanni.features.garden.inventory.GardenPlotIcon; -import at.hannibal2.skyhanni.utils.LorenzUtils; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorButton; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; -import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; -import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; -import io.github.moulberry.moulconfig.annotations.ConfigEditorText; -import io.github.moulberry.moulconfig.annotations.ConfigOption; -import io.github.moulberry.moulconfig.observer.Property; -import net.minecraft.client.Minecraft; -import org.lwjgl.input.Keyboard; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; - -public class GardenConfig { - - @Expose - @ConfigOption(name = "SkyMart", desc = "") - @Accordion - public SkyMartConfig skyMart = new SkyMartConfig(); - - public static class SkyMartConfig { - @Expose - @ConfigOption(name = "Copper Price", desc = "Show copper to coin prices inside the SkyMart inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean copperPrice = true; - - @Expose - @ConfigOption(name = "Advanced Stats", desc = "Show the BIN price and copper price for every item.") - @ConfigEditorBoolean - public boolean copperPriceAdvancedStats = false; - - @Expose - public Position copperPricePos = new Position(211, 132, false, true); - } - - @Expose - @ConfigOption(name = "Visitor", desc = "") - @Accordion - public VisitorConfig visitors = new VisitorConfig(); - - public static class VisitorConfig { - @Expose - @ConfigOption(name = "Visitor Timer", desc = "") - @Accordion - public TimerConfig timer = new TimerConfig(); - - public static class TimerConfig { - @Expose - @ConfigOption(name = "Visitor Timer", desc = "Timer when the next visitor will appear, " + - "and a number for how many visitors are already waiting.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Sixth Visitor Estimate", desc = "Estimate when the sixth visitor in the queue will arrive. " + - "May be inaccurate with co-op members farming simultaneously.") - @ConfigEditorBoolean - public boolean sixthVisitorEnabled = true; - - @Expose - @ConfigOption(name = "Sixth Visitor Warning", desc = "Notifies when it is believed that the sixth visitor has arrived. " + - "May be inaccurate with co-op members farming simultaneously.") - @ConfigEditorBoolean - public boolean sixthVisitorWarning = true; - - @Expose - @ConfigOption(name = "New Visitor Ping", desc = "Pings you when you are less than 10 seconds away from getting a new visitor. " + - "§eUseful for getting Ephemeral Gratitudes during the 2023 Halloween event.") - @ConfigEditorBoolean - public boolean newVisitorPing = false; - - @Expose - public Position pos = new Position(390, 65, false, true); - } - - @Expose - @ConfigOption(name = "Visitor Items Needed", desc = "") - @Accordion - public NeedsConfig needs = new NeedsConfig(); - - public static class NeedsConfig { - @Expose - @ConfigOption(name = "Items Needed", desc = "Show all items needed for the visitors.") - @ConfigEditorBoolean - @FeatureToggle - public boolean display = true; - - @Expose - public Position pos = new Position(180, 170, false, true); - - @Expose - @ConfigOption(name = "Only when Close", desc = "Only show the needed items when close to the visitors.") - @ConfigEditorBoolean - public boolean onlyWhenClose = false; - - @Expose - @ConfigOption(name = "Bazaar Alley", desc = "Show the Visitor Items List while inside the Bazaar Alley in the Hub. " + - "This helps buying the correct amount when not having a Booster Cookie Buff active.") - @ConfigEditorBoolean - public boolean inBazaarAlley = true; - - @Expose - @ConfigOption(name = "Show Price", desc = "Show the coin price in the items needed list.") - @ConfigEditorBoolean - public boolean showPrice = true; - - @Expose - @ConfigOption(name = "Item Preview", desc = "Show the base type for the required items next to new visitors. §cNote that some visitors may require any crop.") - @ConfigEditorBoolean - @FeatureToggle - public boolean itemPreview = true; - } - - @Expose - @ConfigOption(name = "Visitor Inventory", desc = "") - @Accordion - public InventoryConfig inventory = new InventoryConfig(); - - public static class InventoryConfig { - @Expose - @ConfigOption(name = "Visitor Price", desc = "Show the Bazaar price of the items required for the visitors, like in NEU.") - @ConfigEditorBoolean - @FeatureToggle - public boolean showPrice = false; - - @Expose - @ConfigOption(name = "Amount and Time", desc = "Show the exact item amount and the remaining time when farmed manually. Especially useful for Ironman.") - @ConfigEditorBoolean - public boolean exactAmountAndTime = true; - - @Expose - @ConfigOption(name = "Copper Price", desc = "Show the price per copper inside the visitor GUI.") - @ConfigEditorBoolean - @FeatureToggle - public boolean copperPrice = true; - - @Expose - @ConfigOption(name = "Copper Time", desc = "Show the time required per copper inside the visitor GUI.") - @ConfigEditorBoolean - @FeatureToggle - public boolean copperTime = false; - - @Expose - @ConfigOption(name = "Garden Exp Price", desc = "Show the price per garden experience inside the visitor GUI.") - @ConfigEditorBoolean - @FeatureToggle - public boolean experiencePrice = false; - } - - @Expose - @ConfigOption(name = "Visitor Reward Warning", desc = "") - @Accordion - public RewardWarningConfig rewardWarning = new RewardWarningConfig(); - - public static class RewardWarningConfig { - - @Expose - @ConfigOption(name = "Notify in Chat", desc = "Send a chat message once you talk to a visitor with reward.") - @ConfigEditorBoolean - @FeatureToggle - public boolean notifyInChat = true; - - @Expose - @ConfigOption(name = "Show over Name", desc = "Show the reward name above the visitor name.") - @ConfigEditorBoolean - @FeatureToggle - public boolean showOverName = true; - - @Expose - @ConfigOption(name = "Prevent Refusing", desc = "Prevent the refusal of a visitor with reward.") - @ConfigEditorBoolean - @FeatureToggle - public boolean preventRefusing = true; - - @Expose - @ConfigOption(name = "Bypass Key", desc = "Hold that key to bypass the Prevent Refusing feature.") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) - public int bypassKey = Keyboard.KEY_NONE; - - - /** - * Sync up with {at.hannibal2.skyhanni.features.garden.visitor.VisitorReward} - */ - @Expose - @ConfigOption( - name = "Items", - desc = "Warn for these reward items." - ) - @ConfigEditorDraggableList( - exampleText = { - "§9Flowering Bouquet", - "§9Overgrown Grass", - "§9Green Bandana", - "§9Dedication IV", - "§9Music Rune", - "§cSpace Helmet", - "§9Cultivating I", - "§9Replenish I", - } - ) - public List drops = new ArrayList<>(Arrays.asList(1, 2, 3, 4, 5, 6)); - } - - @Expose - @ConfigOption(name = "Notification Chat", desc = "Show in chat when a new visitor is visiting your island.") - @ConfigEditorBoolean - @FeatureToggle - public boolean notificationChat = true; - - @Expose - @ConfigOption(name = "Notification Title", desc = "Show a title when a new visitor is visiting your island.") - @ConfigEditorBoolean - @FeatureToggle - public boolean notificationTitle = true; - - @Expose - @ConfigOption(name = "Highlight Status", desc = "Highlight the status for visitors with a text above or with color.") - @ConfigEditorDropdown(values = {"Color Only", "Name Only", "Both", "Disabled"}) - public int highlightStatus = 2; - - @Expose - @ConfigOption(name = "Colored Name", desc = "Show the visitor name in the color of the rarity.") - @ConfigEditorBoolean - @FeatureToggle - public boolean coloredName = true; - - @Expose - @ConfigOption(name = "Hypixel Message", desc = "Hide the chat message from Hypixel that a new visitor has arrived at your garden.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hypixelArrivedMessage = true; - - @Expose - @ConfigOption(name = "Hide Chat", desc = "Hide chat messages from the visitors in garden. (Except Beth and Spaceman)") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideChat = true; - - @Expose - @ConfigOption(name = "Visitor Drops Statistics Counter", desc = "") - @Accordion - public DropsStatisticsConfig dropsStatistics = new DropsStatisticsConfig(); - - public static class DropsStatisticsConfig { - - @Expose - @ConfigOption( - name = "Enabled", - desc = "Tallies up statistic about visitors and the rewards you have received from them." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption( - name = "Text Format", - desc = "Drag text to change the appearance of the overlay." - ) - @ConfigEditorDraggableList( - exampleText = { - "§e§lVisitor Statistics", - "§e1,636 Total", - "§a1,172§f-§9382§f-§681§f-§c1", - "§21,382 Accepted", - "§c254 Denied", - " ", - "§c62,072 Copper", - "§33.2m Farming EXP", - "§647.2m Coins Spent", - "§b23 §9Flowering Bouquet", - "§b4 §9Overgrown Grass", - "§b2 §5Green Bandana", - "§b1 §9Dedication IV", - "§b6 §b◆ Music Rune I", - "§b1 §cSpace Helmet", - "§b1 §9Cultivating I", - "§b1 §9Replenish I", - " ", // If they want another empty row - "§212,600 Garden EXP", - "§b4.2k Bits", - "§220k Mithril Powder", - "§d18k Gemstone Powder", - } - ) - public List textFormat = new ArrayList<>(Arrays.asList(0, 1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 12)); - - - @Expose - @ConfigOption(name = "Display Numbers First", desc = "Determines whether the number or drop name displays first. " + - "§eNote: Will not update the preview above!") - @ConfigEditorBoolean - public boolean displayNumbersFirst = true; - - @Expose - @ConfigOption(name = "Display Icons", desc = "Replaces the drop names with icons. " + - "§eNote: Will not update the preview above!") - @ConfigEditorBoolean - public boolean displayIcons = false; - - @Expose - @ConfigOption(name = "Only on Barn Plot", desc = "Only shows the overlay while on the Barn plot.") - @ConfigEditorBoolean - public boolean onlyOnBarn = true; - - @Expose - public Position pos = new Position(5, 20, false, true); - } - - @Expose - @ConfigOption( - name = "Accept Hotkey", - desc = "Accept a visitor when you press this keybind while in the visitor GUI. " + - "§eUseful for getting Ephemeral Gratitudes during the 2023 Halloween event." - ) - @ConfigEditorKeybind( - defaultKey = Keyboard.KEY_NONE - ) - public int acceptHotkey = Keyboard.KEY_NONE; - } - - @Expose - @ConfigOption(name = "Numbers", desc = "") - @Accordion - public NumbersConfig number = new NumbersConfig(); - - public static class NumbersConfig { - @Expose - @ConfigOption(name = "Crop Milestone", desc = "Show the number of crop milestones in the inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean cropMilestone = true; - - @Expose - @ConfigOption(name = "Average Milestone", desc = "Show the average crop milestone in the crop milestone inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean averageCropMilestone = true; - - @Expose - @ConfigOption(name = "Crop Upgrades", desc = "Show the number of upgrades in the crop upgrades inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean cropUpgrades = true; - - @Expose - @ConfigOption(name = "Composter Upgrades", desc = "Show the number of upgrades in the Composter upgrades inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean composterUpgrades = true; - } - - @Expose - @ConfigOption(name = "Crop Milestones", desc = "") - @Accordion - public CropMilestonesConfig cropMilestones = new CropMilestonesConfig(); - - public static class CropMilestonesConfig { - @Expose - @ConfigOption( - name = "Progress Display", - desc = "Shows the progress and ETA until the next crop milestone is reached and the current crops/minute value. " + - "§eRequires a tool with either a counter or Cultivating enchantment for full accuracy." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean progress = true; - - @Expose - @ConfigOption( - name = "Warn When Close", - desc = "Warn with title and sound when the next crop milestone upgrade happens in 5 seconds. " + - "Useful for switching to a different pet for leveling.") - @ConfigEditorBoolean - public boolean warnClose = false; - - @Expose - @ConfigOption( - name = "Time Format", - desc = "Change the highest time unit to show (1h30m vs 90min)") - @ConfigEditorDropdown(values = {"Year", "Day", "Hour", "Minute", "Second"}) - public Property highestTimeFormat = Property.of(0); - - @Expose - @ConfigOption( - name = "Maxed Milestone", - desc = "Calculate the progress and ETA till maxed milestone (46) instead of next milestone.") - @ConfigEditorBoolean - public Property bestShowMaxedNeeded = Property.of(false); - - @Expose - @ConfigOption( - name = "Milestone Text", - desc = "Drag text to change the appearance of the overlay.\n" + - "Hold a farming tool to show the overlay." - ) - @ConfigEditorDraggableList( - exampleText = { - "§6Crop Milestones", - "§7Pumpkin Tier 22", - "§e12,300§8/§e100,000", - "§7In §b12m 34s", - "§7Crops/Minute§8: §e12,345", - "§7Blocks/Second§8: §e19.85", - "§7Percentage: §e12.34%", - } - ) - public List text = new ArrayList<>(Arrays.asList(0, 1, 2, 3, 4, 5)); - - @Expose - @ConfigOption(name = "Block Broken Precision", desc = "The amount of decimals displayed in blocks/second.") - @ConfigEditorSlider( - minValue = 0, - maxValue = 6, - minStep = 1 - ) - public int blocksBrokenPrecision = 2; - - @Expose - @ConfigOption(name = "Seconds Before Reset", desc = "How many seconds of not farming until blocks/second resets.") - @ConfigEditorSlider( - minValue = 2, - maxValue = 60, - minStep = 1 - ) - public int blocksBrokenResetTime = 5; - - @Expose - public Position progressDisplayPos = new Position(-400, -200, false, true); - - @Expose - @ConfigOption(name = "Best Crop", desc = "") - @Accordion - public NextConfig next = new NextConfig(); - - // TODO moulconfig runnable support - public static class NextConfig { - @Expose - @ConfigOption( - name = "Best Display", - desc = "Lists all crops and their ETA till next milestone. Sorts for best crop for getting garden or SkyBlock levels.") - @ConfigEditorBoolean - @FeatureToggle - public boolean bestDisplay = true; - - // TODO moulconfig runnable support - @Expose - @ConfigOption(name = "Sort Type", desc = "Sort the crops by either garden or SkyBlock EXP.") - @ConfigEditorDropdown(values = {"Garden Exp", "SkyBlock Exp"}) - public int bestType = 0; - - // TODO moulconfig runnable support - @Expose - @ConfigOption(name = "Only Show Top", desc = "Only show the top # crops.") - @ConfigEditorSlider( - minValue = 1, - maxValue = 10, - minStep = 1 - ) - public int showOnlyBest = 10; - - @Expose - @ConfigOption(name = "Extend Top List", desc = "Add current crop to the list if its lower ranked than the set limit by extending the list.") - @ConfigEditorBoolean - public boolean showCurrent = true; - - // TODO moulconfig runnable support - @Expose - @ConfigOption( - name = "Always On", - desc = "Show the Best Display always while on the garden.") - @ConfigEditorBoolean - public boolean bestAlwaysOn = false; - - @Expose - @ConfigOption( - name = "Compact Display", - desc = "A more compact best crop time: Removing the crop name and exp, hide the # number and using a more compact time format.") - @ConfigEditorBoolean - public boolean bestCompact = false; - - @Expose - @ConfigOption( - name = "Hide Title", - desc = "Hides the 'Best Crop Time' line entirely.") - @ConfigEditorBoolean - public boolean bestHideTitle = false; - - - @Expose - public Position displayPos = new Position(-200, -200, false, true); - } - - @Expose - @ConfigOption(name = "Mushroom Pet Perk", desc = "") - @Accordion - public MushroomPetPerkConfig mushroomPetPerk = new MushroomPetPerkConfig(); - - // TODO moulconfig runnable support - public static class MushroomPetPerkConfig { - @Expose - @ConfigOption( - name = "Display Enabled", - desc = "Show the progress and ETA for mushroom crops when farming other crops because of the Mooshroom Cow perk.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption( - name = "Mushroom Text", - desc = "Drag text to change the appearance of the overlay.\n" + - "Hold a farming tool to show the overlay." - ) - @ConfigEditorDraggableList( - exampleText = { - "§6Mooshroom Cow Perk", - "§7Mushroom Tier 8", - "§e6,700§8/§e15,000", - "§7In §b12m 34s", - "§7Percentage: §e12.34%", - } - ) - public List text = new ArrayList<>(Arrays.asList(0, 1, 2, 3)); - - @Expose - public Position pos = new Position(-112, -143, false, true); - } - } - - // TODO moulconfig runnable support - @Expose - @ConfigOption(name = "Custom Keybinds", desc = "") - @Accordion - public KeyBindConfig keyBind = new KeyBindConfig(); - - public static class KeyBindConfig { - @Expose - @ConfigOption(name = "Enabled", desc = "Use custom keybinds while holding a farming tool or Daedalus Axe in the hand.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @ConfigOption(name = "Disable All", desc = "Disable all keys.") - @ConfigEditorButton(buttonText = "Disable") - public Runnable presetDisable = () -> { - attack = Keyboard.KEY_NONE; - useItem = Keyboard.KEY_NONE; - left = Keyboard.KEY_NONE; - right = Keyboard.KEY_NONE; - forward = Keyboard.KEY_NONE; - back = Keyboard.KEY_NONE; - jump = Keyboard.KEY_NONE; - sneak = Keyboard.KEY_NONE; - - Minecraft.getMinecraft().thePlayer.closeScreen(); - }; - - @ConfigOption(name = "Set Default", desc = "Reset all keys to default.") - @ConfigEditorButton(buttonText = "Default") - public Runnable presetDefault = () -> { - attack = -100; - useItem = -99; - left = Keyboard.KEY_A; - right = Keyboard.KEY_D; - forward = Keyboard.KEY_W; - back = Keyboard.KEY_S; - jump = Keyboard.KEY_SPACE; - sneak = Keyboard.KEY_LSHIFT; - Minecraft.getMinecraft().thePlayer.closeScreen(); - }; - - @Expose - @ConfigOption(name = "Attack", desc = "") - @ConfigEditorKeybind(defaultKey = -100) - public int attack = -100; - - @Expose - @ConfigOption(name = "Use Item", desc = "") - @ConfigEditorKeybind(defaultKey = -99) - public int useItem = -99; - - @Expose - @ConfigOption(name = "Move Left", desc = "") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_A) - public int left = Keyboard.KEY_A; - - @Expose - @ConfigOption(name = "Move Right", desc = "") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_D) - public int right = Keyboard.KEY_D; - - @Expose - @ConfigOption(name = "Move Forward", desc = "") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_W) - public int forward = Keyboard.KEY_W; - - @Expose - @ConfigOption(name = "Move Back", desc = "") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_S) - public int back = Keyboard.KEY_S; - - @Expose - @ConfigOption(name = "Jump", desc = "") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_SPACE) - public int jump = Keyboard.KEY_SPACE; - - @Expose - @ConfigOption(name = "Sneak", desc = "") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_LSHIFT) - public int sneak = Keyboard.KEY_LSHIFT; - } - - @Expose - @ConfigOption(name = "Optimal Speed", desc = "") - @Accordion - public OptimalSpeedConfig optimalSpeeds = new OptimalSpeedConfig(); - - public static class OptimalSpeedConfig { - @Expose - @ConfigOption(name = "Enabled", desc = "Show the optimal speed for your current tool in the hand.\n" + - "(Thanks MelonKingDE for the default values).") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Warning Title", desc = "Warn via title when you don't have the optimal speed.") - @ConfigEditorBoolean - public boolean warning = false; - - @Expose - @ConfigOption(name = "Rancher Boots", desc = "Allows you to set the optimal speed in the Rancher Boots overlay by clicking on the presets.") - @ConfigEditorBoolean - @FeatureToggle - public boolean signEnabled = true; - - @Expose - public Position signPosition = new Position(20, -195, false, true); - - @Expose - @ConfigOption(name = "Custom Speed", desc = "Change the exact speed for every single crop.") - @Accordion - public CustomSpeedConfig customSpeed = new CustomSpeedConfig(); - - public static class CustomSpeedConfig { - - @Expose - @ConfigOption(name = "Wheat", desc = "Suggested farm speed:\n" + - "§e5 Blocks§7: §f✦ 93 speed\n" + - "§e4 Blocks§7: §f✦ 116 speed") - @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) - public int wheat = 93; - - @Expose - @ConfigOption(name = "Carrot", desc = "Suggested farm speed:\n" + - "§e5 Blocks§7: §f✦ 93 speed\n" + - "§e4 Blocks§7: §f✦ 116 speed") - @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) - public int carrot = 93; - - @Expose - @ConfigOption(name = "Potato", desc = "Suggested farm speed:\n" + - "§e5 Blocks§7: §f✦ 93 speed\n" + - "§e4 Blocks§7: §f✦ 116 speed") - @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) - public int potato = 93; - - @Expose - @ConfigOption(name = "Nether Wart", desc = "Suggested farm speed:\n" + - "§e5 Blocks§7: §f✦ 93 speed\n" + - "§e4 Blocks§7: §f✦ 116 speed") - @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) - public int netherWart = 93; - - @Expose - @ConfigOption(name = "Pumpkin", desc = "Suggested farm speed:\n" + - "§e3 Blocks§7: §f✦ 155 speed\n" + - "§e2 Blocks§7: §f✦ 265 §7or §f400 speed") - @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) - public int pumpkin = 155; - - @Expose - @ConfigOption(name = "Melon", desc = "Suggested farm speed:\n" + - "§e3 Blocks§7: §f✦ 155 speed\n" + - "§e2 Blocks§7: §f✦ 265 or 400 speed") - @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) - public int melon = 155; - - @Expose - @ConfigOption(name = "Cocoa Beans", desc = "Suggested farm speed:\n" + - "§e3 Blocks§7: §f✦ 155 speed\n" + - "§e4 Blocks§7: §f✦ 116 speed") - @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) - public int cocoaBeans = 155; - - // TODO does other speed settings exist? - @Expose - @ConfigOption(name = "Sugar Cane", desc = "Suggested farm speed:\n" + - "§eYaw 45§7: §f✦ 328 speed") - @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) - public int sugarCane = 328; - - @Expose - @ConfigOption(name = "Cactus", desc = "Suggested farm speed:\n" + - "§eNormal§7: §f✦ 400 speed\n" + - "§eRacing Helmet§7: §f✦ 464 speed\n" + - "§eBlack Cat§7: §f✦ 464 speed") - @ConfigEditorSlider(minValue = 1, maxValue = 500, minStep = 1) - public int cactus = 400; - - // TODO does other speed settings exist? - @Expose - @ConfigOption(name = "Mushroom", desc = "Suggested farm speed:\n" + - "§eYaw 60§7: §f✦ 233 speed") - @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) - public int mushroom = 233; - } - - @Expose - public Position pos = new Position(5, -200, false, true); - } - - @Expose - @ConfigOption(name = "Garden Level", desc = "") - @Accordion - public GardenLevelConfig gardenLevels = new GardenLevelConfig(); - - public static class GardenLevelConfig { - @Expose - @ConfigOption(name = "Display", desc = "Show the current Garden level and progress to the next level.") - @ConfigEditorBoolean - @FeatureToggle - public boolean display = true; - - @Expose - public Position pos = new Position(390, 40, false, true); - } - - @Expose - @ConfigOption(name = "Farming Weight", desc = "") - @Accordion - public EliteFarmingWeightConfig eliteFarmingWeights = new EliteFarmingWeightConfig(); - - public static class EliteFarmingWeightConfig { - @Expose - @ConfigOption(name = "Display", desc = "Display your farming weight on screen. " + - "The calculation and API is provided by The Elite SkyBlock farmers. " + - "See §ehttps://elitebot.dev/info §7for more info.") - @ConfigEditorBoolean - @FeatureToggle - public boolean display = true; - - @Expose - public Position pos = new Position(180, 10, false, true); - - @Expose - @ConfigOption(name = "Leaderboard Ranking", desc = "Show your position in the farming weight leaderboard. " + - "Only if your farming weight is high enough! Updates every 10 minutes.") - @ConfigEditorBoolean - public boolean leaderboard = true; - - @Expose - @ConfigOption(name = "Overtake ETA", desc = "Show a timer estimating when you'll move up a spot in the leaderboard! " + - "Will show an ETA to rank #10,000 if you're not on the leaderboard yet.") - @ConfigEditorBoolean - public boolean overtakeETA = false; - - @Expose - @ConfigOption(name = "Offscreen Drop Message", desc = "Show a chat message when joining Garden how many spots you have dropped since last Garden join.") - @ConfigEditorBoolean - public boolean offScreenDropMessage = true; - - @Expose - @ConfigOption(name = "Always ETA", desc = "Show the Overtake ETA always, even when not farming at the moment.") - @ConfigEditorBoolean - public boolean overtakeETAAlways = true; - - @Expose - @ConfigOption(name = "ETA Goal", desc = "Override the Overtake ETA to show when you'll reach the specified rank (if not there yet). (Default: \"10,000\")") - @ConfigEditorText - public String ETAGoalRank = "10000"; - - @Expose - @ConfigOption(name = "Show below 200", desc = "Show the farming weight data even if you are below 200 weight.") - @ConfigEditorBoolean - public boolean ignoreLow = false; - } - - @Expose - @ConfigOption(name = "Dicer Counter", desc = "") - @Accordion - public DicerCounterConfig dicerCounters = new DicerCounterConfig(); - - public static class DicerCounterConfig { - @Expose - @ConfigOption(name = "RNG Drop Counter", desc = "Count RNG drops for Melon Dicer and Pumpkin Dicer.") - @ConfigEditorBoolean - @FeatureToggle - public boolean display = true; - - @Expose - @ConfigOption(name = "Hide Chat", desc = "Hide the chat message when dropping a RNG Dicer drop.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideChat = false; - - @Expose - public Position pos = new Position(16, -232, false, true); - } - - @Expose - @ConfigOption(name = "Money per Hour", desc = "") - @Accordion - public MoneyPerHourConfig moneyPerHours = new MoneyPerHourConfig(); - - public static class MoneyPerHourConfig { - @Expose - @ConfigOption(name = "Show Money per Hour", - desc = "Displays the money per hour YOU get with YOUR crop/minute value when selling the item to bazaar. " + - "Supports Bountiful, Mushroom Cow Perk, Armor Crops and Dicer Drops. Their toggles are below.") - @ConfigEditorBoolean - @FeatureToggle - public boolean display = true; - - // TODO moulconfig runnable support - @Expose - @ConfigOption(name = "Only Show Top", desc = "Only show the best # items.") - @ConfigEditorSlider( - minValue = 1, - maxValue = 25, - minStep = 1 - ) - public int showOnlyBest = 5; - - @Expose - @ConfigOption(name = "Extend Top List", desc = "Add current crop to the list if its lower ranked than the set limit by extending the list.") - @ConfigEditorBoolean - public boolean showCurrent = true; - - // TODO moulconfig runnable support - @Expose - @ConfigOption( - name = "Always On", - desc = "Always show the money/hour Display while on the garden.") - @ConfigEditorBoolean - public boolean alwaysOn = false; - - @Expose - @ConfigOption( - name = "Compact Mode", - desc = "Hide the item name and the position number.") - @ConfigEditorBoolean - public boolean compact = false; - - @Expose - @ConfigOption( - name = "Compact Price", - desc = "Show the price more compact.") - @ConfigEditorBoolean - public boolean compactPrice = false; - - @Expose - @ConfigOption( - name = "Use Custom", - desc = "Use the custom format below instead of classic ➜ §eSell Offer §7and other profiles ➜ §eNPC Price.") - @ConfigEditorBoolean - public boolean useCustomFormat = false; - - @Expose - @ConfigOption( - name = "Custom Format", - desc = "Set what prices to show") - @ConfigEditorDraggableList( - exampleText = { - "§eSell Offer", - "§eInstant Sell", - "§eNPC Price" - }, - requireNonEmpty = true - ) - public List customFormat = new ArrayList<>(Arrays.asList(0, 1, 2)); - - @Expose - @ConfigOption( - name = "Merge Seeds", - desc = "Merge the seeds price with the wheat price.") - @ConfigEditorBoolean - public boolean mergeSeeds = true; - - @Expose - @ConfigOption( - name = "Include Bountiful", - desc = "Includes the coins from Bountiful in the calculation.") - @ConfigEditorBoolean - public boolean bountiful = true; - - @Expose - @ConfigOption( - name = "Include Mooshroom Cow", - desc = "Includes the coins you get from selling the mushrooms from your Mooshroom Cow pet.") - @ConfigEditorBoolean - public boolean mooshroom = true; - - @Expose - @ConfigOption( - name = "Include Armor Drops", - desc = "Includes the average coins/hr from your armor.") - @ConfigEditorBoolean - public boolean armor = true; - - @Expose - @ConfigOption( - name = "Include Dicer Drops", - desc = "Includes the average coins/hr from your melon or pumpkin dicer.") - @ConfigEditorBoolean - public boolean dicer = true; - - @Expose - @ConfigOption( - name = "Hide Title", - desc = "Hides the first line of 'Money Per Hour' entirely.") - @ConfigEditorBoolean - public boolean hideTitle = false; - - @Expose - public Position pos = new Position(-330, 170, false, true); - } - - @Expose - @ConfigOption(name = "Next Jacob's Contest", desc = "") - @Accordion - public NextJacobContestConfig nextJacobContests = new NextJacobContestConfig(); - - public static class NextJacobContestConfig { - @Expose - @ConfigOption(name = "Show Jacob's Contest", desc = "Show the current or next Jacob's farming contest time and crops.") - @ConfigEditorBoolean - @FeatureToggle - public boolean display = true; - - @Expose - @ConfigOption(name = "Outside Garden", desc = "Show the timer not only in Garden but everywhere in SkyBlock.") - @ConfigEditorBoolean - public boolean everywhere = false; - - @Expose - @ConfigOption(name = "In Other Guis", desc = "Mark the current or next Farming Contest crops in other farming GUIs as underlined.") - @ConfigEditorBoolean - public boolean otherGuis = false; - - @Expose - @ConfigOption(name = "Fetch Contests", desc = "Automatically fetch Contests from elitebot.dev for the current year if they're uploaded already.") - @ConfigEditorBoolean - public boolean fetchAutomatically = true; - - @Expose - @ConfigOption(name = "Share Contests", desc = "Share the list of upcoming Contests to elitebot.dev for everyone else to then fetch automatically.") - @ConfigEditorDropdown(values = {"Ask When Needed", "Share Automatically", "Disabled"}) - public int shareAutomatically = 0; - - @Expose - @ConfigOption(name = "Warning", desc = "Show a warning shortly before a new Jacob's Contest starts.") - @ConfigEditorBoolean - public boolean warn = false; - - @Expose - @ConfigOption(name = "Warning Time", desc = "Set the warning time in seconds before a Jacob's Contest begins.") - @ConfigEditorSlider( - minValue = 10, - maxValue = 60 * 5, - minStep = 1 - ) - public int warnTime = 60 * 2; - - @Expose - @ConfigOption(name = "Popup Warning", desc = "Opens a popup when the warning time is reached and Minecraft is not in focus.") - @ConfigEditorBoolean - public boolean warnPopup = false; - - @Expose - public Position pos = new Position(-200, 10, false, true); - } - - @Expose - @ConfigOption(name = "Farming Armor Drops", desc = "") - - @Accordion - public FarmingArmorDropsConfig farmingArmorDrop = new FarmingArmorDropsConfig(); - - public static class FarmingArmorDropsConfig { - @Expose - @ConfigOption(name = "Show Counter", desc = "Count all §9Cropie§7, §5Squash §7and §6Fermento §7dropped.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Hide Chat", desc = "Hide the chat message when receiving a farming armor drop.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideChat = false; - - @Expose - public Position pos = new Position(16, -232, false, true); - } - - @Expose - @ConfigOption(name = "Anita Shop", desc = "") - @Accordion - public AnitaShopConfig anitaShop = new AnitaShopConfig(); - - public static class AnitaShopConfig { - @Expose - @ConfigOption( - name = "Medal Prices", - desc = "Helps to identify profitable items to buy at the Anita item shop " + - "and potential profit from selling the item in the Auction House." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean medalProfitEnabled = true; - - @Expose - @ConfigOption( - name = "Extra Farming Fortune", - desc = "Show current tier and cost to max out in the item tooltip.") - @ConfigEditorBoolean - @FeatureToggle - public boolean extraFarmingFortune = true; - - @Expose - public Position medalProfitPos = new Position(206, 158, false, true); - } - - @Expose - @ConfigOption(name = "Composter", desc = "") - @Accordion - public ComposterConfig composters = new ComposterConfig(); - - public static class ComposterConfig { - @Expose - @ConfigOption( - name = "Composter Overlay", - desc = "Show organic matter, fuel, and profit prices while inside the Composter Inventory." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean overlay = true; - - @Expose - @ConfigOption(name = "Overlay Price", desc = "Toggle for Bazaar 'buy order' vs 'instant buy' price in composter overlay.") - @ConfigEditorDropdown(values = {"Instant Buy", "Buy Order"}) - public int overlayPriceType = 0; - - @Expose - @ConfigOption(name = "Retrieve From", desc = "Change where to retrieve the materials from in the composter overlay: The Bazaar or Sacks.") - @ConfigEditorDropdown(values = {"Bazaar", "Sacks"}) - public int retrieveFrom = 0; - - @Expose - public Position overlayOrganicMatterPos = new Position(140, 152, false, true); - - @Expose - public Position overlayFuelExtrasPos = new Position(-320, 152, false, true); - - @Expose - @ConfigOption( - name = "Display Element", - desc = "Displays the Compost data from the tab list as GUI element." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean displayEnabled = true; - - @Expose - @ConfigOption( - name = "Outside Garden", - desc = "Show Time till Composter is empty outside Garden" - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean displayOutsideGarden = false; - - @Expose - @ConfigOption( - name = "Composter Warning", - desc = "Warn when the Composter gets close to empty, even outside Garden." - ) - @ConfigEditorBoolean - public boolean warnAlmostClose = false; - - @Expose - @ConfigOption( - name = "Upgrade Price", - desc = "Show the price for the Composter Upgrade in the lore." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean upgradePrice = true; - - @Expose - @ConfigOption( - name = "Round Amount Needed", - desc = "Rounds the amount needed to fill your Composter down so that you don't overspend." - ) - @ConfigEditorBoolean - public boolean roundDown = true; - - @Expose - @ConfigOption( - name = "Highlight Upgrade", - desc = "Highlight Upgrades that can be bought right now." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean highlightUpgrade = true; - - @Expose - @ConfigOption( - name = "Inventory Numbers", - desc = "Show the amount of Organic Matter, Fuel and Composts Available while inside the Composter Inventory." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean inventoryNumbers = true; - - @Expose - @ConfigOption(name = "Notification When Low Composter", desc = "") - @Accordion - public NotifyLowConfig notifyLow = new NotifyLowConfig(); - - public static class NotifyLowConfig { - @Expose - @ConfigOption(name = "Enable", desc = "Show a notification when Organic Matter or Fuel runs low in your Composter.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Show Title", desc = "Send a title to notify.") - @ConfigEditorBoolean - public boolean title = false; - - @Expose - @ConfigOption(name = "Min Organic Matter", desc = "Warn when Organic Matter is below this value.") - @ConfigEditorSlider( - minValue = 1_000, - maxValue = 80_000, - minStep = 1 - ) - public int organicMatter = 20_000; - - @Expose - @ConfigOption(name = "Min Fuel Cap", desc = "Warn when Fuel is below this value.") - @ConfigEditorSlider( - minValue = 500, - maxValue = 40_000, - minStep = 1 - ) - public int fuel = 10_000; - } - - @Expose - public Position displayPos = new Position(-390, 10, false, true); - - @Expose - public Position outsideGardenPos = new Position(-363, 13, false, true); - } - - @Expose - @ConfigOption(name = "Farming Fortune Display", desc = "") - @Accordion - public FarmingFortuneConfig farmingFortunes = new FarmingFortuneConfig(); - - public static class FarmingFortuneConfig { - @Expose - @ConfigOption( - name = "FF Display", - desc = "Displays the true Farming Fortune for the current crop, including all crop-specific and hidden bonuses." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean display = true; - - @Expose - @ConfigOption( - name = "Show As Drop Multiplier", - desc = "Adds 100 to the displayed Farming Fortune so that it represents a drop multiplier rather than" + - " the chance for bonus drops. " - ) - @ConfigEditorBoolean - public boolean dropMultiplier = true; - - @ConfigOption(name = "Farming Fortune Guide", desc = "Opens a guide that breaks down your Farming Fortune.\n§eCommand: /ff") - @ConfigEditorButton(buttonText = "Open") - public Runnable open = Commands::openFortuneGuide; - - @Expose - public Position pos = new Position(5, -180, false, true); - } - - @Expose - @ConfigOption(name = "Tooltip Tweaks", desc = "") - @Accordion - public TooltipTweaksConfig tooltipTweak = new TooltipTweaksConfig(); - - public static class TooltipTweaksConfig { - @Expose - @ConfigOption( - name = "Compact Descriptions", - desc = "Hides redundant parts of reforge descriptions, generic counter description, and Farmhand perk explanation." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean compactToolTooltips = false; - - @Expose - @ConfigOption( - name = "Breakdown Hotkey", - desc = "When the keybind is pressed, show a breakdown of all fortune sources on a tool." - ) - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_LSHIFT) - public int fortuneTooltipKeybind = Keyboard.KEY_LSHIFT; - - @Expose - @ConfigOption( - name = "Tooltip Format", - desc = "Show crop-specific Farming Fortune in tooltip.\n" + - "§fShow: §7Crop-specific Fortune indicated as §6[+196]\n" + - "§fReplace: §7Edits the total Fortune to include crop-specific Fortune." - ) - @ConfigEditorDropdown(values = {"Default", "Show", "Replace"}) - public int cropTooltipFortune = 1; - - @Expose - @ConfigOption( - name = "Total Crop Milestone", - desc = "Shows the progress bar till maxed crop milestone in the crop milestone inventory." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean cropMilestoneTotalProgress = true; - } - - @Expose - @ConfigOption(name = "Yaw and Pitch", desc = "") - @Accordion - public YawPitchDisplayConfig yawPitchDisplay = new YawPitchDisplayConfig(); - - public static class YawPitchDisplayConfig { - - @Expose - @ConfigOption(name = "Enable", desc = "Displays yaw and pitch while holding a farming tool. Automatically fades out if there is no movement.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Yaw Precision", desc = "Yaw precision up to specified decimal.") - @ConfigEditorSlider( - minValue = 1, - maxValue = 10, - minStep = 1 - ) - public int yawPrecision = 4; - - @Expose - @ConfigOption(name = "Pitch Precision", desc = "Pitch precision up to specified decimal.") - @ConfigEditorSlider( - minValue = 1, - maxValue = 10, - minStep = 1 - ) - public int pitchPrecision = 4; - - @Expose - @ConfigOption(name = "Display Timeout", desc = "Duration in seconds for which the overlay is being displayed after moving.") - @ConfigEditorSlider( - minValue = 1, - maxValue = 20, - minStep = 1 - ) - public int timeout = 5; - - @Expose - @ConfigOption(name = "Show Without Tool", desc = "Does not require you to hold a tool for the overlay to show.") - @ConfigEditorBoolean - public boolean showWithoutTool = false; - - @Expose - @ConfigOption(name = "Show Outside Garden", desc = "The overlay will work outside of the Garden.") - @ConfigEditorBoolean - public boolean showEverywhere = false; - - @Expose - @ConfigOption(name = "Ignore Timeout", desc = "Ignore the timeout after not moving mouse.") - @ConfigEditorBoolean - public boolean showAlways = false; - - @Expose - public Position pos = new Position(445, 225, false, true); - @Expose - public Position posOutside = new Position(445, 225, false, true); - } - - @Expose - @ConfigOption(name = "Crop Start Location", desc = "") - @Accordion - public CropStartLocationConfig cropStartLocation = new CropStartLocationConfig(); - - public static class CropStartLocationConfig { - - @Expose - @ConfigOption(name = "Enable", desc = "Show the start waypoint for your farm with the currently holding tool.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - } - - @Expose - @ConfigOption(name = "Garden Plot Icon", desc = "") - @Accordion - public PlotIconConfig plotIcon = new PlotIconConfig(); - - public static class PlotIconConfig { - @Expose - @ConfigOption(name = "Enable", desc = "Enable icon replacement in the Configure Plots menu.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @ConfigOption(name = "Hard Reset", desc = "Reset every slot to its original item.") - @ConfigEditorButton(buttonText = "Reset") - public Runnable hardReset = () -> { - GardenPlotIcon.INSTANCE.setHardReset(true); - LorenzUtils.INSTANCE.sendCommandToServer("desk"); - }; - } - - @Expose - @ConfigOption(name = "Plot Price", desc = "Show the price of the plot in coins when inside the Configure Plots inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean plotPrice = true; - - @Expose - @ConfigOption(name = "Desk in Menu", desc = "Show a Desk button in the SkyBlock Menu. Opens the /desk command on click.") - @ConfigEditorBoolean - @FeatureToggle - public boolean deskInSkyBlockMenu = true; - - - @Expose - @ConfigOption(name = "Fungi Cutter Warning", desc = "Warn when breaking mushroom with the wrong Fungi Cutter mode.") - @ConfigEditorBoolean - @FeatureToggle - public boolean fungiCutterWarn = true; - - @Expose - @ConfigOption(name = "Burrowing Spores", desc = "Show a notification when a Burrowing Spores spawns while farming mushrooms.") - @ConfigEditorBoolean - @FeatureToggle - public boolean burrowingSporesNotification = true; - - @Expose - @ConfigOption(name = "Wild Strawberry", desc = "Show a notification when a Wild Strawberry Dye drops while farming.") - @ConfigEditorBoolean - @FeatureToggle - public boolean wildStrawberryDyeNotification = true; - - @Expose - @ConfigOption( - name = "FF for Contest", - desc = "Show the minimum needed Farming Fortune for reaching each medal in Jacob's Farming Contest inventory." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean farmingFortuneForContest = true; - - @Expose - public Position farmingFortuneForContestPos = new Position(180, 156, false, true); - - @Expose - @ConfigOption( - name = "Contest Time Needed", - desc = "Show the time and missing FF for every crop inside Jacob's Farming Contest inventory." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean jacobContextTimes = true; - - @Expose - public Position jacobContextTimesPos = new Position(-359, 149, false, true); - - @Expose - @ConfigOption( - name = "Contest Summary", - desc = "Show the average Blocks Per Second and blocks clicked at the end of a Jacob Farming Contest in chat." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean jacobContestSummary = true; - - @Expose - @ConfigOption(name = "Always Finnegan", desc = "Forcefully set the Finnegan Farming Simulator perk to be active. This is useful if the auto mayor detection fails.") - @ConfigEditorBoolean - public boolean forcefullyEnabledAlwaysFinnegan = false; - - @Expose - public Position cropSpeedMeterPos = new Position(278, -236, false, true); - - @Expose - @ConfigOption(name = "Enable Plot Borders", desc = "Enable the use of F3 + G hotkey to show Garden plot borders. Similar to how later Minecraft version render chunk borders.") - @ConfigEditorBoolean - @FeatureToggle - public boolean plotBorders = true; -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/InventoryConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/InventoryConfig.java deleted file mode 100644 index 3c6c750565a3..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/InventoryConfig.java +++ /dev/null @@ -1,438 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.FeatureToggle; -import at.hannibal2.skyhanni.config.core.config.Position; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; -import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; -import io.github.moulberry.moulconfig.annotations.ConfigOption; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; - -public class InventoryConfig { - - @Expose - @ConfigOption(name = "Not Clickable Items", desc = "") - @Accordion - public HideNotClickableConfig hideNotClickable = new HideNotClickableConfig(); - - public static class HideNotClickableConfig { - @Expose - @ConfigOption(name = "Enabled", desc = "Hide items that are not clickable in the current inventory: ah, bz, accessory bag, etc.") - @ConfigEditorBoolean - @FeatureToggle - public boolean items = false; - - @Expose - @ConfigOption(name = "Block Clicks", desc = "Block the clicks on these items.") - @ConfigEditorBoolean - public boolean itemsBlockClicks = true; - - @Expose - @ConfigOption( - name = "Opacity", - desc = "How strong should the items be grayed out?" - ) - @ConfigEditorSlider( - minValue = 0, - maxValue = 255, - minStep = 5 - ) - public int opacity = 180; - - @Expose - @ConfigOption(name = "Bypass With Control", desc = "Adds the ability to bypass not clickable items when holding the control key.") - @ConfigEditorBoolean - public boolean itemsBypass = true; - - @Expose - @ConfigOption(name = "Green Line", desc = "Adds green line around items that are clickable.") - @ConfigEditorBoolean - public boolean itemsGreenLine = true; - - } - - @Expose - @ConfigOption(name = "RNG Meter", desc = "") - @Accordion - public RngMeterConfig rngMeter = new RngMeterConfig(); - - public static class RngMeterConfig { - @Expose - @ConfigOption(name = "Floor Names", desc = "Show the Floor names in the Catacombs RNG Meter inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean floorName = false; - - @Expose - @ConfigOption(name = "No Drop", desc = "Highlight floors without a drop selected in the Catacombs RNG Meter inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean noDrop = false; - - @Expose - @ConfigOption(name = "Selected Drop", desc = "Highlight the selected drop in the Catacombs or Slayer RNG Meter inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean selectedDrop = false; - } - - @Expose - @ConfigOption(name = "Stats Tuning", desc = "") - @Accordion - public StatsTuningConfig statsTuning = new StatsTuningConfig(); - - public static class StatsTuningConfig { - @Expose - @ConfigOption(name = "Selected Stats", desc = "Show the tuning stats in the Thaumaturgy inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean selectedStats = true; - - @Expose - @ConfigOption(name = "Tuning Points", desc = "Show the amount of selected Tuning Points in the Stats Tuning inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean points = true; - - @Expose - @ConfigOption(name = "Selected Template", desc = "Highlight the selected template in the Stats Tuning inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean selectedTemplate = true; - - @Expose - @ConfigOption(name = "Template Stats", desc = "Show the type of stats for the Tuning Point templates.") - @ConfigEditorBoolean - @FeatureToggle - public boolean templateStats = true; - } - - @Expose - @ConfigOption(name = "Jacob Farming Contest", desc = "") - @Accordion - public JacobFarmingContestConfig jacobFarmingContests = new JacobFarmingContestConfig(); - - public static class JacobFarmingContestConfig { - @Expose - @ConfigOption(name = "Unclaimed Rewards", desc = "Highlight contests with unclaimed rewards in the Jacob inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlightRewards = true; - - @Expose - @ConfigOption(name = "Contest Time", desc = "Adds the real time format to the Contest description.") - @ConfigEditorBoolean - @FeatureToggle - public boolean realTime = true; - - @Expose - @ConfigOption(name = "Medal Icon", desc = "Adds a symbol that shows what medal you received in this Contest. " + - "§eIf you use a texture pack this may cause conflicting icons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean medalIcon = true; - - @Expose - @ConfigOption(name = "Finnegan Icon", desc = "Uses a different indicator for when the Contest happened during Mayor Finnegan.") - @ConfigEditorBoolean - public boolean finneganIcon = true; - } - - - @Expose - @ConfigOption(name = "Sack Items Display", desc = "") - @Accordion - public SackDisplayConfig sackDisplay = new SackDisplayConfig(); - - public static class SackDisplayConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Show contained items inside a sack inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption( - name = "Highlight Full", - desc = "Highlight items that are full in red.\n" + - "§eDoes not need the option above to be enabled." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean highlightFull = true; - - @Expose - @ConfigOption(name = "Number Format", desc = "Either show Default, Formatted or Unformatted numbers.\n" + - "§eDefault: §72,240/2.2k\n" + - "§eFormatted: §72.2k/2.2k\n" + - "§eUnformatted: §72,240/2,200") - @ConfigEditorDropdown(values = {"Default", "Formatted", "Unformatted"}) - public int numberFormat = 1; - - @Expose - @ConfigOption(name = "Extra space", desc = "Space between each line of text.") - @ConfigEditorSlider( - minValue = 0, - maxValue = 10, - minStep = 1) - public int extraSpace = 1; - - @Expose - @ConfigOption(name = "Sorting Type", desc = "Sorting type of items in sack.") - @ConfigEditorDropdown(values = {"Descending (Stored)", "Ascending (Stored)", "Descending (Price)", "Ascending (Price)"}) - public int sortingType = 0; - - @Expose - @ConfigOption(name = "Item To Show", desc = "Choose how many items are displayed. (Some sacks have too many items to fit\n" + - "in larger GUI scales, like the nether sack.)") - @ConfigEditorSlider( - minValue = 0, - maxValue = 45, - minStep = 1 - ) - public int itemToShow = 15; - - @Expose - @ConfigOption(name = "Show Empty Item", desc = "Show empty item quantity in the display.") - @ConfigEditorBoolean - public boolean showEmpty = true; - - @Expose - @ConfigOption(name = "Show Price", desc = "Show price for each item in sack.") - @ConfigEditorBoolean - public boolean showPrice = true; - - @Expose - @ConfigOption(name = "Price Format", desc = "Format of the price displayed.\n" + - "§eFormatted: §7(12k)\n" + - "§eUnformatted: §7(12,421)") - @ConfigEditorDropdown(values = {"Formatted", "Unformatted"}) - public int priceFormat = 0; - - @Expose - @ConfigOption(name = "Show Price From", desc = "Show price from Bazaar or NPC.") - @ConfigEditorDropdown(values = {"Bazaar", "NPC"}) - public int priceFrom = 0; - - @Expose - public Position position = new Position(144, 139, false, true); - } - - @Expose - @ConfigOption(name = "Chest Value", desc = "") - @Accordion - public ChestValueConfig chestValueConfig = new ChestValueConfig(); - - public static class ChestValueConfig { - @Expose - @ConfigOption(name = "Enabled", desc = "Enable estimated value of chest.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Enabled in dungeons", desc = "Enable the feature in dungeons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enableInDungeons = false; - - @Expose - @ConfigOption(name = "Show Stacks", desc = "Show the item icon before name.") - @ConfigEditorBoolean - public boolean showStacks = true; - - @Expose - @ConfigOption(name = "Display Type", desc = "Try to align everything to look nicer.") - @ConfigEditorBoolean - public boolean alignedDisplay = true; - - @Expose - @ConfigOption(name = "Name Length", desc = "Reduce item name length to gain extra space on screen.\n§cCalculated in pixels!") - @ConfigEditorSlider(minStep = 1, minValue = 100, maxValue = 150) - public int nameLength = 100; - - @Expose - @ConfigOption(name = "Highlight Slot", desc = "Highlight slot where the item is when you hover over it in the display.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enableHighlight = true; - - @Expose - @ConfigOption(name = "Highlight Color", desc = "Choose the highlight color.") - @ConfigEditorColour - public String highlightColor = "0:249:0:255:88"; - - @Expose - @ConfigOption(name = "Sorting Type", desc = "Price sorting type.") - @ConfigEditorDropdown(values = {"Descending", "Ascending"}) - public int sortingType = 0; - - @Expose - @ConfigOption(name = "Value formatting Type", desc = "Format of the price.") - @ConfigEditorDropdown(values = {"Short", "Long"}) - public int formatType = 0; - - @Expose - @ConfigOption(name = "Item To Show", desc = "Choose how many items are displayed.\n" + - "All items in the chest are still counted for the total value.") - @ConfigEditorSlider( - minValue = 0, - maxValue = 54, - minStep = 1 - ) - public int itemToShow = 15; - - @Expose - @ConfigOption(name = "Hide below", desc = "Item item value below configured amount.\n" + - "Items are still counted for the total value.") - @ConfigEditorSlider( - minValue = 50_000, - maxValue = 10_000_000, - minStep = 50_000 - ) - public int hideBelow = 100_000; - - - @Expose - public Position position = new Position(107, 141, false, true); - } - - @Expose - @ConfigOption(name = "Helper", desc = "") - @Accordion - public HelperConfig helper = new HelperConfig(); - - public static class HelperConfig { - @Expose - @ConfigOption(name = "Melody's Hair Harp", desc = "") - @Accordion - public HarpConfig harp = new HarpConfig(); - - public static class HarpConfig { - @Expose - @ConfigOption(name = "Use Keybinds", desc = "In the Harp, press buttons with your number row on the keyboard instead of clicking.") - @ConfigEditorBoolean - @FeatureToggle - public boolean keybinds = false; - - @Expose - @ConfigOption(name = "Show Numbers", desc = "In the Harp, show buttons as stack size (intended to be used with the Keybinds).") - @ConfigEditorBoolean - public boolean showNumbers = false; - } - - @Expose - @ConfigOption(name = "Tia Relay Abiphone Network Maintenance", desc = "") - @Accordion - public TiaRelayConfig tiaRelay = new TiaRelayConfig(); - - public static class TiaRelayConfig { - - @Expose - @ConfigOption(name = "Sound Puzzle Helper", desc = "Helps with solving the sound puzzle for Tia (The 9 Operator Chips to do maintainance for the Abiphone Network).") - @ConfigEditorBoolean - @FeatureToggle - public boolean soundHelper = true; - - @Expose - @ConfigOption(name = "Next Waypoint", desc = "Show the next relay waypoint for Tia the Fairy, where maintenance for the Abiphone network needs to be done.") - @ConfigEditorBoolean - @FeatureToggle - public boolean nextWaypoint = true; - - @Expose - @ConfigOption(name = "All Waypoints", desc = "Show all relay waypoints at once (intended for debugging).") - @ConfigEditorBoolean - public boolean allWaypoints = false; - - @Expose - @ConfigOption(name = "Mute Sound", desc = "Mutes the sound when close to the relay.") - @ConfigEditorBoolean - @FeatureToggle - public boolean tiaRelayMute = true; - } - } - - @Expose - @ConfigOption( - name = "Item Number", - desc = "Showing the item number as a stack size for these items." - ) - @ConfigEditorDraggableList( - exampleText = { - "§bMaster Star Tier", - "§bMaster Skull Tier", - "§bDungeon Head Floor Number", - "§bNew Year Cake", - "§bPet Level", - "§bMinion Tier", - "§bCrimson Armor", - "§7(Removed)", - "§bKuudra Key", - "§bSkill Level", - "§bCollection Level", - "§bRancher's Boots speed", - "§bLarva Hook", - "§bDungeon Potion Level" - } - ) - public List itemNumberAsStackSize = new ArrayList<>(Arrays.asList(3, 9, 11, 12)); - - @Expose - @ConfigOption( - name = "Quick Craft Confirmation", - desc = "Require Ctrl+Click to craft items that aren't often quick crafted " + - "(e.g. armor, weapons, accessories). Sack items can be crafted normally." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean quickCraftingConfirmation = false; - - @Expose - @ConfigOption(name = "Sack Name", desc = "Show an abbreviation of the sack name.") - @ConfigEditorBoolean - @FeatureToggle - public boolean displaySackName = false; - - @Expose - @ConfigOption(name = "Anvil Combine Helper", desc = "Suggests the same item in the inventory when trying to combine two items in the anvil.") - @ConfigEditorBoolean - @FeatureToggle - public boolean anvilCombineHelper = false; - - @Expose - @ConfigOption(name = "Item Stars", - desc = "Show a compact star count in the item name for all items.") - @ConfigEditorBoolean - @FeatureToggle - public boolean itemStars = false; - - @Expose - @ConfigOption(name = "Missing Tasks", - desc = "Highlight missing tasks in the SkyBlock Level Guide inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlightMissingSkyBlockLevelGuide = true; - - @Expose - @ConfigOption(name = "Highlight Auctions", - desc = "Highlight own items that are sold in green and that are expired in red.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlightAuctions = true; - - @Expose - @ConfigOption(name = "Shift Click Equipment", desc = "Makes normal clicks to shift clicks in equipment inventory") - @ConfigEditorBoolean - @FeatureToggle - public boolean shiftClickForEquipment = false; - -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/ItemAbilityConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/ItemAbilityConfig.java deleted file mode 100644 index 30ba1227f2b3..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/ItemAbilityConfig.java +++ /dev/null @@ -1,74 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.FeatureToggle; -import at.hannibal2.skyhanni.config.core.config.Position; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; -import io.github.moulberry.moulconfig.annotations.ConfigOption; - -public class ItemAbilityConfig { - - @Expose - @ConfigOption(name = "Ability Cooldown", desc = "Show the cooldown of item abilities.") - @ConfigEditorBoolean - @FeatureToggle - public boolean itemAbilityCooldown = false; - - @Expose - @ConfigOption(name = "Ability Cooldown Background", desc = "Show the cooldown color of item abilities in the background.") - @ConfigEditorBoolean - public boolean itemAbilityCooldownBackground = false; - - @Expose - @ConfigOption(name = "Fire Veil", desc = "") - @Accordion - public FireVeilWandConfig fireVeilWands = new FireVeilWandConfig(); - - public static class FireVeilWandConfig { - @Expose - @ConfigOption(name = "Fire Veil Design", desc = "Changes the flame particles of the Fire Veil Wand ability.") - @ConfigEditorDropdown(values = {"Particles", "Line", "Off"}) - public int display = 0; - - @Expose - @ConfigOption( - name = "Line Color", - desc = "Changes the color of the Fire Veil Wand line." - ) - @ConfigEditorColour - public String displayColor = "0:245:255:85:85"; - } - - @ConfigOption(name = "Chicken Head", desc = "") - @Accordion - @Expose - public ChickenHeadConfig chickenHead = new ChickenHeadConfig(); - - public static class ChickenHeadConfig { - - @Expose - @ConfigOption(name = "Checken Head Timer", desc = "Show the cooldown until the next time you can lay an egg with the Chicken Head.") - @ConfigEditorBoolean - @FeatureToggle - public boolean displayTimer = false; - - @Expose - public Position position = new Position(-372, 73, false, true); - - @Expose - @ConfigOption(name = "Hide Chat", desc = "Hide the 'You laid an egg!' chat message.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideChat = true; - } - - @Expose - @ConfigOption(name = "Depleted Bonzo's Masks", - desc = "Highlights used Bonzo's Masks and Spirit Masks with a background.") - @ConfigEditorBoolean - @FeatureToggle - public boolean depletedBonzosMasks = false; -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/MiningConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/MiningConfig.java deleted file mode 100644 index 38ac5f1d34ee..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/MiningConfig.java +++ /dev/null @@ -1,111 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.FeatureToggle; -import at.hannibal2.skyhanni.config.core.config.Position; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; -import io.github.moulberry.moulconfig.annotations.ConfigOption; -import io.github.moulberry.moulconfig.observer.Property; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; - -public class MiningConfig { - - @Expose - @ConfigOption(name = "Powder Tracker", desc = "") - @Accordion - public PowderTrackerConfig powderTracker = new PowderTrackerConfig(); - - public static class PowderTrackerConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Enable the Powder Tracker overlay for mining.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Only when Grinding", desc = "Only show the overlay when powder grinding.") - @ConfigEditorBoolean - public boolean onlyWhenPowderGrinding = false; - - @Expose - @ConfigOption(name = "Great Explorer", desc = "Enable this if your Great Explorer perk is maxed.") - @ConfigEditorBoolean - public boolean greatExplorerMaxed = false; - - @Expose - @ConfigOption( - name = "Text Format", - desc = "Drag text to change the appearance of the overlay." - ) - @ConfigEditorDraggableList( - exampleText = { - "§b§lPowder Tracker", - "§7Display Mode: §a[Total] §e[This Session]", - "§d852 Total chests Picked §7(950/h)", - "§bx2 Powder: §aActive!", - "§b250,420 §aMithril Powder §7(350,000/h)", - "§b250,420 §dGemstone Powder §7(350,000/h)", - "", - "§50§7-§90§7-§a0§f-0 §cRuby Gemstone", - "§50§7-§90§7-§a0§f-0 §bSapphire Gemstone", - "§50§7-§90§7-§a0§f-0 §6Amber Gemstone", - "§50§7-§90§7-§a0§f-0 §5Amethyst Gemstone", - "§50§7-§90§7-§a0§f-0 §aJade Gemstone", - "§50§7-§90§7-§a0§f-0 §eTopaz Gemstone", - - "§b14 §9FTX 3070", - "§b14 §9Electron Transmitter", - "§b14 §9Robotron Reflector", - "§b14 §9Superlite Motor", - "§b14 §9Control Switch", - "§b14 §9Synthetic Heart", - "§b14 §9Total Robot Parts", - - "§90§7-§a0§7-§c0§f-§e0§f-§30 §fGoblin Egg", - - "§b12 §aWishing Compass", - - "§b320 §aSludge Juice", - "§b2 §9Ascension Rope", - "§b6 §5Treasurite", - "§b4 §6Jungle Heart", - "§b1 §5Pickonimbus 2000", - "§b14 §aYoggie", - "§b9 §fPrehistoric Egg", - "§b25 §aOil Barrel" - } - ) - public Property> textFormat = Property.of(new ArrayList<>(Arrays.asList(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18))); - - @Expose - public Position position = new Position(-274, 0, false, true); - - } - - @Expose - @ConfigOption(name = "Highlight Commission Mobs", desc = "Highlight Mobs that are part of active commissions.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlightCommissionMobs = false; - - @Expose - @ConfigOption(name = "King Talisman Helper", desc = "Show kings you have not talked to yet, and when the next missing king will appear.") - @ConfigEditorBoolean - @FeatureToggle - public boolean kingTalismanHelper = false; - - @Expose - public Position kingTalismanHelperPos = new Position(-400, 220, false, true); - - @Expose - @ConfigOption(name = "Names in Core", desc = "Show the names of the 4 areas while in the center of the Crystal Hollows.") - @ConfigEditorBoolean - @FeatureToggle - public boolean crystalHollowsNamesInCore = false; -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/MinionsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/MinionsConfig.java deleted file mode 100644 index a05b913dcb04..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/MinionsConfig.java +++ /dev/null @@ -1,96 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.FeatureToggle; -import at.hannibal2.skyhanni.config.core.config.Position; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; -import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; -import io.github.moulberry.moulconfig.annotations.ConfigOption; - -public class MinionsConfig { - - @Expose - @ConfigOption(name = "Name Display", desc = "Show the minion name and tier over the minion.") - @ConfigEditorBoolean - @FeatureToggle - public boolean nameDisplay = true; - - @Expose - @ConfigOption(name = "Only Tier", desc = "Show only the tier number over the minion. (Useful for Bingo)") - @ConfigEditorBoolean - public boolean nameOnlyTier = false; - - @Expose - @ConfigOption(name = "Last Clicked", desc = "") - @Accordion - public LastClickedMinionConfig lastClickedMinion = new LastClickedMinionConfig(); - - public static class LastClickedMinionConfig { - @Expose - @ConfigOption(name = "Last Minion Display", desc = "Marks the location of the last clicked minion, even through walls.") - @ConfigEditorBoolean - @FeatureToggle - public boolean display = false; - - @Expose - @ConfigOption( - name = "Last Minion Color", - desc = "The color in which the last minion should be displayed." - ) - @ConfigEditorColour - public String color = "0:245:85:255:85"; - - @Expose - @ConfigOption( - name = "Last Minion Time", - desc = "Time in seconds how long the last minion should be displayed." - ) - @ConfigEditorSlider( - minValue = 3, - maxValue = 120, - minStep = 1 - ) - public int time = 20; - } - - @Expose - @ConfigOption(name = "Emptied Time", desc = "") - @Accordion - public EmptiedTimeConfig emptiedTime = new EmptiedTimeConfig(); - - public static class EmptiedTimeConfig { - @Expose - @ConfigOption(name = "Emptied Time Display", desc = "Show the time when the hopper in the minion was last emptied.") - @ConfigEditorBoolean - @FeatureToggle - public boolean display = false; - - @Expose - @ConfigOption( - name = "Distance", - desc = "Maximum distance to display minion data." - ) - @ConfigEditorSlider( - minValue = 3, - maxValue = 30, - minStep = 1 - ) - public int distance = 10; - } - - @Expose - @ConfigOption(name = "Hopper Profit Display", desc = "Use the hopper's held coins and the last empty time to calculate the coins per day.") - @ConfigEditorBoolean - public boolean hopperProfitDisplay = true; - - @Expose - public Position hopperProfitPos = new Position(360, 90, false, true); - - @Expose - @ConfigOption(name = "Hide Mob Nametag", desc = "Hiding the nametag of mobs close to minions.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideMobsNametagNearby = false; -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/MiscConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/MiscConfig.java deleted file mode 100644 index c55c7b3d1b43..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/MiscConfig.java +++ /dev/null @@ -1,784 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.FeatureToggle; -import at.hannibal2.skyhanni.config.core.config.Position; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; -import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; -import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; -import io.github.moulberry.moulconfig.annotations.ConfigEditorText; -import io.github.moulberry.moulconfig.annotations.ConfigOption; -import io.github.moulberry.moulconfig.observer.Property; -import org.lwjgl.input.Keyboard; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; - -public class MiscConfig { - - @Expose - @ConfigOption(name = "Pet", desc = "") - @Accordion - public PetConfig pets = new PetConfig(); - public static class PetConfig { - @Expose - @ConfigOption(name = "Pet Display", desc = "Show the currently active pet.") - @ConfigEditorBoolean - @FeatureToggle - public boolean display = false; - - @Expose - @ConfigOption(name = "Pet Experience Tooltip", desc = "") - @Accordion - public PetExperienceToolTipConfig petExperienceToolTip = new PetExperienceToolTipConfig(); - - public static class PetExperienceToolTipConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Show the full pet exp and the progress to level 100 (ignoring rarity) when hovering over a pet while pressing shift key.") - @ConfigEditorBoolean - @FeatureToggle - public boolean petDisplay = true; - - @Expose - @ConfigOption(name = "Show Always", desc = "Show this info always, even if not pressing shift key.") - @ConfigEditorBoolean - public boolean showAlways = false; - - @Expose - @ConfigOption(name = "Dragon Egg", desc = "For a Golden Dragon Egg, show progress to level 100 instead of 200.") - @ConfigEditorBoolean - public boolean showGoldenDragonEgg = true; - - } - } - - @Expose - public Position petDisplayPos = new Position(-330, -15, false, true); - - @ConfigOption(name = "Hide Armor", desc = "") - @Accordion - @Expose - public HideArmor hideArmor2 = new HideArmor(); - - public static class HideArmor { - - @Expose - @ConfigOption(name = "Mode", desc = "Hide the armor of players.") - @ConfigEditorDropdown(values = {"All", "Own Armor", "Other's Armor", "Off"}) - public int mode = 3; - - @Expose - @ConfigOption(name = "Only Helmet", desc = "Only hide the helmet.") - @ConfigEditorBoolean() - public Boolean onlyHelmet = false; - - } - - @Expose - @ConfigOption(name = "Potion Effects", desc = "") - @Accordion - public PotionEffectsConfig potionEffect = new PotionEffectsConfig(); - public static class PotionEffectsConfig { - @Expose - @ConfigOption(name = "Non God Pot Effects", desc = "Display the active potion effects that are not part of the God Pot.") - @ConfigEditorBoolean - @FeatureToggle - public boolean nonGodPotEffectDisplay = false; - - @Expose - @ConfigOption(name = "Show Mixins", desc = "Include God Pot mixins in the Non God Pot Effects display.") - @ConfigEditorBoolean - @FeatureToggle - public boolean nonGodPotEffectShowMixins = false; - - @Expose - public Position nonGodPotEffectPos = new Position(10, 10, false, true); - } - - @Expose - @ConfigOption(name = "Particle Hider", desc = "") - @Accordion - public ParticleHiderConfig particleHiders = new ParticleHiderConfig(); - public static class ParticleHiderConfig { - @Expose - @ConfigOption(name = "Blaze Particles", desc = "Hide Blaze particles.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideBlazeParticles = false; - - @Expose - @ConfigOption(name = "Enderman Particles", desc = "Hide Enderman particles.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideEndermanParticles = false; - - @Expose - @ConfigOption(name = "Fireball Particles", desc = "Hide fireball particles.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideFireballParticles = true; - - @Expose - @ConfigOption(name = "Fire Particles", desc = "Hide particles from the fire block.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideFireBlockParticles = true; - - @Expose - @ConfigOption(name = "Smoke Particles", desc = "Hide smoke particles.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideSmokeParticles = false; - - @Expose - @ConfigOption(name = "Far Particles", desc = "Hide particles that are more than 40 blocks away.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideFarParticles = true; - - @Expose - @ConfigOption(name = "Close Redstone Particles", desc = "Hide Redstone particles around the player (appear for some potion effects).") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideCloseRedstoneParticles = true; - } - - @Expose - @ConfigOption(name = "Estimated Item Value", desc = "(Prices for Enchantments, Reforge Stones, Gemstones, Drill Parts and more)") - @Accordion - public EstimatedItemValueConfig estimatedItemValues = new EstimatedItemValueConfig(); - public static class EstimatedItemValueConfig { - @Expose - @ConfigOption(name = "Enable Estimated Price", desc = "Displays an Estimated Item Value for the item you hover over.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Hotkey", desc = "Press this key to show the Estimated Item Value.") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) - public int hotkey = Keyboard.KEY_NONE; - - @Expose - @ConfigOption(name = "Show Always", desc = "Ignore the hotkey and always display the item value.") - @ConfigEditorBoolean - public boolean alwaysEnabled = true; - - @Expose - @ConfigOption(name = "Enchantments Cap", desc = "Only show the top # most expensive enchantments.") - @ConfigEditorSlider( - minValue = 1, - maxValue = 30, - minStep = 1 - ) - public Property enchantmentsCap = Property.of(7); - - @Expose - @ConfigOption(name = "Show Exact Price", desc = "Show the exact total price instead of the compact number.") - @ConfigEditorBoolean - public boolean exactPrice = false; - - @Expose - @ConfigOption(name = "Show Armor Value", desc = "Show the value of the full armor set in the Wardrobe inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean armor = true; - - @Expose - public Position itemPriceDataPos = new Position(140, 90, false, true); - } - - @ConfigOption(name = "Discord Rich Presence", desc = "") - @Accordion - @Expose - public DiscordRPC discordRPC = new DiscordRPC(); - - public static class DiscordRPC { - - @Expose - @ConfigOption(name = "Enable Discord RPC", desc = "Details about your SkyBlock session displayed through Discord.") - @ConfigEditorBoolean - @FeatureToggle - public Property enabled = Property.of(false); - - @Expose - @ConfigOption(name = "First Line", desc = "Decide what to show in the first line.") - @ConfigEditorDropdown(values = { - "Nothing", - "Location", - "Purse", - "Bits", - "Stats", - "Held Item", - "SkyBlock Date", - "Profile", - "Slayer", - "Custom", - "Dynamic", - "Crop Milestone", - "Current Pet" - }) - public Property firstLine = Property.of(0); - - @Expose - @ConfigOption(name = "Second Line", desc = "Decide what to show in the second line.") - @ConfigEditorDropdown(values = { - "Nothing", - "Location", - "Purse", - "Bits", - "Stats", - "Held Item", - "SkyBlock Date", - "Profile", - "Slayer", - "Custom", - "Dynamic", - "Crop Milestone", - "Current Pet" - }) - public Property secondLine = Property.of(0); - - @Expose - @ConfigOption(name = "Custom", desc = "What should be displayed if you select \"Custom\" above.") - @ConfigEditorText - public Property customText = Property.of(""); - - @Expose - @ConfigOption(name = "Dynamic Priority", desc = "Disable certain dynamic statuses, or change the priority in case two are triggered at the same time (higher up means higher priority).") - @ConfigEditorDraggableList( - exampleText = { - "Crop Milestones", - "Slayer", - "Stacking Enchantment", - "Dungeon", - "AFK Indicator" - } - ) - public List autoPriority = new ArrayList<>(Arrays.asList(0, 1, 2, 3, 4)); - - @Expose - @ConfigOption(name = "Dynamic Fallback", desc = "What to show when none of your \"Dynamic Priority\" statuses are active.") - @ConfigEditorDropdown(values = { - "Nothing", - "Location", - "Purse", - "Bits", - "Stats", - "Held Item", - "SkyBlock Date", - "Profile", - "Slayer", - "Custom", - "Crop Milestone", - "Current Pet" - }) - public Property auto = Property.of(0); - } - - @ConfigOption(name = "Trevor The Trapper", desc = "") - @Accordion - @Expose - public TrevorTheTrapper trevorTheTrapper = new TrevorTheTrapper(); - - public static class TrevorTheTrapper { - - @Expose - @ConfigOption( - name = "Enable Data Tracker", - desc = "Tracks all of your data from doing Trevor Quests.\n" + - "Shows based on the setting below." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean dataTracker = true; - - @Expose - @ConfigOption( - name = "Show Between Quests", - desc = "Shows the tracker during and between quests otherwise it will only show during them." + - "Will show in the Trapper's Den regardless. §cToggle 'Enable Data Tracker' above." - ) - @ConfigEditorBoolean - public boolean displayType = true; - - @Expose - @ConfigOption( - name = "Text Format", - desc = "Drag text to change the appearance of the overlay." - ) - @ConfigEditorDraggableList( - exampleText = { - "§b§lTrevor Data Tracker", - "§b1,428 §9Quests Started", - "§b11,281 §5Total Pelts Gained", - "§b2,448 §5Pelts Per Hour", - "", - "§b850 §cKilled Animals", - "§b153 §cSelf Killing Animals", - "§b788 §fTrackable Animals", - "§b239 §aUntrackable Animals", - "§b115 §9Undetected Animals", - "§b73 §5Endangered Animals", - "§b12 §6Elusive Animals" - } - ) - public List textFormat = new ArrayList<>(Arrays.asList(0, 1, 2, 3, 4, 5, 7, 8, 9, 10, 11)); - - @Expose - public Position position = new Position(10, 80, false, true); - - @Expose - @ConfigOption(name = "Trapper Solver", desc = "Assists you in finding Trevor's mobs. §eNote: May not always work as expected. " + - "§cWill not help you to find rabbits or sheep in the Oasis!") - @ConfigEditorBoolean - @FeatureToggle - public boolean trapperSolver = true; - - @Expose - @ConfigOption(name = "Mob Dead Warning", desc = "Show a message when Trevor's mob dies.") - @ConfigEditorBoolean - public boolean trapperMobDiedMessage = true; - - @Expose - @ConfigOption(name = "Warp to Trapper", desc = "Warp to Trevor's Den. Works only inside the Farming Islands.") - @ConfigEditorBoolean - @FeatureToggle - public boolean warpToTrapper = false; - - @Expose - @ConfigOption(name = "Accept Trapper Quest", desc = "Click this key after the chat prompt to accept Trevor's quest.") - @ConfigEditorBoolean - @FeatureToggle - public boolean acceptQuest = false; - - @Expose - @ConfigOption(name = "Trapper Hotkey", desc = "Press this key to warp to Trevor's Den or to accept the quest. " + - "§eRequires the relevant above settings to be toggled") - @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) - public int keyBindWarpTrapper = Keyboard.KEY_NONE; - - - @Expose - @ConfigOption(name = "Trapper Cooldown", desc = "Change the color of Trevor and adds a cooldown over his head.") - @ConfigEditorBoolean - @FeatureToggle - public boolean trapperTalkCooldown = true; - - @Expose - @ConfigOption( - name = "Trapper Cooldown GUI", - desc = "Show the cooldown on screen in an overlay (intended for Abiphone users)." - ) - @ConfigEditorBoolean - public boolean trapperCooldownGui = false; - - @Expose - public Position trapperCooldownPos = new Position(10, 10, false, true); - } - - @ConfigOption(name = "Teleport Pads On Private Island", desc = "") - @Accordion - @Expose - public TeleportPad teleportPad = new TeleportPad(); - - public static class TeleportPad { - - @Expose - @ConfigOption(name = "Compact Name", desc = "Hide the 'Warp to' and 'No Destination' texts over teleport pads.") - @ConfigEditorBoolean - @FeatureToggle - public boolean compactName = false; - - @Expose - @ConfigOption(name = "Inventory Numbers", desc = "Show the number of the teleport pads inside the 'Change Destination' inventory as stack size.") - @ConfigEditorBoolean - @FeatureToggle - public boolean inventoryNumbers = false; - } - - @ConfigOption(name = "Pocket Sack-In-A-Sack", desc = "") - @Accordion - @Expose - public PocketSackInASack pocketSackInASack = new PocketSackInASack(); - - public static class PocketSackInASack { - - @Expose - @ConfigOption(name = "Show in Overlay", desc = "Show the number of Pocket Sack-In-A-Sack applied on a sack icon as an overlay.") - @ConfigEditorBoolean - @FeatureToggle - public boolean showOverlay = false; - - @Expose - @ConfigOption(name = "Replace In Lore", desc = "Replace how text is displayed in lore.\nShow §eis stitched with 2/3...\n§7Instead of §eis stitched with two...") - @ConfigEditorBoolean - @FeatureToggle - public boolean replaceLore = true; - } - - @ConfigOption(name = "Quick Mod Menu Switch", desc = "") - @Accordion - @Expose - public QuickModMenuSwitch quickModMenuSwitch = new QuickModMenuSwitch(); - - public static class QuickModMenuSwitch { - - @Expose - @ConfigOption(name = "Enabled", desc = "Adding a mod list, allowing to quickly switch between different mod menus.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Inside Escape Menu", desc = "Show the mod list while inside the Escape menu.") - @ConfigEditorBoolean - public boolean insideEscapeMenu = true; - - @Expose - @ConfigOption(name = "Inside Inventory", desc = "Show the mod list while inside the player inventory (no chest inventory).") - @ConfigEditorBoolean - public boolean insidePlayerInventory = false; - - @Expose - public Position pos = new Position(-178, 143, false, true); - } - - @Expose - @ConfigOption(name = "Cosmetic", desc = "") - @Accordion - public CosmeticConfig cosmeticConfig = new CosmeticConfig(); - - public static class CosmeticConfig { - - @Expose - @ConfigOption(name = "Following Line", desc = "") - @Accordion - public FollowingLineConfig followingLineConfig = new FollowingLineConfig(); - - public static class FollowingLineConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Draw a colored line behind the player.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Line Color", desc = "Color of the line.") - @ConfigEditorColour - public String lineColor = "0:255:255:255:255"; - - @Expose - @ConfigOption(name = "Time Alive", desc = "Time in seconds until the line fades out.") - @ConfigEditorSlider(minStep = 1, minValue = 1, maxValue = 30) - public int secondsAlive = 3; - - @Expose - @ConfigOption(name = "Max Line Width", desc = "Max width of the line.") - @ConfigEditorSlider(minStep = 1, minValue = 1, maxValue = 10) - public int lineWidth = 4; - - @Expose - @ConfigOption(name = "Behind Blocks", desc = "Show behind blocks.") - @ConfigEditorBoolean - public boolean behindBlocks = false; - } - } - - - @Expose - @ConfigOption(name = "Glowing Dropped Items", desc = "") - @Accordion - public GlowingDroppedItems glowingDroppedItems = new GlowingDroppedItems(); - - public static class GlowingDroppedItems { - - @Expose - @ConfigOption(name = "Enabled", desc = "Draws a glowing outline around all dropped items on the ground.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Highlight Showcase Items", desc = "Draws a glowing outline around showcase items.") - @ConfigEditorBoolean - public boolean highlightShowcase = false; - - @Expose - @ConfigOption(name = "Highlight Fishing Bait", desc = "Draws a glowing outline around fishing bait.") - @ConfigEditorBoolean - public boolean highlightFishingBait = false; - - } - - - @Expose - @ConfigOption(name = "Highlight Party Members", desc = "") - @Accordion - public HighlightPartyMembers highlightPartyMembers = new HighlightPartyMembers(); - - public static class HighlightPartyMembers { - - @Expose - @ConfigOption(name = "Enabled", desc = "Marking party members with a bright outline to better find them in the world.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption( - name = "Outline Color", - desc = "The color to outline party members in." - ) - @ConfigEditorColour - public String outlineColor = "0:245:85:255:85"; - - } - - - @Expose - @ConfigOption(name = "Compact Tab List", desc = "") - @Accordion - public CompactTabListConfig compactTabList = new CompactTabListConfig(); - - public static class CompactTabListConfig { - @Expose - @ConfigOption(name = "Enabled", desc = "Compacts the tablist to make it look much nicer like SBA did. Also " + - "doesn't break god-pot detection and shortens some other lines.") - //made tablist one word here so both searches will pick it up - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Hide Hypixel Adverts", desc = "Hides text from advertising the Hypixel server or store in the tablist.") - @ConfigEditorBoolean - public boolean hideAdverts = false; - - @Expose - @ConfigOption(name = "Advanced Player List", desc = "") - @Accordion - public AdvancedPlayerList advancedPlayerList = new AdvancedPlayerList(); - - public static class AdvancedPlayerList { - - @Expose - @ConfigOption(name = "Player Sort", desc = "Change the sort order of player names in the tab list.") - @ConfigEditorDropdown(values = {"Rank (Default)", "SB Level", "Name (Abc)", "Ironman/Bingo", "Party/Friends/Guild", "Random"}) - public int playerSortOrder = 0; - - @Expose - @ConfigOption(name = "Invert Sort", desc = "Flip the player list order on its head (also works with default rank).") - @ConfigEditorBoolean - public boolean reverseSort = false; - - @Expose - @ConfigOption(name = "Hide Player Icons", desc = "Hide the icons/skins of player in the tab list.") - @ConfigEditorBoolean - public boolean hidePlayerIcons = false; - - @Expose - @ConfigOption(name = "Hide Rank Color", desc = "Hide the player rank color.") - @ConfigEditorBoolean - public boolean hideRankColor = false; - - @Expose - @ConfigOption(name = "Hide Emblems", desc = "Hide the emblems behind the player name.") - @ConfigEditorBoolean - public boolean hideEmblem = false; - - @Expose - @ConfigOption(name = "Hide Level", desc = "Hide the SkyBlock level numbers.") - @ConfigEditorBoolean - public boolean hideLevel = false; - - @Expose - @ConfigOption(name = "Hide Level Brackets", desc = "Hide the gray brackets in front of and behind the level numbers.") - @ConfigEditorBoolean - public boolean hideLevelBrackets = false; - - @Expose - @ConfigOption(name = "Level Color As Name", desc = "Use the color of the SkyBlock level for the player color.") - @ConfigEditorBoolean - public boolean useLevelColorForName = false; - - @Expose - @ConfigOption(name = "Bingo Rank Number", desc = "Show the number of the bingo rank next to the icon. Useful if you are not so familar with bingo.") - @ConfigEditorBoolean - public boolean showBingoRankNumber = false; - - @Expose - @ConfigOption(name = "Hide Factions", desc = "Hide the icon of the Crimson Isle Faction in the tab list.") - @ConfigEditorBoolean - public boolean hideFactions = false; - - @Expose - @ConfigOption(name = "Mark Special Persons", desc = "Show speical icons behind the name of guild members, party members, friends, and marked players.") - @ConfigEditorBoolean - public boolean markSpecialPersons = false; - - @Expose - @ConfigOption( - name = "Mark SkyHanni Devs", - desc = "Adds a §c:O §7behind the tablist name of §cSkyHanni's contributors§7. " + - "§eThose are the folks that coded the mod for you for free :)" - ) - @ConfigEditorBoolean - public boolean markSkyHanniContributors = false; - } - } - - @Expose - @ConfigOption(name = "Kick Duration", desc = "") - @Accordion - public KickDurationConfig kickDuration = new KickDurationConfig(); - - public static class KickDurationConfig { - - @Expose - @ConfigOption( - name = "Enabled", - desc = "Show in the Hypixel lobby since when you were last kicked from SkyBlock (" + - "useful if you get blocked because of '§cYou were kicked while joining that server!§7')." - ) - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Warn Time", desc = "Send warning and sound this seconds after a SkyBlock kick.") - @ConfigEditorSlider( - minValue = 5, - maxValue = 300, - minStep = 1 - ) - public Property warnTime = Property.of(60); - - @Expose - public Position position = new Position(400, 200, 1.3f); - } - - @Expose - @ConfigOption(name = "Exp Bottles", desc = "Hides all the experience orbs lying on the ground.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideExpBottles = false; - - @Expose - public Position collectionCounterPos = new Position(10, 10, false, true); - - @Expose - @ConfigOption(name = "Brewing Stand Overlay", desc = "Display the Item names directly inside the Brewing Stand.") - @ConfigEditorBoolean - @FeatureToggle - public boolean brewingStandOverlay = true; - - @Expose - @ConfigOption(name = "Red Scoreboard Numbers", desc = "Hide the red scoreboard numbers on the right side of the screen.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideScoreboardNumbers = false; - - @Expose - @ConfigOption(name = "Hide Piggy", desc = "Replacing 'Piggy' with 'Purse' in the Scoreboard.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hidePiggyScoreboard = true; - - @Expose - @ConfigOption(name = "Explosions Hider", desc = "Hide explosions.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideExplosions = false; - - @Expose - @ConfigOption(name = "CH Join", desc = "Helps buy a Pass for accessing the Crystal Hollows if needed.") - @ConfigEditorBoolean - @FeatureToggle - public boolean crystalHollowsJoin = true; - - @Expose - @ConfigOption(name = "Fire Overlay Hider", desc = "Hide the fire overlay (Like in Skytils).") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideFireOverlay = false; - - @Expose - @ConfigOption(name = "Paste Into Signs", desc = "Allows you to paste the clipboard into signs when you press Ctrl + V.") - @ConfigEditorBoolean - @FeatureToggle - public boolean pasteIntoSigns = true; - - @Expose - @ConfigOption(name = "Movement Speed", desc = "Show the player movement speed in blocks per second.") - @ConfigEditorBoolean - @FeatureToggle - public boolean playerMovementSpeed = false; - - @Expose - public Position playerMovementSpeedPos = new Position(394, 124, false, true); - - @Expose - @ConfigOption(name = "Pet Candy Used", desc = "Show the number of Pet Candy used on a pet.") - @ConfigEditorBoolean - @FeatureToggle - public boolean petCandyUsed = true; - - @Expose - @ConfigOption(name = "Server Restart Title", desc = "Show a title with seconds remaining until the server restarts after a Game Update or Scheduled Restart.") - @ConfigEditorBoolean - @FeatureToggle - public boolean serverRestartTitle = true; - - @Expose - @ConfigOption(name = "Piece Of Wizard Portal", desc = "Restore the Earned By lore line on bought Piece Of Wizard Portal.") - @ConfigEditorBoolean - @FeatureToggle - public boolean restorePieceOfWizardPortalLore = true; - - @Expose - @ConfigOption(name = "Patcher Coords Waypoint", desc = "Highlight the coordinates sent by Patcher.") - @ConfigEditorBoolean - @FeatureToggle - public boolean patcherSendCoordWaypoint = false; - - - @Expose - @ConfigOption(name = "Account Upgrade Reminder", desc = "Remind you to claim account upgrades when complete.") - @ConfigEditorBoolean - @FeatureToggle - public boolean accountUpgradeReminder = true; - - @Expose - @ConfigOption(name = "Superpairs Clicks Alert", desc = "Display an alert when you reach the maximum clicks gained from Chronomatron or Ultrasequencer.") - @ConfigEditorBoolean - @FeatureToggle - public boolean superpairsClicksAlert = false; - - @Expose - @ConfigOption(name = "NEU Heavy Pearls", desc = "Fixing NEU Heavy Pearl detection.") - @ConfigEditorBoolean - @FeatureToggle - public boolean fixNeuHeavyPearls = true; - - @Expose - @ConfigOption( - name = "Time In Limbo", - desc = "Show the time since you entered the limbo.") - @ConfigEditorBoolean - @FeatureToggle - public boolean showTimeInLimbo = true; - - @Expose - public Position showTimeInLimboPosition = new Position(400, 200, 1.3f); - - @Expose - public Position inventoryLoadPos = new Position(394, 124, false, true); -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/OldHidden.java b/src/main/java/at/hannibal2/skyhanni/config/features/OldHidden.java deleted file mode 100644 index a2694210fd18..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/OldHidden.java +++ /dev/null @@ -1,118 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.data.model.ComposterUpgrade; -import at.hannibal2.skyhanni.features.garden.CropAccessory; -import at.hannibal2.skyhanni.features.garden.CropType; -import at.hannibal2.skyhanni.features.garden.farming.FarmingArmorDrops; -import at.hannibal2.skyhanni.features.garden.visitor.VisitorReward; -import com.google.gson.annotations.Expose; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class OldHidden { - - @Expose - public String currentPet = ""; - - @Expose - public Map minionLastClick = new HashMap<>(); - - @Expose - public Map minionName = new HashMap<>(); - - @Expose - public List crimsonIsleQuests = new ArrayList<>(); - - @Expose - public List crimsonIsleMiniBossesDoneToday = new ArrayList<>(); - - @Expose - public List crimsonIsleKuudraTiersDone = new ArrayList<>(); - - @Expose - public Map gardenCropCounter = new HashMap<>(); - - @Expose - public Map gardenCropUpgrades = new HashMap<>(); - - @Expose - public Map gardenCropsPerSecond = new HashMap<>(); - - @Expose - public Map gardenLatestBlocksPerSecond = new HashMap<>(); - - @Expose - public Map gardenLatestTrueFarmingFortune = new HashMap<>(); - - @Expose - public int gardenExp = -1; - - @Expose - public CropAccessory savedCropAccessory = null; - - @Expose - public Map gardenDicerRngDrops = new HashMap<>(); - - @Expose - public long informedAboutLowMatter = 0; - - @Expose - public long informedAboutLowFuel = 0; - - @Expose - public long visitorInterval = 15 * 60_000L; - - @Expose - public long nextSixthVisitorArrival = 0; - - @Expose - public Map> gardenJacobFarmingContestTimes = new HashMap<>(); - - @Expose - public Map gardenFarmingArmorDrops = new HashMap<>(); - - @Expose - public Map gardenComposterUpgrades = new HashMap<>(); - - @Expose - public Map gardenToolHasBountiful = new HashMap<>(); - - @Expose - public String gardenComposterCurrentOrganicMatterItem = ""; - - @Expose - public String gardenComposterCurrentFuelItem = ""; - - - @Expose - public VisitorDrops visitorDrops = new VisitorDrops(); - - public static class VisitorDrops { - @Expose - public int acceptedVisitors = 0; - - @Expose - public int deniedVisitors = 0; - - @Expose - public List visitorRarities = new ArrayList<>(); - - @Expose - public int copper = 0; - - @Expose - public long farmingExp = 0; - - @Expose - public long coinsSpent = 0; - - @Expose - public Map rewardsCount = new HashMap<>(); - } - - @Expose - public boolean isMigrated = false; -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/RiftConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/RiftConfig.java deleted file mode 100644 index 9021ec9be230..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/RiftConfig.java +++ /dev/null @@ -1,720 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.FeatureToggle; -import at.hannibal2.skyhanni.config.core.config.Position; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; -import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; -import io.github.moulberry.moulconfig.annotations.ConfigEditorText; -import io.github.moulberry.moulconfig.annotations.ConfigOption; -import io.github.moulberry.moulconfig.observer.Property; - -public class RiftConfig { - - @ConfigOption(name = "Rift Timer", desc = "") - @Accordion - @Expose - public RiftTimerConfig timer = new RiftTimerConfig(); - - public static class RiftTimerConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Show the remaining rift time, max time, percentage, and extra time changes.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Max Time", desc = "Show max time.") - @ConfigEditorBoolean - public boolean maxTime = true; - - @Expose - @ConfigOption(name = "Percentage", desc = "Show percentage.") - @ConfigEditorBoolean - public boolean percentage = true; - - @Expose - public Position timerPosition = new Position(10, 10, false, true); - - } - - @ConfigOption(name = "Crux Talisman Progress", desc = "") - @Accordion - @Expose - public CruxTalismanDisplayConfig cruxTalisman = new CruxTalismanDisplayConfig(); - - public static class CruxTalismanDisplayConfig { - @Expose - @ConfigOption(name = "Crux Talisman Display", desc = "Display progress of the Crux Talisman on screen.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Compact", desc = "Show a compacted version of the overlay when the talisman is maxed.") - @ConfigEditorBoolean - public boolean compactWhenMaxed = false; - - @Expose - @ConfigOption(name = "Show Bonuses", desc = "Show bonuses you get from the talisman.") - @ConfigEditorBoolean - @FeatureToggle - public Property showBonuses = Property.of(true); - - @Expose - public Position position = new Position(144, 139, false, true); - } - - @ConfigOption(name = "Enigma Soul Waypoints", desc = "") - @Accordion - @Expose - public EnigmaSoulConfig enigmaSoulWaypoints = new EnigmaSoulConfig(); - - public static class EnigmaSoulConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Click on Enigma Souls in Rift Guides to highlight their location.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Color", desc = "Color of the Enigma Souls.") - @ConfigEditorColour - public String color = "0:120:13:49:255"; - - } - - @ConfigOption(name = "Rift Areas", desc = "") - @Accordion - @Expose - public RiftAreasConfig area = new RiftAreasConfig(); - - public static class RiftAreasConfig { - - @ConfigOption(name = "Wyld Woods", desc = "") - @Accordion - @Expose - public WyldWoodsConfig wyldWoodsConfig = new WyldWoodsConfig(); - - public static class WyldWoodsConfig { - - @Expose - @ConfigOption(name = "Shy Crux Warning", desc = "Shows a warning when a Shy Crux is going to steal your time. " + - "Useful if you play without volume.") - @ConfigEditorBoolean - @FeatureToggle - public boolean shyWarning = true; - - @ConfigOption(name = "Larvas", desc = "") - @Accordion - @Expose - public LarvasConfig larvas = new LarvasConfig(); - - public static class LarvasConfig { - - @Expose - @ConfigOption(name = "Highlight", desc = "Highlight §cLarvas on trees §7while holding a §eLarva Hook §7in the hand.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlight = true; - - @Expose - @ConfigOption(name = "Color", desc = "Color of the Larvas.") - @ConfigEditorColour - public String highlightColor = "0:120:13:49:255"; - - } - - @ConfigOption(name = "Odonatas", desc = "") - @Accordion - @Expose - public OdonataConfig odonata = new OdonataConfig(); - - public static class OdonataConfig { - - @Expose - @ConfigOption(name = "Highlight", desc = "Highlight the small §cOdonatas §7flying around the trees while holding an " + - "§eEmpty Odonata Bottle §7in the hand.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlight = true; - - @Expose - @ConfigOption(name = "Color", desc = "Color of the Odonatas.") - @ConfigEditorColour - public String highlightColor = "0:120:13:49:255"; - - } - } - - @ConfigOption(name = "West Village", desc = "") - @Accordion - @Expose - public WestVillageConfig westVillageConfig = new WestVillageConfig(); - - public static class WestVillageConfig { - - @ConfigOption(name = "Kloon Hacking", desc = "") - @Accordion - @Expose - public KloonHackingConfig hacking = new KloonHackingConfig(); - - public static class KloonHackingConfig { - - @Expose - @ConfigOption(name = "Hacking Solver", desc = "Highlights the correct button to click in the hacking inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean solver = true; - - @Expose - @ConfigOption(name = "Color Guide", desc = "Tells you which color to pick.") - @ConfigEditorBoolean - @FeatureToggle - public boolean colour = true; - - @Expose - @ConfigOption(name = "Terminal Waypoints", desc = "While wearing the helmet, waypoints will appear at each terminal location.") - @ConfigEditorBoolean - @FeatureToggle - public boolean waypoints = true; - } - } - - @Expose - @ConfigOption(name = "Dreadfarm", desc = "") - @Accordion - public DreadfarmConfig dreadfarmConfig = new DreadfarmConfig(); - - public static class DreadfarmConfig { - @Expose - @ConfigOption(name = "Agaricus Cap", desc = "Counts down the time until §eAgaricus Cap (Mushroom) " + - "§7changes color from brown to red and is breakable.") - @ConfigEditorBoolean - @FeatureToggle - public boolean agaricusCap = true; - - @ConfigOption(name = "Volt Crux", desc = "") - @Accordion - @Expose - public VoltCruxConfig voltCrux = new VoltCruxConfig(); - - public static class VoltCruxConfig { - - @Expose - @ConfigOption(name = "Volt Warning", desc = "Shows a warning while a Volt is discharging lightning.") - @ConfigEditorBoolean - @FeatureToggle - public boolean voltWarning = true; - - @Expose - @ConfigOption(name = "Volt Range Highlighter", desc = "Shows the area in which a Volt might strike lightning.") - @ConfigEditorBoolean - @FeatureToggle - public boolean voltRange = true; - - @Expose - @ConfigOption(name = "Volt Range Highlighter Color", desc = "In which color should the Volt range be highlighted?") - @ConfigEditorColour - public String voltColour = "0:60:0:0:255"; - - @Expose - @ConfigOption(name = "Volt Mood Color", desc = "Change the color of the Volt enemy depending on their mood.") - @ConfigEditorBoolean - @FeatureToggle - public boolean voltMoodMeter = false; - } - - @ConfigOption(name = "Wilted Berberis", desc = "") - @Accordion - @Expose - public WiltedBerberisConfig wiltedBerberis = new WiltedBerberisConfig(); - - public static class WiltedBerberisConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Show Wilted Berberis helper.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Only on Farmland", desc = "Only show the helper while standing on Farmland blocks.") - @ConfigEditorBoolean - public boolean onlyOnFarmland = false; - - @Expose - @ConfigOption(name = "Hide Particles", desc = "Hide the Wilted Berberis particles.") - @ConfigEditorBoolean - public boolean hideparticles = false; - - } - } - - @ConfigOption(name = "Mirrorverse", desc = "") - @Accordion - @Expose - public MirrorVerseConfig mirrorVerseConfig = new MirrorVerseConfig(); - - public static class MirrorVerseConfig { - - @ConfigOption(name = "Lava Maze", desc = "") - @Accordion - @Expose - public LavaMazeConfig lavaMazeConfig = new LavaMazeConfig(); - - public static class LavaMazeConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Helps solving the lava maze in the Mirrorverse by showing the correct way.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Look Ahead", desc = "Change how many platforms should be shown in front of you.") - @ConfigEditorSlider(minStep = 1, maxValue = 30, minValue = 1) - public Property lookAhead = Property.of(3); - - @Expose - @ConfigOption(name = "Rainbow Color", desc = "Show the rainbow color effect instead of a boring monochrome.") - @ConfigEditorBoolean - public Property rainbowColor = Property.of(true); - - @Expose - @ConfigOption(name = "Monochrome Color", desc = "Set a boring monochrome color for the parkour platforms.") - @ConfigEditorColour - public Property monochromeColor = Property.of("0:60:0:0:255"); - - @Expose - @ConfigOption(name = "Hide Others Players", desc = "Hide other players while doing the lava maze.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hidePlayers = false; - } - - - @ConfigOption(name = "Upside Down Parkour", desc = "") - @Accordion - @Expose - public UpsideDownParkourConfig upsideDownParkour = new UpsideDownParkourConfig(); - - public static class UpsideDownParkourConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Helps solving the upside down parkour in the Mirrorverse by showing the correct way.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Look Ahead", desc = "Change how many platforms should be shown in front of you.") - @ConfigEditorSlider(minStep = 1, maxValue = 9, minValue = 1) - public Property lookAhead = Property.of(3); - - @Expose - @ConfigOption(name = "Outline", desc = "Outlines the top edge of the platforms.") - @ConfigEditorBoolean - public boolean outline = true; - - @Expose - @ConfigOption(name = "Rainbow Color", desc = "Show the rainbow color effect instead of a boring monochrome.") - @ConfigEditorBoolean - public Property rainbowColor = Property.of(true); - - @Expose - @ConfigOption(name = "Monochrome Color", desc = "Set a boring monochrome color for the parkour platforms.") - @ConfigEditorColour - public Property monochromeColor = Property.of("0:60:0:0:255"); - - @Expose - @ConfigOption(name = "Hide Others Players", desc = "Hide other players while doing the upside down parkour.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hidePlayers = false; - } - - - @ConfigOption(name = "Dance Room Helper", desc = "") - @Accordion - @Expose - public DanceRoomHelperConfig danceRoomHelper = new DanceRoomHelperConfig(); - - public static class DanceRoomHelperConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Helps to solve the dance room in the Mirrorverse by showing multiple tasks at once.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Lines to Show", desc = "How many tasks you should see.") - @ConfigEditorSlider(minStep = 1, maxValue = 49, minValue = 1) - public int lineToShow = 3; - - @Expose - @ConfigOption(name = "Space", desc = "Change the space between each line.") - @ConfigEditorSlider(minStep = 1, maxValue = 10, minValue = -5) - public int extraSpace = 0; - - @Expose - @ConfigOption(name = "Hide Other Players", desc = "Hide other players inside the dance room.") - @ConfigEditorBoolean - public boolean hidePlayers = false; - - @Expose - @ConfigOption(name = "Hide Title", desc = "Hide Instructions, \"§aIt's happening!\" §7and \"§aKeep it up!\" §7titles.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideOriginalTitle = false; - - @Expose - @ConfigOption(name = "Formatting", desc = "") - @Accordion - public DanceRoomFormattingConfig danceRoomFormatting = new DanceRoomFormattingConfig(); - - public static class DanceRoomFormattingConfig { - - @Expose - @ConfigOption(name = "Now", desc = "Formatting for \"Now:\"") - @ConfigEditorText - public String now = "&7Now:"; - - @Expose - @ConfigOption(name = "Next", desc = "Formatting for \"Next:\"") - @ConfigEditorText - public String next = "&7Next:"; - - @Expose - @ConfigOption(name = "Later", desc = "Formatting for \"Later:\"") - @ConfigEditorText - public String later = "&7Later:"; - - @Expose - @ConfigOption(name = "Color Option", desc = "") - @Accordion - public ColorConfig color = new ColorConfig(); - - public static class ColorConfig { - @Expose - @ConfigOption(name = "Move", desc = "Color for the Move instruction") - @ConfigEditorText - public String move = "&e"; - - @Expose - @ConfigOption(name = "Stand", desc = "Color for the Stand instruction") - @ConfigEditorText - public String stand = "&e"; - - @Expose - @ConfigOption(name = "Sneak", desc = "Color for the Sneak instruction") - @ConfigEditorText - public String sneak = "&5"; - - @Expose - @ConfigOption(name = "Jump", desc = "Color for the Jump instruction") - @ConfigEditorText - public String jump = "&b"; - - @Expose - @ConfigOption(name = "Punch", desc = "Color for the Punch instruction") - @ConfigEditorText - public String punch = "&d"; - - @Expose - @ConfigOption(name = "Countdown", desc = "Color for the Countdown") - @ConfigEditorText - public String countdown = "&f"; - - @Expose - @ConfigOption(name = "Default", desc = "Fallback color") - @ConfigEditorText - public String fallback = "&f"; - } - } - - @Expose - public Position position = new Position(442, 239, false, true); - } - - - @ConfigOption(name = "Tubulator", desc = "") - @Accordion - @Expose - public TubulatorConfig tubulatorConfig = new TubulatorConfig(); - - public static class TubulatorConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Highlights the location of the invisible Tubulator blocks (Laser Parkour).") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Look Ahead", desc = "Change how many platforms should be shown in front of you.") - @ConfigEditorSlider(minStep = 1, maxValue = 30, minValue = 1) - public Property lookAhead = Property.of(2); - - @Expose - @ConfigOption(name = "Outline", desc = "Outlines the top edge of the platforms.") - @ConfigEditorBoolean - public boolean outline = true; - - @Expose - @ConfigOption(name = "Rainbow Color", desc = "Show the rainbow color effect instead of a boring monochrome.") - @ConfigEditorBoolean - public Property rainbowColor = Property.of(true); - - @Expose - @ConfigOption(name = "Monochrome Color", desc = "Set a boring monochrome color for the parkour platforms.") - @ConfigEditorColour - public Property monochromeColor = Property.of("0:60:0:0:255"); - - @Expose - @ConfigOption(name = "Hide Other Players", desc = "Hide other players while doing the lava maze.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hidePlayers = false; - } - } - -// @Expose -// @ConfigOption(name = "Village Plaza", desc = "") -// @Accordion -// public VillagePlazaConfig villagePlazaConfig = new VillagePlazaConfig(); -// -// public static class VillagePlazaConfig { -// -// } - - @Expose - @ConfigOption(name = "Living Cave", desc = "") - @Accordion - public LivingCaveConfig livingCaveConfig = new LivingCaveConfig(); - - public static class LivingCaveConfig { - - @Expose - @ConfigOption(name = "Living Metal Suit Progress", desc = "") - @Accordion - public LivingMetalSuitProgressConfig livingMetalSuitProgress = new LivingMetalSuitProgressConfig(); - - public static class LivingMetalSuitProgressConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Display Living Metal Suit progress.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Compact", desc = "Show a compacted version of the overlay when the set is maxed.") - @ConfigEditorBoolean - public boolean compactWhenMaxed = false; - - @Expose - public Position position = new Position(100, 100); - } - - @Expose - @ConfigOption(name = "Defense Blocks", desc = "") - @Accordion - public DefenseBlockConfig defenseBlockConfig = new DefenseBlockConfig(); - - public static class DefenseBlockConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Show a line between Defense blocks and the mob and highlight the blocks.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Hide Particles", desc = "Hide particles around Defense Blocks.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideParticles = false; - - @Expose - @ConfigOption(name = "Color", desc = "Set the color of the lines, blocks and the entity.") - @ConfigEditorColour - public Property color = Property.of("0:255:77:104:255"); - - } - - @Expose - @ConfigOption(name = "Living Metal Helper", desc = "") - @Accordion - public LivingCaveLivingMetalConfig livingCaveLivingMetalConfig = new LivingCaveLivingMetalConfig(); - - public static class LivingCaveLivingMetalConfig { - - @Expose - @ConfigOption(name = "Living Metal", desc = "Show a moving animation between Living Metal and the next block.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Hide Particles", desc = "Hide Living Metal particles.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideParticles = false; - - } - } - - @Expose - @ConfigOption(name = "Colosseum", desc = "") - @Accordion - public ColosseumConfig colosseumConfig = new ColosseumConfig(); - - public static class ColosseumConfig { - - @Expose - @ConfigOption(name = "Highlight Blobbercysts", desc = "Highlight Blobbercysts in Bacte fight.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlightBlobbercysts = true; - } - - @Expose - @ConfigOption(name = "Stillgore Chateau", desc = "") - @Accordion - public StillgoreChateauConfig stillgoreChateauConfig = new StillgoreChateauConfig(); - - public static class StillgoreChateauConfig { - - @Expose - @ConfigOption(name = "Blood Effigies", desc = "") - @Accordion - public EffigiesConfig bloodEffigies = new EffigiesConfig(); - - public static class EffigiesConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Show locations of inactive Blood Effigies.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Respawning Soon", desc = "Show effigies that are about to respawn.") - @ConfigEditorBoolean - @FeatureToggle - public boolean respawningSoon = false; - - @Expose - @ConfigOption(name = "Respawning Time", desc = "Time before effigies respawn to show.") - @ConfigEditorSlider( - minValue = 1, - maxValue = 15, - minStep = 1 - ) - public int respwningSoonTime = 3; - - @Expose - @ConfigOption(name = "Unknown Times", desc = "Show effigies without known time.") - @ConfigEditorBoolean - @FeatureToggle - public boolean unknownTime = false; - } - } - -// @Expose -// @ConfigOption(name = "Mountaintop", desc = "") -// @Accordion -// public MountaintopConfig mountaintopConfig = new MountaintopConfig(); -// -// public static class MountaintopConfig { -// -// } - - } - - @Expose - @ConfigOption(name = "Motes Sell Price", desc = "") - @Accordion - public MotesConfig motes = new MotesConfig(); - - public static class MotesConfig { - - @Expose - @ConfigOption(name = "Show Motes Price", desc = "Show the Motes NPC price in the item lore.") - @ConfigEditorBoolean - @FeatureToggle - public boolean showPrice = true; - - @Expose - @ConfigOption(name = "Burger Stacks", desc = "Set your McGrubber's burger stacks.") - @ConfigEditorSlider(minStep = 1, minValue = 0, maxValue = 5) - public int burgerStacks = 0; - - @Expose - @ConfigOption(name = "Inventory Value", desc = "") - @Accordion - public InventoryValueConfig inventoryValue = new InventoryValueConfig(); - - public static class InventoryValueConfig { - @Expose - @ConfigOption(name = "Inventory Value", desc = "Show total Motes NPC price for the current opened inventory.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Number Format Type", desc = "Short: 1.2M\n" + - "Long: 1,200,000") - @ConfigEditorDropdown(values = {"Short", "Long"}) - public int formatType = 0; - - @Expose - public Position position = new Position(126, 156, false, true); - } - } - - @Expose - @ConfigOption(name = "Motes Orbs", desc = "") - @Accordion - public MotesOrbsConfig motesOrbsConfig = new MotesOrbsConfig(); - - public static class MotesOrbsConfig { - - @Expose - @ConfigOption(name = "Highlight Motes Orbs", desc = "Highlight flying Motes Orbs.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Highlight Size", desc = "Set render size for highlighted Motes Orbs.") - @ConfigEditorSlider(minStep = 1, minValue = 1, maxValue = 5) - public int size = 3; - - @Expose - @ConfigOption(name = "Hide Particles", desc = "Hide normal Motes Orbs particles.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideParticles = false; - - } - - @Expose - @ConfigOption(name = "Highlight Guide", desc = "Highlight things to do in the Rift Guide.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlightGuide = true; - - @Expose - @ConfigOption(name = "Horsezooka Hider", desc = "Hide horses while holding the Horsezooka in the hand.") - @ConfigEditorBoolean - @FeatureToggle - public boolean horsezookaHider = false; -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/SlayerConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/SlayerConfig.java deleted file mode 100644 index 6ca5ec984532..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/config/features/SlayerConfig.java +++ /dev/null @@ -1,523 +0,0 @@ -package at.hannibal2.skyhanni.config.features; - -import at.hannibal2.skyhanni.config.FeatureToggle; -import at.hannibal2.skyhanni.config.core.config.Position; -import com.google.gson.annotations.Expose; -import io.github.moulberry.moulconfig.annotations.Accordion; -import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; -import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; -import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; -import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; -import io.github.moulberry.moulconfig.annotations.ConfigEditorText; -import io.github.moulberry.moulconfig.annotations.ConfigOption; - -public class SlayerConfig { - - @Expose - @ConfigOption(name = "Enderman Slayer Features", desc = "") - @Accordion - public EndermanConfig endermen = new EndermanConfig(); - - public static class EndermanConfig { - @Expose - @ConfigOption(name = "Yang Glyph (beacon)", desc = "") - @Accordion - public EndermanBeaconConfig endermanBeaconConfig = new EndermanBeaconConfig(); - - public static class EndermanBeaconConfig { - - @Expose - @ConfigOption(name = "Highlight Beacon", - desc = "Highlight the Enderman Slayer Yang Glyph (beacon) in red color and added a timer for when he explodes. " + - "Supports beacon in hand and beacon flying.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlightBeacon = true; - - @Expose - @ConfigOption(name = "Beacon Color", desc = "Color of the beacon.") - @ConfigEditorColour - public String beaconColor = "0:255:255:0:88"; - - @Expose - @ConfigOption(name = "Show Warning", desc = "Displays a warning mid-screen when the Enderman Slayer throws a Yang Glyph (beacon).") - @ConfigEditorBoolean - @FeatureToggle - public boolean showWarning = false; - - @Expose - @ConfigOption(name = "Show Line", desc = "Draw a line starting at your crosshair to the beacon.") - @ConfigEditorBoolean - @FeatureToggle - public boolean showLine = false; - - @Expose - @ConfigOption(name = "Line Color", desc = "Color of the line.") - @ConfigEditorColour - public String lineColor = "0:255:255:0:88"; - - @Expose - @ConfigOption(name = "Line Width", desc = "Width of the line.") - @ConfigEditorSlider(minStep = 1, minValue = 1, maxValue = 10) - public int lineWidth = 3; - } - - @Expose - @ConfigOption(name = "Highlight Nukekubi Skulls", desc = "Highlights the Enderman Slayer Nukekubi Skulls (Eyes).") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlightNukekebi = false; - - @Expose - @ConfigOption(name = "Phase Display", desc = "Show the current phase of the Enderman Slayer in damage indcator.") - @ConfigEditorBoolean - public boolean phaseDisplay = false; - - @Expose - @ConfigOption(name = "Hide Particles", desc = "Hide particles around Enderman Slayer bosses and Mini-Bosses.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideParticles = false; - } - - - @Expose - @ConfigOption(name = "Blaze", desc = "") - @Accordion - public BlazeConfig blazes = new BlazeConfig(); - - public static class BlazeConfig { - @Expose - @ConfigOption(name = "Hellion Shields", desc = "") - @Accordion - public BlazeHellionConfig hellion = new BlazeHellionConfig(); - - public static class BlazeHellionConfig { - @Expose - @ConfigOption(name = "Colored Mobs", desc = "Color the Blaze Slayer boss and the demons in the right hellion shield color.") - @ConfigEditorBoolean - @FeatureToggle - public boolean coloredMobs = false; - - @Expose - @ConfigOption(name = "Blaze Daggers", desc = "Faster and permanent display for the Blaze Slayer daggers.") - @ConfigEditorBoolean - @FeatureToggle - public boolean daggers = false; - - @Expose - @ConfigOption(name = "Right Dagger", desc = "Mark the right dagger to use for Blaze Slayer in the dagger overlay.") - @ConfigEditorBoolean - @FeatureToggle - public boolean markRightHellionShield = false; - - @Expose - @ConfigOption(name = "First Dagger", desc = "Select the first, left sided dagger for the display.") - @ConfigEditorDropdown(values = {"Spirit/Crystal", "Ashen/Auric"}) - public int firstDagger = 0; - - @Expose - @ConfigOption(name = "Hide Chat", desc = "Remove the wrong Blaze Slayer dagger messages from chat.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideDaggerWarning = false; - } - - - @Expose - @ConfigOption(name = "Fire Pits", desc = "Warning when the fire pit phase starts for the Blaze Slayer tier 3 and 4.") - @ConfigEditorBoolean - @FeatureToggle - public boolean firePitsWarning = false; - - @Expose - @ConfigOption(name = "Phase Display", desc = "Show the current phase of the Blaze Slayer boss.") - @ConfigEditorBoolean - public boolean phaseDisplay = false; - - @Expose - @ConfigOption(name = "Clear View", desc = "Hide particles and fireballs near Blaze Slayer bosses and demons.") - @ConfigEditorBoolean - @FeatureToggle - public boolean clearView = false; - } - - - @Expose - @ConfigOption(name = "Vampire Slayer Features", desc = "") - @Accordion - public VampireSlayerConfig vampireSlayerConfig = new VampireSlayerConfig(); - - public static class VampireSlayerConfig { - - @Expose - @ConfigOption(name = "Your Boss", desc = "") - @Accordion - public OwnBossConfig ownBoss = new OwnBossConfig(); - - public static class OwnBossConfig { - - @Expose - @ConfigOption(name = "Highlight Your Boss", desc = "Highlight your own Vampire Slayer boss.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlight = true; - - @Expose - @ConfigOption(name = "Highlight Color", desc = "What color to highlight the boss in.") - @ConfigEditorColour - public String highlightColor = "0:249:0:255:88"; - - @Expose - @ConfigOption(name = "Steak Alert", desc = "Show a title when you can steak your boss.") - @ConfigEditorBoolean - @FeatureToggle - public boolean steakAlert = true; - - @Expose - @ConfigOption(name = "Twinclaws Title", desc = "Send a title when Twinclaws is about to happen.\nWork on others highlighted people boss.") - @ConfigEditorBoolean - @FeatureToggle - public boolean twinClawsTitle = true; - - @Expose - @ConfigOption(name = "Twinclaws Sound", desc = "Play a sound when Twinclaws is about to happen.") - @ConfigEditorBoolean - @FeatureToggle - public boolean twinClawsSound = true; - } - - @Expose - @ConfigOption(name = "Others Boss", desc = "") - @Accordion - public OthersBossConfig othersBoss = new OthersBossConfig(); - - public static class OthersBossConfig { - - @Expose - @ConfigOption(name = "Highlight Others Boss", desc = "Highlight others players boss.\nYou need to hit them first.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlight = true; - - @Expose - @ConfigOption(name = "Highlight Color", desc = "What color to highlight the boss in.") - @ConfigEditorColour - public String highlightColor = "0:249:0:255:88"; - - @Expose - @ConfigOption(name = "Steak Alert", desc = "Show a title when you can steak the boss.") - @ConfigEditorBoolean - @FeatureToggle - public boolean steakAlert = true; - - @Expose - @ConfigOption(name = "Twinclaws Title", desc = "Send a title when Twinclaws is about to happen.") - @ConfigEditorBoolean - @FeatureToggle - public boolean twinClawsTitle = true; - - @Expose - @ConfigOption(name = "Twinclaws Sound", desc = "Play a sound when Twinclaws is about to happen.") - @ConfigEditorBoolean - @FeatureToggle - public boolean twinClawsSound = true; - } - - @Expose - @ConfigOption(name = "Co-op Boss", desc = "") - @Accordion - public CoopBossHighlightConfig coopBoss = new CoopBossHighlightConfig(); - - public static class CoopBossHighlightConfig { - @Expose - @ConfigOption(name = "Highlight Co-op Boss", desc = "Highlight boss of your co-op member.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlight = true; - - @Expose - @ConfigOption(name = "Highlight Color", desc = "What color to highlight the boss in.") - @ConfigEditorColour - public String highlightColor = "0:249:0:255:88"; - - @Expose - @ConfigOption(name = "Co-op Members", desc = "Add your co-op member here.\n§eFormat: §7Name1,Name2,Name3") - @ConfigEditorText - public String coopMembers = ""; - - @Expose - @ConfigOption(name = "Steak Alert", desc = "Show a title when you can steak the boss.") - @ConfigEditorBoolean - @FeatureToggle - public boolean steakAlert = true; - - @Expose - @ConfigOption(name = "Twinclaws Title", desc = "Send a title when Twinclaws is about to happen.") - @ConfigEditorBoolean - @FeatureToggle - public boolean twinClawsTitle = true; - - @Expose - @ConfigOption(name = "Twinclaws Sound", desc = "Play a sound when Twinclaws is about to happen.") - @ConfigEditorBoolean - @FeatureToggle - public boolean twinClawsSound = true; - } - - @Expose - @ConfigOption(name = "Transparency", desc = "Choose the transparency of the color.") - @ConfigEditorSlider(minStep = 1, minValue = 1, maxValue = 250) - public int withAlpha = 80; - - @Expose - @ConfigOption(name = "See Through Blocks", desc = "Highlight even when behind others mobs/players.") - @ConfigEditorBoolean - public boolean seeThrough = false; - - @Expose - @ConfigOption(name = "Low Health", desc = "Change color when the boss is below 20% health.") - @ConfigEditorBoolean - @FeatureToggle - public boolean changeColorWhenCanSteak = true; - - @Expose - @ConfigOption(name = "Can use Steak Color", desc = "Color when the boss is below 20% health.") - @ConfigEditorColour - public String steakColor = "0:255:255:0:88"; - - @Expose - @ConfigOption(name = "Twinclaws", desc = "Delay the sound and title of Twinclaws alert for a given amount in milliseconds.") - @ConfigEditorSlider(minStep = 1, minValue = 0, maxValue = 1000) - public int twinclawsDelay = 0; - - @Expose - @ConfigOption(name = "Draw Line", desc = "Draw a line starting at your crosshair to the boss head.") - @ConfigEditorBoolean - @FeatureToggle - public boolean drawLine = false; - - @Expose - @ConfigOption(name = "Line Color", desc = "Color of the line.") - @ConfigEditorColour - public String lineColor = "0:255:255:0:88"; - - @Expose - @ConfigOption(name = "Line Width", desc = "Width of the line.") - @ConfigEditorSlider(minStep = 1, minValue = 1, maxValue = 10) - public int lineWidth = 1; - - - @Expose - @ConfigOption(name = "Blood Ichor", desc = "") - @Accordion - public BloodIchorConfig bloodIchor = new BloodIchorConfig(); - - public static class BloodIchorConfig { - @Expose - @ConfigOption(name = "Highlight Blood Ichor", desc = "Highlight the Blood Ichor.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlight = false; - - @Expose - @ConfigOption(name = "Beacon Beam", desc = "Render a beacon beam where the Blood Ichor is.") - @ConfigEditorBoolean - @FeatureToggle - public boolean renderBeam = true; - - @Expose - @ConfigOption(name = "Color", desc = "Highlight color.") - @ConfigEditorColour - public String color = "0:199:100:0:88"; - - @Expose - @ConfigOption(name = "Show Lines", desc = "Draw lines that start from the head of the boss and end on the Blood Ichor.") - @ConfigEditorBoolean - @FeatureToggle - public boolean showLines = false; - - @Expose - @ConfigOption(name = "Lines Start Color", desc = "Starting color of the lines.") - @ConfigEditorColour - public String linesColor = "0:255:255:13:0"; - - } - - @Expose - @ConfigOption(name = "Killer Spring", desc = "") - @Accordion - public KillerSpringConfig killerSpring = new KillerSpringConfig(); - - public static class KillerSpringConfig { - @Expose - @ConfigOption(name = "Highlight Killer Spring", desc = "Highlight the Killer Spring tower.") - @ConfigEditorBoolean - @FeatureToggle - public boolean highlight = false; - - @Expose - @ConfigOption(name = "Color", desc = "Highlight color.") - @ConfigEditorColour - public String color = "0:199:100:0:88"; - - @Expose - @ConfigOption(name = "Show Lines", desc = "Draw lines that start from the head of the boss and end on the Killer Spring tower.") - @ConfigEditorBoolean - @FeatureToggle - public boolean showLines = false; - - @Expose - @ConfigOption(name = "Lines Start Color", desc = "Starting color of the lines.") - @ConfigEditorColour - public String linesColor = "0:255:255:13:0"; - } - } - - @Expose - @ConfigOption(name = "Item Profit Tracker", desc = "") - @Accordion - public ItemProfitTrackerConfig itemProfitTracker = new ItemProfitTrackerConfig(); - - public static class ItemProfitTrackerConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Count all items you pick up while doing slayer, " + - "keep track of how much you pay for starting slayers and calculating the overall profit.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - public Position pos = new Position(20, 20, false, true); - - @Expose - @ConfigOption(name = "Price in Chat", desc = "Show an extra chat message when you pick up an item. " + - "(This contains name, amount and price)") - @ConfigEditorBoolean - @FeatureToggle - public boolean priceInChat = false; - - @Expose - @ConfigOption(name = "Show Price From", desc = "Show price from Bazaar or NPC.") - @ConfigEditorDropdown(values = {"Instant Sell", "Sell Offer", "NPC"}) - public int priceFrom = 1; - - @Expose - @ConfigOption(name = "Minimum Price", desc = "Items below this price will not show up in chat.") - @ConfigEditorSlider(minValue = 1, maxValue = 5_000_000, minStep = 1) - public int minimumPrice = 100_000; - - @Expose - @ConfigOption(name = "Title Warning", desc = "Show a title for expensive item pickups.") - @ConfigEditorBoolean - @FeatureToggle - public boolean titleWarning = false; - - @Expose - @ConfigOption(name = "Title Price", desc = "Items above this price will show up as a title.") - @ConfigEditorSlider(minValue = 1, maxValue = 20_000_000, minStep = 1) - public int minimumPriceWarning = 500_000; - } - - @Expose - @ConfigOption(name = "Items on Ground", desc = "") - @Accordion - public ItemsOnGroundConfig itemsOnGround = new ItemsOnGroundConfig(); - - public static class ItemsOnGroundConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Show the name and price of items laying on the ground. §cOnly in slayer areas!") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Minimum Price", desc = "Items below this price will be ignored.") - @ConfigEditorSlider(minValue = 1, maxValue = 1_000_000, minStep = 1) - public int minimumPrice = 50_000; - } - - @Expose - @ConfigOption(name = "RNG Meter Display", desc = "") - @Accordion - public RngMeterDisplayConfig rngMeterDisplay = new RngMeterDisplayConfig(); - - public static class RngMeterDisplayConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Display amount of bosses needed until next RNG meter drop.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = true; - - @Expose - @ConfigOption(name = "Warn Empty", desc = "Warn when no item is set in the RNG Meter.") - @ConfigEditorBoolean - public boolean warnEmpty = false; - - @Expose - @ConfigOption(name = "Hide Chat", desc = "Hide the RNG meter message from chat if current item is selected.") - @ConfigEditorBoolean - public boolean hideChat = true; - - @Expose - public Position pos = new Position(410, 110, false, true); - - } - - @Expose - @ConfigOption(name = "Boss Spawn Warning", desc = "") - @Accordion - public SlayerBossWarningConfig slayerBossWarning = new SlayerBossWarningConfig(); - - public static class SlayerBossWarningConfig { - - @Expose - @ConfigOption(name = "Enabled", desc = "Send a title when your boss is about to spawn.") - @ConfigEditorBoolean - @FeatureToggle - public boolean enabled = false; - - @Expose - @ConfigOption(name = "Percent", desc = "The percentage at which the title and sound should be sent.") - @ConfigEditorSlider(minStep = 1, minValue = 50, maxValue = 90) - public int percent = 80; - - @Expose - @ConfigOption(name = "Repeat", desc = "Resend the title and sound on every kill after reaching the configured percent value.") - @ConfigEditorBoolean - public boolean repeat = false; - } - - @Expose - @ConfigOption(name = "Miniboss Highlight", desc = "Highlight Slayer Mini-Boss in blue color.") - @ConfigEditorBoolean - @FeatureToggle - public boolean slayerMinibossHighlight = false; - - @Expose - @ConfigOption(name = "Line to Miniboss", desc = "Adds a line to every Slayer Mini-Boss around you.") - @ConfigEditorBoolean - @FeatureToggle - public boolean slayerMinibossLine = false; - - @Expose - @ConfigOption(name = "Hide Mob Names", desc = "Hide the name of the mobs you need to kill in order for the Slayer boss to spawn. Exclude mobs that are damaged, corrupted, runic or semi rare.") - @ConfigEditorBoolean - @FeatureToggle - public boolean hideMobNames = false; - - @Expose - @ConfigOption(name = "Quest Warning", desc = "Warning when wrong Slayer quest is selected, or killing mobs for the wrong Slayer.") - @ConfigEditorBoolean - @FeatureToggle - public boolean questWarning = true; - - @Expose - @ConfigOption(name = "Quest Warning Title", desc = "Sends a title when warning.") - @ConfigEditorBoolean - @FeatureToggle - public boolean questWarningTitle = true; -} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/BazaarConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/bazaar/BazaarConfig.java similarity index 96% rename from src/main/java/at/hannibal2/skyhanni/config/features/BazaarConfig.java rename to src/main/java/at/hannibal2/skyhanni/config/features/bazaar/BazaarConfig.java index b02c0ef40d30..515255e4b8fd 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/features/BazaarConfig.java +++ b/src/main/java/at/hannibal2/skyhanni/config/features/bazaar/BazaarConfig.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.config.features; +package at.hannibal2.skyhanni.config.features.bazaar; import at.hannibal2.skyhanni.config.FeatureToggle; import at.hannibal2.skyhanni.config.core.config.Position; diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/chat/ChatConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/chat/ChatConfig.java new file mode 100644 index 000000000000..09df4f5e783e --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/chat/ChatConfig.java @@ -0,0 +1,91 @@ +package at.hannibal2.skyhanni.config.features.chat; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +public class ChatConfig { + + @Expose + @ConfigOption(name = "Peek Chat", desc = "Hold this key to keep the chat open.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_Z) + public int peekChat = Keyboard.KEY_Z; + + @Expose + @ConfigOption(name = "Chat Filter Types", desc = "") + @Accordion + public FilterTypesConfig filterType = new FilterTypesConfig(); + + + @Expose + @ConfigOption(name = "Player Messages", desc = "") + @Accordion + public PlayerMessagesConfig playerMessage = new PlayerMessagesConfig(); + + @Expose + @ConfigOption(name = "Player Chat Symbols", desc = "") + @Accordion + public ChatSymbols chatSymbols = new ChatSymbols(); + + @Expose + @ConfigOption(name = "Dungeon Filter", desc = "Hide annoying messages in Dungeons.") + @ConfigEditorBoolean + @FeatureToggle + public boolean dungeonMessages = true; + + @Expose + @ConfigOption(name = "Dungeon Boss Messages", desc = "Hide messages from the Watcher and bosses in the Dungeon.") + @ConfigEditorBoolean + @FeatureToggle + public boolean dungeonBossMessages = false; + + @Expose + @ConfigOption(name = "Hide Far Deaths", desc = "Hide other players' death messages, " + + "except for players who are nearby or during Dungeons/a Kuudra fight.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideFarDeathMessages = false; + //TODO jawbus + thunder + + @Expose + @ConfigOption(name = "Compact Potion Messages", desc = "") + @Accordion + public CompactPotionConfig compactPotionMessages = new CompactPotionConfig(); + + @Expose + @ConfigOption(name = "Compact Bestiary Message", desc = "Shorten the Bestiary level up message, showing additional information when hovering.") + @ConfigEditorBoolean + @FeatureToggle + public boolean compactBestiaryMessage = true; + + @Expose + @ConfigOption(name = "Arachne Hider", desc = "Hide chat messages about the Arachne Fight while outside of §eArachne's Sanctuary§7.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideArachneMessages = false; + + @Expose + @ConfigOption( + name = "Sacks Hider", + desc = "Hide the chat's sack change message with this, " + + "not in Hypixel settings, for mods to access sack data in new features." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean hideSacksChange = false; + + @Expose + @ConfigOption( + name = "Translator", + desc = "Click on a message to translate it into English. " + + "Use §e/shcopytranslation§7 to get the translation from English. " + + "§cTranslation is not guaranteed to be 100% accurate." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean translator = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/chat/ChatSymbols.java b/src/main/java/at/hannibal2/skyhanni/config/features/chat/ChatSymbols.java new file mode 100644 index 000000000000..c8ea29aeef29 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/chat/ChatSymbols.java @@ -0,0 +1,24 @@ +package at.hannibal2.skyhanni.config.features.chat; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ChatSymbols { + + @Expose + @ConfigOption(name = "Enabled", desc = "Adds extra symbols to the chat such as those from ironman, " + + "stranded, bingo or nether factions and places them next to your regular player emblems. " + + "§cDoes not work with hide rank hider!") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Chat Symbol Location", desc = "Determines where the symbols should go in chat in relation to the " + + "player's name. Hidden will hide all emblems from the chat. §eRequires above setting to be on to hide the symbols.") + @ConfigEditorDropdown(values = {"Left", "Right", "Hidden"}) + public int symbolLocation = 0; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/chat/CompactPotionConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/chat/CompactPotionConfig.java new file mode 100644 index 000000000000..c06244b90e30 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/chat/CompactPotionConfig.java @@ -0,0 +1,20 @@ +package at.hannibal2.skyhanni.config.features.chat; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class CompactPotionConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Shorten chat messages about player potion effects.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Clickable Chat Message", desc = "Makes the Compact Potion message open the Potion effects menu on click.") + @ConfigEditorBoolean + public boolean clickableChatMessage = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/chat/FilterTypesConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/chat/FilterTypesConfig.java new file mode 100644 index 000000000000..f37e6670590d --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/chat/FilterTypesConfig.java @@ -0,0 +1,89 @@ +package at.hannibal2.skyhanni.config.features.chat; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class FilterTypesConfig { + + @Expose + @ConfigOption(name = "Hypixel Hub", desc = "Block messages outside SkyBlock in the Hypixel lobby: player joins, loot boxes, prototype lobby messages, radiating generosity and Hypixel tournaments.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hypixelHub = true; + + @Expose + @ConfigOption(name = "Empty", desc = "Hide all the empty messages from the chat.") + @ConfigEditorBoolean + @FeatureToggle + public boolean empty = true; + + @Expose + @ConfigOption(name = "Warping", desc = "Block 'Sending request to join...' and 'Warping...' messages.") + @ConfigEditorBoolean + @FeatureToggle + public boolean warping = true; + + @Expose + @ConfigOption(name = "Welcome", desc = "Hide the 'Welcome to SkyBlock' message.") + @ConfigEditorBoolean + @FeatureToggle + public boolean welcome = true; + + @Expose + @ConfigOption(name = "Guild Exp", desc = "Hide Guild EXP messages.") + @ConfigEditorBoolean + @FeatureToggle + public boolean guildExp = true; + + @Expose + @ConfigOption(name = "Friend Join Left", desc = "Hide friend join/left messages.") + @ConfigEditorBoolean + @FeatureToggle + public boolean friendJoinLeft = false; + + @Expose + @ConfigOption(name = "Winter Gifts", desc = "Hide useless Winter Gift messages.") + @ConfigEditorBoolean + @FeatureToggle + public boolean winterGift = false; + + @Expose + @ConfigOption(name = "Powder Mining", desc = "Hide messages while opening chests in the Crystal Hollows. " + + "(Except powder numbers over 1k, essence numbers over 2, Prehistoric Eggs, and Automaton Parts)") + @ConfigEditorBoolean + @FeatureToggle + public boolean powderMining = true; + + @Expose + @ConfigOption(name = "Kill Combo", desc = "Hide messages about the current Kill Combo from the Grandma Wolf Pet.") + @ConfigEditorBoolean + @FeatureToggle + public boolean killCombo = false; + + @Expose + @ConfigOption(name = "Watchdog", desc = "Hide the message where Hypixel is flexing how many players they have banned over the last week.") + @ConfigEditorBoolean + @FeatureToggle + public boolean watchDog = true; + + @Expose + @ConfigOption(name = "Profile Join", desc = "Hide 'You are playing on profile' and 'Profile ID' chat messages.") + @ConfigEditorBoolean + @FeatureToggle + public boolean profileJoin = true; + + @Expose + @ConfigOption(name = "Fire Sale", desc = "Hide the repeating fire sale reminder chat messages.") + @ConfigEditorBoolean + @FeatureToggle + public boolean fireSale = true; + + //TODO remove + @Expose + @ConfigOption(name = "Others", desc = "Hide other annoying messages.") + @ConfigEditorBoolean + @FeatureToggle + public boolean others = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/chat/PlayerMessagesConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/chat/PlayerMessagesConfig.java new file mode 100644 index 000000000000..93c22adabb48 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/chat/PlayerMessagesConfig.java @@ -0,0 +1,21 @@ +package at.hannibal2.skyhanni.config.features.chat; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class PlayerMessagesConfig { + + @Expose + @ConfigOption(name = "Player Rank Hider", desc = "Hide player ranks in all chat messages.") + @ConfigEditorBoolean + @FeatureToggle + public boolean playerRankHider = false; + + @Expose + @ConfigOption(name = "Chat Filter", desc = "Scan messages sent by players for blacklisted words and gray out the message if any are found.") + @ConfigEditorBoolean + @FeatureToggle + public boolean chatFilter = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/ChromaConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/chroma/ChromaConfig.java similarity index 98% rename from src/main/java/at/hannibal2/skyhanni/config/features/ChromaConfig.java rename to src/main/java/at/hannibal2/skyhanni/config/features/chroma/ChromaConfig.java index 80c40cd9843e..81e3b26df130 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/features/ChromaConfig.java +++ b/src/main/java/at/hannibal2/skyhanni/config/features/chroma/ChromaConfig.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.config.features; +package at.hannibal2.skyhanni.config.features.chroma; import at.hannibal2.skyhanni.SkyHanniMod; import at.hannibal2.skyhanni.config.FeatureToggle; diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/combat/BestiaryConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/combat/BestiaryConfig.java new file mode 100644 index 000000000000..97c41da3d389 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/combat/BestiaryConfig.java @@ -0,0 +1,48 @@ +package at.hannibal2.skyhanni.config.features.combat; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class BestiaryConfig { + @Expose + @ConfigOption(name = "Enable", desc = "Show Bestiary Data overlay in the Bestiary menu.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Number format", desc = "Short: 1.1k\nLong: 1.100") + @ConfigEditorDropdown(values = {"Short", "Long"}) + public int numberFormat = 0; + + @Expose + @ConfigOption(name = "Display type", desc = "Choose what the display should show") + @ConfigEditorDropdown(values = { + "Global to max", + "Global to next tier", + "Lowest total kills", + "Highest total kills", + "Lowest kills needed to max", + "Highest kills needed to max", + "Lowest kills needed to next tier", + "Highest kills needed to next tier" + }) + public int displayType = 0; + + @Expose + @ConfigOption(name = "Hide maxed", desc = "Hide maxed mobs.") + @ConfigEditorBoolean + public boolean hideMaxed = false; + + @Expose + @ConfigOption(name = "Replace Romans", desc = "Replace Roman numerals (IX) with regular numbers (9)") + @ConfigEditorBoolean + public boolean replaceRoman = false; + + @Expose + public Position position = new Position(100, 100, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/combat/CombatConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/combat/CombatConfig.java new file mode 100644 index 000000000000..94780f9dda15 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/combat/CombatConfig.java @@ -0,0 +1,47 @@ +package at.hannibal2.skyhanni.config.features.combat; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.features.combat.damageindicator.DamageIndicatorConfig; +import at.hannibal2.skyhanni.config.features.combat.ghostcounter.GhostCounterConfig; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.Category; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class CombatConfig { + + @Expose + @Category(name = "Damage Indicator", desc = "Damage Indicator settings") + public DamageIndicatorConfig damageIndicator = new DamageIndicatorConfig(); + + @Expose + @Category(name = "Ghost Counter", desc = "Ghost counter settings") + public GhostCounterConfig ghostCounter = new GhostCounterConfig(); + + @Expose + @ConfigOption(name = "Summonings", desc = "") + @Accordion + public SummoningsConfig summonings = new SummoningsConfig(); + + @Expose + @ConfigOption(name = "Mobs", desc = "") + @Accordion + public MobsConfig mobs = new MobsConfig(); + + @Expose + @ConfigOption(name = "Bestiary", desc = "") + @Accordion + public BestiaryConfig bestiary = new BestiaryConfig(); + + @Expose + @ConfigOption(name = "Ender Node Tracker", desc = "") + @Accordion + public EnderNodeConfig enderNodeTracker = new EnderNodeConfig(); + + @Expose + @ConfigOption(name = "Hide Damage Splash", desc = "Hide all damage splashes anywhere in SkyBlock.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideDamageSplash = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/combat/EnderNodeConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/combat/EnderNodeConfig.java new file mode 100644 index 000000000000..37f6cdfb8d3b --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/combat/EnderNodeConfig.java @@ -0,0 +1,122 @@ +package at.hannibal2.skyhanni.config.features.combat; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.HasLegacyId; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import io.github.moulberry.moulconfig.observer.Property; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import static at.hannibal2.skyhanni.config.features.combat.EnderNodeConfig.EnderNodeDisplayEntry.COINS_MADE; +import static at.hannibal2.skyhanni.config.features.combat.EnderNodeConfig.EnderNodeDisplayEntry.ENCHANTED_ENDER_PEARL; +import static at.hannibal2.skyhanni.config.features.combat.EnderNodeConfig.EnderNodeDisplayEntry.ENCHANTED_END_STONE; +import static at.hannibal2.skyhanni.config.features.combat.EnderNodeConfig.EnderNodeDisplayEntry.ENCHANTED_OBSIDIAN; +import static at.hannibal2.skyhanni.config.features.combat.EnderNodeConfig.EnderNodeDisplayEntry.ENDERMAN_PET; +import static at.hannibal2.skyhanni.config.features.combat.EnderNodeConfig.EnderNodeDisplayEntry.ENDERMITE_NEST; +import static at.hannibal2.skyhanni.config.features.combat.EnderNodeConfig.EnderNodeDisplayEntry.ENDER_ARMOR; +import static at.hannibal2.skyhanni.config.features.combat.EnderNodeConfig.EnderNodeDisplayEntry.GRAND_XP_BOTTLE; +import static at.hannibal2.skyhanni.config.features.combat.EnderNodeConfig.EnderNodeDisplayEntry.MAGICAL_RUNE_I; +import static at.hannibal2.skyhanni.config.features.combat.EnderNodeConfig.EnderNodeDisplayEntry.MITE_GEL; +import static at.hannibal2.skyhanni.config.features.combat.EnderNodeConfig.EnderNodeDisplayEntry.NODES_MINED; +import static at.hannibal2.skyhanni.config.features.combat.EnderNodeConfig.EnderNodeDisplayEntry.SHRIMP_THE_FISH; +import static at.hannibal2.skyhanni.config.features.combat.EnderNodeConfig.EnderNodeDisplayEntry.SPACER_1; +import static at.hannibal2.skyhanni.config.features.combat.EnderNodeConfig.EnderNodeDisplayEntry.SPACER_2; +import static at.hannibal2.skyhanni.config.features.combat.EnderNodeConfig.EnderNodeDisplayEntry.TITANIC_XP_BOTTLE; +import static at.hannibal2.skyhanni.config.features.combat.EnderNodeConfig.EnderNodeDisplayEntry.TITLE; + +public class EnderNodeConfig { + @Expose + @ConfigOption( + name = "Enabled", + desc = "Tracks all of your drops from mining Ender Nodes in the End.\n" + + "Also tracks drops from Endermen." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption( + name = "Text Format", + desc = "Drag text to change the appearance of the overlay." + ) + @ConfigEditorDraggableList() + public Property> textFormat = Property.of(new ArrayList<>(Arrays.asList( + TITLE, + NODES_MINED, + COINS_MADE, + SPACER_1, + ENDERMITE_NEST, + ENCHANTED_END_STONE, + ENCHANTED_OBSIDIAN, + ENCHANTED_ENDER_PEARL, + GRAND_XP_BOTTLE, + TITANIC_XP_BOTTLE, + MAGICAL_RUNE_I, + MITE_GEL, + SHRIMP_THE_FISH, + SPACER_2, + ENDER_ARMOR, + ENDERMAN_PET) + )); + + public enum EnderNodeDisplayEntry implements HasLegacyId { + TITLE("§5§lEnder Node Tracker", 0), + NODES_MINED("§d1,303 Ender Nodes Mined", 1), + COINS_MADE("§615.3M Coins Made", 2), + SPACER_1(" ", 3), + ENDERMITE_NEST("§b123 §cEndermite Nest", 4), + ENCHANTED_END_STONE("§b832 §aEnchanted End Stone", 5), + ENCHANTED_OBSIDIAN("§b230 §aEnchanted Obsidian", 6), + ENCHANTED_ENDER_PEARL("§b1630 §aEnchanted Ender Pearl", 7), + GRAND_XP_BOTTLE("§b85 §aGrand Experience Bottle", 8), + TITANIC_XP_BOTTLE("§b4 §9Titanic Experience Bottle", 9), + END_STONE_SHULKER("§b15 §9End Stone Shulker", 10), + END_STONE_GEODE("§b53 §9End Stone Geode", 11), + MAGICAL_RUNE_I("§b10 §d◆ Magical Rune I", 12), + ENDER_GAUNTLET("§b24 §5Ender Gauntlet", 13), + MITE_GEL("§b357 §5Mite Gel", 14), + SHRIMP_THE_FISH("§b2 §cShrimp The Fish", 15), + SPACER_2(" ", 16), + ENDER_ARMOR("§b200 §5Ender Armor", 17), + ENDER_HELMET("§b24 §5Ender Helmet", 18), + ENDER_CHESTPLATE("§b24 §5Ender Chestplate", 19), + ENDER_LEGGINGS("§b24 §5Ender Leggings", 20), + ENDER_BOOTS("§b24 §5Ender Boots", 21), + ENDER_NECKLACE("§b24 §5Ender Necklace", 22), + ENDERMAN_PET("§f10§7-§a8§7-§93§7-§52§7-§61 §fEnderman Pet", 23), + ; + + private final String str; + private final int legacyId; + + EnderNodeDisplayEntry(String str, int legacyId) { + this.str = str; + this.legacyId = legacyId; + } + + // Constructor if new enum elements are added post-migration + EnderNodeDisplayEntry(String str) { + this(str, -1); + } + + @Override + public int getLegacyId() { + return legacyId; + } + + @Override + public String toString() { + return str; + } + } + + @Expose + public Position position = new Position(10, 80, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/combat/MobsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/combat/MobsConfig.java new file mode 100644 index 000000000000..3514c6729464 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/combat/MobsConfig.java @@ -0,0 +1,85 @@ +package at.hannibal2.skyhanni.config.features.combat; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class MobsConfig { + @Expose + @ConfigOption(name = "Area Boss", desc = "Highlight Golden Ghoul, Old Wolf, Voidling Extremist and Millenia-Aged Blaze.") + @ConfigEditorBoolean + @FeatureToggle + public boolean areaBossHighlight = true; + + @Expose + @ConfigOption(name = "Arachne Keeper", desc = "Highlight the Arachne Keeper in the Spider's Den in purple color.") + @ConfigEditorBoolean + @FeatureToggle + public boolean arachneKeeperHighlight = true; + + @Expose + @ConfigOption(name = "Corleone", desc = "Highlight Boss Corleone in the Crystal Hollows.") + @ConfigEditorBoolean + @FeatureToggle + public boolean corleoneHighlighter = true; + + @Expose + @ConfigOption(name = "Zealot", desc = "Highlight Zealots and Bruisers in The End.") + @ConfigEditorBoolean + @FeatureToggle + public boolean zealotBruiserHighlighter = false; + + @Expose + @ConfigOption( + name = "Special Zealots", + desc = "Highlight Special Zealots (the ones that drop Summoning Eyes) in the End." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean specialZealotHighlighter = true; + + @Expose + @ConfigOption(name = "Corrupted Mob", desc = "Highlight corrupted mobs in purple color.") + @ConfigEditorBoolean + @FeatureToggle + public boolean corruptedMobHighlight = false; + + @Expose + @ConfigOption(name = "Arachne Boss", desc = "Highlight the Arachne boss in red and mini-bosses in orange.") + @ConfigEditorBoolean + @FeatureToggle + public boolean arachneBossHighlighter = true; + + @Expose + @ConfigOption( + name = "Area Boss", + desc = "Show a timer when Golden Ghoul, Old Wolf, Voidling Extremist or Millenia-Aged Blaze respawns. " + + "§cSometimes it takes 20-30 seconds to calibrate correctly." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean areaBossRespawnTimer = false; + + @Expose + @ConfigOption( + name = "Arachne Spawn Timer", + desc = "Show a timer when Arachne fragments or crystals are placed to indicate how long " + + "until the boss will spawn. §cTimer may be 1-2 seconds off." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean showArachneSpawnTimer = true; + + @Expose + @ConfigOption(name = "Enderman TP Hider", desc = "Stops the Enderman Teleportation animation.") + @ConfigEditorBoolean + @FeatureToggle + public boolean endermanTeleportationHider = true; + + @Expose + @ConfigOption(name = "Arachne Minis Hider", desc = "Hides the nametag above Arachne minis.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideNameTagArachneMinis = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/combat/SummoningsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/combat/SummoningsConfig.java new file mode 100644 index 000000000000..9abe2bf8dd25 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/combat/SummoningsConfig.java @@ -0,0 +1,38 @@ +package at.hannibal2.skyhanni.config.features.combat; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class SummoningsConfig { + + @Expose + @ConfigOption(name = "Summoning Soul Display", desc = "Show the name of dropped Summoning Souls laying on the ground. " + + "§cNot working in Dungeons if Skytils' 'Hide Non-Starred Mobs Nametags' feature is enabled!") + @ConfigEditorBoolean + @FeatureToggle + public boolean summoningSoulDisplay = false; + + @Expose + @ConfigOption(name = "Summoning Mob Display", desc = "Show the health of your spawned summons.") + @ConfigEditorBoolean + @FeatureToggle + public boolean summoningMobDisplay = false; + + @Expose + public Position summoningMobDisplayPos = new Position(10, 10, false, true); + + @Expose + @ConfigOption(name = "Summoning Mob Nametag", desc = "Hide the nametag of your spawned summons.") + @ConfigEditorBoolean + @FeatureToggle + public boolean summoningMobHideNametag = false; + + @Expose + @ConfigOption(name = "Summoning Mob Color", desc = "Marks own summons green.") + @ConfigEditorBoolean + @FeatureToggle + public boolean summoningMobColored = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/combat/damageindicator/DamageIndicatorConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/combat/damageindicator/DamageIndicatorConfig.java new file mode 100644 index 000000000000..6986d706cf99 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/combat/damageindicator/DamageIndicatorConfig.java @@ -0,0 +1,160 @@ +package at.hannibal2.skyhanni.config.features.combat.damageindicator; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.HasLegacyId; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import static at.hannibal2.skyhanni.config.features.combat.damageindicator.DamageIndicatorConfig.DamageIndicatorBossEntry.ARACHNE; +import static at.hannibal2.skyhanni.config.features.combat.damageindicator.DamageIndicatorConfig.DamageIndicatorBossEntry.DIANA_MOBS; +import static at.hannibal2.skyhanni.config.features.combat.damageindicator.DamageIndicatorConfig.DamageIndicatorBossEntry.DUNGEON_ALL; +import static at.hannibal2.skyhanni.config.features.combat.damageindicator.DamageIndicatorConfig.DamageIndicatorBossEntry.GARDEN_PESTS; +import static at.hannibal2.skyhanni.config.features.combat.damageindicator.DamageIndicatorConfig.DamageIndicatorBossEntry.INFERNO_DEMONLORD; +import static at.hannibal2.skyhanni.config.features.combat.damageindicator.DamageIndicatorConfig.DamageIndicatorBossEntry.NETHER_MINI_BOSSES; +import static at.hannibal2.skyhanni.config.features.combat.damageindicator.DamageIndicatorConfig.DamageIndicatorBossEntry.REINDRAKE; +import static at.hannibal2.skyhanni.config.features.combat.damageindicator.DamageIndicatorConfig.DamageIndicatorBossEntry.REVENANT_HORROR; +import static at.hannibal2.skyhanni.config.features.combat.damageindicator.DamageIndicatorConfig.DamageIndicatorBossEntry.RIFTSTALKER_BLOODFIEND; +import static at.hannibal2.skyhanni.config.features.combat.damageindicator.DamageIndicatorConfig.DamageIndicatorBossEntry.SEA_CREATURES; +import static at.hannibal2.skyhanni.config.features.combat.damageindicator.DamageIndicatorConfig.DamageIndicatorBossEntry.SVEN_PACKMASTER; +import static at.hannibal2.skyhanni.config.features.combat.damageindicator.DamageIndicatorConfig.DamageIndicatorBossEntry.TARANTULA_BROODFATHER; +import static at.hannibal2.skyhanni.config.features.combat.damageindicator.DamageIndicatorConfig.DamageIndicatorBossEntry.THE_RIFT_BOSSES; +import static at.hannibal2.skyhanni.config.features.combat.damageindicator.DamageIndicatorConfig.DamageIndicatorBossEntry.VANQUISHER; +import static at.hannibal2.skyhanni.config.features.combat.damageindicator.DamageIndicatorConfig.DamageIndicatorBossEntry.VOIDGLOOM_SERAPH; + +public class DamageIndicatorConfig { + + @Expose + @ConfigOption(name = "Damage Indicator Enabled", desc = "Show the boss' remaining health.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Healing Chat Message", desc = "Sends a chat message when a boss heals themself.") + @ConfigEditorBoolean + public boolean healingMessage = false; + + @Expose + @ConfigOption( + name = "Boss Name", + desc = "Change how the boss name should be displayed.") + @ConfigEditorDropdown(values = {"Hidden", "Full Name", "Short Name"}) + public int bossName = 1; + + @Expose + @ConfigOption( + name = "Select Boss", + desc = "Change what type of boss you want the damage indicator be enabled for." + ) + @ConfigEditorDraggableList() + //TODO only show currently working and tested features + public List bossesToShow = new ArrayList<>(Arrays.asList( + DUNGEON_ALL, + NETHER_MINI_BOSSES, + VANQUISHER, + REVENANT_HORROR, + TARANTULA_BROODFATHER, + SVEN_PACKMASTER, + VOIDGLOOM_SERAPH, + INFERNO_DEMONLORD, + DIANA_MOBS, + SEA_CREATURES, + ARACHNE, + THE_RIFT_BOSSES, + RIFTSTALKER_BLOODFIEND, + REINDRAKE, + GARDEN_PESTS + + )); + + public enum DamageIndicatorBossEntry implements HasLegacyId { + DUNGEON_ALL("§bDungeon All", 0), + NETHER_MINI_BOSSES("§bNether Mini Bosses", 1), + VANQUISHER("§bVanquisher", 2), + ENDERSTONE_PROTECTOR("§bEndstone Protector (not tested)", 3), + ENDER_DRAGON("§bEnder Dragon (not finished)", 4), + REVENANT_HORROR("§bRevenant Horror", 5), + TARANTULA_BROODFATHER("§bTarantula Broodfather", 6), + SVEN_PACKMASTER("§bSven Packmaster", 7), + VOIDGLOOM_SERAPH("§bVoidgloom Seraph", 8), + INFERNO_DEMONLORD("§bInferno Demonlord", 9), + HEADLESS_HORSEMAN("§bHeadless Horseman (bugged)", 10), + DUNGEON_FLOOR_1("§bDungeon Floor 1", 11), + DUNGEON_FLOOR_2("§bDungeon Floor 2", 12), + DUNGEON_FLOOR_3("§bDungeon Floor 3", 13), + DUNGEON_FLOOR_4("§bDungeon Floor 4", 14), + DUNGEON_FLOOR_5("§bDungeon Floor 5", 15), + DUNGEON_FLOOR_6("§bDungeon Floor 6", 16), + DUNGEON_FLOOR_7("§bDungeon Floor 7", 17), + DIANA_MOBS("§bDiana Mobs", 18), + SEA_CREATURES("§bSea Creatures", 19), + DUMMY("Dummy", 20), + ARACHNE("§bArachne", 21), + THE_RIFT_BOSSES("§bThe Rift Bosses", 22), + RIFTSTALKER_BLOODFIEND("§bRiftstalker Bloodfiend", 23), + REINDRAKE("§6Reindrake", 24), + GARDEN_PESTS("§aGarden Pests", 25), + ; + + private final String str; + private final int legacyId; + + DamageIndicatorBossEntry(String str, int legacyId) { + this.str = str; + this.legacyId = legacyId; + } + + // Constructor if new enum elements are added post-migration + DamageIndicatorBossEntry(String str) { + this(str, -1); + } + + @Override + public int getLegacyId() { + return legacyId; + } + + @Override + public String toString() { + return str; + } + } + @Expose + @ConfigOption(name = "Hide Damage Splash", desc = "Hiding damage splashes near the damage indicator.") + @ConfigEditorBoolean + public boolean hideDamageSplash = false; + + @Expose + @ConfigOption(name = "Damage Over Time", desc = "Show damage and health over time below the damage indicator.") + @ConfigEditorBoolean + public boolean showDamageOverTime = false; + + @Expose + @ConfigOption(name = "Hide Nametag", desc = "Hide the vanilla nametag of damage indicator bosses.") + @ConfigEditorBoolean + public boolean hideVanillaNametag = false; + + @Expose + @ConfigOption(name = "Time to Kill", desc = "Show the time it takes to kill the slayer boss.") + @ConfigEditorBoolean + public boolean timeToKillSlayer = true; + + + @Expose + @ConfigOption(name = "Ender Slayer", desc = "") + @Accordion + public EnderSlayerConfig enderSlayer = new EnderSlayerConfig(); + + @Expose + @ConfigOption(name = "Vampire Slayer", desc = "") + @Accordion + public VampireSlayerConfig vampireSlayer = new VampireSlayerConfig(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/combat/damageindicator/EnderSlayerConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/combat/damageindicator/EnderSlayerConfig.java new file mode 100644 index 000000000000..392505686e03 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/combat/damageindicator/EnderSlayerConfig.java @@ -0,0 +1,18 @@ +package at.hannibal2.skyhanni.config.features.combat.damageindicator; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class EnderSlayerConfig { + + @Expose + @ConfigOption(name = "Laser Phase Timer", desc = "Show a timer when the laser phase will end.") + @ConfigEditorBoolean + public boolean laserPhaseTimer = false; + + @Expose + @ConfigOption(name = "Health During Laser", desc = "Show the health of Voidgloom Seraph 4 during the laser phase.") + @ConfigEditorBoolean + public boolean showHealthDuringLaser = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/combat/damageindicator/VampireSlayerConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/combat/damageindicator/VampireSlayerConfig.java new file mode 100644 index 000000000000..ec1d07b9216b --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/combat/damageindicator/VampireSlayerConfig.java @@ -0,0 +1,23 @@ +package at.hannibal2.skyhanni.config.features.combat.damageindicator; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class VampireSlayerConfig { + + @Expose + @ConfigOption(name = "HP Until Steak", desc = "Show the amount of HP missing until the Steak can be used on the Vampire Slayer on top of the boss.") + @ConfigEditorBoolean + public boolean hpTillSteak = false; + + @Expose + @ConfigOption(name = "Mania Circles", desc = "Show a timer until the boss leaves the invincible Mania Circles state.") + @ConfigEditorBoolean + public boolean maniaCircles = false; + + @Expose + @ConfigOption(name = "Percentage HP", desc = "Show the percentage of HP next to the HP.") + @ConfigEditorBoolean + public boolean percentage = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/GhostCounterConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/GhostCounterConfig.java new file mode 100644 index 000000000000..6bc8ee48d658 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/GhostCounterConfig.java @@ -0,0 +1,141 @@ +package at.hannibal2.skyhanni.config.features.combat.ghostcounter; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.HasLegacyId; +import at.hannibal2.skyhanni.config.core.config.Position; +import at.hannibal2.skyhanni.config.features.combat.ghostcounter.textformatting.TextFormattingConfig; +import at.hannibal2.skyhanni.features.combat.ghostcounter.GhostUtil; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorButton; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import static at.hannibal2.skyhanni.config.features.combat.ghostcounter.GhostCounterConfig.GhostDisplayEntry.AVG_MAGIC_FIND; +import static at.hannibal2.skyhanni.config.features.combat.ghostcounter.GhostCounterConfig.GhostDisplayEntry.GHOSTS_KILLED; +import static at.hannibal2.skyhanni.config.features.combat.ghostcounter.GhostCounterConfig.GhostDisplayEntry.GHOST_PER_SORROW; +import static at.hannibal2.skyhanni.config.features.combat.ghostcounter.GhostCounterConfig.GhostDisplayEntry.GHOST_SINCE_SORROW; +import static at.hannibal2.skyhanni.config.features.combat.ghostcounter.GhostCounterConfig.GhostDisplayEntry.HIGHEST_KILL_COMBO; +import static at.hannibal2.skyhanni.config.features.combat.ghostcounter.GhostCounterConfig.GhostDisplayEntry.KILL_COMBO; +import static at.hannibal2.skyhanni.config.features.combat.ghostcounter.GhostCounterConfig.GhostDisplayEntry.SCAVENGER_COINS; +import static at.hannibal2.skyhanni.config.features.combat.ghostcounter.GhostCounterConfig.GhostDisplayEntry.SORROW; +import static at.hannibal2.skyhanni.config.features.combat.ghostcounter.GhostCounterConfig.GhostDisplayEntry.TITLE; + +public class GhostCounterConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Enable the ghost counter (invisible creepers in the Dwarven Mines The Mist area).") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption( + name = "Display Text", + desc = "Drag text to change the appearance of the overlay." + ) + @ConfigEditorDraggableList() + public List ghostDisplayText = new ArrayList<>(Arrays.asList( + TITLE, + GHOSTS_KILLED, + SORROW, + GHOST_SINCE_SORROW, + GHOST_PER_SORROW, + AVG_MAGIC_FIND, + SCAVENGER_COINS, + KILL_COMBO, + HIGHEST_KILL_COMBO + )); + + public enum GhostDisplayEntry implements HasLegacyId { + TITLE("§6Ghosts Counter", 0), + GHOSTS_KILLED(" §bGhost Killed: 42", 1), + SORROW(" §bSorrow: 6", 2), + GHOST_SINCE_SORROW(" §bGhost since Sorrow: 1", 3), + GHOST_PER_SORROW(" §bGhosts/Sorrow: 5", 4), + VOLTA(" §bVolta: 6", 5), + PLASMA(" §bPlasma: 8", 6), + GHOSTLY_BOOTS(" §bGhostly Boots: 1", 7), + BAG_OF_CASH(" §bBag Of Cash: 4", 8), + AVG_MAGIC_FIND(" §bAvg Magic Find: 271", 9), + SCAVENGER_COINS(" §bScavenger Coins: 15,000", 10), + KILL_COMBO(" §bKill Combo: 14", 11), + HIGHEST_KILL_COMBO(" §bHighest Kill Combo: 96", 12), + SKILL_XP_GAINED(" §bSkill XP Gained: 145,648", 13), + BESTIARY(" §bBestiary 1: 0/10", 14), + XP_PER_HOUR(" §bXP/h: 810,410", 15), + KILLS_PER_HOUR(" §bKills/h: 420", 16), + ETA(" §bETA: 14d", 17), + MONEY_PER_HOUR(" §bMoney/h: 13,420,069", 18), + MONEY_MADE(" §bMoney made: 14B", 19), + ; + + private final String str; + private final int legacyId; + + GhostDisplayEntry(String str, int legacyId) { + this.str = str; + this.legacyId = legacyId; + } + + // Constructor if new enum elements are added post-migration + GhostDisplayEntry(String str) { + this(str, -1); + } + + @Override + public int getLegacyId() { + return legacyId; + } + + @Override + public String toString() { + return str; + } + } + + @ConfigOption(name = "Text Formatting", desc = "") + @Accordion + @Expose + public TextFormattingConfig textFormatting = new TextFormattingConfig(); + + @Expose + @ConfigOption(name = "Extra space", desc = "Space between each line of text.") + @ConfigEditorSlider( + minValue = -5, + maxValue = 10, + minStep = 1) + public int extraSpace = 1; + + @Expose + @ConfigOption(name = "Pause Timer", desc = "How many seconds does it wait before pausing.") + @ConfigEditorSlider( + minValue = 1, + maxValue = 20, + minStep = 1 + ) + public int pauseTimer = 3; + + @Expose + @ConfigOption(name = "Show only in The Mist", desc = "Show the overlay only when you are in The Mist.") + @ConfigEditorBoolean + public boolean onlyOnMist = true; + + @Expose + @ConfigOption(name = "Maxed Bestiary", desc = "Show progress to max bestiary instead of next level.") + @ConfigEditorBoolean + public boolean showMax = false; + + @ConfigOption(name = "Reset", desc = "Reset the counter.") + @ConfigEditorButton(buttonText = "Reset") + public Runnable resetCounter = GhostUtil.INSTANCE::reset; + + @Expose + public Position position = new Position(50, 50, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/textformatting/BestiaryFormattingConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/textformatting/BestiaryFormattingConfig.java new file mode 100644 index 000000000000..c41b23fe128a --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/textformatting/BestiaryFormattingConfig.java @@ -0,0 +1,41 @@ +package at.hannibal2.skyhanni.config.features.combat.ghostcounter.textformatting; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorText; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class BestiaryFormattingConfig { + + @Expose + @ConfigOption(name = "Bestiary", desc = "Bestiary Progress line.\n§e%value% §7is replaced with\n" + + "Your current progress to next level.\n" + + "§e%currentLevel% &7is replaced with your current bestiary level\n" + + "§e%nextLevel% §7is replaced with your current bestiary level +1.\n" + + "§e%value% §7is replaced with one of the text below.") + @ConfigEditorText + public String base = " &6Bestiary %display%: &b%value%"; + + @Expose + @ConfigOption(name = "No Data", desc = "Text to show when you need to open the\nBestiary Menu to gather data.") + @ConfigEditorText + public String openMenu = "§cOpen Bestiary Menu !"; + + @Expose + @ConfigOption(name = "Maxed", desc = "Text to show when your bestiary for ghost is at max level.\n" + + "§e%currentKill% §7is replaced with your current total kill.") + @ConfigEditorText + public String maxed = "%currentKill% (&c&lMaxed!)"; + + @Expose + @ConfigOption(name = "Progress to Max", desc = "Text to show progress when the §eMaxed Bestiary §7option is §aON\n" + + "§e%currentKill% §7is replaced with your current total kill.") + @ConfigEditorText + public String showMax_progress = "%currentKill%/250k (%percentNumber%%)"; + + @Expose + @ConfigOption(name = "Progress", desc = "Text to show progress when the §eMaxed Bestiary§7 option is §cOFF\n" + + "§e%currentKill% §7is replaced with how many kill you have to the next level.\n" + + "§e%killNeeded% §7is replaced with how many kill you need to reach the next level.") + @ConfigEditorText + public String progress = "%currentKill%/%killNeeded%"; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/textformatting/ETAFormattingConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/textformatting/ETAFormattingConfig.java new file mode 100644 index 000000000000..146b56811ae7 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/textformatting/ETAFormattingConfig.java @@ -0,0 +1,42 @@ +package at.hannibal2.skyhanni.config.features.combat.ghostcounter.textformatting; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorText; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ETAFormattingConfig { + @Expose + @ConfigOption(name = "ETA to next level", desc = "ETA To Next Level Line.\n" + + "§e%value% §7is replaced with one of the text below.") + @ConfigEditorText + public String base = " &6ETA: &b%value%"; + + @Expose + @ConfigOption(name = "Maxed!", desc = "So you really maxed ghost bestiary ?") + @ConfigEditorText + public String maxed = "&c&lMAXED!"; + + @Expose + @ConfigOption(name = "No Data", desc = "Start killing some ghosts !") + @ConfigEditorText + public String noData = "&bN/A"; + + @Expose + @ConfigOption(name = "Progress", desc = "Text to show progress to next level.") + @ConfigEditorText + public String progress = "&b%value%"; + + @Expose + @ConfigOption(name = "Paused", desc = "Text displayed next to the time \n" + + "when you are doing nothing for a given amount of seconds") + @ConfigEditorText + public String paused = "&c(PAUSED)"; + + @Expose + @ConfigOption(name = "Time", desc = "§e%days% §7is replaced with days remaining.\n" + + "§e%hours% §7is replaced with hours remaining.\n" + + "§e%minutes% §7is replaced with minutes remaining.\n" + + "§e%seconds% §7is replaced with seconds remaining.") + @ConfigEditorText + public String time = "&6%days%%hours%%minutes%%seconds%"; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/textformatting/KillHourFormattingConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/textformatting/KillHourFormattingConfig.java new file mode 100644 index 000000000000..41cf0dcddf59 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/textformatting/KillHourFormattingConfig.java @@ -0,0 +1,24 @@ +package at.hannibal2.skyhanni.config.features.combat.ghostcounter.textformatting; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorText; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class KillHourFormattingConfig { + @Expose + @ConfigOption(name = "Kill/h", desc = "Kill Per Hour line.\n§e%value% §7is replaced with\nEstimated kills per hour you get.") + @ConfigEditorText + public String base = " &6Kill/h: &b%value%"; + + @Expose + @ConfigOption(name = "No Data", desc = "Start killing some ghosts !") + @ConfigEditorText + public String noData = "&bN/A"; + + @Expose + @ConfigOption(name = "Paused", desc = "Text displayed next to the time \n" + + "when you are doing nothing for a given amount of seconds") + @ConfigEditorText + public String paused = "&c(PAUSED)"; +} + diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/textformatting/TextFormattingConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/textformatting/TextFormattingConfig.java new file mode 100644 index 000000000000..1414a986dae1 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/textformatting/TextFormattingConfig.java @@ -0,0 +1,148 @@ +package at.hannibal2.skyhanni.config.features.combat.ghostcounter.textformatting; + +import at.hannibal2.skyhanni.features.combat.ghostcounter.GhostFormatting; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorButton; +import io.github.moulberry.moulconfig.annotations.ConfigEditorInfoText; +import io.github.moulberry.moulconfig.annotations.ConfigEditorText; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class TextFormattingConfig { + + @ConfigOption(name = "§eText Formatting Info", desc = "§e%session% §ris §e§lalways §rreplaced with\n" + + "§7the count for your current session.\n" + + "§7Reset when restarting the game.\n" + + "§7You can use §e&Z §7color code to use SBA chroma.") + @ConfigEditorInfoText + public boolean formatInfo = false; + + @ConfigOption(name = "Reset Formatting", desc = "Reset formatting to default text.") + @ConfigEditorButton(buttonText = "Reset") + public Runnable resetFormatting = GhostFormatting.INSTANCE::reset; + + @ConfigOption(name = "Export Formatting", desc = "Export current formatting to clipboard.") + @ConfigEditorButton(buttonText = "Export") + public Runnable exportFormatting = GhostFormatting.INSTANCE::export; + + @ConfigOption(name = "Import Formatting", desc = "Import formatting from clipboard.") + @ConfigEditorButton(buttonText = "Import") + public Runnable importFormatting = GhostFormatting.INSTANCE::importFormat; + + @Expose + @ConfigOption(name = "Title", desc = "Title Line.") + @ConfigEditorText + public String titleFormat = "&6Ghost Counter"; + + @Expose + @ConfigOption(name = "Ghosts Killed", desc = "Ghosts Killed line.\n§e%value% §ris replaced with\n" + + "Ghosts Killed.\n" + + "§e%session% §7is replaced with Ghosts killed") + @ConfigEditorText + public String ghostKilledFormat = " &6Ghosts Killed: &b%value% &7(%session%)"; + + @Expose + @ConfigOption(name = "Sorrows", desc = "Sorrows drop line.\n" + + "§e%value% §7is replaced with\nsorrows dropped.") + @ConfigEditorText + public String sorrowsFormat = " &6Sorrow: &b%value% &7(%session%)"; + + @Expose + @ConfigOption(name = "Ghost Since Sorrow", desc = "Ghost Since Sorrow line.\n" + + "§e%value% §7is replaced with\nGhost since last sorrow drop.") + @ConfigEditorText + public String ghostSinceSorrowFormat = " &6Ghost since Sorrow: &b%value%"; + + @Expose + @ConfigOption(name = "Ghost Kill Per Sorrow", desc = "Ghost Kill Per Sorrow line.\n" + + "§e%value% §7is replaced with\naverage ghost kill per sorrow drop.") + @ConfigEditorText + public String ghostKillPerSorrowFormat = " &6Ghosts/Sorrow: &b%value%"; + + @Expose + @ConfigOption(name = "Voltas", desc = "Voltas drop line.\n" + + "§e%value% §7is replaced with\nvoltas dropped.") + @ConfigEditorText + public String voltasFormat = " &6Voltas: &b%value% &7(%session%)"; + + @Expose + @ConfigOption(name = "Plasmas", desc = "Plasmas drop line.\n" + + "§e%value% §7is replaced with\nplasmas dropped.") + @ConfigEditorText + public String plasmasFormat = " &6Plasmas: &b%value% &7(%session%)"; + + @Expose + @ConfigOption(name = "Ghostly Boots", desc = "Ghostly Boots drop line.\n" + + "§e%value% §7is replaced with\nGhostly Boots dropped.") + @ConfigEditorText + public String ghostlyBootsFormat = " &6Ghostly Boots: &b%value% &7(%session%)"; + + @Expose + @ConfigOption(name = "Bag Of Cash", desc = "Bag Of Cash drop line.\n" + + "§e%value% §7is replaced with\nBag Of Cash dropped.") + @ConfigEditorText + public String bagOfCashFormat = " &6Bag Of Cash: &b%value% &7(%session%)"; + + @Expose + @ConfigOption(name = "Average Magic Find", desc = "Average Magic Find line.\n" + + "§e%value% §7is replaced with\nAverage Magic Find.") + @ConfigEditorText + public String avgMagicFindFormat = " &6Avg Magic Find: &b%value%"; + + @Expose + @ConfigOption(name = "Scavenger Coins", desc = "Scavenger Coins line.\n" + + "§e%value% §7is replaced with\nCoins earned from kill ghosts.\nInclude: Scavenger Enchant, Scavenger Talismans, Kill Combo.") + @ConfigEditorText + public String scavengerCoinsFormat = " &6Scavenger Coins: &b%value% &7(%session%)"; + + @Expose + @ConfigOption(name = "Kill Combo", desc = "Kill Combo line.\n" + + "§e%value% §7is replaced with\nYour current kill combo.") + @ConfigEditorText + public String killComboFormat = " &6Kill Combo: &b%value%"; + + @Expose + @ConfigOption(name = "Highest Kill Combo", desc = "Highest Kill Combo line.\n" + + "§e%value% §7is replaced with\nYour current highest kill combo.") + @ConfigEditorText + public String highestKillComboFormat = " &6Highest Kill Combo: &b%value% &7(%session%)"; + + @Expose + @ConfigOption(name = "Skill XP Gained", desc = "Skill XP Gained line.\n" + + "§e%value% §7is replaced with\nSkill XP Gained from killing Ghosts.") + @ConfigEditorText + public String skillXPGainFormat = " &6Skill XP Gained: &b%value% &7(%session%)"; + + @ConfigOption(name = "Bestiary Formatting", desc = "") + @Accordion + @Expose + public BestiaryFormattingConfig bestiaryFormatting = new BestiaryFormattingConfig(); + + @ConfigOption(name = "XP Per Hour Formatting", desc = "") + @Accordion + @Expose + public XPHourFormattingConfig xpHourFormatting = new XPHourFormattingConfig(); + + @ConfigOption(name = "ETA Formatting", desc = "") + @Accordion + @Expose + public ETAFormattingConfig etaFormatting = new ETAFormattingConfig(); + + @ConfigOption(name = "Kill Per Hour Formatting", desc = "") + @Expose + @Accordion + public KillHourFormattingConfig killHourFormatting = new KillHourFormattingConfig(); + + @Expose + @ConfigOption(name = "Money Per Hour", desc = "Money Per Hour.\n§e%value% §7is replaced with\nEstimated money you get per hour\n" + + "Calculated with your kill per hour and your average magic find.") + @ConfigEditorText + public String moneyHourFormat = " &6$/h: &b%value%"; + + @Expose + @ConfigOption(name = "Money made", desc = "Calculate the money you made.\nInclude §eSorrow§7, §ePlasma§7, §eVolta§7, §e1M coins drop\n" + + "§eGhostly Boots§7, §eScavenger coins.\n" + + "§cUsing current Sell Offer value.") + @ConfigEditorText + public String moneyMadeFormat = " &6Money made: &b%value%"; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/textformatting/XPHourFormattingConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/textformatting/XPHourFormattingConfig.java new file mode 100644 index 000000000000..d04f4942a0a9 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/combat/ghostcounter/textformatting/XPHourFormattingConfig.java @@ -0,0 +1,26 @@ +package at.hannibal2.skyhanni.config.features.combat.ghostcounter.textformatting; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorText; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class XPHourFormattingConfig { + + @Expose + @ConfigOption(name = "XP/h", desc = "XP Per Hour line.\n" + + "§e%value% §7is replaced with one of the text below.") + @ConfigEditorText + public String base = " &6XP/h: &b%value%"; + + @Expose + @ConfigOption(name = "No Data", desc = "XP Per Hour line.\n§e%value% §7is replaced with\nEstimated amount of combat xp you gain per hour.") + @ConfigEditorText + public String noData = "&bN/A"; + + @Expose + @ConfigOption(name = "Paused", desc = "Text displayed next to the time \n" + + "when you are doing nothing for a given amount of seconds") + @ConfigEditorText + public String paused = "&c(PAUSED)"; +} + diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/commands/CommandsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/commands/CommandsConfig.java new file mode 100644 index 000000000000..777d543a3148 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/commands/CommandsConfig.java @@ -0,0 +1,39 @@ +package at.hannibal2.skyhanni.config.features.commands; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class CommandsConfig { + + @ConfigOption(name = "Tab Complete", desc = "") + @Accordion + @Expose + public TabCompleteConfig tabComplete = new TabCompleteConfig(); + + @ConfigOption(name = "Fandom Wiki for §e/wiki", desc = "") + @Accordion + @Expose + public FandomWikiCommandConfig fandomWiki = new FandomWikiCommandConfig(); + + @ConfigOption(name = "Party Commands", desc = "Shortens party commands and allows tab-completing for them. " + + "\n§eCommands: /pt /pp /pko /pk §7SkyBlock command §e/pt §7to check the play time still works.") + @Expose + @ConfigEditorBoolean + @FeatureToggle + public boolean shortCommands = true; + + @Expose + @ConfigOption(name = "Replace Warp Is", desc = "Adds §e/warp is §7alongside §e/is§7. Idk why. Ask §cKaeso") + @ConfigEditorBoolean + @FeatureToggle + public boolean replaceWarpIs = false; + + @Expose + @ConfigOption(name = "/viewrecipe Lower Case", desc = "Adds support for lower case item IDs to the Hypixel command §e/viewrecipe§7.") + @ConfigEditorBoolean + @FeatureToggle + public boolean viewRecipeLowerCase = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/commands/FandomWikiCommandConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/commands/FandomWikiCommandConfig.java new file mode 100644 index 000000000000..c8a25a204668 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/commands/FandomWikiCommandConfig.java @@ -0,0 +1,27 @@ +package at.hannibal2.skyhanni.config.features.commands; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +public class FandomWikiCommandConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Use Fandom Wiki (§ehypixel-skyblock.fandom.com§7) instead of the Hypixel wiki (§ewiki.hypixel.net§7) in most wiki-related chat messages.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Skip Chat", desc = "Directly opens the Fandom Wiki instead of sending the §e\"Click to search for this thing on the Fandom Wiki\"§7 message beforehand.") + @ConfigEditorBoolean + public boolean skipWikiChat = false; + + @Expose + @ConfigOption(name = "Fandom Wiki Key", desc = "Search for an item on Fandom Wiki with this keybind.\n§4For optimal experiences, do §lNOT§r §4bind this to a mouse button.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int fandomWikiKeybind = Keyboard.KEY_NONE; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/commands/TabCompleteConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/commands/TabCompleteConfig.java new file mode 100644 index 000000000000..b7edd0e0779e --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/commands/TabCompleteConfig.java @@ -0,0 +1,62 @@ +package at.hannibal2.skyhanni.config.features.commands; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class TabCompleteConfig { + + @Expose + @ConfigOption(name = "Warps", desc = "Tab complete the warp-point names when typing §e/warp §7.") + @ConfigEditorBoolean + @FeatureToggle + public boolean warps = true; + + @Expose + @ConfigOption(name = "Island Players", desc = "Tab complete other players on the same island.") + @ConfigEditorBoolean + public boolean islandPlayers = true; + + @Expose + @ConfigOption(name = "Friends", desc = "Tab complete friends from your friends list.") + @ConfigEditorBoolean + @FeatureToggle + public boolean friends = true; + + @Expose + @ConfigOption(name = "Only Best Friends", desc = "Only Tab Complete best friends.") + @ConfigEditorBoolean + @FeatureToggle + public boolean onlyBestFriends = false; + + @Expose + @ConfigOption(name = "Party", desc = "Tab complete Party Members.") + @ConfigEditorBoolean + @FeatureToggle + public boolean party = true; + + @Expose + @ConfigOption(name = "VIP Visits", desc = "Tab complete the visit to special users with cake souls on it.") + @ConfigEditorBoolean + @FeatureToggle + public boolean vipVisits = true; + + @Expose + @ConfigOption(name = "/gfs Sack", desc = "Tab complete §e/gfs §7sack items.") + @ConfigEditorBoolean + @FeatureToggle + public boolean gfsSack = true; + + @Expose + @ConfigOption(name = "Party Commands", desc = "Tab complete commonly used party commands.") + @ConfigEditorBoolean + @FeatureToggle + public boolean partyCommands = true; + + @Expose + @ConfigOption(name = "View Recipe", desc = "Tab complete item IDs in the the Hypixel command §e/viewrecipe§7. Only items with recipes are tab completed.") + @ConfigEditorBoolean + @FeatureToggle + public boolean viewrecipeItems = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/CrimsonIsleConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/CrimsonIsleConfig.java new file mode 100644 index 000000000000..7dd530bc4e7f --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/CrimsonIsleConfig.java @@ -0,0 +1,34 @@ +package at.hannibal2.skyhanni.config.features.crimsonisle; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.features.crimsonisle.ashfang.AshfangConfig; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.Category; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class CrimsonIsleConfig { + + @Category(name = "Ashfang", desc = "Ashfang settings") + @Expose + public AshfangConfig ashfang = new AshfangConfig(); + + @ConfigOption(name = "Reputation Helper", desc = "") + @Accordion + @Expose + public ReputationHelperConfig reputationHelper = new ReputationHelperConfig(); + + @Expose + @ConfigOption(name = "Quest Item Helper", desc = "When you open the fetch item quest in the town board, " + + "it shows a clickable chat message that will grab the items needed from the sacks.") + @ConfigEditorBoolean + @FeatureToggle + public boolean questItemHelper = false; + + @Expose + @ConfigOption(name = "Pablo NPC Helper", desc = "Similar to Quest Item Helper, shows a clickable message that grabs the flower needed from sacks.") + @ConfigEditorBoolean + @FeatureToggle + public boolean pabloHelper = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/ReputationHelperConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/ReputationHelperConfig.java new file mode 100644 index 000000000000..cddce2228704 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/ReputationHelperConfig.java @@ -0,0 +1,38 @@ +package at.hannibal2.skyhanni.config.features.crimsonisle; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +public class ReputationHelperConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Enable features around Reputation features in the Crimson Isle.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Use Hotkey", desc = "Only show the Reputation Helper while pressing the hotkey.") + @ConfigEditorBoolean + public boolean useHotkey = false; + + @Expose + @ConfigOption(name = "Hotkey", desc = "Press this hotkey to show the Reputation Helper.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int hotkey = Keyboard.KEY_NONE; + + + @Expose + public Position position = new Position(10, 10, false, true); + + @Expose + @ConfigOption(name = "Show Locations", desc = "Crimson Isles waypoints for locations to get reputation.") + @ConfigEditorDropdown(values = {"Always", "Only With Hotkey", "Never"}) + public int showLocation = 1; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/ashfang/AshfangConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/ashfang/AshfangConfig.java new file mode 100644 index 000000000000..6e983e440d03 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/ashfang/AshfangConfig.java @@ -0,0 +1,50 @@ +package at.hannibal2.skyhanni.config.features.crimsonisle.ashfang; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class AshfangConfig { + + @ConfigOption(name = "Gravity Orbs", desc = "") + @Accordion + @Expose + public GravityOrbsConfig gravityOrbs = new GravityOrbsConfig(); + + @ConfigOption(name = "Blazing Souls", desc = "") + @Accordion + @Expose + public BlazingSoulsColor blazingSouls = new BlazingSoulsColor(); + + @ConfigOption(name = "Hide Stuff", desc = "") + @Accordion + @Expose + public HideAshfangConfig hide = new HideAshfangConfig(); + + @Expose + @ConfigOption(name = "Highlight Blazes", desc = "Highlight the different blazes in their respective colors.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightBlazes = false; + + @Expose + @ConfigOption(name = "Freeze Cooldown", desc = "Show the cooldown for how long Ashfang blocks your abilities.") + @ConfigEditorBoolean + @FeatureToggle + public boolean freezeCooldown = false; + + @Expose + public Position freezeCooldownPos = new Position(10, 10, false, true); + + @Expose + @ConfigOption(name = "Reset Time", desc = "Show the cooldown until Ashfang pulls his underlings back.") + @ConfigEditorBoolean + @FeatureToggle + public boolean nextResetCooldown = false; + + @Expose + public Position nextResetCooldownPos = new Position(10, 10, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/ashfang/BlazingSoulsColor.java b/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/ashfang/BlazingSoulsColor.java new file mode 100644 index 000000000000..6af0547d8f10 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/ashfang/BlazingSoulsColor.java @@ -0,0 +1,21 @@ +package at.hannibal2.skyhanni.config.features.crimsonisle.ashfang; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class BlazingSoulsColor { + + @Expose + @ConfigOption(name = "Enabled", desc = "Shows the Blazing Souls more clearly.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Souls Color", desc = "Color of the Blazing Souls.") + @ConfigEditorColour + public String color = "0:245:85:255:85"; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/ashfang/GravityOrbsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/ashfang/GravityOrbsConfig.java new file mode 100644 index 000000000000..a9e1fddf5f82 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/ashfang/GravityOrbsConfig.java @@ -0,0 +1,21 @@ +package at.hannibal2.skyhanni.config.features.crimsonisle.ashfang; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class GravityOrbsConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Shows the Gravity Orbs more clearly.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Color", desc = "Color of the Gravity Orbs.") + @ConfigEditorColour + public String color = "0:120:255:85:85"; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/ashfang/HideAshfangConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/ashfang/HideAshfangConfig.java new file mode 100644 index 000000000000..1160988e5fce --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/crimsonisle/ashfang/HideAshfangConfig.java @@ -0,0 +1,27 @@ +package at.hannibal2.skyhanni.config.features.crimsonisle.ashfang; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class HideAshfangConfig { + + @Expose + @ConfigOption(name = "Hide Particles", desc = "Hide particles around the Ashfang boss.") + @ConfigEditorBoolean + @FeatureToggle + public boolean particles = false; + + @Expose + @ConfigOption(name = "Hide Full Names", desc = "Hide the names of full health blazes around Ashfang (only useful when highlight blazes is enabled)") + @ConfigEditorBoolean + @FeatureToggle + public boolean fullNames = false; + + @Expose + @ConfigOption(name = "Hide Damage Splash", desc = "Hide damage splashes around Ashfang.") + @ConfigEditorBoolean + @FeatureToggle + public boolean damageSplash = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/dev/DebugConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/dev/DebugConfig.java new file mode 100644 index 000000000000..7f7b9af637d2 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/dev/DebugConfig.java @@ -0,0 +1,88 @@ +package at.hannibal2.skyhanni.config.features.dev; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +public class DebugConfig { + @Expose + @ConfigOption(name = "Enable Debug", desc = "Enable Test logic") + @ConfigEditorBoolean + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Command Logging", desc = "Logs stack trace information into the console when a command gets sent to Hypixel. (by any mod or the player)") + @ConfigEditorBoolean + public boolean commandLogs = false; + + @Expose + @ConfigOption( + name = "Mod Menu Log", + desc = "Enables debug messages when the currently opened GUI changes, with the path to the gui class. " + + "Useful for adding more mods to quick mod menu switch." + ) + @ConfigEditorBoolean + public boolean modMenuLog = false; + + @Expose + @ConfigOption(name = "Show Internal Name", desc = "Show internal names in item lore.") + @ConfigEditorBoolean + public boolean showInternalName = false; + + @Expose + @ConfigOption(name = "Show Empty Internal Names", desc = "Shows internal name even for items with none.") + @ConfigEditorBoolean + public boolean showEmptyNames = false; + + @Expose + @ConfigOption(name = "Show Item Rarity", desc = "Show item rarities in item lore.") + @ConfigEditorBoolean + public boolean showItemRarity = false; + + @Expose + @ConfigOption(name = "Copy Internal Name", desc = "Copies the internal name of an item on key press in the clipboard.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int copyInternalName = Keyboard.KEY_NONE; + + @Expose + @ConfigOption(name = "Show NPC Price", desc = "Show NPC price in item lore.") + @ConfigEditorBoolean + public boolean showNpcPrice = false; + + @Expose + @ConfigOption(name = "Show Item UUID", desc = "Show the Unique Identifier of items in the lore.") + @ConfigEditorBoolean + public boolean showItemUuid = false; + + @Expose + @ConfigOption(name = "Copy Item Data", desc = "Copies item NBT data on key press in a GUI to clipboard.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int copyItemData = Keyboard.KEY_NONE; + + @Expose + @ConfigOption(name = "Copy Compressed Item Data", desc = "Copies compressed item NBT data on key press in a GUI to clipboard.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int copyItemDataCompressed = Keyboard.KEY_NONE; + + @Expose + @ConfigOption(name = "Copy RNG Meter", desc = "Copies internal names and maxed XP needed from RNG meter inventories as json to clipboard.") + @ConfigEditorBoolean + public boolean copyRngMeter = false; + + @Expose + @ConfigOption(name = "Copy Bestiary Data", desc = "Copies the bestiary data from the inventory as json to clipboard.") + @ConfigEditorBoolean + public boolean copyBestiaryData = false; + + @Expose + @ConfigOption(name = "Highlight Missing Repo Items", desc = "Highlights each item in the current inventory that is not in your current NEU repo.") + @ConfigEditorBoolean + public boolean highlightMissingRepo = false; + + @Expose + @ConfigOption(name = "Hot Swap Detection", desc = "Show chat messages when Hot Swap starts and ends.") + @ConfigEditorBoolean + public boolean hotSwapDetection = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/dev/DevConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/dev/DevConfig.java new file mode 100644 index 000000000000..0c1fc01edaae --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/dev/DevConfig.java @@ -0,0 +1,52 @@ +package at.hannibal2.skyhanni.config.features.dev; + +import at.hannibal2.skyhanni.config.core.config.Position; +import at.hannibal2.skyhanni.config.features.dev.minecraftconsole.MinecraftConsoleConfig; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.Category; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +public class DevConfig { + + @Expose + @ConfigOption(name = "Repo Auto Update", desc = "Update the repository on every startup.\n" + + "§cOnly disable this if you know what you are doing!") + @ConfigEditorBoolean + public boolean repoAutoUpdate = true; + + @Expose + @ConfigOption(name = "Log Expiry Time", desc = "Deletes your SkyHanni logs after this time period in days.") + @ConfigEditorSlider(minValue = 1, maxValue = 30, minStep = 1) + public int logExpiryTime = 14; + + @Expose + @ConfigOption(name = "Debug", desc = "") + @Accordion + public DebugConfig debug = new DebugConfig(); + + @Expose + @ConfigOption(name = "Slot Number", desc = "Show slot number in inventory while pressing this key.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int showSlotNumberKey = Keyboard.KEY_NONE; + + @ConfigOption(name = "Parkour Waypoints", desc = "") + @Accordion + @Expose + public WaypointsConfig waypoint = new WaypointsConfig(); + + @Expose + public Position debugPos = new Position(10, 10, false, true); + + @Expose + public Position debugLocationPos = new Position(1, 160, false, true); + + @Expose + @Category(name = "Minecraft Console", desc = "Minecraft Console Settings") + public MinecraftConsoleConfig minecraftConsoles = new MinecraftConsoleConfig(); + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/dev/WaypointsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/dev/WaypointsConfig.java new file mode 100644 index 000000000000..863f9147624a --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/dev/WaypointsConfig.java @@ -0,0 +1,26 @@ +package at.hannibal2.skyhanni.config.features.dev; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +public class WaypointsConfig { + + @Expose + @ConfigOption(name = "Save Hotkey", desc = "Saves block location to a temporarily parkour and copies everything to your clipboard.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int saveKey = Keyboard.KEY_NONE; + + @Expose + @ConfigOption(name = "Delete Hotkey", desc = "Deletes the last saved location for when you make a mistake.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int deleteKey = Keyboard.KEY_NONE; + + @Expose + @ConfigOption(name = "Show Platform Number", desc = "Show the index number over the platform for every parkour.") + @ConfigEditorBoolean + public boolean showPlatformNumber = false; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/dev/minecraftconsole/ConsoleFiltersConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/dev/minecraftconsole/ConsoleFiltersConfig.java new file mode 100644 index 000000000000..6f537f3000b6 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/dev/minecraftconsole/ConsoleFiltersConfig.java @@ -0,0 +1,53 @@ +package at.hannibal2.skyhanni.config.features.dev.minecraftconsole; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ConsoleFiltersConfig { + @Expose + @ConfigOption(name = "Filter Chat", desc = "Filter chat messages.") + @ConfigEditorBoolean + public boolean filterChat = false; + + @Expose + @ConfigOption(name = "Filter Grow Buffer", desc = "Filter 'Needed to grow BufferBuilder buffer:'") + @ConfigEditorBoolean + public boolean filterGrowBuffer = true; + + @Expose + @ConfigOption(name = "Filter Sound Error", desc = "Filter 'Unable to play unknown soundEvent'.") + @ConfigEditorBoolean + public boolean filterUnknownSound = true; + + @Expose + @ConfigOption(name = "Filter Scoreboard Errors", desc = "Filter error messages with Scoreboard: removeTeam, createTeam, " + + "removeObjective and 'scoreboard team already exists'.") + @ConfigEditorBoolean + public boolean filterScoreboardErrors = true; + + @Expose + @ConfigOption(name = "Filter Particle", desc = "Filter message 'Could not spawn particle effect VILLAGER_HAPPY'.") + @ConfigEditorBoolean + public boolean filterParticleVillagerHappy = true; + + @Expose + @ConfigOption(name = "Filter OptiFine", desc = "Filter OptiFine messages CustomItems and ConnectedTextures during loading.") + @ConfigEditorBoolean + public boolean filterOptiFine = true; + + @Expose + @ConfigOption(name = "Filter AsmHelper Transformer", desc = "Filter messages when AsmHelper is Transforming a class during loading.") + @ConfigEditorBoolean + public boolean filterAmsHelperTransformer = true; + + @Expose + @ConfigOption(name = "Filter Applying AsmWriter", desc = "Filter messages when AsmHelper is applying AsmWriter ModifyWriter.") + @ConfigEditorBoolean + public boolean filterAsmHelperApplying = true; + + @Expose + @ConfigOption(name = "Filter Biome ID Bounds", desc = "Filter message 'Biome ID is out of bounds'.") + @ConfigEditorBoolean + public boolean filterBiomeIdBounds = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/dev/minecraftconsole/MinecraftConsoleConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/dev/minecraftconsole/MinecraftConsoleConfig.java new file mode 100644 index 000000000000..bdca34590ceb --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/dev/minecraftconsole/MinecraftConsoleConfig.java @@ -0,0 +1,40 @@ +package at.hannibal2.skyhanni.config.features.dev.minecraftconsole; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class MinecraftConsoleConfig { + @Expose + @ConfigOption(name = "Unfiltered Debug", desc = "Print the debug information for unfiltered console messages.") + @ConfigEditorBoolean + public boolean printUnfilteredDebugs = false; + + @Expose + @ConfigOption(name = "Unfiltered Debug File", desc = "Print the debug information into log files instead of into the console for unfiltered console messages.") + @ConfigEditorBoolean + public boolean logUnfilteredFile = false; + + @Expose + @ConfigOption( + name = "Outside SkyBlock", + desc = "Print the debug information for unfiltered console messages outside SkyBlock too." + ) + @ConfigEditorBoolean + public boolean printUnfilteredDebugsOutsideSkyBlock = false; + + @Expose + @ConfigOption( + name = "Log Filtered", + desc = "Log the filtered messages into the console." + ) + @ConfigEditorBoolean + public boolean printFilteredReason = false; + + @Expose + @ConfigOption(name = "Console Filters", desc = "") + @Accordion + public ConsoleFiltersConfig consoleFilter = new ConsoleFiltersConfig(); + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/CleanEndConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/CleanEndConfig.java new file mode 100644 index 000000000000..4dcdc6d7f133 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/CleanEndConfig.java @@ -0,0 +1,21 @@ +package at.hannibal2.skyhanni.config.features.dungeon; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class CleanEndConfig { + @Expose + @ConfigOption(name = "Enabled", desc = "After the last Dungeon boss has died, all entities and " + + "particles are no longer displayed and the music stops playing, but the loot chests are still displayed.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Ignore Guardians", desc = "Ignore F3 and M3 Guardians from the clean end feature when " + + "sneaking. Makes it easier to kill them after the boss died already. Thanks Hypixel.") + @ConfigEditorBoolean + public boolean F3IgnoreGuardians = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/DungeonConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/DungeonConfig.java new file mode 100644 index 000000000000..84cba4de76f2 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/DungeonConfig.java @@ -0,0 +1,102 @@ +package at.hannibal2.skyhanni.config.features.dungeon; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class DungeonConfig { + + @Expose + @ConfigOption(name = "Clicked Blocks", desc = "Highlight levers, chests, and Wither Essence when clicked in Dungeons.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightClickedBlocks = false; + + @Expose + @ConfigOption(name = "Milestones Display", desc = "Show the current milestone in Dungeons.") + @ConfigEditorBoolean + @FeatureToggle + public boolean showMilestonesDisplay = false; + + @Expose + public Position showMileStonesDisplayPos = new Position(10, 10, false, true); + + @Expose + @ConfigOption(name = "Death Counter Display", desc = "Display the total amount of deaths in the current Dungeon.") + @ConfigEditorBoolean + @FeatureToggle + public boolean deathCounterDisplay = false; + + @Expose + public Position deathCounterPos = new Position(10, 10, false, true); + + @Expose + @ConfigOption(name = "Clean End", desc = "") + @Accordion + public CleanEndConfig cleanEnd = new CleanEndConfig(); + + @Expose + @ConfigOption(name = "Boss Damage Splash", desc = "Hides damage splashes while inside the boss room (fixes a Skytils feature).") + @ConfigEditorBoolean + @FeatureToggle + public boolean damageSplashBoss = false; + + @Expose + @ConfigOption(name = "Highlight Deathmites", desc = "Highlight Deathmites in Dungeons in red color.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightDeathmites = true; + + @Expose + @ConfigOption(name = "Highlight Teammates", desc = "Highlight Dungeon teammates with a glowing outline.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightTeammates = true; + + @Expose + @ConfigOption(name = "Object Hider", desc = "Hide various things in Dungeons.") + @Accordion + public ObjectHiderConfig objectHider = new ObjectHiderConfig(); + + @Expose + @ConfigOption(name = "Message Filter", desc = "") + @Accordion + public MessageFilterConfig messageFilter = new MessageFilterConfig(); + + @Expose + @ConfigOption(name = "Dungeon Copilot", desc = "") + @Accordion + public DungeonCopilotConfig dungeonCopilot = new DungeonCopilotConfig(); + + @Expose + @ConfigOption(name = "Party Finder", desc = "") + @Accordion + public PartyFinderConfig partyFinder = new PartyFinderConfig(); + + @Expose + @ConfigOption(name = "Tab List", desc = "") + @Accordion + public TabListConfig tabList = new TabListConfig(); + + @Expose + @ConfigOption(name = "Livid Finder", desc = "") + @Accordion + public LividFinderConfig lividFinder = new LividFinderConfig(); + + @Expose + @ConfigOption(name = "Moving Skeleton Skulls", desc = "Highlight Skeleton Skulls when combining into an " + + "orange Skeletor (not useful when combined with feature Hide Skeleton Skull).") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightSkeletonSkull = true; + + @Expose + @ConfigOption(name = "Croesus Chest", desc = "Adds a visual highlight to the Croesus inventory that " + + "shows unopened chests.") + @ConfigEditorBoolean + @FeatureToggle + public boolean croesusUnopenedChestTracker = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/DungeonCopilotConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/DungeonCopilotConfig.java new file mode 100644 index 000000000000..e285fd95125c --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/DungeonCopilotConfig.java @@ -0,0 +1,18 @@ +package at.hannibal2.skyhanni.config.features.dungeon; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class DungeonCopilotConfig { + @Expose + @ConfigOption(name = "Copilot Enabled", desc = "Suggests what to do next in Dungeons.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + public Position pos = new Position(10, 10, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/LividFinderConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/LividFinderConfig.java new file mode 100644 index 000000000000..4525d1c31f10 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/LividFinderConfig.java @@ -0,0 +1,20 @@ +package at.hannibal2.skyhanni.config.features.dungeon; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class LividFinderConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Helps find the correct livid in F5 and in M5.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Hide Wrong Livids", desc = "Hide wrong livids entirely.") + @ConfigEditorBoolean + public boolean hideWrong = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/MessageFilterConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/MessageFilterConfig.java new file mode 100644 index 000000000000..5455ab0f5147 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/MessageFilterConfig.java @@ -0,0 +1,14 @@ +package at.hannibal2.skyhanni.config.features.dungeon; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class MessageFilterConfig { + @Expose + @ConfigOption(name = "Keys and Doors", desc = "Hides the chat message when picking up keys or opening doors in Dungeons.") + @ConfigEditorBoolean + @FeatureToggle + public boolean keysAndDoors = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/ObjectHiderConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/ObjectHiderConfig.java new file mode 100644 index 000000000000..690d09249bb0 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/ObjectHiderConfig.java @@ -0,0 +1,65 @@ +package at.hannibal2.skyhanni.config.features.dungeon; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ObjectHiderConfig { + @Expose + @ConfigOption(name = "Hide Superboom TNT", desc = "Hide Superboom TNT laying around in Dungeons.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideSuperboomTNT = false; + + @Expose + @ConfigOption(name = "Hide Blessings", desc = "Hide Blessings laying around in Dungeons.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideBlessing = false; + + @Expose + @ConfigOption(name = "Hide Revive Stones", desc = "Hide Revive Stones laying around in Dungeons.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideReviveStone = false; + + @Expose + @ConfigOption(name = "Hide Premium Flesh", desc = "Hide Premium Flesh laying around in Dungeons.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hidePremiumFlesh = false; + + @Expose + @ConfigOption(name = "Hide Journal Entry", desc = "Hide Journal Entry pages laying around in Dungeons.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideJournalEntry = false; + + @Expose + @ConfigOption(name = "Hide Skeleton Skull", desc = "Hide Skeleton Skulls laying around in Dungeons.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideSkeletonSkull = true; + + @Expose + @ConfigOption(name = "Hide Healer Orbs", desc = "Hides the damage, ability damage and defensive orbs that spawn when the Healer kills mobs.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideHealerOrbs = false; + + @Expose + @ConfigOption(name = "Hide Healer Fairy", desc = "Hide the Golden Fairy that follows the Healer in Dungeons.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideHealerFairy = false; + + @Expose + @ConfigOption( + name = "Hide Soulweaver Skulls", + desc = "Hide the annoying soulweaver skulls that float around you if you have the soulweaver gloves equipped.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideSoulweaverSkulls = false; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/PartyFinderConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/PartyFinderConfig.java new file mode 100644 index 000000000000..2abb3ec222e3 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/PartyFinderConfig.java @@ -0,0 +1,44 @@ +package at.hannibal2.skyhanni.config.features.dungeon; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class PartyFinderConfig { + @Expose + @ConfigOption(name = "Colored Class Level", desc = "Color class levels in Party Finder.") + @ConfigEditorBoolean + @FeatureToggle + public boolean coloredClassLevel = true; + + @Expose + @ConfigOption(name = "Floor Stack Size", desc = "Display the party finder floor as the item stack size.") + @ConfigEditorBoolean + @FeatureToggle + public boolean floorAsStackSize = true; + + @Expose + @ConfigOption(name = "Mark Paid Carries", desc = "Highlight paid carries with a red background to make them easier to find/skip.") + @ConfigEditorBoolean + @FeatureToggle + public boolean markPaidCarries = true; + + @Expose + @ConfigOption(name = "Mark Low Levels", desc = "Highlight groups with players at or below the specified class level to make them easier to find/skip.") + @ConfigEditorSlider(minValue = 0, maxValue = 50, minStep = 1) + public int markBelowClassLevel = 0; + + @Expose + @ConfigOption(name = "Mark Ineligible Groups", desc = "Highlight groups with requirements that you do not meet.") + @ConfigEditorBoolean + @FeatureToggle + public boolean markIneligibleGroups = true; + + @Expose + @ConfigOption(name = "Mark Missing Class", desc = "Highlight groups that don't currently have any members of your selected dungeon class.") + @ConfigEditorBoolean + @FeatureToggle + public boolean markMissingClass = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/TabListConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/TabListConfig.java new file mode 100644 index 000000000000..221cf4651ea5 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/dungeon/TabListConfig.java @@ -0,0 +1,15 @@ +package at.hannibal2.skyhanni.config.features.dungeon; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class TabListConfig { + + @Expose + @ConfigOption(name = "Colored Class Level", desc = "Color class levels in tab list. (Also hides rank colors and emblems, because who needs that in Dungeons anyway?)") + @ConfigEditorBoolean + @FeatureToggle + public boolean coloredClassLevel = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/CenturyConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/CenturyConfig.java new file mode 100644 index 000000000000..d5636117ddbb --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/CenturyConfig.java @@ -0,0 +1,24 @@ +package at.hannibal2.skyhanni.config.features.event; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class CenturyConfig { + + @ConfigOption(name = "Enable Active Player Timer", desc = "Show a HUD telling you how much longer you have to wait to be eligible for another free ticket.") + @Expose + @ConfigEditorBoolean + @FeatureToggle + public boolean enableActiveTimer = true; + + @Expose + public Position activeTimerPosition = new Position(100, 100, false, true); + + @ConfigOption(name = "Enable Active Player Alert", desc = "Loudly proclaim when it is time to break some wheat.") + @Expose + @ConfigEditorBoolean + public boolean enableActiveAlert = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/CityProjectConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/CityProjectConfig.java new file mode 100644 index 000000000000..ec0b853bbafa --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/CityProjectConfig.java @@ -0,0 +1,31 @@ +package at.hannibal2.skyhanni.config.features.event; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class CityProjectConfig { + + @Expose + @ConfigOption(name = "Show Materials", desc = "Show materials needed for contributing to the City Project.") + @ConfigEditorBoolean + @FeatureToggle + public boolean showMaterials = true; + + @Expose + @ConfigOption(name = "Show Ready", desc = "Mark contributions that are ready to participate.") + @ConfigEditorBoolean + @FeatureToggle + public boolean showReady = true; + + @Expose + @ConfigOption(name = "Daily Reminder", desc = "Remind every 24 hours to participate.") + @ConfigEditorBoolean + @FeatureToggle + public boolean dailyReminder = true; + + @Expose + public Position pos = new Position(150, 150, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/EventConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/EventConfig.java new file mode 100644 index 000000000000..ef27a42bd95f --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/EventConfig.java @@ -0,0 +1,51 @@ +package at.hannibal2.skyhanni.config.features.event; + +import at.hannibal2.skyhanni.config.features.event.bingo.BingoConfig; +import at.hannibal2.skyhanni.config.features.event.diana.DianaConfig; +import at.hannibal2.skyhanni.config.features.event.winter.WinterConfig; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.Category; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class EventConfig { + + @Category(name = "Bingo", desc = "Monthly Bingo Event settings") + @Expose + public BingoConfig bingo = new BingoConfig(); + + @Category(name = "Diana", desc = "Diana's Mythological Burrows") + @Expose + public DianaConfig diana = new DianaConfig(); + + @Category(name = "Winter", desc = "Winter Season on Jerry's Island") + @Expose + public WinterConfig winter = new WinterConfig(); + + @ConfigOption(name = "City Project", desc = "") + @Accordion + @Expose + public CityProjectConfig cityProject = new CityProjectConfig(); + + @ConfigOption(name = "Mayor Jerry's Jerrypocalypse", desc = "") + @Accordion + @Expose + public MayorJerryConfig jerry = new MayorJerryConfig(); + + @ConfigOption(name = "The Great Spook", desc = "") + @Accordion + @Expose + public GreatSpookConfig spook = new GreatSpookConfig(); + + // comment in if the event is needed again +// @ConfigOption(name = "300þ Anniversary Celebration", desc = "Features for the 300þ year of SkyBlock") + @Accordion + @Expose + public CenturyConfig century = new CenturyConfig(); + + @Expose + @ConfigOption(name = "Main Lobby Halloween Basket Waypoints", desc = "") + @Accordion + public HalloweenBasketConfig halloweenBasket = new HalloweenBasketConfig(); + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/GreatSpookConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/GreatSpookConfig.java new file mode 100644 index 000000000000..69eb0ae06e22 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/GreatSpookConfig.java @@ -0,0 +1,44 @@ +package at.hannibal2.skyhanni.config.features.event; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class GreatSpookConfig { + + @Expose + @ConfigOption(name = "Primal Fear Timer", desc = "Shows cooldown timer for next primal fear.") + @ConfigEditorBoolean + @FeatureToggle + public boolean primalFearTimer = false; + + @Expose + @ConfigOption(name = "Primal Fear Notify", desc = "Plays a notification sound when the next primal fear can spawn.") + @ConfigEditorBoolean + @FeatureToggle + public boolean primalFearNotification = false; + + @Expose + public Position positionTimer = new Position(20, 20, false, true); + + @Expose + @ConfigOption(name = "Fear Stat Display", desc = "Shows your current Fear stat value.") + @ConfigEditorBoolean + @FeatureToggle + public boolean fearStatDisplay = false; + + @Expose + public Position positionFear = new Position(30, 30, false, true); + + @Expose + @ConfigOption(name = "IRL Time Left", desc = "Shows the IRL time left before The Great Spook ends.") + @ConfigEditorBoolean + @FeatureToggle + public boolean greatSpookTimeLeft = false; + + @Expose + public Position positionTimeLeft = new Position(40, 40, false, true); + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/HalloweenBasketConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/HalloweenBasketConfig.java new file mode 100644 index 000000000000..5cb2bfef403d --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/HalloweenBasketConfig.java @@ -0,0 +1,25 @@ +package at.hannibal2.skyhanni.config.features.event; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class HalloweenBasketConfig { + + @Expose + @ConfigOption(name = "Basket Waypoints", desc = "Show all Halloween Basket waypoints.\nShoutout to §bTobbbb §7for the coordinates.\n(AS OF 2023)") + @ConfigEditorBoolean + @FeatureToggle + public boolean allWaypoints = false; + + @Expose + @ConfigOption(name = "Entrance Waypoints", desc = "Show helper waypoints to Baskets #23, #24, and #25. Coordinates by §bErymanthus§7.") + @ConfigEditorBoolean + public boolean allEntranceWaypoints = false; + + @Expose + @ConfigOption(name = "Only Closest", desc = "Only show the closest waypoint") + @ConfigEditorBoolean + public boolean onlyClosest = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/MayorJerryConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/MayorJerryConfig.java new file mode 100644 index 000000000000..b3afe6c1a8df --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/MayorJerryConfig.java @@ -0,0 +1,16 @@ +package at.hannibal2.skyhanni.config.features.event; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class MayorJerryConfig { + + @Expose + @ConfigOption(name = "Highlight Jerries", desc = "Highlights Jerries found from the Jerrypocalypse perk. Highlight color is based on color of the Jerry.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightJerries = true; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/bingo/BingoCardConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/bingo/BingoCardConfig.java new file mode 100644 index 000000000000..2bc7e1f8fc86 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/bingo/BingoCardConfig.java @@ -0,0 +1,50 @@ +package at.hannibal2.skyhanni.config.features.event.bingo; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import io.github.moulberry.moulconfig.observer.Property; + +public class BingoCardConfig { + @Expose + @ConfigOption(name = "Enable", desc = "Displays the Bingo Card.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + @Expose + @ConfigOption(name = "Quick Toggle", desc = "Quickly toggle the Bingo Card or the step helper by sneaking with SkyBlock Menu in hand.") + @ConfigEditorBoolean + public boolean quickToggle = true; + + @Expose + @ConfigOption(name = "Bingo Steps", desc = "Show help with the next step in Bingo instead of the Bingo Card. " + + "§cThis feature is in early development. Expect bugs and missing goals.") + @ConfigEditorBoolean + public boolean stepHelper = false; + + @Expose + @ConfigOption(name = "Hide Community Goals", desc = "Hide Community Goals from the Bingo Card display.") + @ConfigEditorBoolean + public Property hideCommunityGoals = Property.of(false); + + @Expose + @ConfigOption( + name = "Show Guide", + desc = "Show tips and difficulty for bingo goals inside the Bingo Card inventory.\n" + + "These tips are made from inspirations and guides from the community,\n" + + "aiming to help you to complete the bingo card." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean bingoSplashGuide = true; + + @Expose + public Position bingoCardPos = new Position(10, 10, false, true); + + @Expose + @ConfigOption(name = "Next Tip Duration", desc = "Show the duration until the next hidden personal goal gets a tip revealed.") + @ConfigEditorBoolean + public Property nextTipDuration = Property.of(true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/bingo/BingoConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/bingo/BingoConfig.java new file mode 100644 index 000000000000..816f8a1940a0 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/bingo/BingoConfig.java @@ -0,0 +1,30 @@ +package at.hannibal2.skyhanni.config.features.event.bingo; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class BingoConfig { + + @Expose + @ConfigOption(name = "Bingo Card", desc = "") + @Accordion + public BingoCardConfig bingoCard = new BingoCardConfig(); + + @Expose + @ConfigOption(name = "Compact Chat Messages", desc = "") + @Accordion + public CompactChatConfig compactChat = new CompactChatConfig(); + + @Expose + @ConfigOption(name = "Minion Craft Helper", desc = "Show how many more items you need to upgrade the minion in your inventory. Especially useful for Bingo.") + @ConfigEditorBoolean + @FeatureToggle + public boolean minionCraftHelperEnabled = true; + + @Expose + public Position minionCraftHelperPos = new Position(10, 10, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/bingo/CompactChatConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/bingo/CompactChatConfig.java new file mode 100644 index 000000000000..bbf73764667f --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/bingo/CompactChatConfig.java @@ -0,0 +1,27 @@ +package at.hannibal2.skyhanni.config.features.event.bingo; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class CompactChatConfig { + + @Expose + @ConfigOption(name = "Enable", desc = "Shortens chat messages about skill level ups, collection gains, " + + "new area discoveries and SkyBlock level up messages while on Bingo.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Hide Border", desc = "Hide the border messages before and after the compact level up messages.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideBorder = true; + + @Expose + @ConfigOption(name = "Outside Bingo", desc = "Compact the level up chat messages outside of an Bingo profile as well.") + @ConfigEditorBoolean + public boolean outsideBingo = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/diana/DianaConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/diana/DianaConfig.java new file mode 100644 index 000000000000..b5d21bade3fb --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/diana/DianaConfig.java @@ -0,0 +1,60 @@ +package at.hannibal2.skyhanni.config.features.event.diana; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +public class DianaConfig { + + @Expose + @ConfigOption(name = "Soopy Guess", desc = "Uses §eSoopy's Guess Logic §7to find the next burrow. Does not require SoopyV2 or ChatTriggers to be installed.") + @ConfigEditorBoolean + @FeatureToggle + public boolean burrowsSoopyGuess = false; + + @Expose + @ConfigOption(name = "Nearby Detection", desc = "Show burrows near you.") + @ConfigEditorBoolean + @FeatureToggle + public boolean burrowsNearbyDetection = false; + + @Expose + @ConfigOption(name = "Smooth Transition", desc = "Show the way from one burrow to another smoothly.") + @ConfigEditorBoolean + public boolean burrowSmoothTransition = false; + + @Expose + @ConfigOption(name = "Nearest Warp", desc = "Warps to the nearest warp point on the hub, if closer to the next burrow.") + @ConfigEditorBoolean + public boolean burrowNearestWarp = false; + + @Expose + @ConfigOption(name = "Warp Key", desc = "Press this key to warp to nearest burrow waypoint.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int keyBindWarp = Keyboard.KEY_NONE; + + @Expose + @ConfigOption(name = "Ignored Warps", desc = "") + @Accordion + public IgnoredWarpsConfig ignoredWarps = new IgnoredWarpsConfig(); + + @Expose + @ConfigOption(name = "Inquisitor Waypoint Sharing", desc = "") + @Accordion + public InquisitorSharingConfig inquisitorSharing = new InquisitorSharingConfig(); + + @Expose + @ConfigOption(name = "Griffin Pet Warning", desc = "Warn when holding an Ancestral Spade if a Griffin Pet is not equipped.") + @ConfigEditorBoolean + @FeatureToggle + public boolean petWarning = true; + + @Expose + @ConfigOption(name = "Always Diana", desc = "Forcefully set the Diana event to be active. This is useful if the auto mayor detection fails.") + @ConfigEditorBoolean + public boolean alwaysDiana = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/diana/IgnoredWarpsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/diana/IgnoredWarpsConfig.java new file mode 100644 index 000000000000..2cef22331753 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/diana/IgnoredWarpsConfig.java @@ -0,0 +1,19 @@ +package at.hannibal2.skyhanni.config.features.event.diana; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class IgnoredWarpsConfig { + + @Expose + @ConfigOption(name = "Crypt", desc = "Ignore the Crypt warp point (Because it takes a long time to leave).") + @ConfigEditorBoolean + public boolean crypt = false; + + @Expose + @ConfigOption(name = "Wizard", desc = "Ignore the Wizard Tower warp point (Because it is easy to fall into the rift).") + @ConfigEditorBoolean + public boolean wizard = false; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/diana/InquisitorSharingConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/diana/InquisitorSharingConfig.java new file mode 100644 index 000000000000..c719a710157b --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/diana/InquisitorSharingConfig.java @@ -0,0 +1,37 @@ +package at.hannibal2.skyhanni.config.features.event.diana; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +public class InquisitorSharingConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Shares your Inquisitor and receiving other Inquisitors via Party Chat.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Focus", desc = "Hide other waypoints when your Party finds an Inquisitor.") + @ConfigEditorBoolean + public boolean focusInquisitor = false; + + @Expose + @ConfigOption(name = "Instant Share", desc = "Share the waypoint as soon as you find an Inquisitor. As an alternative, you can share it only via key press.") + @ConfigEditorBoolean + public boolean instantShare = true; + + @Expose + @ConfigOption(name = "Share Key", desc = "Press this key to share your Inquisitor Waypoint.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_Y) + public int keyBindShare = Keyboard.KEY_Y; + + @Expose + @ConfigOption(name = "Show Despawn Time", desc = "Show the time until the shared Inquisitor will despawn.") + @ConfigEditorBoolean + public boolean showDespawnTime = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/winter/FrozenTreasureConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/winter/FrozenTreasureConfig.java new file mode 100644 index 000000000000..a1f378d08da5 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/winter/FrozenTreasureConfig.java @@ -0,0 +1,124 @@ +package at.hannibal2.skyhanni.config.features.event.winter; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.HasLegacyId; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import static at.hannibal2.skyhanni.config.features.event.winter.FrozenTreasureConfig.FrozenTreasureDisplayEntry.COMPACT_PROCS; +import static at.hannibal2.skyhanni.config.features.event.winter.FrozenTreasureConfig.FrozenTreasureDisplayEntry.ENCHANTED_ICE; +import static at.hannibal2.skyhanni.config.features.event.winter.FrozenTreasureConfig.FrozenTreasureDisplayEntry.ENCHANTED_PACKED_ICE; +import static at.hannibal2.skyhanni.config.features.event.winter.FrozenTreasureConfig.FrozenTreasureDisplayEntry.GLACIAL_FRAGMENT; +import static at.hannibal2.skyhanni.config.features.event.winter.FrozenTreasureConfig.FrozenTreasureDisplayEntry.GLACIAL_TALISMAN; +import static at.hannibal2.skyhanni.config.features.event.winter.FrozenTreasureConfig.FrozenTreasureDisplayEntry.GREEN_GIFT; +import static at.hannibal2.skyhanni.config.features.event.winter.FrozenTreasureConfig.FrozenTreasureDisplayEntry.ICE_PER_HOUR; +import static at.hannibal2.skyhanni.config.features.event.winter.FrozenTreasureConfig.FrozenTreasureDisplayEntry.RED_GIFT; +import static at.hannibal2.skyhanni.config.features.event.winter.FrozenTreasureConfig.FrozenTreasureDisplayEntry.SPACER_1; +import static at.hannibal2.skyhanni.config.features.event.winter.FrozenTreasureConfig.FrozenTreasureDisplayEntry.TITLE; +import static at.hannibal2.skyhanni.config.features.event.winter.FrozenTreasureConfig.FrozenTreasureDisplayEntry.TOTAL_ICE; +import static at.hannibal2.skyhanni.config.features.event.winter.FrozenTreasureConfig.FrozenTreasureDisplayEntry.TREASURES_MINED; +import static at.hannibal2.skyhanni.config.features.event.winter.FrozenTreasureConfig.FrozenTreasureDisplayEntry.WHITE_GIFT; + +public class FrozenTreasureConfig { + + @Expose + @ConfigOption( + name = "Enabled", + desc = "Tracks all of your drops from Frozen Treasure in the Glacial Caves.\n" + + "§eIce calculations are an estimate but are relatively accurate." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption( + name = "Text Format", + desc = "Drag text to change the appearance of the overlay." + ) + @ConfigEditorDraggableList() + public List textFormat = new ArrayList<>(Arrays.asList( + TITLE, + TREASURES_MINED, + TOTAL_ICE, + ICE_PER_HOUR, + COMPACT_PROCS, + SPACER_1, + WHITE_GIFT, + GREEN_GIFT, + RED_GIFT, + ENCHANTED_ICE, + ENCHANTED_PACKED_ICE, + GLACIAL_FRAGMENT, + GLACIAL_TALISMAN + )); + + public enum FrozenTreasureDisplayEntry implements HasLegacyId { + TITLE("§1§lFrozen Treasure Tracker", 0), + TREASURES_MINED("§61,636 Treasures Mined", 1), + TOTAL_ICE("§33.2m Total Ice", 2), + ICE_PER_HOUR("§3342,192 Ice/hr", 3), + COMPACT_PROCS("§81,002 Compact Procs", 4), + SPACER_1(" ", 5), + WHITE_GIFT("§b182 §fWhite Gift", 6), + GREEN_GIFT("§b94 §aGreen Gift", 7), + RED_GIFT("§b17 §9§cRed Gift", 8), + PACKED_ICE("§b328 §fPacked Ice", 9), + ENCHANTED_ICE("§b80 §aEnchanted Ice", 10), + ENCHANTED_PACKED_ICE("§b4 §9Enchanted Packed Ice", 11), + ICE_BAIT("§b182 §aIce Bait", 12), + GLOWY_CHUM_BAIT("§b3 §aGlowy Chum Bait", 13), + GLACIAL_FRAGMENT("§b36 §5Glacial Fragment", 14), + GLACIAL_TALISMAN("§b6 §fGlacial Talisman", 15), + SPACER_2(" ", 16); + + private final String str; + private final int legacyId; + + FrozenTreasureDisplayEntry(String str, int legacyId) { + this.str = str; + this.legacyId = legacyId; + } + + // Constructor if new enum elements are added post-migration + FrozenTreasureDisplayEntry(String str) { + this(str, -1); + } + + @Override + public int getLegacyId() { + return legacyId; + } + + @Override + public String toString() { + return str; + } + } + + @Expose + @ConfigOption(name = "Only in Glacial Cave", desc = "Only shows the overlay while in the Glacial Cave.") + @ConfigEditorBoolean + public boolean onlyInCave = true; + + @Expose + @ConfigOption(name = "Show as Drops", desc = "Multiplies the numbers on the display by the base drop. \n" + + "E.g. 3 Ice Bait -> 48 Ice Bait") + @ConfigEditorBoolean + public boolean showAsDrops = false; + + @Expose + @ConfigOption(name = "Hide Chat Messages", desc = "Hides the chat messages from Frozen Treasures.") + @ConfigEditorBoolean + public boolean hideMessages = false; + + @Expose + public Position position = new Position(10, 80, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/winter/GiftingOpportunitiesConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/winter/GiftingOpportunitiesConfig.java new file mode 100644 index 000000000000..f303099b4a54 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/winter/GiftingOpportunitiesConfig.java @@ -0,0 +1,27 @@ +package at.hannibal2.skyhanni.config.features.event.winter; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class GiftingOpportunitiesConfig { + @Expose + @ConfigOption(name = "Enabled", desc = "Highlight players who you haven't given gifts to yet.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Only While Holding Gift", desc = "Only highlight ungifted players while holding a gift.") + @ConfigEditorBoolean + public boolean highlighWithGiftOnly = true; + + + @Expose + @ConfigOption(name = "Use Armor Stands", desc = "Make use of armor stands to stop highlighting players. " + + "This is a bit inaccurate, but it can help with people you gifted before this feature was used.") + @ConfigEditorBoolean + public boolean useArmorStandDetection = false; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/winter/UniqueGiftConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/winter/UniqueGiftConfig.java new file mode 100644 index 000000000000..5ccc823c505f --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/winter/UniqueGiftConfig.java @@ -0,0 +1,19 @@ +package at.hannibal2.skyhanni.config.features.event.winter; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class UniqueGiftConfig { + @Expose + @ConfigOption(name = "Enabled", desc = "Show in a display how many unique players you have given gifts to in the winter 2023 event." + + " Open §e/opengenerowmenu §7to sync up!") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + public Position position = new Position(100, 100, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/event/winter/WinterConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/event/winter/WinterConfig.java new file mode 100644 index 000000000000..79ac983c2472 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/event/winter/WinterConfig.java @@ -0,0 +1,36 @@ +package at.hannibal2.skyhanni.config.features.event.winter; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class WinterConfig { + + @Expose + @ConfigOption(name = "Frozen Treasure Tracker", desc = "") + @Accordion + public FrozenTreasureConfig frozenTreasureTracker = new FrozenTreasureConfig(); + + @Accordion + @Expose + @ConfigOption(name = "Unique Gifting Opportunities", desc = "Highlight players who you haven't given gifts to yet.") + public GiftingOpportunitiesConfig giftingOpportunities = new GiftingOpportunitiesConfig(); + + @Accordion + @Expose + @ConfigOption(name = "Unique Gift Counter", desc = "Keep track how many unique players you have given gifts to.") + public UniqueGiftConfig uniqueGiftCounter = new UniqueGiftConfig(); + + @Expose + @ConfigOption(name = "Island Close Time", desc = "While on the Winter Island, show a timer until Jerry's Workshop closes.") + @ConfigEditorBoolean + @FeatureToggle + public boolean islandCloseTime = true; + + @Expose + public Position islandCloseTimePosition = new Position(10, 10, false, true); + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/fishing/BarnTimerConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/BarnTimerConfig.java new file mode 100644 index 000000000000..bf2609ed0b93 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/BarnTimerConfig.java @@ -0,0 +1,78 @@ +package at.hannibal2.skyhanni.config.features.fishing; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +public class BarnTimerConfig { + @Expose + @ConfigOption( + name = "Barn Fishing Timer", + desc = "Show the time and amount of sea creatures while fishing on the barn via hub." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption( + name = "Worm Fishing", + desc = "Show the Barn Fishing Timer in the Crystal Hollows." + ) + @ConfigEditorBoolean + public boolean crystalHollows = true; + + @Expose + @ConfigOption( + name = "Lava Fishing", + desc = "Show the Barn Fishing Timer in the Crimson Isle." + ) + @ConfigEditorBoolean + public boolean crimsonIsle = true; + + @Expose + @ConfigOption( + name = "Winter Fishing", + desc = "Show the Barn Fishing Timer on the Jerry's Workshop." + ) + @ConfigEditorBoolean + public boolean winterIsland = true; + + @Expose + @ConfigOption( + name = "Stranded Fishing", + desc = "Show the Barn Fishing Timer on all the different islands that Stranded players can visit." + ) + @ConfigEditorBoolean + public boolean forStranded = true; + + @Expose + @ConfigOption( + name = "Worm Cap Alert", + desc = "Alerts you with title and sound if you hit the Worm Sea Creature limit of 60." + ) + @ConfigEditorBoolean + public boolean wormLimitAlert = true; + + @Expose + @ConfigOption(name = "Reset Timer Hotkey", desc = "Press this key to reset the timer manualy") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int manualResetTimer = Keyboard.KEY_NONE; + + @Expose + @ConfigOption(name = "Fishing Timer Alert", desc = "Change the amount of time in seconds until the timer dings.") + @ConfigEditorSlider( + minValue = 240, + maxValue = 360, + minStep = 10 + ) + public int alertTime = 330; + + @Expose + public Position pos = new Position(10, 10, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/fishing/ChumBucketHiderConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/ChumBucketHiderConfig.java new file mode 100644 index 000000000000..aaf8a891e649 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/ChumBucketHiderConfig.java @@ -0,0 +1,26 @@ +package at.hannibal2.skyhanni.config.features.fishing; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import io.github.moulberry.moulconfig.observer.Property; + +public class ChumBucketHiderConfig { + + @Expose + @ConfigOption(name = "Enable", desc = "Hide the Chum/Chumcap Bucket name tags for other players.") + @ConfigEditorBoolean + @FeatureToggle + public Property enabled = Property.of(true); + + @Expose + @ConfigOption(name = "Hide Bucket", desc = "Hide the Chum/Chumcap Bucket.") + @ConfigEditorBoolean + public Property hideBucket = Property.of(false); + + @Expose + @ConfigOption(name = "Hide Own", desc = "Hides your own Chum/Chumcap Bucket.") + @ConfigEditorBoolean + public Property hideOwn = Property.of(false); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/fishing/FishedItemNameConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/FishedItemNameConfig.java new file mode 100644 index 000000000000..51c37e5ea88b --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/FishedItemNameConfig.java @@ -0,0 +1,21 @@ +package at.hannibal2.skyhanni.config.features.fishing; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class FishedItemNameConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Show the fished item name above the item when fishing.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Show Bait", desc = "Also show the name of the consumed bait.") + @ConfigEditorBoolean + public boolean showBaits = false; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/fishing/FishingBaitWarningsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/FishingBaitWarningsConfig.java new file mode 100644 index 000000000000..ae2dd9c9b489 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/FishingBaitWarningsConfig.java @@ -0,0 +1,20 @@ +package at.hannibal2.skyhanni.config.features.fishing; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class FishingBaitWarningsConfig { + @Expose + @ConfigOption(name = "Bait Change Warning", desc = "Show warning when fishing bait is changed") + @ConfigEditorBoolean + @FeatureToggle + public boolean baitChangeWarning = false; + + @Expose + @ConfigOption(name = "No Bait Warning", desc = "Show warning when no bait is used") + @ConfigEditorBoolean + @FeatureToggle + public boolean noBaitWarning = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/fishing/FishingConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/FishingConfig.java new file mode 100644 index 000000000000..349f4882eb12 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/FishingConfig.java @@ -0,0 +1,81 @@ +package at.hannibal2.skyhanni.config.features.fishing; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import at.hannibal2.skyhanni.config.features.fishing.trophyfishing.TrophyFishingConfig; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.Category; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class FishingConfig { + + @Expose + @Category(name = "Trophy Fishing", desc = "Trophy Fishing Settings") + public TrophyFishingConfig trophyFishing = new TrophyFishingConfig(); + + @Expose + @ConfigOption(name = "Thunder Spark", desc = "") + @Accordion + public ThunderSparkConfig thunderSpark = new ThunderSparkConfig(); + + @Expose + @ConfigOption(name = "Barn Fishing Timer", desc = "") + @Accordion + public BarnTimerConfig barnTimer = new BarnTimerConfig(); + + @Expose + @ConfigOption(name = "Chum/Chumcap Bucket Hider", desc = "") + @Accordion + public ChumBucketHiderConfig chumBucketHider = new ChumBucketHiderConfig(); + + @Expose + @ConfigOption(name = "Fished Item Name", desc = "") + @Accordion + public FishedItemNameConfig fishedItemName = new FishedItemNameConfig(); + + @Expose + @ConfigOption(name = "Fishing Hook Display", desc = "") + @Accordion + public FishingHookDisplayConfig fishingHookDisplay = new FishingHookDisplayConfig(); + + @Expose + @ConfigOption(name = "Bait Warnings", desc = "") + @Accordion + public FishingBaitWarningsConfig fishingBaitWarnings = new FishingBaitWarningsConfig(); + + @Expose + @ConfigOption(name = "Rare Sea Creatures", desc = "") + @Accordion + public RareCatchesConfig rareCatches = new RareCatchesConfig(); + + @Expose + @ConfigOption(name = "Fishing Profit Tracker", desc = "") + @Accordion + public FishingProfitTrackerConfig fishingProfitTracker = new FishingProfitTrackerConfig(); + + @Expose + @ConfigOption( + name = "Shark Fish Counter", + desc = "Counts how many Sharks have been caught." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean sharkFishCounter = false; + + @Expose + public Position sharkFishCounterPos = new Position(10, 10, false, true); + + @Expose + @ConfigOption(name = "Shorten Fishing Message", desc = "Shortens the chat message that says what type of Sea Creature you have fished.") + @ConfigEditorBoolean + @FeatureToggle + public boolean shortenFishingMessage = false; + + @Expose + @ConfigOption(name = "Compact Double Hook", desc = "Adds Double Hook to the Sea Creature chat message instead of in a previous line.") + @ConfigEditorBoolean + @FeatureToggle + public boolean compactDoubleHook = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/fishing/FishingHookDisplayConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/FishingHookDisplayConfig.java new file mode 100644 index 000000000000..e2cfdfa0553f --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/FishingHookDisplayConfig.java @@ -0,0 +1,27 @@ +package at.hannibal2.skyhanni.config.features.fishing; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class FishingHookDisplayConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Display the Hypixel timer until the fishing hook can be pulled out of the water/lava, only bigger and on your screen.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption( + name = "Hide Armor Stand", + desc = "Hide the original armor stand from Hypixel when the SkyHanni display is enabled." + ) + @ConfigEditorBoolean + public boolean hideArmorStand = true; + + @Expose + public Position position = new Position(460, -240, 3.4f); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/fishing/FishingProfitTrackerConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/FishingProfitTrackerConfig.java new file mode 100644 index 000000000000..4090e12ddbac --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/FishingProfitTrackerConfig.java @@ -0,0 +1,29 @@ +package at.hannibal2.skyhanni.config.features.fishing; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class FishingProfitTrackerConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Count all items you pick up while fishing.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + public Position position = new Position(20, 20, false, true); + + @Expose + @ConfigOption(name = "Hide Moving", desc = "Hide the Fishing Profit Tracker while moving.") + @ConfigEditorBoolean + public boolean hideMoving = true; + + @Expose + @ConfigOption(name = "Show When Pickup", desc = "Show the fishing tracker for a couple of seconds after catching something even while moving.") + @ConfigEditorBoolean + public boolean showWhenPickup = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/fishing/RareCatchesConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/RareCatchesConfig.java new file mode 100644 index 000000000000..b89347c65ed4 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/RareCatchesConfig.java @@ -0,0 +1,32 @@ +package at.hannibal2.skyhanni.config.features.fishing; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class RareCatchesConfig { + + @Expose + @ConfigOption(name = "Alert (Own Sea Creatures)", desc = "Show an alert on screen when you catch a rare sea creature.") + @ConfigEditorBoolean + @FeatureToggle + public boolean alertOwnCatches = true; + + @Expose + @ConfigOption(name = "Alert (Other Sea Creatures)", desc = "Show an alert on screen when other players nearby catch a rare sea creature.") + @ConfigEditorBoolean + public boolean alertOtherCatches = false; + + @Expose + @ConfigOption(name = "Play Sound Alert", desc = "Play a sound effect when rare sea creature alerts are displayed.") + @ConfigEditorBoolean + public boolean playSound = true; + + @Expose + @ConfigOption(name = "Highlight", desc = "Highlight nearby rare sea creatures.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlight = false; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/fishing/ThunderSparkConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/ThunderSparkConfig.java new file mode 100644 index 000000000000..78e75f6c48c9 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/ThunderSparkConfig.java @@ -0,0 +1,20 @@ +package at.hannibal2.skyhanni.config.features.fishing; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ThunderSparkConfig { + @Expose + @ConfigOption(name = "Thunder Spark Highlight", desc = "Highlight Thunder Sparks after killing a Thunder.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlight = false; + + @Expose + @ConfigOption(name = "Thunder Spark Color", desc = "Color of the Thunder Sparks.") + @ConfigEditorColour + public String color = "0:255:255:255:255"; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/fishing/trophyfishing/ChatMessagesConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/trophyfishing/ChatMessagesConfig.java new file mode 100644 index 000000000000..f19fc0d86488 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/trophyfishing/ChatMessagesConfig.java @@ -0,0 +1,56 @@ +package at.hannibal2.skyhanni.config.features.fishing.trophyfishing; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ChatMessagesConfig { + + @Expose + @ConfigOption( + name = "Trophy Counter", + desc = "Counts Trophy messages from chat and tells you how many you have found." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption( + name = "Trophy Counter Design", + desc = "§fStyle 1: §72. §6§lGOLD §5Moldfin\n" + + "§fStyle 2: §bYou caught a §5Moldfin §6§lGOLD§b. §7(2)\n" + + "§fStyle 3: §bYou caught your 2nd §6§lGOLD §5Moldfin§b." + ) + @ConfigEditorDropdown(values = {"Style 1", "Style 2", "Style 3"}) + public int design = 0; + + @Expose + @ConfigOption(name = "Show Total Amount", desc = "Show total amount of all rarities at the end of the chat message.") + @ConfigEditorBoolean + public boolean totalAmount = false; + + @Expose + @ConfigOption(name = "Trophy Fish Info", desc = "Show information and stats about a Trophy Fish when hovering over a catch message in chat.") + @ConfigEditorBoolean + @FeatureToggle + public boolean tooltip = true; + + @Expose + @ConfigOption(name = "Hide Repeated Catches", desc = "Delete past catches of the same Trophy Fish from chat.") + @ConfigEditorBoolean + @FeatureToggle + public boolean duplicateHider = false; + + @Expose + @ConfigOption(name = "Bronze Duplicates", desc = "Hide duplicate messages for bronze Trophy Fishes from chat.") + @ConfigEditorBoolean + public boolean bronzeHider = false; + + @Expose + @ConfigOption(name = "Silver Duplicates", desc = "Hide duplicate messages for silver Trophy Fishes from chat.") + @ConfigEditorBoolean + public boolean silverHider = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/fishing/trophyfishing/TrophyFishingConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/trophyfishing/TrophyFishingConfig.java new file mode 100644 index 000000000000..ce774a72f130 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/fishing/trophyfishing/TrophyFishingConfig.java @@ -0,0 +1,27 @@ +package at.hannibal2.skyhanni.config.features.fishing.trophyfishing; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class TrophyFishingConfig { + + @Expose + @ConfigOption(name = "Trophy Fishing Chat Messages", desc = "") + @Accordion + public ChatMessagesConfig chatMessages = new ChatMessagesConfig(); + + @Expose + @ConfigOption(name = "Fillet Tooltip", desc = "Show fillet value of Trophy Fish in tooltip.") + @ConfigEditorBoolean + @FeatureToggle + public boolean filletTooltip = true; + + @Expose + @ConfigOption(name = "Odger Waypoint", desc = "Show the Odger waypoint when Trophy Fishes are in the inventory and no lava rod in hand.") + @ConfigEditorBoolean + @FeatureToggle + public boolean odgerLocation = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/AnitaShopConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/AnitaShopConfig.java new file mode 100644 index 000000000000..f45f8cbc149a --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/AnitaShopConfig.java @@ -0,0 +1,30 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class AnitaShopConfig { + @Expose + @ConfigOption( + name = "Medal Prices", + desc = "Helps to identify profitable items to buy at the Anita item shop " + + "and potential profit from selling the item in the Auction House." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean medalProfitEnabled = true; + + @Expose + @ConfigOption( + name = "Extra Farming Fortune", + desc = "Show current tier and cost to max out in the item tooltip.") + @ConfigEditorBoolean + @FeatureToggle + public boolean extraFarmingFortune = true; + + @Expose + public Position medalProfitPos = new Position(206, 158, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/CropStartLocationConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/CropStartLocationConfig.java new file mode 100644 index 000000000000..721c5757f6fd --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/CropStartLocationConfig.java @@ -0,0 +1,16 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class CropStartLocationConfig { + + @Expose + @ConfigOption(name = "Enable", desc = "Show the start waypoint for the farm of your current tool in hand. Do §e/shcropstartlocation §7to change the waypoint again.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/DicerCounterConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/DicerCounterConfig.java new file mode 100644 index 000000000000..63087dab1d0a --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/DicerCounterConfig.java @@ -0,0 +1,24 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class DicerCounterConfig { + @Expose + @ConfigOption(name = "RNG Drop Counter", desc = "Count RNG drops for Melon Dicer and Pumpkin Dicer.") + @ConfigEditorBoolean + @FeatureToggle + public boolean display = true; + + @Expose + @ConfigOption(name = "Hide Chat", desc = "Hide the chat message when dropping a RNG Dicer drop.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideChat = false; + + @Expose + public Position pos = new Position(16, -232, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/EliteFarmingWeightConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/EliteFarmingWeightConfig.java new file mode 100644 index 000000000000..caf56c19511e --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/EliteFarmingWeightConfig.java @@ -0,0 +1,54 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorText; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class EliteFarmingWeightConfig { + @Expose + @ConfigOption(name = "Display", desc = "Display your farming weight on screen. " + + "The calculation and API is provided by The Elite SkyBlock farmers. " + + "See §ehttps://elitebot.dev/info §7for more info.") + @ConfigEditorBoolean + @FeatureToggle + public boolean display = true; + + @Expose + public Position pos = new Position(180, 10, false, true); + + @Expose + @ConfigOption(name = "Leaderboard Ranking", desc = "Show your position in the farming weight leaderboard. " + + "Only if your farming weight is high enough! Updates every 10 minutes.") + @ConfigEditorBoolean + public boolean leaderboard = true; + + @Expose + @ConfigOption(name = "Overtake ETA", desc = "Show a timer estimating when you'll move up a spot in the leaderboard! " + + "Will show an ETA to rank #10,000 if you're not on the leaderboard yet.") + @ConfigEditorBoolean + public boolean overtakeETA = false; + + @Expose + @ConfigOption(name = "Show LB Change", desc = "Show the change of your position in the farming weight leaderboard while you were offline.") + @ConfigEditorBoolean + // TODO migrate + public boolean offScreenDropMessage = true; + + @Expose + @ConfigOption(name = "Always ETA", desc = "Show the Overtake ETA always, even when not farming at the moment.") + @ConfigEditorBoolean + public boolean overtakeETAAlways = true; + + @Expose + @ConfigOption(name = "ETA Goal", desc = "Override the Overtake ETA to show when you'll reach the specified rank (if not there yet). (Default: \"10,000\")") + @ConfigEditorText + public String ETAGoalRank = "10000"; + + @Expose + @ConfigOption(name = "Show below 200", desc = "Show the farming weight data even if you are below 200 weight.") + @ConfigEditorBoolean + public boolean ignoreLow = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/FarmingArmorDropsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/FarmingArmorDropsConfig.java new file mode 100644 index 000000000000..64d04f932af6 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/FarmingArmorDropsConfig.java @@ -0,0 +1,24 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class FarmingArmorDropsConfig { + @Expose + @ConfigOption(name = "Show Counter", desc = "Count all §9Cropie§7, §5Squash §7and §6Fermento §7dropped.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Hide Chat", desc = "Hide the chat message when receiving a farming armor drop.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideChat = false; + + @Expose + public Position pos = new Position(16, -232, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/FarmingFortuneConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/FarmingFortuneConfig.java new file mode 100644 index 000000000000..ff5f6c62d776 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/FarmingFortuneConfig.java @@ -0,0 +1,27 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.commands.Commands; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorButton; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class FarmingFortuneConfig { + @Expose + @ConfigOption( + name = "FF Display", + desc = "Displays the true Farming Fortune for the current crop, including all crop-specific and hidden bonuses." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean display = true; + + @ConfigOption(name = "Farming Fortune Guide", desc = "Opens a guide that breaks down your Farming Fortune.\n§eCommand: /ff") + @ConfigEditorButton(buttonText = "Open") + public Runnable open = Commands::openFortuneGuide; + + @Expose + public Position pos = new Position(5, -180, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/GardenCommandsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/GardenCommandsConfig.java new file mode 100644 index 000000000000..5f7d28b2e5f5 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/GardenCommandsConfig.java @@ -0,0 +1,31 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +public class GardenCommandsConfig { + @Expose + @ConfigOption(name = "Warp Commands", desc = "Enable commands §e/home§7, §e/barn §7and §e/tp §7. §cOnly works while in the garden.") + @ConfigEditorBoolean + @FeatureToggle + public boolean warpCommands = true; + + @Expose + @ConfigOption(name = "Home Hotkey", desc = "Press this key to teleport you to your Garden home. §cOnly works while in the garden.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int homeHotkey = Keyboard.KEY_NONE; + + @Expose + @ConfigOption(name = "Sethome Hotkey", desc = "Press this key to set your Garden home. §cOnly works while in the garden.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int sethomeHotkey = Keyboard.KEY_NONE; + + @Expose + @ConfigOption(name = "Barn Hotkey", desc = "Press this key to teleport you to the Garden barn. §cOnly works while in the garden.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int barnHotkey = Keyboard.KEY_NONE; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/GardenConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/GardenConfig.java new file mode 100644 index 000000000000..77e497b5e8c6 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/GardenConfig.java @@ -0,0 +1,227 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import at.hannibal2.skyhanni.config.features.garden.composter.ComposterConfig; +import at.hannibal2.skyhanni.config.features.garden.cropmilestones.CropMilestonesConfig; +import at.hannibal2.skyhanni.config.features.garden.optimalspeed.OptimalSpeedConfig; +import at.hannibal2.skyhanni.config.features.garden.pests.PestsConfig; +import at.hannibal2.skyhanni.config.features.garden.visitor.VisitorConfig; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.Category; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class GardenConfig { + + @Expose + @ConfigOption(name = "SkyMart", desc = "") + @Accordion + public SkyMartConfig skyMart = new SkyMartConfig(); + + @Expose + @Category(name = "Visitor", desc = "Visitor Settings") + public VisitorConfig visitors = new VisitorConfig(); + + @Expose + @ConfigOption(name = "Numbers", desc = "") + @Accordion + public NumbersConfig number = new NumbersConfig(); + + @Expose + @Category(name = "Crop Milestones", desc = "Crop Milestones Settings") + public CropMilestonesConfig cropMilestones = new CropMilestonesConfig(); + + // TODO moulconfig runnable support + @Expose + @ConfigOption(name = "Custom Keybinds", desc = "") + @Accordion + public KeyBindConfig keyBind = new KeyBindConfig(); + + @Expose + @Category(name = "Optimal Speed", desc = "Optimal Speed Settings") + public OptimalSpeedConfig optimalSpeeds = new OptimalSpeedConfig(); + + @Expose + @ConfigOption(name = "Garden Level", desc = "") + @Accordion + public GardenLevelConfig gardenLevels = new GardenLevelConfig(); + + @Expose + @ConfigOption(name = "Farming Weight", desc = "") + @Accordion + public EliteFarmingWeightConfig eliteFarmingWeights = new EliteFarmingWeightConfig(); + + @Expose + @ConfigOption(name = "Dicer Counter", desc = "") + @Accordion + public DicerCounterConfig dicerCounters = new DicerCounterConfig(); + + @Expose + @ConfigOption(name = "Money per Hour", desc = "") + @Accordion + public MoneyPerHourConfig moneyPerHours = new MoneyPerHourConfig(); + + @Expose + @ConfigOption(name = "Next Jacob's Contest", desc = "") + @Accordion + public NextJacobContestConfig nextJacobContests = new NextJacobContestConfig(); + + @Expose + @ConfigOption(name = "Farming Armor Drops", desc = "") + + @Accordion + public FarmingArmorDropsConfig farmingArmorDrop = new FarmingArmorDropsConfig(); + + @Expose + @ConfigOption(name = "Anita Shop", desc = "") + @Accordion + public AnitaShopConfig anitaShop = new AnitaShopConfig(); + + @Expose + @Category(name = "Composter", desc = "Composter Settings") + public ComposterConfig composters = new ComposterConfig(); + + @Expose + @Category(name = "Pests", desc = "Pests Settings") + public PestsConfig pests = new PestsConfig(); + + @Expose + @ConfigOption(name = "Farming Fortune Display", desc = "") + @Accordion + public FarmingFortuneConfig farmingFortunes = new FarmingFortuneConfig(); + + @Expose + @ConfigOption(name = "Tooltip Tweaks", desc = "") + @Accordion + public TooltipTweaksConfig tooltipTweak = new TooltipTweaksConfig(); + + @Expose + @ConfigOption(name = "Yaw and Pitch", desc = "") + @Accordion + public YawPitchDisplayConfig yawPitchDisplay = new YawPitchDisplayConfig(); + + @Expose + @ConfigOption(name = "Crop Start Location", desc = "") + @Accordion + public CropStartLocationConfig cropStartLocation = new CropStartLocationConfig(); + + @Expose + @ConfigOption(name = "Garden Plot Icon", desc = "") + @Accordion + public PlotIconConfig plotIcon = new PlotIconConfig(); + + @Expose + @ConfigOption(name = "Garden Commands", desc = "") + @Accordion + public GardenCommandsConfig gardenCommands = new GardenCommandsConfig(); + + @Expose + @ConfigOption(name = "Plot Price", desc = "Show the price of the plot in coins when inside the Configure Plots inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean plotPrice = true; + + @Expose + @ConfigOption(name = "Desk in Menu", desc = "Show a Desk button in the SkyBlock Menu. Opens the /desk command on click.") + @ConfigEditorBoolean + @FeatureToggle + public boolean deskInSkyBlockMenu = true; + + @Expose + @ConfigOption(name = "Fungi Cutter Warning", desc = "Warn when breaking mushroom with the wrong Fungi Cutter mode.") + @ConfigEditorBoolean + @FeatureToggle + public boolean fungiCutterWarn = true; + + @Expose + @ConfigOption(name = "Burrowing Spores", desc = "Show a notification when a Burrowing Spores spawns while farming mushrooms.") + @ConfigEditorBoolean + @FeatureToggle + public boolean burrowingSporesNotification = true; + + @Expose + @ConfigOption(name = "Wild Strawberry", desc = "Show a notification when a Wild Strawberry Dye drops while farming.") + @ConfigEditorBoolean + @FeatureToggle + public boolean wildStrawberryDyeNotification = true; + + @Expose + @ConfigOption( + name = "FF for Contest", + desc = "Show the minimum needed Farming Fortune for reaching each medal in Jacob's Farming Contest inventory." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean farmingFortuneForContest = true; + + @Expose + public Position farmingFortuneForContestPos = new Position(180, 156, false, true); + + @Expose + @ConfigOption( + name = "Contest Time Needed", + desc = "Show the time and missing FF for every crop inside Jacob's Farming Contest inventory." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean jacobContextTimes = true; + + @Expose + @ConfigOption( + name = "Custom BPS", + desc = "Use custom Blocks per Second value in some GUIs instead of the real one." + ) + @ConfigEditorBoolean + public boolean jacobContestCustomBps = true; + + // TODO moulconfig runnable support + @Expose + @ConfigOption(name = "Custom BPS Value", desc = "Set a custom Blocks per Second value.") + @ConfigEditorSlider( + minValue = 15, + maxValue = 20, + minStep = 0.1f + ) + public double jacobContestCustomBpsValue = 19.9; + + @Expose + public Position jacobContextTimesPos = new Position(-359, 149, false, true); + + @Expose + @ConfigOption( + name = "Contest Summary", + desc = "Show the average Blocks Per Second and blocks clicked at the end of a Jacob Farming Contest in chat." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean jacobContestSummary = true; + + @Expose + @ConfigOption(name = "Always Finnegan", desc = "Forcefully set the Finnegan Farming Simulator perk to be active. This is useful if the auto mayor detection fails.") + @ConfigEditorBoolean + public boolean forcefullyEnabledAlwaysFinnegan = false; + + @Expose + public Position cropSpeedMeterPos = new Position(278, -236, false, true); + + @Expose + @ConfigOption(name = "Enable Plot Borders", desc = "Enable the use of F3 + G hotkey to show Garden plot borders. Similar to how later Minecraft version render chunk borders.") + @ConfigEditorBoolean + @FeatureToggle + public boolean plotBorders = true; + + @Expose + @ConfigOption(name = "Plot Name in Scoreboard", desc = "Showing a more compact plot name in scoreboard. Updates faster and doesnt hide when pests are spawned.") + @ConfigEditorBoolean + @FeatureToggle + public boolean plotNameInScoreboard = true; + + @Expose + @ConfigOption(name = "Copy Milestone Data", desc = "Copy wrong crop milestone data in clipboard when opening the crop milestone menu. Please share this data in SkyHanni discord.") + @ConfigEditorBoolean + @FeatureToggle + public boolean copyMilestoneData = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/GardenLevelConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/GardenLevelConfig.java new file mode 100644 index 000000000000..07f330dcd78b --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/GardenLevelConfig.java @@ -0,0 +1,18 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class GardenLevelConfig { + @Expose + @ConfigOption(name = "Display", desc = "Show the current Garden level and progress to the next level.") + @ConfigEditorBoolean + @FeatureToggle + public boolean display = true; + + @Expose + public Position pos = new Position(390, 40, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/KeyBindConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/KeyBindConfig.java new file mode 100644 index 000000000000..c016cac7c3dc --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/KeyBindConfig.java @@ -0,0 +1,87 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorButton; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import net.minecraft.client.Minecraft; +import org.lwjgl.input.Keyboard; + +public class KeyBindConfig { + @Expose + @ConfigOption(name = "Enabled", desc = "Use custom keybinds while holding a farming tool or Daedalus Axe in the hand.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @ConfigOption(name = "Disable All", desc = "Disable all keys.") + @ConfigEditorButton(buttonText = "Disable") + public Runnable presetDisable = () -> { + attack = Keyboard.KEY_NONE; + useItem = Keyboard.KEY_NONE; + left = Keyboard.KEY_NONE; + right = Keyboard.KEY_NONE; + forward = Keyboard.KEY_NONE; + back = Keyboard.KEY_NONE; + jump = Keyboard.KEY_NONE; + sneak = Keyboard.KEY_NONE; + + Minecraft.getMinecraft().thePlayer.closeScreen(); + }; + + @ConfigOption(name = "Set Default", desc = "Reset all keys to default.") + @ConfigEditorButton(buttonText = "Default") + public Runnable presetDefault = () -> { + attack = -100; + useItem = -99; + left = Keyboard.KEY_A; + right = Keyboard.KEY_D; + forward = Keyboard.KEY_W; + back = Keyboard.KEY_S; + jump = Keyboard.KEY_SPACE; + sneak = Keyboard.KEY_LSHIFT; + Minecraft.getMinecraft().thePlayer.closeScreen(); + }; + + @Expose + @ConfigOption(name = "Attack", desc = "") + @ConfigEditorKeybind(defaultKey = -100) + public int attack = -100; + + @Expose + @ConfigOption(name = "Use Item", desc = "") + @ConfigEditorKeybind(defaultKey = -99) + public int useItem = -99; + + @Expose + @ConfigOption(name = "Move Left", desc = "") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_A) + public int left = Keyboard.KEY_A; + + @Expose + @ConfigOption(name = "Move Right", desc = "") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_D) + public int right = Keyboard.KEY_D; + + @Expose + @ConfigOption(name = "Move Forward", desc = "") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_W) + public int forward = Keyboard.KEY_W; + + @Expose + @ConfigOption(name = "Move Back", desc = "") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_S) + public int back = Keyboard.KEY_S; + + @Expose + @ConfigOption(name = "Jump", desc = "") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_SPACE) + public int jump = Keyboard.KEY_SPACE; + + @Expose + @ConfigOption(name = "Sneak", desc = "") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_LSHIFT) + public int sneak = Keyboard.KEY_LSHIFT; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/MoneyPerHourConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/MoneyPerHourConfig.java new file mode 100644 index 000000000000..77c9eddc2753 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/MoneyPerHourConfig.java @@ -0,0 +1,160 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.HasLegacyId; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import static at.hannibal2.skyhanni.config.features.garden.MoneyPerHourConfig.CustomFormatEntry.INSTANT_SELL; +import static at.hannibal2.skyhanni.config.features.garden.MoneyPerHourConfig.CustomFormatEntry.NPC_PRICE; +import static at.hannibal2.skyhanni.config.features.garden.MoneyPerHourConfig.CustomFormatEntry.SELL_OFFER; + +public class MoneyPerHourConfig { + @Expose + @ConfigOption(name = "Show Money per Hour", + desc = "Displays the money per hour YOU get with YOUR crop/minute value when selling the item to bazaar. " + + "Supports Bountiful, Mushroom Cow Perk, Armor Crops and Dicer Drops. Their toggles are below.") + @ConfigEditorBoolean + @FeatureToggle + public boolean display = true; + + // TODO moulconfig runnable support + @Expose + @ConfigOption(name = "Only Show Top", desc = "Only show the best # items.") + @ConfigEditorSlider( + minValue = 1, + maxValue = 25, + minStep = 1 + ) + public int showOnlyBest = 5; + + @Expose + @ConfigOption(name = "Extend Top List", desc = "Add current crop to the list if its lower ranked than the set limit by extending the list.") + @ConfigEditorBoolean + public boolean showCurrent = true; + + // TODO moulconfig runnable support + @Expose + @ConfigOption( + name = "Always On", + desc = "Always show the money/hour Display while in the garden.") + @ConfigEditorBoolean + public boolean alwaysOn = false; + + @Expose + @ConfigOption( + name = "Compact Mode", + desc = "Hide the item name and the position number.") + @ConfigEditorBoolean + public boolean compact = false; + + @Expose + @ConfigOption( + name = "Compact Price", + desc = "Show the price more compact.") + @ConfigEditorBoolean + public boolean compactPrice = false; + + @Expose + @ConfigOption( + name = "Use Custom", + desc = "Use the custom format below instead of classic ➜ §eSell Offer §7and other profiles ➜ §eNPC Price.") + @ConfigEditorBoolean + public boolean useCustomFormat = false; + + @Expose + @ConfigOption( + name = "Custom Format", + desc = "Set what prices to show") + @ConfigEditorDraggableList( + requireNonEmpty = true + ) + public List customFormat = new ArrayList<>(Arrays.asList( + SELL_OFFER, + INSTANT_SELL, + NPC_PRICE + )); + + public enum CustomFormatEntry implements HasLegacyId { + SELL_OFFER("§eSell Offer", 0), + INSTANT_SELL("§eInstant Sell", 1), + NPC_PRICE("§eNPC Price", 2), + ; + + private final String str; + private final int legacyId; + + CustomFormatEntry(String str, int legacyId) { + this.str = str; + this.legacyId = legacyId; + } + + // Constructor if new enum elements are added post-migration + CustomFormatEntry(String str) { + this(str, -1); + } + + @Override + public int getLegacyId() { + return legacyId; + } + + @Override + public String toString() { + return str; + } + } + + @Expose + @ConfigOption( + name = "Merge Seeds", + desc = "Merge the seeds price with the wheat price.") + @ConfigEditorBoolean + public boolean mergeSeeds = true; + + @Expose + @ConfigOption( + name = "Include Bountiful", + desc = "Includes the coins from Bountiful in the calculation.") + @ConfigEditorBoolean + public boolean bountiful = true; + + @Expose + @ConfigOption( + name = "Include Mooshroom Cow", + desc = "Includes the coins you get from selling the mushrooms from your Mooshroom Cow pet.") + @ConfigEditorBoolean + public boolean mooshroom = true; + + @Expose + @ConfigOption( + name = "Include Armor Drops", + desc = "Includes the average coins/hr from your armor.") + @ConfigEditorBoolean + public boolean armor = true; + + @Expose + @ConfigOption( + name = "Include Dicer Drops", + desc = "Includes the average coins/hr from your melon or pumpkin dicer.") + @ConfigEditorBoolean + public boolean dicer = true; + + @Expose + @ConfigOption( + name = "Hide Title", + desc = "Hides the first line of 'Money Per Hour' entirely.") + @ConfigEditorBoolean + public boolean hideTitle = false; + + @Expose + public Position pos = new Position(-330, 170, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/NextJacobContestConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/NextJacobContestConfig.java new file mode 100644 index 000000000000..b17f312797e8 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/NextJacobContestConfig.java @@ -0,0 +1,59 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class NextJacobContestConfig { + @Expose + @ConfigOption(name = "Show Jacob's Contest", desc = "Show the current or next Jacob's farming contest time and crops.") + @ConfigEditorBoolean + @FeatureToggle + public boolean display = true; + + @Expose + @ConfigOption(name = "Outside Garden", desc = "Show the timer not only in the Garden but everywhere in SkyBlock.") + @ConfigEditorBoolean + public boolean everywhere = false; + + @Expose + @ConfigOption(name = "In Other Guis", desc = "Mark the current or next Farming Contest crops in other farming GUIs as underlined.") + @ConfigEditorBoolean + public boolean otherGuis = false; + + @Expose + @ConfigOption(name = "Fetch Contests", desc = "Automatically fetch Contests from elitebot.dev for the current year if they're uploaded already.") + @ConfigEditorBoolean + public boolean fetchAutomatically = true; + + @Expose + @ConfigOption(name = "Share Contests", desc = "Share the list of upcoming Contests to elitebot.dev for everyone else to then fetch automatically.") + @ConfigEditorDropdown(values = {"Ask When Needed", "Share Automatically", "Disabled"}) + public int shareAutomatically = 0; + + @Expose + @ConfigOption(name = "Warning", desc = "Show a warning shortly before a new Jacob's Contest starts.") + @ConfigEditorBoolean + public boolean warn = false; + + @Expose + @ConfigOption(name = "Warning Time", desc = "Set the warning time in seconds before a Jacob's Contest begins.") + @ConfigEditorSlider( + minValue = 10, + maxValue = 60 * 5, + minStep = 1 + ) + public int warnTime = 60 * 2; + + @Expose + @ConfigOption(name = "Popup Warning", desc = "Opens a popup when the warning time is reached and Minecraft is not in focus.") + @ConfigEditorBoolean + public boolean warnPopup = false; + + @Expose + public Position pos = new Position(-200, 10, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/NumbersConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/NumbersConfig.java new file mode 100644 index 000000000000..106af45c84b0 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/NumbersConfig.java @@ -0,0 +1,32 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class NumbersConfig { + @Expose + @ConfigOption(name = "Crop Milestone", desc = "Show the number of crop milestones in the inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean cropMilestone = true; + + @Expose + @ConfigOption(name = "Average Milestone", desc = "Show the average crop milestone in the crop milestone inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean averageCropMilestone = true; + + @Expose + @ConfigOption(name = "Crop Upgrades", desc = "Show the number of upgrades in the crop upgrades inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean cropUpgrades = true; + + @Expose + @ConfigOption(name = "Composter Upgrades", desc = "Show the number of upgrades in the Composter upgrades inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean composterUpgrades = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/PlotIconConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/PlotIconConfig.java new file mode 100644 index 000000000000..cb47862a2cef --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/PlotIconConfig.java @@ -0,0 +1,24 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.features.garden.inventory.GardenPlotIcon; +import at.hannibal2.skyhanni.utils.LorenzUtils; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorButton; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class PlotIconConfig { + @Expose + @ConfigOption(name = "Enable", desc = "Enable icon replacement in the Configure Plots menu.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @ConfigOption(name = "Hard Reset", desc = "Reset every slot to its original item.") + @ConfigEditorButton(buttonText = "Reset") + public Runnable hardReset = () -> { + GardenPlotIcon.INSTANCE.setHardReset(true); + LorenzUtils.INSTANCE.sendCommandToServer("desk"); + }; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/SkyMartConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/SkyMartConfig.java new file mode 100644 index 000000000000..65eeea93eeb8 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/SkyMartConfig.java @@ -0,0 +1,29 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class SkyMartConfig { + @Expose + @ConfigOption(name = "Copper Price", desc = "Show copper to coin prices inside the SkyMart inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean copperPrice = true; + + @Expose + @ConfigOption(name = "Advanced Stats", desc = "Show the BIN price and copper price for every item.") + @ConfigEditorBoolean + public boolean copperPriceAdvancedStats = false; + + @Expose + @ConfigOption(name = "Item Scale", desc = "Change the size of the items.") + @ConfigEditorSlider(minValue = 0.3f, maxValue = 5, minStep = 0.1f) + public double itemScale = 1.7; + + @Expose + public Position copperPricePos = new Position(211, 132, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/TooltipTweaksConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/TooltipTweaksConfig.java new file mode 100644 index 000000000000..560fcaaa708b --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/TooltipTweaksConfig.java @@ -0,0 +1,47 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +public class TooltipTweaksConfig { + @Expose + @ConfigOption( + name = "Compact Descriptions", + desc = "Hides redundant parts of reforge descriptions, generic counter description, and Farmhand perk explanation." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean compactToolTooltips = false; + + @Expose + @ConfigOption( + name = "Breakdown Hotkey", + desc = "When the keybind is pressed, show a breakdown of all fortune sources on a tool." + ) + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_LSHIFT) + public int fortuneTooltipKeybind = Keyboard.KEY_LSHIFT; + + @Expose + @ConfigOption( + name = "Tooltip Format", + desc = "Show crop-specific Farming Fortune in tooltip.\n" + + "§fShow: §7Crop-specific Fortune indicated as §6[+196]\n" + + "§fReplace: §7Edits the total Fortune to include crop-specific Fortune." + ) + @ConfigEditorDropdown(values = {"Default", "Show", "Replace"}) + public int cropTooltipFortune = 1; + + @Expose + @ConfigOption( + name = "Total Crop Milestone", + desc = "Shows the progress bar till maxed crop milestone in the crop milestone inventory." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean cropMilestoneTotalProgress = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/YawPitchDisplayConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/YawPitchDisplayConfig.java new file mode 100644 index 000000000000..dd7997fba320 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/YawPitchDisplayConfig.java @@ -0,0 +1,64 @@ +package at.hannibal2.skyhanni.config.features.garden; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class YawPitchDisplayConfig { + + @Expose + @ConfigOption(name = "Enable", desc = "Displays yaw and pitch while holding a farming tool. Automatically fades out if there is no movement.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Yaw Precision", desc = "Yaw precision up to specified decimal.") + @ConfigEditorSlider( + minValue = 1, + maxValue = 10, + minStep = 1 + ) + public int yawPrecision = 4; + + @Expose + @ConfigOption(name = "Pitch Precision", desc = "Pitch precision up to specified decimal.") + @ConfigEditorSlider( + minValue = 1, + maxValue = 10, + minStep = 1 + ) + public int pitchPrecision = 4; + + @Expose + @ConfigOption(name = "Display Timeout", desc = "Duration in seconds for which the overlay is being displayed after moving.") + @ConfigEditorSlider( + minValue = 1, + maxValue = 20, + minStep = 1 + ) + public int timeout = 5; + + @Expose + @ConfigOption(name = "Show Without Tool", desc = "Does not require you to hold a tool for the overlay to show.") + @ConfigEditorBoolean + public boolean showWithoutTool = false; + + @Expose + @ConfigOption(name = "Show Outside Garden", desc = "The overlay will work outside of the Garden.") + @ConfigEditorBoolean + public boolean showEverywhere = false; + + @Expose + @ConfigOption(name = "Ignore Timeout", desc = "Ignore the timeout after not moving mouse.") + @ConfigEditorBoolean + public boolean showAlways = false; + + @Expose + public Position pos = new Position(445, 225, false, true); + @Expose + public Position posOutside = new Position(445, 225, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/composter/ComposterConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/composter/ComposterConfig.java new file mode 100644 index 000000000000..700c4fc49c35 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/composter/ComposterConfig.java @@ -0,0 +1,108 @@ +package at.hannibal2.skyhanni.config.features.garden.composter; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ComposterConfig { + @Expose + @ConfigOption( + name = "Composter Overlay", + desc = "Show organic matter, fuel, and profit prices while inside the Composter Inventory." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean overlay = true; + + @Expose + @ConfigOption(name = "Overlay Price", desc = "Toggle for Bazaar 'buy order' vs 'instant buy' price in composter overlay.") + @ConfigEditorDropdown(values = {"Instant Buy", "Buy Order"}) + public int overlayPriceType = 0; + + @Expose + @ConfigOption(name = "Retrieve From", desc = "Change where to retrieve the materials from in the composter overlay: The Bazaar or Sacks.") + @ConfigEditorDropdown(values = {"Bazaar", "Sacks"}) + public int retrieveFrom = 0; + + @Expose + public Position overlayOrganicMatterPos = new Position(140, 152, false, true); + + @Expose + public Position overlayFuelExtrasPos = new Position(-320, 152, false, true); + + @Expose + @ConfigOption( + name = "Display Element", + desc = "Displays the Compost data from the tab list as GUI element." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean displayEnabled = true; + + @Expose + @ConfigOption( + name = "Outside Garden", + desc = "Show Time till Composter is empty outside Garden" + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean displayOutsideGarden = false; + + @Expose + @ConfigOption( + name = "Composter Warning", + desc = "Warn when the Composter gets close to empty, even outside Garden." + ) + @ConfigEditorBoolean + public boolean warnAlmostClose = false; + + @Expose + @ConfigOption( + name = "Upgrade Price", + desc = "Show the price for the Composter Upgrade in the lore." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean upgradePrice = true; + + @Expose + @ConfigOption( + name = "Round Amount Needed", + desc = "Rounds the amount needed to fill your Composter down so that you don't overspend." + ) + @ConfigEditorBoolean + public boolean roundDown = true; + + @Expose + @ConfigOption( + name = "Highlight Upgrade", + desc = "Highlight Upgrades that can be bought right now." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightUpgrade = true; + + @Expose + @ConfigOption( + name = "Inventory Numbers", + desc = "Show the amount of Organic Matter, Fuel and Composts Available while inside the Composter Inventory." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean inventoryNumbers = true; + + @Expose + @ConfigOption(name = "Notification When Low Composter", desc = "") + @Accordion + public NotifyLowConfig notifyLow = new NotifyLowConfig(); + + @Expose + public Position displayPos = new Position(-390, 10, false, true); + + @Expose + public Position outsideGardenPos = new Position(-363, 13, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/composter/NotifyLowConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/composter/NotifyLowConfig.java new file mode 100644 index 000000000000..a854fa6a9041 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/composter/NotifyLowConfig.java @@ -0,0 +1,38 @@ +package at.hannibal2.skyhanni.config.features.garden.composter; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class NotifyLowConfig { + @Expose + @ConfigOption(name = "Enable", desc = "Show a notification when Organic Matter or Fuel runs low in your Composter.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Show Title", desc = "Send a title to notify.") + @ConfigEditorBoolean + public boolean title = false; + + @Expose + @ConfigOption(name = "Min Organic Matter", desc = "Warn when Organic Matter is below this value.") + @ConfigEditorSlider( + minValue = 1_000, + maxValue = 80_000, + minStep = 1 + ) + public int organicMatter = 20_000; + + @Expose + @ConfigOption(name = "Min Fuel Cap", desc = "Warn when Fuel is below this value.") + @ConfigEditorSlider( + minValue = 500, + maxValue = 40_000, + minStep = 1 + ) + public int fuel = 10_000; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/cropmilestones/CropMilestonesConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/cropmilestones/CropMilestonesConfig.java new file mode 100644 index 000000000000..8f2d5a4509a3 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/cropmilestones/CropMilestonesConfig.java @@ -0,0 +1,173 @@ +package at.hannibal2.skyhanni.config.features.garden.cropmilestones; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.HasLegacyId; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import io.github.moulberry.moulconfig.observer.Property; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import static at.hannibal2.skyhanni.config.features.garden.cropmilestones.CropMilestonesConfig.MilestoneTextEntry.BLOCKS_PER_SECOND; +import static at.hannibal2.skyhanni.config.features.garden.cropmilestones.CropMilestonesConfig.MilestoneTextEntry.CROPS_PER_MINUTE; +import static at.hannibal2.skyhanni.config.features.garden.cropmilestones.CropMilestonesConfig.MilestoneTextEntry.MILESTONE_TIER; +import static at.hannibal2.skyhanni.config.features.garden.cropmilestones.CropMilestonesConfig.MilestoneTextEntry.NUMBER_OUT_OF_TOTAL; +import static at.hannibal2.skyhanni.config.features.garden.cropmilestones.CropMilestonesConfig.MilestoneTextEntry.TIME; +import static at.hannibal2.skyhanni.config.features.garden.cropmilestones.CropMilestonesConfig.MilestoneTextEntry.TITLE; +import static at.hannibal2.skyhanni.config.features.garden.cropmilestones.CropMilestonesConfig.TimeFormatEntry.YEAR; + +public class CropMilestonesConfig { + @Expose + @ConfigOption( + name = "Progress Display", + desc = "Shows the progress and ETA until the next crop milestone is reached and the current crops/minute value. " + + "§eRequires a tool with either a counter or Cultivating enchantment for full accuracy." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean progress = true; + + @Expose + @ConfigOption( + name = "Warn When Close", + desc = "Warn with title and sound when the next crop milestone upgrade happens in 5 seconds. " + + "Useful for switching to a different pet for leveling.") + @ConfigEditorBoolean + public boolean warnClose = false; + + @Expose + @ConfigOption( + name = "Time Format", + desc = "Change the highest time unit to show (1h30m vs 90min)") + @ConfigEditorDropdown() + public Property highestTimeFormat = Property.of(YEAR); + + public enum TimeFormatEntry implements HasLegacyId { + YEAR("Year", 0), + DAY("Day", 1), + HOUR("Hour", 2), + MINUTE("Minute", 3), + SECOND("Second", 4), + ; + + private final String str; + private final int legacyId; + + TimeFormatEntry(String str, int legacyId) { + this.str = str; + this.legacyId = legacyId; + } + + // Constructor if new enum elements are added post-migration + TimeFormatEntry(String str) { + this(str, -1); + } + + @Override + public int getLegacyId() { + return legacyId; + } + + @Override + public String toString() { + return str; + } + } + + @Expose + @ConfigOption( + name = "Maxed Milestone", + desc = "Calculate the progress and ETA till maxed milestone (46) instead of next milestone.") + @ConfigEditorBoolean + public Property bestShowMaxedNeeded = Property.of(false); + + @Expose + @ConfigOption( + name = "Milestone Text", + desc = "Drag text to change the appearance of the overlay.\n" + + "Hold a farming tool to show the overlay." + ) + @ConfigEditorDraggableList() + public List text = new ArrayList<>(Arrays.asList( + TITLE, + MILESTONE_TIER, + NUMBER_OUT_OF_TOTAL, + TIME, + CROPS_PER_MINUTE, + BLOCKS_PER_SECOND + )); + + public enum MilestoneTextEntry implements HasLegacyId { + TITLE("§6Crop Milestones", 0), + MILESTONE_TIER("§7Pumpkin Tier 22", 1), + NUMBER_OUT_OF_TOTAL("§e12,300§8/§e100,000", 2), + TIME("§7In §b12m 34s", 3), + CROPS_PER_MINUTE("§7Crops/Minute§8: §e12,345", 4), + BLOCKS_PER_SECOND("§7Blocks/Second§8: §e19.85", 5), + PERCENTAGE("§7Percentage: §e12.34%", 6), + ; + + private final String str; + private final int legacyId; + + MilestoneTextEntry(String str, int legacyId) { + this.str = str; + this.legacyId = legacyId; + } + + // Constructor if new enum elements are added post-migration + MilestoneTextEntry(String str) { + this(str, -1); + } + + @Override + public int getLegacyId() { + return legacyId; + } + + @Override + public String toString() { + return str; + } + } + + @Expose + @ConfigOption(name = "Block Broken Precision", desc = "The amount of decimals displayed in blocks/second.") + @ConfigEditorSlider( + minValue = 0, + maxValue = 6, + minStep = 1 + ) + public int blocksBrokenPrecision = 2; + + @Expose + @ConfigOption(name = "Seconds Before Reset", desc = "How many seconds of not farming until blocks/second resets.") + @ConfigEditorSlider( + minValue = 2, + maxValue = 60, + minStep = 1 + ) + public int blocksBrokenResetTime = 5; + + @Expose + public Position progressDisplayPos = new Position(-400, -200, false, true); + + @Expose + @ConfigOption(name = "Best Crop", desc = "") + @Accordion + public NextConfig next = new NextConfig(); + + @Expose + @ConfigOption(name = "Mushroom Pet Perk", desc = "") + @Accordion + public MushroomPetPerkConfig mushroomPetPerk = new MushroomPetPerkConfig(); + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/cropmilestones/MushroomPetPerkConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/cropmilestones/MushroomPetPerkConfig.java new file mode 100644 index 000000000000..2cd4cd91126c --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/cropmilestones/MushroomPetPerkConfig.java @@ -0,0 +1,78 @@ +package at.hannibal2.skyhanni.config.features.garden.cropmilestones; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.HasLegacyId; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import static at.hannibal2.skyhanni.config.features.garden.cropmilestones.MushroomPetPerkConfig.MushroomTextEntry.MUSHROOM_TIER; +import static at.hannibal2.skyhanni.config.features.garden.cropmilestones.MushroomPetPerkConfig.MushroomTextEntry.NUMBER_OUT_OF_TOTAL; +import static at.hannibal2.skyhanni.config.features.garden.cropmilestones.MushroomPetPerkConfig.MushroomTextEntry.TIME; +import static at.hannibal2.skyhanni.config.features.garden.cropmilestones.MushroomPetPerkConfig.MushroomTextEntry.TITLE; + +// TODO moulconfig runnable support +public class MushroomPetPerkConfig { + @Expose + @ConfigOption( + name = "Display Enabled", + desc = "Show the progress and ETA for mushroom crops when farming other crops because of the Mooshroom Cow perk.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption( + name = "Mushroom Text", + desc = "Drag text to change the appearance of the overlay.\n" + + "Hold a farming tool to show the overlay." + ) + @ConfigEditorDraggableList() + public List text = new ArrayList<>(Arrays.asList( + TITLE, + MUSHROOM_TIER, + NUMBER_OUT_OF_TOTAL, + TIME + )); + + public enum MushroomTextEntry implements HasLegacyId { + TITLE("§6Mooshroom Cow Perk", 0), + MUSHROOM_TIER("§7Mushroom Tier 8", 1), + NUMBER_OUT_OF_TOTAL("§e6,700§8/§e15,000", 2), + TIME("§7In §b12m 34s", 3), + PERCENTAGE("§7Percentage: §e12.34%", 4), + ; + + private final String str; + private final int legacyId; + + MushroomTextEntry(String str, int legacyId) { + this.str = str; + this.legacyId = legacyId; + } + + // Constructor if new enum elements are added post-migration + MushroomTextEntry(String str) { + this(str, -1); + } + + @Override + public int getLegacyId() { + return legacyId; + } + + @Override + public String toString() { + return str; + } + } + + @Expose + public Position pos = new Position(-112, -143, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/cropmilestones/NextConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/cropmilestones/NextConfig.java new file mode 100644 index 000000000000..188848e4826b --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/cropmilestones/NextConfig.java @@ -0,0 +1,66 @@ +package at.hannibal2.skyhanni.config.features.garden.cropmilestones; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +// TODO moulconfig runnable support +public class NextConfig { + @Expose + @ConfigOption( + name = "Best Display", + desc = "Lists all crops and their ETA till next milestone. Sorts for best crop for getting garden or SkyBlock levels.") + @ConfigEditorBoolean + @FeatureToggle + public boolean bestDisplay = true; + + // TODO moulconfig runnable support + @Expose + @ConfigOption(name = "Sort Type", desc = "Sort the crops by either garden or SkyBlock EXP.") + @ConfigEditorDropdown(values = {"Garden Exp", "SkyBlock Exp"}) + public int bestType = 0; + + // TODO moulconfig runnable support + @Expose + @ConfigOption(name = "Only Show Top", desc = "Only show the top # crops.") + @ConfigEditorSlider( + minValue = 1, + maxValue = 10, + minStep = 1 + ) + public int showOnlyBest = 10; + + @Expose + @ConfigOption(name = "Extend Top List", desc = "Add current crop to the list if its lower ranked than the set limit by extending the list.") + @ConfigEditorBoolean + public boolean showCurrent = true; + + // TODO moulconfig runnable support + @Expose + @ConfigOption( + name = "Always On", + desc = "Show the Best Display always while in the garden.") + @ConfigEditorBoolean + public boolean bestAlwaysOn = false; + + @Expose + @ConfigOption( + name = "Compact Display", + desc = "A more compact best crop time: Removing the crop name and exp, hide the # number and using a more compact time format.") + @ConfigEditorBoolean + public boolean bestCompact = false; + + @Expose + @ConfigOption( + name = "Hide Title", + desc = "Hides the 'Best Crop Time' line entirely.") + @ConfigEditorBoolean + public boolean bestHideTitle = false; + + @Expose + public Position displayPos = new Position(-200, -200, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/optimalspeed/CustomSpeedConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/optimalspeed/CustomSpeedConfig.java new file mode 100644 index 000000000000..615883c96121 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/optimalspeed/CustomSpeedConfig.java @@ -0,0 +1,79 @@ +package at.hannibal2.skyhanni.config.features.garden.optimalspeed; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class CustomSpeedConfig { + + @Expose + @ConfigOption(name = "Wheat", desc = "Suggested farm speed:\n" + + "§e5 Blocks§7: §f✦ 93 speed\n" + + "§e4 Blocks§7: §f✦ 116 speed") + @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) + public int wheat = 93; + + @Expose + @ConfigOption(name = "Carrot", desc = "Suggested farm speed:\n" + + "§e5 Blocks§7: §f✦ 93 speed\n" + + "§e4 Blocks§7: §f✦ 116 speed") + @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) + public int carrot = 93; + + @Expose + @ConfigOption(name = "Potato", desc = "Suggested farm speed:\n" + + "§e5 Blocks§7: §f✦ 93 speed\n" + + "§e4 Blocks§7: §f✦ 116 speed") + @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) + public int potato = 93; + + @Expose + @ConfigOption(name = "Nether Wart", desc = "Suggested farm speed:\n" + + "§e5 Blocks§7: §f✦ 93 speed\n" + + "§e4 Blocks§7: §f✦ 116 speed") + @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) + public int netherWart = 93; + + @Expose + @ConfigOption(name = "Pumpkin", desc = "Suggested farm speed:\n" + + "§e3 Blocks§7: §f✦ 155 speed\n" + + "§e2 Blocks§7: §f✦ 265 §7or §f400 speed") + @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) + public int pumpkin = 155; + + @Expose + @ConfigOption(name = "Melon", desc = "Suggested farm speed:\n" + + "§e3 Blocks§7: §f✦ 155 speed\n" + + "§e2 Blocks§7: §f✦ 265 or 400 speed") + @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) + public int melon = 155; + + @Expose + @ConfigOption(name = "Cocoa Beans", desc = "Suggested farm speed:\n" + + "§e3 Blocks§7: §f✦ 155 speed\n" + + "§e4 Blocks§7: §f✦ 116 speed") + @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) + public int cocoaBeans = 155; + + // TODO does other speed settings exist? + @Expose + @ConfigOption(name = "Sugar Cane", desc = "Suggested farm speed:\n" + + "§eYaw 45§7: §f✦ 328 speed") + @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) + public int sugarCane = 328; + + @Expose + @ConfigOption(name = "Cactus", desc = "Suggested farm speed:\n" + + "§eNormal§7: §f✦ 400 speed\n" + + "§eRacing Helmet§7: §f✦ 464 speed\n" + + "§eBlack Cat§7: §f✦ 464 speed") + @ConfigEditorSlider(minValue = 1, maxValue = 500, minStep = 1) + public int cactus = 400; + + // TODO does other speed settings exist? + @Expose + @ConfigOption(name = "Mushroom", desc = "Suggested farm speed:\n" + + "§eYaw 60§7: §f✦ 233 speed") + @ConfigEditorSlider(minValue = 1, maxValue = 400, minStep = 1) + public int mushroom = 233; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/optimalspeed/OptimalSpeedConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/optimalspeed/OptimalSpeedConfig.java new file mode 100644 index 000000000000..385d7907f404 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/optimalspeed/OptimalSpeedConfig.java @@ -0,0 +1,39 @@ +package at.hannibal2.skyhanni.config.features.garden.optimalspeed; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class OptimalSpeedConfig { + @Expose + @ConfigOption(name = "Enabled", desc = "Show the optimal speed for your current tool in the hand.\n" + + "(Thanks MelonKingDE for the default values).") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Warning Title", desc = "Warn via title when you don't have the optimal speed.") + @ConfigEditorBoolean + public boolean warning = false; + + @Expose + @ConfigOption(name = "Rancher Boots", desc = "Allows you to set the optimal speed in the Rancher Boots overlay by clicking on the presets.") + @ConfigEditorBoolean + @FeatureToggle + public boolean signEnabled = true; + + @Expose + public Position signPosition = new Position(20, -195, false, true); + + @Expose + @ConfigOption(name = "Custom Speed", desc = "Change the exact speed for every single crop.") + @Accordion + public CustomSpeedConfig customSpeed = new CustomSpeedConfig(); + + @Expose + public Position pos = new Position(5, -200, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/pests/PestFinderConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/pests/PestFinderConfig.java new file mode 100644 index 000000000000..9f4b69d122bd --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/pests/PestFinderConfig.java @@ -0,0 +1,46 @@ +package at.hannibal2.skyhanni.config.features.garden.pests; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +public class PestFinderConfig { + + @Expose + @ConfigOption( + name = "Display", + desc = "Show a display with all know pest locations." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean showDisplay = true; + + @Expose + @ConfigOption( + name = "Show Plot in World", + desc = "Mark infected plot names and world border in the world." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean showPlotInWorld = true; + + @Expose + @ConfigOption( + name = "Only With Vacuum", + desc = "Only show the pest display and waypoints while holding a vacuum in the hand." + ) + @ConfigEditorBoolean + public boolean onlyWithVacuum = true; + + @Expose + public Position position = new Position(-350, 200, 1.3f); + + @Expose + @ConfigOption(name = "Teleport Hotkey", desc = "Press this key to warp to the nearest plot with pests on it.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int teleportHotkey = Keyboard.KEY_NONE; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/pests/PestSpawnConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/pests/PestSpawnConfig.java new file mode 100644 index 000000000000..ba723acfa02e --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/pests/PestSpawnConfig.java @@ -0,0 +1,26 @@ +package at.hannibal2.skyhanni.config.features.garden.pests; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class PestSpawnConfig { + + @Expose + @ConfigOption( + name = "Chat Message Format", + desc = "Change how the pest spawn chat message should be formatted.") + @ConfigEditorDropdown(values = {"Hypixel Style", "Compact", "Disabled"}) + public int chatMessageFormat = 0; + + @Expose + @ConfigOption( + name = "Show Title", + desc = "Show a Title when a pest spawns." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean showTitle = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/pests/PestTimerConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/pests/PestTimerConfig.java new file mode 100644 index 000000000000..43b69b2ef037 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/pests/PestTimerConfig.java @@ -0,0 +1,30 @@ +package at.hannibal2.skyhanni.config.features.garden.pests; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class PestTimerConfig { + + @Expose + @ConfigOption( + name = "Enabled", + desc = "Show the time since the last pest spawned in your garden." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption( + name = "Only With Vacuum", + desc = "Only show the time while holding a vacuum in the hand." + ) + @ConfigEditorBoolean + public boolean onlyWithVacuum = true; + + @Expose + public Position position = new Position(390, 65, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/pests/PestsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/pests/PestsConfig.java new file mode 100644 index 000000000000..94e972dfe57f --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/pests/PestsConfig.java @@ -0,0 +1,28 @@ +package at.hannibal2.skyhanni.config.features.garden.pests; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class PestsConfig { + + @Expose + @ConfigOption(name = "Pest Spawn", desc = "") + @Accordion + public PestSpawnConfig pestSpawn = new PestSpawnConfig(); + + @Expose + @ConfigOption(name = "Pest Finder", desc = "") + @Accordion + public PestFinderConfig pestFinder = new PestFinderConfig(); + + @Expose + @ConfigOption(name = "Pest Timer", desc = "") + @Accordion + public PestTimerConfig pestTimer = new PestTimerConfig(); + + @Expose + @ConfigOption(name = "Spray", desc = "") + @Accordion + public SprayConfig spray = new SprayConfig(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/pests/SprayConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/pests/SprayConfig.java new file mode 100644 index 000000000000..da715712fa61 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/pests/SprayConfig.java @@ -0,0 +1,28 @@ +package at.hannibal2.skyhanni.config.features.garden.pests; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class SprayConfig { + + @Expose + @ConfigOption( + name = "Pest Spray Selector", + desc = "Show the pests that are attracted when changing the selected material of the §aSprayonator§7." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean pestWhenSelector = true; + + @Expose + @ConfigOption(name = "Draw Plot Border", desc = "Draw plots border when holding the Sprayonator.") + @ConfigEditorBoolean + @FeatureToggle + public boolean drawPlotsBorderWhenInHands = true; + + @Expose + public Position position = new Position(315, -200, 2.3f); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/DropsStatisticsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/DropsStatisticsConfig.java new file mode 100644 index 000000000000..6c4b0856f2f8 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/DropsStatisticsConfig.java @@ -0,0 +1,128 @@ +package at.hannibal2.skyhanni.config.features.garden.visitor; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.HasLegacyId; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import static at.hannibal2.skyhanni.config.features.garden.visitor.DropsStatisticsConfig.DropsStatisticsTextEntry.ACCEPTED; +import static at.hannibal2.skyhanni.config.features.garden.visitor.DropsStatisticsConfig.DropsStatisticsTextEntry.COINS_SPENT; +import static at.hannibal2.skyhanni.config.features.garden.visitor.DropsStatisticsConfig.DropsStatisticsTextEntry.COPPER; +import static at.hannibal2.skyhanni.config.features.garden.visitor.DropsStatisticsConfig.DropsStatisticsTextEntry.DEDICATION_IV; +import static at.hannibal2.skyhanni.config.features.garden.visitor.DropsStatisticsConfig.DropsStatisticsTextEntry.DENIED; +import static at.hannibal2.skyhanni.config.features.garden.visitor.DropsStatisticsConfig.DropsStatisticsTextEntry.FARMING_EXP; +import static at.hannibal2.skyhanni.config.features.garden.visitor.DropsStatisticsConfig.DropsStatisticsTextEntry.GREEN_BANDANA; +import static at.hannibal2.skyhanni.config.features.garden.visitor.DropsStatisticsConfig.DropsStatisticsTextEntry.OVERGROWN_GRASS; +import static at.hannibal2.skyhanni.config.features.garden.visitor.DropsStatisticsConfig.DropsStatisticsTextEntry.SPACER_1; +import static at.hannibal2.skyhanni.config.features.garden.visitor.DropsStatisticsConfig.DropsStatisticsTextEntry.TITLE; +import static at.hannibal2.skyhanni.config.features.garden.visitor.DropsStatisticsConfig.DropsStatisticsTextEntry.TOTAL_VISITORS; +import static at.hannibal2.skyhanni.config.features.garden.visitor.DropsStatisticsConfig.DropsStatisticsTextEntry.VISITORS_BY_RARITY; + +public class DropsStatisticsConfig { + + @Expose + @ConfigOption( + name = "Enabled", + desc = "Tallies up statistic about visitors and the rewards you have received from them." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption( + name = "Text Format", + desc = "Drag text to change the appearance of the overlay." + ) + @ConfigEditorDraggableList() + public List textFormat = new ArrayList<>(Arrays.asList( + TITLE, + TOTAL_VISITORS, + VISITORS_BY_RARITY, + ACCEPTED, + DENIED, + SPACER_1, + COPPER, + FARMING_EXP, + COINS_SPENT, + OVERGROWN_GRASS, + GREEN_BANDANA, + DEDICATION_IV + )); + + public enum DropsStatisticsTextEntry implements HasLegacyId { + TITLE("§e§lVisitor Statistics", 0), + TOTAL_VISITORS("§e1,636 Total", 1), + VISITORS_BY_RARITY("§a1,172§f-§9382§f-§681§f-§d2§f-§c1", 2), + ACCEPTED("§21,382 Accepted", 3), + DENIED("§c254 Denied", 4), + SPACER_1(" ", 5), + COPPER("§c62,072 Copper", 6), + FARMING_EXP("§33.2m Farming EXP", 7), + COINS_SPENT("§647.2m Coins Spent", 8), + FLOWERING_BOUQUET("§b23 §9Flowering Bouquet", 9), + OVERGROWN_GRASS("§b4 §9Overgrown Grass", 10), + GREEN_BANDANA("§b2 §5Green Bandana", 11), + DEDICATION_IV("§b1 §9Dedication IV", 12), + MUSIC_RUNE_I("§b6 §b◆ Music Rune I", 13), + SPACE_HELMET("§b1 §cSpace Helmet", 14), + CULTIVATING_I("§b1 §9Cultivating I", 15), + REPLENISH_I("§b1 §9Replenish I", 16), + SPACER_2(" ", 17), + GARDEN_EXP("§212,600 Garden EXP", 18), + BITS("§b4.2k Bits", 19), + MITHRIL_POWDER("§220k Mithril Powder", 20), + GEMSTONE_POWDER("§d18k Gemstone Powder", 21), + ; + + private final String str; + private final int legacyId; + + DropsStatisticsTextEntry(String str, int legacyId) { + this.str = str; + this.legacyId = legacyId; + } + + // Constructor if new enum elements are added post-migration + DropsStatisticsTextEntry(String str) { + this(str, -1); + } + + @Override + public int getLegacyId() { + return legacyId; + } + + @Override + public String toString() { + return str; + } + } + + @Expose + @ConfigOption(name = "Display Numbers First", desc = "Determines whether the number or drop name displays first. " + + "§eNote: Will not update the preview above!") + @ConfigEditorBoolean + public boolean displayNumbersFirst = true; + + @Expose + @ConfigOption(name = "Display Icons", desc = "Replaces the drop names with icons. " + + "§eNote: Will not update the preview above!") + @ConfigEditorBoolean + public boolean displayIcons = false; + + @Expose + @ConfigOption(name = "Only on Barn Plot", desc = "Only shows the overlay while on the Barn plot.") + @ConfigEditorBoolean + public boolean onlyOnBarn = true; + + @Expose + public Position pos = new Position(5, 20, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/InventoryConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/InventoryConfig.java new file mode 100644 index 000000000000..5c671d4e7967 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/InventoryConfig.java @@ -0,0 +1,37 @@ +package at.hannibal2.skyhanni.config.features.garden.visitor; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class InventoryConfig { + @Expose + @ConfigOption(name = "Visitor Price", desc = "Show the Bazaar price of the items required for the visitors, like in NEU.") + @ConfigEditorBoolean + @FeatureToggle + public boolean showPrice = false; + + @Expose + @ConfigOption(name = "Amount and Time", desc = "Show the exact item amount and the remaining time when farmed manually. Especially useful for Ironman.") + @ConfigEditorBoolean + public boolean exactAmountAndTime = true; + + @Expose + @ConfigOption(name = "Copper Price", desc = "Show the price per copper inside the visitor GUI.") + @ConfigEditorBoolean + @FeatureToggle + public boolean copperPrice = true; + + @Expose + @ConfigOption(name = "Copper Time", desc = "Show the time required per copper inside the visitor GUI.") + @ConfigEditorBoolean + @FeatureToggle + public boolean copperTime = false; + + @Expose + @ConfigOption(name = "Garden Exp Price", desc = "Show the price per garden experience inside the visitor GUI.") + @ConfigEditorBoolean + @FeatureToggle + public boolean experiencePrice = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/NeedsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/NeedsConfig.java new file mode 100644 index 000000000000..b60b6207f7ea --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/NeedsConfig.java @@ -0,0 +1,40 @@ +package at.hannibal2.skyhanni.config.features.garden.visitor; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class NeedsConfig { + @Expose + @ConfigOption(name = "Items Needed", desc = "Show all items needed for the visitors.") + @ConfigEditorBoolean + @FeatureToggle + public boolean display = true; + + @Expose + public Position pos = new Position(180, 170, false, true); + + @Expose + @ConfigOption(name = "Only when Close", desc = "Only show the needed items when close to the visitors.") + @ConfigEditorBoolean + public boolean onlyWhenClose = false; + + @Expose + @ConfigOption(name = "Bazaar Alley", desc = "Show the Visitor Items List while inside the Bazaar Alley in the Hub. " + + "This helps buying the correct amount when not having a Booster Cookie Buff active.") + @ConfigEditorBoolean + public boolean inBazaarAlley = true; + + @Expose + @ConfigOption(name = "Show Price", desc = "Show the coin price in the items needed list.") + @ConfigEditorBoolean + public boolean showPrice = true; + + @Expose + @ConfigOption(name = "Item Preview", desc = "Show the base type for the required items next to new visitors. §cNote that some visitors may require any crop.") + @ConfigEditorBoolean + @FeatureToggle + public boolean itemPreview = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/RewardWarningConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/RewardWarningConfig.java new file mode 100644 index 000000000000..bd3f158ffa33 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/RewardWarningConfig.java @@ -0,0 +1,112 @@ +package at.hannibal2.skyhanni.config.features.garden.visitor; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.HasLegacyId; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import static at.hannibal2.skyhanni.config.features.garden.visitor.RewardWarningConfig.ItemWarnEntry.CULTIVATING_I; +import static at.hannibal2.skyhanni.config.features.garden.visitor.RewardWarningConfig.ItemWarnEntry.DEDICATION_IV; +import static at.hannibal2.skyhanni.config.features.garden.visitor.RewardWarningConfig.ItemWarnEntry.GREEN_BANDANA; +import static at.hannibal2.skyhanni.config.features.garden.visitor.RewardWarningConfig.ItemWarnEntry.MUSIC_RUNE; +import static at.hannibal2.skyhanni.config.features.garden.visitor.RewardWarningConfig.ItemWarnEntry.OVERGROWN_GRASS; +import static at.hannibal2.skyhanni.config.features.garden.visitor.RewardWarningConfig.ItemWarnEntry.SPACE_HELMET; + +public class RewardWarningConfig { + + @Expose + @ConfigOption(name = "Notify in Chat", desc = "Send a chat message once you talk to a visitor with reward.") + @ConfigEditorBoolean + @FeatureToggle + public boolean notifyInChat = true; + + @Expose + @ConfigOption(name = "Show over Name", desc = "Show the reward name above the visitor name.") + @ConfigEditorBoolean + @FeatureToggle + public boolean showOverName = true; + + @Expose + @ConfigOption(name = "Prevent Refusing", desc = "Prevent the refusal of a visitor with reward.") + @ConfigEditorBoolean + @FeatureToggle + public boolean preventRefusing = true; + + @Expose + @ConfigOption(name = "Bypass Key", desc = "Hold that key to bypass the Prevent Refusing feature.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int bypassKey = Keyboard.KEY_NONE; + + + /** + * Sync up with {at.hannibal2.skyhanni.features.garden.visitor.VisitorReward} + */ + @Expose + @ConfigOption( + name = "Items", + desc = "Warn for these reward items." + ) + @ConfigEditorDraggableList( + exampleText = { + "§9Flowering Bouquet", + "§9Overgrown Grass", + "§9Green Bandana", + "§9Dedication IV", + "§9Music Rune", + "§cSpace Helmet", + "§9Cultivating I", + "§9Replenish I", + } + ) + public List drops = new ArrayList<>(Arrays.asList( + OVERGROWN_GRASS, + GREEN_BANDANA, + DEDICATION_IV, + MUSIC_RUNE, + SPACE_HELMET, + CULTIVATING_I + )); + + public enum ItemWarnEntry implements HasLegacyId { + FLOWERING_BOUQUET("§9Flowering Bouquet", 0), + OVERGROWN_GRASS("§9Overgrown Grass", 1), + GREEN_BANDANA("§9Green Bandana", 2), + DEDICATION_IV("§9Dedication IV", 3), + MUSIC_RUNE("§9Music Rune", 4), + SPACE_HELMET("§cSpace Helmet", 5), + CULTIVATING_I("§9Cultivating I", 6), + REPLENISH_I("§9Replenish I", 7), + ; + + private final String str; + private final int legacyId; + + ItemWarnEntry(String str, int legacyId) { + this.str = str; + this.legacyId = legacyId; + } + + // Constructor if new enum elements are added post-migration + ItemWarnEntry(String str) { + this(str, -1); + } + + @Override + public int getLegacyId() { + return legacyId; + } + + @Override + public String toString() { + return str; + } + } +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/TimerConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/TimerConfig.java new file mode 100644 index 000000000000..d85f7d04883c --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/TimerConfig.java @@ -0,0 +1,37 @@ +package at.hannibal2.skyhanni.config.features.garden.visitor; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class TimerConfig { + @Expose + @ConfigOption(name = "Visitor Timer", desc = "Timer when the next visitor will appear, " + + "and a number for how many visitors are already waiting.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Sixth Visitor Estimate", desc = "Estimate when the sixth visitor in the queue will arrive. " + + "May be inaccurate with co-op members farming simultaneously.") + @ConfigEditorBoolean + public boolean sixthVisitorEnabled = true; + + @Expose + @ConfigOption(name = "Sixth Visitor Warning", desc = "Notifies when it is believed that the sixth visitor has arrived. " + + "May be inaccurate with co-op members farming simultaneously.") + @ConfigEditorBoolean + public boolean sixthVisitorWarning = true; + + @Expose + @ConfigOption(name = "New Visitor Ping", desc = "Pings you when you are less than 10 seconds away from getting a new visitor. " + + "§eUseful for getting Ephemeral Gratitudes during the 2023 Halloween event.") + @ConfigEditorBoolean + public boolean newVisitorPing = false; + + @Expose + public Position pos = new Position(390, 65, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/VisitorConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/VisitorConfig.java new file mode 100644 index 000000000000..1a1883516f99 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/garden/visitor/VisitorConfig.java @@ -0,0 +1,118 @@ +package at.hannibal2.skyhanni.config.features.garden.visitor; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +public class VisitorConfig { + @Expose + @ConfigOption(name = "Visitor Timer", desc = "") + @Accordion + public TimerConfig timer = new TimerConfig(); + + @Expose + @ConfigOption(name = "Visitor Items Needed", desc = "") + @Accordion + public NeedsConfig needs = new NeedsConfig(); + + @Expose + @ConfigOption(name = "Visitor Inventory", desc = "") + @Accordion + public InventoryConfig inventory = new InventoryConfig(); + + @Expose + @ConfigOption(name = "Visitor Reward Warning", desc = "") + @Accordion + public RewardWarningConfig rewardWarning = new RewardWarningConfig(); + + @Expose + @ConfigOption(name = "Notification Chat", desc = "Show in chat when a new visitor is visiting your island.") + @ConfigEditorBoolean + @FeatureToggle + public boolean notificationChat = true; + + @Expose + @ConfigOption(name = "Notification Title", desc = "Show a title when a new visitor is visiting your island.") + @ConfigEditorBoolean + @FeatureToggle + public boolean notificationTitle = true; + + @Expose + @ConfigOption(name = "Highlight Status", desc = "Highlight the status for visitors with a text above or with color.") + @ConfigEditorDropdown(values = {"Color Only", "Name Only", "Both", "Disabled"}) + public int highlightStatus = 2; + + @Expose + @ConfigOption(name = "Colored Name", desc = "Show the visitor name in the color of the rarity.") + @ConfigEditorBoolean + @FeatureToggle + public boolean coloredName = true; + + @Expose + @ConfigOption(name = "Hypixel Message", desc = "Hide the chat message from Hypixel that a new visitor has arrived at your garden.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hypixelArrivedMessage = true; + + @Expose + @ConfigOption(name = "Hide Chat", desc = "Hide chat messages from the visitors in the garden. (Except Beth, Jacob and Spaceman)") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideChat = true; + + @Expose + @ConfigOption(name = "Visitor Drops Statistics Counter", desc = "") + @Accordion + public DropsStatisticsConfig dropsStatistics = new DropsStatisticsConfig(); + + @Expose + @ConfigOption( + name = "Accept Hotkey", + desc = "Accept a visitor when you press this keybind while in the visitor GUI. " + + "§eUseful for getting Ephemeral Gratitudes during the 2023 Halloween event." + ) + @ConfigEditorKeybind( + defaultKey = Keyboard.KEY_NONE + ) + public int acceptHotkey = Keyboard.KEY_NONE; + + + @Expose + @ConfigOption( + name = "Highlight Visitors in SkyBlock", + desc = "Highlights Visitors outside of the Garden" + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightVisitors = false; + + + @Expose + @ConfigOption( + name = "Block Interacting with Visitors", + desc = "Blocks you from interacting with / unlocking Visitors to allow for Dedication Cycling" + ) + @ConfigEditorDropdown + public VisitorBlockBehaviour blockInteracting = VisitorBlockBehaviour.ONLY_ON_BINGO; + + public enum VisitorBlockBehaviour { + DONT("Don't"), ALWAYS("Always"), ONLY_ON_BINGO("Only on Bingo"); + + final String str; + + VisitorBlockBehaviour(String str) { + this.str = str; + } + + @Override + public String toString() { + return str; + } + } + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/gui/GUIConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/gui/GUIConfig.java new file mode 100644 index 000000000000..4eeadf221fad --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/gui/GUIConfig.java @@ -0,0 +1,74 @@ +package at.hannibal2.skyhanni.config.features.gui; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import at.hannibal2.skyhanni.data.GuiEditManager; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorButton; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +public class GUIConfig { + + @ConfigOption(name = "Edit GUI Locations", desc = "Change the position of SkyHanni's overlays.") + @ConfigEditorButton(buttonText = "Edit") + public Runnable positions = () -> GuiEditManager.openGuiPositionEditor(true); + + @Expose + @ConfigOption(name = "Open Hotkey", desc = "Press this key to open the GUI Editor.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int keyBindOpen = Keyboard.KEY_NONE; + + @Expose + @ConfigOption(name = "Global GUI Scale", desc = "Globally scale all SkyHanni GUIs.") + @ConfigEditorSlider(minValue = 0.1F, maxValue = 10, minStep = 0.05F) + public float globalScale = 1F; + + @Expose + @ConfigOption(name = "Modify Visual Words", desc = "") + @Accordion + public ModifyWordsConfig modifyWords = new ModifyWordsConfig(); + + @Expose + @ConfigOption(name = "Custom Text Box", desc = "") + @Accordion + public TextBoxConfig customTextBox = new TextBoxConfig(); + + @Expose + @ConfigOption(name = "Real Time", desc = "Display the current computer time, a handy feature when playing in full-screen mode.") + @ConfigEditorBoolean + @FeatureToggle + public boolean realTime = false; + + @Expose + @ConfigOption(name = "Real Time 12h Format", desc = "Display the current computer time in 12hr Format rather than 24h Format.") + @ConfigEditorBoolean + public boolean realTimeFormatToggle = false; + + @Expose + public Position realTimePosition = new Position(10, 10, false, true); + + @Expose + @ConfigOption(name = "In-Game Date", desc = "") + @Accordion + public InGameDateConfig inGameDate = new InGameDateConfig(); + + @Expose + @ConfigOption(name = "TPS Display", desc = "Show the TPS of the current server, like in Soopy.") + @ConfigEditorBoolean + @FeatureToggle + public boolean tpsDisplay = false; + + @Expose + public Position tpsDisplayPosition = new Position(10, 10, false, true); + + @Expose + @ConfigOption(name = "Config Button", desc = "Add a button to the pause menu to configure SkyHanni.") + @ConfigEditorBoolean + @FeatureToggle + public boolean configButtonOnPause = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/gui/InGameDateConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/gui/InGameDateConfig.java new file mode 100644 index 000000000000..5985e5131dcd --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/gui/InGameDateConfig.java @@ -0,0 +1,63 @@ +package at.hannibal2.skyhanni.config.features.gui; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class InGameDateConfig { + + @Expose + @ConfigOption( + name = "Enabled", + desc = "Show the in-game date of SkyBlock (like in Apec, §ebut with mild delays§7).\n" + + "(Though this one includes the SkyBlock year!)" + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + public Position position = new Position(10, 10, false, true); + + @Expose + @ConfigOption( + name = "Use Scoreboard for Date", + desc = "Uses the scoreboard instead to find the current month, date, and time. Greater \"accuracy\", depending on who's asking." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean useScoreboard = true; + + @Expose + @ConfigOption( + name = "Show Sun/Moon", + desc = "Show the sun or moon symbol seen on the scoreboard." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean includeSunMoon = true; + + @Expose + @ConfigOption( + name = "Show Date Ordinal", + desc = "Show the date's ordinal suffix. Ex: (1st <-> 1, 22nd <-> 22, 23rd <-> 3, 24th <-> 24, etc.)" + ) + @ConfigEditorBoolean + public boolean includeOrdinal = false; + + @Expose + @ConfigOption( + name = "Refresh Rate", + desc = "Change the time in seconds you would like to refresh the In-Game Date Display." + + "\n§eNOTE: If \"Use Scoreboard for Date\" is enabled, this setting is ignored." + ) + @ConfigEditorSlider( + minValue = 1, + maxValue = 60, + minStep = 1 + ) + public int refreshSeconds = 30; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/gui/ModifyWordsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/gui/ModifyWordsConfig.java new file mode 100644 index 000000000000..498dba83d9a1 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/gui/ModifyWordsConfig.java @@ -0,0 +1,28 @@ +package at.hannibal2.skyhanni.config.features.gui; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.commands.Commands; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorButton; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ModifyWordsConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Enables replacing all instances of a word or phrase with another word or phrase.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Work Outside SkyBlock", desc = "Allows modifying visual words anywhere on Hypixel.") + @ConfigEditorBoolean + @FeatureToggle + public boolean workOutside = false; + + @ConfigOption(name = "Open Config", desc = "Opens the menu to setup the visual words.\n§eCommand: /shwords") + @ConfigEditorButton(buttonText = "Open") + public Runnable open = Commands::openVisualWords; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/gui/TextBoxConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/gui/TextBoxConfig.java new file mode 100644 index 000000000000..1347324657c6 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/gui/TextBoxConfig.java @@ -0,0 +1,26 @@ +package at.hannibal2.skyhanni.config.features.gui; + +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorText; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import io.github.moulberry.moulconfig.observer.Property; + +public class TextBoxConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Enables showing the textbox while in SkyBlock.") + @ConfigEditorBoolean + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Text", desc = "Enter text you want to display here.\n" + + "§eUse '&' as the colour code character.\n" + + "§eUse '\\n' as the line break character.") + @ConfigEditorText + public Property text = Property.of("&aYour Text Here\\n&bYour new line here"); + + @Expose + public Position position = new Position(10, 80, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/ChestValueConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/ChestValueConfig.java new file mode 100644 index 000000000000..62eb303854fd --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/ChestValueConfig.java @@ -0,0 +1,88 @@ +package at.hannibal2.skyhanni.config.features.inventory; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ChestValueConfig { + @Expose + @ConfigOption(name = "Enabled", desc = "Enable estimated value of chest.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Enabled in dungeons", desc = "Enable the feature in dungeons.") + @ConfigEditorBoolean + public boolean enableInDungeons = false; + + @Expose + @ConfigOption(name = "Enable during Item Value", desc = "Show this display even if the Estimated Item Value is visible.") + @ConfigEditorBoolean + public boolean showDuringEstimatedItemValue = false; + + @Expose + @ConfigOption(name = "Show Stacks", desc = "Show the item icon before name.") + @ConfigEditorBoolean + public boolean showStacks = true; + + @Expose + @ConfigOption(name = "Display Type", desc = "Try to align everything to look nicer.") + @ConfigEditorBoolean + public boolean alignedDisplay = true; + + @Expose + @ConfigOption(name = "Name Length", desc = "Reduce item name length to gain extra space on screen.\n§cCalculated in pixels!") + @ConfigEditorSlider(minStep = 1, minValue = 100, maxValue = 150) + public int nameLength = 100; + + @Expose + @ConfigOption(name = "Highlight Slot", desc = "Highlight slot where the item is when you hover over it in the display.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enableHighlight = true; + + @Expose + @ConfigOption(name = "Highlight Color", desc = "Choose the highlight color.") + @ConfigEditorColour + public String highlightColor = "0:249:0:255:88"; + + @Expose + @ConfigOption(name = "Sorting Type", desc = "Price sorting type.") + @ConfigEditorDropdown(values = {"Descending", "Ascending"}) + public int sortingType = 0; + + @Expose + @ConfigOption(name = "Value formatting Type", desc = "Format of the price.") + @ConfigEditorDropdown(values = {"Short", "Long"}) + public int formatType = 0; + + @Expose + @ConfigOption(name = "Item To Show", desc = "Choose how many items are displayed.\n" + + "All items in the chest are still counted for the total value.") + @ConfigEditorSlider( + minValue = 0, + maxValue = 54, + minStep = 1 + ) + public int itemToShow = 15; + + @Expose + @ConfigOption(name = "Hide below", desc = "Item item value below configured amount.\n" + + "Items are still counted for the total value.") + @ConfigEditorSlider( + minValue = 50_000, + maxValue = 10_000_000, + minStep = 50_000 + ) + public int hideBelow = 100_000; + + + @Expose + public Position position = new Position(107, 141, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/HideNotClickableConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/HideNotClickableConfig.java new file mode 100644 index 000000000000..9c0c016028b1 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/HideNotClickableConfig.java @@ -0,0 +1,43 @@ +package at.hannibal2.skyhanni.config.features.inventory; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class HideNotClickableConfig { + @Expose + @ConfigOption(name = "Enabled", desc = "Hide items that are not clickable in the current inventory: ah, bz, accessory bag, etc.") + @ConfigEditorBoolean + @FeatureToggle + public boolean items = false; + + @Expose + @ConfigOption(name = "Block Clicks", desc = "Block the clicks on these items.") + @ConfigEditorBoolean + public boolean itemsBlockClicks = true; + + @Expose + @ConfigOption( + name = "Opacity", + desc = "How strong should the items be grayed out?" + ) + @ConfigEditorSlider( + minValue = 0, + maxValue = 255, + minStep = 5 + ) + public int opacity = 180; + + @Expose + @ConfigOption(name = "Bypass With Control", desc = "Adds the ability to bypass not clickable items when holding the control key.") + @ConfigEditorBoolean + public boolean itemsBypass = true; + + @Expose + @ConfigOption(name = "Green Line", desc = "Adds green line around items that are clickable.") + @ConfigEditorBoolean + public boolean itemsGreenLine = true; + +} 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 new file mode 100644 index 000000000000..60cc0e40592d --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/InventoryConfig.java @@ -0,0 +1,171 @@ +package at.hannibal2.skyhanni.config.features.inventory; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.HasLegacyId; +import at.hannibal2.skyhanni.config.features.inventory.helper.HelperConfig; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.Category; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import static at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.LARVA_HOOK; +import static at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.NEW_YEAR_CAKE; +import static at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.RANCHERS_BOOTS_SPEED; +import static at.hannibal2.skyhanni.config.features.inventory.InventoryConfig.ItemNumberEntry.VACUUM_GARDEN; + +public class InventoryConfig { + + @Expose + @ConfigOption(name = "Not Clickable Items", desc = "") + @Accordion + public HideNotClickableConfig hideNotClickable = new HideNotClickableConfig(); + + @Expose + @ConfigOption(name = "RNG Meter", desc = "") + @Accordion + public RngMeterConfig rngMeter = new RngMeterConfig(); + + @Expose + @ConfigOption(name = "Stats Tuning", desc = "") + @Accordion + public StatsTuningConfig statsTuning = new StatsTuningConfig(); + + @Expose + @ConfigOption(name = "Jacob Farming Contest", desc = "") + @Accordion + public JacobFarmingContestConfig jacobFarmingContests = new JacobFarmingContestConfig(); + + + @Expose + @ConfigOption(name = "Sack Items Display", desc = "") + @Accordion + public SackDisplayConfig sackDisplay = new SackDisplayConfig(); + + @Expose + @ConfigOption(name = "Chest Value", desc = "") + @Accordion + public ChestValueConfig chestValueConfig = new ChestValueConfig(); + + @Expose + @Category(name = "Helpers", desc = "Settings for Helpers") + public HelperConfig helper = new HelperConfig(); + + @Expose + @ConfigOption( + name = "Item Number", + desc = "Showing the item number as a stack size for these items." + ) + @ConfigEditorDraggableList() + public List itemNumberAsStackSize = new ArrayList<>(Arrays.asList( + NEW_YEAR_CAKE, + RANCHERS_BOOTS_SPEED, + LARVA_HOOK, + VACUUM_GARDEN + )); + + public enum ItemNumberEntry implements HasLegacyId { + MASTER_STAR_TIER("§bMaster Star Tier", 0), + MASTER_SKULL_TIER("§bMaster Skull Tier", 1), + DUNGEON_HEAD_FLOOR_NUMBER("§bDungeon Head Floor Number", 2), + NEW_YEAR_CAKE("§bNew Year Cake", 3), + PET_LEVEL("§bPet Level", 4), + MINION_TIER("§bMinion Tier", 5), + CRIMSON_ARMOR("§bCrimson Armor", 6), + REMOVED("§7(Removed)", 7), + KUUDRA_KEY("§bKuudra Key", 8), + SKILL_LEVEL("§bSkill Level", 9), + COLLECTION_LEVEL("§bCollection Level", 10), + RANCHERS_BOOTS_SPEED("§bRancher's Boots speed", 11), + LARVA_HOOK("§bLarva Hook", 12), + DUNGEON_POTION_LEVEL("§bDungeon Potion Level", 13), + VACUUM_GARDEN("§bVacuum (Garden)", 14), + BOTTLE_OF_JYRRE("§bBottle Of Jyrre", 15), + EDITION_NUMBER("§bEdition Number", 16), + BINGO_GOAL_RANK("§bBingo Goal Rank"), + ; + + private final String str; + private final int legacyId; + + ItemNumberEntry(String str, int legacyId) { + this.str = str; + this.legacyId = legacyId; + } + + // Constructor if new enum elements are added post-migration + ItemNumberEntry(String str) { + this(str, -1); + } + + @Override + public int getLegacyId() { + return legacyId; + } + + @Override + public String toString() { + return str; + } + } + + @Expose + @ConfigOption(name = " Vacuum Bag Cap", desc = "Capping the Garden Vacuum Bag item number display to 40.") + @ConfigEditorBoolean + public boolean vacuumBagCap = true; + + @Expose + @ConfigOption( + name = "Quick Craft Confirmation", + desc = "Require Ctrl+Click to craft items that aren't often quick crafted " + + "(e.g. armor, weapons, accessories). Sack items can be crafted normally." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean quickCraftingConfirmation = false; + + @Expose + @ConfigOption(name = "Sack Name", desc = "Show an abbreviation of the sack name.") + @ConfigEditorBoolean + @FeatureToggle + public boolean displaySackName = false; + + @Expose + @ConfigOption(name = "Anvil Combine Helper", desc = "Suggests the same item in the inventory when trying to combine two items in the anvil.") + @ConfigEditorBoolean + @FeatureToggle + public boolean anvilCombineHelper = false; + + @Expose + @ConfigOption(name = "Item Stars", + desc = "Show a compact star count in the item name for all items.") + @ConfigEditorBoolean + @FeatureToggle + public boolean itemStars = false; + + @Expose + @ConfigOption(name = "Missing Tasks", + desc = "Highlight missing tasks in the SkyBlock Level Guide inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightMissingSkyBlockLevelGuide = true; + + @Expose + @ConfigOption(name = "Highlight Auctions", + desc = "Highlight own items that are sold in green and that are expired in red.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightAuctions = true; + + @Expose + @ConfigOption(name = "Shift Click Equipment", desc = "Makes normal clicks to shift clicks in equipment inventory") + @ConfigEditorBoolean + @FeatureToggle + public boolean shiftClickForEquipment = false; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/JacobFarmingContestConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/JacobFarmingContestConfig.java new file mode 100644 index 000000000000..dc18bd29de74 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/JacobFarmingContestConfig.java @@ -0,0 +1,32 @@ +package at.hannibal2.skyhanni.config.features.inventory; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class JacobFarmingContestConfig { + @Expose + @ConfigOption(name = "Unclaimed Rewards", desc = "Highlight contests with unclaimed rewards in the Jacob inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightRewards = true; + + @Expose + @ConfigOption(name = "Contest Time", desc = "Adds the real time format to the Contest description.") + @ConfigEditorBoolean + @FeatureToggle + public boolean realTime = true; + + @Expose + @ConfigOption(name = "Medal Icon", desc = "Adds a symbol that shows what medal you received in this Contest. " + + "§eIf you use a texture pack this may cause conflicting icons.") + @ConfigEditorBoolean + @FeatureToggle + public boolean medalIcon = true; + + @Expose + @ConfigOption(name = "Finnegan Icon", desc = "Uses a different indicator for when the Contest happened during Mayor Finnegan.") + @ConfigEditorBoolean + public boolean finneganIcon = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/RngMeterConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/RngMeterConfig.java new file mode 100644 index 000000000000..e57e95b5c81a --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/RngMeterConfig.java @@ -0,0 +1,26 @@ +package at.hannibal2.skyhanni.config.features.inventory; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class RngMeterConfig { + @Expose + @ConfigOption(name = "Floor Names", desc = "Show the Floor names in the Catacombs RNG Meter inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean floorName = false; + + @Expose + @ConfigOption(name = "No Drop", desc = "Highlight floors without a drop selected in the Catacombs RNG Meter inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean noDrop = false; + + @Expose + @ConfigOption(name = "Selected Drop", desc = "Highlight the selected drop in the Catacombs or Slayer RNG Meter inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean selectedDrop = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/SackDisplayConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/SackDisplayConfig.java new file mode 100644 index 000000000000..37eab2be356f --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/SackDisplayConfig.java @@ -0,0 +1,84 @@ +package at.hannibal2.skyhanni.config.features.inventory; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class SackDisplayConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Show contained items inside a sack inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption( + name = "Highlight Full", + desc = "Highlight items that are full in red.\n" + + "§eDoes not need the option above to be enabled." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightFull = true; + + @Expose + @ConfigOption(name = "Number Format", desc = "Either show Default, Formatted or Unformatted numbers.\n" + + "§eDefault: §72,240/2.2k\n" + + "§eFormatted: §72.2k/2.2k\n" + + "§eUnformatted: §72,240/2,200") + @ConfigEditorDropdown(values = {"Default", "Formatted", "Unformatted"}) + public int numberFormat = 1; + + @Expose + @ConfigOption(name = "Extra space", desc = "Space between each line of text.") + @ConfigEditorSlider( + minValue = 0, + maxValue = 10, + minStep = 1) + public int extraSpace = 1; + + @Expose + @ConfigOption(name = "Sorting Type", desc = "Sorting type of items in sack.") + @ConfigEditorDropdown(values = {"Descending (Stored)", "Ascending (Stored)", "Descending (Price)", "Ascending (Price)"}) + public int sortingType = 0; + + @Expose + @ConfigOption(name = "Item To Show", desc = "Choose how many items are displayed. (Some sacks have too many items to fit\n" + + "in larger GUI scales, like the nether sack.)") + @ConfigEditorSlider( + minValue = 0, + maxValue = 45, + minStep = 1 + ) + public int itemToShow = 15; + + @Expose + @ConfigOption(name = "Show Empty Item", desc = "Show empty item quantity in the display.") + @ConfigEditorBoolean + public boolean showEmpty = true; + + @Expose + @ConfigOption(name = "Show Price", desc = "Show price for each item in sack.") + @ConfigEditorBoolean + public boolean showPrice = true; + + @Expose + @ConfigOption(name = "Price Format", desc = "Format of the price displayed.\n" + + "§eFormatted: §7(12k)\n" + + "§eUnformatted: §7(12,421)") + @ConfigEditorDropdown(values = {"Formatted", "Unformatted"}) + public int priceFormat = 0; + + @Expose + @ConfigOption(name = "Show Price From", desc = "Show price from Bazaar or NPC.") + @ConfigEditorDropdown(values = {"Bazaar", "NPC"}) + public int priceFrom = 0; + + @Expose + public Position position = new Position(144, 139, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/StatsTuningConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/StatsTuningConfig.java new file mode 100644 index 000000000000..2f6111fee54f --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/StatsTuningConfig.java @@ -0,0 +1,32 @@ +package at.hannibal2.skyhanni.config.features.inventory; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class StatsTuningConfig { + @Expose + @ConfigOption(name = "Selected Stats", desc = "Show the tuning stats in the Thaumaturgy inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean selectedStats = true; + + @Expose + @ConfigOption(name = "Tuning Points", desc = "Show the amount of selected Tuning Points in the Stats Tuning inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean points = true; + + @Expose + @ConfigOption(name = "Selected Template", desc = "Highlight the selected template in the Stats Tuning inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean selectedTemplate = true; + + @Expose + @ConfigOption(name = "Template Stats", desc = "Show the type of stats for the Tuning Point templates.") + @ConfigEditorBoolean + @FeatureToggle + public boolean templateStats = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/helper/HarpConfigKeyBinds.java b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/helper/HarpConfigKeyBinds.java new file mode 100644 index 000000000000..fcdac1d57782 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/helper/HarpConfigKeyBinds.java @@ -0,0 +1,37 @@ +package at.hannibal2.skyhanni.config.features.inventory.helper; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +public class HarpConfigKeyBinds { + @Expose + @ConfigOption(name = "Key 1", desc = "Key for the first Node") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_1) + public int key1 = Keyboard.KEY_1; + @Expose + @ConfigOption(name = "Key 2", desc = "Key for the second Node") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_2) + public int key2 = Keyboard.KEY_2; + @Expose + @ConfigOption(name = "Key 3", desc = "Key for the third Node") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_3) + public int key3 = Keyboard.KEY_3; + @Expose + @ConfigOption(name = "Key 4", desc = "Key for the fourth Node") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_4) + public int key4 = Keyboard.KEY_4; + @Expose + @ConfigOption(name = "Key 5", desc = "Key for the fifth Node") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_5) + public int key5 = Keyboard.KEY_5; + @Expose + @ConfigOption(name = "Key 6", desc = "Key for the sixth Node") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_6) + public int key6 = Keyboard.KEY_6; + @Expose + @ConfigOption(name = "Key 7", desc = "Key for the seventh Node") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_7) + public int key7 = Keyboard.KEY_7; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/helper/HelperConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/helper/HelperConfig.java new file mode 100644 index 000000000000..02c06f39a18e --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/helper/HelperConfig.java @@ -0,0 +1,37 @@ +package at.hannibal2.skyhanni.config.features.inventory.helper; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class HelperConfig { + @Expose + @ConfigOption(name = "Melody's Hair Harp", desc = "") + @Accordion + public HarpConfig harp = new HarpConfig(); + + public static class HarpConfig { + @Expose + @ConfigOption(name = "Use Keybinds", desc = "In the Harp, press buttons with your number row on the keyboard instead of clicking.") + @ConfigEditorBoolean + @FeatureToggle + public boolean keybinds = false; + + @Expose + @ConfigOption(name = "Show Numbers", desc = "In the Harp, show buttons as stack size (intended to be used with the Keybinds).") + @ConfigEditorBoolean + public boolean showNumbers = false; + + @Expose + @ConfigOption(name = "Keybinds", desc = "") + @Accordion + public HarpConfigKeyBinds harpKeybinds = new HarpConfigKeyBinds(); + } + + @Expose + @ConfigOption(name = "Tia Relay Abiphone Network Maintenance", desc = "") + @Accordion + public TiaRelayConfig tiaRelay = new TiaRelayConfig(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/helper/TiaRelayConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/helper/TiaRelayConfig.java new file mode 100644 index 000000000000..78480b4df024 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/helper/TiaRelayConfig.java @@ -0,0 +1,32 @@ +package at.hannibal2.skyhanni.config.features.inventory.helper; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class TiaRelayConfig { + + @Expose + @ConfigOption(name = "Sound Puzzle Helper", desc = "Helps with solving the sound puzzle for Tia (The 9 Operator Chips to do maintainance for the Abiphone Network).") + @ConfigEditorBoolean + @FeatureToggle + public boolean soundHelper = true; + + @Expose + @ConfigOption(name = "Next Waypoint", desc = "Show the next relay waypoint for Tia the Fairy, where maintenance for the Abiphone network needs to be done.") + @ConfigEditorBoolean + @FeatureToggle + public boolean nextWaypoint = true; + + @Expose + @ConfigOption(name = "All Waypoints", desc = "Show all relay waypoints at once (intended for debugging).") + @ConfigEditorBoolean + public boolean allWaypoints = false; + + @Expose + @ConfigOption(name = "Mute Sound", desc = "Mutes the sound when close to the relay.") + @ConfigEditorBoolean + @FeatureToggle + public boolean tiaRelayMute = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/itemability/ChickenHeadConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/itemability/ChickenHeadConfig.java new file mode 100644 index 000000000000..49c803cd5ca0 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/itemability/ChickenHeadConfig.java @@ -0,0 +1,25 @@ +package at.hannibal2.skyhanni.config.features.itemability; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ChickenHeadConfig { + + @Expose + @ConfigOption(name = "Checken Head Timer", desc = "Show the cooldown until the next time you can lay an egg with the Chicken Head.") + @ConfigEditorBoolean + @FeatureToggle + public boolean displayTimer = false; + + @Expose + public Position position = new Position(-372, 73, false, true); + + @Expose + @ConfigOption(name = "Hide Chat", desc = "Hide the 'You laid an egg!' chat message.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideChat = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/itemability/FireVeilWandConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/itemability/FireVeilWandConfig.java new file mode 100644 index 000000000000..a05558d942ff --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/itemability/FireVeilWandConfig.java @@ -0,0 +1,21 @@ +package at.hannibal2.skyhanni.config.features.itemability; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class FireVeilWandConfig { + @Expose + @ConfigOption(name = "Fire Veil Design", desc = "Changes the flame particles of the Fire Veil Wand ability.") + @ConfigEditorDropdown(values = {"Particles", "Line", "Off"}) + public int display = 0; + + @Expose + @ConfigOption( + name = "Line Color", + desc = "Changes the color of the Fire Veil Wand line." + ) + @ConfigEditorColour + public String displayColor = "0:245:255:85:85"; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/itemability/ItemAbilityConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/itemability/ItemAbilityConfig.java new file mode 100644 index 000000000000..a53075016486 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/itemability/ItemAbilityConfig.java @@ -0,0 +1,38 @@ +package at.hannibal2.skyhanni.config.features.itemability; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ItemAbilityConfig { + + @Expose + @ConfigOption(name = "Ability Cooldown", desc = "Show the cooldown of item abilities.") + @ConfigEditorBoolean + @FeatureToggle + public boolean itemAbilityCooldown = false; + + @Expose + @ConfigOption(name = "Ability Cooldown Background", desc = "Show the cooldown color of item abilities in the background.") + @ConfigEditorBoolean + public boolean itemAbilityCooldownBackground = false; + + @Expose + @ConfigOption(name = "Fire Veil", desc = "") + @Accordion + public FireVeilWandConfig fireVeilWands = new FireVeilWandConfig(); + + @ConfigOption(name = "Chicken Head", desc = "") + @Accordion + @Expose + public ChickenHeadConfig chickenHead = new ChickenHeadConfig(); + + @Expose + @ConfigOption(name = "Depleted Bonzo's Masks", + desc = "Highlights used Bonzo's Masks and Spirit Masks with a background.") + @ConfigEditorBoolean + @FeatureToggle + public boolean depletedBonzosMasks = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/MarkedPlayerConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/markedplayer/MarkedPlayerConfig.java similarity index 93% rename from src/main/java/at/hannibal2/skyhanni/config/features/MarkedPlayerConfig.java rename to src/main/java/at/hannibal2/skyhanni/config/features/markedplayer/MarkedPlayerConfig.java index e199f7c5583c..431e5f29cc14 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/features/MarkedPlayerConfig.java +++ b/src/main/java/at/hannibal2/skyhanni/config/features/markedplayer/MarkedPlayerConfig.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.config.features; +package at.hannibal2.skyhanni.config.features.markedplayer; import com.google.gson.annotations.Expose; import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/mining/KingTalismanConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/mining/KingTalismanConfig.java new file mode 100644 index 000000000000..e98ae5740de6 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/mining/KingTalismanConfig.java @@ -0,0 +1,25 @@ +package at.hannibal2.skyhanni.config.features.mining; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class KingTalismanConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Show kings you have not talked to yet, and when the next missing king will appear.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Outside Mines", desc = "Show the display even while outside the Dwarven Mines.") + @ConfigEditorBoolean + @FeatureToggle + public boolean outsideMines = false; + + @Expose + public Position position = new Position(-400, 220, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/mining/MiningConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/mining/MiningConfig.java new file mode 100644 index 000000000000..feeb465abaf5 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/mining/MiningConfig.java @@ -0,0 +1,32 @@ +package at.hannibal2.skyhanni.config.features.mining; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class MiningConfig { + + @Expose + @ConfigOption(name = "Powder Tracker", desc = "") + @Accordion + public PowderTrackerConfig powderTracker = new PowderTrackerConfig(); + + @Expose + @ConfigOption(name = "King Talisman", desc = "") + @Accordion + public KingTalismanConfig kingTalisman = new KingTalismanConfig(); + + @Expose + @ConfigOption(name = "Highlight Commission Mobs", desc = "Highlight Mobs that are part of active commissions.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightCommissionMobs = false; + + @Expose + @ConfigOption(name = "Names in Core", desc = "Show the names of the 4 areas while in the center of the Crystal Hollows.") + @ConfigEditorBoolean + @FeatureToggle + public boolean crystalHollowsNamesInCore = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/mining/PowderTrackerConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/mining/PowderTrackerConfig.java new file mode 100644 index 000000000000..1e658c5a2ffd --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/mining/PowderTrackerConfig.java @@ -0,0 +1,145 @@ +package at.hannibal2.skyhanni.config.features.mining; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.HasLegacyId; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import io.github.moulberry.moulconfig.observer.Property; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.AMBER; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.AMETHYST; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.DIAMOND_ESSENCE; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.DISPLAY_MODE; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.DOUBLE_POWDER; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.ELECTRON; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.FTX; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.GEMSTONE_POWDER; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.GOLD_ESSENCE; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.JADE; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.MITHRIL_POWDER; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.ROBOTRON; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.RUBY; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.SAPPHIRE; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.SPACER_1; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.SPACER_2; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.TITLE; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.TOPAZ; +import static at.hannibal2.skyhanni.config.features.mining.PowderTrackerConfig.PowderDisplayEntry.TOTAL_CHESTS; + +public class PowderTrackerConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Enable the Powder Tracker overlay for mining.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Only when Grinding", desc = "Only show the overlay when powder grinding.") + @ConfigEditorBoolean + public boolean onlyWhenPowderGrinding = false; + + @Expose + @ConfigOption(name = "Great Explorer", desc = "Enable this if your Great Explorer perk is maxed.") + @ConfigEditorBoolean + public boolean greatExplorerMaxed = false; + + @Expose + @ConfigOption( + name = "Text Format", + desc = "Drag text to change the appearance of the overlay." + ) + @ConfigEditorDraggableList() + public Property> textFormat = Property.of(new ArrayList<>(Arrays.asList( + TITLE, + DISPLAY_MODE, + TOTAL_CHESTS, + DOUBLE_POWDER, + MITHRIL_POWDER, + GEMSTONE_POWDER, + SPACER_1, + DIAMOND_ESSENCE, + GOLD_ESSENCE, + SPACER_2, + RUBY, + SAPPHIRE, + AMBER, + AMETHYST, + JADE, + TOPAZ, + FTX, + ELECTRON, + ROBOTRON + ))); + + public enum PowderDisplayEntry implements HasLegacyId { + TITLE("§b§lPowder Tracker", 0), + DISPLAY_MODE("§7Display Mode: §a[Total] §e[This Session]", 1), + TOTAL_CHESTS("§d852 Total chests Picked §7(950/h)", 2), + DOUBLE_POWDER("§bx2 Powder: §aActive!", 3), + MITHRIL_POWDER("§b250,420 §aMithril Powder §7(350,000/h)", 4), + GEMSTONE_POWDER("§b250,420 §dGemstone Powder §7(350,000/h)", 5), + SPACER_1("", 6), + DIAMOND_ESSENCE("§b129 §bDiamond Essence §7(600/h)", 7), + GOLD_ESSENCE("§b234 §6Gold Essence §7(700/h)", 8), + SPACER_2("", 9), + RUBY("§50§7-§90§7-§a0§f-0 §cRuby Gemstone", 10), + SAPPHIRE("§50§7-§90§7-§a0§f-0 §bSapphire Gemstone", 11), + AMBER("§50§7-§90§7-§a0§f-0 §6Amber Gemstone", 12), + AMETHYST("§50§7-§90§7-§a0§f-0 §5Amethyst Gemstone", 13), + JADE("§50§7-§90§7-§a0§f-0 §aJade Gemstone", 14), + TOPAZ("§50§7-§90§7-§a0§f-0 §eTopaz Gemstone", 15), + FTX("§b14 §9FTX 3070", 16), + ELECTRON("§b14 §9Electron Transmitter", 17), + ROBOTRON("§b14 §9Robotron Reflector", 18), + SUPERLITE("§b14 §9Superlite Motor", 19), + CONTROL_SWITCH("§b14 §9Control Switch", 20), + SYNTHETIC_HEART("§b14 §9Synthetic Heart", 21), + TOTAL_ROBOT_PARTS("§b14 §9Total Robot Parts", 22), + GOBLIN_EGGS("§90§7-§a0§7-§c0§f-§e0§f-§30 §fGoblin Egg", 23), + WISHING_COMPASS("§b12 §aWishing Compass", 24), + SLUDGE_JUICE("§b320 §aSludge Juice", 25), + ASCENSION_ROPE("§b2 §9Ascension Rope", 26), + TREASURITE("§b6 §5Treasurite", 27), + JUNGLE_HEART("§b4 §6Jungle Heart", 28), + PICKONIMBUS("§b1 §5Pickonimbus 2000", 29), + YOGGIE("§b14 §aYoggie", 30), + PREHISTORIC_EGG("§b9 §fPrehistoric Egg", 31), + OIL_BARREL("§b25 §aOil Barrel", 32), + ; + + private final String str; + private final int legacyId; + + PowderDisplayEntry(String str, int legacyId) { + this.str = str; + this.legacyId = legacyId; + } + + // Constructor if new enum elements are added post-migration + PowderDisplayEntry(String str) { + this(str, -1); + } + + @Override + public int getLegacyId() { + return legacyId; + } + + @Override + public String toString() { + return str; + } + } + + @Expose + public Position position = new Position(-274, 0, false, true); + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/minion/EmptiedTimeConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/minion/EmptiedTimeConfig.java new file mode 100644 index 000000000000..53f324e003c3 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/minion/EmptiedTimeConfig.java @@ -0,0 +1,27 @@ +package at.hannibal2.skyhanni.config.features.minion; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class EmptiedTimeConfig { + @Expose + @ConfigOption(name = "Emptied Time Display", desc = "Show the time when the hopper in the minion was last emptied.") + @ConfigEditorBoolean + @FeatureToggle + public boolean display = false; + + @Expose + @ConfigOption( + name = "Distance", + desc = "Maximum distance to display minion data." + ) + @ConfigEditorSlider( + minValue = 3, + maxValue = 30, + minStep = 1 + ) + public int distance = 10; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/minion/LastClickedMinionConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/minion/LastClickedMinionConfig.java new file mode 100644 index 000000000000..391a104680f4 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/minion/LastClickedMinionConfig.java @@ -0,0 +1,36 @@ +package at.hannibal2.skyhanni.config.features.minion; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class LastClickedMinionConfig { + @Expose + @ConfigOption(name = "Last Minion Display", desc = "Marks the location of the last clicked minion, even through walls.") + @ConfigEditorBoolean + @FeatureToggle + public boolean display = false; + + @Expose + @ConfigOption( + name = "Last Minion Color", + desc = "The color in which the last minion should be displayed." + ) + @ConfigEditorColour + public String color = "0:245:85:255:85"; + + @Expose + @ConfigOption( + name = "Last Minion Time", + desc = "Time in seconds how long the last minion should be displayed." + ) + @ConfigEditorSlider( + minValue = 3, + maxValue = 120, + minStep = 1 + ) + public int time = 20; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/minion/MinionsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/minion/MinionsConfig.java new file mode 100644 index 000000000000..4f089ce9de28 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/minion/MinionsConfig.java @@ -0,0 +1,52 @@ +package at.hannibal2.skyhanni.config.features.minion; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class MinionsConfig { + + @Expose + @ConfigOption(name = "Name Display", desc = "Show the minion name and tier over the minion.") + @ConfigEditorBoolean + @FeatureToggle + public boolean nameDisplay = true; + + @Expose + @ConfigOption(name = "Only Tier", desc = "Show only the tier number over the minion. (Useful for Bingo)") + @ConfigEditorBoolean + public boolean nameOnlyTier = false; + + @Expose + @ConfigOption(name = "Last Clicked", desc = "") + @Accordion + public LastClickedMinionConfig lastClickedMinion = new LastClickedMinionConfig(); + + @Expose + @ConfigOption(name = "Emptied Time", desc = "") + @Accordion + public EmptiedTimeConfig emptiedTime = new EmptiedTimeConfig(); + + @Expose + @ConfigOption(name = "Hopper Profit Display", desc = "Use the hopper's held coins and the last empty time to calculate the coins per day.") + @ConfigEditorBoolean + public boolean hopperProfitDisplay = true; + + @Expose + @ConfigOption(name = "Show Xp", desc = "Shows how much skill experience you will get when picking up items from the minion storage.") + @ConfigEditorBoolean + @FeatureToggle + public boolean xpDisplay = true; + + @Expose + public Position hopperProfitPos = new Position(360, 90, false, true); + + @Expose + @ConfigOption(name = "Hide Mob Nametag", desc = "Hiding the nametag of mobs close to minions.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideMobsNametagNearby = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/DiscordRPCConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/DiscordRPCConfig.java new file mode 100644 index 000000000000..aa7a1d4b78ec --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/DiscordRPCConfig.java @@ -0,0 +1,134 @@ +package at.hannibal2.skyhanni.config.features.misc; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.HasLegacyId; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigEditorText; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import io.github.moulberry.moulconfig.observer.Property; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import static at.hannibal2.skyhanni.config.features.misc.DiscordRPCConfig.LineEntry.NOTHING; +import static at.hannibal2.skyhanni.config.features.misc.DiscordRPCConfig.PriorityEntry.AFK; +import static at.hannibal2.skyhanni.config.features.misc.DiscordRPCConfig.PriorityEntry.CROP_MILESTONES; +import static at.hannibal2.skyhanni.config.features.misc.DiscordRPCConfig.PriorityEntry.DUNGEONS; +import static at.hannibal2.skyhanni.config.features.misc.DiscordRPCConfig.PriorityEntry.SLAYER; +import static at.hannibal2.skyhanni.config.features.misc.DiscordRPCConfig.PriorityEntry.STACKING_ENCHANT; + +public class DiscordRPCConfig { + + @Expose + @ConfigOption(name = "Enable Discord RPC", desc = "Details about your SkyBlock session displayed through Discord.") + @ConfigEditorBoolean + @FeatureToggle + public Property enabled = Property.of(false); + + @Expose + @ConfigOption(name = "First Line", desc = "Decide what to show in the first line.") + @ConfigEditorDropdown() + public Property firstLine = Property.of(NOTHING); + + @Expose + @ConfigOption(name = "Second Line", desc = "Decide what to show in the second line.") + @ConfigEditorDropdown() + public Property secondLine = Property.of(NOTHING); + + @Expose + @ConfigOption(name = "Custom", desc = "What should be displayed if you select \"Custom\" above.") + @ConfigEditorText + public Property customText = Property.of(""); + + @Expose + @ConfigOption(name = "Dynamic Priority", desc = "Disable certain dynamic statuses, or change the priority in case two are triggered at the same time (higher up means higher priority).") + @ConfigEditorDraggableList() + public List autoPriority = new ArrayList<>(Arrays.asList( + CROP_MILESTONES, + SLAYER, + STACKING_ENCHANT, + DUNGEONS, + AFK + )); + + public enum PriorityEntry implements HasLegacyId { + CROP_MILESTONES("Crop Milestones", 0), + SLAYER("Slayer", 1), + STACKING_ENCHANT("Stacking Enchantment", 2), + DUNGEONS("Dungeon", 3), + AFK("AFK Indicator", 4), + ; + + private final String str; + private final int legacyId; + + PriorityEntry(String str, int legacyId) { + this.str = str; + this.legacyId = legacyId; + } + + // Constructor if new enum elements are added post-migration + PriorityEntry(String str) { + this(str, -1); + } + + @Override + public int getLegacyId() { + return legacyId; + } + + @Override + public String toString() { + return str; + } + } + + @Expose + @ConfigOption(name = "Dynamic Fallback", desc = "What to show when none of your \"Dynamic Priority\" statuses are active.") + @ConfigEditorDropdown() + public Property auto = Property.of(NOTHING); + + public enum LineEntry implements HasLegacyId { + NOTHING("Nothing", 0), + LOCATION("Location", 1), + PURSE("Purse", 2), + BITS("Bits", 3), + STATS("Stats", 4), + HELD_ITEM("Held Item", 5), + SKYBLOCK_DATE("SkyBlock Date", 6), + PROFILE("Profile", 7), + SLAYER("Slayer", 8), + CUSTOM("Custom", 9), + DYNAMIC("Dynamic", 10), + CROP_MILESTONE("Crop Milestone", 11), + CURRENT_PET("Current Pet", 12), + ; + + private final String str; + private final int legacyId; + + LineEntry(String str, int legacyId) { + this.str = str; + this.legacyId = legacyId; + } + + // Constructor if new enum elements are added post-migration + LineEntry(String str) { + this(str, -1); + } + + @Override + public int getLegacyId() { + return legacyId; + } + + @Override + public String toString() { + return str; + } + } +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/EstimatedItemValueConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/EstimatedItemValueConfig.java new file mode 100644 index 000000000000..2513cd66bca3 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/EstimatedItemValueConfig.java @@ -0,0 +1,52 @@ +package at.hannibal2.skyhanni.config.features.misc; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import io.github.moulberry.moulconfig.observer.Property; +import org.lwjgl.input.Keyboard; + +public class EstimatedItemValueConfig { + @Expose + @ConfigOption(name = "Enable Estimated Price", desc = "Displays an Estimated Item Value for the item you hover over.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Hotkey", desc = "Press this key to show the Estimated Item Value.") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int hotkey = Keyboard.KEY_NONE; + + @Expose + @ConfigOption(name = "Show Always", desc = "Ignore the hotkey and always display the item value.") + @ConfigEditorBoolean + public boolean alwaysEnabled = true; + + @Expose + @ConfigOption(name = "Enchantments Cap", desc = "Only show the top # most expensive enchantments.") + @ConfigEditorSlider( + minValue = 1, + maxValue = 30, + minStep = 1 + ) + public Property enchantmentsCap = Property.of(7); + + @Expose + @ConfigOption(name = "Show Exact Price", desc = "Show the exact total price instead of the compact number.") + @ConfigEditorBoolean + public boolean exactPrice = false; + + @Expose + @ConfigOption(name = "Show Armor Value", desc = "Show the value of the full armor set in the Wardrobe inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean armor = true; + + @Expose + public Position itemPriceDataPos = new Position(140, 90, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/GlowingDroppedItemsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/GlowingDroppedItemsConfig.java new file mode 100644 index 000000000000..4b5a260a1178 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/GlowingDroppedItemsConfig.java @@ -0,0 +1,26 @@ +package at.hannibal2.skyhanni.config.features.misc; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class GlowingDroppedItemsConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Draws a glowing outline around all dropped items on the ground.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Highlight Showcase Items", desc = "Draws a glowing outline around showcase items.") + @ConfigEditorBoolean + public boolean highlightShowcase = false; + + @Expose + @ConfigOption(name = "Highlight Fishing Bait", desc = "Draws a glowing outline around fishing bait.") + @ConfigEditorBoolean + public boolean highlightFishingBait = false; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/HideArmorConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/HideArmorConfig.java new file mode 100644 index 000000000000..286249061d7b --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/HideArmorConfig.java @@ -0,0 +1,20 @@ +package at.hannibal2.skyhanni.config.features.misc; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class HideArmorConfig { + + @Expose + @ConfigOption(name = "Mode", desc = "Hide the armor of players.") + @ConfigEditorDropdown(values = {"All", "Own Armor", "Other's Armor", "Off"}) + public int mode = 3; + + @Expose + @ConfigOption(name = "Only Helmet", desc = "Only hide the helmet.") + @ConfigEditorBoolean() + public Boolean onlyHelmet = false; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/HighlightPartyMembersConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/HighlightPartyMembersConfig.java new file mode 100644 index 000000000000..8dc4d7c02f02 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/HighlightPartyMembersConfig.java @@ -0,0 +1,25 @@ +package at.hannibal2.skyhanni.config.features.misc; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class HighlightPartyMembersConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Marking party members with a bright outline to better find them in the world.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption( + name = "Outline Color", + desc = "The color to outline party members in." + ) + @ConfigEditorColour + public String outlineColor = "0:245:85:255:85"; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/KickDurationConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/KickDurationConfig.java new file mode 100644 index 000000000000..0d5af9046228 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/KickDurationConfig.java @@ -0,0 +1,34 @@ +package at.hannibal2.skyhanni.config.features.misc; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import io.github.moulberry.moulconfig.observer.Property; + +public class KickDurationConfig { + + @Expose + @ConfigOption( + name = "Enabled", + desc = "Show in the Hypixel lobby since when you were last kicked from SkyBlock (" + + "useful if you get blocked because of '§cYou were kicked while joining that server!§7')." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Warn Time", desc = "Send warning and sound this seconds after a SkyBlock kick.") + @ConfigEditorSlider( + minValue = 5, + maxValue = 300, + minStep = 1 + ) + public Property warnTime = Property.of(60); + + @Expose + public Position position = new Position(400, 200, 1.3f); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/MiscConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/MiscConfig.java new file mode 100644 index 000000000000..c9465ea2d9f6 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/MiscConfig.java @@ -0,0 +1,221 @@ +package at.hannibal2.skyhanni.config.features.misc; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import at.hannibal2.skyhanni.config.features.misc.compacttablist.CompactTabListConfig; +import at.hannibal2.skyhanni.config.features.misc.cosmetic.CosmeticConfig; +import at.hannibal2.skyhanni.config.features.misc.pets.PetConfig; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.Category; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class MiscConfig { + + @Expose + @Category(name = "Pets", desc = "Pets Settings") + public PetConfig pets = new PetConfig(); + + @ConfigOption(name = "Hide Armor", desc = "") + @Accordion + @Expose + public HideArmorConfig hideArmor2 = new HideArmorConfig(); + + @Expose + @ConfigOption(name = "Potion Effects", desc = "") + @Accordion + public PotionEffectsConfig potionEffect = new PotionEffectsConfig(); + + @Expose + @ConfigOption(name = "Particle Hider", desc = "") + @Accordion + public ParticleHiderConfig particleHiders = new ParticleHiderConfig(); + + @Expose + @ConfigOption(name = "Estimated Item Value", desc = "(Prices for Enchantments, Reforge Stones, Gemstones, Drill Parts and more)") + @Accordion + public EstimatedItemValueConfig estimatedItemValues = new EstimatedItemValueConfig(); + + @ConfigOption(name = "Discord Rich Presence", desc = "") + @Accordion + @Expose + public DiscordRPCConfig discordRPC = new DiscordRPCConfig(); + + @ConfigOption(name = "Trevor The Trapper", desc = "") + @Accordion + @Expose + public TrevorTheTrapperConfig trevorTheTrapper = new TrevorTheTrapperConfig(); + + @ConfigOption(name = "Teleport Pads On Private Island", desc = "") + @Accordion + @Expose + public TeleportPadConfig teleportPad = new TeleportPadConfig(); + + @ConfigOption(name = "Pocket Sack-In-A-Sack", desc = "") + @Accordion + @Expose + public PocketSackInASackConfig pocketSackInASack = new PocketSackInASackConfig(); + + @ConfigOption(name = "Quick Mod Menu Switch", desc = "") + @Accordion + @Expose + public QuickModMenuSwitchConfig quickModMenuSwitch = new QuickModMenuSwitchConfig(); + + @Expose + @Category(name = "Cosmetic", desc = "Cosmetics Settings") + public CosmeticConfig cosmetic = new CosmeticConfig(); + + + @Expose + @ConfigOption(name = "Glowing Dropped Items", desc = "") + @Accordion + public GlowingDroppedItemsConfig glowingDroppedItems = new GlowingDroppedItemsConfig(); + + @Expose + @ConfigOption(name = "Highlight Party Members", desc = "") + @Accordion + public HighlightPartyMembersConfig highlightPartyMembers = new HighlightPartyMembersConfig(); + + @Expose + @Category(name = "Compact Tab List", desc = "Compact Tab List Settings") + @Accordion + public CompactTabListConfig compactTabList = new CompactTabListConfig(); + + @Expose + @ConfigOption(name = "Kick Duration", desc = "") + @Accordion + public KickDurationConfig kickDuration = new KickDurationConfig(); + + @Expose + @ConfigOption(name = "Tracker", desc = "Tracker Config") + @Accordion + public TrackerConfig tracker = new TrackerConfig(); + + @Expose + @ConfigOption(name = "Exp Bottles", desc = "Hides all the experience orbs lying on the ground.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideExpBottles = false; + + @Expose + public Position collectionCounterPos = new Position(10, 10, false, true); + + @Expose + @ConfigOption(name = "Brewing Stand Overlay", desc = "Display the Item names directly inside the Brewing Stand.") + @ConfigEditorBoolean + @FeatureToggle + public boolean brewingStandOverlay = true; + + @Expose + @ConfigOption(name = "Red Scoreboard Numbers", desc = "Hide the red scoreboard numbers on the right side of the screen.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideScoreboardNumbers = false; + + @Expose + @ConfigOption(name = "Hide Piggy", desc = "Replacing 'Piggy' with 'Purse' in the Scoreboard.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hidePiggyScoreboard = true; + + @Expose + @ConfigOption(name = "Explosions Hider", desc = "Hide explosions.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideExplosions = false; + + @Expose + @ConfigOption(name = "CH Join", desc = "Helps buy a Pass for accessing the Crystal Hollows if needed.") + @ConfigEditorBoolean + @FeatureToggle + public boolean crystalHollowsJoin = true; + + @Expose + @ConfigOption(name = "Fire Overlay Hider", desc = "Hide the fire overlay (Like in Skytils).") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideFireOverlay = false; + + @Expose + @ConfigOption(name = "Paste Into Signs", desc = "Allows you to paste the clipboard into signs when you press Ctrl + V.") + @ConfigEditorBoolean + @FeatureToggle + public boolean pasteIntoSigns = true; + + @Expose + @ConfigOption(name = "Movement Speed", desc = "Show the player movement speed in blocks per second.") + @ConfigEditorBoolean + @FeatureToggle + public boolean playerMovementSpeed = false; + + @Expose + public Position playerMovementSpeedPos = new Position(394, 124, false, true); + + @Expose + @ConfigOption(name = "Pet Candy Used", desc = "Show the number of Pet Candy used on a pet.") + @ConfigEditorBoolean + @FeatureToggle + public boolean petCandyUsed = true; + + @Expose + @ConfigOption(name = "Server Restart Title", desc = "Show a title with seconds remaining until the server restarts after a Game Update or Scheduled Restart.") + @ConfigEditorBoolean + @FeatureToggle + public boolean serverRestartTitle = true; + + @Expose + @ConfigOption(name = "Piece Of Wizard Portal", desc = "Restore the Earned By lore line on bought Piece Of Wizard Portal.") + @ConfigEditorBoolean + @FeatureToggle + public boolean restorePieceOfWizardPortalLore = true; + + @Expose + @ConfigOption(name = "Patcher Coords Waypoint", desc = "Highlight the coordinates sent by Patcher.") + @ConfigEditorBoolean + @FeatureToggle + public boolean patcherSendCoordWaypoint = false; + + + @Expose + @ConfigOption(name = "Account Upgrade Reminder", desc = "Remind you to claim account upgrades when complete.") + @ConfigEditorBoolean + @FeatureToggle + public boolean accountUpgradeReminder = true; + + @Expose + @ConfigOption(name = "Superpairs Clicks Alert", desc = "Display an alert when you reach the maximum clicks gained from Chronomatron or Ultrasequencer.") + @ConfigEditorBoolean + @FeatureToggle + public boolean superpairsClicksAlert = false; + + @Expose + @ConfigOption(name = "NEU Heavy Pearls", desc = "Fixing NEU Heavy Pearl detection.") + @ConfigEditorBoolean + @FeatureToggle + public boolean fixNeuHeavyPearls = true; + + @Expose + @ConfigOption( + name = "Time In Limbo", + desc = "Show the time since you entered the limbo.") + @ConfigEditorBoolean + @FeatureToggle + public boolean showTimeInLimbo = true; + + @Expose + @ConfigOption( + name = "Lock Mouse Message", + desc = "Show a message in chat when toggling the /shmouselock.") + @ConfigEditorBoolean + public boolean lockMouseLookChatMessage = true; + + @Expose + public Position showTimeInLimboPosition = new Position(400, 200, 1.3f); + + @Expose + public Position lockedMouseDisplay = new Position(400, 200, 0.8f); + + @Expose + public Position inventoryLoadPos = new Position(394, 124, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/ParticleHiderConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/ParticleHiderConfig.java new file mode 100644 index 000000000000..45f7c445e164 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/ParticleHiderConfig.java @@ -0,0 +1,50 @@ +package at.hannibal2.skyhanni.config.features.misc; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ParticleHiderConfig { + @Expose + @ConfigOption(name = "Blaze Particles", desc = "Hide Blaze particles.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideBlazeParticles = false; + + @Expose + @ConfigOption(name = "Enderman Particles", desc = "Hide Enderman particles.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideEndermanParticles = false; + + @Expose + @ConfigOption(name = "Fireball Particles", desc = "Hide fireball particles.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideFireballParticles = true; + + @Expose + @ConfigOption(name = "Fire Particles", desc = "Hide particles from the fire block.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideFireBlockParticles = true; + + @Expose + @ConfigOption(name = "Smoke Particles", desc = "Hide smoke particles.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideSmokeParticles = false; + + @Expose + @ConfigOption(name = "Far Particles", desc = "Hide particles that are more than 40 blocks away.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideFarParticles = true; + + @Expose + @ConfigOption(name = "Close Redstone Particles", desc = "Hide Redstone particles around the player (appear for some potion effects).") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideCloseRedstoneParticles = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/PocketSackInASackConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/PocketSackInASackConfig.java new file mode 100644 index 000000000000..c3a57d993bb3 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/PocketSackInASackConfig.java @@ -0,0 +1,21 @@ +package at.hannibal2.skyhanni.config.features.misc; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class PocketSackInASackConfig { + + @Expose + @ConfigOption(name = "Show in Overlay", desc = "Show the number of Pocket Sack-In-A-Sack applied on a sack icon as an overlay.") + @ConfigEditorBoolean + @FeatureToggle + public boolean showOverlay = false; + + @Expose + @ConfigOption(name = "Replace In Lore", desc = "Replace how text is displayed in lore.\nShow §eis stitched with 2/3...\n§7Instead of §eis stitched with two...") + @ConfigEditorBoolean + @FeatureToggle + public boolean replaceLore = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/PotionEffectsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/PotionEffectsConfig.java new file mode 100644 index 000000000000..19711ffdbfac --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/PotionEffectsConfig.java @@ -0,0 +1,24 @@ +package at.hannibal2.skyhanni.config.features.misc; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class PotionEffectsConfig { + @Expose + @ConfigOption(name = "Non God Pot Effects", desc = "Display the active potion effects that are not part of the God Pot.") + @ConfigEditorBoolean + @FeatureToggle + public boolean nonGodPotEffectDisplay = false; + + @Expose + @ConfigOption(name = "Show Mixins", desc = "Include God Pot mixins in the Non God Pot Effects display.") + @ConfigEditorBoolean + @FeatureToggle + public boolean nonGodPotEffectShowMixins = false; + + @Expose + public Position nonGodPotEffectPos = new Position(10, 10, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/QuickModMenuSwitchConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/QuickModMenuSwitchConfig.java new file mode 100644 index 000000000000..a1361d4a2c39 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/QuickModMenuSwitchConfig.java @@ -0,0 +1,29 @@ +package at.hannibal2.skyhanni.config.features.misc; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class QuickModMenuSwitchConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Adding a mod list, allowing to quickly switch between different mod menus.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Inside Escape Menu", desc = "Show the mod list while inside the Escape menu.") + @ConfigEditorBoolean + public boolean insideEscapeMenu = true; + + @Expose + @ConfigOption(name = "Inside Inventory", desc = "Show the mod list while inside the player inventory (no chest inventory).") + @ConfigEditorBoolean + public boolean insidePlayerInventory = false; + + @Expose + public Position pos = new Position(-178, 143, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/TeleportPadConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/TeleportPadConfig.java new file mode 100644 index 000000000000..f16165547470 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/TeleportPadConfig.java @@ -0,0 +1,21 @@ +package at.hannibal2.skyhanni.config.features.misc; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class TeleportPadConfig { + + @Expose + @ConfigOption(name = "Compact Name", desc = "Hide the 'Warp to' and 'No Destination' texts over teleport pads.") + @ConfigEditorBoolean + @FeatureToggle + public boolean compactName = false; + + @Expose + @ConfigOption(name = "Inventory Numbers", desc = "Show the number of the teleport pads inside the 'Change Destination' inventory as stack size.") + @ConfigEditorBoolean + @FeatureToggle + public boolean inventoryNumbers = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/TrackerConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/TrackerConfig.java new file mode 100644 index 000000000000..613adde60872 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/TrackerConfig.java @@ -0,0 +1,36 @@ +package at.hannibal2.skyhanni.config.features.misc; + +import at.hannibal2.skyhanni.utils.tracker.SkyHanniTracker; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import io.github.moulberry.moulconfig.observer.Property; + +public class TrackerConfig { + + @Expose + @ConfigOption(name = "Hide with Item Value", desc = "Hide all trackers while the Estimated Item Value is visible.") + @ConfigEditorBoolean + public boolean hideInEstimatedItemValue = true; + + @Expose + @ConfigOption(name = "Show Price From", desc = "Show price from Bazaar or NPC.") + @ConfigEditorDropdown(values = {"Instant Sell", "Sell Offer", "NPC"}) + public int priceFrom = 1; + + @Expose + @ConfigOption(name = "Default Display Mode", desc = "Change the display mode that gets shown on default.") + @ConfigEditorDropdown + public Property defaultDisplayMode = Property.of(SkyHanniTracker.DefaultDisplayMode.REMEMBER_LAST); + + @Expose + @ConfigOption(name = "Recent Drops", desc = "Highlight the amount in green on recently gained items.") + @ConfigEditorBoolean + public boolean showRecentDrops = true; + + @Expose + @ConfigOption(name = "Exclude Hidden", desc = "Exclude hidden items in the total price calculation.") + @ConfigEditorBoolean + public boolean excludeHiddenItemsInPrice = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/TrevorTheTrapperConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/TrevorTheTrapperConfig.java new file mode 100644 index 000000000000..025125c4faa9 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/TrevorTheTrapperConfig.java @@ -0,0 +1,159 @@ +package at.hannibal2.skyhanni.config.features.misc; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.HasLegacyId; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDraggableList; +import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import org.lwjgl.input.Keyboard; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import static at.hannibal2.skyhanni.config.features.misc.TrevorTheTrapperConfig.TrackerEntry.ELUSIVE; +import static at.hannibal2.skyhanni.config.features.misc.TrevorTheTrapperConfig.TrackerEntry.ENDANGERED; +import static at.hannibal2.skyhanni.config.features.misc.TrevorTheTrapperConfig.TrackerEntry.KILLED; +import static at.hannibal2.skyhanni.config.features.misc.TrevorTheTrapperConfig.TrackerEntry.PELTS_PER_HOUR; +import static at.hannibal2.skyhanni.config.features.misc.TrevorTheTrapperConfig.TrackerEntry.QUESTS_STARTED; +import static at.hannibal2.skyhanni.config.features.misc.TrevorTheTrapperConfig.TrackerEntry.SPACER_1; +import static at.hannibal2.skyhanni.config.features.misc.TrevorTheTrapperConfig.TrackerEntry.TITLE; +import static at.hannibal2.skyhanni.config.features.misc.TrevorTheTrapperConfig.TrackerEntry.TOTAL_PELTS; +import static at.hannibal2.skyhanni.config.features.misc.TrevorTheTrapperConfig.TrackerEntry.TRACKABLE; +import static at.hannibal2.skyhanni.config.features.misc.TrevorTheTrapperConfig.TrackerEntry.UNDETECTED; +import static at.hannibal2.skyhanni.config.features.misc.TrevorTheTrapperConfig.TrackerEntry.UNTRACKABLE; + +public class TrevorTheTrapperConfig { + + @Expose + @ConfigOption( + name = "Enable Data Tracker", + desc = "Tracks all of your data from doing Trevor Quests.\n" + + "Shows based on the setting below." + ) + @ConfigEditorBoolean + @FeatureToggle + public boolean dataTracker = true; + + @Expose + @ConfigOption( + name = "Show Between Quests", + desc = "Shows the tracker during and between quests otherwise it will only show during them." + + "Will show in the Trapper's Den regardless. §cToggle 'Enable Data Tracker' above." + ) + @ConfigEditorBoolean + public boolean displayType = true; + + @Expose + @ConfigOption( + name = "Text Format", + desc = "Drag text to change the appearance of the overlay." + ) + @ConfigEditorDraggableList() + public List textFormat = new ArrayList<>(Arrays.asList( + TITLE, + QUESTS_STARTED, + TOTAL_PELTS, + PELTS_PER_HOUR, + SPACER_1, + KILLED, + TRACKABLE, + UNTRACKABLE, + UNDETECTED, + ENDANGERED, + ELUSIVE + )); + + public enum TrackerEntry implements HasLegacyId { + TITLE("§b§lTrevor Data Tracker", 0), + QUESTS_STARTED("§b1,428 §9Quests Started", 1), + TOTAL_PELTS("§b11,281 §5Total Pelts Gained", 2), + PELTS_PER_HOUR("§b2,448 §5Pelts Per Hour", 3), + SPACER_1("", 4), + KILLED("§b850 §cKilled Animals", 5), + SELF_KILLING("§b153 §cSelf Killing Animals", 6), + TRACKABLE("§b788 §fTrackable Animals", 7), + UNTRACKABLE("§b239 §aUntrackable Animals", 8), + UNDETECTED("§b115 §9Undetected Animals", 9), + ENDANGERED("§b73 §5Endangered Animals", 10), + ELUSIVE("§b12 §6Elusive Animals", 11), + ; + + private final String str; + private final int legacyId; + + TrackerEntry(String str, int legacyId) { + this.str = str; + this.legacyId = legacyId; + } + + // Constructor if new enum elements are added post-migration + TrackerEntry(String str) { + this(str, -1); + } + + @Override + public int getLegacyId() { + return legacyId; + } + + @Override + public String toString() { + return str; + } + } + + @Expose + public Position position = new Position(10, 80, false, true); + + @Expose + @ConfigOption(name = "Trapper Solver", desc = "Assists you in finding Trevor's mobs. §eNote: May not always work as expected. " + + "§cWill not help you to find rabbits or sheep in the Oasis!") + @ConfigEditorBoolean + @FeatureToggle + public boolean trapperSolver = true; + + @Expose + @ConfigOption(name = "Mob Dead Warning", desc = "Show a message when Trevor's mob dies.") + @ConfigEditorBoolean + public boolean trapperMobDiedMessage = true; + + @Expose + @ConfigOption(name = "Warp to Trapper", desc = "Warp to Trevor's Den. Works only inside the Farming Islands.") + @ConfigEditorBoolean + @FeatureToggle + public boolean warpToTrapper = false; + + @Expose + @ConfigOption(name = "Accept Trapper Quest", desc = "Click this key after the chat prompt to accept Trevor's quest.") + @ConfigEditorBoolean + @FeatureToggle + public boolean acceptQuest = false; + + @Expose + @ConfigOption(name = "Trapper Hotkey", desc = "Press this key to warp to Trevor's Den or to accept the quest. " + + "§eRequires the relevant above settings to be toggled") + @ConfigEditorKeybind(defaultKey = Keyboard.KEY_NONE) + public int keyBindWarpTrapper = Keyboard.KEY_NONE; + + + @Expose + @ConfigOption(name = "Trapper Cooldown", desc = "Change the color of Trevor and adds a cooldown over his head.") + @ConfigEditorBoolean + @FeatureToggle + public boolean trapperTalkCooldown = true; + + @Expose + @ConfigOption( + name = "Trapper Cooldown GUI", + desc = "Show the cooldown on screen in an overlay (intended for Abiphone users)." + ) + @ConfigEditorBoolean + public boolean trapperCooldownGui = false; + + @Expose + public Position trapperCooldownPos = new Position(10, 10, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/compacttablist/AdvancedPlayerListConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/compacttablist/AdvancedPlayerListConfig.java new file mode 100644 index 000000000000..0bd6360d6da9 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/compacttablist/AdvancedPlayerListConfig.java @@ -0,0 +1,73 @@ +package at.hannibal2.skyhanni.config.features.misc.compacttablist; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class AdvancedPlayerListConfig { + + @Expose + @ConfigOption(name = "Player Sort", desc = "Change the sort order of player names in the tab list.") + @ConfigEditorDropdown(values = {"Rank (Default)", "SB Level", "Name (Abc)", "Ironman/Bingo", "Party/Friends/Guild", "Random"}) + public int playerSortOrder = 0; + + @Expose + @ConfigOption(name = "Invert Sort", desc = "Flip the player list order on its head (also works with default rank).") + @ConfigEditorBoolean + public boolean reverseSort = false; + + @Expose + @ConfigOption(name = "Hide Player Icons", desc = "Hide the icons/skins of player in the tab list.") + @ConfigEditorBoolean + public boolean hidePlayerIcons = false; + + @Expose + @ConfigOption(name = "Hide Rank Color", desc = "Hide the player rank color.") + @ConfigEditorBoolean + public boolean hideRankColor = false; + + @Expose + @ConfigOption(name = "Hide Emblems", desc = "Hide the emblems behind the player name.") + @ConfigEditorBoolean + public boolean hideEmblem = false; + + @Expose + @ConfigOption(name = "Hide Level", desc = "Hide the SkyBlock level numbers.") + @ConfigEditorBoolean + public boolean hideLevel = false; + + @Expose + @ConfigOption(name = "Hide Level Brackets", desc = "Hide the gray brackets in front of and behind the level numbers.") + @ConfigEditorBoolean + public boolean hideLevelBrackets = false; + + @Expose + @ConfigOption(name = "Level Color As Name", desc = "Use the color of the SkyBlock level for the player color.") + @ConfigEditorBoolean + public boolean useLevelColorForName = false; + + @Expose + @ConfigOption(name = "Bingo Rank Number", desc = "Show the number of the bingo rank next to the icon. Useful if you are not so familar with bingo.") + @ConfigEditorBoolean + public boolean showBingoRankNumber = false; + + @Expose + @ConfigOption(name = "Hide Factions", desc = "Hide the icon of the Crimson Isle Faction in the tab list.") + @ConfigEditorBoolean + public boolean hideFactions = false; + + @Expose + @ConfigOption(name = "Mark Special Persons", desc = "Show special icons behind the name of guild members, party members, friends, and marked players.") + @ConfigEditorBoolean + public boolean markSpecialPersons = false; + + @Expose + @ConfigOption( + name = "Mark SkyHanni Devs", + desc = "Adds a §c:O §7behind the tablist name of §cSkyHanni's contributors§7. " + + "§eThose are the folks that coded the mod for you for free :)" + ) + @ConfigEditorBoolean + public boolean markSkyHanniContributors = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/compacttablist/CompactTabListConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/compacttablist/CompactTabListConfig.java new file mode 100644 index 000000000000..2236d886b6cf --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/compacttablist/CompactTabListConfig.java @@ -0,0 +1,27 @@ +package at.hannibal2.skyhanni.config.features.misc.compacttablist; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class CompactTabListConfig { + @Expose + @ConfigOption(name = "Enabled", desc = "Compacts the tablist to make it look much nicer like SBA did. Also " + + "doesn't break god-pot detection and shortens some other lines.") + //made tablist one word here so both searches will pick it up + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Hide Hypixel Adverts", desc = "Hides text from advertising the Hypixel server or store in the tablist.") + @ConfigEditorBoolean + public boolean hideAdverts = false; + + @Expose + @ConfigOption(name = "Advanced Player List", desc = "") + @Accordion + public AdvancedPlayerListConfig advancedPlayerList = new AdvancedPlayerListConfig(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/cosmetic/ArrowTrailConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/cosmetic/ArrowTrailConfig.java new file mode 100644 index 000000000000..7f8a044ed79c --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/cosmetic/ArrowTrailConfig.java @@ -0,0 +1,46 @@ +package at.hannibal2.skyhanni.config.features.misc.cosmetic; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ArrowTrailConfig { + @Expose + @ConfigOption(name = "Enabled", desc = "Draw a colored line behind arrows in the air.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Hide Nonplayer Arrows", desc = "Only shows for arrows the player has shot.") + @ConfigEditorBoolean + public boolean hideOtherArrows = true; + + @Expose + @ConfigOption(name = "Arrow Color", desc = "Color of the line.") + @ConfigEditorColour + public String arrowColor = "0:200:85:255:85"; + + @Expose + @ConfigOption(name = "Player Arrows", desc = "Different color for the line of arrows that you have shot.") + @ConfigEditorBoolean + public boolean handlePlayerArrowsDifferently = false; + + @Expose + @ConfigOption(name = "Player Arrow Color", desc = "Color of the line of your own arrows.") + @ConfigEditorColour + public String playerArrowColor = "0:200:85:255:255"; + + @Expose + @ConfigOption(name = "Time Alive", desc = "Time in seconds until the trail fades out.") + @ConfigEditorSlider(minStep = 0.1f, minValue = 0.1f, maxValue = 10) + public float secondsAlive = 0.5f; + + @Expose + @ConfigOption(name = "Line Width", desc = "Width of the line.") + @ConfigEditorSlider(minStep = 1, minValue = 1, maxValue = 10) + public int lineWidth = 4; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/cosmetic/CosmeticConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/cosmetic/CosmeticConfig.java new file mode 100644 index 000000000000..80b5c60437cc --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/cosmetic/CosmeticConfig.java @@ -0,0 +1,18 @@ +package at.hannibal2.skyhanni.config.features.misc.cosmetic; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class CosmeticConfig { + + @Expose + @ConfigOption(name = "Following Line", desc = "") + @Accordion + public FollowingLineConfig followingLine = new FollowingLineConfig(); + + @Expose + @ConfigOption(name = "Arrow Trail", desc = "") + @Accordion + public ArrowTrailConfig arrowTrail = new ArrowTrailConfig(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/cosmetic/FollowingLineConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/cosmetic/FollowingLineConfig.java new file mode 100644 index 000000000000..87f846e7141f --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/cosmetic/FollowingLineConfig.java @@ -0,0 +1,37 @@ +package at.hannibal2.skyhanni.config.features.misc.cosmetic; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class FollowingLineConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Draw a colored line behind the player.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Line Color", desc = "Color of the line.") + @ConfigEditorColour + public String lineColor = "0:255:255:255:255"; + + @Expose + @ConfigOption(name = "Time Alive", desc = "Time in seconds until the line fades out.") + @ConfigEditorSlider(minStep = 1, minValue = 1, maxValue = 30) + public int secondsAlive = 3; + + @Expose + @ConfigOption(name = "Max Line Width", desc = "Max width of the line.") + @ConfigEditorSlider(minStep = 1, minValue = 1, maxValue = 10) + public int lineWidth = 4; + + @Expose + @ConfigOption(name = "Behind Blocks", desc = "Show behind blocks.") + @ConfigEditorBoolean + public boolean behindBlocks = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/pets/PetConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/pets/PetConfig.java new file mode 100644 index 000000000000..c6a32cee9b61 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/pets/PetConfig.java @@ -0,0 +1,24 @@ +package at.hannibal2.skyhanni.config.features.misc.pets; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class PetConfig { + @Expose + @ConfigOption(name = "Pet Display", desc = "Show the currently active pet.") + @ConfigEditorBoolean + @FeatureToggle + public boolean display = false; + + @Expose + public Position displayPos = new Position(-330, -15, false, true); + + @Expose + @ConfigOption(name = "Pet Experience Tooltip", desc = "") + @Accordion + public PetExperienceToolTipConfig petExperienceToolTip = new PetExperienceToolTipConfig(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/misc/pets/PetExperienceToolTipConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/misc/pets/PetExperienceToolTipConfig.java new file mode 100644 index 000000000000..71ad44ba3e5b --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/misc/pets/PetExperienceToolTipConfig.java @@ -0,0 +1,27 @@ +package at.hannibal2.skyhanni.config.features.misc.pets; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class PetExperienceToolTipConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Show the full pet exp and the progress to level 100 (ignoring rarity) when hovering over a pet while pressing shift key.") + @ConfigEditorBoolean + @FeatureToggle + public boolean petDisplay = true; + + + @Expose + @ConfigOption(name = "Show Always", desc = "Show this info always, even if not pressing shift key.") + @ConfigEditorBoolean + public boolean showAlways = false; + + @Expose + @ConfigOption(name = "Dragon Egg", desc = "For a Golden Dragon Egg, show progress to level 100 instead of 200.") + @ConfigEditorBoolean + public boolean showGoldenDragonEgg = true; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/CruxTalismanDisplayConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/CruxTalismanDisplayConfig.java new file mode 100644 index 000000000000..fc69df292c30 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/CruxTalismanDisplayConfig.java @@ -0,0 +1,30 @@ +package at.hannibal2.skyhanni.config.features.rift; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import io.github.moulberry.moulconfig.observer.Property; + +public class CruxTalismanDisplayConfig { + @Expose + @ConfigOption(name = "Crux Talisman Display", desc = "Display progress of the Crux Talisman on screen.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Compact", desc = "Show a compacted version of the overlay when the talisman is maxed.") + @ConfigEditorBoolean + public boolean compactWhenMaxed = false; + + @Expose + @ConfigOption(name = "Show Bonuses", desc = "Show bonuses you get from the talisman.") + @ConfigEditorBoolean + @FeatureToggle + public Property showBonuses = Property.of(true); + + @Expose + public Position position = new Position(144, 139, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/EnigmaSoulConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/EnigmaSoulConfig.java new file mode 100644 index 000000000000..9b80b718d2e9 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/EnigmaSoulConfig.java @@ -0,0 +1,22 @@ +package at.hannibal2.skyhanni.config.features.rift; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class EnigmaSoulConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Click on Enigma Souls in Rift Guides to highlight their location.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Color", desc = "Color of the Enigma Souls.") + @ConfigEditorColour + public String color = "0:120:13:49:255"; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/MotesOrbsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/MotesOrbsConfig.java new file mode 100644 index 000000000000..ebcdb2e572b4 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/MotesOrbsConfig.java @@ -0,0 +1,28 @@ +package at.hannibal2.skyhanni.config.features.rift; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class MotesOrbsConfig { + + @Expose + @ConfigOption(name = "Highlight Motes Orbs", desc = "Highlight flying Motes Orbs.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Highlight Size", desc = "Set render size for highlighted Motes Orbs.") + @ConfigEditorSlider(minStep = 1, minValue = 1, maxValue = 5) + public int size = 3; + + @Expose + @ConfigOption(name = "Hide Particles", desc = "Hide normal Motes Orbs particles.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideParticles = false; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/RiftConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/RiftConfig.java new file mode 100644 index 000000000000..ca20e01f9e0d --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/RiftConfig.java @@ -0,0 +1,53 @@ +package at.hannibal2.skyhanni.config.features.rift; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.features.rift.area.RiftAreasConfig; +import at.hannibal2.skyhanni.config.features.rift.motes.MotesConfig; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.Category; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class RiftConfig { + + @ConfigOption(name = "Rift Timer", desc = "") + @Accordion + @Expose + public RiftTimerConfig timer = new RiftTimerConfig(); + + @ConfigOption(name = "Crux Talisman Progress", desc = "") + @Accordion + @Expose + public CruxTalismanDisplayConfig cruxTalisman = new CruxTalismanDisplayConfig(); + + @ConfigOption(name = "Enigma Soul Waypoints", desc = "") + @Accordion + @Expose + public EnigmaSoulConfig enigmaSoulWaypoints = new EnigmaSoulConfig(); + + @Category(name = "Rift Areas", desc = "Rift Area Settings") + @Expose + public RiftAreasConfig area = new RiftAreasConfig(); + + @Expose + @Category(name = "Motes", desc = "Motes Sell Price") + public MotesConfig motes = new MotesConfig(); + + @Expose + @ConfigOption(name = "Motes Orbs", desc = "") + @Accordion + public MotesOrbsConfig motesOrbs = new MotesOrbsConfig(); + + @Expose + @ConfigOption(name = "Highlight Guide", desc = "Highlight things to do in the Rift Guide.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightGuide = true; + + @Expose + @ConfigOption(name = "Horsezooka Hider", desc = "Hide horses while holding the Horsezooka in the hand.") + @ConfigEditorBoolean + @FeatureToggle + public boolean horsezookaHider = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/RiftTimerConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/RiftTimerConfig.java new file mode 100644 index 000000000000..f1c7f32dd5e8 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/RiftTimerConfig.java @@ -0,0 +1,30 @@ +package at.hannibal2.skyhanni.config.features.rift; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class RiftTimerConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Show the remaining rift time, max time, percentage, and extra time changes.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Max Time", desc = "Show max time.") + @ConfigEditorBoolean + public boolean maxTime = true; + + @Expose + @ConfigOption(name = "Percentage", desc = "Show percentage.") + @ConfigEditorBoolean + public boolean percentage = true; + + @Expose + public Position timerPosition = new Position(10, 10, false, true); + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/RiftAreasConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/RiftAreasConfig.java new file mode 100644 index 000000000000..397eb2b90175 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/RiftAreasConfig.java @@ -0,0 +1,60 @@ +package at.hannibal2.skyhanni.config.features.rift.area; + +import at.hannibal2.skyhanni.config.features.rift.area.colosseum.ColosseumConfig; +import at.hannibal2.skyhanni.config.features.rift.area.dreadfarm.DreadfarmConfig; +import at.hannibal2.skyhanni.config.features.rift.area.livingcave.LivingCaveConfig; +import at.hannibal2.skyhanni.config.features.rift.area.mirrorverse.MirrorVerseConfig; +import at.hannibal2.skyhanni.config.features.rift.area.stillgorechateau.StillgoreChateauConfig; +import at.hannibal2.skyhanni.config.features.rift.area.westvillage.WestVillageConfig; +import at.hannibal2.skyhanni.config.features.rift.area.wyldwoods.WyldWoodsConfig; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class RiftAreasConfig { + + @ConfigOption(name = "Wyld Woods", desc = "") + @Accordion + @Expose + public WyldWoodsConfig wyldWoods = new WyldWoodsConfig(); + + @ConfigOption(name = "West Village", desc = "") + @Accordion + @Expose + public WestVillageConfig westVillage = new WestVillageConfig(); + + @Expose + @ConfigOption(name = "Dreadfarm", desc = "") + @Accordion + public DreadfarmConfig dreadfarm = new DreadfarmConfig(); + + @ConfigOption(name = "Mirrorverse", desc = "") + @Accordion + @Expose + public MirrorVerseConfig mirrorverse = new MirrorVerseConfig(); + +// @Expose +// @ConfigOption(name = "Village Plaza", desc = "") +// @Accordion +// public VillagePlazaConfig villagePlaza = new VillagePlazaConfig(); + + @Expose + @ConfigOption(name = "Living Cave", desc = "") + @Accordion + public LivingCaveConfig livingCave = new LivingCaveConfig(); + + @Expose + @ConfigOption(name = "Colosseum", desc = "") + @Accordion + public ColosseumConfig colosseum = new ColosseumConfig(); + + @Expose + @ConfigOption(name = "Stillgore Chateau", desc = "") + @Accordion + public StillgoreChateauConfig stillgoreChateau = new StillgoreChateauConfig(); + +// @Expose +// @ConfigOption(name = "Mountaintop", desc = "") +// @Accordion +// public MountaintopConfig mountaintop = new MountaintopConfig(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/colosseum/ColosseumConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/colosseum/ColosseumConfig.java new file mode 100644 index 000000000000..d9a662f0d9a5 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/colosseum/ColosseumConfig.java @@ -0,0 +1,15 @@ +package at.hannibal2.skyhanni.config.features.rift.area.colosseum; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ColosseumConfig { + + @Expose + @ConfigOption(name = "Highlight Blobbercysts", desc = "Highlight Blobbercysts in Bacte fight.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightBlobbercysts = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/dreadfarm/DreadfarmConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/dreadfarm/DreadfarmConfig.java new file mode 100644 index 000000000000..9a17c70b8041 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/dreadfarm/DreadfarmConfig.java @@ -0,0 +1,26 @@ +package at.hannibal2.skyhanni.config.features.rift.area.dreadfarm; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class DreadfarmConfig { + @Expose + @ConfigOption(name = "Agaricus Cap", desc = "Counts down the time until §eAgaricus Cap (Mushroom) " + + "§7changes color from brown to red and is breakable.") + @ConfigEditorBoolean + @FeatureToggle + public boolean agaricusCap = true; + + @ConfigOption(name = "Volt Crux", desc = "") + @Accordion + @Expose + public VoltCruxConfig voltCrux = new VoltCruxConfig(); + + @ConfigOption(name = "Wilted Berberis", desc = "") + @Accordion + @Expose + public WiltedBerberisConfig wiltedBerberis = new WiltedBerberisConfig(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/dreadfarm/VoltCruxConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/dreadfarm/VoltCruxConfig.java new file mode 100644 index 000000000000..307e57d45675 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/dreadfarm/VoltCruxConfig.java @@ -0,0 +1,33 @@ +package at.hannibal2.skyhanni.config.features.rift.area.dreadfarm; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class VoltCruxConfig { + + @Expose + @ConfigOption(name = "Volt Warning", desc = "Shows a warning while a Volt is discharging lightning.") + @ConfigEditorBoolean + @FeatureToggle + public boolean voltWarning = true; + + @Expose + @ConfigOption(name = "Volt Range Highlighter", desc = "Shows the area in which a Volt might strike lightning.") + @ConfigEditorBoolean + @FeatureToggle + public boolean voltRange = true; + + @Expose + @ConfigOption(name = "Volt Range Highlighter Color", desc = "In which color should the Volt range be highlighted?") + @ConfigEditorColour + public String voltColour = "0:60:0:0:255"; + + @Expose + @ConfigOption(name = "Volt Mood Color", desc = "Change the color of the Volt enemy depending on their mood.") + @ConfigEditorBoolean + @FeatureToggle + public boolean voltMoodMeter = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/dreadfarm/WiltedBerberisConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/dreadfarm/WiltedBerberisConfig.java new file mode 100644 index 000000000000..9cad5a4750d8 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/dreadfarm/WiltedBerberisConfig.java @@ -0,0 +1,26 @@ +package at.hannibal2.skyhanni.config.features.rift.area.dreadfarm; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class WiltedBerberisConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Show Wilted Berberis helper.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Only on Farmland", desc = "Only show the helper while standing on Farmland blocks.") + @ConfigEditorBoolean + public boolean onlyOnFarmland = false; + + @Expose + @ConfigOption(name = "Hide Particles", desc = "Hide the Wilted Berberis particles.") + @ConfigEditorBoolean + public boolean hideparticles = false; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/livingcave/DefenseBlockConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/livingcave/DefenseBlockConfig.java new file mode 100644 index 000000000000..1754afb1ee2c --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/livingcave/DefenseBlockConfig.java @@ -0,0 +1,29 @@ +package at.hannibal2.skyhanni.config.features.rift.area.livingcave; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import io.github.moulberry.moulconfig.observer.Property; + +public class DefenseBlockConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Show a line between Defense blocks and the mob and highlight the blocks.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Hide Particles", desc = "Hide particles around Defense Blocks.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideParticles = false; + + @Expose + @ConfigOption(name = "Color", desc = "Set the color of the lines, blocks and the entity.") + @ConfigEditorColour + public Property color = Property.of("0:255:77:104:255"); + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/livingcave/LivingCaveConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/livingcave/LivingCaveConfig.java new file mode 100644 index 000000000000..620238538737 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/livingcave/LivingCaveConfig.java @@ -0,0 +1,23 @@ +package at.hannibal2.skyhanni.config.features.rift.area.livingcave; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class LivingCaveConfig { + + @Expose + @ConfigOption(name = "Living Metal Suit Progress", desc = "") + @Accordion + public LivingMetalSuitProgressConfig livingMetalSuitProgress = new LivingMetalSuitProgressConfig(); + + @Expose + @ConfigOption(name = "Defense Blocks", desc = "") + @Accordion + public DefenseBlockConfig defenseBlockConfig = new DefenseBlockConfig(); + + @Expose + @ConfigOption(name = "Living Metal Helper", desc = "") + @Accordion + public LivingCaveLivingMetalConfig livingCaveLivingMetalConfig = new LivingCaveLivingMetalConfig(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/livingcave/LivingCaveLivingMetalConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/livingcave/LivingCaveLivingMetalConfig.java new file mode 100644 index 000000000000..aab75d5710fd --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/livingcave/LivingCaveLivingMetalConfig.java @@ -0,0 +1,22 @@ +package at.hannibal2.skyhanni.config.features.rift.area.livingcave; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class LivingCaveLivingMetalConfig { + + @Expose + @ConfigOption(name = "Living Metal", desc = "Show a moving animation between Living Metal and the next block.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Hide Particles", desc = "Hide Living Metal particles.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideParticles = false; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/livingcave/LivingMetalSuitProgressConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/livingcave/LivingMetalSuitProgressConfig.java new file mode 100644 index 000000000000..d24520dc1414 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/livingcave/LivingMetalSuitProgressConfig.java @@ -0,0 +1,24 @@ +package at.hannibal2.skyhanni.config.features.rift.area.livingcave; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class LivingMetalSuitProgressConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Display Living Metal Suit progress.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Compact", desc = "Show a compacted version of the overlay when the set is maxed.") + @ConfigEditorBoolean + public boolean compactWhenMaxed = false; + + @Expose + public Position position = new Position(100, 100); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/LavaMazeConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/LavaMazeConfig.java new file mode 100644 index 000000000000..b3198cc4ca53 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/LavaMazeConfig.java @@ -0,0 +1,39 @@ +package at.hannibal2.skyhanni.config.features.rift.area.mirrorverse; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import io.github.moulberry.moulconfig.observer.Property; + +public class LavaMazeConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Helps solving the lava maze in the Mirrorverse by showing the correct way.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Look Ahead", desc = "Change how many platforms should be shown in front of you.") + @ConfigEditorSlider(minStep = 1, maxValue = 30, minValue = 1) + public Property lookAhead = Property.of(3); + + @Expose + @ConfigOption(name = "Rainbow Color", desc = "Show the rainbow color effect instead of a boring monochrome.") + @ConfigEditorBoolean + public Property rainbowColor = Property.of(true); + + @Expose + @ConfigOption(name = "Monochrome Color", desc = "Set a boring monochrome color for the parkour platforms.") + @ConfigEditorColour + public Property monochromeColor = Property.of("0:60:0:0:255"); + + @Expose + @ConfigOption(name = "Hide Others Players", desc = "Hide other players while doing the lava maze.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hidePlayers = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/MirrorVerseConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/MirrorVerseConfig.java new file mode 100644 index 000000000000..e9332497235b --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/MirrorVerseConfig.java @@ -0,0 +1,29 @@ +package at.hannibal2.skyhanni.config.features.rift.area.mirrorverse; + +import at.hannibal2.skyhanni.config.features.rift.area.mirrorverse.danceroomhelper.DanceRoomHelperConfig; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class MirrorVerseConfig { + + @ConfigOption(name = "Lava Maze", desc = "") + @Accordion + @Expose + public LavaMazeConfig lavaMazeConfig = new LavaMazeConfig(); + + @ConfigOption(name = "Upside Down Parkour", desc = "") + @Accordion + @Expose + public UpsideDownParkourConfig upsideDownParkour = new UpsideDownParkourConfig(); + + @ConfigOption(name = "Dance Room Helper", desc = "") + @Accordion + @Expose + public DanceRoomHelperConfig danceRoomHelper = new DanceRoomHelperConfig(); + + @ConfigOption(name = "Tubulator", desc = "") + @Accordion + @Expose + public TubulatorConfig tubulatorConfig = new TubulatorConfig(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/TubulatorConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/TubulatorConfig.java new file mode 100644 index 000000000000..586ce2f4ee1f --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/TubulatorConfig.java @@ -0,0 +1,44 @@ +package at.hannibal2.skyhanni.config.features.rift.area.mirrorverse; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import io.github.moulberry.moulconfig.observer.Property; + +public class TubulatorConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Highlights the location of the invisible Tubulator blocks (Laser Parkour).") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Look Ahead", desc = "Change how many platforms should be shown in front of you.") + @ConfigEditorSlider(minStep = 1, maxValue = 30, minValue = 1) + public Property lookAhead = Property.of(2); + + @Expose + @ConfigOption(name = "Outline", desc = "Outlines the top edge of the platforms.") + @ConfigEditorBoolean + public boolean outline = true; + + @Expose + @ConfigOption(name = "Rainbow Color", desc = "Show the rainbow color effect instead of a boring monochrome.") + @ConfigEditorBoolean + public Property rainbowColor = Property.of(true); + + @Expose + @ConfigOption(name = "Monochrome Color", desc = "Set a boring monochrome color for the parkour platforms.") + @ConfigEditorColour + public Property monochromeColor = Property.of("0:60:0:0:255"); + + @Expose + @ConfigOption(name = "Hide Other Players", desc = "Hide other players while doing the lava maze.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hidePlayers = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/UpsideDownParkourConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/UpsideDownParkourConfig.java new file mode 100644 index 000000000000..e8712f3105bf --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/UpsideDownParkourConfig.java @@ -0,0 +1,44 @@ +package at.hannibal2.skyhanni.config.features.rift.area.mirrorverse; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; +import io.github.moulberry.moulconfig.observer.Property; + +public class UpsideDownParkourConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Helps solving the upside down parkour in the Mirrorverse by showing the correct way.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Look Ahead", desc = "Change how many platforms should be shown in front of you.") + @ConfigEditorSlider(minStep = 1, maxValue = 9, minValue = 1) + public Property lookAhead = Property.of(3); + + @Expose + @ConfigOption(name = "Outline", desc = "Outlines the top edge of the platforms.") + @ConfigEditorBoolean + public boolean outline = true; + + @Expose + @ConfigOption(name = "Rainbow Color", desc = "Show the rainbow color effect instead of a boring monochrome.") + @ConfigEditorBoolean + public Property rainbowColor = Property.of(true); + + @Expose + @ConfigOption(name = "Monochrome Color", desc = "Set a boring monochrome color for the parkour platforms.") + @ConfigEditorColour + public Property monochromeColor = Property.of("0:60:0:0:255"); + + @Expose + @ConfigOption(name = "Hide Others Players", desc = "Hide other players while doing the upside down parkour.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hidePlayers = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/danceroomhelper/DanceRoomHelperConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/danceroomhelper/DanceRoomHelperConfig.java new file mode 100644 index 000000000000..a5b61aee8941 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/danceroomhelper/DanceRoomHelperConfig.java @@ -0,0 +1,48 @@ +package at.hannibal2.skyhanni.config.features.rift.area.mirrorverse.danceroomhelper; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import at.hannibal2.skyhanni.config.features.rift.area.mirrorverse.danceroomhelper.danceroomformatting.DanceRoomFormattingConfig; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class DanceRoomHelperConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Helps to solve the dance room in the Mirrorverse by showing multiple tasks at once.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Lines to Show", desc = "How many tasks you should see.") + @ConfigEditorSlider(minStep = 1, maxValue = 49, minValue = 1) + public int lineToShow = 3; + + @Expose + @ConfigOption(name = "Space", desc = "Change the space between each line.") + @ConfigEditorSlider(minStep = 1, maxValue = 10, minValue = -5) + public int extraSpace = 0; + + @Expose + @ConfigOption(name = "Hide Other Players", desc = "Hide other players inside the dance room.") + @ConfigEditorBoolean + public boolean hidePlayers = false; + + @Expose + @ConfigOption(name = "Hide Title", desc = "Hide Instructions, \"§aIt's happening!\" §7and \"§aKeep it up!\" §7titles.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideOriginalTitle = false; + + @Expose + @ConfigOption(name = "Formatting", desc = "") + @Accordion + public DanceRoomFormattingConfig danceRoomFormatting = new DanceRoomFormattingConfig(); + + @Expose + public Position position = new Position(442, 239, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/danceroomhelper/danceroomformatting/ColorConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/danceroomhelper/danceroomformatting/ColorConfig.java new file mode 100644 index 000000000000..71f3013a6e2a --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/danceroomhelper/danceroomformatting/ColorConfig.java @@ -0,0 +1,42 @@ +package at.hannibal2.skyhanni.config.features.rift.area.mirrorverse.danceroomhelper.danceroomformatting; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorText; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ColorConfig { + @Expose + @ConfigOption(name = "Move", desc = "Color for the Move instruction") + @ConfigEditorText + public String move = "&e"; + + @Expose + @ConfigOption(name = "Stand", desc = "Color for the Stand instruction") + @ConfigEditorText + public String stand = "&e"; + + @Expose + @ConfigOption(name = "Sneak", desc = "Color for the Sneak instruction") + @ConfigEditorText + public String sneak = "&5"; + + @Expose + @ConfigOption(name = "Jump", desc = "Color for the Jump instruction") + @ConfigEditorText + public String jump = "&b"; + + @Expose + @ConfigOption(name = "Punch", desc = "Color for the Punch instruction") + @ConfigEditorText + public String punch = "&d"; + + @Expose + @ConfigOption(name = "Countdown", desc = "Color for the Countdown") + @ConfigEditorText + public String countdown = "&f"; + + @Expose + @ConfigOption(name = "Default", desc = "Fallback color") + @ConfigEditorText + public String fallback = "&f"; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/danceroomhelper/danceroomformatting/DanceRoomFormattingConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/danceroomhelper/danceroomformatting/DanceRoomFormattingConfig.java new file mode 100644 index 000000000000..1c35a3924bb9 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/mirrorverse/danceroomhelper/danceroomformatting/DanceRoomFormattingConfig.java @@ -0,0 +1,29 @@ +package at.hannibal2.skyhanni.config.features.rift.area.mirrorverse.danceroomhelper.danceroomformatting; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorText; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class DanceRoomFormattingConfig { + + @Expose + @ConfigOption(name = "Now", desc = "Formatting for \"Now:\"") + @ConfigEditorText + public String now = "&7Now:"; + + @Expose + @ConfigOption(name = "Next", desc = "Formatting for \"Next:\"") + @ConfigEditorText + public String next = "&7Next:"; + + @Expose + @ConfigOption(name = "Later", desc = "Formatting for \"Later:\"") + @ConfigEditorText + public String later = "&7Later:"; + + @Expose + @ConfigOption(name = "Color Option", desc = "") + @Accordion + public ColorConfig color = new ColorConfig(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/stillgorechateau/EffigiesConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/stillgorechateau/EffigiesConfig.java new file mode 100644 index 000000000000..62a20c0e05a6 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/stillgorechateau/EffigiesConfig.java @@ -0,0 +1,37 @@ +package at.hannibal2.skyhanni.config.features.rift.area.stillgorechateau; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class EffigiesConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Show locations of inactive Blood Effigies.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Respawning Soon", desc = "Show effigies that are about to respawn.") + @ConfigEditorBoolean + @FeatureToggle + public boolean respawningSoon = false; + + @Expose + @ConfigOption(name = "Respawning Time", desc = "Time before effigies respawn to show.") + @ConfigEditorSlider( + minValue = 1, + maxValue = 15, + minStep = 1 + ) + public int respwningSoonTime = 3; + + @Expose + @ConfigOption(name = "Unknown Times", desc = "Show effigies without known time.") + @ConfigEditorBoolean + @FeatureToggle + public boolean unknownTime = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/stillgorechateau/StillgoreChateauConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/stillgorechateau/StillgoreChateauConfig.java new file mode 100644 index 000000000000..761b7c1d2883 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/stillgorechateau/StillgoreChateauConfig.java @@ -0,0 +1,14 @@ +package at.hannibal2.skyhanni.config.features.rift.area.stillgorechateau; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class StillgoreChateauConfig { + + @Expose + @ConfigOption(name = "Blood Effigies", desc = "") + @Accordion + public EffigiesConfig bloodEffigies = new EffigiesConfig(); + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/westvillage/KloonHackingConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/westvillage/KloonHackingConfig.java new file mode 100644 index 000000000000..346747aab340 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/westvillage/KloonHackingConfig.java @@ -0,0 +1,27 @@ +package at.hannibal2.skyhanni.config.features.rift.area.westvillage; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class KloonHackingConfig { + + @Expose + @ConfigOption(name = "Hacking Solver", desc = "Highlights the correct button to click in the hacking inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean solver = true; + + @Expose + @ConfigOption(name = "Color Guide", desc = "Tells you which color to pick.") + @ConfigEditorBoolean + @FeatureToggle + public boolean colour = true; + + @Expose + @ConfigOption(name = "Terminal Waypoints", desc = "While wearing the helmet, waypoints will appear at each terminal location.") + @ConfigEditorBoolean + @FeatureToggle + public boolean waypoints = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/westvillage/WestVillageConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/westvillage/WestVillageConfig.java new file mode 100644 index 000000000000..273080489c7c --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/westvillage/WestVillageConfig.java @@ -0,0 +1,13 @@ +package at.hannibal2.skyhanni.config.features.rift.area.westvillage; + +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class WestVillageConfig { + + @ConfigOption(name = "Kloon Hacking", desc = "") + @Accordion + @Expose + public KloonHackingConfig hacking = new KloonHackingConfig(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/wyldwoods/LarvasConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/wyldwoods/LarvasConfig.java new file mode 100644 index 000000000000..b7a7aa240c8a --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/wyldwoods/LarvasConfig.java @@ -0,0 +1,22 @@ +package at.hannibal2.skyhanni.config.features.rift.area.wyldwoods; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class LarvasConfig { + + @Expose + @ConfigOption(name = "Highlight", desc = "Highlight §cLarvas on trees §7while holding a §eLarva Hook §7in the hand.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlight = true; + + @Expose + @ConfigOption(name = "Color", desc = "Color of the Larvas.") + @ConfigEditorColour + public String highlightColor = "0:120:13:49:255"; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/wyldwoods/OdonataConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/wyldwoods/OdonataConfig.java new file mode 100644 index 000000000000..e32e9e01be0a --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/wyldwoods/OdonataConfig.java @@ -0,0 +1,23 @@ +package at.hannibal2.skyhanni.config.features.rift.area.wyldwoods; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class OdonataConfig { + + @Expose + @ConfigOption(name = "Highlight", desc = "Highlight the small §cOdonatas §7flying around the trees while holding an " + + "§eEmpty Odonata Bottle §7in the hand.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlight = true; + + @Expose + @ConfigOption(name = "Color", desc = "Color of the Odonatas.") + @ConfigEditorColour + public String highlightColor = "0:120:13:49:255"; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/wyldwoods/WyldWoodsConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/wyldwoods/WyldWoodsConfig.java new file mode 100644 index 000000000000..3eae50fb5ce3 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/area/wyldwoods/WyldWoodsConfig.java @@ -0,0 +1,27 @@ +package at.hannibal2.skyhanni.config.features.rift.area.wyldwoods; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class WyldWoodsConfig { + + @Expose + @ConfigOption(name = "Shy Crux Warning", desc = "Shows a warning when a Shy Crux is going to steal your time. " + + "Useful if you play without volume.") + @ConfigEditorBoolean + @FeatureToggle + public boolean shyWarning = true; + + @ConfigOption(name = "Larvas", desc = "") + @Accordion + @Expose + public LarvasConfig larvas = new LarvasConfig(); + + @ConfigOption(name = "Odonatas", desc = "") + @Accordion + @Expose + public OdonataConfig odonata = new OdonataConfig(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/motes/InventoryValueConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/motes/InventoryValueConfig.java new file mode 100644 index 000000000000..297a83a1c24b --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/motes/InventoryValueConfig.java @@ -0,0 +1,25 @@ +package at.hannibal2.skyhanni.config.features.rift.motes; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class InventoryValueConfig { + @Expose + @ConfigOption(name = "Inventory Value", desc = "Show total Motes NPC price for the current opened inventory.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Number Format Type", desc = "Short: 1.2M\n" + + "Long: 1,200,000") + @ConfigEditorDropdown(values = {"Short", "Long"}) + public int formatType = 0; + + @Expose + public Position position = new Position(126, 156, false, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/rift/motes/MotesConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/rift/motes/MotesConfig.java new file mode 100644 index 000000000000..2a65a6652098 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/rift/motes/MotesConfig.java @@ -0,0 +1,27 @@ +package at.hannibal2.skyhanni.config.features.rift.motes; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class MotesConfig { + + @Expose + @ConfigOption(name = "Show Motes Price", desc = "Show the Motes NPC price in the item lore.") + @ConfigEditorBoolean + @FeatureToggle + public boolean showPrice = true; + + @Expose + @ConfigOption(name = "Burger Stacks", desc = "Set your McGrubber's burger stacks.") + @ConfigEditorSlider(minStep = 1, minValue = 0, maxValue = 5) + public int burgerStacks = 0; + + @Expose + @ConfigOption(name = "Inventory Value", desc = "") + @Accordion + public InventoryValueConfig inventoryValue = new InventoryValueConfig(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/slayer/ItemProfitTrackerConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/ItemProfitTrackerConfig.java new file mode 100644 index 000000000000..5fc67993bd79 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/ItemProfitTrackerConfig.java @@ -0,0 +1,44 @@ +package at.hannibal2.skyhanni.config.features.slayer; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ItemProfitTrackerConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Count all items you pick up while doing slayer, " + + "keep track of how much you pay for starting slayers and calculating the overall profit.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + public Position pos = new Position(20, 20, false, true); + + @Expose + @ConfigOption(name = "Price in Chat", desc = "Show an extra chat message when you pick up an item. " + + "(This contains name, amount and price)") + @ConfigEditorBoolean + @FeatureToggle + public boolean priceInChat = false; + + @Expose + @ConfigOption(name = "Minimum Price", desc = "Items below this price will not show up in chat.") + @ConfigEditorSlider(minValue = 1, maxValue = 5_000_000, minStep = 1) + public int minimumPrice = 100_000; + + @Expose + @ConfigOption(name = "Title Warning", desc = "Show a title for expensive item pickups.") + @ConfigEditorBoolean + @FeatureToggle + public boolean titleWarning = false; + + @Expose + @ConfigOption(name = "Title Price", desc = "Items above this price will show up as a title.") + @ConfigEditorSlider(minValue = 1, maxValue = 20_000_000, minStep = 1) + public int minimumPriceWarning = 500_000; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/slayer/ItemsOnGroundConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/ItemsOnGroundConfig.java new file mode 100644 index 000000000000..4f3e2428d869 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/ItemsOnGroundConfig.java @@ -0,0 +1,21 @@ +package at.hannibal2.skyhanni.config.features.slayer; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class ItemsOnGroundConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Show the name and price of items laying on the ground. §cOnly in slayer areas!") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Minimum Price", desc = "Items below this price will be ignored.") + @ConfigEditorSlider(minValue = 1, maxValue = 1_000_000, minStep = 1) + public int minimumPrice = 50_000; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/slayer/RngMeterDisplayConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/RngMeterDisplayConfig.java new file mode 100644 index 000000000000..04b6c6704135 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/RngMeterDisplayConfig.java @@ -0,0 +1,30 @@ +package at.hannibal2.skyhanni.config.features.slayer; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class RngMeterDisplayConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Display amount of bosses needed until next RNG meter drop.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Warn Empty", desc = "Warn when no item is set in the RNG Meter.") + @ConfigEditorBoolean + public boolean warnEmpty = false; + + @Expose + @ConfigOption(name = "Hide Chat", desc = "Hide the RNG meter message from chat if current item is selected.") + @ConfigEditorBoolean + public boolean hideChat = true; + + @Expose + public Position pos = new Position(410, 110, false, true); + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/slayer/SlayerBossWarningConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/SlayerBossWarningConfig.java new file mode 100644 index 000000000000..1376a29a2795 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/SlayerBossWarningConfig.java @@ -0,0 +1,26 @@ +package at.hannibal2.skyhanni.config.features.slayer; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class SlayerBossWarningConfig { + + @Expose + @ConfigOption(name = "Enabled", desc = "Send a title when your boss is about to spawn.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = false; + + @Expose + @ConfigOption(name = "Percent", desc = "The percentage at which the title and sound should be sent.") + @ConfigEditorSlider(minStep = 1, minValue = 50, maxValue = 90) + public int percent = 80; + + @Expose + @ConfigOption(name = "Repeat", desc = "Resend the title and sound on every kill after reaching the configured percent value.") + @ConfigEditorBoolean + public boolean repeat = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/slayer/SlayerConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/SlayerConfig.java new file mode 100644 index 000000000000..89128e7ff761 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/SlayerConfig.java @@ -0,0 +1,77 @@ +package at.hannibal2.skyhanni.config.features.slayer; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.features.slayer.blaze.BlazeConfig; +import at.hannibal2.skyhanni.config.features.slayer.endermen.EndermanConfig; +import at.hannibal2.skyhanni.config.features.slayer.vampire.VampireConfig; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.Category; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class SlayerConfig { + + @Expose + @Category(name = "Endermen", desc = "Endermen Slayer Feature") + @Accordion + public EndermanConfig endermen = new EndermanConfig(); + + @Expose + @Category(name = "Blaze", desc = "Blaze Slayer Features") + public BlazeConfig blazes = new BlazeConfig(); + + @Expose + @Category(name = "Vampire", desc = "Vampire Slayer Features") + public VampireConfig vampire = new VampireConfig(); + + @Expose + @ConfigOption(name = "Item Profit Tracker", desc = "") + @Accordion + public ItemProfitTrackerConfig itemProfitTracker = new ItemProfitTrackerConfig(); + + @Expose + @ConfigOption(name = "Items on Ground", desc = "") + @Accordion + public ItemsOnGroundConfig itemsOnGround = new ItemsOnGroundConfig(); + + @Expose + @ConfigOption(name = "RNG Meter Display", desc = "") + @Accordion + public RngMeterDisplayConfig rngMeterDisplay = new RngMeterDisplayConfig(); + + @Expose + @ConfigOption(name = "Boss Spawn Warning", desc = "") + @Accordion + public SlayerBossWarningConfig slayerBossWarning = new SlayerBossWarningConfig(); + + @Expose + @ConfigOption(name = "Miniboss Highlight", desc = "Highlight Slayer Mini-Boss in blue color.") + @ConfigEditorBoolean + @FeatureToggle + public boolean slayerMinibossHighlight = false; + + @Expose + @ConfigOption(name = "Line to Miniboss", desc = "Adds a line to every Slayer Mini-Boss around you.") + @ConfigEditorBoolean + @FeatureToggle + public boolean slayerMinibossLine = false; + + @Expose + @ConfigOption(name = "Hide Mob Names", desc = "Hide the name of the mobs you need to kill in order for the Slayer boss to spawn. Exclude mobs that are damaged, corrupted, runic or semi rare.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideMobNames = false; + + @Expose + @ConfigOption(name = "Quest Warning", desc = "Warning when wrong Slayer quest is selected, or killing mobs for the wrong Slayer.") + @ConfigEditorBoolean + @FeatureToggle + public boolean questWarning = true; + + @Expose + @ConfigOption(name = "Quest Warning Title", desc = "Sends a title when warning.") + @ConfigEditorBoolean + @FeatureToggle + public boolean questWarningTitle = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/slayer/blaze/BlazeConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/blaze/BlazeConfig.java new file mode 100644 index 000000000000..c631b10f879e --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/blaze/BlazeConfig.java @@ -0,0 +1,32 @@ +package at.hannibal2.skyhanni.config.features.slayer.blaze; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class BlazeConfig { + @Expose + @ConfigOption(name = "Hellion Shields", desc = "") + @Accordion + public BlazeHellionConfig hellion = new BlazeHellionConfig(); + + + @Expose + @ConfigOption(name = "Fire Pits", desc = "Warning when the fire pit phase starts for the Blaze Slayer tier 3 and 4.") + @ConfigEditorBoolean + @FeatureToggle + public boolean firePitsWarning = false; + + @Expose + @ConfigOption(name = "Phase Display", desc = "Show the current phase of the Blaze Slayer boss.") + @ConfigEditorBoolean + public boolean phaseDisplay = false; + + @Expose + @ConfigOption(name = "Clear View", desc = "Hide particles and fireballs near Blaze Slayer bosses and demons.") + @ConfigEditorBoolean + @FeatureToggle + public boolean clearView = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/slayer/blaze/BlazeHellionConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/blaze/BlazeHellionConfig.java new file mode 100644 index 000000000000..4a5e4af8ce99 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/blaze/BlazeHellionConfig.java @@ -0,0 +1,45 @@ +package at.hannibal2.skyhanni.config.features.slayer.blaze; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorDropdown; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class BlazeHellionConfig { + @Expose + @ConfigOption(name = "Colored Mobs", desc = "Color the Blaze Slayer boss and the demons in the right hellion shield color.") + @ConfigEditorBoolean + @FeatureToggle + public boolean coloredMobs = false; + + @Expose + @ConfigOption(name = "Blaze Daggers", desc = "Faster and permanent display for the Blaze Slayer daggers.") + @ConfigEditorBoolean + @FeatureToggle + public boolean daggers = false; + + @Expose + @ConfigOption(name = "Right Dagger", desc = "Mark the right dagger to use for Blaze Slayer in the dagger overlay.") + @ConfigEditorBoolean + @FeatureToggle + public boolean markRightHellionShield = false; + + @Expose + @ConfigOption(name = "First Dagger", desc = "Select the first, left sided dagger for the display.") + @ConfigEditorDropdown(values = {"Spirit/Crystal", "Ashen/Auric"}) + public int firstDagger = 0; + + @Expose + @ConfigOption(name = "Hide Chat", desc = "Remove the wrong Blaze Slayer dagger messages from chat.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideDaggerWarning = false; + + @Expose + public Position positionTop = new Position(-475, 173, 4.4f, true); + + @Expose + public Position positionBottom = new Position(-475, 230, 3.2f, true); +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/slayer/endermen/EndermanBeaconConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/endermen/EndermanBeaconConfig.java new file mode 100644 index 000000000000..32592e4b9fe0 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/endermen/EndermanBeaconConfig.java @@ -0,0 +1,46 @@ +package at.hannibal2.skyhanni.config.features.slayer.endermen; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class EndermanBeaconConfig { + + @Expose + @ConfigOption(name = "Highlight Beacon", + desc = "Highlight the Enderman Slayer Yang Glyph (beacon) in red color and added a timer for when he explodes. " + + "Supports beacon in hand and beacon flying.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightBeacon = true; + + @Expose + @ConfigOption(name = "Beacon Color", desc = "Color of the beacon.") + @ConfigEditorColour + public String beaconColor = "0:255:255:0:88"; + + @Expose + @ConfigOption(name = "Show Warning", desc = "Displays a warning mid-screen when the Enderman Slayer throws a Yang Glyph (beacon).") + @ConfigEditorBoolean + @FeatureToggle + public boolean showWarning = false; + + @Expose + @ConfigOption(name = "Show Line", desc = "Draw a line starting at your crosshair to the beacon.") + @ConfigEditorBoolean + @FeatureToggle + public boolean showLine = false; + + @Expose + @ConfigOption(name = "Line Color", desc = "Color of the line.") + @ConfigEditorColour + public String lineColor = "0:255:255:0:88"; + + @Expose + @ConfigOption(name = "Line Width", desc = "Width of the line.") + @ConfigEditorSlider(minStep = 1, minValue = 1, maxValue = 10) + public int lineWidth = 3; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/slayer/endermen/EndermanConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/endermen/EndermanConfig.java new file mode 100644 index 000000000000..a31d9f82af42 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/endermen/EndermanConfig.java @@ -0,0 +1,31 @@ +package at.hannibal2.skyhanni.config.features.slayer.endermen; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class EndermanConfig { + @Expose + @ConfigOption(name = "Yang Glyph (Beacon)", desc = "") + @Accordion + public EndermanBeaconConfig beacon = new EndermanBeaconConfig(); + + @Expose + @ConfigOption(name = "Highlight Nukekubi Skulls", desc = "Highlights the Enderman Slayer Nukekubi Skulls (Eyes).") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlightNukekebi = false; + + @Expose + @ConfigOption(name = "Phase Display", desc = "Show the current phase of the Enderman Slayer in damage indicator.") + @ConfigEditorBoolean + public boolean phaseDisplay = false; + + @Expose + @ConfigOption(name = "Hide Particles", desc = "Hide particles around Enderman Slayer bosses and Mini-Bosses.") + @ConfigEditorBoolean + @FeatureToggle + public boolean hideParticles = false; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/BloodIchorConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/BloodIchorConfig.java new file mode 100644 index 000000000000..7daca5ea3523 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/BloodIchorConfig.java @@ -0,0 +1,38 @@ +package at.hannibal2.skyhanni.config.features.slayer.vampire; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class BloodIchorConfig { + @Expose + @ConfigOption(name = "Highlight Blood Ichor", desc = "Highlight the Blood Ichor.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlight = false; + + @Expose + @ConfigOption(name = "Beacon Beam", desc = "Render a beacon beam where the Blood Ichor is.") + @ConfigEditorBoolean + @FeatureToggle + public boolean renderBeam = true; + + @Expose + @ConfigOption(name = "Color", desc = "Highlight color.") + @ConfigEditorColour + public String color = "0:199:100:0:88"; + + @Expose + @ConfigOption(name = "Show Lines", desc = "Draw lines that start from the head of the boss and end on the Blood Ichor.") + @ConfigEditorBoolean + @FeatureToggle + public boolean showLines = false; + + @Expose + @ConfigOption(name = "Lines Start Color", desc = "Starting color of the lines.") + @ConfigEditorColour + public String linesColor = "0:255:255:13:0"; + +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/CoopBossHighlightConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/CoopBossHighlightConfig.java new file mode 100644 index 000000000000..5c91c41a9bcc --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/CoopBossHighlightConfig.java @@ -0,0 +1,44 @@ +package at.hannibal2.skyhanni.config.features.slayer.vampire; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigEditorText; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class CoopBossHighlightConfig { + @Expose + @ConfigOption(name = "Highlight Co-op Boss", desc = "Highlight boss of your co-op member.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlight = true; + + @Expose + @ConfigOption(name = "Highlight Color", desc = "What color to highlight the boss in.") + @ConfigEditorColour + public String highlightColor = "0:249:0:255:88"; + + @Expose + @ConfigOption(name = "Co-op Members", desc = "Add your co-op member here.\n§eFormat: §7Name1,Name2,Name3") + @ConfigEditorText + public String coopMembers = ""; + + @Expose + @ConfigOption(name = "Steak Alert", desc = "Show a title when you can steak the boss.") + @ConfigEditorBoolean + @FeatureToggle + public boolean steakAlert = true; + + @Expose + @ConfigOption(name = "Twinclaws Title", desc = "Send a title when Twinclaws is about to happen.") + @ConfigEditorBoolean + @FeatureToggle + public boolean twinClawsTitle = true; + + @Expose + @ConfigOption(name = "Twinclaws Sound", desc = "Play a sound when Twinclaws is about to happen.") + @ConfigEditorBoolean + @FeatureToggle + public boolean twinClawsSound = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/KillerSpringConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/KillerSpringConfig.java new file mode 100644 index 000000000000..1d38c7ce785a --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/KillerSpringConfig.java @@ -0,0 +1,31 @@ +package at.hannibal2.skyhanni.config.features.slayer.vampire; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class KillerSpringConfig { + @Expose + @ConfigOption(name = "Highlight Killer Spring", desc = "Highlight the Killer Spring tower.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlight = false; + + @Expose + @ConfigOption(name = "Color", desc = "Highlight color.") + @ConfigEditorColour + public String color = "0:199:100:0:88"; + + @Expose + @ConfigOption(name = "Show Lines", desc = "Draw lines that start from the head of the boss and end on the Killer Spring tower.") + @ConfigEditorBoolean + @FeatureToggle + public boolean showLines = false; + + @Expose + @ConfigOption(name = "Lines Start Color", desc = "Starting color of the lines.") + @ConfigEditorColour + public String linesColor = "0:255:255:13:0"; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/OthersBossConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/OthersBossConfig.java new file mode 100644 index 000000000000..6a89c9f773bd --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/OthersBossConfig.java @@ -0,0 +1,39 @@ +package at.hannibal2.skyhanni.config.features.slayer.vampire; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class OthersBossConfig { + + @Expose + @ConfigOption(name = "Highlight Others Boss", desc = "Highlight others players boss.\nYou need to hit them first.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlight = true; + + @Expose + @ConfigOption(name = "Highlight Color", desc = "What color to highlight the boss in.") + @ConfigEditorColour + public String highlightColor = "0:249:0:255:88"; + + @Expose + @ConfigOption(name = "Steak Alert", desc = "Show a title when you can steak the boss.") + @ConfigEditorBoolean + @FeatureToggle + public boolean steakAlert = true; + + @Expose + @ConfigOption(name = "Twinclaws Title", desc = "Send a title when Twinclaws is about to happen.") + @ConfigEditorBoolean + @FeatureToggle + public boolean twinClawsTitle = true; + + @Expose + @ConfigOption(name = "Twinclaws Sound", desc = "Play a sound when Twinclaws is about to happen.") + @ConfigEditorBoolean + @FeatureToggle + public boolean twinClawsSound = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/OwnBossConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/OwnBossConfig.java new file mode 100644 index 000000000000..481576242671 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/OwnBossConfig.java @@ -0,0 +1,39 @@ +package at.hannibal2.skyhanni.config.features.slayer.vampire; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class OwnBossConfig { + + @Expose + @ConfigOption(name = "Highlight Your Boss", desc = "Highlight your own Vampire Slayer boss.") + @ConfigEditorBoolean + @FeatureToggle + public boolean highlight = true; + + @Expose + @ConfigOption(name = "Highlight Color", desc = "What color to highlight the boss in.") + @ConfigEditorColour + public String highlightColor = "0:249:0:255:88"; + + @Expose + @ConfigOption(name = "Steak Alert", desc = "Show a title when you can steak your boss.") + @ConfigEditorBoolean + @FeatureToggle + public boolean steakAlert = true; + + @Expose + @ConfigOption(name = "Twinclaws Title", desc = "Send a title when Twinclaws is about to happen.\nWork on others highlighted people boss.") + @ConfigEditorBoolean + @FeatureToggle + public boolean twinClawsTitle = true; + + @Expose + @ConfigOption(name = "Twinclaws Sound", desc = "Play a sound when Twinclaws is about to happen.") + @ConfigEditorBoolean + @FeatureToggle + public boolean twinClawsSound = true; +} diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/VampireConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/VampireConfig.java new file mode 100644 index 000000000000..4a068878b468 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/slayer/vampire/VampireConfig.java @@ -0,0 +1,80 @@ +package at.hannibal2.skyhanni.config.features.slayer.vampire; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import com.google.gson.annotations.Expose; +import io.github.moulberry.moulconfig.annotations.Accordion; +import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean; +import io.github.moulberry.moulconfig.annotations.ConfigEditorColour; +import io.github.moulberry.moulconfig.annotations.ConfigEditorSlider; +import io.github.moulberry.moulconfig.annotations.ConfigOption; + +public class VampireConfig { + + @Expose + @ConfigOption(name = "Your Boss", desc = "") + @Accordion + public OwnBossConfig ownBoss = new OwnBossConfig(); + + @Expose + @ConfigOption(name = "Others Boss", desc = "") + @Accordion + public OthersBossConfig othersBoss = new OthersBossConfig(); + + @Expose + @ConfigOption(name = "Co-op Boss", desc = "") + @Accordion + public CoopBossHighlightConfig coopBoss = new CoopBossHighlightConfig(); + + @Expose + @ConfigOption(name = "Transparency", desc = "Choose the transparency of the color.") + @ConfigEditorSlider(minStep = 1, minValue = 1, maxValue = 250) + public int withAlpha = 80; + + @Expose + @ConfigOption(name = "See Through Blocks", desc = "Highlight even when behind others mobs/players.") + @ConfigEditorBoolean + public boolean seeThrough = false; + + @Expose + @ConfigOption(name = "Low Health", desc = "Change color when the boss is below 20% health.") + @ConfigEditorBoolean + @FeatureToggle + public boolean changeColorWhenCanSteak = true; + + @Expose + @ConfigOption(name = "Can use Steak Color", desc = "Color when the boss is below 20% health.") + @ConfigEditorColour + public String steakColor = "0:255:255:0:88"; + + @Expose + @ConfigOption(name = "Twinclaws", desc = "Delay the sound and title of Twinclaws alert for a given amount in milliseconds.") + @ConfigEditorSlider(minStep = 1, minValue = 0, maxValue = 1000) + public int twinclawsDelay = 0; + + @Expose + @ConfigOption(name = "Draw Line", desc = "Draw a line starting at your crosshair to the boss head.") + @ConfigEditorBoolean + @FeatureToggle + public boolean drawLine = false; + + @Expose + @ConfigOption(name = "Line Color", desc = "Color of the line.") + @ConfigEditorColour + public String lineColor = "0:255:255:0:88"; + + @Expose + @ConfigOption(name = "Line Width", desc = "Width of the line.") + @ConfigEditorSlider(minStep = 1, minValue = 1, maxValue = 10) + public int lineWidth = 1; + + + @Expose + @ConfigOption(name = "Blood Ichor", desc = "") + @Accordion + public BloodIchorConfig bloodIchor = new BloodIchorConfig(); + + @Expose + @ConfigOption(name = "Killer Spring", desc = "") + @Accordion + public KillerSpringConfig killerSpring = new KillerSpringConfig(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/BingoAPI.kt b/src/main/java/at/hannibal2/skyhanni/data/BingoAPI.kt deleted file mode 100644 index 5b32a1d15d68..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/data/BingoAPI.kt +++ /dev/null @@ -1,19 +0,0 @@ -package at.hannibal2.skyhanni.data - -import at.hannibal2.skyhanni.events.RepositoryReloadEvent -import at.hannibal2.skyhanni.utils.jsonobjects.BingoRanksJson -import net.minecraftforge.fml.common.eventhandler.SubscribeEvent - -object BingoAPI { - private var ranks = mapOf() - - @SubscribeEvent - fun onRepoReload(event: RepositoryReloadEvent) { - ranks = event.getConstant("BingoRanks").ranks - } - - fun getRank(text: String) = ranks.entries.find { text.contains(it.key) }?.value - - fun getIcon(searchRank: Int) = ranks.entries.find { it.value == searchRank }?.key - -} diff --git a/src/main/java/at/hannibal2/skyhanni/data/ChatManager.kt b/src/main/java/at/hannibal2/skyhanni/data/ChatManager.kt index c7ddf1777018..c426f9666f17 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/ChatManager.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/ChatManager.kt @@ -3,6 +3,7 @@ package at.hannibal2.skyhanni.data import at.hannibal2.skyhanni.SkyHanniMod import at.hannibal2.skyhanni.events.LorenzActionBarEvent import at.hannibal2.skyhanni.events.LorenzChatEvent +import at.hannibal2.skyhanni.events.MessageSendToServerEvent import at.hannibal2.skyhanni.events.PacketEvent import at.hannibal2.skyhanni.features.chat.ChatFilterGui import at.hannibal2.skyhanni.utils.IdentityCharacteristics @@ -13,6 +14,7 @@ import net.minecraft.client.Minecraft import net.minecraft.client.gui.ChatLine import net.minecraft.client.gui.GuiNewChat import net.minecraft.event.HoverEvent +import net.minecraft.network.play.client.C01PacketChatMessage import net.minecraft.network.play.server.S02PacketChat import net.minecraft.util.EnumChatFormatting import net.minecraft.util.IChatComponent @@ -63,15 +65,23 @@ object ChatManager { @SubscribeEvent(priority = EventPriority.LOW, receiveCanceled = true) fun onActionBarPacket(event: PacketEvent.ReceiveEvent) { - val packet = event.packet - if (packet !is S02PacketChat) return - val messageComponent = packet.chatComponent + val packet = event.packet as? S02PacketChat ?: return + val messageComponent = packet.chatComponent val message = LorenzUtils.stripVanillaMessage(messageComponent.formattedText) if (packet.type.toInt() == 2) { val actionBarEvent = LorenzActionBarEvent(message) actionBarEvent.postAndCatch() } + + } + + @SubscribeEvent + fun onSendMessageToServerPacket(event: PacketEvent.SendEvent) { + val packet = event.packet as? C01PacketChatMessage ?: return + + val message = packet.message + event.isCanceled = MessageSendToServerEvent(message).postAndCatch() } @SubscribeEvent(receiveCanceled = true) @@ -164,4 +174,4 @@ object ChatManager { history.actionKind = ActionKind.RETRACTED history.actionReason = reason.uppercase() } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/CropAccessoryData.kt b/src/main/java/at/hannibal2/skyhanni/data/CropAccessoryData.kt index 021e59b91cb9..79202ffa2aa4 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/CropAccessoryData.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/CropAccessoryData.kt @@ -104,9 +104,9 @@ class CropAccessoryData { val pagesLoaded get() = accessoryPage.size var cropAccessory: CropAccessory? - get() = GardenAPI.config?.savedCropAccessory + get() = GardenAPI.storage?.savedCropAccessory private set(accessory) { - GardenAPI.config?.savedCropAccessory = accessory + GardenAPI.storage?.savedCropAccessory = accessory } // Derived partially from NotEnoughUpdates/NotEnoughUpdates, ProfileViewer.Profile#getInventoryInfo diff --git a/src/main/java/at/hannibal2/skyhanni/data/EntityData.kt b/src/main/java/at/hannibal2/skyhanni/data/EntityData.kt index b26312b51e17..8d1b836dffec 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/EntityData.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/EntityData.kt @@ -8,7 +8,6 @@ import at.hannibal2.skyhanni.events.PacketEvent import at.hannibal2.skyhanni.utils.EntityUtils import at.hannibal2.skyhanni.utils.LorenzUtils.baseMaxHealth import at.hannibal2.skyhanni.utils.LorenzUtils.derpy -import net.minecraft.client.Minecraft import net.minecraft.client.entity.EntityOtherPlayerMP import net.minecraft.client.entity.EntityPlayerSP import net.minecraft.entity.EntityLivingBase @@ -50,8 +49,7 @@ class EntityData { val watchableObjects = packet.func_149376_c() ?: return val entityId = packet.entityId - val theWorld = Minecraft.getMinecraft().theWorld ?: return - val entity = theWorld.getEntityByID(entityId) ?: return + val entity = EntityUtils.getEntityByID(entityId) ?: return if (entity is EntityArmorStand) return if (entity is EntityXPOrb) return if (entity is EntityItem) return @@ -77,4 +75,4 @@ class EntityData { } } } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/EntityMovementData.kt b/src/main/java/at/hannibal2/skyhanni/data/EntityMovementData.kt index d67ae4a6373f..dec06dc8e200 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/EntityMovementData.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/EntityMovementData.kt @@ -6,6 +6,7 @@ import at.hannibal2.skyhanni.events.LorenzWorldChangeEvent import at.hannibal2.skyhanni.utils.LorenzUtils import at.hannibal2.skyhanni.utils.LorenzVec import at.hannibal2.skyhanni.utils.getLorenzVec +import net.minecraft.client.Minecraft import net.minecraft.entity.Entity import net.minecraftforge.fml.common.eventhandler.SubscribeEvent @@ -24,6 +25,7 @@ class EntityMovementData { @SubscribeEvent fun onTick(event: LorenzTickEvent) { if (!LorenzUtils.inSkyBlock) return + addToTrack(Minecraft.getMinecraft().thePlayer) for (entity in entityLocation.keys) { if (entity.isDead) continue @@ -42,4 +44,4 @@ class EntityMovementData { fun onWorldChange(event: LorenzWorldChangeEvent) { entityLocation.clear() } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/FriendAPI.kt b/src/main/java/at/hannibal2/skyhanni/data/FriendAPI.kt index bca06d18cd76..e3d256b2164a 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/FriendAPI.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/FriendAPI.kt @@ -1,66 +1,51 @@ package at.hannibal2.skyhanni.data -import at.hannibal2.skyhanni.config.ConfigManager +import at.hannibal2.skyhanni.SkyHanniMod +import at.hannibal2.skyhanni.config.ConfigFileType import at.hannibal2.skyhanni.events.HypixelJoinEvent import at.hannibal2.skyhanni.events.LorenzChatEvent import at.hannibal2.skyhanni.test.command.ErrorManager import at.hannibal2.skyhanni.utils.LorenzUtils import at.hannibal2.skyhanni.utils.StringUtils.cleanPlayerName import at.hannibal2.skyhanni.utils.StringUtils.matchMatcher -import at.hannibal2.skyhanni.utils.jsonobjects.FriendsJson -import at.hannibal2.skyhanni.utils.jsonobjects.FriendsJson.PlayerFriends.Friend +import at.hannibal2.skyhanni.data.jsonobjects.local.FriendsJson +import at.hannibal2.skyhanni.data.jsonobjects.local.FriendsJson.PlayerFriends.Friend import net.minecraft.util.ChatStyle import net.minecraftforge.fml.common.eventhandler.SubscribeEvent -import java.io.File -import java.io.FileReader import java.util.UUID -class FriendAPI { - private val file = File("config/skyhanni/friends.json") - +object FriendAPI { // TODO USE SH-REPO private val removedFriendPattern = ".*\n§r§eYou removed §r(?.*)§e from your friends list!§r§9§m\n.*".toPattern() private val addedFriendPattern = "§aYou are now friends with (?.*)".toPattern() private val noBestFriendPattern = ".*\n§r(?.*)§e is no longer a best friend!§r§9§m\n.*".toPattern() private val bestFriendPattern = ".*\n(?.*)§a is now a best friend!§r§9§m\n.*".toPattern() + private val readFriendListPattern = "/viewprofile (?.*)".toPattern() - companion object { - - private var friendsJson: FriendsJson? = null - - private fun getFriends(): MutableMap { - val friendsJson = friendsJson ?: error("savedFriends not loaded yet!") - return friendsJson.players.getOrPut(LorenzUtils.getRawPlayerUuid()) { - FriendsJson.PlayerFriends().also { it.friends = mutableMapOf() } - }.friends - } - - private val tempFriends = mutableListOf() + private val tempFriends = mutableListOf() - fun getAllFriends(): List { - val list = mutableListOf() - list.addAll(getFriends().values) - list.addAll(tempFriends) - return list - } - } + private fun getFriends() = SkyHanniMod.friendsData.players.getOrPut(LorenzUtils.getRawPlayerUuid()) { + FriendsJson.PlayerFriends().also { it.friends = mutableMapOf() } + }.friends @SubscribeEvent fun onHypixelJoin(event: HypixelJoinEvent) { - if (file.isFile) { - friendsJson = ConfigManager.gson.fromJson(FileReader(file), FriendsJson::class.java) - } - if (friendsJson == null) { - file.parentFile.mkdirs() - file.createNewFile() - friendsJson = FriendsJson().also { it.players = mutableMapOf() } + if (SkyHanniMod.friendsData.players == null) { + SkyHanniMod.friendsData.players = mutableMapOf() saveConfig() } } + fun getAllFriends(): List { + val list = mutableListOf() + list.addAll(getFriends().values) + list.addAll(tempFriends) + return list + } + fun saveConfig() { - file.writeText(ConfigManager.gson.toJson(friendsJson)) + SkyHanniMod.configManager.saveConfig(ConfigFileType.FRIENDS, "Save file") } @SubscribeEvent @@ -111,12 +96,19 @@ class FriendAPI { val value = chatStyle.chatClickEvent?.value ?: continue if (!value.startsWith("/viewprofile")) continue - val uuid = "/viewprofile (?.*)".toPattern().matchMatcher(value) { + val uuid = readFriendListPattern.matchMatcher(value) { group("uuid")?.let { try { UUID.fromString(it) } catch (e: IllegalArgumentException) { - ErrorManager.logError(e, "Error reading friend list.") + ErrorManager.logErrorWithData( + e, "Error reading friend list.", + "raw uuid" to it, + "value" to value, + "chatStyle" to chatStyle, + "event.chatComponent" to event.chatComponent, + "event.message" to event.message, + ) return } } diff --git a/src/main/java/at/hannibal2/skyhanni/data/GardenComposterUpgradesData.kt b/src/main/java/at/hannibal2/skyhanni/data/GardenComposterUpgradesData.kt index 14651f900407..138158ccb7d5 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/GardenComposterUpgradesData.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/GardenComposterUpgradesData.kt @@ -5,7 +5,8 @@ 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 class GardenComposterUpgradesData { @@ -16,15 +17,12 @@ class GardenComposterUpgradesData { if (event.inventoryName != "Composter Upgrades") return for (item in event.inventoryItems.values) { val itemName = item.name ?: continue - val matcher = ComposterUpgrade.regex.matcher(itemName) - if (!matcher.matches()) continue - - if (matcher.groupCount() != 0) { - val name = matcher.group("name") - val level = matcher.group("level")?.romanToDecimalIfNeeded() ?: 0 + ComposterUpgrade.regex.matchMatcher(itemName) { + val name = group("name") + val level = group("level")?.romanToDecimalIfNecessary() ?: 0 val composterUpgrade = ComposterUpgrade.getByName(name)!! ComposterAPI.composterUpgrades?.put(composterUpgrade, level) } } } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/GardenCropMilestones.kt b/src/main/java/at/hannibal2/skyhanni/data/GardenCropMilestones.kt index ecbaee59153a..34baceb0b525 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/GardenCropMilestones.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/GardenCropMilestones.kt @@ -6,15 +6,16 @@ import at.hannibal2.skyhanni.events.RepositoryReloadEvent import at.hannibal2.skyhanni.features.garden.CropType import at.hannibal2.skyhanni.features.garden.GardenAPI import at.hannibal2.skyhanni.utils.ItemUtils.getLore +import at.hannibal2.skyhanni.utils.NumberUtil.formatNumber import at.hannibal2.skyhanni.utils.StringUtils.matchMatcher -import at.hannibal2.skyhanni.utils.jsonobjects.GardenJson +import at.hannibal2.skyhanni.data.jsonobjects.repo.GardenJson import net.minecraft.item.ItemStack import net.minecraftforge.fml.common.eventhandler.SubscribeEvent object GardenCropMilestones { // TODO USE SH-REPO private val cropPattern = "§7Harvest §f(?.*) §7on .*".toPattern() - private val totalPattern = "§7Total: §a(?.*)".toPattern() + val totalPattern = "§7Total: §a(?.*)".toPattern() fun getCropTypeByLore(itemStack: ItemStack): CropType? { for (line in itemStack.getLore()) { @@ -34,17 +35,18 @@ object GardenCropMilestones { val crop = getCropTypeByLore(stack) ?: continue for (line in stack.getLore()) { totalPattern.matchMatcher(line) { - val amount = group("name").replace(",", "").toLong() + val amount = group("name").formatNumber() crop.setCounter(amount) } } } CropMilestoneUpdateEvent().postAndCatch() + GardenCropMilestonesCommunityFix.openInventory(event.inventoryItems) } - private var cropMilestoneData: Map> = emptyMap() + var cropMilestoneData: Map> = emptyMap() - val cropCounter: MutableMap? get() = GardenAPI.config?.cropCounter + val cropCounter: MutableMap? get() = GardenAPI.storage?.cropCounter // TODO make nullable fun CropType.getCounter() = cropCounter?.get(this) ?: 0 @@ -54,6 +56,7 @@ object GardenCropMilestones { } fun CropType.isMaxed(): Boolean { + // TODO change 1b val maxValue = cropMilestoneData[this]?.sum() ?: 1_000_000_000 // 1 bil for now return getCounter() >= maxValue } diff --git a/src/main/java/at/hannibal2/skyhanni/data/GardenCropMilestonesCommunityFix.kt b/src/main/java/at/hannibal2/skyhanni/data/GardenCropMilestonesCommunityFix.kt new file mode 100644 index 000000000000..71398af27e0b --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/data/GardenCropMilestonesCommunityFix.kt @@ -0,0 +1,178 @@ +package at.hannibal2.skyhanni.data + +import at.hannibal2.skyhanni.SkyHanniMod +import at.hannibal2.skyhanni.config.ConfigManager +import at.hannibal2.skyhanni.data.jsonobjects.repo.GardenJson +import at.hannibal2.skyhanni.events.RepositoryReloadEvent +import at.hannibal2.skyhanni.features.garden.CropType +import at.hannibal2.skyhanni.features.garden.GardenAPI +import at.hannibal2.skyhanni.utils.ItemUtils.getLore +import at.hannibal2.skyhanni.utils.ItemUtils.name +import at.hannibal2.skyhanni.utils.LorenzUtils +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.romanToDecimalIfNecessary +import at.hannibal2.skyhanni.utils.OSUtils +import at.hannibal2.skyhanni.utils.StringUtils.matchMatcher +import at.hannibal2.skyhanni.utils.StringUtils.matches +import at.hannibal2.skyhanni.utils.StringUtils.removeColor +import kotlinx.coroutines.launch +import net.minecraft.item.ItemStack +import net.minecraftforge.fml.common.eventhandler.SubscribeEvent + +object GardenCropMilestonesCommunityFix { + private val pattern = ".*§e(?.*)§6/§e(?.*)".toPattern() + private var showWrongData = false + private var showWhenAllCorrect = false + + @SubscribeEvent + fun onRepoReload(event: RepositoryReloadEvent) { + val data = event.getConstant("Garden") + val map = data.crop_milestone_community_help ?: return + for ((key, value) in map) { + if (key == "show_wrong_data") { + showWrongData = value + } + if (key == "show_when_all_correct") { + showWhenAllCorrect = value + } + } + } + + fun openInventory(inventoryItems: Map) { + if (!showWrongData) return + if (!GardenAPI.config.copyMilestoneData) return + fixForWrongData(inventoryItems) + } + + private fun fixForWrongData(inventoryItems: Map) { + val data = mutableListOf() + for ((_, stack) in inventoryItems) { + val crop = GardenCropMilestones.getCropTypeByLore(stack) ?: continue + checkForWrongData(stack, crop, data) + } + + if (data.isNotEmpty()) { + LorenzUtils.chat( + "Found §c${data.size} §ewrong crop milestone steps in the menu! " + + "Correct data got put into clipboard. " + + "Please share it on the §bSkyHanni Discord §ein the channel §b#share-data§e." + ) + OSUtils.copyToClipboard("```${data.joinToString("\n")}```") + } else { + if (showWhenAllCorrect) { + LorenzUtils.chat("No wrong crop milestone steps found!") + } + } + } + + private fun checkForWrongData( + stack: ItemStack, + crop: CropType, + wrongData: MutableList + ) { + val name = stack.name ?: return + val rawNumber = name.removeColor().replace(crop.cropName, "").trim() + val realTier = if (rawNumber == "") 0 else rawNumber.romanToDecimalIfNecessary() + + val lore = stack.getLore() + val next = lore.nextAfter({ GardenCropMilestones.totalPattern.matches(it) }, 3) ?: return + val total = lore.nextAfter({ GardenCropMilestones.totalPattern.matches(it) }, 6) ?: return + +// debug(" ") +// debug("crop: $crop") +// debug("realTier: $realTier") + + val guessNextMax = GardenCropMilestones.getCropsForTier( + realTier + 1, + crop + ) - GardenCropMilestones.getCropsForTier(realTier, crop) +// debug("guessNextMax: ${guessNextMax.addSeparators()}") + val nextMax = pattern.matchMatcher(next) { + group("max").formatNumber() + } ?: return +// debug("nextMax real: ${nextMax.addSeparators()}") + if (nextMax != guessNextMax) { +// debug("wrong, add to list") + wrongData.add("$crop:$realTier:${nextMax.addSeparators()}") + } + + val guessTotalMax = GardenCropMilestones.getCropsForTier(46, crop) +// println("guessTotalMax: ${guessTotalMax.addSeparators()}") + val totalMax = pattern.matchMatcher(total) { + group("max").formatNumber() + } ?: return +// println("totalMax real: ${totalMax.addSeparators()}") + val totalOffBy = guessTotalMax - totalMax +// debug("$crop total offf by: ${totalOffBy.addSeparators()}") + } + +// fun debug(message: String) { +// if (SkyHanniMod.feature.dev.debug.enabled) { +// println(message) +// } +// } + + /** + * This helps to fix wrong crop milestone data + * This command reads the clipboard content, + * in the format of users sending crop milestone step data. + * + * The new data will be compared to the currently saved data, + * differences are getting replaced, and the result gets put into the clipboard. + * The clipboard context can be used to update the repo content. + */ + fun readDataFromClipboard() { + SkyHanniMod.coroutineScope.launch { + OSUtils.readFromClipboard()?.let { + handleInput(it) + } + } + } + + private var totalFixedValues = 0 + + private fun handleInput(input: String) { + println(" ") + var fixed = 0 + var alreadyCorrect = 0 + for (line in input.lines()) { + val split = line.replace("```", "").replace(".", ",").split(":") + if (split.size != 3) continue + val (rawCrop, tier, amount) = split + val crop = LorenzUtils.enumValueOf(rawCrop) + + if (tryFix(crop, tier.toInt(), amount.formatNumber().toInt())) { + fixed++ + } else { + alreadyCorrect++ + } + } + totalFixedValues += fixed + LorenzUtils.chat("Fixed: $fixed/$alreadyCorrect, total fixes: $totalFixedValues") + val s = ConfigManager.gson.toJsonTree(GardenCropMilestones.cropMilestoneData).toString() + OSUtils.copyToClipboard("\"crop_milestones\":$s,") + } + + private fun tryFix(crop: CropType, tier: Int, amount: Int): Boolean { + val guessNextMax = GardenCropMilestones.getCropsForTier(tier + 1, crop) - GardenCropMilestones.getCropsForTier( + tier, + crop + ) + if (guessNextMax.toInt() == amount) { + return false + } + GardenCropMilestones.cropMilestoneData = GardenCropMilestones.cropMilestoneData.editCopy { + fix(crop, this, tier, amount) + } + return true + } + + private fun fix(crop: CropType, map: MutableMap>, tier: Int, amount: Int) { + map[crop] = map[crop]!!.editCopy { + this[tier] = amount + } + } +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/GardenCropUpgrades.kt b/src/main/java/at/hannibal2/skyhanni/data/GardenCropUpgrades.kt index 15a18ca26d25..1ea0871eebcb 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/GardenCropUpgrades.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/GardenCropUpgrades.kt @@ -39,7 +39,7 @@ class GardenCropUpgrades { } companion object { - private val cropUpgrades: MutableMap? get() = GardenAPI.config?.cropUpgrades + private val cropUpgrades: MutableMap? get() = GardenAPI.storage?.cropUpgrades fun CropType.getUpgradeLevel() = cropUpgrades?.get(this) diff --git a/src/main/java/at/hannibal2/skyhanni/data/GuiEditManager.kt b/src/main/java/at/hannibal2/skyhanni/data/GuiEditManager.kt index 4f31107891c8..29a344b18478 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/GuiEditManager.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/GuiEditManager.kt @@ -9,6 +9,8 @@ import at.hannibal2.skyhanni.test.SkyHanniDebugsAndTests import at.hannibal2.skyhanni.utils.LorenzUtils import at.hannibal2.skyhanni.utils.LorenzUtils.isRancherSign import at.hannibal2.skyhanni.utils.NEUItems +import at.hannibal2.skyhanni.utils.SimpleTimeMark +import io.github.moulberry.notenoughupdates.profileviewer.GuiProfileViewer import net.minecraft.client.Minecraft import net.minecraft.client.gui.inventory.GuiChest import net.minecraft.client.gui.inventory.GuiEditSign @@ -17,8 +19,13 @@ import net.minecraft.client.renderer.GlStateManager import net.minecraftforge.fml.common.eventhandler.EventPriority import net.minecraftforge.fml.common.eventhandler.SubscribeEvent import java.util.UUID +import kotlin.time.Duration.Companion.milliseconds +import kotlin.time.Duration.Companion.minutes class GuiEditManager { + + private var lastHotkeyPressed = SimpleTimeMark.farPast() + @SubscribeEvent fun onKeyClick(event: LorenzKeyPressEvent) { if (!LorenzUtils.inSkyBlock) return @@ -26,13 +33,15 @@ class GuiEditManager { if (isInGui()) return Minecraft.getMinecraft().currentScreen?.let { - if (it !is GuiInventory && it !is GuiChest && it !is GuiEditSign) return + if (it !is GuiInventory && it !is GuiChest && it !is GuiEditSign && it !is GuiProfileViewer) return if (it is GuiEditSign && !it.isRancherSign()) return } + if (lastHotkeyPressed.passedSince() < 500.milliseconds) return if (NEUItems.neuHasFocus()) return + lastHotkeyPressed = SimpleTimeMark.now() - openGuiPositionEditor() + openGuiPositionEditor(hotkeyReminder = false) } @SubscribeEvent(priority = EventPriority.LOWEST) @@ -59,9 +68,19 @@ class GuiEditManager { } } + private var lastHotkeyReminded = SimpleTimeMark.farPast() + @JvmStatic - fun openGuiPositionEditor() { + fun openGuiPositionEditor(hotkeyReminder: Boolean) { SkyHanniMod.screenToOpen = GuiPositionEditor(latestPositions.values.toList(), 2) + if (hotkeyReminder && lastHotkeyReminded.passedSince() > 30.minutes) { + lastHotkeyReminded = SimpleTimeMark.now() + LorenzUtils.chat( + "§eTo edit hidden GUI elements:\n" + + " §7- §e1. Set a key in /sh edit.\n" + + " §7- §e2. Click that key while the GUI element is visible." + ) + } } @JvmStatic @@ -95,4 +114,4 @@ class GuiEditManager { } } -class Vector2i(val x: Int, val y: Int) \ No newline at end of file +class Vector2i(val x: Int, val y: Int) diff --git a/src/main/java/at/hannibal2/skyhanni/data/HypixelData.kt b/src/main/java/at/hannibal2/skyhanni/data/HypixelData.kt index 31bb7c04725f..1b0b463520cf 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/HypixelData.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/HypixelData.kt @@ -7,24 +7,19 @@ import at.hannibal2.skyhanni.events.LorenzChatEvent import at.hannibal2.skyhanni.events.LorenzTickEvent import at.hannibal2.skyhanni.events.LorenzWorldChangeEvent import at.hannibal2.skyhanni.events.ProfileJoinEvent -import at.hannibal2.skyhanni.utils.LocationUtils.isPlayerInside +import at.hannibal2.skyhanni.features.bingo.BingoAPI import at.hannibal2.skyhanni.utils.LorenzLogger import at.hannibal2.skyhanni.utils.LorenzUtils import at.hannibal2.skyhanni.utils.StringUtils.matchMatcher import at.hannibal2.skyhanni.utils.StringUtils.removeColor import at.hannibal2.skyhanni.utils.TabListData import net.minecraft.client.Minecraft -import net.minecraft.util.AxisAlignedBB import net.minecraftforge.fml.common.eventhandler.SubscribeEvent import net.minecraftforge.fml.common.network.FMLNetworkEvent class HypixelData { // TODO USE SH-REPO private val tabListProfilePattern = "§e§lProfile: §r§a(?.*)".toPattern() - private val westVillageFarmArea = AxisAlignedBB(-54.0, 69.0, -115.0, -40.0, 75.0, -127.0) - private val howlingCaveArea = AxisAlignedBB(-401.0, 50.0, -104.0, -337.0, 90.0, 36.0) - private val fakeZealotBruiserHideoutArea = AxisAlignedBB(-520.0, 66.0, -332.0, -558.0, 85.0, -280.0) - private val realZealotBruiserHideoutArea = AxisAlignedBB(-552.0, 50.0, -245.0, -580.0, 72.0, -209.0) companion object { var hypixelLive = false @@ -85,15 +80,7 @@ class HypixelData { .firstOrNull { it.startsWith(" §7⏣ ") || it.startsWith(" §5ф ") } ?.substring(5)?.removeColor() ?: "?" - - skyBlockArea = when { - skyBlockIsland == IslandType.THE_RIFT && westVillageFarmArea.isPlayerInside() -> "Dreadfarm" - skyBlockIsland == IslandType.THE_PARK && howlingCaveArea.isPlayerInside() -> "Howling Cave" - skyBlockIsland == IslandType.THE_END && fakeZealotBruiserHideoutArea.isPlayerInside() -> "The End" - skyBlockIsland == IslandType.THE_END && realZealotBruiserHideoutArea.isPlayerInside() -> "Zealot Bruiser Hideout" - - else -> originalLocation - } + skyBlockArea = LocationFixData.fixLocation(skyBlockIsland) ?: originalLocation checkProfileName() } @@ -188,7 +175,7 @@ class HypixelData { } private fun getIslandType(newIsland: String, guesting: Boolean): IslandType { - val islandType = IslandType.getBySidebarName(newIsland) + val islandType = IslandType.getByNameOrUnknown(newIsland) if (guesting) { if (islandType == IslandType.PRIVATE_ISLAND) return IslandType.PRIVATE_ISLAND_GUEST if (islandType == IslandType.GARDEN) return IslandType.GARDEN_GUEST @@ -204,6 +191,6 @@ class HypixelData { val displayName = objective.displayName val scoreboardTitle = displayName.removeColor() return scoreboardTitle.contains("SKYBLOCK") || - scoreboardTitle.contains("SKIBLOCK") // April 1st jokes are so funny + scoreboardTitle.contains("SKIBLOCK") // April 1st jokes are so funny } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/IslandType.kt b/src/main/java/at/hannibal2/skyhanni/data/IslandType.kt index 15195dec4a69..7e1ac4159495 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/IslandType.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/IslandType.kt @@ -1,6 +1,6 @@ package at.hannibal2.skyhanni.data -enum class IslandType(val displayName: String, val apiName: String = "null") { +enum class IslandType(val displayName: String, val modeName: String = "null") { // TODO USE SH-REPO (for displayName only) PRIVATE_ISLAND("Private Island"), PRIVATE_ISLAND_GUEST("Private Island Guest"), @@ -28,8 +28,9 @@ enum class IslandType(val displayName: String, val apiName: String = "null") { ; companion object { - fun getBySidebarName(name: String): IslandType { - return entries.firstOrNull { it.displayName == name } ?: UNKNOWN - } + fun getByNameOrUnknown(name: String) = getByNameOrNull(name) ?: UNKNOWN + fun getByName(name: String) = getByNameOrNull(name) ?: error("IslandType not found: '$name'") + + fun getByNameOrNull(name: String) = entries.firstOrNull { it.displayName == name } } } diff --git a/src/main/java/at/hannibal2/skyhanni/data/ItemAddManager.kt b/src/main/java/at/hannibal2/skyhanni/data/ItemAddManager.kt new file mode 100644 index 000000000000..3d4b8f067d2e --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/data/ItemAddManager.kt @@ -0,0 +1,90 @@ +package at.hannibal2.skyhanni.data + +import at.hannibal2.skyhanni.events.GuiContainerEvent +import at.hannibal2.skyhanni.events.InventoryOpenEvent +import at.hannibal2.skyhanni.events.ItemAddEvent +import at.hannibal2.skyhanni.events.LorenzChatEvent +import at.hannibal2.skyhanni.events.SackChangeEvent +import at.hannibal2.skyhanni.events.entity.ItemAddInInventoryEvent +import at.hannibal2.skyhanni.utils.LorenzUtils +import at.hannibal2.skyhanni.utils.NEUInternalName +import at.hannibal2.skyhanni.utils.NEUInternalName.Companion.asInternalName +import at.hannibal2.skyhanni.utils.SimpleTimeMark +import at.hannibal2.skyhanni.utils.StringUtils.matches +import net.minecraftforge.fml.common.eventhandler.SubscribeEvent +import kotlin.time.Duration.Companion.milliseconds +import kotlin.time.Duration.Companion.seconds + +class ItemAddManager { + enum class Source { + ITEM_ADD, + SACKS, + ; + } + + private val ARCHFIEND_DICE = "ARCHFIEND_DICE".asInternalName() + private val HIGH_CLASS_ARCHFIEND_DICE = "HIGH_CLASS_ARCHFIEND_DICE".asInternalName() + + private val diceRollChatPattern = + "§eYour §r§(5|6High Class )Archfiend Dice §r§erolled a §r§.(?.)§r§e! Bonus: §r§.(?.*)❤".toPattern() + + private var inSackInventory = false + private var lastSackInventoryLeave = SimpleTimeMark.farPast() + + @SubscribeEvent + fun onInventoryOpen(event: InventoryOpenEvent) { + if (event.inventoryName.contains("Sack")) { + inSackInventory = true + } + } + + @SubscribeEvent + fun onInventoryClose(event: GuiContainerEvent.CloseWindowEvent) { + if (inSackInventory) { + inSackInventory = false + lastSackInventoryLeave = SimpleTimeMark.now() + } + } + + @SubscribeEvent + fun onSackChange(event: SackChangeEvent) { + if (!LorenzUtils.inSkyBlock) return + + if (inSackInventory || lastSackInventoryLeave.passedSince() < 10.seconds) return + + for (sackChange in event.sackChanges) { + val change = sackChange.delta + if (change > 0) { + val internalName = sackChange.internalName + Source.SACKS.addItem(internalName, change) + } + } + } + + @SubscribeEvent + fun onItemAdd(event: ItemAddInInventoryEvent) { + if (!LorenzUtils.inSkyBlock) return + + val internalName = event.internalName + if (internalName == ARCHFIEND_DICE || internalName == HIGH_CLASS_ARCHFIEND_DICE) { + if (lastDiceRoll.passedSince() < 500.milliseconds) { + return + } + } + + Source.ITEM_ADD.addItem(internalName, event.amount) + } + + private fun Source.addItem(internalName: NEUInternalName, amount: Int) { + ItemAddEvent(internalName, amount, this).postAndCatch() + } + + private var lastDiceRoll = SimpleTimeMark.farPast() + + @SubscribeEvent + fun onChat(event: LorenzChatEvent) { + if (diceRollChatPattern.matches(event.message)) { + lastDiceRoll = SimpleTimeMark.now() + } + } +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/LocationFixData.kt b/src/main/java/at/hannibal2/skyhanni/data/LocationFixData.kt new file mode 100644 index 000000000000..f32256031e5c --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/data/LocationFixData.kt @@ -0,0 +1,33 @@ +package at.hannibal2.skyhanni.data + +import at.hannibal2.skyhanni.events.RepositoryReloadEvent +import at.hannibal2.skyhanni.utils.LocationUtils.isPlayerInside +import at.hannibal2.skyhanni.data.jsonobjects.repo.LocationFixJson +import net.minecraft.util.AxisAlignedBB +import net.minecraftforge.fml.common.eventhandler.EventPriority +import net.minecraftforge.fml.common.eventhandler.SubscribeEvent + +object LocationFixData { + private var locationFixes = mutableListOf() + + class LocationFix(val island: IslandType, val area: AxisAlignedBB, val realLocation: String) + + // priority set to low so that IslandType can load their island names from repo earlier + @SubscribeEvent(priority = EventPriority.LOW) + fun onRepoReload(event: RepositoryReloadEvent) { + val data = event.getConstant("LocationFix") + locationFixes.clear() + + for (fix in data.locationFixes.values) { + val island = IslandType.getByName(fix.island_name) + val area = fix.a.axisAlignedTo(fix.b) + val realLocation = fix.real_location + + locationFixes.add(LocationFix(island, area, realLocation)) + } + } + + fun fixLocation(skyBlockIsland: IslandType) = locationFixes + .firstOrNull { skyBlockIsland == it.island && it.area.isPlayerInside() } + ?.realLocation +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/MayorElection.kt b/src/main/java/at/hannibal2/skyhanni/data/MayorElection.kt index d4ad57e2d531..53ffdae71486 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/MayorElection.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/MayorElection.kt @@ -6,7 +6,7 @@ import at.hannibal2.skyhanni.events.LorenzTickEvent import at.hannibal2.skyhanni.utils.APIUtil import at.hannibal2.skyhanni.utils.LorenzUtils import at.hannibal2.skyhanni.utils.LorenzUtils.put -import at.hannibal2.skyhanni.utils.jsonobjects.MayorJson +import at.hannibal2.skyhanni.data.jsonobjects.local.MayorJson import io.github.moulberry.notenoughupdates.util.SkyBlockTime import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.launch @@ -73,4 +73,4 @@ class MayorElection { private fun MayorJson.Election.getPairs() = year + 1 to candidates.bestCandidate() private fun List.bestCandidate() = maxBy { it.votes } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/MinecraftData.kt b/src/main/java/at/hannibal2/skyhanni/data/MinecraftData.kt index da9497d0801b..2ec0ea6679f2 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/MinecraftData.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/MinecraftData.kt @@ -6,6 +6,7 @@ import at.hannibal2.skyhanni.events.LorenzWorldChangeEvent import at.hannibal2.skyhanni.events.PacketEvent import at.hannibal2.skyhanni.events.PlaySoundEvent import at.hannibal2.skyhanni.events.ReceiveParticleEvent +import at.hannibal2.skyhanni.utils.DelayedRun import at.hannibal2.skyhanni.utils.InventoryUtils import at.hannibal2.skyhanni.utils.ItemUtils.getInternalName import at.hannibal2.skyhanni.utils.LorenzUtils @@ -75,11 +76,12 @@ object MinecraftData { @SubscribeEvent fun onTick(event: LorenzTickEvent) { + DelayedRun.checkRuns() if (!LorenzUtils.inSkyBlock) return val hand = InventoryUtils.getItemInHand() val newItem = hand?.getInternalName() ?: NEUInternalName.NONE - if (newItem != InventoryUtils.itemInHandId) { - ItemInHandChangeEvent(newItem, hand).postAndCatch() + val oldItem = InventoryUtils.itemInHandId + if (newItem != oldItem) { InventoryUtils.recentItemsInHand.keys.removeIf { it + 30_000 > System.currentTimeMillis() } if (newItem != NEUInternalName.NONE) { @@ -87,6 +89,7 @@ object MinecraftData { } InventoryUtils.itemInHandId = newItem InventoryUtils.latestItemInHand = hand + ItemInHandChangeEvent(newItem, oldItem).postAndCatch() } } @@ -95,4 +98,4 @@ object MinecraftData { InventoryUtils.itemInHandId = NEUInternalName.NONE InventoryUtils.recentItemsInHand.clear() } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/OtherInventoryData.kt b/src/main/java/at/hannibal2/skyhanni/data/OtherInventoryData.kt index 5950d5fb88b0..921d591b2899 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/OtherInventoryData.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/OtherInventoryData.kt @@ -22,9 +22,9 @@ object OtherInventoryData { close() } - fun close() { + fun close(reopenSameName: Boolean = false) { currentInventory?.let { - InventoryCloseEvent(it).postAndCatch() + InventoryCloseEvent(it, reopenSameName).postAndCatch() currentInventory = null } } @@ -49,7 +49,8 @@ object OtherInventoryData { val windowId = packet.windowId val title = packet.windowTitle.unformattedText val slotCount = packet.slotCount - close() + val reopenSameName = title == currentInventory?.title + close(reopenSameName) currentInventory = Inventory(windowId, title, slotCount) acceptItems = true @@ -104,4 +105,4 @@ object OtherInventoryData { val slotCount: Int, val items: MutableMap = mutableMapOf(), ) -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/OtherMod.kt b/src/main/java/at/hannibal2/skyhanni/data/OtherMod.kt deleted file mode 100644 index 391d669752c1..000000000000 --- a/src/main/java/at/hannibal2/skyhanni/data/OtherMod.kt +++ /dev/null @@ -1,42 +0,0 @@ -package at.hannibal2.skyhanni.data - -import at.hannibal2.skyhanni.config.ConfigManager -import com.google.gson.JsonObject -import java.io.BufferedReader - -enum class OtherMod(val modName: String, val configPath: String, val readKey: (BufferedReader) -> (String)) { - NEU("Not Enough Updates", "config/notenoughupdates/configNew.json", { reader -> - getJson(reader)["apiData"].asJsonObject["apiKey"].asString - }), - COW("Cowlection", "config/cowlection/do-not-share-me-with-other-players.cfg", { reader -> - val lines = reader.readText().split(System.lineSeparator()) - val line = lines.find { it.startsWith(" S:moo=") }!! - line.split("=")[1] - }), - DSM("Dankers SkyBlock Mod", "config/Danker's Skyblock Mod.cfg", { reader -> - val lines = reader.readText().split(System.lineSeparator()) - val line = lines.find { it.startsWith(" S:APIKey=") }!! - line.split("=")[1] - }), - DG("Dungeons Guide", "config/dungeonsguide/config.json", { reader -> - getJson(reader)["partykicker.apikey"].asJsonObject["apikey"].asString - }), - SKYTILS("Skytils", "config/skytils/config.toml", { reader -> - val lines = reader.readText().split(System.lineSeparator()) - val line = lines.find { it.startsWith(" hypixel_api_key = \"") }!! - line.split("\"")[1] - }), - HYPIXEL_API_KEY_MANAGER("Hypixel API Key Manager", "HypixelApiKeyManager/localdata.json", { reader -> - getJson(reader)["key"].asString - }), - SOOPY("Soopy Addons", "soopyAddonsData/apikey.txt", { reader -> - reader.readText() - }), - SBE("SkyBlock Extras", "config/SkyblockExtras.cfg", { reader -> - getJson(reader)["values"].asJsonObject["apiKey"].asString - }), -} - -fun getJson(reader: BufferedReader): JsonObject { - return ConfigManager.gson.fromJson(reader, com.google.gson.JsonObject::class.java) -} \ No newline at end of file diff --git a/src/main/java/at/hannibal2/skyhanni/data/OwnInventoryData.kt b/src/main/java/at/hannibal2/skyhanni/data/OwnInventoryData.kt index 7e20320774a4..a7b31159b488 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/OwnInventoryData.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/OwnInventoryData.kt @@ -1,101 +1,118 @@ package at.hannibal2.skyhanni.data -import at.hannibal2.skyhanni.api.CollectionAPI -import at.hannibal2.skyhanni.events.InventoryCloseEvent +import at.hannibal2.skyhanni.events.GuiContainerEvent +import at.hannibal2.skyhanni.events.LorenzTickEvent +import at.hannibal2.skyhanni.events.LorenzWorldChangeEvent import at.hannibal2.skyhanni.events.OwnInventoryItemUpdateEvent import at.hannibal2.skyhanni.events.PacketEvent -import at.hannibal2.skyhanni.features.bazaar.BazaarApi +import at.hannibal2.skyhanni.events.entity.ItemAddInInventoryEvent +import at.hannibal2.skyhanni.utils.DelayedRun +import at.hannibal2.skyhanni.utils.InventoryUtils import at.hannibal2.skyhanni.utils.ItemUtils.getInternalNameOrNull -import at.hannibal2.skyhanni.utils.ItemUtils.name import at.hannibal2.skyhanni.utils.LorenzUtils +import at.hannibal2.skyhanni.utils.LorenzUtils.addOrPut import at.hannibal2.skyhanni.utils.NEUInternalName -import at.hannibal2.skyhanni.utils.NEUItems -import net.minecraft.item.ItemStack +import at.hannibal2.skyhanni.utils.SimpleTimeMark +import net.minecraft.client.Minecraft +import net.minecraft.network.play.server.S0DPacketCollectItem import net.minecraft.network.play.server.S2FPacketSetSlot import net.minecraftforge.fml.common.eventhandler.EventPriority import net.minecraftforge.fml.common.eventhandler.SubscribeEvent +import kotlin.time.Duration +import kotlin.time.Duration.Companion.milliseconds class OwnInventoryData { - - private var itemNames = mutableMapOf() - private var itemAmount = mutableMapOf() + private var itemAmounts = mapOf() + private var dirty = false @SubscribeEvent(priority = EventPriority.LOW, receiveCanceled = true) fun onChatPacket(event: PacketEvent.ReceiveEvent) { if (!LorenzUtils.inSkyBlock) return val packet = event.packet + if (packet is S2FPacketSetSlot || packet is S0DPacketCollectItem) { + dirty = true + } if (packet is S2FPacketSetSlot) { val windowId = packet.func_149175_c() if (windowId == 0) { val item = packet.func_149174_e() ?: return - OwnInventoryItemUpdateEvent(item).postAndCatch() - } - } - if (packet is S2FPacketSetSlot) { - val windowId = packet.func_149175_c() - val item = packet.func_149174_e() - val slot = packet.func_149173_d() - if (windowId != 0) return - val name = item?.name ?: "null" - - val oldItem = itemNames.getOrDefault(slot, "null") - val oldAmount = itemAmount.getOrDefault(slot, 0) - - val amount = item?.stackSize ?: 0 - if (name == oldItem) { - val diff = amount - oldAmount - if (amount > oldAmount) { - add(item, diff) - } - } else { - if (name != "null") { - add(item, amount) + DelayedRun.runNextTick { + OwnInventoryItemUpdateEvent(item).postAndCatch() } } - itemNames[slot] = name - itemAmount[slot] = amount } } @SubscribeEvent - fun onInventoryClose(event: InventoryCloseEvent) { - BazaarApi.inBazaarInventory = false - lastClose = System.currentTimeMillis() - } + fun onTick(event: LorenzTickEvent) { + if (!LorenzUtils.inSkyBlock) return + if (itemAmounts.isEmpty()) { + itemAmounts = getCurrentItems() + } - private var lastClose = 0L + if (!dirty) return + dirty = false - private fun add(item: ItemStack?, add: Int) { - if (item == null) return + val map = getCurrentItems() + for ((internalName, amount) in map) { + calculateDifference(internalName, amount) + } + itemAmounts = map + } - val diffClose = System.currentTimeMillis() - lastClose - if (diffClose < 500) return + private fun getCurrentItems(): MutableMap { + val map = mutableMapOf() + for (itemStack in InventoryUtils.getItemsInOwnInventory()) { + val internalName = itemStack.getInternalNameOrNull() ?: continue + map.addOrPut(internalName, itemStack.stackSize) + } + return map + } - val diffWorld = System.currentTimeMillis() - LorenzUtils.lastWorldSwitch - if (diffWorld < 3_000) return + @SubscribeEvent + fun onWorldChange(event: LorenzWorldChangeEvent) { + itemAmounts = emptyMap() + } - val internalName = item.getInternalNameOrNull() + private fun calculateDifference(internalName: NEUInternalName, newAmount: Int) { + val oldAmount = itemAmounts[internalName] ?: 0 - item.name?.let { - if (it == "§8Quiver Arrow") { - return - } + val diff = newAmount - oldAmount + if (diff > 0) { + addItem(internalName, diff) } + } - if (internalName == null) { - LorenzUtils.debug("OwnInventoryData add is empty for: '${item.name}'") - return - } - if (internalName.startsWith("MAP-")) return + @SubscribeEvent + fun onInventoryClose(event: GuiContainerEvent.CloseWindowEvent) { + val item = Minecraft.getMinecraft().thePlayer.inventory.itemStack ?: return + val internalNameOrNull = item.getInternalNameOrNull() ?: return + ignoreItem(500.milliseconds) { it == internalNameOrNull } + } - val (_, amount) = NEUItems.getMultiplier(internalName) - if (amount > 1) return + @SubscribeEvent + fun onSlotClick(event: GuiContainerEvent.SlotClickEvent) { + ignoreItem(500.milliseconds) { true } + } - addMultiplier(internalName, add) + private fun ignoreItem(duration: Duration, condition: (NEUInternalName) -> Boolean) { + ignoredItemsUntil.add(IgnoredItem(condition, SimpleTimeMark.now() + duration)) } - private fun addMultiplier(internalName: NEUInternalName, amount: Int) { - CollectionAPI.addFromInventory(internalName, amount) + private val ignoredItemsUntil = mutableListOf() + + class IgnoredItem(val condition: (NEUInternalName) -> Boolean, val blockedUntil: SimpleTimeMark) + + private fun addItem(internalName: NEUInternalName, add: Int) { + val diffWorld = System.currentTimeMillis() - LorenzUtils.lastWorldSwitch + if (diffWorld < 3_000) return + + ignoredItemsUntil.removeIf { it.blockedUntil.isInPast() } + if (ignoredItemsUntil.any { it.condition(internalName) }) return + + if (internalName.startsWith("MAP-")) return + + ItemAddInInventoryEvent(internalName, add).postAndCatch() } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/PartyAPI.kt b/src/main/java/at/hannibal2/skyhanni/data/PartyAPI.kt index 08344c51bb17..90fe4783ebc3 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/PartyAPI.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/PartyAPI.kt @@ -8,7 +8,6 @@ import at.hannibal2.skyhanni.utils.StringUtils.matchMatcher import at.hannibal2.skyhanni.utils.StringUtils.removeColor import at.hannibal2.skyhanni.utils.StringUtils.removeResets import at.hannibal2.skyhanni.utils.StringUtils.trimWhiteSpaceAndResets -import net.minecraft.client.Minecraft import net.minecraftforge.fml.common.eventhandler.SubscribeEvent import kotlin.random.Random @@ -33,17 +32,17 @@ object PartyAPI { fun listMembers() { val size = partyMembers.size if (size == 0) { - LorenzUtils.chat("§e[SkyHanni] No tracked party members!") + LorenzUtils.chat("No tracked party members!") return } - LorenzUtils.chat("§a[SkyHanni] Tracked party members §7($size) §f:") + LorenzUtils.chat("Tracked party members §7($size) §f:", prefixColor = "§a") for (member in partyMembers) { - LorenzUtils.chat(" §a- §7$member") + LorenzUtils.chat(" §a- §7$member", false) } if (Random.nextDouble() < 0.1) { OSUtils.openBrowser("https://www.youtube.com/watch?v=iANP7ib7CPA") - LorenzUtils.hoverableChat("§7Are You Ready To Party?", listOf("§b~Spongebob")) + LorenzUtils.hoverableChat("§7Are You Ready To Party?", listOf("§b~Spongebob"), prefix = false) } } @@ -112,7 +111,7 @@ object PartyAPI { partyMemberListPattern.matchMatcher(message.removeColor()) { for (name in group("names").split(" ● ")) { val playerName = name.replace(" ●", "").cleanPlayerName() - if (playerName == Minecraft.getMinecraft().thePlayer.name) continue + if (playerName == LorenzUtils.getPlayerName()) continue if (!partyMembers.contains(playerName)) partyMembers.add(playerName) } } diff --git a/src/main/java/at/hannibal2/skyhanni/data/PetAPI.kt b/src/main/java/at/hannibal2/skyhanni/data/PetAPI.kt new file mode 100644 index 000000000000..9c5eac6101bb --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/data/PetAPI.kt @@ -0,0 +1,11 @@ +package at.hannibal2.skyhanni.data + +object PetAPI { + + // Contains color code + name and for older SkyHanni users maybe also the pet level + var currentPet: String? + get() = ProfileStorageData.profileSpecific?.currentPet + set(value) { + ProfileStorageData.profileSpecific?.currentPet = value + } +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/ProfileStorageData.kt b/src/main/java/at/hannibal2/skyhanni/data/ProfileStorageData.kt index 63f77f2d2f4c..8e6f9bb7d858 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/ProfileStorageData.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/ProfileStorageData.kt @@ -12,7 +12,6 @@ import at.hannibal2.skyhanni.events.PreProfileSwitchEvent import at.hannibal2.skyhanni.events.ProfileJoinEvent import at.hannibal2.skyhanni.events.TabListUpdateEvent import at.hannibal2.skyhanni.utils.LorenzUtils -import at.hannibal2.skyhanni.utils.LorenzVec import at.hannibal2.skyhanni.utils.StringUtils.matchMatcher import net.minecraftforge.fml.common.eventhandler.EventPriority import net.minecraftforge.fml.common.eventhandler.SubscribeEvent @@ -25,14 +24,15 @@ object ProfileStorageData { private var nextProfile: String? = null + // TODO USE SH-REPO + private val profileSwitchPattern = "§7Switching to profile (?.*)\\.\\.\\.".toPattern() private var sackPlayers: SackData.PlayerSpecific? = null var sackProfiles: SackData.ProfileSpecific? = null @SubscribeEvent(priority = EventPriority.HIGHEST) fun onChat(event: LorenzChatEvent) { - // TODO USE SH-REPO - "§7Switching to profile (?.*)\\.\\.\\.".toPattern().matchMatcher(event.message) { + profileSwitchPattern.matchMatcher(event.message) { nextProfile = group("name").lowercase() loaded = false PreProfileSwitchEvent().postAndCatch() @@ -54,7 +54,7 @@ object ProfileStorageData { LorenzUtils.error("sackPlayers after profile swap can not be set: sackPlayers is null!") return } - loadProfileSpecific(playerSpecific, sackPlayers, profileName, "profile swap (chat message)") + loadProfileSpecific(playerSpecific, sackPlayers, profileName) ConfigLoadEvent().postAndCatch() } @@ -73,7 +73,7 @@ object ProfileStorageData { if (profileSpecific == null) { val profileName = event.name - loadProfileSpecific(playerSpecific, sackPlayers, profileName, "first join (chat message)") + loadProfileSpecific(playerSpecific, sackPlayers, profileName) } } @@ -86,7 +86,7 @@ object ProfileStorageData { val pattern = "§e§lProfile: §r§a(?.*)".toPattern() pattern.matchMatcher(line) { val profileName = group("name").lowercase() - loadProfileSpecific(playerSpecific, sackPlayers, profileName, "tab list") + loadProfileSpecific(playerSpecific, sackPlayers, profileName) nextProfile = null return } @@ -105,17 +105,20 @@ object ProfileStorageData { if (System.currentTimeMillis() > noTabListTime + 3_000) { noTabListTime = System.currentTimeMillis() LorenzUtils.chat( - "§c[SkyHanni] Extra Information from Tab list not found! " + - "Enable it: SkyBlock Menu ➜ Settings ➜ Personal ➜ User Interface ➜ Player List Info" + "Extra Information from Tab list not found! " + + "Enable it: SkyBlock Menu ➜ Settings ➜ Personal ➜ User Interface ➜ Player List Info" ) } } - private fun loadProfileSpecific(playerSpecific: Storage.PlayerSpecific, sackProfile: SackData.PlayerSpecific, profileName: String, reason: String) { + private fun loadProfileSpecific( + playerSpecific: Storage.PlayerSpecific, + sackProfile: SackData.PlayerSpecific, + profileName: String + ) { noTabListTime = -1 profileSpecific = playerSpecific.profiles.getOrPut(profileName) { Storage.ProfileSpecific() } sackProfiles = sackProfile.profiles.getOrPut(profileName) { SackData.ProfileSpecific() } - tryMigrateProfileSpecific() loaded = true ConfigLoadEvent().postAndCatch() } @@ -125,79 +128,6 @@ object ProfileStorageData { val playerUuid = LorenzUtils.getRawPlayerUuid() playerSpecific = SkyHanniMod.feature.storage.players.getOrPut(playerUuid) { Storage.PlayerSpecific() } sackPlayers = SkyHanniMod.sackData.players.getOrPut(playerUuid) { SackData.PlayerSpecific() } - migratePlayerSpecific() ConfigLoadEvent().postAndCatch() } - - private fun migratePlayerSpecific() { - val oldHidden = SkyHanniMod.feature.hidden - if (oldHidden.isMigrated) return - - SkyHanniMod.feature.storage?.let { - it.gardenJacobFarmingContestTimes = oldHidden.gardenJacobFarmingContestTimes - } - } - - private fun tryMigrateProfileSpecific() { - val oldHidden = SkyHanniMod.feature.hidden - if (oldHidden.isMigrated) return - - profileSpecific?.let { - it.currentPet = oldHidden.currentPet - - for ((rawLocation, minionName) in oldHidden.minionName) { - val lastClick = oldHidden.minionLastClick[rawLocation] ?: -1 - val location = LorenzVec.decodeFromString(rawLocation) - val minionConfig = Storage.ProfileSpecific.MinionConfig() - minionConfig.displayName = minionName - minionConfig.lastClicked = lastClick - it.minions[location] = minionConfig - } - } - - profileSpecific?.crimsonIsle?.let { - it.quests = oldHidden.crimsonIsleQuests - it.miniBossesDoneToday = oldHidden.crimsonIsleMiniBossesDoneToday - it.kuudraTiersDone = oldHidden.crimsonIsleKuudraTiersDone - } - - profileSpecific?.garden?.let { - it.experience = oldHidden.gardenExp.toLong() - it.cropCounter = oldHidden.gardenCropCounter - it.cropUpgrades = oldHidden.gardenCropUpgrades - - for ((crop, speed) in oldHidden.gardenCropsPerSecond) { - if (speed != -1) { - it.cropsPerSecond[crop] = speed - } - } - - it.latestBlocksPerSecond = oldHidden.gardenLatestBlocksPerSecond - it.latestTrueFarmingFortune = oldHidden.gardenLatestTrueFarmingFortune - it.savedCropAccessory = oldHidden.savedCropAccessory - it.dicerRngDrops = oldHidden.gardenDicerRngDrops - it.informedAboutLowMatter = oldHidden.informedAboutLowMatter - it.informedAboutLowFuel = oldHidden.informedAboutLowFuel - it.visitorInterval = oldHidden.visitorInterval - it.nextSixthVisitorArrival = oldHidden.nextSixthVisitorArrival - it.farmArmorDrops = oldHidden.gardenFarmingArmorDrops - it.composterUpgrades = oldHidden.gardenComposterUpgrades - it.toolWithBountiful = oldHidden.gardenToolHasBountiful - it.composterCurrentOrganicMatterItem = oldHidden.gardenComposterCurrentOrganicMatterItem - it.composterCurrentFuelItem = oldHidden.gardenComposterCurrentFuelItem - } - - profileSpecific?.garden?.visitorDrops?.let { - val old = oldHidden.visitorDrops - it.acceptedVisitors = old.acceptedVisitors - it.deniedVisitors = old.deniedVisitors - it.visitorRarities = old.visitorRarities - it.copper = old.copper - it.farmingExp = old.farmingExp - it.coinsSpent = old.coinsSpent - it.rewardsCount = old.rewardsCount - } - - oldHidden.isMigrated = true - } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/PurseAPI.kt b/src/main/java/at/hannibal2/skyhanni/data/PurseAPI.kt index cb3b2103197e..0deb53164d2a 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/PurseAPI.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/PurseAPI.kt @@ -5,6 +5,7 @@ import at.hannibal2.skyhanni.events.LorenzTickEvent import at.hannibal2.skyhanni.events.PurseChangeCause import at.hannibal2.skyhanni.events.PurseChangeEvent import at.hannibal2.skyhanni.utils.NumberUtil.formatNumber +import at.hannibal2.skyhanni.utils.NumberUtil.milion import at.hannibal2.skyhanni.utils.StringUtils.matchMatcher import net.minecraft.client.Minecraft import net.minecraftforge.fml.common.eventhandler.SubscribeEvent @@ -41,12 +42,16 @@ class PurseAPI { if (diff == 1.0) { return PurseChangeCause.GAIN_TALISMAN_OF_COINS } + + if (diff == 15.milion || diff == 100.milion) { + return PurseChangeCause.GAIN_DICE_ROLL + } + if (Minecraft.getMinecraft().currentScreen == null) { val timeDiff = System.currentTimeMillis() - inventoryCloseTime if (timeDiff > 2_000) { return PurseChangeCause.GAIN_MOB_KILL } - } return PurseChangeCause.GAIN_UNKNOWN } else { @@ -55,7 +60,11 @@ class PurseAPI { return PurseChangeCause.LOSE_SLAYER_QUEST_STARTED } + if (diff == -6_666_666.0 || diff == -666_666.0) { + return PurseChangeCause.LOSE_DICE_ROLL_COST + } + return PurseChangeCause.LOSE_UNKNOWN } } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/RenderData.kt b/src/main/java/at/hannibal2/skyhanni/data/RenderData.kt index f109ea01b897..9a57f87cccfe 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/RenderData.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/RenderData.kt @@ -48,4 +48,4 @@ class RenderData { if (!SkyHanniDebugsAndTests.globalRender) return LorenzRenderWorldEvent(event.partialTicks).postAndCatch() } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/SackAPI.kt b/src/main/java/at/hannibal2/skyhanni/data/SackAPI.kt index 59d250b0ad81..3694bf672f86 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/SackAPI.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/SackAPI.kt @@ -1,16 +1,15 @@ package at.hannibal2.skyhanni.data import at.hannibal2.skyhanni.SkyHanniMod +import at.hannibal2.skyhanni.config.ConfigFileType import at.hannibal2.skyhanni.events.InventoryCloseEvent import at.hannibal2.skyhanni.events.InventoryFullyOpenedEvent import at.hannibal2.skyhanni.events.LorenzChatEvent import at.hannibal2.skyhanni.events.SackChangeEvent -import at.hannibal2.skyhanni.features.fishing.trophy.TrophyFishManager -import at.hannibal2.skyhanni.features.fishing.trophy.TrophyFishManager.getFilletValue +import at.hannibal2.skyhanni.features.fishing.FishingAPI import at.hannibal2.skyhanni.features.fishing.trophy.TrophyRarity import at.hannibal2.skyhanni.features.inventory.SackDisplay import at.hannibal2.skyhanni.utils.ItemUtils.getInternalName -import at.hannibal2.skyhanni.utils.ItemUtils.getInternalName_old import at.hannibal2.skyhanni.utils.ItemUtils.getLore import at.hannibal2.skyhanni.utils.ItemUtils.name import at.hannibal2.skyhanni.utils.LorenzUtils @@ -21,6 +20,7 @@ import at.hannibal2.skyhanni.utils.NEUItems.getNpcPriceOrNull import at.hannibal2.skyhanni.utils.NEUItems.getPrice import at.hannibal2.skyhanni.utils.NumberUtil.formatNumber import at.hannibal2.skyhanni.utils.StringUtils.matchMatcher +import at.hannibal2.skyhanni.utils.StringUtils.matches import at.hannibal2.skyhanni.utils.StringUtils.removeColor import com.google.gson.annotations.Expose import net.minecraft.item.ItemStack @@ -32,6 +32,7 @@ object SackAPI { private var lastOpenedInventory = "" var inSackInventory = false + // TODO USE SH-REPO private val sackPattern = "^(.* Sack|Enchanted .* Sack)$".toPattern() private val numPattern = @@ -66,7 +67,7 @@ object SackAPI { val inventoryName = event.inventoryName val isNewInventory = inventoryName != lastOpenedInventory lastOpenedInventory = inventoryName - val match = sackPattern.matcher(inventoryName).matches() + val match = sackPattern.matches(inventoryName) if (!match) return val stacks = event.inventoryItems isRuneSack = inventoryName == "Runes Sack" @@ -158,13 +159,8 @@ object SackAPI { if (savingSacks) setSackItem(item.internalName, item.stored.formatNumber()) item.price = if (isTrophySack) { - val internal = stack.getInternalName_old() - val trophyFishName = internal.substringBeforeLast("_") - .replace("_", "").lowercase() - val trophyRarityName = internal.substringAfterLast("_") - val info = TrophyFishManager.getInfo(trophyFishName) - val rarity = TrophyRarity.getByName(trophyRarityName) ?: TrophyRarity.BRONZE - val filletValue = (info?.getFilletValue(rarity) ?: 0) * stored.formatNumber() + val filletPerTrophy = FishingAPI.getFilletPerTrophy(stack.getInternalName()) + val filletValue = filletPerTrophy * stored.formatNumber() item.magmaFish = filletValue "MAGMA_FISH".asInternalName().sackPrice(filletValue.toString()) } else { @@ -301,7 +297,7 @@ object SackAPI { private fun saveSackData() { ProfileStorageData.sackProfiles?.sackContents = sackData - SkyHanniMod.configManager.saveSackData("saving-data") + SkyHanniMod.configManager.saveConfig(ConfigFileType.SACKS, "saving-data") } data class SackGemstone( diff --git a/src/main/java/at/hannibal2/skyhanni/data/SkillExperience.kt b/src/main/java/at/hannibal2/skyhanni/data/SkillExperience.kt index 78c25e79975e..470c8d171306 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/SkillExperience.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/SkillExperience.kt @@ -3,6 +3,7 @@ package at.hannibal2.skyhanni.data import at.hannibal2.skyhanni.events.InventoryFullyOpenedEvent import at.hannibal2.skyhanni.events.LorenzActionBarEvent import at.hannibal2.skyhanni.events.ProfileJoinEvent +import at.hannibal2.skyhanni.events.SkillExpGainEvent import at.hannibal2.skyhanni.utils.ItemUtils.getLore import at.hannibal2.skyhanni.utils.ItemUtils.name import at.hannibal2.skyhanni.utils.LorenzUtils @@ -32,7 +33,14 @@ class SkillExperience { val neededForNextLevel = group("needed").formatNumber() val nextLevel = getLevelForExpExactly(neededForNextLevel) val baseExp = getExpForLevel(nextLevel - 1) - skillExp[skill] = baseExp + overflow + val totalExp = baseExp + overflow + skillExp[skill] = totalExp + SkillExpGainEvent(skill).postAndCatch() + } + val pattern = ".*§3+(?.+) (?.*) \\((?.*)%\\).*".toPattern() + pattern.matchMatcher(event.message) { + val skill = group("skill").lowercase() + SkillExpGainEvent(skill).postAndCatch() } } diff --git a/src/main/java/at/hannibal2/skyhanni/data/SlayerAPI.kt b/src/main/java/at/hannibal2/skyhanni/data/SlayerAPI.kt index f3c23700daa7..2a6b99297f73 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/SlayerAPI.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/SlayerAPI.kt @@ -15,7 +15,6 @@ import at.hannibal2.skyhanni.utils.NEUItems.getNpcPriceOrNull import at.hannibal2.skyhanni.utils.NEUItems.getPrice import at.hannibal2.skyhanni.utils.NumberUtil import at.hannibal2.skyhanni.utils.RecalculatingValue -import at.hannibal2.skyhanni.utils.StringUtils.removeColor import com.google.common.cache.CacheBuilder import net.minecraftforge.fml.common.eventhandler.SubscribeEvent import java.util.concurrent.TimeUnit @@ -29,6 +28,7 @@ object SlayerAPI { var questStartTime = 0L var isInCorrectArea = false + var isInAnyArea = false var latestSlayerCategory = "" private var latestProgressChangeTime = 0L var latestWrongAreaWarning = 0L @@ -40,22 +40,6 @@ object SlayerAPI { System.currentTimeMillis() } else latestProgressChangeTime - - // TODO use repo - fun ignoreSlayerDrop(name: String) = when (name.removeColor()) { - // maybe everywhere? - "Stone" -> true - "Head" -> true - - // Spider - "Cobweb" -> true - - // Blaze - "Water Bottle" -> true - - else -> false - } - fun getItemNameAndPrice(internalName: NEUInternalName, amount: Int): Pair { val key = internalName to amount nameCache.getIfPresent(key)?.let { @@ -139,9 +123,12 @@ object SlayerAPI { if (event.isMod(5)) { isInCorrectArea = if (LorenzUtils.isStrandedProfile) { + isInAnyArea = true true } else { - getSlayerTypeForCurrentArea() == getActiveSlayer() + val slayerTypeForCurrentArea = getSlayerTypeForCurrentArea() + isInAnyArea = slayerTypeForCurrentArea != null + slayerTypeForCurrentArea == getActiveSlayer() && slayerTypeForCurrentArea != null } } } @@ -178,4 +165,4 @@ object SlayerAPI { else -> null } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/FriendsJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/local/FriendsJson.java similarity index 89% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/FriendsJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/local/FriendsJson.java index 82482b6a68cb..d95cea3bda43 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/FriendsJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/local/FriendsJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.local; import com.google.gson.annotations.Expose; diff --git a/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/local/JacobContestsJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/local/JacobContestsJson.java new file mode 100644 index 000000000000..0eb31c5fd62c --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/local/JacobContestsJson.java @@ -0,0 +1,13 @@ +package at.hannibal2.skyhanni.data.jsonobjects.local; + +import at.hannibal2.skyhanni.features.garden.CropType; +import com.google.gson.annotations.Expose; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class JacobContestsJson { + @Expose + public Map> contestTimes = new HashMap<>(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/local/KnownFeaturesJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/local/KnownFeaturesJson.java new file mode 100644 index 000000000000..e72400c9ec0d --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/local/KnownFeaturesJson.java @@ -0,0 +1,12 @@ +package at.hannibal2.skyhanni.data.jsonobjects.local; + +import com.google.gson.annotations.Expose; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class KnownFeaturesJson { + @Expose + public Map> knownFeatures = new HashMap<>(); +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/MayorJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/local/MayorJson.java similarity index 75% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/MayorJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/local/MayorJson.java index bc877658a73e..6525e59d34bc 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/MayorJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/local/MayorJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.local; import com.google.gson.annotations.Expose; @@ -27,11 +27,11 @@ public class Candidate { @Override public String toString() { return "Candidate{" + - "key='" + key + '\'' + - ", name='" + name + '\'' + - ", perks=" + perks + - ", votes=" + votes + - '}'; + "key='" + key + '\'' + + ", name='" + name + '\'' + + ", perks=" + perks + + ", votes=" + votes + + '}'; } } @@ -62,9 +62,9 @@ public static class Perk { @Override public String toString() { return "Perk{" + - "name='" + name + '\'' + - ", description='" + description + '\'' + - '}'; + "name='" + name + '\'' + + ", description='" + description + '\'' + + '}'; } } } diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/AnitaUpgradeCostsJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/AnitaUpgradeCostsJson.java similarity index 84% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/AnitaUpgradeCostsJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/AnitaUpgradeCostsJson.java index 09a2de7db9ba..a1122eec348a 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/AnitaUpgradeCostsJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/AnitaUpgradeCostsJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; @@ -15,4 +15,4 @@ public static class Price { @Expose public Integer jacob_tickets; } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/ArmorDropsJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/ArmorDropsJson.java similarity index 85% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/ArmorDropsJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/ArmorDropsJson.java index 698bad3db170..c8038c49fc34 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/ArmorDropsJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/ArmorDropsJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; @@ -16,4 +16,4 @@ public static class DropInfo { @Expose public List chance; } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/BingoJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/BingoJson.java similarity index 75% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/BingoJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/BingoJson.java index 810f6d3abfd1..babe7cc9e493 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/BingoJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/BingoJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; @@ -15,5 +15,7 @@ public static class BingoTip { @Expose public List note; + @Expose + public String found; } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/BingoRanksJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/BingoRanksJson.java similarity index 73% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/BingoRanksJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/BingoRanksJson.java index 49d7e662f49d..98f2a469547f 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/BingoRanksJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/BingoRanksJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; @@ -7,4 +7,4 @@ public class BingoRanksJson { @Expose public Map ranks; -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/ContributorListJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/ContributorListJson.java similarity index 73% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/ContributorListJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/ContributorListJson.java index 6ab663941508..dc2b4a5ac47d 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/ContributorListJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/ContributorListJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; import java.util.List; @@ -6,4 +6,4 @@ public class ContributorListJson { @Expose public List usernames; -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/CrimsonIsleReputationJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/CrimsonIsleReputationJson.java similarity index 92% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/CrimsonIsleReputationJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/CrimsonIsleReputationJson.java index 9235680fb365..f349aef9a892 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/CrimsonIsleReputationJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/CrimsonIsleReputationJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/DanceRoomInstructionsJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/DanceRoomInstructionsJson.java similarity index 74% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/DanceRoomInstructionsJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/DanceRoomInstructionsJson.java index 9316d8671f9c..e7c167e5349b 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/DanceRoomInstructionsJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/DanceRoomInstructionsJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; @@ -7,4 +7,4 @@ public class DanceRoomInstructionsJson { @Expose public List instructions; -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/DicerDropsJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/DicerDropsJson.java similarity index 91% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/DicerDropsJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/DicerDropsJson.java index 996a558eaf8e..00a662768473 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/DicerDropsJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/DicerDropsJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; import com.google.gson.annotations.SerializedName; @@ -28,4 +28,4 @@ public static class DropInfo { @Expose public List amount; } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/DisabledFeaturesJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/DisabledFeaturesJson.java similarity index 74% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/DisabledFeaturesJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/DisabledFeaturesJson.java index 45abedfa3da1..1099cf782ded 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/DisabledFeaturesJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/DisabledFeaturesJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; @@ -7,4 +7,4 @@ public class DisabledFeaturesJson { @Expose public Map features; -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/EnigmaSoulsJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/EnigmaSoulsJson.java similarity index 87% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/EnigmaSoulsJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/EnigmaSoulsJson.java index 5769520f5c41..cd17d1744ef2 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/EnigmaSoulsJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/EnigmaSoulsJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import at.hannibal2.skyhanni.utils.LorenzVec; import com.google.gson.annotations.Expose; @@ -17,4 +17,4 @@ public static class EnigmaPosition { @Expose public LorenzVec position; } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/FishingProfitItemsJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/FishingProfitItemsJson.java new file mode 100644 index 000000000000..47f7fc0bb276 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/FishingProfitItemsJson.java @@ -0,0 +1,12 @@ +package at.hannibal2.skyhanni.data.jsonobjects.repo; + +import at.hannibal2.skyhanni.utils.NEUInternalName; +import com.google.gson.annotations.Expose; + +import java.util.List; +import java.util.Map; + +public class FishingProfitItemsJson { + @Expose + public Map> categories; +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/GardenJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/GardenJson.java new file mode 100644 index 000000000000..acb8e08ba118 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/GardenJson.java @@ -0,0 +1,58 @@ +package at.hannibal2.skyhanni.data.jsonobjects.repo; + +import at.hannibal2.skyhanni.features.garden.CropType; +import at.hannibal2.skyhanni.utils.LorenzRarity; +import at.hannibal2.skyhanni.utils.LorenzVec; +import com.google.gson.annotations.Expose; +import org.jetbrains.annotations.Nullable; + +import java.util.List; +import java.util.Map; + +public class GardenJson { + @Expose + public List garden_exp; + + @Expose + public Map> crop_milestones; + + @Expose + public Map crop_milestone_community_help; + + @Expose + public Map visitors; + + @Expose + public Map organic_matter; + + @Expose + public Map fuel; + + public static class GardenVisitor { + @Expose + public LorenzRarity rarity; + + @Expose + public LorenzRarity new_rarity; + + @Nullable + @Expose + public LorenzVec position; + + /** + * Formatted as follows: + * - If this visitor is a player, get the encoded skin value + * - If this visitor is a mob, get their mob class name + */ + @Nullable + @Expose + public String skinOrType; + + @Nullable + @Expose + public String mode; + + @Expose + public List need_items; + } +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/HideNotClickableItemsJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/HideNotClickableItemsJson.java similarity index 90% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/HideNotClickableItemsJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/HideNotClickableItemsJson.java index d4ac9c52b41f..8877e596e836 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/HideNotClickableItemsJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/HideNotClickableItemsJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; @@ -27,4 +27,4 @@ public static class SalvageFilter { @Expose public List items; } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/ItemsJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/ItemsJson.java similarity index 80% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/ItemsJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/ItemsJson.java index f3767191331a..c6bfc90f3e6b 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/ItemsJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/ItemsJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; @@ -11,4 +11,4 @@ public class ItemsJson { @Expose public Map crimson_tiers; -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/LocationFixJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/LocationFixJson.java new file mode 100644 index 000000000000..0df76b4a9c05 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/LocationFixJson.java @@ -0,0 +1,27 @@ +package at.hannibal2.skyhanni.data.jsonobjects.repo; + +import at.hannibal2.skyhanni.utils.LorenzVec; +import com.google.gson.annotations.Expose; + +import java.util.Map; + +public class LocationFixJson { + + @Expose + public Map locationFixes; + + public static class LocationFix { + @Expose + public LorenzVec a; + + @Expose + public LorenzVec b; + + @Expose + public String island_name; + + @Expose + public String real_location; + } + +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/MinionXPJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/MinionXPJson.java new file mode 100644 index 000000000000..44f66b8b86f9 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/MinionXPJson.java @@ -0,0 +1,10 @@ +package at.hannibal2.skyhanni.data.jsonobjects.repo; + +import com.google.gson.annotations.Expose; + +import java.util.Map; + +public class MinionXPJson { + @Expose + public Map> minion_xp; +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/ModGuiSwitcherJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/ModGuiSwitcherJson.java similarity index 89% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/ModGuiSwitcherJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/ModGuiSwitcherJson.java index 078b1f6ad537..cf0b0656d593 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/ModGuiSwitcherJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/ModGuiSwitcherJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; @@ -22,4 +22,4 @@ public static class Mod { @Expose public List guiPath = new ArrayList<>(); } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/MultiFilterJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/MultiFilterJson.java similarity index 87% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/MultiFilterJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/MultiFilterJson.java index 8704f91fbaf6..0d0c0d6e1191 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/MultiFilterJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/MultiFilterJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; @@ -22,4 +22,4 @@ public class MultiFilterJson { @Expose public String description; -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/ParkourJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/ParkourJson.java similarity index 88% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/ParkourJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/ParkourJson.java index 5ae2d40cae55..0dd51143010d 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/ParkourJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/ParkourJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import at.hannibal2.skyhanni.utils.LorenzVec; import com.google.gson.annotations.Expose; @@ -20,4 +20,4 @@ public static class ShortCut { @Expose public int to; } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/PlayerChatFilterJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/PlayerChatFilterJson.java similarity index 74% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/PlayerChatFilterJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/PlayerChatFilterJson.java index a65a2f8a1957..708ac24e06aa 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/PlayerChatFilterJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/PlayerChatFilterJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; @@ -7,4 +7,4 @@ public class PlayerChatFilterJson { @Expose public List filters; -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/RiftEffigiesJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/RiftEffigiesJson.java similarity index 78% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/RiftEffigiesJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/RiftEffigiesJson.java index d914ef9344f2..ad94c374dc35 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/RiftEffigiesJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/RiftEffigiesJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import at.hannibal2.skyhanni.utils.LorenzVec; import com.google.gson.annotations.Expose; @@ -8,4 +8,4 @@ public class RiftEffigiesJson { @Expose public List locations; -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/SacksJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/SacksJson.java similarity index 71% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/SacksJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/SacksJson.java index dfd2103efc4e..8a2765210842 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/SacksJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/SacksJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; @@ -7,4 +7,4 @@ public class SacksJson { @Expose public List sackList; -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/SeaCreatureJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/SeaCreatureJson.java similarity index 85% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/SeaCreatureJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/SeaCreatureJson.java index 52ed7f636f65..3f8449fb6ac6 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/SeaCreatureJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/SeaCreatureJson.java @@ -1,32 +1,33 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; - -import at.hannibal2.skyhanni.utils.LorenzRarity; -import com.google.gson.annotations.Expose; -import com.google.gson.reflect.TypeToken; - -import java.lang.reflect.Type; -import java.util.Map; - -public class SeaCreatureJson { - - public static Type TYPE = new TypeToken>(){}.getType(); - - public static class Variant { - @Expose - public String chat_color; - @Expose - public Map sea_creatures; - } - - public static class SeaCreature { - @Expose - public String chat_message; - @Expose - public int fishing_experience; - @Expose - public Boolean rare; - @Expose - public LorenzRarity rarity; - } - -} +package at.hannibal2.skyhanni.data.jsonobjects.repo; + +import at.hannibal2.skyhanni.utils.LorenzRarity; +import com.google.gson.annotations.Expose; +import com.google.gson.reflect.TypeToken; + +import java.lang.reflect.Type; +import java.util.Map; + +public class SeaCreatureJson { + + public static Type TYPE = new TypeToken>() { + }.getType(); + + public static class Variant { + @Expose + public String chat_color; + @Expose + public Map sea_creatures; + } + + public static class SeaCreature { + @Expose + public String chat_message; + @Expose + public int fishing_experience; + @Expose + public Boolean rare; + @Expose + public LorenzRarity rarity; + } + +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/SlayerProfitTrackerItemsJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/SlayerProfitTrackerItemsJson.java similarity index 82% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/SlayerProfitTrackerItemsJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/SlayerProfitTrackerItemsJson.java index 37758220016b..f9c91bdfc124 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/SlayerProfitTrackerItemsJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/SlayerProfitTrackerItemsJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import at.hannibal2.skyhanni.utils.NEUInternalName; import com.google.gson.annotations.Expose; @@ -9,4 +9,4 @@ public class SlayerProfitTrackerItemsJson { @Expose public Map> slayers; -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/TabListJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/TabListJson.java new file mode 100644 index 000000000000..2c475679e095 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/TabListJson.java @@ -0,0 +1,11 @@ +package at.hannibal2.skyhanni.data.jsonobjects.repo; + +import com.google.gson.annotations.Expose; + +import java.util.List; + +public class TabListJson { + + @Expose + public List sun_moon_symbols; +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/TrophyFishJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/TrophyFishJson.java similarity index 89% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/TrophyFishJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/TrophyFishJson.java index 6303c16be4fd..c15adf1b89e9 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/TrophyFishJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/TrophyFishJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import at.hannibal2.skyhanni.features.fishing.trophy.TrophyRarity; import com.google.gson.annotations.Expose; @@ -22,4 +22,4 @@ public static class TrophyFishInfo { @Expose public Map fillet; } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/VipVisitsJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/VipVisitsJson.java similarity index 72% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/VipVisitsJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/VipVisitsJson.java index c80f4953f2dc..d2a4a0562ac8 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/VipVisitsJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/VipVisitsJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; @@ -7,4 +7,4 @@ public class VipVisitsJson { @Expose public List vipVisits; -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/WarpsJson.java b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/WarpsJson.java similarity index 72% rename from src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/WarpsJson.java rename to src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/WarpsJson.java index e09bf3c9d40f..ef81b052a462 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/jsonobjects/WarpsJson.java +++ b/src/main/java/at/hannibal2/skyhanni/data/jsonobjects/repo/WarpsJson.java @@ -1,4 +1,4 @@ -package at.hannibal2.skyhanni.utils.jsonobjects; +package at.hannibal2.skyhanni.data.jsonobjects.repo; import com.google.gson.annotations.Expose; @@ -7,4 +7,4 @@ public class WarpsJson { @Expose public List warpCommands; -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/model/ComposterUpgrade.kt b/src/main/java/at/hannibal2/skyhanni/data/model/ComposterUpgrade.kt index 4712689dc335..627bfdef7add 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/model/ComposterUpgrade.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/model/ComposterUpgrade.kt @@ -10,9 +10,10 @@ enum class ComposterUpgrade(val displayName: String, val slotNumber: Int) { companion object { private fun regexValues() = entries.joinToString("|") { it.displayName } + // TODO USE SH-REPO val regex = "§a(?${regexValues()})(?: (?.*))?".toPattern() fun getByName(name: String) = entries.firstOrNull { it.displayName == name } } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/data/repo/RepoManager.kt b/src/main/java/at/hannibal2/skyhanni/data/repo/RepoManager.kt index 593d9a65241c..9dcba5e8fbb3 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/repo/RepoManager.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/repo/RepoManager.kt @@ -83,7 +83,7 @@ class RepoManager(private val configLocation: File) { if (unsuccessfulConstants.isEmpty()) { if (command) { - LorenzUtils.chat("§e[SkyHanni] §7The repo is already up to date!") + LorenzUtils.chat("§7The repo is already up to date!") atomicShouldManuallyReload.set(false) } return@supplyAsync false @@ -156,12 +156,13 @@ class RepoManager(private val configLocation: File) { } comp.complete(null) if (answerMessage.isNotEmpty() && !error) { - LorenzUtils.chat("§e[SkyHanni] §a$answerMessage") + LorenzUtils.chat("§a$answerMessage") } if (error) { LorenzUtils.clickableChat( - "§e[SkyHanni] Error with the repo detected, try /shupdaterepo to fix it!", - "shupdaterepo" + "Error with the repo detected, try /shupdaterepo to fix it!", + "shupdaterepo", + prefixColor = "§c" ) if (unsuccessfulConstants.isEmpty()) { unsuccessfulConstants.add("All Constants") @@ -174,9 +175,12 @@ class RepoManager(private val configLocation: File) { fun displayRepoStatus(joinEvent: Boolean) { if (joinEvent) { if (unsuccessfulConstants.isNotEmpty()) { - LorenzUtils.chat("§c[SkyHanni] §7Repo Issue! Some features may not work. Please report this error on the Discord!") - LorenzUtils.chat("§7Repo Auto Update Value: §c${SkyHanniMod.feature.dev.repoAutoUpdate}") - LorenzUtils.chat("§7If you have Repo Auto Update turned off, please try turning that on.\n§cUnsuccessful Constants §7(${unsuccessfulConstants.size}):") + LorenzUtils.error( + "§7Repo Issue! Some features may not work. Please report this error on the Discord!\n" + + "§7Repo Auto Update Value: §c${SkyHanniMod.feature.dev.repoAutoUpdate}\n" + + "§7If you have Repo Auto Update turned off, please try turning that on.\n" + + "§cUnsuccessful Constants §7(${unsuccessfulConstants.size}):" + ) for (constant in unsuccessfulConstants) { LorenzUtils.chat(" §e- §7$constant") } @@ -184,14 +188,14 @@ class RepoManager(private val configLocation: File) { return } if (unsuccessfulConstants.isEmpty() && successfulConstants.isNotEmpty()) { - LorenzUtils.chat("§a[SkyHanni] Repo working fine!") + LorenzUtils.chat("Repo working fine!", prefixColor = "§a") return } - if (successfulConstants.isNotEmpty()) LorenzUtils.chat("§a[SkyHanni] Successful Constants §7(${successfulConstants.size}):") + if (successfulConstants.isNotEmpty()) LorenzUtils.chat("Successful Constants §7(${successfulConstants.size}):", prefixColor = "§a") for (constant in successfulConstants) { LorenzUtils.chat(" §a- §7$constant") } - LorenzUtils.chat("§c[SkyHanni] Unsuccessful Constants §7(${unsuccessfulConstants.size}):") + LorenzUtils.chat("Unsuccessful Constants §7(${unsuccessfulConstants.size}):") for (constant in unsuccessfulConstants) { LorenzUtils.chat(" §e- §7$constant") } diff --git a/src/main/java/at/hannibal2/skyhanni/events/DamageIndicatorDeathEvent.kt b/src/main/java/at/hannibal2/skyhanni/events/DamageIndicatorDeathEvent.kt new file mode 100644 index 000000000000..141f293a388d --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/events/DamageIndicatorDeathEvent.kt @@ -0,0 +1,6 @@ +package at.hannibal2.skyhanni.events + +import at.hannibal2.skyhanni.features.combat.damageindicator.EntityData +import net.minecraft.entity.EntityLivingBase + +class DamageIndicatorDeathEvent(val entity: EntityLivingBase, val data: EntityData) : LorenzEvent() diff --git a/src/main/java/at/hannibal2/skyhanni/events/DataWatcherUpdatedEvent.kt b/src/main/java/at/hannibal2/skyhanni/events/DataWatcherUpdatedEvent.kt new file mode 100644 index 000000000000..05389c2d7f04 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/events/DataWatcherUpdatedEvent.kt @@ -0,0 +1,9 @@ +package at.hannibal2.skyhanni.events + +import net.minecraft.entity.DataWatcher +import net.minecraft.entity.Entity + +data class DataWatcherUpdatedEvent( + val entity: Entity, + val updatedEntries: List, +) : LorenzEvent() diff --git a/src/main/java/at/hannibal2/skyhanni/events/EntityCustomNameUpdateEvent.kt b/src/main/java/at/hannibal2/skyhanni/events/EntityCustomNameUpdateEvent.kt new file mode 100644 index 000000000000..4b4b075e3ac3 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/events/EntityCustomNameUpdateEvent.kt @@ -0,0 +1,8 @@ +package at.hannibal2.skyhanni.events + +import net.minecraft.entity.Entity + +data class EntityCustomNameUpdateEvent( + val newName: String?, + val entity: Entity, +) : LorenzEvent() diff --git a/src/main/java/at/hannibal2/skyhanni/events/EntityEquipmentChangeEvent.kt b/src/main/java/at/hannibal2/skyhanni/events/EntityEquipmentChangeEvent.kt index 26705ab5e47d..eecc132caf51 100644 --- a/src/main/java/at/hannibal2/skyhanni/events/EntityEquipmentChangeEvent.kt +++ b/src/main/java/at/hannibal2/skyhanni/events/EntityEquipmentChangeEvent.kt @@ -9,6 +9,10 @@ data class EntityEquipmentChangeEvent( val newItemStack: ItemStack? ) : LorenzEvent() { val isHead get() = equipmentSlot == EQUIPMENT_SLOT_HEAD + val isChest get() = equipmentSlot == EQUIPMENT_SLOT_CHEST + val isLeggings get() = equipmentSlot == EQUIPMENT_SLOT_LEGGINGS + val isFeet get() = equipmentSlot == EQUIPMENT_SLOT_FEET + val isHand get() = equipmentSlot == EQUIPMENT_SLOT_HAND companion object { const val EQUIPMENT_SLOT_HEAD = 4 @@ -17,4 +21,4 @@ data class EntityEquipmentChangeEvent( const val EQUIPMENT_SLOT_FEET = 1 const val EQUIPMENT_SLOT_HAND = 0 } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/events/FishingBobberCastEvent.kt b/src/main/java/at/hannibal2/skyhanni/events/FishingBobberCastEvent.kt new file mode 100644 index 000000000000..01ea0222e82b --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/events/FishingBobberCastEvent.kt @@ -0,0 +1,5 @@ +package at.hannibal2.skyhanni.events + +import net.minecraft.entity.projectile.EntityFishHook + +class FishingBobberCastEvent(val bobber: EntityFishHook) : LorenzEvent() diff --git a/src/main/java/at/hannibal2/skyhanni/events/InventoryCloseEvent.kt b/src/main/java/at/hannibal2/skyhanni/events/InventoryCloseEvent.kt index bf43a57f9092..72630756a45c 100644 --- a/src/main/java/at/hannibal2/skyhanni/events/InventoryCloseEvent.kt +++ b/src/main/java/at/hannibal2/skyhanni/events/InventoryCloseEvent.kt @@ -3,9 +3,9 @@ package at.hannibal2.skyhanni.events import at.hannibal2.skyhanni.data.OtherInventoryData import net.minecraft.item.ItemStack -class InventoryCloseEvent(val inventory: OtherInventoryData.Inventory) : LorenzEvent() { +class InventoryCloseEvent(val inventory: OtherInventoryData.Inventory, val reopenSameName: Boolean) : LorenzEvent() { val inventoryId: Int by lazy { inventory.windowId } val inventoryName: String by lazy { inventory.title } val inventorySize: Int by lazy { inventory.slotCount } val inventoryItems: Map by lazy { inventory.items } -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/events/ItemAddEvent.kt b/src/main/java/at/hannibal2/skyhanni/events/ItemAddEvent.kt new file mode 100644 index 000000000000..ad0c6355dfd3 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/events/ItemAddEvent.kt @@ -0,0 +1,7 @@ +package at.hannibal2.skyhanni.events + +import at.hannibal2.skyhanni.data.ItemAddManager +import at.hannibal2.skyhanni.utils.NEUInternalName + +class ItemAddEvent(val internalName: NEUInternalName, val amount: Int, val source: ItemAddManager.Source) : + LorenzEvent() diff --git a/src/main/java/at/hannibal2/skyhanni/events/ItemInHandChangeEvent.kt b/src/main/java/at/hannibal2/skyhanni/events/ItemInHandChangeEvent.kt index 3f5b94b3c9ec..4ef39df43345 100644 --- a/src/main/java/at/hannibal2/skyhanni/events/ItemInHandChangeEvent.kt +++ b/src/main/java/at/hannibal2/skyhanni/events/ItemInHandChangeEvent.kt @@ -1,6 +1,5 @@ package at.hannibal2.skyhanni.events import at.hannibal2.skyhanni.utils.NEUInternalName -import net.minecraft.item.ItemStack -class ItemInHandChangeEvent(val internalName: NEUInternalName, val stack: ItemStack?) : LorenzEvent() \ No newline at end of file +class ItemInHandChangeEvent(val newItem: NEUInternalName, val oldItem: NEUInternalName) : LorenzEvent() diff --git a/src/main/java/at/hannibal2/skyhanni/events/LorenzEvent.kt b/src/main/java/at/hannibal2/skyhanni/events/LorenzEvent.kt index 2f39e381dffb..21f9d07e83ba 100644 --- a/src/main/java/at/hannibal2/skyhanni/events/LorenzEvent.kt +++ b/src/main/java/at/hannibal2/skyhanni/events/LorenzEvent.kt @@ -40,7 +40,7 @@ abstract class LorenzEvent : Event() { } if (errors > visibleErrors) { val hiddenErrors = errors - visibleErrors - LorenzUtils.chat("§c[SkyHanni] $hiddenErrors more errors in $eventName are hidden!") + LorenzUtils.error("$hiddenErrors more errors in $eventName are hidden!") } return if (isCancelable) isCanceled else false } diff --git a/src/main/java/at/hannibal2/skyhanni/events/MessageSendToServerEvent.kt b/src/main/java/at/hannibal2/skyhanni/events/MessageSendToServerEvent.kt new file mode 100644 index 000000000000..b6dff658e30e --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/events/MessageSendToServerEvent.kt @@ -0,0 +1,6 @@ +package at.hannibal2.skyhanni.events + +import net.minecraftforge.fml.common.eventhandler.Cancelable + +@Cancelable +class MessageSendToServerEvent(val message: String) : LorenzEvent() diff --git a/src/main/java/at/hannibal2/skyhanni/events/MinionOpenEvent.kt b/src/main/java/at/hannibal2/skyhanni/events/MinionOpenEvent.kt index 5d577b6eeb59..bfe8649ba97c 100644 --- a/src/main/java/at/hannibal2/skyhanni/events/MinionOpenEvent.kt +++ b/src/main/java/at/hannibal2/skyhanni/events/MinionOpenEvent.kt @@ -1,5 +1,8 @@ package at.hannibal2.skyhanni.events +import at.hannibal2.skyhanni.utils.LorenzVec import net.minecraft.item.ItemStack -class MinionOpenEvent(val inventoryName: String, val inventoryItems: Map) : LorenzEvent() \ No newline at end of file +class MinionOpenEvent(val inventoryName: String, val inventoryItems: Map) : LorenzEvent() +class MinionCloseEvent : LorenzEvent() +class MinionStorageOpenEvent(val position: LorenzVec?, val inventoryItems: Map) : LorenzEvent() diff --git a/src/main/java/at/hannibal2/skyhanni/events/OwnInventoryItemUpdateEvent.kt b/src/main/java/at/hannibal2/skyhanni/events/OwnInventoryItemUpdateEvent.kt index a7a5ba4913bf..32e19e7514a3 100644 --- a/src/main/java/at/hannibal2/skyhanni/events/OwnInventoryItemUpdateEvent.kt +++ b/src/main/java/at/hannibal2/skyhanni/events/OwnInventoryItemUpdateEvent.kt @@ -2,7 +2,4 @@ package at.hannibal2.skyhanni.events import net.minecraft.item.ItemStack -/** - * Note: This event is async and may not be executed on the main minecraft thread. - */ -data class OwnInventoryItemUpdateEvent(val itemStack: ItemStack) : LorenzEvent() \ No newline at end of file +data class OwnInventoryItemUpdateEvent(val itemStack: ItemStack) : LorenzEvent() diff --git a/src/main/java/at/hannibal2/skyhanni/events/PurseChangeEvent.kt b/src/main/java/at/hannibal2/skyhanni/events/PurseChangeEvent.kt index 50343a7d9bcb..d776fe32b672 100644 --- a/src/main/java/at/hannibal2/skyhanni/events/PurseChangeEvent.kt +++ b/src/main/java/at/hannibal2/skyhanni/events/PurseChangeEvent.kt @@ -5,8 +5,10 @@ class PurseChangeEvent(val coins: Double, val reason: PurseChangeCause) : Lorenz enum class PurseChangeCause { GAIN_MOB_KILL, GAIN_TALISMAN_OF_COINS, + GAIN_DICE_ROLL, GAIN_UNKNOWN, LOSE_SLAYER_QUEST_STARTED, + LOSE_DICE_ROLL_COST, LOSE_UNKNOWN, -} \ No newline at end of file +} diff --git a/src/main/java/at/hannibal2/skyhanni/events/RenderEntityOutlineEvent.kt b/src/main/java/at/hannibal2/skyhanni/events/RenderEntityOutlineEvent.kt index 21e18bd6c90a..6a197de6ccd1 100644 --- a/src/main/java/at/hannibal2/skyhanni/events/RenderEntityOutlineEvent.kt +++ b/src/main/java/at/hannibal2/skyhanni/events/RenderEntityOutlineEvent.kt @@ -7,7 +7,7 @@ import net.minecraft.entity.item.EntityItemFrame import java.util.function.Consumer class RenderEntityOutlineEvent(theType: Type?, potentialEntities: HashSet?) : - LorenzEvent() { + LorenzEvent() { /** * The phase of the event (see [Type] @@ -115,4 +115,4 @@ class RenderEntityOutlineEvent(theType: Type?, potentialEntities: HashSet() + var tips: Map = emptyMap() + + @SubscribeEvent + fun onRepoReload(event: RepositoryReloadEvent) { + ranks = event.getConstant("BingoRanks").ranks + tips = event.getConstant("Bingo").bingo_tips + } + + fun getRank(text: String) = ranks.entries.find { text.contains(it.key) }?.value + + fun getIcon(searchRank: Int) = ranks.entries.find { it.value == searchRank }?.key + + // We added the suffix (Community Goal) so that older skyhanni versions don't crash with the new repo data. + fun getCommunityTip(itemName: String) = + tips.filter { itemName.startsWith(it.key.split(" (Community Goal)")[0]) }.values.firstOrNull() + +} diff --git a/src/main/java/at/hannibal2/skyhanni/features/bingo/BingoCardDisplay.kt b/src/main/java/at/hannibal2/skyhanni/features/bingo/BingoCardDisplay.kt index 0badd1e57f66..48a5cb456a88 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/bingo/BingoCardDisplay.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/bingo/BingoCardDisplay.kt @@ -2,10 +2,12 @@ package at.hannibal2.skyhanni.features.bingo import at.hannibal2.skyhanni.SkyHanniMod import at.hannibal2.skyhanni.config.ConfigUpdaterMigrator +import at.hannibal2.skyhanni.data.jsonobjects.repo.BingoJson.BingoTip import at.hannibal2.skyhanni.events.ConfigLoadEvent import at.hannibal2.skyhanni.events.GuiRenderEvent import at.hannibal2.skyhanni.events.InventoryFullyOpenedEvent import at.hannibal2.skyhanni.events.LorenzChatEvent +import at.hannibal2.skyhanni.events.LorenzTickEvent import at.hannibal2.skyhanni.features.bingo.card.CommunityGoal import at.hannibal2.skyhanni.features.bingo.card.PersonalGoal import at.hannibal2.skyhanni.utils.InventoryUtils @@ -15,18 +17,26 @@ import at.hannibal2.skyhanni.utils.ItemUtils.name import at.hannibal2.skyhanni.utils.LorenzUtils import at.hannibal2.skyhanni.utils.LorenzUtils.onToggle import at.hannibal2.skyhanni.utils.RenderUtils.renderStrings +import at.hannibal2.skyhanni.utils.SimpleTimeMark import at.hannibal2.skyhanni.utils.StringUtils.matchMatcher import at.hannibal2.skyhanni.utils.StringUtils.removeColor +import at.hannibal2.skyhanni.utils.TimeUtils +import at.hannibal2.skyhanni.utils.TimeUtils.format import net.minecraft.client.Minecraft import net.minecraft.client.gui.GuiChat import net.minecraftforge.fml.common.eventhandler.SubscribeEvent +import kotlin.time.Duration.Companion.days class BingoCardDisplay { private var display = emptyList() + // TODO USE SH-REPO private val goalCompletePattern = "§6§lBINGO GOAL COMPLETE! §r§e(?.*)".toPattern() + private var lastBingoCardOpenTime = SimpleTimeMark.farPast() + private var hasHiddenPersonalGoals = false + init { update() } @@ -35,6 +45,8 @@ class BingoCardDisplay { private const val MAX_PERSONAL_GOALS = 20 private const val MAX_COMMUNITY_GOALS = 5 + val personalHiddenGoalPattern = ".*§7§eThe next hint will unlock in (?