diff options
author | HiZe <super@hize.be> | 2024-06-01 11:19:31 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-06-01 11:19:31 +0200 |
commit | 6e75bd6dc33b23507e952267015628ba542715b9 (patch) | |
tree | 2db59cecdac12d8b5b6f2cf46edfc4e7a812b113 /src/main/java/at/hannibal2/skyhanni/config/features | |
parent | a926a1ffe1edee456ede638c28e439fb3ae8958e (diff) | |
download | skyhanni-6e75bd6dc33b23507e952267015628ba542715b9.tar.gz skyhanni-6e75bd6dc33b23507e952267015628ba542715b9.tar.bz2 skyhanni-6e75bd6dc33b23507e952267015628ba542715b9.zip |
Improvement + Fix: Sound for special stray rabbit (#1913)
Co-authored-by: hannibal2 <24389977+hannibal00212@users.noreply.github.com>
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/config/features')
2 files changed, 46 insertions, 5 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/chocolatefactory/ChocolateFactoryConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/chocolatefactory/ChocolateFactoryConfig.java index f954015ac..50230a6ae 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/chocolatefactory/ChocolateFactoryConfig.java +++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/chocolatefactory/ChocolateFactoryConfig.java @@ -71,11 +71,6 @@ public class ChocolateFactoryConfig { public boolean useMiddleClick = true; @Expose - @ConfigOption(name = "Rabbit Warning", desc = "Warn when the rabbit that needs to be clicked appears.") - @ConfigEditorBoolean - public boolean rabbitWarning = true; - - @Expose @ConfigOption( name = "Rabbit Crush Threshold", desc = "How close should you be to your barn capacity before being warned about needing to upgrade it." @@ -186,6 +181,11 @@ public class ChocolateFactoryConfig { public boolean onlyHighlightRequirementNotMet = true; @Expose + @ConfigOption(name = "Rabbit Warning", desc = "") + @Accordion + public ChocolateFactoryRabbitWarningConfig rabbitWarning = new ChocolateFactoryRabbitWarningConfig(); + + @Expose @ConfigOption(name = "Chocolate Shop Price", desc = "") @Accordion public ChocolateShopPriceConfig chocolateShopPrice = new ChocolateShopPriceConfig(); diff --git a/src/main/java/at/hannibal2/skyhanni/config/features/inventory/chocolatefactory/ChocolateFactoryRabbitWarningConfig.java b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/chocolatefactory/ChocolateFactoryRabbitWarningConfig.java new file mode 100644 index 000000000..ef39d5f6c --- /dev/null +++ b/src/main/java/at/hannibal2/skyhanni/config/features/inventory/chocolatefactory/ChocolateFactoryRabbitWarningConfig.java @@ -0,0 +1,41 @@ +package at.hannibal2.skyhanni.config.features.inventory.chocolatefactory; + +import at.hannibal2.skyhanni.utils.OSUtils; +import com.google.gson.annotations.Expose; +import io.github.notenoughupdates.moulconfig.annotations.ConfigEditorBoolean; +import io.github.notenoughupdates.moulconfig.annotations.ConfigEditorButton; +import io.github.notenoughupdates.moulconfig.annotations.ConfigEditorSlider; +import io.github.notenoughupdates.moulconfig.annotations.ConfigEditorText; +import io.github.notenoughupdates.moulconfig.annotations.ConfigOption; +import io.github.notenoughupdates.moulconfig.observer.Property; + +public class ChocolateFactoryRabbitWarningConfig { + + @Expose + @ConfigOption(name = "Rabbit Warning", desc = "Warn when the rabbit that needs to be clicked appears.") + @ConfigEditorBoolean + public boolean rabbitWarning = true; + + @Expose + @ConfigOption(name = "Special Rabbit Warning", desc = "Warn when a special rabbit that needs to be clicked appears. (Rabbit The Fish and Golden Rabbits.") + @ConfigEditorBoolean + public boolean specialRabbitWarning = true; + + @Expose + @ConfigOption(name = "Warning Sound", desc = "The sound that play for a special rabbit.\n" + + "§eYou can use custom sounds, put it in the skyhanni/sounds folder in your resource pack.\n" + + "§eThen write skyhanni:yourfilename\n" + + "§cMust be a .ogg file") + @ConfigEditorText + public Property<String> specialRabbitSound = Property.of("note.pling"); + + @Expose + @ConfigOption(name = "Repeat Sound", desc = "How many times the sound should be repeated.") + @ConfigEditorSlider(minValue = 1, maxValue = 20, minStep = 1) + public int repeatSound = 20; + + @ConfigOption(name = "Sounds", desc = "Click to open the list of available sounds.") + @ConfigEditorButton(buttonText = "OPEN") + public Runnable sounds = () -> OSUtils.openBrowser("https://www.minecraftforum.net/forums/mapping-and-modding-java-edition/mapping-and-modding-tutorials/2213619-1-8-all-playsound-sound-arguments"); + +} |