mirror of
https://github.com/GTNewHorizons/TinkersConstruct.git
synced 2026-11-19 03:49:29 +00:00
restore NEI integration
This commit is contained in:
1 parent
12c4a94823
commit
7528d0819e
12 files changed
+36
-71
No files matched your search
@@ -0,0 +1,41 @@
|
||||
package tconstruct.plugins.nei;
|
||||
|
||||
import codechicken.nei.api.API;
|
||||
import codechicken.nei.recipe.DefaultOverlayHandler;
|
||||
import cpw.mods.fml.common.FMLCommonHandler;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import mantle.module.ILoadableModule;
|
||||
import tconstruct.TConstruct;
|
||||
import tconstruct.client.gui.CraftingStationGui;
|
||||
|
||||
public class NotEnoughItems implements ILoadableModule
|
||||
{
|
||||
@SuppressWarnings("unused")
|
||||
public static String modId = "NotEnoughItems";
|
||||
|
||||
@Override
|
||||
public void preInit() {
|
||||
// Nothing
|
||||
}
|
||||
|
||||
@Override
|
||||
public void init() {
|
||||
TConstruct.logger.info("NotEnoughItems detected. Registering TConstruct NEI plugin.");
|
||||
registerNEICompat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void postInit() {
|
||||
// Nothing
|
||||
}
|
||||
public static void registerNEICompat ()
|
||||
{
|
||||
if (FMLCommonHandler.instance().getEffectiveSide() == Side.CLIENT)
|
||||
{
|
||||
API.registerGuiOverlay(CraftingStationGui.class, "crafting");
|
||||
API.registerGuiOverlayHandler(CraftingStationGui.class, new DefaultOverlayHandler(), "crafting");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user