mirror of
https://github.com/GTNewHorizons/TinkersConstruct.git
synced 2026-11-21 20:52:26 +00:00
start of the 1.7 update commits
This commit is contained in:
1 parent
6f8ca82d98
commit
1bd860c52f
118 files changed
+403
-1837
No files matched your search
@@ -3,15 +3,11 @@ package tconstruct.plugins;
|
||||
import cpw.mods.fml.common.Loader;
|
||||
import net.minecraftforge.common.Configuration;
|
||||
import tconstruct.TConstruct;
|
||||
import tconstruct.plugins.fmp.ForgeMultiPart;
|
||||
import tconstruct.plugins.ic2.IC2;
|
||||
import tconstruct.plugins.imc.AppEng;
|
||||
import tconstruct.plugins.imc.BuildcraftTransport;
|
||||
import tconstruct.plugins.imc.Mystcraft;
|
||||
import tconstruct.plugins.imc.Thaumcraft;
|
||||
import tconstruct.plugins.minefactoryreloaded.MineFactoryReloaded;
|
||||
import tconstruct.plugins.nei.NotEnoughItems;
|
||||
import tconstruct.plugins.waila.Waila;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.*;
|
||||
@@ -112,12 +108,12 @@ public class PluginController
|
||||
|
||||
registerPlugin(new AppEng());
|
||||
registerPlugin(new BuildcraftTransport());
|
||||
registerPlugin(new ForgeMultiPart());
|
||||
//registerPlugin(new ForgeMultiPart());
|
||||
registerPlugin(new IC2());
|
||||
registerPlugin(new MineFactoryReloaded());
|
||||
registerPlugin(new NotEnoughItems());
|
||||
// registerPlugin(new MineFactoryReloaded());
|
||||
//registerPlugin(new NotEnoughItems());
|
||||
registerPlugin(new Thaumcraft());
|
||||
registerPlugin(new Waila());
|
||||
// registerPlugin(new Waila());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,585 +0,0 @@
|
||||
package tconstruct.plugins.fmp;
|
||||
|
||||
import codechicken.lib.lighting.*;
|
||||
import codechicken.lib.render.*;
|
||||
import codechicken.lib.vec.*;
|
||||
import codechicken.microblock.*;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.renderer.Tessellator;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import tconstruct.blocks.GlassBlockConnected;
|
||||
import tconstruct.util.config.PHConstruct;
|
||||
|
||||
public class ConnectedTexturesMicroMaterial extends BlockMicroMaterial
|
||||
{
|
||||
|
||||
public GlassBlockConnected b;
|
||||
|
||||
MultiIconTransformation icont = null;
|
||||
|
||||
public ConnectedTexturesMicroMaterial(GlassBlockConnected block, int meta)
|
||||
{
|
||||
super(block, meta);
|
||||
b = block;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void loadIcons ()
|
||||
{
|
||||
icont = new MultiIconTransformation(b.getIcons());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void renderMicroFace (Vertex5[] verts, int side, Vector3 pos, LightMatrix lightMatrix, IMicroMaterialRender part)
|
||||
{
|
||||
renderMicroFace(verts, side, pos, lightMatrix, getColour(part), icont);
|
||||
}
|
||||
|
||||
public int determineTextre (IBlockAccess par1IBlockAccess, int par2, int par3, int par4, int par5)
|
||||
{
|
||||
if (PHConstruct.connectedTexturesMode == 0)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
boolean isOpenUp = false, isOpenDown = false, isOpenLeft = false, isOpenRight = false;
|
||||
|
||||
switch (par5)
|
||||
{
|
||||
case 0:
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2 - 1, par3, par4), par1IBlockAccess.getBlockMetadata(par2 - 1, par3, par4)))
|
||||
{
|
||||
isOpenDown = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2 + 1, par3, par4), par1IBlockAccess.getBlockMetadata(par2 + 1, par3, par4)))
|
||||
{
|
||||
isOpenUp = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2, par3, par4 - 1), par1IBlockAccess.getBlockMetadata(par2, par3, par4 - 1)))
|
||||
{
|
||||
isOpenLeft = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2, par3, par4 + 1), par1IBlockAccess.getBlockMetadata(par2, par3, par4 + 1)))
|
||||
{
|
||||
isOpenRight = true;
|
||||
}
|
||||
|
||||
if (isOpenUp && isOpenDown && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 15;
|
||||
}
|
||||
else if (isOpenUp && isOpenDown && isOpenLeft)
|
||||
{
|
||||
return 11;
|
||||
}
|
||||
else if (isOpenUp && isOpenDown && isOpenRight)
|
||||
{
|
||||
return 12;
|
||||
}
|
||||
else if (isOpenUp && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 13;
|
||||
}
|
||||
else if (isOpenDown && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 14;
|
||||
}
|
||||
else if (isOpenDown && isOpenUp)
|
||||
{
|
||||
return 5;
|
||||
}
|
||||
else if (isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 6;
|
||||
}
|
||||
else if (isOpenDown && isOpenLeft)
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
else if (isOpenDown && isOpenRight)
|
||||
{
|
||||
return 10;
|
||||
}
|
||||
else if (isOpenUp && isOpenLeft)
|
||||
{
|
||||
return 7;
|
||||
}
|
||||
else if (isOpenUp && isOpenRight)
|
||||
{
|
||||
return 9;
|
||||
}
|
||||
else if (isOpenDown)
|
||||
{
|
||||
return 3;
|
||||
}
|
||||
else if (isOpenUp)
|
||||
{
|
||||
return 4;
|
||||
}
|
||||
else if (isOpenLeft)
|
||||
{
|
||||
return 2;
|
||||
}
|
||||
else if (isOpenRight)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
break;
|
||||
case 1:
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2 - 1, par3, par4), par1IBlockAccess.getBlockMetadata(par2 - 1, par3, par4)))
|
||||
{
|
||||
isOpenDown = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2 + 1, par3, par4), par1IBlockAccess.getBlockMetadata(par2 + 1, par3, par4)))
|
||||
{
|
||||
isOpenUp = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2, par3, par4 - 1), par1IBlockAccess.getBlockMetadata(par2, par3, par4 - 1)))
|
||||
{
|
||||
isOpenLeft = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2, par3, par4 + 1), par1IBlockAccess.getBlockMetadata(par2, par3, par4 + 1)))
|
||||
{
|
||||
isOpenRight = true;
|
||||
}
|
||||
|
||||
if (isOpenUp && isOpenDown && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 15;
|
||||
}
|
||||
else if (isOpenUp && isOpenDown && isOpenLeft)
|
||||
{
|
||||
return 11;
|
||||
}
|
||||
else if (isOpenUp && isOpenDown && isOpenRight)
|
||||
{
|
||||
return 12;
|
||||
}
|
||||
else if (isOpenUp && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 13;
|
||||
}
|
||||
else if (isOpenDown && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 14;
|
||||
}
|
||||
else if (isOpenDown && isOpenUp)
|
||||
{
|
||||
return 5;
|
||||
}
|
||||
else if (isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 6;
|
||||
}
|
||||
else if (isOpenDown && isOpenLeft)
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
else if (isOpenDown && isOpenRight)
|
||||
{
|
||||
return 10;
|
||||
}
|
||||
else if (isOpenUp && isOpenLeft)
|
||||
{
|
||||
return 7;
|
||||
}
|
||||
else if (isOpenUp && isOpenRight)
|
||||
{
|
||||
return 9;
|
||||
}
|
||||
else if (isOpenDown)
|
||||
{
|
||||
return 3;
|
||||
}
|
||||
else if (isOpenUp)
|
||||
{
|
||||
return 4;
|
||||
}
|
||||
else if (isOpenLeft)
|
||||
{
|
||||
return 2;
|
||||
}
|
||||
else if (isOpenRight)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2, par3 - 1, par4), par1IBlockAccess.getBlockMetadata(par2, par3 - 1, par4)))
|
||||
{
|
||||
isOpenDown = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2, par3 + 1, par4), par1IBlockAccess.getBlockMetadata(par2, par3 + 1, par4)))
|
||||
{
|
||||
isOpenUp = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2 - 1, par3, par4), par1IBlockAccess.getBlockMetadata(par2 - 1, par3, par4)))
|
||||
{
|
||||
isOpenLeft = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2 + 1, par3, par4), par1IBlockAccess.getBlockMetadata(par2 + 1, par3, par4)))
|
||||
{
|
||||
isOpenRight = true;
|
||||
}
|
||||
|
||||
if (isOpenUp && isOpenDown && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 15;
|
||||
}
|
||||
else if (isOpenUp && isOpenDown && isOpenLeft)
|
||||
{
|
||||
return 13;
|
||||
}
|
||||
else if (isOpenUp && isOpenDown && isOpenRight)
|
||||
{
|
||||
return 14;
|
||||
}
|
||||
else if (isOpenUp && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 11;
|
||||
}
|
||||
else if (isOpenDown && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 12;
|
||||
}
|
||||
else if (isOpenDown && isOpenUp)
|
||||
{
|
||||
return 6;
|
||||
}
|
||||
else if (isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 5;
|
||||
}
|
||||
else if (isOpenDown && isOpenLeft)
|
||||
{
|
||||
return 9;
|
||||
}
|
||||
else if (isOpenDown && isOpenRight)
|
||||
{
|
||||
return 10;
|
||||
}
|
||||
else if (isOpenUp && isOpenLeft)
|
||||
{
|
||||
return 7;
|
||||
}
|
||||
else if (isOpenUp && isOpenRight)
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
else if (isOpenDown)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
else if (isOpenUp)
|
||||
{
|
||||
return 2;
|
||||
}
|
||||
else if (isOpenLeft)
|
||||
{
|
||||
return 4;
|
||||
}
|
||||
else if (isOpenRight)
|
||||
{
|
||||
return 3;
|
||||
}
|
||||
break;
|
||||
case 3:
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2, par3 - 1, par4), par1IBlockAccess.getBlockMetadata(par2, par3 - 1, par4)))
|
||||
{
|
||||
isOpenDown = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2, par3 + 1, par4), par1IBlockAccess.getBlockMetadata(par2, par3 + 1, par4)))
|
||||
{
|
||||
isOpenUp = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2 - 1, par3, par4), par1IBlockAccess.getBlockMetadata(par2 - 1, par3, par4)))
|
||||
{
|
||||
isOpenLeft = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2 + 1, par3, par4), par1IBlockAccess.getBlockMetadata(par2 + 1, par3, par4)))
|
||||
{
|
||||
isOpenRight = true;
|
||||
}
|
||||
|
||||
if (isOpenUp && isOpenDown && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 15;
|
||||
}
|
||||
else if (isOpenUp && isOpenDown && isOpenLeft)
|
||||
{
|
||||
return 14;
|
||||
}
|
||||
else if (isOpenUp && isOpenDown && isOpenRight)
|
||||
{
|
||||
return 13;
|
||||
}
|
||||
else if (isOpenUp && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 11;
|
||||
}
|
||||
else if (isOpenDown && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 12;
|
||||
}
|
||||
else if (isOpenDown && isOpenUp)
|
||||
{
|
||||
return 6;
|
||||
}
|
||||
else if (isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 5;
|
||||
}
|
||||
else if (isOpenDown && isOpenLeft)
|
||||
{
|
||||
return 10;
|
||||
}
|
||||
else if (isOpenDown && isOpenRight)
|
||||
{
|
||||
return 9;
|
||||
}
|
||||
else if (isOpenUp && isOpenLeft)
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
else if (isOpenUp && isOpenRight)
|
||||
{
|
||||
return 7;
|
||||
}
|
||||
else if (isOpenDown)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
else if (isOpenUp)
|
||||
{
|
||||
return 2;
|
||||
}
|
||||
else if (isOpenLeft)
|
||||
{
|
||||
return 3;
|
||||
}
|
||||
else if (isOpenRight)
|
||||
{
|
||||
return 4;
|
||||
}
|
||||
break;
|
||||
case 4:
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2, par3 - 1, par4), par1IBlockAccess.getBlockMetadata(par2, par3 - 1, par4)))
|
||||
{
|
||||
isOpenDown = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2, par3 + 1, par4), par1IBlockAccess.getBlockMetadata(par2, par3 + 1, par4)))
|
||||
{
|
||||
isOpenUp = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2, par3, par4 - 1), par1IBlockAccess.getBlockMetadata(par2, par3, par4 - 1)))
|
||||
{
|
||||
isOpenLeft = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2, par3, par4 + 1), par1IBlockAccess.getBlockMetadata(par2, par3, par4 + 1)))
|
||||
{
|
||||
isOpenRight = true;
|
||||
}
|
||||
|
||||
if (isOpenUp && isOpenDown && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 15;
|
||||
}
|
||||
else if (isOpenUp && isOpenDown && isOpenLeft)
|
||||
{
|
||||
return 14;
|
||||
}
|
||||
else if (isOpenUp && isOpenDown && isOpenRight)
|
||||
{
|
||||
return 13;
|
||||
}
|
||||
else if (isOpenUp && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 11;
|
||||
}
|
||||
else if (isOpenDown && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 12;
|
||||
}
|
||||
else if (isOpenDown && isOpenUp)
|
||||
{
|
||||
return 6;
|
||||
}
|
||||
else if (isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 5;
|
||||
}
|
||||
else if (isOpenDown && isOpenLeft)
|
||||
{
|
||||
return 10;
|
||||
}
|
||||
else if (isOpenDown && isOpenRight)
|
||||
{
|
||||
return 9;
|
||||
}
|
||||
else if (isOpenUp && isOpenLeft)
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
else if (isOpenUp && isOpenRight)
|
||||
{
|
||||
return 7;
|
||||
}
|
||||
else if (isOpenDown)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
else if (isOpenUp)
|
||||
{
|
||||
return 2;
|
||||
}
|
||||
else if (isOpenLeft)
|
||||
{
|
||||
return 3;
|
||||
}
|
||||
else if (isOpenRight)
|
||||
{
|
||||
return 4;
|
||||
}
|
||||
break;
|
||||
case 5:
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2, par3 - 1, par4), par1IBlockAccess.getBlockMetadata(par2, par3 - 1, par4)))
|
||||
{
|
||||
isOpenDown = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2, par3 + 1, par4), par1IBlockAccess.getBlockMetadata(par2, par3 + 1, par4)))
|
||||
{
|
||||
isOpenUp = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2, par3, par4 - 1), par1IBlockAccess.getBlockMetadata(par2, par3, par4 - 1)))
|
||||
{
|
||||
isOpenLeft = true;
|
||||
}
|
||||
|
||||
if (b.shouldConnectToBlock(par1IBlockAccess, par2, par3, par4, par1IBlockAccess.getBlockId(par2, par3, par4 + 1), par1IBlockAccess.getBlockMetadata(par2, par3, par4 + 1)))
|
||||
{
|
||||
isOpenRight = true;
|
||||
}
|
||||
|
||||
if (isOpenUp && isOpenDown && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 15;
|
||||
}
|
||||
else if (isOpenUp && isOpenDown && isOpenLeft)
|
||||
{
|
||||
return 13;
|
||||
}
|
||||
else if (isOpenUp && isOpenDown && isOpenRight)
|
||||
{
|
||||
return 14;
|
||||
}
|
||||
else if (isOpenUp && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 11;
|
||||
}
|
||||
else if (isOpenDown && isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 12;
|
||||
}
|
||||
else if (isOpenDown && isOpenUp)
|
||||
{
|
||||
return 6;
|
||||
}
|
||||
else if (isOpenLeft && isOpenRight)
|
||||
{
|
||||
return 5;
|
||||
}
|
||||
else if (isOpenDown && isOpenLeft)
|
||||
{
|
||||
return 9;
|
||||
}
|
||||
else if (isOpenDown && isOpenRight)
|
||||
{
|
||||
return 10;
|
||||
}
|
||||
else if (isOpenUp && isOpenLeft)
|
||||
{
|
||||
return 7;
|
||||
}
|
||||
else if (isOpenUp && isOpenRight)
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
else if (isOpenDown)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
else if (isOpenUp)
|
||||
{
|
||||
return 2;
|
||||
}
|
||||
else if (isOpenLeft)
|
||||
{
|
||||
return 4;
|
||||
}
|
||||
else if (isOpenRight)
|
||||
{
|
||||
return 3;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public void renderMicroFace (Vertex5[] verts, int side, Vector3 pos, LightMatrix lightMatrix, int colour, IUVTransformation uvt)
|
||||
{
|
||||
UV uv = new UV();
|
||||
Tessellator t = Tessellator.instance;
|
||||
int i = 0;
|
||||
while (i < 4)
|
||||
{
|
||||
if (CCRenderState.useNormals())
|
||||
{
|
||||
Vector3 n = Rotation.axes[side % 6];
|
||||
t.setNormal((float) n.x, (float) n.y, (float) n.z);
|
||||
}
|
||||
Vertex5 vert = verts[i];
|
||||
if (lightMatrix != null)
|
||||
{
|
||||
LC lc = LC.computeO(vert.vec, side);
|
||||
if (CCRenderState.useModelColours())
|
||||
lightMatrix.setColour(t, lc, colour);
|
||||
lightMatrix.setBrightness(t, lc);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (CCRenderState.useModelColours())
|
||||
CCRenderState.vertexColour(colour);
|
||||
}
|
||||
|
||||
// ((MultiIconTransformation)uvt).setIconIndex(null, determineTextre(Minecraft.getMinecraft().theWorld, (int)pos.x, (int)pos.y, (int)pos.z, side));
|
||||
|
||||
uvt.transform(uv.set(vert.uv));
|
||||
t.addVertexWithUV(vert.vec.x + pos.x, vert.vec.y + pos.y, vert.vec.z + pos.z, uv.u, uv.v);
|
||||
i += 1;
|
||||
}
|
||||
}
|
||||
|
||||
public static void createAndRegister (GlassBlockConnected block)
|
||||
{
|
||||
MicroMaterialRegistry.registerMaterial(new ConnectedTexturesMicroMaterial(block, 0), block.getUnlocalizedName());
|
||||
}
|
||||
}
|
||||
@@ -1,37 +0,0 @@
|
||||
package tconstruct.plugins.fmp;
|
||||
|
||||
import tconstruct.TConstruct;
|
||||
import tconstruct.common.TRepo;
|
||||
import tconstruct.plugins.ICompatPlugin;
|
||||
|
||||
public class ForgeMultiPart implements ICompatPlugin
|
||||
{
|
||||
@Override
|
||||
public String getModId() {
|
||||
return "ForgeMultipart";
|
||||
}
|
||||
|
||||
@Override
|
||||
public void preInit() {
|
||||
// Nothing
|
||||
}
|
||||
|
||||
@Override
|
||||
public void init()
|
||||
{
|
||||
TConstruct.logger.info("ForgeMultipart detected. Registering TConstruct decorative blocks with FMP.");
|
||||
RegisterWithFMP.registerBlock(TRepo.clearGlass);
|
||||
RegisterWithFMP.registerBlock(TRepo.stainedGlassClear, 0, 15);
|
||||
RegisterWithFMP.registerBlock(TRepo.multiBrick, 0, 13);
|
||||
RegisterWithFMP.registerBlock(TRepo.metalBlock, 0, 10);
|
||||
RegisterWithFMP.registerBlock(TRepo.multiBrickFancy, 0, 15);
|
||||
RegisterWithFMP.registerBlock(TRepo.smeltery, 2, 2);
|
||||
RegisterWithFMP.registerBlock(TRepo.smeltery, 4, 10);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void postInit() {
|
||||
// Nothing
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,42 +0,0 @@
|
||||
package tconstruct.plugins.fmp;
|
||||
|
||||
import codechicken.microblock.MicroMaterialRegistry.IMicroMaterial;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import codechicken.microblock.BlockMicroMaterial;
|
||||
import codechicken.microblock.MicroMaterialRegistry;
|
||||
|
||||
public class RegisterWithFMP
|
||||
{
|
||||
//For blocks with metadata values only
|
||||
public static void registerBlock (Block block, int metastart, int metaend)
|
||||
{
|
||||
for (int meta = metastart; meta <= metaend; meta++)
|
||||
{
|
||||
String identifier = new String(block.getUnlocalizedName());
|
||||
MicroMaterialRegistry.registerMaterial(new BlockMicroMaterial(block, meta), identifier + meta);
|
||||
}
|
||||
}
|
||||
|
||||
//For blocks without metadata values only.
|
||||
public static void registerBlock (Block block)
|
||||
{
|
||||
BlockMicroMaterial.createAndRegister(block);
|
||||
}
|
||||
|
||||
//For blocks with metadata values and special MicroMaterial only
|
||||
public static void registerBlock (Block block, int metastart, int metaend, IMicroMaterial material)
|
||||
{
|
||||
for (int meta = metastart; meta <= metaend; meta++)
|
||||
{
|
||||
String identifier = new String(block.getUnlocalizedName());
|
||||
MicroMaterialRegistry.registerMaterial(material, identifier + meta);
|
||||
}
|
||||
}
|
||||
|
||||
//For blocks without metadata values and special MicroMaterial only.
|
||||
public static void registerBlock (Block block, IMicroMaterial material)
|
||||
{
|
||||
MicroMaterialRegistry.registerMaterial(material, new String(block.getUnlocalizedName()));
|
||||
}
|
||||
}
|
||||
@@ -1,27 +0,0 @@
|
||||
package tconstruct.plugins.minefactoryreloaded;
|
||||
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.potion.Potion;
|
||||
import net.minecraft.potion.PotionEffect;
|
||||
import powercrystals.minefactoryreloaded.api.ILiquidDrinkHandler;
|
||||
|
||||
public class Drinkables implements ILiquidDrinkHandler
|
||||
{
|
||||
|
||||
@Override
|
||||
public void onDrink (EntityPlayer player)
|
||||
{
|
||||
//boost health when drink
|
||||
if (player != null)
|
||||
{
|
||||
PotionEffect potion = player.getActivePotionEffect(Potion.field_76434_w);
|
||||
int duration = 0;
|
||||
if (potion != null)
|
||||
duration = potion.duration;
|
||||
player.addPotionEffect(new PotionEffect(Potion.field_76434_w.id, duration + 20 * 30, 0));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,38 +0,0 @@
|
||||
package tconstruct.plugins.minefactoryreloaded;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.passive.EntityHorse;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
import powercrystals.minefactoryreloaded.api.IFactoryGrindable;
|
||||
import powercrystals.minefactoryreloaded.api.MobDrop;
|
||||
import tconstruct.common.TRepo;
|
||||
|
||||
public class GrindableHorse implements IFactoryGrindable
|
||||
{
|
||||
@Override
|
||||
public Class<?> getGrindableEntity ()
|
||||
{
|
||||
return EntityHorse.class;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<MobDrop> grind (World world, EntityLivingBase entity, Random random)
|
||||
{
|
||||
List<MobDrop> drops = new ArrayList<MobDrop>();
|
||||
|
||||
drops.add(new MobDrop(10, new ItemStack(TRepo.materials, random.nextInt(4) + 1, 36)));
|
||||
|
||||
return drops;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean processEntity (EntityLivingBase entity)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@@ -1,67 +0,0 @@
|
||||
package tconstruct.plugins.minefactoryreloaded;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
import powercrystals.minefactoryreloaded.api.HarvestType;
|
||||
import powercrystals.minefactoryreloaded.api.IFactoryHarvestable;
|
||||
|
||||
public class HarvestableOreBerry implements IFactoryHarvestable
|
||||
{
|
||||
private int _sourceBlockId;
|
||||
private int _berryItemId;
|
||||
private int _metaOffset;
|
||||
|
||||
public HarvestableOreBerry(int sourceBlockId, int berryItemId, int metaOffset)
|
||||
{
|
||||
_sourceBlockId = sourceBlockId;
|
||||
_berryItemId = berryItemId;
|
||||
_metaOffset = metaOffset;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getPlantId ()
|
||||
{
|
||||
return _sourceBlockId;
|
||||
}
|
||||
|
||||
@Override
|
||||
public HarvestType getHarvestType ()
|
||||
{
|
||||
return HarvestType.Column;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean breakBlock ()
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canBeHarvested (World world, Map<String, Boolean> harvesterSettings, int x, int y, int z)
|
||||
{
|
||||
return world.getBlockMetadata(x, y, z) >= 12;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<ItemStack> getDrops (World world, Random rand, Map<String, Boolean> harvesterSettings, int x, int y, int z)
|
||||
{
|
||||
ItemStack[] returnItems = { new ItemStack(_berryItemId, 1, world.getBlockMetadata(x, y, z) % 4 + _metaOffset) };
|
||||
return Arrays.asList(returnItems);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void preHarvest (World world, int x, int y, int z)
|
||||
{
|
||||
}
|
||||
|
||||
@Override
|
||||
public void postHarvest (World world, int x, int y, int z)
|
||||
{
|
||||
world.setBlockMetadataWithNotify(x, y, z, world.getBlockMetadata(x, y, z) - 4, 2);
|
||||
}
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
package tconstruct.plugins.minefactoryreloaded;
|
||||
|
||||
import powercrystals.minefactoryreloaded.api.FactoryRegistry;
|
||||
import tconstruct.common.TRepo;
|
||||
|
||||
public class MFRRegister
|
||||
{
|
||||
public static void registerWithMFR ()
|
||||
{
|
||||
FactoryRegistry.registerHarvestable(new HarvestableOreBerry(TRepo.oreBerry.blockID, TRepo.oreBerries.itemID, 0));
|
||||
FactoryRegistry.registerHarvestable(new HarvestableOreBerry(TRepo.oreBerrySecond.blockID, TRepo.oreBerries.itemID, 4));
|
||||
FactoryRegistry.registerGrindable(new GrindableHorse());
|
||||
FactoryRegistry.registerLiquidDrinkHandler(TRepo.bloodFluid.getName(), new Drinkables());
|
||||
}
|
||||
}
|
||||
@@ -1,35 +0,0 @@
|
||||
package tconstruct.plugins.minefactoryreloaded;
|
||||
|
||||
import tconstruct.TConstruct;
|
||||
import tconstruct.plugins.ICompatPlugin;
|
||||
|
||||
public class MineFactoryReloaded implements ICompatPlugin
|
||||
{
|
||||
@Override
|
||||
public String getModId() {
|
||||
return "MineFactoryReloaded";
|
||||
}
|
||||
|
||||
@Override
|
||||
public void preInit() {
|
||||
// Nothing
|
||||
}
|
||||
|
||||
@Override
|
||||
public void init()
|
||||
{
|
||||
TConstruct.logger.info("MineFactoryReloaded detected. Registering TConstruct farmables/grindables with MFR's Farming Registry.");
|
||||
MFRRegister.registerWithMFR();
|
||||
/*
|
||||
* Perhaps TC ores should be registered as drops from the MFR Laser Drill here, but I don't know which things would be suitable for that.
|
||||
* Syntax: FarmingRegistry.registerLaserOre(int weight, ItemStack droppedStack));
|
||||
* Currently used weights are from about 50 (emerald) to 175 (coal).
|
||||
*/
|
||||
}
|
||||
|
||||
@Override
|
||||
public void postInit() {
|
||||
// Nothing
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,21 +0,0 @@
|
||||
package tconstruct.plugins.nei;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.common.FMLCommonHandler;
|
||||
import codechicken.nei.recipe.DefaultOverlayHandler;
|
||||
import codechicken.nei.api.API;
|
||||
import tconstruct.client.gui.CraftingStationGui;
|
||||
|
||||
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");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,29 +0,0 @@
|
||||
package tconstruct.plugins.nei;
|
||||
|
||||
import tconstruct.TConstruct;
|
||||
import tconstruct.plugins.ICompatPlugin;
|
||||
|
||||
public class NotEnoughItems implements ICompatPlugin
|
||||
{
|
||||
@Override
|
||||
public String getModId() {
|
||||
return "NotEnoughItems";
|
||||
}
|
||||
|
||||
@Override
|
||||
public void preInit() {
|
||||
// Nothing
|
||||
}
|
||||
|
||||
@Override
|
||||
public void init() {
|
||||
TConstruct.logger.info("NotEnoughItems detected. Registering TConstruct NEI plugin.");
|
||||
NEICompat.registerNEICompat();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void postInit() {
|
||||
// Nothing
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,51 +0,0 @@
|
||||
package tconstruct.plugins.waila;
|
||||
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
import tconstruct.blocks.logic.CastingBasinLogic;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class BasinDataProvider implements IWailaDataProvider {
|
||||
|
||||
@Override
|
||||
public ItemStack getWailaStack(IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
if (accessor.getTileEntity() instanceof CastingBasinLogic)
|
||||
{
|
||||
return ((CastingBasinLogic)accessor.getTileEntity()).getStackInSlot(0);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaHead(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaBody(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
if (accessor.getTileEntity() instanceof CastingBasinLogic && config.getConfig("tcon.basin", true))
|
||||
{
|
||||
CastingBasinLogic te = (CastingBasinLogic)accessor.getTileEntity();
|
||||
if (te.getFluidAmount() != 0)
|
||||
{
|
||||
FluidStack fs = te.getFluid();
|
||||
currenttip.add("Liquid: " + WailaRegistrar.fluidNameHelper(fs));
|
||||
currenttip.add("Amount: " + fs.amount + "/" + te.getCapacity());
|
||||
}
|
||||
else
|
||||
{
|
||||
if (te.getStackInSlot(0) != null) {
|
||||
currenttip.add("Contains: " + te.getStackInSlot(0).getDisplayName());
|
||||
} else {
|
||||
currenttip.add("§oEmpty"); // "§o" == Italics
|
||||
}
|
||||
}
|
||||
}
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,48 +0,0 @@
|
||||
package tconstruct.plugins.waila;
|
||||
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
import tconstruct.blocks.logic.CastingChannelLogic;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class CastingChannelDataProvider implements IWailaDataProvider
|
||||
{
|
||||
|
||||
@Override
|
||||
public ItemStack getWailaStack (IWailaDataAccessor accessor, IWailaConfigHandler config)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaHead (ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config)
|
||||
{
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaBody (ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config)
|
||||
{
|
||||
if (accessor.getTileEntity() instanceof CastingChannelLogic && config.getConfig("tcon.castingchannel", true))
|
||||
{
|
||||
CastingChannelLogic te = (CastingChannelLogic) accessor.getTileEntity();
|
||||
if (te.liquid != null && te.liquid.amount > 0)
|
||||
{
|
||||
FluidStack fs = te.liquid;
|
||||
currenttip.add("Liquid: " + WailaRegistrar.fluidNameHelper(fs));
|
||||
currenttip.add("Amount: " + fs.amount + "/" + te.getCapacity());
|
||||
}
|
||||
else
|
||||
{
|
||||
currenttip.add("§oEmpty"); // "§o" == Italics
|
||||
}
|
||||
}
|
||||
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,46 +0,0 @@
|
||||
package tconstruct.plugins.waila;
|
||||
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
import tconstruct.blocks.logic.LavaTankLogic;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class SearedTankDataProvider implements IWailaDataProvider
|
||||
{
|
||||
|
||||
@Override
|
||||
public ItemStack getWailaStack (IWailaDataAccessor accessor, IWailaConfigHandler config)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaHead (ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config)
|
||||
{
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaBody (ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config)
|
||||
{
|
||||
if (accessor.getTileEntity() instanceof LavaTankLogic && config.getConfig("tcon.searedtank", true))
|
||||
{
|
||||
LavaTankLogic te = (LavaTankLogic) accessor.getTileEntity();
|
||||
if (te.containsFluid())
|
||||
{
|
||||
FluidStack fs = te.tank.getFluid();
|
||||
currenttip.add("Liquid: " + WailaRegistrar.fluidNameHelper(fs));
|
||||
currenttip.add("Amount: " + fs.amount + "/" + te.tank.getCapacity());
|
||||
}
|
||||
else
|
||||
{
|
||||
currenttip.add("§oEmpty"); // "§o" == Italics
|
||||
}
|
||||
}
|
||||
return currenttip;
|
||||
}
|
||||
}
|
||||
@@ -1,58 +0,0 @@
|
||||
package tconstruct.plugins.waila;
|
||||
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
import tconstruct.blocks.logic.SmelteryLogic;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class SmelteryDataProvider implements IWailaDataProvider
|
||||
{
|
||||
|
||||
@Override
|
||||
public ItemStack getWailaStack (IWailaDataAccessor accessor, IWailaConfigHandler config)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaHead (ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config)
|
||||
{
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaBody (ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config)
|
||||
{
|
||||
if (accessor.getTileEntity() instanceof SmelteryLogic && config.getConfig("tcon.smeltery", true))
|
||||
{
|
||||
SmelteryLogic te = (SmelteryLogic) accessor.getTileEntity();
|
||||
if (te.validStructure)
|
||||
{
|
||||
List<FluidStack> fls = te.moltenMetal;
|
||||
if (fls.size() <= 0)
|
||||
{
|
||||
currenttip.add("§oEmpty"); // "§o" == Italics
|
||||
}
|
||||
else
|
||||
{
|
||||
for (int i = 0; i < fls.size(); i++)
|
||||
{
|
||||
FluidStack st = fls.get(i);
|
||||
currenttip.add(WailaRegistrar.fluidNameHelper(st) + " (" + st.amount + "mB)");
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
currenttip.add("§oInvalid structure");
|
||||
}
|
||||
}
|
||||
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,46 +0,0 @@
|
||||
package tconstruct.plugins.waila;
|
||||
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import tconstruct.blocks.logic.CastingTableLogic;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class TableDataProvider implements IWailaDataProvider {
|
||||
|
||||
@Override
|
||||
public ItemStack getWailaStack(IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
if (accessor.getTileEntity() instanceof CastingTableLogic)
|
||||
{
|
||||
CastingTableLogic te = (CastingTableLogic)accessor.getTileEntity();
|
||||
return te.getStackInSlot(0);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaHead(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaBody(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
if (accessor.getTileEntity() instanceof CastingTableLogic && config.getConfig("tcon.table", true))
|
||||
{
|
||||
CastingTableLogic te = (CastingTableLogic)accessor.getTileEntity();
|
||||
if (te.getStackInSlot(1) != null)
|
||||
{
|
||||
currenttip.add("Contains: " + te.getStackInSlot(1).getDisplayName());
|
||||
}
|
||||
if (te.getFluid() != null)
|
||||
{
|
||||
currenttip.add("Fluid: " + WailaRegistrar.fluidNameHelper(te.getFluid()));
|
||||
currenttip.add("Amount: " + te.getFluidAmount() + "/" + te.getCapacity());
|
||||
}
|
||||
}
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,31 +0,0 @@
|
||||
package tconstruct.plugins.waila;
|
||||
|
||||
import cpw.mods.fml.common.event.FMLInterModComms;
|
||||
import tconstruct.TConstruct;
|
||||
import tconstruct.plugins.ICompatPlugin;
|
||||
|
||||
public class Waila implements ICompatPlugin
|
||||
{
|
||||
@Override
|
||||
public String getModId() {
|
||||
return "Waila";
|
||||
}
|
||||
|
||||
@Override
|
||||
public void preInit() {
|
||||
// Nothing
|
||||
}
|
||||
|
||||
@Override
|
||||
public void init() {
|
||||
TConstruct.logger.info("Waila detected. Registering TConstruct tank blocks with Waila registry.");
|
||||
|
||||
FMLInterModComms.sendMessage("Waila", "register", "tconstruct.plugins.waila.WailaRegistrar.wailaCallback");
|
||||
}
|
||||
|
||||
@Override
|
||||
public void postInit() {
|
||||
// Nothing
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,46 +0,0 @@
|
||||
package tconstruct.plugins.waila;
|
||||
|
||||
import mcp.mobius.waila.api.IWailaRegistrar;
|
||||
import net.minecraft.util.StatCollector;
|
||||
import net.minecraftforge.fluids.FluidRegistry;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
import tconstruct.TConstruct;
|
||||
import tconstruct.blocks.LavaTankBlock;
|
||||
import tconstruct.blocks.SmelteryBlock;
|
||||
import tconstruct.blocks.logic.CastingBasinLogic;
|
||||
import tconstruct.blocks.logic.CastingChannelLogic;
|
||||
import tconstruct.blocks.logic.CastingTableLogic;
|
||||
|
||||
public class WailaRegistrar
|
||||
{
|
||||
public static void wailaCallback (IWailaRegistrar registrar)
|
||||
{
|
||||
TConstruct.logger.info("[Waila-Compat] Got registrar: " + registrar);
|
||||
|
||||
// Configs
|
||||
registrar.addConfig("Tinkers' Construct", "tcon.searedtank", "Seared Tank");
|
||||
registrar.addConfig("Tinkers' Construct", "tcon.castingchannel", "Casting Channel");
|
||||
//registrar.addConfig("Tinkers' Construct", "tcon.essenceetractor", "Essence Extractor");
|
||||
registrar.addConfig("Tinkers' Construct", "tcon.basin", "Casting Basin");
|
||||
registrar.addConfig("Tinkers' Construct", "tcon.table", "Casting Table");
|
||||
registrar.addConfig("Tinkers' Construct", "tcon.smeltery", "Smeltery status");
|
||||
|
||||
// Tanks
|
||||
registrar.registerBodyProvider(new SearedTankDataProvider(), LavaTankBlock.class);
|
||||
registrar.registerBodyProvider(new CastingChannelDataProvider(), CastingChannelLogic.class);
|
||||
//registrar.registerBodyProvider(new EssenceExtractorDataProvider(), EssenceExtractor.class);
|
||||
|
||||
// Casting systems
|
||||
registrar.registerBodyProvider(new BasinDataProvider(), CastingBasinLogic.class);
|
||||
registrar.registerBodyProvider(new TableDataProvider(), CastingTableLogic.class);
|
||||
|
||||
// Smeltery
|
||||
registrar.registerBodyProvider(new SmelteryDataProvider(), SmelteryBlock.class);
|
||||
}
|
||||
|
||||
public static String fluidNameHelper (FluidStack f)
|
||||
{
|
||||
return StatCollector.translateToLocal(FluidRegistry.getFluidName(f));
|
||||
}
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user