Skip to content

Commit

Permalink
Changing a few things with IMC, NEI, removing buildcraft IMC
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexander Behrhof committed Aug 2, 2014
1 parent 050c427 commit 580f8b0
Show file tree
Hide file tree
Showing 5 changed files with 32 additions and 54 deletions.
2 changes: 0 additions & 2 deletions src/main/java/tconstruct/TConstruct.java
Expand Up @@ -21,7 +21,6 @@
import tconstruct.mechworks.TinkerMechworks;
import tconstruct.mechworks.landmine.behavior.Behavior;
import tconstruct.mechworks.landmine.behavior.stackCombo.SpecialStackHandler;
import tconstruct.plugins.imc.TinkerBuildcraft;
import tconstruct.plugins.imc.TinkerThaumcraft;
import tconstruct.plugins.nei.TinkerNEI;
import tconstruct.smeltery.TinkerSmeltery;
Expand Down Expand Up @@ -112,7 +111,6 @@ public void preInit (FMLPreInitializationEvent event)
pulsar.registerPulse(new TinkerArmor());
pulsar.registerPulse(new TinkerNEI());
pulsar.registerPulse(new TinkerThaumcraft());
pulsar.registerPulse(new TinkerBuildcraft());
/*pulsar.registerPulse(new TinkerPrayers());
pulsar.registerPulse(new TinkerCropify());*/

Expand Down
37 changes: 0 additions & 37 deletions src/main/java/tconstruct/plugins/imc/TinkerBuildcraft.java

This file was deleted.

7 changes: 4 additions & 3 deletions src/main/java/tconstruct/plugins/imc/TinkerThaumcraft.java
Expand Up @@ -12,11 +12,12 @@
import cpw.mods.fml.common.registry.GameRegistry.ObjectHolder;

@ObjectHolder(TConstruct.modID)
@Pulse(id = "Tinkers Thaumcraft addon", description = "The Thaumcraft addon for Tinkers.", modsRequired = "Thaumcraft", forced = true)
public class TinkerThaumcraft {
@Pulse(id = "Tinkers Thaumcraft Compatibility", description = "Tinkers Construct compatibility for Thaumcraft", modsRequired = "Thaumcraft")
public class TinkerThaumcraft
{

@Handler
public void init(FMLInitializationEvent event)
public void init (FMLInitializationEvent event)
{
TConstruct.logger.info("[Thaumcraft] Registering harvestables.");
FMLInterModComms.sendMessage("Thaumcraft", "harvestClickableCrop", new ItemStack(TinkerWorld.oreBerry, 1, 12));
Expand Down
21 changes: 21 additions & 0 deletions src/main/java/tconstruct/plugins/nei/NEICompat.java
@@ -0,0 +1,21 @@
package tconstruct.plugins.nei;

import tconstruct.tools.gui.CraftingStationGui;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.common.FMLCommonHandler;
import codechicken.nei.recipe.DefaultOverlayHandler;
import codechicken.nei.api.API;

public class NEICompat
{

public static void registerNEICompat ()
{
if (FMLCommonHandler.instance().getEffectiveSide() == Side.CLIENT)
{
API.registerGuiOverlay(CraftingStationGui.class, "crafting");
API.registerGuiOverlayHandler(CraftingStationGui.class, new DefaultOverlayHandler(), "crafting");
}
}

}
19 changes: 7 additions & 12 deletions src/main/java/tconstruct/plugins/nei/TinkerNEI.java
@@ -1,28 +1,23 @@
package tconstruct.plugins.nei;

import codechicken.nei.api.API;
import codechicken.nei.recipe.DefaultOverlayHandler;
import mantle.pulsar.pulse.Handler;
import mantle.pulsar.pulse.Pulse;
import tconstruct.TConstruct;
import tconstruct.tools.gui.CraftingStationGui;
import cpw.mods.fml.common.FMLCommonHandler;
import cpw.mods.fml.common.event.FMLInitializationEvent;
import cpw.mods.fml.common.registry.GameRegistry.ObjectHolder;
import cpw.mods.fml.relauncher.Side;

@ObjectHolder(TConstruct.modID)
@Pulse(id = "Tinkers Not Enough Items Addon", description = "The NEI addon for Tinkers.", modsRequired = "NotEnoughItems", forced = true)
public class TinkerNEI {

@Pulse(id = "Tinkers NEI Compatibility", description = "Tinkers Construct compatibility for NEI", modsRequired = "NotEnoughItems")
public class TinkerNEI
{

@Handler
public void init (FMLInitializationEvent event)
{
if (FMLCommonHandler.instance().getEffectiveSide() == Side.CLIENT)
{
API.registerGuiOverlay(CraftingStationGui.class, "crafting");
API.registerGuiOverlayHandler(CraftingStationGui.class, new DefaultOverlayHandler(), "crafting");
}
TConstruct.logger.info("NotEnoughItems detected. Registering TConstruct NEI plugin.");
NEICompat.registerNEICompat();
}

}

0 comments on commit 580f8b0

Please sign in to comment.