diff options
author | Phoebe <77941535+catgirlseraid@users.noreply.github.com> | 2024-07-26 23:04:12 +1200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-07-26 13:04:12 +0200 |
commit | 3cbb6b8b640d0f78cb3c316de1af92a9a0d8fed4 (patch) | |
tree | 5af597ab89f3636ae9668ddd21ee7a8ed25bd561 /src/main/java/at/hannibal2/skyhanni/config/features | |
parent | 4558f7b79dbd6097747e4742e13dcbdec623612f (diff) | |
download | skyhanni-3cbb6b8b640d0f78cb3c316de1af92a9a0d8fed4.tar.gz skyhanni-3cbb6b8b640d0f78cb3c316de1af92a9a0d8fed4.tar.bz2 skyhanni-3cbb6b8b640d0f78cb3c316de1af92a9a0d8fed4.zip |
Feature: Item Pickup Log (#1937)
Co-authored-by: SeRaid <77941535+SeRaid743@users.noreply.github.com>
Co-authored-by: blahajenjoyer7 <171753706+blahajenjoyer7@users.noreply.github.com>
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/config/features')
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/config/features/inventory/InventoryConfig.java | 5 | ||||
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/config/features/inventory/ItemPickupLogConfig.java | 80 |
2 files changed, 85 insertions, 0 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/InventoryConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/InventoryConfig.java index 684e2bb79..a3f88fca6 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/InventoryConfig.java +++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/InventoryConfig.java @@ -59,6 +59,11 @@ public class InventoryConfig { public ChocolateFactoryConfig chocolateFactory = new ChocolateFactoryConfig(); @Expose + @ConfigOption(name = "Item Pickup Log", desc = "Logs all the picked up and dropped items") + @Accordion + public ItemPickupLogConfig itemPickupLogConfig = new ItemPickupLogConfig(); + + @Expose @Category(name = "Craftable Item List", desc = "") @Accordion public CraftableItemListConfig craftableItemList = new CraftableItemListConfig(); diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/ItemPickupLogConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/ItemPickupLogConfig.java new file mode 100644 index 000000000..24dc1dc11 --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/ItemPickupLogConfig.java @@ -0,0 +1,80 @@ +package at.hannibal2.skyhanni.config.features.inventory; + +import at.hannibal2.skyhanni.config.FeatureToggle; +import at.hannibal2.skyhanni.config.core.config.Position; +import at.hannibal2.skyhanni.features.inventory.ItemPickupLog; +import at.hannibal2.skyhanni.utils.RenderUtils; +import com.google.gson.annotations.Expose; +import io.github.notenoughupdates.moulconfig.annotations.ConfigEditorBoolean; +import io.github.notenoughupdates.moulconfig.annotations.ConfigEditorDraggableList; +import io.github.notenoughupdates.moulconfig.annotations.ConfigEditorDropdown; +import io.github.notenoughupdates.moulconfig.annotations.ConfigEditorSlider; +import io.github.notenoughupdates.moulconfig.annotations.ConfigLink; +import io.github.notenoughupdates.moulconfig.annotations.ConfigOption; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +public class ItemPickupLogConfig { + + @Expose + @ConfigOption(name = "Item Pickup Log", desc = "Show a log of what items you pick up/drop and their amounts.") + @ConfigEditorBoolean + @FeatureToggle + public boolean enabled = true; + + @Expose + @ConfigOption(name = "Compact Lines", desc = "Combine the §a+ §7and §c- §7lines into a single line.") + @ConfigEditorBoolean + public boolean compactLines = true; + + @Expose + @ConfigOption(name = "Compact Numbers", desc = "Compact the amounts added and removed.") + @ConfigEditorBoolean + public boolean shorten = false; + + @Expose + @ConfigOption(name = "Sacks", desc = "Show items added and removed from stacks.") + @ConfigEditorBoolean + public boolean sack = false; + + @Expose + @ConfigOption(name = "Coins", desc = "Show coins added and removed from purse.") + @ConfigEditorBoolean + public boolean coins = false; + + @Expose + @ConfigOption( + name = "Alignment", + desc = "How the item pickup log should be aligned. §d:3" + ) + @ConfigEditorDropdown + public RenderUtils.VerticalAlignment alignment = RenderUtils.VerticalAlignment.TOP; + + @Expose + @ConfigOption( + name = "Layout", + desc = "Drag text to change the layout. List will be rendered horizontally" + ) + @ConfigEditorDraggableList(requireNonEmpty = true) + public List<ItemPickupLog.DisplayLayout> displayLayout = new ArrayList<>(Arrays.asList( + ItemPickupLog.DisplayLayout.CHANGE_AMOUNT, + ItemPickupLog.DisplayLayout.ICON, + ItemPickupLog.DisplayLayout.ITEM_NAME + )); + + @Expose + @ConfigOption( + name = "Expire After", + desc = "How long items show for after being picked up or dropped, in seconds." + ) + @ConfigEditorSlider(minValue = 1, maxValue = 20, minStep = 1) + public int expireAfter = 10; + + @Expose + @ConfigLink(owner = ItemPickupLogConfig.class, field = "enabled") + public Position pos = new Position(-256, 140, false, true); +} + + |