From 72b8073da162930e1353b9254d7d97a39f0d5857 Mon Sep 17 00:00:00 2001 From: MerchantPug <81167232+MerchantPug@users.noreply.github.com> Date: Wed, 4 Dec 2024 09:29:31 +1100 Subject: [PATCH] Fix #118. --- .../farmersdelight/common/Configuration.java | 79 ++++++++++--------- 1 file changed, 40 insertions(+), 39 deletions(-) diff --git a/src/main/java/vectorwing/farmersdelight/common/Configuration.java b/src/main/java/vectorwing/farmersdelight/common/Configuration.java index a4e16a11..f97df92e 100644 --- a/src/main/java/vectorwing/farmersdelight/common/Configuration.java +++ b/src/main/java/vectorwing/farmersdelight/common/Configuration.java @@ -4,6 +4,7 @@ import io.github.fabricators_of_create.porting_lib.config.ModConfigSpec; import java.util.List; +import java.util.function.Supplier; public class Configuration { @@ -12,59 +13,59 @@ public class Configuration // COMMON public static final String CATEGORY_SETTINGS = "settings"; - public static ModConfigSpec.BooleanValue ENABLE_VANILLA_CROP_CRATES; - public static ModConfigSpec.BooleanValue FARMERS_BUY_FD_CROPS; - public static ModConfigSpec.BooleanValue WANDERING_TRADER_SELLS_FD_ITEMS; - public static ModConfigSpec.DoubleValue RICH_SOIL_BOOST_CHANCE; - public static ModConfigSpec.DoubleValue CUTTING_BOARD_FORTUNE_BONUS; - public static ModConfigSpec.BooleanValue ENABLE_ROPE_REELING; - public static ModConfigSpec.ConfigValue> CANVAS_SIGN_DARK_BACKGROUND_LIST; + public static Supplier ENABLE_VANILLA_CROP_CRATES; + public static Supplier FARMERS_BUY_FD_CROPS; + public static Supplier WANDERING_TRADER_SELLS_FD_ITEMS; + public static Supplier RICH_SOIL_BOOST_CHANCE; + public static Supplier CUTTING_BOARD_FORTUNE_BONUS; + public static Supplier ENABLE_ROPE_REELING; + public static Supplier> CANVAS_SIGN_DARK_BACKGROUND_LIST; public static final String CATEGORY_FARMING = "farming"; - public static ModConfigSpec.ConfigValue DEFAULT_TOMATO_VINE_ROPE; - public static ModConfigSpec.BooleanValue ENABLE_TOMATO_VINE_CLIMBING_TAGGED_ROPES; + public static Supplier DEFAULT_TOMATO_VINE_ROPE; + public static Supplier ENABLE_TOMATO_VINE_CLIMBING_TAGGED_ROPES; public static final String CATEGORY_RECIPE_BOOK = "recipe_book"; - public static ModConfigSpec.BooleanValue ENABLE_RECIPE_BOOK_COOKING_POT; + public static Supplier ENABLE_RECIPE_BOOK_COOKING_POT; public static final String CATEGORY_OVERRIDES = "overrides"; - public static ModConfigSpec.BooleanValue VANILLA_SOUP_EXTRA_EFFECTS; - public static ModConfigSpec.BooleanValue RABBIT_STEW_BUFF; - public static ModConfigSpec.BooleanValue DISPENSER_TOOLS_CUTTING_BOARD; + public static Supplier VANILLA_SOUP_EXTRA_EFFECTS; + public static Supplier RABBIT_STEW_BUFF; + public static Supplier DISPENSER_TOOLS_CUTTING_BOARD; public static final String CATEGORY_OVERRIDES_STACK_SIZE = "stack_size"; - public static ModConfigSpec.BooleanValue ENABLE_STACKABLE_SOUP_ITEMS; - public static ModConfigSpec.ConfigValue> SOUP_ITEM_LIST; + public static Supplier ENABLE_STACKABLE_SOUP_ITEMS; + public static Supplier> SOUP_ITEM_LIST; public static final String CATEGORY_WORLD = "world"; - public static ModConfigSpec.BooleanValue GENERATE_FD_CHEST_LOOT; - public static ModConfigSpec.BooleanValue GENERATE_VILLAGE_COMPOST_HEAPS; - public static ModConfigSpec.BooleanValue GENERATE_VILLAGE_FARM_FD_CROPS; - public static ModConfigSpec.BooleanValue GENERATE_WILD_CABBAGES; - public static ModConfigSpec.IntValue CHANCE_WILD_CABBAGES; - public static ModConfigSpec.BooleanValue GENERATE_WILD_BEETROOTS; - public static ModConfigSpec.IntValue CHANCE_WILD_BEETROOTS; - public static ModConfigSpec.BooleanValue GENERATE_WILD_POTATOES; - public static ModConfigSpec.IntValue CHANCE_WILD_POTATOES; - public static ModConfigSpec.BooleanValue GENERATE_WILD_ONIONS; - public static ModConfigSpec.IntValue CHANCE_WILD_ONIONS; - public static ModConfigSpec.BooleanValue GENERATE_WILD_CARROTS; - public static ModConfigSpec.IntValue CHANCE_WILD_CARROTS; - public static ModConfigSpec.BooleanValue GENERATE_WILD_TOMATOES; - public static ModConfigSpec.IntValue CHANCE_WILD_TOMATOES; - public static ModConfigSpec.BooleanValue GENERATE_WILD_RICE; - public static ModConfigSpec.IntValue CHANCE_WILD_RICE; - public static ModConfigSpec.BooleanValue GENERATE_BROWN_MUSHROOM_COLONIES; - public static ModConfigSpec.IntValue CHANCE_BROWN_MUSHROOM_COLONIES; - public static ModConfigSpec.BooleanValue GENERATE_RED_MUSHROOM_COLONIES; - public static ModConfigSpec.IntValue CHANCE_RED_MUSHROOM_COLONIES; + public static Supplier GENERATE_FD_CHEST_LOOT; + public static Supplier GENERATE_VILLAGE_COMPOST_HEAPS; + public static Supplier GENERATE_VILLAGE_FARM_FD_CROPS; + public static Supplier GENERATE_WILD_CABBAGES; + public static Supplier CHANCE_WILD_CABBAGES; + public static Supplier GENERATE_WILD_BEETROOTS; + public static Supplier CHANCE_WILD_BEETROOTS; + public static Supplier GENERATE_WILD_POTATOES; + public static Supplier CHANCE_WILD_POTATOES; + public static Supplier GENERATE_WILD_ONIONS; + public static Supplier CHANCE_WILD_ONIONS; + public static Supplier GENERATE_WILD_CARROTS; + public static Supplier CHANCE_WILD_CARROTS; + public static Supplier GENERATE_WILD_TOMATOES; + public static Supplier CHANCE_WILD_TOMATOES; + public static Supplier GENERATE_WILD_RICE; + public static Supplier CHANCE_WILD_RICE; + public static Supplier GENERATE_BROWN_MUSHROOM_COLONIES; + public static Supplier CHANCE_BROWN_MUSHROOM_COLONIES; + public static Supplier GENERATE_RED_MUSHROOM_COLONIES; + public static Supplier CHANCE_RED_MUSHROOM_COLONIES; // CLIENT public static final String CATEGORY_CLIENT = "client"; - public static ModConfigSpec.BooleanValue NOURISHED_HUNGER_OVERLAY; - public static ModConfigSpec.BooleanValue COMFORT_HEALTH_OVERLAY; - public static ModConfigSpec.BooleanValue FOOD_EFFECT_TOOLTIP; + public static Supplier NOURISHED_HUNGER_OVERLAY; + public static Supplier COMFORT_HEALTH_OVERLAY; + public static Supplier FOOD_EFFECT_TOOLTIP; static { ModConfigSpec.Builder COMMON_BUILDER = new ModConfigSpec.Builder();