mirror of
https://github.com/Ellpeck/ActuallyAdditions.git
synced 2024-11-26 00:38:35 +01:00
Fixes #1055
This commit is contained in:
parent
b0efb95e4d
commit
88daf6683d
2 changed files with 35 additions and 25 deletions
|
@ -37,6 +37,7 @@ import de.ellpeck.actuallyadditions.mod.recipe.TreasureChestHandler;
|
|||
import de.ellpeck.actuallyadditions.mod.tile.TileEntityBase;
|
||||
import de.ellpeck.actuallyadditions.mod.update.UpdateChecker;
|
||||
import de.ellpeck.actuallyadditions.mod.util.ModUtil;
|
||||
import de.ellpeck.actuallyadditions.mod.util.compat.CompatUtil;
|
||||
import net.minecraft.server.MinecraftServer;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.MinecraftForge;
|
||||
|
@ -77,7 +78,7 @@ public class ActuallyAdditions{
|
|||
ActuallyAdditionsAPI.connectionHandler = new LaserRelayConnectionHandler();
|
||||
Lenses.init();
|
||||
InitBooklet.preInit();
|
||||
|
||||
CompatUtil.registerCraftingTweaks();
|
||||
commonCapsLoaded = Loader.isModLoaded("commoncapabilities");
|
||||
|
||||
MinecraftForge.EVENT_BUS.register(new RegistryHandler());
|
||||
|
|
|
@ -13,9 +13,11 @@ package de.ellpeck.actuallyadditions.mod.util.compat;
|
|||
import net.minecraft.client.gui.inventory.GuiCrafting;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.inventory.ContainerWorkbench;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.fml.common.Loader;
|
||||
import net.minecraftforge.fml.common.event.FMLInterModComms;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
|
||||
|
@ -37,4 +39,11 @@ public final class CompatUtil {
|
|||
}
|
||||
};
|
||||
}
|
||||
|
||||
public static void registerCraftingTweaks() {
|
||||
NBTTagCompound t = new NBTTagCompound();
|
||||
if (fb) t.setString("ContainerClass", "de.ellpeck.actuallyadditions.mod.util.compat.CompatFastBench$1");
|
||||
else t.setString("ContainerClass", "de.ellpeck.actuallyadditions.mod.util.compat.CompatUtil$1");
|
||||
FMLInterModComms.sendMessage("craftingtweaks", "RegisterProvider", t);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue