2018-10-19 14:35:25 +02:00
|
|
|
package de.ellpeck.naturesaura.compat;
|
|
|
|
|
2018-11-11 16:50:51 +01:00
|
|
|
import de.ellpeck.naturesaura.compat.crafttweaker.CraftTweakerCompat;
|
2019-03-01 18:27:24 +01:00
|
|
|
import de.ellpeck.naturesaura.compat.patchouli.PatchouliCompat;
|
2018-10-19 14:35:25 +02:00
|
|
|
import net.minecraftforge.common.MinecraftForge;
|
|
|
|
import net.minecraftforge.fml.common.Loader;
|
|
|
|
|
|
|
|
public final class Compat {
|
|
|
|
|
2019-03-31 10:21:59 +02:00
|
|
|
public static final String CRAFT_TWEAKER = "crafttweaker";
|
2018-10-19 14:35:25 +02:00
|
|
|
public static boolean baubles;
|
2018-11-11 16:50:51 +01:00
|
|
|
public static boolean craftTweaker;
|
2018-11-11 17:00:47 +01:00
|
|
|
public static boolean mtLib;
|
2018-10-19 14:35:25 +02:00
|
|
|
|
2018-11-11 16:50:51 +01:00
|
|
|
public static void preInit() {
|
2018-10-19 14:35:25 +02:00
|
|
|
baubles = Loader.isModLoaded("baubles");
|
2019-03-31 10:21:59 +02:00
|
|
|
craftTweaker = Loader.isModLoaded(CRAFT_TWEAKER);
|
2018-11-11 17:00:47 +01:00
|
|
|
mtLib = Loader.isModLoaded("mtlib");
|
2018-11-11 16:50:51 +01:00
|
|
|
|
|
|
|
if (baubles)
|
2018-10-19 14:35:25 +02:00
|
|
|
MinecraftForge.EVENT_BUS.register(new BaublesCompat());
|
2019-01-26 00:34:05 +01:00
|
|
|
|
2019-03-01 18:27:24 +01:00
|
|
|
PatchouliCompat.preInit();
|
|
|
|
}
|
|
|
|
|
2019-03-03 23:33:38 +01:00
|
|
|
public static void preInitClient() {
|
|
|
|
PatchouliCompat.preInitClient();
|
|
|
|
}
|
|
|
|
|
2018-11-11 16:50:51 +01:00
|
|
|
public static void postInit() {
|
2018-11-11 17:00:47 +01:00
|
|
|
if (craftTweaker && mtLib)
|
2018-11-11 16:50:51 +01:00
|
|
|
CraftTweakerCompat.postInit();
|
2018-10-26 12:03:42 +02:00
|
|
|
}
|
2018-10-19 14:35:25 +02:00
|
|
|
}
|