From 69a08217ec3ca685dfe1a0bdd53eb8d7424a8791 Mon Sep 17 00:00:00 2001 From: Rime <81419447+Emirlol@users.noreply.github.com> Date: Fri, 7 Jun 2024 15:36:58 +0300 Subject: Reformat SupercraftReminder and lowercase the uuid the variable Co-authored-by: Kevin <92656833+kevinthegreat1@users.noreply.github.com> --- .../skyblock/item/tooltip/adders/SupercraftReminder.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/main/java/de') diff --git a/src/main/java/de/hysky/skyblocker/skyblock/item/tooltip/adders/SupercraftReminder.java b/src/main/java/de/hysky/skyblocker/skyblock/item/tooltip/adders/SupercraftReminder.java index eb953b9c..8a8f198c 100644 --- a/src/main/java/de/hysky/skyblocker/skyblock/item/tooltip/adders/SupercraftReminder.java +++ b/src/main/java/de/hysky/skyblocker/skyblock/item/tooltip/adders/SupercraftReminder.java @@ -21,10 +21,10 @@ public class SupercraftReminder extends TooltipAdder { @Override public void addToTooltip(List lines, Slot focusedSlot) { if (focusedSlot.id != SUPERCRAFT_SLOT || !focusedSlot.getStack().isOf(Items.GOLDEN_PICKAXE)) return; - String UUID = ItemUtils.getItemUuid(focusedSlot.inventory.getStack(RECIPE_RESULT_SLOT)); - if (!UUID.isEmpty()) return; //Items with UUID can't be stacked, and therefore the shift-click feature doesn't matter - int index = lines.size()-1; - if (lines.get(lines.size()-2).getString().equals("Recipe not unlocked!")) index--; //Place it right below the "Right-Click to set amount" line + String uuid = ItemUtils.getItemUuid(focusedSlot.inventory.getStack(RECIPE_RESULT_SLOT)); + if (!uuid.isEmpty()) return; //Items with UUID can't be stacked, and therefore the shift-click feature doesn't matter + int index = lines.size() - 1; + if (lines.get(lines.size() - 2).getString().equals("Recipe not unlocked!")) index--; //Place it right below the "Right-Click to set amount" line lines.add(index, Text.literal("Shift-Click to maximize the amount!").formatted(Formatting.GOLD)); } } -- cgit