old-bugs

Minecraft: Better than Adventure! mod that brings back bugs from older versions
git clone git://memoryshards.xyz/old-bugs.git
Log | Files | Refs | README | LICENSE

commit 26c1ee24b2df008cc8c3d88aadf3cc4c1a1558f5
parent ed8fd787b1b89459e0f2f5461278ffd2cd6baa68
Author: Amb0s <ambos@disroot.org>
Date:   Wed, 24 Jan 2024 21:41:29 +0100

Fixed TOML category issue

Diffstat:
Msrc/main/java/ambos/oldbugs/OldBugs.java | 40++++++++++++++++++++--------------------
1 file changed, 20 insertions(+), 20 deletions(-)

diff --git a/src/main/java/ambos/oldbugs/OldBugs.java b/src/main/java/ambos/oldbugs/OldBugs.java @@ -1,16 +1,16 @@ package ambos.oldbugs; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + import net.fabricmc.api.ModInitializer; import turniplabs.halplibe.util.TomlConfigHandler; import turniplabs.halplibe.util.toml.Toml; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - public class OldBugs implements ModInitializer { public static final String MOD_ID = "oldbugs"; public static final Logger LOGGER = LoggerFactory.getLogger(MOD_ID); - public static final TomlConfigHandler TOML_CONFIG_HANDLER; + public static final TomlConfigHandler CONFIG; public static final boolean OLD_FIRE_SPREAD; public static final boolean BOAT_WATER_LIFT; public static final boolean LADDER_GAP; @@ -18,23 +18,23 @@ public class OldBugs implements ModInitializer { public static final boolean SOUTH_EAST_RULE_LIQUIDS; public static final int FIRE_TICK_RATE; static { - Toml configToml = new Toml(); - configToml.addCategory("Bugs"); - configToml.addEntry("old_fire_spread", true); - configToml.addEntry("boat_water_lift", true); - configToml.addEntry("ladder_gap", true); - configToml.addEntry("minecart_booster", true); - configToml.addEntry("south_east_rule_liquids", true); - configToml.addCategory("Settings"); - configToml.addEntry("fire_tick_rate", 10); + Toml toml = new Toml(); + toml.addCategory("Bugs"); + toml.addEntry("Bugs.old_fire_spread", "Restores fast and large fire spread", true); + toml.addEntry("Bugs.boat_water_lift", "Restores boat elevators", true); + toml.addEntry("Bugs.ladder_gap", "Restores ladders gaps", true); + toml.addEntry("Bugs.minecart_booster", "Restores minecart boosters", true); + toml.addEntry("Bugs.south_east_rule_liquids", "Restores south-west rule for water and lava", true); + toml.addCategory("Settings"); + toml.addEntry("Settings.fire_tick_rate", "Sets fire tick rate (requires 'old_fire_spread = true')", 10); - TOML_CONFIG_HANDLER = new TomlConfigHandler(MOD_ID, configToml); - OLD_FIRE_SPREAD = TOML_CONFIG_HANDLER.getBoolean("Bugs.old_fire_spread"); - BOAT_WATER_LIFT = TOML_CONFIG_HANDLER.getBoolean("Bugs.boat_water_lift"); - LADDER_GAP = TOML_CONFIG_HANDLER.getBoolean("Bugs.ladder_gap"); - MINECART_BOOSTER = TOML_CONFIG_HANDLER.getBoolean("Bugs.minecart_booster"); - SOUTH_EAST_RULE_LIQUIDS = TOML_CONFIG_HANDLER.getBoolean("Bugs.south_east_rule_liquids"); - FIRE_TICK_RATE = TOML_CONFIG_HANDLER.getInt("Settings.fire_tick_rate"); + CONFIG = new TomlConfigHandler(MOD_ID, toml); + OLD_FIRE_SPREAD = CONFIG.getBoolean("Bugs.old_fire_spread"); + BOAT_WATER_LIFT = CONFIG.getBoolean("Bugs.boat_water_lift"); + LADDER_GAP = CONFIG.getBoolean("Bugs.ladder_gap"); + MINECART_BOOSTER = CONFIG.getBoolean("Bugs.minecart_booster"); + SOUTH_EAST_RULE_LIQUIDS = CONFIG.getBoolean("Bugs.south_east_rule_liquids"); + FIRE_TICK_RATE = CONFIG.getInt("Settings.fire_tick_rate"); } @Override