VanillaFixes.java (2002B)
1 package ambos.vanillafixes; 2 3 import net.fabricmc.api.ModInitializer; 4 import turniplabs.halplibe.util.TomlConfigHandler; 5 import turniplabs.halplibe.util.toml.Toml; 6 7 import org.slf4j.Logger; 8 import org.slf4j.LoggerFactory; 9 10 public class VanillaFixes implements ModInitializer { 11 public static final String MOD_ID = "vanillafixes"; 12 public static final Logger LOGGER = LoggerFactory.getLogger(MOD_ID); 13 14 public static final TomlConfigHandler CONFIG; 15 public static final boolean JITERRING; 16 public static final boolean FOG; 17 public static final boolean F3_MENU; 18 public static final boolean MOD_RESOURCES_PATH; 19 public static final boolean SIMPLE_MAIN_MENU; 20 public static final boolean IMPROVED_TOOLTIP; 21 static { 22 Toml toml = new Toml(); 23 toml.addCategory("Fixes"); 24 toml.addEntry("Fixes.jittering", "Fixes jitter at high coordinates", true); 25 toml.addEntry("Fixes.fog", "Properly disables fog and fix underwater rendering", true); 26 toml.addEntry("Fixes.mod_resources_path", "Changes mod resources path to '.minecraft/resources/mod'", true); 27 toml.addCategory("Settings"); 28 toml.addEntry("Settings.f3_menu", "Deobfuscates debug menu", true); 29 toml.addEntry("Settings.simple_main_menu", "Removes buttons, links and text on the main menu", true); 30 toml.addEntry("Settings.improved_tooltip", "Shows item durability and/or damage value in the tooltip", true); 31 32 CONFIG = new TomlConfigHandler(MOD_ID, toml); 33 JITERRING = CONFIG.getBoolean("Fixes.jittering"); 34 FOG = CONFIG.getBoolean("Fixes.fog"); 35 MOD_RESOURCES_PATH = CONFIG.getBoolean("Fixes.mod_resources_path"); 36 F3_MENU = CONFIG.getBoolean("Settings.f3_menu"); 37 SIMPLE_MAIN_MENU = CONFIG.getBoolean("Settings.simple_main_menu"); 38 IMPROVED_TOOLTIP = CONFIG.getBoolean("Settings.improved_tooltip"); 39 } 40 41 @Override 42 public void onInitialize() { 43 LOGGER.info("Vanilla Fixes initialized"); 44 } 45 }