Finished modularization
This commit is contained in:
parent
daf896fa85
commit
fcb78c6a4a
72 changed files with 108 additions and 270 deletions
|
@ -4,7 +4,6 @@ import net.minecraft.block.Block;
|
|||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.oredict.ShapedOreRecipe;
|
||||
import resonantinduction.archaic.blocks.BlockMachineMaterial;
|
||||
import resonantinduction.archaic.blocks.BlockTurntable;
|
||||
import resonantinduction.archaic.crate.BlockCrate;
|
||||
import resonantinduction.archaic.crate.ItemBlockCrate;
|
||||
|
@ -17,7 +16,6 @@ import resonantinduction.archaic.firebox.BlockHotPlate;
|
|||
import resonantinduction.archaic.firebox.TileFirebox;
|
||||
import resonantinduction.archaic.firebox.TileHotPlate;
|
||||
import resonantinduction.archaic.imprint.BlockImprinter;
|
||||
import resonantinduction.archaic.imprint.ItemImprint;
|
||||
import resonantinduction.archaic.imprint.TileImprinter;
|
||||
import resonantinduction.archaic.process.BlockCast;
|
||||
import resonantinduction.archaic.process.BlockMillstone;
|
||||
|
@ -27,6 +25,7 @@ import resonantinduction.core.Reference;
|
|||
import resonantinduction.core.ResonantInduction;
|
||||
import resonantinduction.core.Settings;
|
||||
import resonantinduction.core.TabRI;
|
||||
import resonantinduction.core.prefab.imprint.ItemImprint;
|
||||
import calclavia.lib.content.ContentRegistry;
|
||||
import calclavia.lib.network.PacketAnnotation;
|
||||
import calclavia.lib.network.PacketHandler;
|
||||
|
@ -76,8 +75,6 @@ public class Archaic
|
|||
public static Block blockHotPlate;
|
||||
public static Block blockMillstone;
|
||||
public static Block blockCast;
|
||||
public static Block blockMachinePart;
|
||||
|
||||
public static Item itemImprint;
|
||||
|
||||
// Machine and Processing
|
||||
|
@ -96,7 +93,6 @@ public class Archaic
|
|||
blockHotPlate = contentRegistry.createTile(BlockHotPlate.class, TileHotPlate.class);
|
||||
blockMillstone = contentRegistry.createTile(BlockMillstone.class, TileMillstone.class);
|
||||
blockCast = contentRegistry.createTile(BlockCast.class, TileCast.class);
|
||||
blockMachinePart = contentRegistry.createBlock(BlockMachineMaterial.class, ItemBlockMetadata.class);
|
||||
|
||||
itemImprint = contentRegistry.createItem(ItemImprint.class);
|
||||
itemHammer = contentRegistry.createItem(ItemHammer.class);
|
||||
|
|
|
@ -11,7 +11,6 @@ import net.minecraft.world.IBlockAccess;
|
|||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.core.Reference;
|
||||
import universalelectricity.api.UniversalElectricity;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import calclavia.lib.prefab.block.BlockRotatable;
|
||||
import calclavia.lib.prefab.block.IRotatableBlock;
|
||||
|
|
|
@ -18,8 +18,8 @@ import net.minecraftforge.common.ForgeDirection;
|
|||
|
||||
import org.apache.commons.lang3.ArrayUtils;
|
||||
|
||||
import resonantinduction.archaic.imprint.ItemImprint;
|
||||
import resonantinduction.core.ResonantInduction;
|
||||
import resonantinduction.core.prefab.imprint.ItemImprint;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import calclavia.lib.gui.ContainerDummy;
|
||||
import calclavia.lib.network.IPacketReceiver;
|
||||
|
|
|
@ -10,6 +10,7 @@ import net.minecraft.world.IBlockAccess;
|
|||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.core.Reference;
|
||||
import resonantinduction.core.prefab.imprint.ItemImprint;
|
||||
import universalelectricity.api.UniversalElectricity;
|
||||
import universalelectricity.api.vector.Vector2;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
|
|
|
@ -11,6 +11,7 @@ import net.minecraft.nbt.NBTTagCompound;
|
|||
import net.minecraft.nbt.NBTTagList;
|
||||
import net.minecraft.network.packet.Packet;
|
||||
import resonantinduction.core.ResonantInduction;
|
||||
import resonantinduction.core.prefab.imprint.ItemImprint;
|
||||
import calclavia.lib.network.IPacketReceiver;
|
||||
import calclavia.lib.network.PacketHandler;
|
||||
import calclavia.lib.prefab.tile.TileAdvanced;
|
||||
|
|
|
@ -129,7 +129,7 @@ import net.minecraftforge.gradle.delayed.*
|
|||
task createChangelog(type: ChangelogTask) {
|
||||
def jobName = "${System.getenv().JOB_NAME}"
|
||||
def buildNumber = "${System.getenv().BUILD_NUMBER}"
|
||||
|
||||
jobName.replaceAll(' ','%20')
|
||||
setServerRoot(new DelayedString(project, 'http://ci.calclavia.com/'))
|
||||
setJobName(new DelayedString(project, jobName.toString()));
|
||||
setAuthName(new DelayedString(project, 'console_script'));
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package resonantinduction.electrical;
|
||||
|
||||
import calclavia.lib.render.item.GlobalItemRenderer;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
|
@ -23,6 +22,7 @@ import resonantinduction.electrical.tesla.RenderTesla;
|
|||
import resonantinduction.electrical.tesla.TileTesla;
|
||||
import resonantinduction.electrical.transformer.RenderTransformer;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import calclavia.lib.render.item.GlobalItemRenderer;
|
||||
import codechicken.multipart.TMultiPart;
|
||||
import codechicken.multipart.TileMultipart;
|
||||
import cpw.mods.fml.client.FMLClientHandler;
|
||||
|
|
|
@ -2,7 +2,7 @@ package resonantinduction.electrical.armbot.task;
|
|||
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.api.IBelt;
|
||||
import resonantinduction.api.mechanical.IBelt;
|
||||
import resonantinduction.electrical.armbot.IArmbot;
|
||||
import resonantinduction.electrical.armbot.TaskBaseArmbot;
|
||||
import universalelectricity.api.vector.Vector2;
|
||||
|
|
|
@ -19,8 +19,6 @@ import net.minecraftforge.common.ForgeDirection;
|
|||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import resonantinduction.core.Reference;
|
||||
import resonantinduction.electrical.battery.ItemBlockBattery;
|
||||
import resonantinduction.electrical.battery.TileBattery;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import calclavia.lib.render.RenderUtility;
|
||||
import calclavia.lib.render.item.ISimpleItemRenderer;
|
||||
|
|
|
@ -5,8 +5,8 @@ import java.util.EnumSet;
|
|||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.mechanical.network.IMechanical;
|
||||
import resonantinduction.mechanical.network.IMechanicalNetwork;
|
||||
import resonantinduction.api.mechanical.IMechanical;
|
||||
import resonantinduction.api.mechanical.IMechanicalNetwork;
|
||||
import universalelectricity.api.energy.EnergyStorageHandler;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import calclavia.lib.prefab.tile.IRotatable;
|
||||
|
|
|
@ -15,9 +15,9 @@ import net.minecraft.nbt.NBTTagCompound;
|
|||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.MovingObjectPosition;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.api.mechanical.IMechanical;
|
||||
import resonantinduction.core.ResonantInduction;
|
||||
import resonantinduction.electrical.Electrical;
|
||||
import resonantinduction.mechanical.network.IMechanical;
|
||||
import universalelectricity.api.CompatibilityModule;
|
||||
import universalelectricity.api.energy.IConductor;
|
||||
import universalelectricity.api.energy.IEnergyNetwork;
|
||||
|
|
|
@ -10,8 +10,8 @@ import net.minecraftforge.common.ForgeDirection;
|
|||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import resonantinduction.archaic.Archaic;
|
||||
import resonantinduction.core.Reference;
|
||||
import resonantinduction.core.ResonantInduction;
|
||||
import universalelectricity.api.energy.UnitDisplay;
|
||||
import universalelectricity.api.energy.UnitDisplay.Unit;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
|
@ -46,14 +46,14 @@ public class RenderMultimeter implements ISimpleItemRenderer
|
|||
GL11.glRotatef(90, 1, 0, 0);
|
||||
RenderUtility.bind(TextureMap.locationBlocksTexture);
|
||||
// Render the main panel
|
||||
RenderUtility.renderCube(-0.5, -0.05, -0.5, 0.5, 0.05, 0.5, Archaic.blockMachinePart, RenderUtility.loadedIconMap.get(Reference.PREFIX + "multimeter_screen"));
|
||||
RenderUtility.renderCube(-0.5, -0.05, -0.5, 0.5, 0.05, 0.5, ResonantInduction.blockMachinePart, RenderUtility.loadedIconMap.get(Reference.PREFIX + "multimeter_screen"));
|
||||
ForgeDirection dir = ForgeDirection.NORTH;
|
||||
final int metadata = 8;
|
||||
// Render edges
|
||||
// UP
|
||||
RenderUtility.renderCube(-0.501, -0.0501, -0.501, 0.501, 0.0501, -0.44, Archaic.blockMachinePart, null, metadata);
|
||||
RenderUtility.renderCube(-0.501, -0.0501, -0.501, 0.501, 0.0501, -0.44, ResonantInduction.blockMachinePart, null, metadata);
|
||||
// DOWN
|
||||
RenderUtility.renderCube(-0.501, -0.0501, 0.44, 0.501, 0.0501, 0.501, Archaic.blockMachinePart, null, metadata);
|
||||
RenderUtility.renderCube(-0.501, -0.0501, 0.44, 0.501, 0.0501, 0.501, ResonantInduction.blockMachinePart, null, metadata);
|
||||
// LEFT
|
||||
for (int i = 2; i < 6; i++)
|
||||
{
|
||||
|
@ -63,22 +63,22 @@ public class RenderMultimeter implements ISimpleItemRenderer
|
|||
{
|
||||
if (dir.offsetX != check.offsetZ)
|
||||
{
|
||||
RenderUtility.renderCube(-0.501, -0.0501, -0.501, -0.44, 0.0501, 0.501, Archaic.blockMachinePart, null, metadata);
|
||||
RenderUtility.renderCube(-0.501, -0.0501, -0.501, -0.44, 0.0501, 0.501, ResonantInduction.blockMachinePart, null, metadata);
|
||||
}
|
||||
else if (dir.offsetX == check.offsetZ)
|
||||
{
|
||||
RenderUtility.renderCube(0.44, -0.0501, -0.501, 0.501, 0.0501, 0.501, Archaic.blockMachinePart, null, metadata);
|
||||
RenderUtility.renderCube(0.44, -0.0501, -0.501, 0.501, 0.0501, 0.501, ResonantInduction.blockMachinePart, null, metadata);
|
||||
}
|
||||
}
|
||||
if (dir.offsetZ != 0 && check.offsetX != 0)
|
||||
{
|
||||
if (dir.offsetZ == check.offsetX)
|
||||
{
|
||||
RenderUtility.renderCube(-0.501, -0.0501, -0.501, -0.44, 0.0501, 0.501, Archaic.blockMachinePart, null, metadata);
|
||||
RenderUtility.renderCube(-0.501, -0.0501, -0.501, -0.44, 0.0501, 0.501, ResonantInduction.blockMachinePart, null, metadata);
|
||||
}
|
||||
else if (dir.offsetZ != check.offsetX)
|
||||
{
|
||||
RenderUtility.renderCube(0.44, -0.0501, -0.501, 0.501, 0.0501, 0.501, Archaic.blockMachinePart, null, metadata);
|
||||
RenderUtility.renderCube(0.44, -0.0501, -0.501, 0.501, 0.0501, 0.501, ResonantInduction.blockMachinePart, null, metadata);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -98,15 +98,15 @@ public class RenderMultimeter implements ISimpleItemRenderer
|
|||
RenderUtility.rotateFaceBlockToSideOutwards(part.getDirection().getOpposite());
|
||||
RenderUtility.bind(TextureMap.locationBlocksTexture);
|
||||
// Render the main panel
|
||||
RenderUtility.renderCube(-0.5, -0.05, -0.5, 0.5, 0.05, 0.5, Archaic.blockMachinePart, RenderUtility.loadedIconMap.get(Reference.PREFIX + "multimeter_screen"));
|
||||
RenderUtility.renderCube(-0.5, -0.05, -0.5, 0.5, 0.05, 0.5, ResonantInduction.blockMachinePart, RenderUtility.loadedIconMap.get(Reference.PREFIX + "multimeter_screen"));
|
||||
final int metadata = 8;
|
||||
// Render edges
|
||||
// UP
|
||||
if (!part.hasMultimeter(part.x(), part.y() + 1, part.z()))
|
||||
RenderUtility.renderCube(-0.501, -0.0501, -0.501, 0.501, 0.0501, -0.44, Archaic.blockMachinePart, null, metadata);
|
||||
RenderUtility.renderCube(-0.501, -0.0501, -0.501, 0.501, 0.0501, -0.44, ResonantInduction.blockMachinePart, null, metadata);
|
||||
// DOWN
|
||||
if (!part.hasMultimeter(part.x(), part.y() - 1, part.z()))
|
||||
RenderUtility.renderCube(-0.501, -0.0501, 0.44, 0.501, 0.0501, 0.501, Archaic.blockMachinePart, null, metadata);
|
||||
RenderUtility.renderCube(-0.501, -0.0501, 0.44, 0.501, 0.0501, 0.501, ResonantInduction.blockMachinePart, null, metadata);
|
||||
// LEFT
|
||||
for (int i = 2; i < 6; i++)
|
||||
{
|
||||
|
@ -118,22 +118,22 @@ public class RenderMultimeter implements ISimpleItemRenderer
|
|||
{
|
||||
if (dir.offsetX != check.offsetZ)
|
||||
{
|
||||
RenderUtility.renderCube(-0.501, -0.0501, -0.501, -0.44, 0.0501, 0.501, Archaic.blockMachinePart, null, metadata);
|
||||
RenderUtility.renderCube(-0.501, -0.0501, -0.501, -0.44, 0.0501, 0.501, ResonantInduction.blockMachinePart, null, metadata);
|
||||
}
|
||||
else if (dir.offsetX == check.offsetZ)
|
||||
{
|
||||
RenderUtility.renderCube(0.44, -0.0501, -0.501, 0.501, 0.0501, 0.501, Archaic.blockMachinePart, null, metadata);
|
||||
RenderUtility.renderCube(0.44, -0.0501, -0.501, 0.501, 0.0501, 0.501, ResonantInduction.blockMachinePart, null, metadata);
|
||||
}
|
||||
}
|
||||
if (dir.offsetZ != 0 && check.offsetX != 0)
|
||||
{
|
||||
if (dir.offsetZ == check.offsetX)
|
||||
{
|
||||
RenderUtility.renderCube(-0.501, -0.0501, -0.501, -0.44, 0.0501, 0.501, Archaic.blockMachinePart, null, metadata);
|
||||
RenderUtility.renderCube(-0.501, -0.0501, -0.501, -0.44, 0.0501, 0.501, ResonantInduction.blockMachinePart, null, metadata);
|
||||
}
|
||||
else if (dir.offsetZ != check.offsetX)
|
||||
{
|
||||
RenderUtility.renderCube(0.44, -0.0501, -0.501, 0.501, 0.0501, 0.501, Archaic.blockMachinePart, null, metadata);
|
||||
RenderUtility.renderCube(0.44, -0.0501, -0.501, 0.501, 0.0501, 0.501, ResonantInduction.blockMachinePart, null, metadata);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -3,8 +3,10 @@ package resonantinduction.mechanical;
|
|||
import net.minecraft.block.Block;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.common.MinecraftForge;
|
||||
import net.minecraftforge.oredict.OreDictionary;
|
||||
import net.minecraftforge.oredict.ShapedOreRecipe;
|
||||
import resonantinduction.api.mechanical.IMechanical;
|
||||
import resonantinduction.core.Reference;
|
||||
import resonantinduction.core.ResonantInduction;
|
||||
import resonantinduction.core.Settings;
|
||||
|
@ -13,10 +15,10 @@ import resonantinduction.mechanical.belt.BlockConveyorBelt;
|
|||
import resonantinduction.mechanical.belt.TileConveyorBelt;
|
||||
import resonantinduction.mechanical.fluid.pipe.ItemBlockFluidContainer;
|
||||
import resonantinduction.mechanical.fluid.pipe.ItemPipe;
|
||||
import resonantinduction.mechanical.fluid.pump.BlockGrate;
|
||||
import resonantinduction.mechanical.fluid.pump.TileGrate;
|
||||
import resonantinduction.mechanical.fluid.tank.BlockTank;
|
||||
import resonantinduction.mechanical.fluid.tank.TileTank;
|
||||
import resonantinduction.mechanical.fluid.transport.BlockGrate;
|
||||
import resonantinduction.mechanical.fluid.transport.TileGrate;
|
||||
import resonantinduction.mechanical.gear.ItemGear;
|
||||
import resonantinduction.mechanical.gear.ItemGearShaft;
|
||||
import resonantinduction.mechanical.item.ItemPipeGauge;
|
||||
|
@ -26,7 +28,6 @@ import resonantinduction.mechanical.logistic.BlockRejector;
|
|||
import resonantinduction.mechanical.logistic.TileDetector;
|
||||
import resonantinduction.mechanical.logistic.TileManipulator;
|
||||
import resonantinduction.mechanical.logistic.TileRejector;
|
||||
import resonantinduction.mechanical.network.IMechanical;
|
||||
import resonantinduction.mechanical.network.PacketNetwork;
|
||||
import resonantinduction.mechanical.process.BlockFilter;
|
||||
import resonantinduction.mechanical.process.BlockGrindingWheel;
|
||||
|
@ -109,6 +110,8 @@ public class Mechanical
|
|||
{
|
||||
Settings.load();
|
||||
NetworkRegistry.instance().registerGuiHandler(this, proxy);
|
||||
MinecraftForge.EVENT_BUS.register(new MicroblockHighlightHandler());
|
||||
|
||||
itemGear = contentRegistry.createItem(ItemGear.class);
|
||||
itemGearShaft = contentRegistry.createItem(ItemGearShaft.class);
|
||||
windTurbine = contentRegistry.createTile(BlockWindTurbine.class, TileWindTurbine.class);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.core;
|
||||
package resonantinduction.mechanical;
|
||||
|
||||
import net.minecraft.util.EnumMovingObjectType;
|
||||
import net.minecraftforge.client.event.DrawBlockHighlightEvent;
|
||||
|
@ -6,12 +6,7 @@ import net.minecraftforge.event.ForgeSubscribe;
|
|||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import calclavia.lib.render.RenderUtility;
|
||||
import resonantinduction.mechanical.Mechanical;
|
||||
import resonantinduction.mechanical.gear.RenderGear;
|
||||
import codechicken.lib.render.CCRenderState;
|
||||
import codechicken.lib.render.RenderUtils;
|
||||
import codechicken.lib.render.TextureUtils;
|
||||
import codechicken.lib.vec.Vector3;
|
||||
import codechicken.microblock.FacePlacementGrid$;
|
||||
import cpw.mods.fml.relauncher.Side;
|
|
@ -2,7 +2,6 @@ package resonantinduction.mechanical.belt;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.item.EntityItem;
|
||||
|
|
|
@ -11,11 +11,11 @@ import net.minecraft.network.packet.Packet;
|
|||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.AxisAlignedBB;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.api.IBelt;
|
||||
import resonantinduction.api.mechanical.IBelt;
|
||||
import resonantinduction.api.mechanical.IMechanical;
|
||||
import resonantinduction.core.Reference;
|
||||
import resonantinduction.core.ResonantInduction;
|
||||
import resonantinduction.mechanical.Mechanical;
|
||||
import resonantinduction.mechanical.network.IMechanical;
|
||||
import resonantinduction.mechanical.network.TileMechanical;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import calclavia.lib.network.IPacketReceiverWithID;
|
||||
|
|
|
@ -7,8 +7,8 @@ import net.minecraftforge.fluids.FluidStack;
|
|||
import net.minecraftforge.fluids.FluidTank;
|
||||
import net.minecraftforge.fluids.FluidTankInfo;
|
||||
import net.minecraftforge.fluids.IFluidHandler;
|
||||
import resonantinduction.api.fluid.IFluidConnector;
|
||||
import resonantinduction.api.fluid.IFluidNetwork;
|
||||
import resonantinduction.api.mechanical.fluid.IFluidConnector;
|
||||
import resonantinduction.api.mechanical.fluid.IFluidNetwork;
|
||||
import universalelectricity.api.net.IUpdate;
|
||||
import universalelectricity.core.net.NetworkTickHandler;
|
||||
import universalelectricity.core.net.NodeNetwork;
|
||||
|
|
|
@ -8,9 +8,9 @@ import java.util.Map.Entry;
|
|||
import net.minecraftforge.common.ForgeDirection;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
import net.minecraftforge.fluids.IFluidHandler;
|
||||
import resonantinduction.api.fluid.IFluidConnector;
|
||||
import resonantinduction.api.fluid.IFluidNetwork;
|
||||
import resonantinduction.api.fluid.IFluidPipe;
|
||||
import resonantinduction.api.mechanical.fluid.IFluidConnector;
|
||||
import resonantinduction.api.mechanical.fluid.IFluidNetwork;
|
||||
import resonantinduction.api.mechanical.fluid.IFluidPipe;
|
||||
import calclavia.lib.utility.FluidUtility;
|
||||
|
||||
/**
|
||||
|
|
|
@ -6,10 +6,10 @@
|
|||
|
||||
package resonantinduction.mechanical.fluid.pipe;
|
||||
|
||||
import calclavia.lib.render.RenderUtility;
|
||||
import net.minecraft.client.model.ModelBase;
|
||||
import net.minecraft.client.model.ModelRenderer;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import calclavia.lib.render.RenderUtility;
|
||||
|
||||
public class ModelOpenTrough extends ModelBase
|
||||
{
|
||||
|
|
|
@ -13,8 +13,8 @@ import net.minecraftforge.fluids.FluidStack;
|
|||
import net.minecraftforge.fluids.FluidTank;
|
||||
import net.minecraftforge.fluids.FluidTankInfo;
|
||||
import net.minecraftforge.fluids.IFluidHandler;
|
||||
import resonantinduction.api.fluid.IFluidNetwork;
|
||||
import resonantinduction.api.fluid.IFluidPipe;
|
||||
import resonantinduction.api.mechanical.fluid.IFluidNetwork;
|
||||
import resonantinduction.api.mechanical.fluid.IFluidPipe;
|
||||
import resonantinduction.core.prefab.part.PartFramedConnection;
|
||||
import resonantinduction.mechanical.Mechanical;
|
||||
import resonantinduction.mechanical.fluid.network.PipeNetwork;
|
||||
|
|
|
@ -7,8 +7,8 @@ import net.minecraftforge.common.ForgeDirection;
|
|||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import calclavia.lib.render.RenderUtility;
|
||||
import resonantinduction.core.Reference;
|
||||
import calclavia.lib.render.RenderUtility;
|
||||
import cpw.mods.fml.client.FMLClientHandler;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
|
|
@ -13,8 +13,8 @@ import net.minecraftforge.fluids.FluidStack;
|
|||
import net.minecraftforge.fluids.FluidTank;
|
||||
import net.minecraftforge.fluids.FluidTankInfo;
|
||||
import resonantinduction.api.IReadOut;
|
||||
import resonantinduction.api.fluid.IFluidConnector;
|
||||
import resonantinduction.api.fluid.IFluidNetwork;
|
||||
import resonantinduction.api.mechanical.fluid.IFluidConnector;
|
||||
import resonantinduction.api.mechanical.fluid.IFluidNetwork;
|
||||
import resonantinduction.core.ResonantInduction;
|
||||
import resonantinduction.mechanical.Mechanical;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
|
|
|
@ -3,9 +3,6 @@ package resonantinduction.mechanical.fluid.tank;
|
|||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.client.renderer.RenderBlocks;
|
||||
import net.minecraft.client.renderer.Tessellator;
|
||||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
@ -13,16 +10,12 @@ import net.minecraft.tileentity.TileEntity;
|
|||
import net.minecraft.util.MovingObjectPosition;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
import resonantinduction.archaic.Archaic;
|
||||
import resonantinduction.core.render.RIBlockRenderingHandler;
|
||||
import resonantinduction.mechanical.Mechanical;
|
||||
import resonantinduction.mechanical.fluid.pipe.EnumPipeMaterial;
|
||||
import resonantinduction.mechanical.fluid.pipe.ItemBlockFluidContainer;
|
||||
import resonantinduction.mechanical.fluid.prefab.BlockFluidNetwork;
|
||||
import universalelectricity.api.UniversalElectricity;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import calclavia.lib.render.RenderUtility;
|
||||
import calclavia.lib.render.block.ICustomBlockRenderer;
|
||||
import calclavia.lib.utility.FluidUtility;
|
||||
import calclavia.lib.utility.inventory.InventoryUtility;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
|
|
|
@ -1,14 +1,12 @@
|
|||
package resonantinduction.mechanical.fluid.tank;
|
||||
|
||||
import net.minecraft.client.renderer.texture.TextureMap;
|
||||
import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import resonantinduction.archaic.Archaic;
|
||||
import resonantinduction.core.ResonantInduction;
|
||||
import resonantinduction.core.render.RenderFluidHelper;
|
||||
import resonantinduction.mechanical.Mechanical;
|
||||
import calclavia.lib.render.RenderUtility;
|
||||
|
@ -34,7 +32,7 @@ public class RenderTank extends TileEntitySpecialRenderer
|
|||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(x + 0.5, y + 0.5, z + 0.5);
|
||||
RenderUtility.renderBlockWithConnectedTextures(renderSides, Mechanical.blockTank, null, Archaic.blockMachinePart, null);
|
||||
RenderUtility.renderBlockWithConnectedTextures(renderSides, Mechanical.blockTank, null, ResonantInduction.blockMachinePart, null);
|
||||
GL11.glPopMatrix();
|
||||
|
||||
if (fluid != null && fluid.amount > 100)
|
||||
|
|
|
@ -5,8 +5,8 @@ import java.util.Set;
|
|||
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
import resonantinduction.api.fluid.IFluidConnector;
|
||||
import resonantinduction.api.fluid.IFluidNetwork;
|
||||
import resonantinduction.api.mechanical.fluid.IFluidConnector;
|
||||
import resonantinduction.api.mechanical.fluid.IFluidNetwork;
|
||||
import resonantinduction.mechanical.fluid.network.FluidNetwork;
|
||||
|
||||
/**
|
||||
|
|
|
@ -3,8 +3,8 @@ package resonantinduction.mechanical.fluid.tank;
|
|||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import net.minecraftforge.fluids.FluidContainerRegistry;
|
||||
import resonantinduction.api.fluid.IFluidConnector;
|
||||
import resonantinduction.api.fluid.IFluidNetwork;
|
||||
import resonantinduction.api.mechanical.fluid.IFluidConnector;
|
||||
import resonantinduction.api.mechanical.fluid.IFluidNetwork;
|
||||
import resonantinduction.mechanical.fluid.prefab.TileFluidNetwork;
|
||||
|
||||
public class TileTank extends TileFluidNetwork
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.mechanical.fluid.pump;
|
||||
package resonantinduction.mechanical.fluid.transport;
|
||||
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IconRegister;
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.mechanical.motor;
|
||||
package resonantinduction.mechanical.fluid.transport;
|
||||
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
|
@ -21,7 +21,7 @@ public class BlockHydrualicPump extends BlockRotatable
|
|||
@Override
|
||||
public TileEntity createNewTileEntity(World world)
|
||||
{
|
||||
return new TileFluidMotor();
|
||||
return new TileHydraulicPump();
|
||||
}
|
||||
|
||||
@Override
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.api.fluid;
|
||||
package resonantinduction.mechanical.fluid.transport;
|
||||
|
||||
import java.util.List;
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.mechanical.fluid.pump;
|
||||
package resonantinduction.mechanical.fluid.transport;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.mechanical.fluid.pump;
|
||||
package resonantinduction.mechanical.fluid.transport;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Iterator;
|
||||
|
@ -11,7 +11,6 @@ import net.minecraftforge.fluids.FluidStack;
|
|||
import net.minecraftforge.fluids.FluidTank;
|
||||
import net.minecraftforge.fluids.FluidTankInfo;
|
||||
import net.minecraftforge.fluids.IFluidHandler;
|
||||
import resonantinduction.api.fluid.IDrain;
|
||||
import universalelectricity.api.net.IUpdate;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import universalelectricity.core.net.NetworkTickHandler;
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.mechanical.motor;
|
||||
package resonantinduction.mechanical.fluid.transport;
|
||||
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
|
@ -6,12 +6,12 @@ import net.minecraftforge.fluids.Fluid;
|
|||
import net.minecraftforge.fluids.FluidStack;
|
||||
import net.minecraftforge.fluids.FluidTankInfo;
|
||||
import net.minecraftforge.fluids.IFluidHandler;
|
||||
import resonantinduction.api.fluid.IFluidPipe;
|
||||
import resonantinduction.api.mechanical.fluid.IFluidPipe;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import calclavia.lib.prefab.tile.IRotatable;
|
||||
import calclavia.lib.prefab.tile.TileAdvanced;
|
||||
|
||||
public class TileFluidMotor extends TileAdvanced implements IFluidHandler, IRotatable
|
||||
public class TileHydraulicPump extends TileAdvanced implements IFluidHandler, IRotatable
|
||||
{
|
||||
ForgeDirection facing = ForgeDirection.UNKNOWN;
|
||||
boolean input = true;
|
||||
|
@ -39,7 +39,7 @@ public class TileFluidMotor extends TileAdvanced implements IFluidHandler, IRota
|
|||
return 0;
|
||||
}
|
||||
}
|
||||
if (tileOut instanceof IFluidHandler && !(tileOut instanceof TileFluidMotor))
|
||||
if (tileOut instanceof IFluidHandler && !(tileOut instanceof TileHydraulicPump))
|
||||
{
|
||||
// TODO pass fluid on to the other side of the motor and get average flow rate
|
||||
}
|
||||
|
@ -80,7 +80,7 @@ public class TileFluidMotor extends TileAdvanced implements IFluidHandler, IRota
|
|||
if (from == getDirection().getOpposite())
|
||||
{
|
||||
TileEntity tile = new Vector3(this).translate(from.getOpposite()).getTileEntity(this.worldObj);
|
||||
if (tile instanceof IFluidHandler && !(tile instanceof TileFluidMotor))
|
||||
if (tile instanceof IFluidHandler && !(tile instanceof TileHydraulicPump))
|
||||
{
|
||||
return ((IFluidHandler) tile).getTankInfo(from);
|
||||
}
|
|
@ -7,7 +7,6 @@ import net.minecraft.entity.player.EntityPlayer;
|
|||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import codechicken.lib.vec.BlockCoord;
|
||||
import codechicken.lib.vec.Vector3;
|
||||
import codechicken.microblock.FacePlacementGrid$;
|
||||
|
|
|
@ -3,7 +3,6 @@ package resonantinduction.mechanical.gear;
|
|||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
import resonantinduction.core.Settings;
|
||||
import codechicken.lib.vec.BlockCoord;
|
||||
import codechicken.lib.vec.Vector3;
|
||||
import codechicken.multipart.JItemMultiPart;
|
||||
|
|
|
@ -11,9 +11,9 @@ import net.minecraft.tileentity.TileEntity;
|
|||
import net.minecraft.util.MovingObjectPosition;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.api.mechanical.IMechanical;
|
||||
import resonantinduction.core.Reference;
|
||||
import resonantinduction.mechanical.Mechanical;
|
||||
import resonantinduction.mechanical.network.IMechanical;
|
||||
import resonantinduction.mechanical.network.PartMechanical;
|
||||
import calclavia.lib.multiblock.reference.IMultiBlockStructure;
|
||||
import calclavia.lib.multiblock.reference.MultiBlockHandler;
|
||||
|
|
|
@ -7,8 +7,8 @@ import java.util.Set;
|
|||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.api.mechanical.IMechanical;
|
||||
import resonantinduction.mechanical.Mechanical;
|
||||
import resonantinduction.mechanical.network.IMechanical;
|
||||
import resonantinduction.mechanical.network.PartMechanical;
|
||||
import codechicken.lib.raytracer.IndexedCuboid6;
|
||||
import codechicken.lib.vec.Cuboid6;
|
||||
|
|
|
@ -1,7 +1,5 @@
|
|||
package resonantinduction.mechanical.gear;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.client.renderer.RenderBlocks;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.client.model.AdvancedModelLoader;
|
||||
import net.minecraftforge.client.model.IModelCustom;
|
||||
|
|
|
@ -11,7 +11,7 @@ import net.minecraft.world.IBlockAccess;
|
|||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.core.Reference;
|
||||
import resonantinduction.core.prefab.BlockImprintable;
|
||||
import resonantinduction.core.prefab.imprint.BlockImprintable;
|
||||
import universalelectricity.api.UniversalElectricity;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
|
|
@ -5,7 +5,7 @@ import net.minecraft.tileentity.TileEntity;
|
|||
import net.minecraft.util.AxisAlignedBB;
|
||||
import net.minecraft.util.ChatMessageComponent;
|
||||
import net.minecraft.world.World;
|
||||
import resonantinduction.core.prefab.BlockImprintable;
|
||||
import resonantinduction.core.prefab.imprint.BlockImprintable;
|
||||
import resonantinduction.core.render.RIBlockRenderingHandler;
|
||||
import universalelectricity.api.UniversalElectricity;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
|
|
|
@ -5,7 +5,7 @@ import net.minecraft.tileentity.TileEntity;
|
|||
import net.minecraft.util.Icon;
|
||||
import net.minecraft.world.World;
|
||||
import resonantinduction.core.Reference;
|
||||
import resonantinduction.core.prefab.BlockImprintable;
|
||||
import resonantinduction.core.prefab.imprint.BlockImprintable;
|
||||
import resonantinduction.core.render.RIBlockRenderingHandler;
|
||||
import universalelectricity.api.UniversalElectricity;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
|
|
|
@ -11,7 +11,7 @@ import net.minecraft.network.packet.Packet;
|
|||
import net.minecraft.util.AxisAlignedBB;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.core.ResonantInduction;
|
||||
import resonantinduction.core.prefab.TileFilterable;
|
||||
import resonantinduction.core.prefab.imprint.TileFilterable;
|
||||
import resonantinduction.mechanical.Mechanical;
|
||||
import calclavia.lib.network.IPacketReceiver;
|
||||
import calclavia.lib.network.PacketHandler;
|
||||
|
|
|
@ -9,10 +9,10 @@ import net.minecraft.nbt.NBTTagCompound;
|
|||
import net.minecraft.network.packet.Packet;
|
||||
import net.minecraft.util.AxisAlignedBB;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.api.IManipulator;
|
||||
import resonantinduction.archaic.imprint.ItemImprint;
|
||||
import resonantinduction.api.mechanical.IManipulator;
|
||||
import resonantinduction.core.ResonantInduction;
|
||||
import resonantinduction.core.prefab.TileFilterable;
|
||||
import resonantinduction.core.prefab.imprint.ItemImprint;
|
||||
import resonantinduction.core.prefab.imprint.TileFilterable;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import calclavia.lib.network.IPacketReceiver;
|
||||
import calclavia.lib.prefab.tile.IRotatable;
|
||||
|
|
|
@ -10,9 +10,9 @@ import net.minecraft.network.packet.Packet;
|
|||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.AxisAlignedBB;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.api.IBelt;
|
||||
import resonantinduction.api.mechanical.IBelt;
|
||||
import resonantinduction.core.ResonantInduction;
|
||||
import resonantinduction.core.prefab.TileFilterable;
|
||||
import resonantinduction.core.prefab.imprint.TileFilterable;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import calclavia.lib.network.IPacketReceiverWithID;
|
||||
|
||||
|
|
|
@ -7,7 +7,8 @@ import java.util.LinkedHashMap;
|
|||
import java.util.LinkedHashSet;
|
||||
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.mechanical.process.TileGrinderWheel;
|
||||
import resonantinduction.api.mechanical.IMechanical;
|
||||
import resonantinduction.api.mechanical.IMechanicalNetwork;
|
||||
import universalelectricity.api.net.IUpdate;
|
||||
import universalelectricity.core.net.Network;
|
||||
import universalelectricity.core.net.NetworkTickHandler;
|
||||
|
|
|
@ -8,6 +8,8 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.MovingObjectPosition;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.api.mechanical.IMechanical;
|
||||
import resonantinduction.api.mechanical.IMechanicalNetwork;
|
||||
import codechicken.lib.data.MCDataInput;
|
||||
import codechicken.lib.data.MCDataOutput;
|
||||
import codechicken.multipart.JCuboidPart;
|
||||
|
|
|
@ -4,6 +4,8 @@ import net.minecraft.entity.player.EntityPlayer;
|
|||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.api.mechanical.IMechanical;
|
||||
import resonantinduction.api.mechanical.IMechanicalNetwork;
|
||||
import resonantinduction.core.ResonantInduction;
|
||||
import resonantinduction.mechanical.gear.PartGearShaft;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
|
|
|
@ -1,7 +1,5 @@
|
|||
package resonantinduction.mechanical.process;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.block.ITileEntityProvider;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.entity.Entity;
|
||||
|
@ -13,7 +11,8 @@ import net.minecraftforge.common.ForgeDirection;
|
|||
import resonantinduction.core.Reference;
|
||||
import resonantinduction.core.render.RIBlockRenderingHandler;
|
||||
import calclavia.lib.prefab.block.BlockRotatable;
|
||||
import calclavia.lib.utility.WorldUtility;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
/**
|
||||
* A block used to build machines.
|
||||
|
|
|
@ -12,7 +12,6 @@ import net.minecraftforge.client.model.obj.WavefrontObject;
|
|||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.core.Reference;
|
||||
import calclavia.lib.render.RenderUtility;
|
||||
import calclavia.lib.utility.WorldUtility;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
|
|
|
@ -7,12 +7,12 @@ import net.minecraftforge.common.ForgeDirection;
|
|||
|
||||
import org.apache.commons.lang3.ArrayUtils;
|
||||
|
||||
import resonantinduction.api.mechanical.IMechanical;
|
||||
import resonantinduction.api.recipe.MachineRecipes;
|
||||
import resonantinduction.api.recipe.MachineRecipes.RecipeType;
|
||||
import resonantinduction.api.recipe.RecipeResource;
|
||||
import resonantinduction.core.Reference;
|
||||
import resonantinduction.core.ResonantInduction;
|
||||
import resonantinduction.mechanical.network.IMechanical;
|
||||
import resonantinduction.mechanical.network.TileMechanical;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import calclavia.lib.prefab.tile.IRotatable;
|
||||
|
|
|
@ -4,8 +4,8 @@ import java.util.HashSet;
|
|||
import java.util.Set;
|
||||
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.mechanical.network.IMechanical;
|
||||
import resonantinduction.mechanical.network.IMechanicalNetwork;
|
||||
import resonantinduction.api.mechanical.IMechanical;
|
||||
import resonantinduction.api.mechanical.IMechanicalNetwork;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import codechicken.multipart.PartMap;
|
||||
import codechicken.multipart.TMultiPart;
|
||||
|
|
|
@ -4,8 +4,6 @@ import net.minecraft.block.material.Material;
|
|||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
import resonantinduction.core.Reference;
|
||||
import resonantinduction.core.Settings;
|
||||
import resonantinduction.core.TabRI;
|
||||
import resonantinduction.core.render.RIBlockRenderingHandler;
|
||||
import calclavia.lib.prefab.turbine.BlockTurbine;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
|
|
|
@ -4,8 +4,6 @@ import net.minecraft.block.material.Material;
|
|||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
import resonantinduction.core.Reference;
|
||||
import resonantinduction.core.Settings;
|
||||
import resonantinduction.core.TabRI;
|
||||
import resonantinduction.core.render.RIBlockRenderingHandler;
|
||||
import calclavia.lib.prefab.turbine.BlockTurbine;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
|
|
|
@ -5,10 +5,10 @@ import net.minecraft.nbt.NBTTagCompound;
|
|||
import net.minecraft.network.packet.Packet;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.api.mechanical.IMechanical;
|
||||
import resonantinduction.api.mechanical.IMechanicalNetwork;
|
||||
import resonantinduction.core.ResonantInduction;
|
||||
import resonantinduction.mechanical.gear.PartGearShaft;
|
||||
import resonantinduction.mechanical.network.IMechanical;
|
||||
import resonantinduction.mechanical.network.IMechanicalNetwork;
|
||||
import resonantinduction.mechanical.network.MechanicalNetwork;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import calclavia.lib.network.PacketHandler;
|
||||
|
|
|
@ -1,19 +1,15 @@
|
|||
package resonantinduction.mechanical.turbine;
|
||||
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.network.packet.Packet;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.biome.BiomeGenBase;
|
||||
import net.minecraft.world.biome.BiomeGenOcean;
|
||||
import net.minecraft.world.biome.BiomeGenPlains;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.core.ResonantInduction;
|
||||
import resonantinduction.api.mechanical.IMechanical;
|
||||
import resonantinduction.api.mechanical.IMechanicalNetwork;
|
||||
import resonantinduction.mechanical.gear.PartGearShaft;
|
||||
import resonantinduction.mechanical.network.IMechanical;
|
||||
import resonantinduction.mechanical.network.IMechanicalNetwork;
|
||||
import resonantinduction.mechanical.network.MechanicalNetwork;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import calclavia.lib.network.PacketHandler;
|
||||
import calclavia.lib.prefab.turbine.TileTurbine;
|
||||
|
||||
/**
|
||||
|
|
|
@ -1,9 +1,8 @@
|
|||
package resonantinduction.api;
|
||||
package resonantinduction.api.mechanical;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.entity.Entity;
|
||||
import resonantinduction.mechanical.network.IMechanical;
|
||||
|
||||
/**
|
||||
* An interface applied to the tile entity of a conveyor belt
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.api;
|
||||
package resonantinduction.api.mechanical;
|
||||
|
||||
/**
|
||||
* Interface applied to the manipulator.
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.mechanical.network;
|
||||
package resonantinduction.api.mechanical;
|
||||
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import universalelectricity.api.net.IConnector;
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.mechanical.network;
|
||||
package resonantinduction.api.mechanical;
|
||||
|
||||
import universalelectricity.api.net.INetwork;
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.api.fluid;
|
||||
package resonantinduction.api.mechanical.fluid;
|
||||
|
||||
import net.minecraftforge.fluids.FluidTank;
|
||||
import net.minecraftforge.fluids.IFluidHandler;
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.api.fluid;
|
||||
package resonantinduction.api.mechanical.fluid;
|
||||
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.api.fluid;
|
||||
package resonantinduction.api.mechanical.fluid;
|
||||
|
||||
/**
|
||||
* Applied to tiles that are pipes and support pressure
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.api.fluid;
|
||||
package resonantinduction.api.mechanical.fluid;
|
||||
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.api.fluid;
|
||||
package resonantinduction.api.mechanical.fluid;
|
||||
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
|
|
@ -14,6 +14,7 @@ import org.modstats.Modstats;
|
|||
import resonantinduction.core.handler.TextureHookHandler;
|
||||
import resonantinduction.core.prefab.part.PacketMultiPart;
|
||||
import resonantinduction.core.resource.BlockDust;
|
||||
import resonantinduction.core.resource.BlockMachineMaterial;
|
||||
import resonantinduction.core.resource.ResourceGenerator;
|
||||
import resonantinduction.core.resource.TileMaterial;
|
||||
import resonantinduction.core.resource.fluid.TileFluidMixture;
|
||||
|
@ -24,6 +25,7 @@ import calclavia.lib.content.ContentRegistry;
|
|||
import calclavia.lib.network.PacketAnnotation;
|
||||
import calclavia.lib.network.PacketHandler;
|
||||
import calclavia.lib.network.PacketTile;
|
||||
import calclavia.lib.prefab.item.ItemBlockMetadata;
|
||||
import calclavia.lib.utility.LanguageUtility;
|
||||
import cpw.mods.fml.common.FMLLog;
|
||||
import cpw.mods.fml.common.Mod;
|
||||
|
@ -76,7 +78,7 @@ public class ResonantInduction
|
|||
public static Block blockDust;
|
||||
public static final List<Block> blockFluidMixtures = new ArrayList<Block>();
|
||||
public static final List<Block> blockFluidMaterials = new ArrayList<Block>();
|
||||
public static Block blockGas;
|
||||
public static Block blockMachinePart;
|
||||
|
||||
public static List<Fluid> fluidMixtures = new ArrayList<Fluid>();
|
||||
public static List<Fluid> fluidMaterials = new ArrayList<Fluid>();
|
||||
|
@ -96,7 +98,8 @@ public class ResonantInduction
|
|||
// Register Forge Events
|
||||
MinecraftForge.EVENT_BUS.register(ResourceGenerator.INSTANCE);
|
||||
MinecraftForge.EVENT_BUS.register(new TextureHookHandler());
|
||||
MinecraftForge.EVENT_BUS.register(new MicroblockHighlightHandler());
|
||||
|
||||
blockMachinePart = contentRegistry.createBlock(BlockMachineMaterial.class, ItemBlockMetadata.class);
|
||||
|
||||
/**
|
||||
* Melting dusts
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.core.prefab;
|
||||
package resonantinduction.core.prefab.imprint;
|
||||
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
|
@ -9,7 +9,6 @@ import net.minecraft.tileentity.TileEntity;
|
|||
import net.minecraft.util.MathHelper;
|
||||
import net.minecraft.world.World;
|
||||
import resonantinduction.api.IFilterable;
|
||||
import resonantinduction.archaic.imprint.ItemImprint;
|
||||
import calclavia.lib.prefab.block.BlockRotatable;
|
||||
|
||||
/**
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.archaic.imprint;
|
||||
package resonantinduction.core.prefab.imprint;
|
||||
|
||||
import java.util.HashSet;
|
||||
import java.util.List;
|
||||
|
@ -19,11 +19,6 @@ import resonantinduction.core.TabRI;
|
|||
|
||||
public class ItemImprint extends Item
|
||||
{
|
||||
public ItemImprint()
|
||||
{
|
||||
this(Settings.getNextItemID());
|
||||
}
|
||||
|
||||
public ItemImprint(int id)
|
||||
{
|
||||
super(Settings.CONFIGURATION.getItem("imprint", id).getInt());
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.core.prefab;
|
||||
package resonantinduction.core.prefab.imprint;
|
||||
|
||||
import java.util.Set;
|
||||
|
||||
|
@ -6,7 +6,6 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import resonantinduction.api.IFilterable;
|
||||
import resonantinduction.archaic.imprint.ItemImprint;
|
||||
import calclavia.lib.prefab.tile.IRotatable;
|
||||
import calclavia.lib.prefab.tile.TileExternalInventory;
|
||||
|
|
@ -8,8 +8,8 @@ import net.minecraft.entity.player.EntityPlayer;
|
|||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.MovingObjectPosition;
|
||||
import resonantinduction.archaic.imprint.ItemImprint;
|
||||
import resonantinduction.core.prefab.TileFilterable;
|
||||
import resonantinduction.core.prefab.imprint.ItemImprint;
|
||||
import resonantinduction.core.prefab.imprint.TileFilterable;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import calclavia.lib.render.RenderUtility;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
package resonantinduction.archaic.blocks;
|
||||
package resonantinduction.core.resource;
|
||||
|
||||
import java.util.List;
|
||||
|
|
@ -1,128 +0,0 @@
|
|||
package resonantinduction.core.resource;
|
||||
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.util.MathHelper;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.world.chunk.IChunkProvider;
|
||||
import net.minecraft.world.gen.ChunkProviderEnd;
|
||||
import net.minecraft.world.gen.ChunkProviderHell;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
import resonantinduction.core.ResonantInduction;
|
||||
import cpw.mods.fml.common.IWorldGenerator;
|
||||
|
||||
public class GasOreGenerator implements IWorldGenerator
|
||||
{
|
||||
|
||||
public int minGenerateLevel = 6;
|
||||
public int maxGenerateLevel = 50;
|
||||
public int amountPerChunk = 3;
|
||||
public int amountPerBranch = 15;
|
||||
public int replaceID = 1;
|
||||
|
||||
public FluidStack stack;
|
||||
|
||||
@Override
|
||||
public void generate(Random rand, int chunkX, int chunkZ, World world, IChunkProvider chunkGenerator, IChunkProvider chunkProvider)
|
||||
{
|
||||
chunkX = chunkX << 4;
|
||||
chunkZ = chunkZ << 4;
|
||||
|
||||
if (this.isOreGeneratedInWorld(world, chunkGenerator))
|
||||
{
|
||||
this.generate(world, rand, chunkX, chunkZ);
|
||||
}
|
||||
}
|
||||
|
||||
public void generate(World world, Random random, int varX, int varZ)
|
||||
{
|
||||
try
|
||||
{
|
||||
// TODO get the biome of the chunk and generate more gas in swamp biomes
|
||||
// chunk = world.getChunkFromChunkCoords(varX, varZ);
|
||||
for (int i = 0; i < this.amountPerChunk; i++)
|
||||
{
|
||||
int x = varX + random.nextInt(16);
|
||||
int z = varZ + random.nextInt(16);
|
||||
int y = random.nextInt(Math.max(this.maxGenerateLevel - this.minGenerateLevel, 0)) + this.minGenerateLevel;
|
||||
this.generateReplace(world, random, x, y, z);
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
System.out.println("[CoreMachine]Error generating natural gas");
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
public boolean generateReplace(World world, Random random, int par3, int par4, int par5)
|
||||
{
|
||||
float var6 = random.nextFloat() * (float) Math.PI;
|
||||
double var7 = par3 + 8 + MathHelper.sin(var6) * this.amountPerBranch / 8.0F;
|
||||
double var9 = par3 + 8 - MathHelper.sin(var6) * this.amountPerBranch / 8.0F;
|
||||
double var11 = par5 + 8 + MathHelper.cos(var6) * this.amountPerBranch / 8.0F;
|
||||
double var13 = par5 + 8 - MathHelper.cos(var6) * this.amountPerBranch / 8.0F;
|
||||
double var15 = par4 + random.nextInt(3) - 2;
|
||||
double var17 = par4 + random.nextInt(3) - 2;
|
||||
|
||||
for (int oreCount = 0; oreCount <= this.amountPerBranch; ++oreCount)
|
||||
{
|
||||
double var20 = var7 + (var9 - var7) * oreCount / this.amountPerBranch;
|
||||
double var22 = var15 + (var17 - var15) * oreCount / this.amountPerBranch;
|
||||
double var24 = var11 + (var13 - var11) * oreCount / this.amountPerBranch;
|
||||
double var26 = random.nextDouble() * this.amountPerBranch / 16.0D;
|
||||
double var28 = (MathHelper.sin(oreCount * (float) Math.PI / this.amountPerBranch) + 1.0F) * var26 + 1.0D;
|
||||
double var30 = (MathHelper.sin(oreCount * (float) Math.PI / this.amountPerBranch) + 1.0F) * var26 + 1.0D;
|
||||
int var32 = MathHelper.floor_double(var20 - var28 / 2.0D);
|
||||
int var33 = MathHelper.floor_double(var22 - var30 / 2.0D);
|
||||
int var34 = MathHelper.floor_double(var24 - var28 / 2.0D);
|
||||
int var35 = MathHelper.floor_double(var20 + var28 / 2.0D);
|
||||
int var36 = MathHelper.floor_double(var22 + var30 / 2.0D);
|
||||
int var37 = MathHelper.floor_double(var24 + var28 / 2.0D);
|
||||
|
||||
for (int x = var32; x <= var35; ++x)
|
||||
{
|
||||
double var39 = (x + 0.5D - var20) / (var28 / 2.0D);
|
||||
|
||||
if (var39 * var39 < 1.0D)
|
||||
{
|
||||
for (int y = var33; y <= var36; ++y)
|
||||
{
|
||||
double var42 = (y + 0.5D - var22) / (var30 / 2.0D);
|
||||
|
||||
if (var39 * var39 + var42 * var42 < 1.0D)
|
||||
{
|
||||
for (int z = var34; z <= var37; ++z)
|
||||
{
|
||||
double var45 = (z + 0.5D - var24) / (var28 / 2.0D);
|
||||
|
||||
int blockid = world.getBlockId(x, y, z);
|
||||
Block block = Block.blocksList[blockid];
|
||||
if (var39 * var39 + var42 * var42 + var45 * var45 < 1.0D && (block == null || block.isAirBlock(world, x, y, z) || block.canBeReplacedByLeaves(world, x, y, z) || blockid == this.replaceID))
|
||||
{
|
||||
world.setBlock(x, y, z, ResonantInduction.blockGas.blockID, 10 + world.rand.nextInt(5), 2);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
public boolean isOreGeneratedInWorld(World world, IChunkProvider chunkGenerator)
|
||||
{
|
||||
if (chunkGenerator instanceof ChunkProviderHell)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
if (chunkGenerator instanceof ChunkProviderEnd)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
|
@ -3,7 +3,6 @@ package resonantinduction.core.resource.fluid;
|
|||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.Configuration;
|
||||
import net.minecraftforge.fluids.BlockFluidFinite;
|
||||
import net.minecraftforge.fluids.Fluid;
|
||||
import net.minecraftforge.fluids.FluidContainerRegistry;
|
||||
|
|
|
@ -4,7 +4,6 @@ import net.minecraft.block.material.Material;
|
|||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.Configuration;
|
||||
import net.minecraftforge.fluids.BlockFluidFinite;
|
||||
import net.minecraftforge.fluids.Fluid;
|
||||
import net.minecraftforge.fluids.FluidContainerRegistry;
|
||||
|
|
Loading…
Add table
Reference in a new issue