A lot of import fixes

This commit is contained in:
Calclavia 2014-07-14 14:46:49 -04:00
parent 1890a56a8f
commit 020e13c7f8
225 changed files with 805 additions and 805 deletions

View file

@ -1,6 +1,5 @@
package resonantinduction.mechanical;
import mechanical.CommonProxy;
import resonantinduction.mechanical.render.MechanicalBlockRenderingHandler;
import cpw.mods.fml.client.registry.RenderingRegistry;

View file

@ -1,11 +1,10 @@
package resonantinduction.mechanical;
import mechanical.CommonProxy;
import net.minecraft.block.Block;
import resonantinduction.core.Reference;
import resonantinduction.core.ResonantInduction;
import resonantinduction.core.Settings;
import mechanical.belt.BlockConveyorBelt;
import resonantinduction.mechanical.belt.BlockConveyorBelt;
import resonantinduction.old.core.recipe.RecipeLoader;
import resonantinduction.old.transport.ResonantInductionTransport;
import calclavia.lib.network.PacketHandler;

View file

@ -3,8 +3,6 @@ package resonantinduction.mechanical.belt;
import java.util.List;
import java.util.Set;
import mechanical.belt.RenderConveyorBelt;
import mechanical.belt.TileConveyorBelt;
import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLiving;
@ -20,7 +18,7 @@ import net.minecraft.world.World;
import net.minecraftforge.common.Configuration;
import net.minecraftforge.common.ForgeDirection;
import resonantinduction.core.prefab.block.BlockMachine;
import mechanical.belt.TileConveyorBelt.SlantType;
import resonantinduction.mechanical.belt.TileConveyorBelt.SlantType;
import resonantinduction.mechanical.render.MechanicalBlockRenderingHandler;
import resonantinduction.old.client.render.RenderConveyorBelt;

View file

@ -8,7 +8,7 @@ import net.minecraft.world.IBlockAccess;
import org.lwjgl.opengl.GL11;
import resonantinduction.core.Reference;
import mechanical.Mechanical;
import resonantinduction.mechanical.Mechanical;
import resonantinduction.old.client.model.ModelConveyorBelt;
import resonantinduction.old.client.model.ModelCrusher;
import resonantinduction.old.client.model.ModelGrinder;

View file

@ -3,7 +3,7 @@ package resonantinduction.old.client.gui;
import net.minecraft.entity.player.InventoryPlayer;
import net.minecraft.inventory.Container;
import resonantinduction.core.prefab.tile.TileEntityMachine;
import mechanical.CommonProxy;
import resonantinduction.mechanical.CommonProxy;
import resonantinduction.old.transport.ResonantInductionTransport;
import dark.lib.prefab.invgui.ContainerFake;
import dark.lib.prefab.invgui.GuiMachineContainer;

View file

@ -55,7 +55,7 @@ public class BlockRenderHelper implements ISimpleBlockRenderingHandler
{
GL11.glTranslatef(0.0F, 1.5F, 0.0F);
GL11.glRotatef(180f, 0f, 0f, 1f);
FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation(Reference.DOMAIN, Reference.MODEL_DIRECTORY + "mechanical/GearRod.png"));
FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation(Reference.DOMAIN, Reference.MODEL_DIRECTORY + "resonantinduction/mechanical/GearRod.png"));
modelRod.render(0.0825F, 0);
}
else if (RecipeLoader.blockConPump != null && block.blockID == RecipeLoader.blockConPump.blockID && metadata < 4)

View file

@ -7,8 +7,8 @@ import net.minecraft.util.ResourceLocation;
import org.lwjgl.opengl.GL11;
import resonantinduction.core.Reference;
import mechanical.belt.TileConveyorBelt;
import mechanical.belt.TileConveyorBelt.SlantType;
import resonantinduction.mechanical.belt.TileConveyorBelt;
import resonantinduction.mechanical.belt.TileConveyorBelt.SlantType;
import resonantinduction.old.client.model.ModelAngledBelt;
import resonantinduction.old.client.model.ModelConveyorBelt;
import cpw.mods.fml.relauncher.Side;

View file

@ -21,7 +21,7 @@ public class RenderGearRod extends TileEntitySpecialRenderer
public void renderAModelAt(TileEntity tileEntity, double d, double d1, double d2, float f)
{
// bindTextureByName(FluidMech.MODEL_TEXTURE_DIRECTORY + "mechanical/GearRod.png");
// bindTextureByName(FluidMech.MODEL_TEXTURE_DIRECTORY + "resonantinduction.mechanical/GearRod.png");
GL11.glPushMatrix();
int meta = tileEntity.worldObj.getBlockMetadata(tileEntity.xCoord, tileEntity.yCoord, tileEntity.zCoord);

View file

@ -23,7 +23,7 @@ public class RenderGenerator extends TileEntitySpecialRenderer
@Override
public void renderTileEntityAt(TileEntity tileEntity, double d, double d1, double d2, float d3)
{
// bindTextureByName(FluidMech.MODEL_TEXTURE_DIRECTORY + "mechanical/Generator.png");
// bindTextureByName(FluidMech.MODEL_TEXTURE_DIRECTORY + "resonantinduction.mechanical/Generator.png");
GL11.glPushMatrix();
GL11.glTranslatef((float) d + 0.5F, (float) d1 + 1.45F, (float) d2 + 0.5F);
GL11.glScalef(1.0F, -1F, -1F);

View file

@ -14,7 +14,7 @@ import net.minecraft.world.World;
import net.minecraftforge.common.Configuration;
import net.minecraftforge.oredict.OreDictionary;
import resonantinduction.core.prefab.block.BlockMachine;
import mechanical.CommonProxy;
import resonantinduction.mechanical.CommonProxy;
import resonantinduction.old.client.render.MechanicalBlockRenderingHandler;
import resonantinduction.old.client.render.RenderProcessor;
import resonantinduction.old.transport.ResonantInductionTransport;

View file

@ -12,7 +12,7 @@ import net.minecraft.world.World;
import resonantinduction.core.Reference;
import resonantinduction.core.Settings;
import resonantinduction.core.prefab.block.BlockMachine;
import mechanical.CommonProxy;
import resonantinduction.mechanical.CommonProxy;
import resonantinduction.old.transport.ResonantInductionTransport;
import com.builtbroken.common.Pair;

View file

@ -1,2 +1,2 @@
rootProject.name = 'Resonant-Induction Core'
include 'archaic', 'mechanical', 'electrical', 'atomic'
include 'archaic', 'resonantinduction.mechanical', 'electrical', 'atomic'

View file

@ -1,86 +1,99 @@
package resonantinduction.archaic.blocks
import codechicken.multipart.TileMultipart
import cpw.mods.fml.relauncher.SideOnly
import net.minecraft.block.Block
import cpw.mods.fml.relauncher.{Side, SideOnly}
import net.minecraft.block.material.Material
import net.minecraft.client.renderer.texture.IconRegister
import net.minecraft.tileentity.TileEntity
import net.minecraft.util.Icon
import net.minecraft.world.IBlockAccess
import net.minecraft.world.World
import net.minecraftforge.common.ForgeDirection
import net.minecraft.client.renderer.texture.IIconRegister
import net.minecraft.util.IIcon
import net.minecraft.world.{IBlockAccess, World}
import net.minecraftforge.common.util.ForgeDirection
import resonant.api.IRotatable
import resonant.api.blocks.IRotatableBlock
import resonant.api.blocks.IRotatableBlock
import resonant.lib.content.module.TileBlock
import resonant.lib.content.module.TileRender
import resonant.lib.render.RotatedTextureRenderer
import resonant.content.prefab.RenderRotatedTexture
import resonant.content.spatial.block.SpatialBlock
import resonant.lib.content.prefab.TRotatable
import resonantinduction.core.Reference
import universalelectricity.api.vector.Vector3
import cpw.mods.fml.relauncher.Side
import universalelectricity.core.transform.vector.Vector3
class TileTurntable extends TileBlock(Material.piston) with IRotatable {
object TileTurntable
{
var top: IIcon = null
}
class TileTurntable extends SpatialBlock(Material.piston) with TRotatable with RenderRotatedTexture
{
textureName = "turntable_side"
tickRandomly = true
rotationMask = Integer.parseInt("111111", 2).toByte
override def tickRate(par1World: World): Int =
{
return 5
}
override def tickRate(par1World: World): Int = 5
@SideOnly(Side.CLIENT) override def registerIcons(iconReg: IconRegister) {
@SideOnly(Side.CLIENT)
override def registerIcons(iconReg: IIconRegister)
{
super.registerIcons(iconReg)
TileTurntable.top = iconReg.registerIcon(Reference.PREFIX + "turntable")
}
override def updateEntity() {
override def updateEntity()
{
updateTurntableState(world, x, y, z)
}
@SideOnly(Side.CLIENT) override def getIcon(access: IBlockAccess, side: Int): Icon =
@SideOnly(Side.CLIENT)
override def getIcon(access: IBlockAccess, side: Int): IIcon =
{
if (side == metadata)
{
if (side == super.metadata()) {
return TileTurntable.top
}
return getIcon
}
@SideOnly(Side.CLIENT) override def getIcon(side: Int, meta: Int): Icon =
@SideOnly(Side.CLIENT)
override def getIcon(side: Int, meta: Int): IIcon =
{
if (side == 1)
{
if (side == 1) {
return TileTurntable.top
}
return getIcon
}
override def onNeighborChanged() {
scheduelTick(10)
override def onNeighborChanged()
{
scheduleTick(10)
}
private def updateTurntableState(world: World, x: Int, y: Int, z: Int) {
if (world.isBlockIndirectlyGettingPowered(x, y, z)) {
try {
private def updateTurntableState(world: World, x: Int, y: Int, z: Int)
{
if (world.isBlockIndirectlyGettingPowered(x, y, z))
{
try
{
val facing: ForgeDirection = ForgeDirection.getOrientation(world.getBlockMetadata(x, y, z))
val position: Vector3 = new Vector3(x, y, z).translate(facing)
val tileEntity: TileEntity = position.getTileEntity(world)
val block: Block = Block.blocksList(position.getBlockID(world))
if (!(tileEntity.isInstanceOf[TileMultipart])) {
if (tileEntity.isInstanceOf[IRotatable]) {
val blockRotation: ForgeDirection = (tileEntity.asInstanceOf[IRotatable]).getDirection
(tileEntity.asInstanceOf[IRotatable]).setDirection(blockRotation.getRotation(facing.getOpposite))
} else if (block.isInstanceOf[IRotatableBlock]) {
val blockRotation: ForgeDirection = (block.asInstanceOf[IRotatableBlock]).getDirection(world, position.intX, position.intY, position.intZ)
(block.asInstanceOf[IRotatableBlock]).setDirection(world, position.intX, position.intY, position.intZ, blockRotation.getRotation(facing.getOpposite))
} else if (block != null) {
Block.blocksList(blockID).rotateBlock(world, position.intX, position.intY, position.intZ, facing.getOpposite)
val position = new Vector3(x, y, z) + facing
val tileEntity = position.getTileEntity(world)
val block = position.getBlock(world)
if (!(tileEntity.isInstanceOf[TileMultipart]))
{
if (tileEntity.isInstanceOf[IRotatable])
{
val blockRotation = tileEntity.asInstanceOf[IRotatable].getDirection
tileEntity.asInstanceOf[IRotatable].setDirection(blockRotation.getRotation(facing.getOpposite))
}
else if (block != null)
{
block.rotateBlock(world, position.intX, position.intY, position.intZ, facing.getOpposite)
}
world.markBlockForUpdate(position.intX, position.intY, position.intZ)
world.playSoundEffect(x + 0.5D, y + 0.5D, z + 0.5D, "tile.piston.in", 0.5F, world.rand.nextFloat * 0.15F + 0.6F)
}
} catch {
}
catch
{
case e: Exception =>
{
System.out.println("Error while rotating a block near " + x + "x " + y + "y " + z + "z " + (if (world != null && world.provider != null) world.provider.dimensionId + "d" else "null:world"))
@ -89,13 +102,4 @@ class TileTurntable extends TileBlock(Material.piston) with IRotatable {
}
}
}
@SideOnly(Side.CLIENT) protected override def newRenderer: TileRender =
{
return new RotatedTextureRenderer(this)
}
}
object TileTurntable {
var top: Icon = null
}

View file

@ -3,7 +3,7 @@ package resonantinduction.archaic.crate;
import java.util.ArrayList;
import java.util.List;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.entity.item.EntityItem;
import net.minecraft.entity.player.EntityPlayer;
@ -11,7 +11,7 @@ import net.minecraft.entity.player.EntityPlayerMP;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.ChatMessageComponent;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import net.minecraft.world.World;
import net.minecraftforge.oredict.OreDictionary;
import resonant.lib.prefab.block.BlockTile;
@ -31,7 +31,7 @@ import cpw.mods.fml.relauncher.SideOnly;
* @author DarkGuardsman */
public class BlockCrate extends BlockTile
{
Icon advanced, elite;
IIcon advanced, elite;
public BlockCrate(int id)
{
@ -40,7 +40,7 @@ public class BlockCrate extends BlockTile
@SideOnly(Side.CLIENT)
@Override
public void registerIcons(IconRegister iconReg)
public void registerIcons(IIconRegister iconReg)
{
this.blockIcon = iconReg.registerIcon(Reference.PREFIX + "crate_wood");
this.advanced = iconReg.registerIcon(Reference.PREFIX + "crate_iron");
@ -49,7 +49,7 @@ public class BlockCrate extends BlockTile
@Override
@SideOnly(Side.CLIENT)
public Icon getIcon(int side, int meta)
public IIcon getIcon(int side, int meta)
{
if (meta == 1)
{

View file

@ -4,8 +4,8 @@ import java.util.ArrayList;
import java.util.List;
import net.minecraft.tileentity.TileEntity;
import net.minecraftforge.common.ForgeDirection;
import universalelectricity.api.vector.Vector3;
import net.minecraftforge.common.util.ForgeDirection;
import universalelectricity.core.transform.vector.Vector3;
import universalelectricity.api.vector.VectorHelper;
/**

View file

@ -9,7 +9,7 @@ import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.network.packet.Packet;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.oredict.OreDictionary;
import resonant.api.IExtendedStorage;
import resonant.api.IFilterable;

View file

@ -4,7 +4,7 @@ import java.util.ArrayList;
import java.util.Set;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.entity.player.EntityPlayerMP;
import net.minecraft.entity.player.InventoryPlayer;
@ -17,8 +17,8 @@ import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.nbt.NBTTagList;
import net.minecraft.network.packet.Packet;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.Icon;
import net.minecraftforge.common.ForgeDirection;
import net.minecraft.util.IIcon;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.oredict.OreDictionary;
import org.apache.commons.lang3.ArrayUtils;
@ -47,7 +47,7 @@ import resonantinduction.core.ResonantInduction;
import resonantinduction.core.ResonantInduction.RecipeType;
import resonantinduction.core.prefab.imprint.ItemImprint;
import universalelectricity.api.vector.Vector2;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import codechicken.multipart.ControlKeyModifer;
import com.google.common.io.ByteArrayDataInput;
@ -87,7 +87,7 @@ public class TileEngineeringTable extends TileInventory implements IPacketReceiv
private int[] playerSlots;
@SideOnly(Side.CLIENT)
private static Icon iconTop, iconFront, iconSide;
private static IIcon iconTop, iconFront, iconSide;
public TileEngineeringTable()
{
@ -100,14 +100,14 @@ public class TileEngineeringTable extends TileInventory implements IPacketReceiv
@Override
@SideOnly(Side.CLIENT)
public Icon getIcon(int side, int meta)
public IIcon getIcon(int side, int meta)
{
return side == 1 ? iconTop : (side == meta ? iconFront : iconSide);
}
@Override
@SideOnly(Side.CLIENT)
public void registerIcons(IconRegister iconRegister)
public void registerIcons(IIconRegister iconRegister)
{
iconTop = iconRegister.registerIcon(getTextureName() + "_top");
iconFront = iconRegister.registerIcon(getTextureName() + "_front");
@ -184,9 +184,9 @@ public class TileEngineeringTable extends TileInventory implements IPacketReceiv
final double regionLength = 1d / 3d;
// Rotate the hit vector based on direction of the tile.
hitVector.translate(new Vector3(-0.5, 0, -0.5));
hitVector.add(new Vector3(-0.5, 0, -0.5));
hitVector.rotate(WorldUtility.getAngleFromForgeDirection(getDirection()), Vector3.UP());
hitVector.translate(new Vector3(0.5, 0, 0.5));
hitVector.add(new Vector3(0.5, 0, 0.5));
/** Crafting Matrix */
matrix:
@ -364,7 +364,7 @@ public class TileEngineeringTable extends TileInventory implements IPacketReceiv
for (ForgeDirection dir : ForgeDirection.VALID_DIRECTIONS)
{
TileEntity tile = new Vector3(this).translate(dir).getTileEntity(worldObj);
TileEntity tile = new Vector3(this).add(dir).getTileEntity(worldObj);
if (tile instanceof IInventory)
{
@ -440,7 +440,7 @@ public class TileEngineeringTable extends TileInventory implements IPacketReceiv
for (ForgeDirection dir : ForgeDirection.VALID_DIRECTIONS)
{
TileEntity tile = new Vector3(this).translate(dir).getTileEntity(worldObj);
TileEntity tile = new Vector3(this).add(dir).getTileEntity(worldObj);
if (tile instanceof IInventory)
{
@ -736,7 +736,7 @@ public class TileEngineeringTable extends TileInventory implements IPacketReceiv
for (ForgeDirection dir : ForgeDirection.VALID_DIRECTIONS)
{
TileEntity tile = new Vector3(this).translate(dir).getTileEntity(worldObj);
TileEntity tile = new Vector3(this).add(dir).getTileEntity(worldObj);
if (tile instanceof IInventory)
{

View file

@ -1,21 +1,21 @@
package resonantinduction.archaic.filter;
import net.minecraft.block.Block;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.lib.prefab.block.BlockTile;
import resonant.lib.utility.inventory.InventoryUtility;
import resonantinduction.core.Reference;
import resonantinduction.core.prefab.imprint.ItemImprint;
import universalelectricity.api.UniversalElectricity;
import universalelectricity.api.vector.Vector2;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import universalelectricity.api.vector.VectorWorld;
import codechicken.multipart.ControlKeyModifer;
import cpw.mods.fml.relauncher.Side;
@ -23,9 +23,9 @@ import cpw.mods.fml.relauncher.SideOnly;
public class BlockImprinter extends BlockTile
{
Icon imprinter_side;
Icon imprinter_top;
Icon imprinter_bottom;
IIcon imprinter_side;
IIcon imprinter_top;
IIcon imprinter_bottom;
public BlockImprinter(int id)
{
@ -34,7 +34,7 @@ public class BlockImprinter extends BlockTile
@SideOnly(Side.CLIENT)
@Override
public void registerIcons(IconRegister iconReg)
public void registerIcons(IIconRegister iconReg)
{
this.imprinter_side = iconReg.registerIcon(Reference.PREFIX + "imprinter_side");
this.imprinter_top = iconReg.registerIcon(Reference.PREFIX + "imprinter_top");
@ -43,7 +43,7 @@ public class BlockImprinter extends BlockTile
@Override
@SideOnly(Side.CLIENT)
public Icon getBlockTexture(IBlockAccess world, int x, int y, int z, int side)
public IIcon getBlockTexture(IBlockAccess world, int x, int y, int z, int side)
{
return getIcon(side, 0);
}
@ -51,7 +51,7 @@ public class BlockImprinter extends BlockTile
/** Returns the block texture based on the side being looked at. Args: side */
@Override
@SideOnly(Side.CLIENT)
public Icon getIcon(int side, int meta)
public IIcon getIcon(int side, int meta)
{
if (side == 1)
{
@ -75,7 +75,7 @@ public class BlockImprinter extends BlockTile
if (te instanceof TileImprinter)
{
TileImprinter tile = (TileImprinter) te;
int idOnTop = ((VectorWorld) new VectorWorld(world, x, y, z).translate(ForgeDirection.getOrientation(1))).getBlockID();
int idOnTop = ((VectorWorld) new VectorWorld(world, x, y, z).add(ForgeDirection.getOrientation(1))).getBlock();
if (Block.pistonMoving.blockID == blockID)
{

View file

@ -3,7 +3,7 @@ package resonantinduction.archaic.filter;
import net.minecraft.client.renderer.RenderBlocks;
import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
import net.minecraft.tileentity.TileEntity;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.lib.render.RenderItemOverlayUtility;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;

View file

@ -10,7 +10,7 @@ import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.network.packet.Packet;
import net.minecraft.world.IBlockAccess;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.FluidRegistry;
import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.IFluidHandler;
@ -31,7 +31,7 @@ import resonantinduction.core.prefab.imprint.ItemImprint;
import resonantinduction.core.prefab.imprint.TileFilterable;
import resonantinduction.core.resource.ResourceGenerator;
import resonantinduction.core.resource.fluid.BlockFluidMixture;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@ -81,10 +81,10 @@ public class TileFilter extends TileFilterable implements IFilterable
/** Fluid filters */
Vector3 position = new Vector3(this);
Vector3 checkAbove = position.clone().translate(ForgeDirection.UP);
Vector3 checkBelow = position.clone().translate(ForgeDirection.DOWN);
Vector3 checkAbove = position.clone().add(ForgeDirection.UP);
Vector3 checkBelow = position.clone().add(ForgeDirection.DOWN);
Block bAbove = Block.blocksList[checkAbove.getBlockID(worldObj)];
Block bAbove = Block.blocksList[checkAbove.getBlock(worldObj)];
if (bAbove instanceof BlockFluidMixture && worldObj.isAirBlock(checkBelow.intX(), checkBelow.intY(), checkBelow.intZ()))
{

View file

@ -5,12 +5,12 @@ import java.util.Random;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import resonant.lib.prefab.block.BlockTile;
@ -21,15 +21,15 @@ import cpw.mods.fml.relauncher.SideOnly;
public class BlockFirebox extends BlockTile
{
private Icon topOn;
private Icon topOff;
private Icon sideOn;
private Icon sideOff;
private IIcon topOn;
private IIcon topOff;
private IIcon sideOn;
private IIcon sideOff;
private Icon topElectricOn;
private Icon topElectricOff;
private Icon sideOnElectric;
private Icon sideOffElectric;
private IIcon topElectricOn;
private IIcon topElectricOff;
private IIcon sideOnElectric;
private IIcon sideOffElectric;
public BlockFirebox(int id)
{
@ -40,7 +40,7 @@ public class BlockFirebox extends BlockTile
@Override
@SideOnly(Side.CLIENT)
public void registerIcons(IconRegister iconReg)
public void registerIcons(IIconRegister iconReg)
{
super.registerIcons(iconReg);
sideOn = iconReg.registerIcon(Reference.PREFIX + "firebox_side_on");
@ -88,7 +88,7 @@ public class BlockFirebox extends BlockTile
}
@Override
public Icon getBlockTexture(IBlockAccess access, int x, int y, int z, int side)
public IIcon getBlockTexture(IBlockAccess access, int x, int y, int z, int side)
{
if (side == 0)
return blockIcon;
@ -112,7 +112,7 @@ public class BlockFirebox extends BlockTile
@Override
@SideOnly(Side.CLIENT)
public Icon getIcon(int side, int meta)
public IIcon getIcon(int side, int meta)
{
if (side == 0)
return blockIcon;

View file

@ -3,23 +3,23 @@ package resonantinduction.archaic.firebox;
import java.util.Random;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.Entity;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.DamageSource;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import net.minecraft.world.World;
import resonant.lib.prefab.block.BlockTile;
import resonantinduction.core.Reference;
import universalelectricity.api.vector.Vector2;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class BlockHotPlate extends BlockTile
{
private Icon topElectric;
private IIcon topElectric;
public BlockHotPlate(int id)
{
@ -42,7 +42,7 @@ public class BlockHotPlate extends BlockTile
@Override
@SideOnly(Side.CLIENT)
public void registerIcons(IconRegister iconReg)
public void registerIcons(IIconRegister iconReg)
{
super.registerIcons(iconReg);
topElectric = iconReg.registerIcon(Reference.PREFIX + "electricHotPlate");
@ -50,7 +50,7 @@ public class BlockHotPlate extends BlockTile
@Override
@SideOnly(Side.CLIENT)
public Icon getIcon(int side, int meta)
public IIcon getIcon(int side, int meta)
{
return meta == 1 ? topElectric : blockIcon;
}
@ -131,12 +131,12 @@ public class BlockHotPlate extends BlockTile
for (int spawn = 0; spawn < maxParticles; spawn++)
{
Vector3 particlePosition = new Vector3(x, y, z).translate((double) (i / 2) / ((double) 2) + (0.5 / (2)), 0.2, (double) (i % 2) / ((double) 2) + (0.5 / (2)));
particlePosition.translate(new Vector3((random.nextFloat() - 0.5) * 0.2, (random.nextFloat() - 0.5) * 0.2, (random.nextFloat() - 0.5) * 0.2));
Vector3 particlePosition = new Vector3(x, y, z).add((double) (i / 2) / ((double) 2) + (0.5 / (2)), 0.2, (double) (i % 2) / ((double) 2) + (0.5 / (2)));
particlePosition.add(new Vector3((random.nextFloat() - 0.5) * 0.2, (random.nextFloat() - 0.5) * 0.2, (random.nextFloat() - 0.5) * 0.2));
world.spawnParticle("smoke", particlePosition.x, particlePosition.y, particlePosition.z, 0.0D, 0.0D, 0.0D);
}
Vector3 particlePosition = new Vector3(x, y, z).translate((double) (i / 2) / ((double) 2) + (0.5 / (2)), 0.2, (double) (i % 2) / ((double) 2) + (0.5 / (2)));
Vector3 particlePosition = new Vector3(x, y, z).add((double) (i / 2) / ((double) 2) + (0.5 / (2)), 0.2, (double) (i % 2) / ((double) 2) + (0.5 / (2)));
world.spawnParticle("flame", particlePosition.x, particlePosition.y, particlePosition.z, 0.0D, 0.01D, 0.0D);
}
}

View file

@ -3,7 +3,7 @@ package resonantinduction.archaic.firebox;
import net.minecraft.client.renderer.RenderBlocks;
import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
import net.minecraft.tileentity.TileEntity;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.lib.render.RenderItemOverlayUtility;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;

View file

@ -9,7 +9,7 @@ import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.network.packet.Packet;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.tileentity.TileEntityFurnace;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.common.MinecraftForge;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidContainerRegistry;
@ -31,7 +31,7 @@ import resonantinduction.core.ResonantInduction;
import resonantinduction.core.resource.ResourceGenerator;
import resonantinduction.core.resource.TileMaterial;
import universalelectricity.api.energy.EnergyStorageHandler;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import com.google.common.io.ByteArrayDataInput;
@ -154,7 +154,7 @@ public class TileFirebox extends TileElectricalInventory implements IPacketRecei
{
if (FluidRegistry.getFluid("steam") != null)
{
MinecraftForge.EVENT_BUS.post(new BoilEvent(worldObj, new Vector3(this).translate(0, 1, 0), new FluidStack(FluidRegistry.WATER, volume), new FluidStack(FluidRegistry.getFluid("steam"), volume), 2, false));
MinecraftForge.EVENT_BUS.post(new BoilEvent(worldObj, new Vector3(this).add(0, 1, 0), new FluidStack(FluidRegistry.WATER, volume), new FluidStack(FluidRegistry.getFluid("steam"), volume), 2, false));
boiledVolume += volume;
}
@ -179,7 +179,7 @@ public class TileFirebox extends TileElectricalInventory implements IPacketRecei
{
if (FluidRegistry.getFluid("steam") != null)
{
MinecraftForge.EVENT_BUS.post(new BoilEvent(worldObj, new Vector3(this).translate(0, 1, 0), new FluidStack(FluidRegistry.WATER, volume), new FluidStack(FluidRegistry.getFluid("steam"), volume), 2, false));
MinecraftForge.EVENT_BUS.post(new BoilEvent(worldObj, new Vector3(this).add(0, 1, 0), new FluidStack(FluidRegistry.WATER, volume), new FluidStack(FluidRegistry.getFluid("steam"), volume), 2, false));
((TileGutter) tileEntity).drain(ForgeDirection.DOWN, volume, true);
}

View file

@ -6,12 +6,12 @@ import java.util.HashMap;
import java.util.PriorityQueue;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import net.minecraft.world.IBlockAccess;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidContainerRegistry;
import net.minecraftforge.fluids.FluidRegistry;
@ -23,7 +23,7 @@ import resonant.lib.utility.FluidUtility;
import resonantinduction.core.Reference;
import resonantinduction.core.grid.fluid.FluidPressureNode;
import resonantinduction.core.grid.fluid.TilePressureNode;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@ -35,7 +35,7 @@ public class TileGrate extends TilePressureNode implements IRotatable
private static double grateDrainSpeedMultiplier = 0.01;
@SideOnly(Side.CLIENT)
private static Icon iconFront, iconSide;
private static IIcon iconFront, iconSide;
private GratePathfinder gratePath;
@ -52,20 +52,20 @@ public class TileGrate extends TilePressureNode implements IRotatable
}
@Override
public Icon getIcon(IBlockAccess world, int side)
public IIcon getIcon(IBlockAccess world, int side)
{
return side == getDirection().ordinal() ? iconFront : iconSide;
}
@Override
public Icon getIcon(int side, int metadata)
public IIcon getIcon(int side, int metadata)
{
return side == 1 ? iconFront : iconSide;
}
@Override
@SideOnly(Side.CLIENT)
public void registerIcons(IconRegister iconRegister)
public void registerIcons(IIconRegister iconRegister)
{
iconFront = iconRegister.registerIcon(Reference.PREFIX + "grate_front");
iconSide = iconRegister.registerIcon(Reference.PREFIX + "grate");
@ -317,7 +317,7 @@ public class TileGrate extends TilePressureNode implements IRotatable
if (dir == TileGrate.this.getDirection())
{
Vector3 check = start.clone().translate(dir);
Vector3 check = start.clone().add(dir);
this.navigationMap.put(check, start);
this.workingNodes.add(new TileGrate.ComparableVector(check, 0));
}
@ -380,7 +380,7 @@ public class TileGrate extends TilePressureNode implements IRotatable
{
for (int i = 0; i < 6; i++)
{
Vector3 newPosition = next.position.clone().translate(ForgeDirection.getOrientation(i));
Vector3 newPosition = next.position.clone().add(ForgeDirection.getOrientation(i));
if (!this.navigationMap.containsKey(newPosition) && !(!fillOver && newPosition.intY() > y()))
{
@ -401,7 +401,7 @@ public class TileGrate extends TilePressureNode implements IRotatable
if (dir == TileGrate.this.getDirection())
{
Vector3 check = start.clone().translate(dir);
Vector3 check = start.clone().add(dir);
this.navigationMap.put(check, start);
this.workingNodes.add(new ComparableVector(check, 0));
fluidType = FluidUtility.getFluidFromBlock(TileGrate.this.worldObj, check);
@ -450,7 +450,7 @@ public class TileGrate extends TilePressureNode implements IRotatable
{
for (int i = 0; i < 6; i++)
{
Vector3 check = next.position.clone().translate(ForgeDirection.getOrientation(i));
Vector3 check = next.position.clone().add(ForgeDirection.getOrientation(i));
Fluid checkFluid = FluidUtility.getFluidFromBlock(TileGrate.this.worldObj, check);
if (checkFluid != null && fluidType.getID() == checkFluid.getID())

View file

@ -1,6 +1,6 @@
package resonantinduction.archaic.fluid.gutter;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonantinduction.core.grid.fluid.FluidPressureNode;
import resonantinduction.core.grid.fluid.IPressureNodeProvider;

View file

@ -13,7 +13,7 @@ import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.ResourceLocation;
import net.minecraftforge.client.model.AdvancedModelLoader;
import net.minecraftforge.client.model.IModelCustom;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidRegistry;
import net.minecraftforge.fluids.FluidStack;
@ -38,7 +38,7 @@ import resonantinduction.core.ResonantInduction.RecipeType;
import resonantinduction.core.grid.fluid.FluidPressureNode;
import resonantinduction.core.grid.fluid.IPressureNodeProvider;
import resonantinduction.core.grid.fluid.TilePressureNode;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@ -68,7 +68,7 @@ public class TileGutter extends TilePressureNode
for (ForgeDirection dir : ForgeDirection.VALID_DIRECTIONS)
{
TileEntity tile = position().translate(dir).getTileEntity(world());
TileEntity tile = position().add(dir).getTileEntity(world());
if (tile instanceof IFluidHandler)
{
@ -116,7 +116,7 @@ public class TileGutter extends TilePressureNode
if (!this.world().isRemote && this.ticks % 20 == 0)
{
/** Drain block above if it is a fluid. */
Vector3 drainPos = position().translate(0, 1, 0);
Vector3 drainPos = position().add(0, 1, 0);
FluidStack drain = FluidUtility.drainBlock(worldObj, drainPos, false);
if (drain != null)
@ -200,7 +200,7 @@ public class TileGutter extends TilePressureNode
{
ForgeDirection dir = ForgeDirection.getOrientation(i);
int pressure = node.getPressure(dir);
Vector3 position = position().translate(dir);
Vector3 position = position().add(dir);
TileEntity checkTile = position.getTileEntity(world());

View file

@ -11,7 +11,7 @@ import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.world.IBlockAccess;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.FluidContainerRegistry;
import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.FluidTank;
@ -20,7 +20,7 @@ import org.lwjgl.opengl.GL11;
import resonant.api.IRemovable.ISneakPickup;
import resonant.api.items.ISimpleItemRenderer;
import resonant.lib.content.module.TileBlock.IComparatorInputOverride;
import resonant.content.spatial.block.SpatialBlock.IComparatorInputOverride;
import resonant.lib.content.module.TileRender;
import resonant.lib.render.FluidRenderUtility;
import resonant.lib.render.RenderUtility;
@ -33,7 +33,7 @@ import resonantinduction.core.grid.fluid.FluidDistributionetwork;
import resonantinduction.core.grid.fluid.IFluidDistribution;
import resonantinduction.core.grid.fluid.TileFluidDistribution;
import universalelectricity.api.UniversalElectricity;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;

View file

@ -9,7 +9,7 @@ import resonant.lib.prefab.block.BlockTile;
import resonant.lib.render.block.BlockRenderingHandler;
import resonant.lib.utility.inventory.InventoryUtility;
import resonantinduction.core.Reference;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;

View file

@ -1,24 +1,24 @@
package resonantinduction.archaic.process;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import resonant.lib.prefab.block.BlockTile;
import resonant.lib.utility.inventory.InventoryUtility;
import resonantinduction.core.Reference;
import resonantinduction.core.resource.ItemHandCrank;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class BlockMillstone extends BlockTile
{
Icon top;
IIcon top;
public BlockMillstone(int id)
{
@ -28,7 +28,7 @@ public class BlockMillstone extends BlockTile
@SideOnly(Side.CLIENT)
@Override
public void registerIcons(IconRegister iconReg)
public void registerIcons(IIconRegister iconReg)
{
this.top = iconReg.registerIcon(Reference.PREFIX + "millstone_top");
super.registerIcons(iconReg);
@ -36,7 +36,7 @@ public class BlockMillstone extends BlockTile
@Override
@SideOnly(Side.CLIENT)
public Icon getBlockTexture(IBlockAccess world, int x, int y, int z, int side)
public IIcon getBlockTexture(IBlockAccess world, int x, int y, int z, int side)
{
return getIcon(side, 0);
}
@ -44,7 +44,7 @@ public class BlockMillstone extends BlockTile
/** Returns the block texture based on the side being looked at. Args: side */
@Override
@SideOnly(Side.CLIENT)
public Icon getIcon(int side, int meta)
public IIcon getIcon(int side, int meta)
{
if (side == 0 || side == 1)
{

View file

@ -3,7 +3,7 @@ package resonantinduction.archaic.process;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.network.packet.Packet;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidContainerRegistry;
import net.minecraftforge.fluids.FluidStack;
@ -18,7 +18,7 @@ import resonant.lib.prefab.tile.TileExternalInventory;
import resonant.lib.utility.FluidUtility;
import resonantinduction.core.ResonantInduction;
import resonantinduction.core.ResonantInduction.RecipeType;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import com.google.common.io.ByteArrayDataInput;
@ -78,7 +78,7 @@ public class TileCastingMold extends TileExternalInventory implements IFluidHand
/**
* Check blocks above for fluid.
*/
Vector3 checkPos = new Vector3(this).translate(0, 1, 0);
Vector3 checkPos = new Vector3(this).add(0, 1, 0);
FluidStack drainStack = FluidUtility.drainBlock(worldObj, checkPos, false);
if (MachineRecipes.INSTANCE.getOutput(RecipeType.SMELTER.name(), drainStack).length > 0)

View file

@ -4,7 +4,7 @@ import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.network.packet.Packet;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.api.recipe.MachineRecipes;
import resonant.api.recipe.RecipeResource;
import resonant.lib.network.IPacketReceiver;
@ -13,7 +13,7 @@ import resonant.lib.prefab.tile.TileExternalInventory;
import resonant.lib.utility.inventory.InventoryUtility;
import resonantinduction.core.ResonantInduction;
import resonantinduction.core.ResonantInduction.RecipeType;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import com.google.common.io.ByteArrayDataInput;

View file

@ -116,7 +116,7 @@ import resonantinduction.core.Reference;
import resonantinduction.core.ResonantInduction;
import resonantinduction.core.Settings;
import resonantinduction.core.TabRI;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import universalelectricity.api.vector.VectorWorld;
import cpw.mods.fml.common.Loader;
import cpw.mods.fml.common.Mod;
@ -651,7 +651,7 @@ public class Atomic
public void thermalEventHandler(EventThermalUpdate evt)
{
VectorWorld pos = evt.position;
Block block = Block.blocksList[pos.getBlockID()];
Block block = Block.blocksList[pos.getBlock()];
if (block == blockElectromagnet)
{
@ -664,7 +664,7 @@ public class Atomic
{
World world = evt.world;
Vector3 position = new Vector3(evt.x, evt.y, evt.z);
int blockID = position.getBlockID(world);
int blockID = position.getBlock(world);
Block block = Block.blocksList[blockID];
@ -733,7 +733,7 @@ public class Atomic
if (!evt.world.isRemote && evt.target != null && evt.target.typeOfHit == EnumMovingObjectType.TILE)
{
Vector3 blockPos = new Vector3(evt.target);
int blockID = blockPos.getBlockID(evt.world);
int blockID = blockPos.getBlock(evt.world);
if (blockID == blockToxicWaste.blockID)
{

View file

@ -10,7 +10,7 @@ import net.minecraft.world.World;
import net.minecraftforge.fluids.BlockFluidClassic;
import net.minecraftforge.fluids.FluidRegistry;
import resonant.lib.prefab.poison.PoisonRadiation;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
public class BlockToxicWaste extends BlockFluidClassic
{

View file

@ -3,7 +3,7 @@ package resonantinduction.atomic.blocks;
import java.util.Random;
import net.minecraft.block.material.Material;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import net.minecraft.world.World;
import resonant.lib.prefab.block.BlockRadioactive;
import resonantinduction.core.Reference;
@ -43,7 +43,7 @@ public class BlockUraniumOre extends BlockRadioactive
}
@Override
public Icon getIcon(int side, int metadata)
public IIcon getIcon(int side, int metadata)
{
return this.blockIcon;
}

View file

@ -2,10 +2,10 @@ package resonantinduction.atomic.blocks;
import java.util.List;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.item.ItemStack;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import net.minecraft.world.IBlockAccess;
import resonant.api.IElectromagnet;
import resonant.lib.content.module.TileBase;
@ -20,7 +20,7 @@ import cpw.mods.fml.relauncher.SideOnly;
/** Electromagnet block */
public class TileElectromagnet extends TileBase implements IElectromagnet
{
private static Icon iconTop, iconGlass;
private static IIcon iconTop, iconGlass;
public TileElectromagnet()
{
@ -31,7 +31,7 @@ public class TileElectromagnet extends TileBase implements IElectromagnet
}
@Override
public Icon getIcon(int side, int metadata)
public IIcon getIcon(int side, int metadata)
{
if (metadata == 1)
{
@ -48,7 +48,7 @@ public class TileElectromagnet extends TileBase implements IElectromagnet
@SideOnly(Side.CLIENT)
@Override
public void registerIcons(IconRegister iconRegister)
public void registerIcons(IIconRegister iconRegister)
{
super.registerIcons(iconRegister);
iconTop = iconRegister.registerIcon(domain + textureName + "_top");

View file

@ -2,14 +2,14 @@ package resonantinduction.atomic.blocks;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.world.World;
import net.minecraftforge.common.ForgeDirection;
import resonant.lib.content.module.TileBlock;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.content.spatial.block.SpatialBlock;
import resonantinduction.core.Reference;
import universalelectricity.api.UniversalElectricity;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
/** Siren block */
public class TileSiren extends TileBlock
public class TileSiren extends SpatialBlock
{
public TileSiren()
{
@ -41,8 +41,8 @@ public class TileSiren extends TileBlock
float volume = 0.5f;
for (int i = 0; i < 6; i++)
{
Vector3 check = position().translate(ForgeDirection.getOrientation(i));
if (check.getBlockID(world) == blockID())
Vector3 check = position().add(ForgeDirection.getOrientation(i));
if (check.getBlock(world) == blockID())
{
volume *= 1.5f;
}

View file

@ -1,4 +1,4 @@
package resonantinduction.quantum.gate;
package resonantinduction.atomic.gate;
import net.minecraft.entity.Entity;
import net.minecraft.inventory.ISidedInventory;

View file

@ -1,4 +1,4 @@
package resonantinduction.quantum.gate;
package resonantinduction.atomic.gate;
import java.util.List;

View file

@ -1,4 +1,4 @@
package resonantinduction.quantum.gate;
package resonantinduction.atomic.gate;
import java.util.ArrayList;
import java.util.Arrays;
@ -12,7 +12,7 @@ import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.MovingObjectPosition;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidContainerRegistry;
import net.minecraftforge.fluids.FluidStack;
@ -114,7 +114,7 @@ public class PartQuantumGlyph extends JCuboidPart implements TSlottedPart, JNorm
if (gates.size() > 0)
{
IQuantumGate gate = gates.get(gates.size() > 1 ? entity.worldObj.rand.nextInt(gates.size() - 1) : 0);
VectorWorld position = new VectorWorld((TileEntity) gate).translate(0.5, 2, 0.5);
VectorWorld position = new VectorWorld((TileEntity) gate).add(0.5, 2, 0.5);
if (QuantumGateManager.moveEntity(entity, position))
world().playSoundAtEntity(entity, "mob.endermen.portal", 1.0F, 1.0F);
}
@ -137,8 +137,8 @@ public class PartQuantumGlyph extends JCuboidPart implements TSlottedPart, JNorm
{
float deviation = 1;
// Spawn particle effects.
universalelectricity.api.vector.Vector3 center = new universalelectricity.api.vector.Vector3(x() + 0.5, y() + 0.5, z() + 0.5);
Electrical.proxy.renderElectricShock(world(), center, center.clone().translate(Math.random() * deviation - deviation / 2, Math.random() * deviation - deviation / 2, Math.random() * deviation - deviation / 2));
universalelectricity.core.transform.vector.Vector3 center = new universalelectricity.core.transform.vector.Vector3(x() + 0.5, y() + 0.5, z() + 0.5);
Electrical.proxy.renderElectricShock(world(), center, center.clone().add(Math.random() * deviation - deviation / 2, Math.random() * deviation - deviation / 2, Math.random() * deviation - deviation / 2));
}
}
}

View file

@ -1,4 +1,4 @@
package resonantinduction.quantum.gate;
package resonantinduction.atomic.gate;
import java.util.HashMap;

View file

@ -1,4 +1,4 @@
package resonantinduction.quantum.gate;
package resonantinduction.atomic.gate;
import net.minecraft.block.Block;
import net.minecraft.client.renderer.texture.TextureMap;

View file

@ -1,9 +1,9 @@
package resonantinduction.quantum.gate;
package resonantinduction.atomic.gate;
import net.minecraft.entity.Entity;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.FluidTank;

View file

@ -3,13 +3,13 @@ package resonantinduction.atomic.items;
import java.util.List;
import resonantinduction.atomic.Atomic;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLiving;
import net.minecraft.item.ItemStack;
import net.minecraft.util.AxisAlignedBB;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import net.minecraft.world.Explosion;
import net.minecraft.world.World;
import net.minecraftforge.common.MinecraftForge;
@ -23,14 +23,14 @@ import resonantinduction.atomic.Atomic;
import resonantinduction.core.Reference;
import resonantinduction.core.ResonantInduction;
import resonantinduction.core.Settings;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
/* Antimatter Cell */
public class ItemAntimatter extends ItemCell
{
private Icon iconGram;
private IIcon iconGram;
public ItemAntimatter(int itemID)
{
@ -41,7 +41,7 @@ public class ItemAntimatter extends ItemCell
@SideOnly(Side.CLIENT)
@Override
public void registerIcons(IconRegister iconRegister)
public void registerIcons(IIconRegister iconRegister)
{
// Animated Icons
//ResonantInduction.LOGGER.info(this.getUnlocalizedName().replace("item.", "") + "_milligram");
@ -50,7 +50,7 @@ public class ItemAntimatter extends ItemCell
}
@Override
public Icon getIconFromDamage(int metadata)
public IIcon getIconFromDamage(int metadata)
{
if (metadata >= 1)
{

View file

@ -3,7 +3,7 @@ package resonantinduction.atomic.items;
import resonantinduction.atomic.Atomic;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
import resonant.api.IReactor;
@ -27,7 +27,7 @@ public class ItemCell extends ItemTooltip
@SideOnly(Side.CLIENT)
@Override
public void registerIcons(IconRegister iconRegister)
public void registerIcons(IIconRegister iconRegister)
{
this.itemIcon = iconRegister.registerIcon(this.getUnlocalizedName().replace("item.", ""));
}

View file

@ -1,6 +1,6 @@
package resonantinduction.atomic.items;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@ -15,9 +15,9 @@ public class ItemDarkMatter extends ItemCell
@SideOnly(Side.CLIENT)
@Override
public void registerIcons(IconRegister iconRegister)
public void registerIcons(IIconRegister iconRegister)
{
// Animated Icon
// Animated IIcon
this.itemIcon = iconRegister.registerIcon(this.getUnlocalizedName().replace("item.", ""));
}
}

View file

@ -7,14 +7,14 @@ import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.world.World;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.FluidStack;
import resonant.api.IReactor;
import resonant.api.IReactorComponent;
import atomic.machine.reactor.TileReactorCell;
import resonantinduction.atomic.Atomic;
import resonantinduction.core.Settings;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@ -49,7 +49,7 @@ public class ItemFissileFuel extends ItemRadioactive implements IReactorComponen
for (int i = 0; i < 6; i++)
{
Vector3 checkPos = new Vector3(tileEntity).translate(ForgeDirection.getOrientation(i));
Vector3 checkPos = new Vector3(tileEntity).add(ForgeDirection.getOrientation(i));
TileEntity tile = checkPos.getTileEntity(worldObj);
// Check that the other reactors not only exist but also are running.

View file

@ -6,7 +6,7 @@ import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
import resonant.lib.prefab.poison.PoisonRadiation;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
/** Radioactive Items */
public class ItemRadioactive extends Item

View file

@ -14,11 +14,11 @@ import net.minecraft.world.World;
import net.minecraftforge.common.ForgeChunkManager;
import net.minecraftforge.common.ForgeChunkManager.Ticket;
import net.minecraftforge.common.ForgeChunkManager.Type;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.api.IElectromagnet;
import resonant.lib.prefab.poison.PoisonRadiation;
import resonantinduction.core.Reference;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import universalelectricity.api.vector.VectorHelper;
import com.google.common.io.ByteArrayDataInput;
@ -54,7 +54,7 @@ public class EntityParticle extends Entity implements IEntityAdditionalSpawnData
public static boolean canSpawnParticle(World world, Vector3 pos)
{
Block block = Block.blocksList[pos.getBlockID(world)];
Block block = Block.blocksList[pos.getBlock(world)];
if (block != null && !block.isAirBlock(world, pos.intX(), pos.intY(), pos.intZ()))
{
return false;
@ -75,7 +75,7 @@ public class EntityParticle extends Entity implements IEntityAdditionalSpawnData
public static boolean isElectromagnet(World world, Vector3 position, ForgeDirection dir)
{
Vector3 checkPos = position.clone().translate(dir);
Vector3 checkPos = position.clone().add(dir);
TileEntity tile = checkPos.getTileEntity(world);
if (tile instanceof IElectromagnet)
@ -187,7 +187,7 @@ public class EntityParticle extends Entity implements IEntityAdditionalSpawnData
}
Vector3 dongLi = new Vector3();
dongLi.translate(this.movementDirection);
dongLi.add(this.movementDirection);
dongLi.scale(acceleration);
this.motionX = Math.min(dongLi.x + this.motionX, TileAccelerator.clientParticleVelocity);
this.motionY = Math.min(dongLi.y + this.motionY, TileAccelerator.clientParticleVelocity);
@ -229,17 +229,17 @@ public class EntityParticle extends Entity implements IEntityAdditionalSpawnData
{
ForgeDirection zuoFangXiang = VectorHelper.getOrientationFromSide(this.movementDirection, ForgeDirection.EAST);
Vector3 zuoBian = new Vector3(this).floor();
zuoBian.translate(zuoFangXiang);
zuoBian.add(zuoFangXiang);
ForgeDirection youFangXiang = VectorHelper.getOrientationFromSide(this.movementDirection, ForgeDirection.WEST);
Vector3 youBian = new Vector3(this).floor();
youBian.translate(youFangXiang);
youBian.add(youFangXiang);
if (zuoBian.getBlockID(this.worldObj) == 0)
if (zuoBian.getBlock(this.worldObj) == 0)
{
this.movementDirection = zuoFangXiang;
}
else if (youBian.getBlockID(this.worldObj) == 0)
else if (youBian.getBlock(this.worldObj) == 0)
{
this.movementDirection = youFangXiang;
}

View file

@ -4,7 +4,7 @@ import net.minecraft.entity.player.InventoryPlayer;
import resonant.lib.gui.GuiContainerBase;
import universalelectricity.api.energy.UnitDisplay;
import universalelectricity.api.energy.UnitDisplay.Unit;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
public class GuiAccelerator extends GuiContainerBase
{
@ -27,7 +27,7 @@ public class GuiAccelerator extends GuiContainerBase
String status = "";
Vector3 position = new Vector3(this.tileEntity);
position.translate(this.tileEntity.getDirection().getOpposite());
position.add(this.tileEntity.getDirection().getOpposite());
if (!EntityParticle.canSpawnParticle(this.tileEntity.worldObj, position))
{

View file

@ -10,7 +10,7 @@ import net.minecraft.inventory.ISidedInventory;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.network.packet.Packet;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.api.IElectromagnet;
import resonant.api.IRotatable;
import resonant.lib.network.Synced;
@ -24,7 +24,7 @@ import universalelectricity.api.UniversalElectricity;
import universalelectricity.api.electricity.IVoltageInput;
import universalelectricity.api.energy.EnergyStorageHandler;
import universalelectricity.api.energy.IEnergyInterface;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import cpw.mods.fml.common.network.PacketDispatcher;
import cpw.mods.fml.common.network.Player;
@ -153,8 +153,8 @@ public class TileAccelerator extends TileElectricalInventory implements IElectro
if (getStackInSlot(0) != null && lastSpawnTick >= 40)
{
Vector3 spawn_vec = new Vector3(this);
spawn_vec.translate(getDirection().getOpposite());
spawn_vec.translate(0.5f);
spawn_vec.add(getDirection().getOpposite());
spawn_vec.add(0.5f);
// Only render the particle if container within the proper environment for it.
if (EntityParticle.canSpawnParticle(worldObj, spawn_vec))

View file

@ -6,7 +6,7 @@ import net.minecraft.inventory.ISidedInventory;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.network.packet.Packet;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidContainerRegistry;
import net.minecraftforge.fluids.FluidStack;

View file

@ -7,7 +7,7 @@ import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.network.packet.Packet;
import net.minecraft.tileentity.TileEntity;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidContainerRegistry;
import net.minecraftforge.fluids.FluidStack;
@ -22,7 +22,7 @@ import resonantinduction.core.Settings;
import universalelectricity.api.CompatibilityModule;
import universalelectricity.api.electricity.IVoltageInput;
import universalelectricity.api.energy.EnergyStorageHandler;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import universalelectricity.api.vector.VectorHelper;
import com.google.common.io.ByteArrayDataInput;

View file

@ -6,7 +6,7 @@ import net.minecraft.inventory.ISidedInventory;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.network.packet.Packet;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidContainerRegistry;
import net.minecraftforge.fluids.FluidRegistry;

View file

@ -1,6 +1,6 @@
package resonantinduction.atomic.machine.extractor.turbine;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.Fluid;
import resonant.api.IBoilHandler;
import resonant.lib.prefab.turbine.TileTurbine;

View file

@ -1,11 +1,11 @@
package resonantinduction.atomic.machine.extractor.turbine;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.Icon;
import net.minecraftforge.common.ForgeDirection;
import net.minecraft.util.IIcon;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidContainerRegistry;
import net.minecraftforge.fluids.FluidStack;
@ -23,7 +23,7 @@ import cpw.mods.fml.relauncher.SideOnly;
/** Funnel for gas. */
public class TileFunnel extends TileBase implements IBoilHandler
{
private static Icon iconTop;
private static IIcon iconTop;
private final FluidTank tank = new FluidTank(FluidContainerRegistry.BUCKET_VOLUME * 16);
public TileFunnel()
@ -33,14 +33,14 @@ public class TileFunnel extends TileBase implements IBoilHandler
}
@Override
public Icon getIcon(int side, int meta)
public IIcon getIcon(int side, int meta)
{
return side == 1 || side == 0 ? iconTop : super.getIcon(side, meta);
}
@SideOnly(Side.CLIENT)
@Override
public void registerIcons(IconRegister iconRegister)
public void registerIcons(IIconRegister iconRegister)
{
super.registerIcons(iconRegister);
iconTop = iconRegister.registerIcon(domain + name + "_top");

View file

@ -9,7 +9,7 @@ import net.minecraft.util.Vec3;
import net.minecraftforge.event.ForgeSubscribe;
import resonant.api.explosion.ExplosionEvent.DoExplosionEvent;
import resonantinduction.atomic.Atomic;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
/** Atomic Science Event Handling. */
public class FulminationHandler
@ -47,7 +47,7 @@ public class FulminationHandler
if (!tileEntity.isInvalid())
{
Vector3 tileDiDian = new Vector3(tileEntity);
tileDiDian.translate(0.5f);
tileDiDian.add(0.5f);
double juLi = tileDiDian.distance(new Vector3(evt.x, evt.y, evt.z));
if (juLi <= evt.iExplosion.getRadius() && juLi > 0)

View file

@ -3,7 +3,7 @@ package resonantinduction.atomic.machine.fulmination;
import java.util.EnumSet;
import net.minecraft.block.material.Material;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.lib.utility.ConnectedTextureRenderer;
import resonant.lib.content.module.TileRender;
import resonant.lib.prefab.tile.TileElectrical;

View file

@ -1,6 +1,6 @@
package resonantinduction.atomic.machine.plasma;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.world.World;

View file

@ -9,14 +9,14 @@ import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.DamageSource;
import net.minecraft.world.IBlockAccess;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.common.MinecraftForge;
import resonant.api.event.PlasmaEvent.SpawnPlasmaEvent;
import resonant.lib.config.Config;
import resonant.lib.content.module.TileBase;
import resonant.lib.prefab.vector.Cuboid;
import resonant.lib.thermal.ThermalGrid;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import universalelectricity.api.vector.VectorWorld;
public class TilePlasma extends TileBase
@ -93,7 +93,7 @@ public class TilePlasma extends TileBase
}
Vector3 diDian = new Vector3(this);
diDian.translate(ForgeDirection.getOrientation(i));
diDian.add(ForgeDirection.getOrientation(i));
TileEntity tileEntity = diDian.getTileEntity(worldObj);

View file

@ -6,7 +6,7 @@ import atomic.Atomic;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.network.packet.Packet;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidContainerRegistry;
import net.minecraftforge.fluids.FluidStack;
@ -23,7 +23,7 @@ import resonantinduction.core.ResonantInduction;
import universalelectricity.api.energy.EnergyStorageHandler;
import universalelectricity.api.energy.UnitDisplay;
import universalelectricity.api.energy.UnitDisplay.Unit;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import com.google.common.io.ByteArrayDataInput;

View file

@ -7,7 +7,7 @@ import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.network.packet.Packet;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.api.recipe.QuantumAssemblerRecipes;
import resonant.lib.network.IPacketReceiver;
import resonant.lib.prefab.tile.TileElectricalInventory;
@ -16,7 +16,7 @@ import resonantinduction.core.Reference;
import resonantinduction.core.ResonantInduction;
import universalelectricity.api.electricity.IVoltageInput;
import universalelectricity.api.energy.EnergyStorageHandler;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import com.google.common.io.ByteArrayDataInput;
@ -132,7 +132,7 @@ public class TileQuantumAssembler extends TileElectricalInventory implements IPa
}
//Animation frame update
this.rotation.translate(3, 2, 1);
this.rotation.add(3, 2, 1);
}
}

View file

@ -1,10 +1,10 @@
package resonantinduction.atomic.machine.reactor;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import net.minecraft.util.MathHelper;
import net.minecraft.world.World;
import resonant.lib.prefab.block.BlockRotatable;
@ -15,7 +15,7 @@ import cpw.mods.fml.relauncher.SideOnly;
/** Reactor tap block */
public class BlockReactorDrain extends BlockRotatable
{
private Icon frontIcon;
private IIcon frontIcon;
public BlockReactorDrain(int id)
{
@ -46,7 +46,7 @@ public class BlockReactorDrain extends BlockRotatable
}
@Override
public Icon getIcon(int side, int metadata)
public IIcon getIcon(int side, int metadata)
{
if (side == metadata)
{
@ -57,7 +57,7 @@ public class BlockReactorDrain extends BlockRotatable
@SideOnly(Side.CLIENT)
@Override
public void registerIcons(IconRegister iconRegister)
public void registerIcons(IIconRegister iconRegister)
{
super.registerIcons(iconRegister);
this.frontIcon = iconRegister.registerIcon(this.getUnlocalizedName().replace("tile.", "") + "_front");

View file

@ -1,11 +1,11 @@
package resonantinduction.atomic.machine.reactor;
import net.minecraft.block.material.Material;
import resonant.lib.content.module.TileBlock;
import resonant.content.spatial.block.SpatialBlock;
import resonant.lib.prefab.vector.Cuboid;
/** Control rod block */
public class TileControlRod extends TileBlock
public class TileControlRod extends SpatialBlock
{
public TileControlRod()
{

View file

@ -17,7 +17,7 @@ import net.minecraft.network.packet.Packet;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.AxisAlignedBB;
import net.minecraft.world.World;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.common.MinecraftForge;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidContainerRegistry;
@ -45,7 +45,7 @@ import resonantinduction.atomic.machine.plasma.TilePlasma;
import resonantinduction.core.Reference;
import resonantinduction.core.ResonantInduction;
import universalelectricity.api.UniversalElectricity;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import universalelectricity.api.vector.VectorWorld;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@ -182,8 +182,8 @@ public class TileReactorCell extends TileInventory implements IMultiBlockStructu
if (drain != null && drain.amount >= FluidContainerRegistry.BUCKET_VOLUME)
{
ForgeDirection spawnDir = ForgeDirection.getOrientation(worldObj.rand.nextInt(3) + 2);
Vector3 spawnPos = new Vector3(this).translate(spawnDir, 2);
spawnPos.translate(0, Math.max(worldObj.rand.nextInt(getHeight()) - 1, 0), 0);
Vector3 spawnPos = new Vector3(this).add(spawnDir, 2);
spawnPos.add(0, Math.max(worldObj.rand.nextInt(getHeight()) - 1, 0), 0);
if (worldObj.isAirBlock(spawnPos.intX(), spawnPos.intY(), spawnPos.intZ()))
{
@ -243,9 +243,9 @@ public class TileReactorCell extends TileInventory implements IMultiBlockStructu
for (int i = 2; i < 6; i++)
{
Vector3 checkAdjacent = new Vector3(this).translate(ForgeDirection.getOrientation(i));
Vector3 checkAdjacent = new Vector3(this).add(ForgeDirection.getOrientation(i));
if (checkAdjacent.getBlockID(worldObj) == Atomic.blockControlRod.blockID)
if (checkAdjacent.getBlock(worldObj) == Atomic.blockControlRod.blockID)
{
deltaT /= 1.1;
rods++;
@ -308,9 +308,9 @@ public class TileReactorCell extends TileInventory implements IMultiBlockStructu
if (isOverToxic())
{
/** Randomly leak toxic waste when it is too toxic */
VectorWorld leakPos = new VectorWorld(this).translate(worldObj.rand.nextInt(20) - 10, worldObj.rand.nextInt(20) - 10, worldObj.rand.nextInt(20) - 10);
VectorWorld leakPos = new VectorWorld(this).add(worldObj.rand.nextInt(20) - 10, worldObj.rand.nextInt(20) - 10, worldObj.rand.nextInt(20) - 10);
int blockID = leakPos.getBlockID();
int blockID = leakPos.getBlock();
if (blockID == Block.grass.blockID)
{
@ -321,7 +321,7 @@ public class TileReactorCell extends TileInventory implements IMultiBlockStructu
{
if (tank.getFluid() != null)
{
leakPos.setBlock(worldObj, tank.getFluid().getFluid().getBlockID());
leakPos.setBlock(worldObj, tank.getFluid().getFluid().getBlock());
tank.drain(FluidContainerRegistry.BUCKET_VOLUME, true);
}
}

View file

@ -9,7 +9,7 @@ import net.minecraft.block.Block;
import net.minecraft.block.BlockFluid;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.world.World;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.FluidTankInfo;
@ -19,7 +19,7 @@ import net.minecraftforge.fluids.IFluidTank;
import resonant.lib.path.IPathCallBack;
import resonant.lib.path.Pathfinder;
import resonant.lib.prefab.tile.TileAdvanced;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
/** Reactor Drain
*
@ -45,8 +45,8 @@ public class TileReactorDrain extends TileAdvanced implements IFluidHandler
for (int i = 0; i < 6; i++)
{
ForgeDirection direction = ForgeDirection.getOrientation(i);
Vector3 position = currentNode.clone().translate(direction);
int connectedBlockID = position.getBlockID(world);
Vector3 position = currentNode.clone().add(direction);
int connectedBlockID = position.getBlock(world);
if (connectedBlockID == 0 || Block.blocksList[connectedBlockID] instanceof BlockFluid || Block.blocksList[connectedBlockID] instanceof IFluidBlock || position.getTileEntity(world) instanceof TileReactorCell)
{
@ -72,7 +72,7 @@ public class TileReactorDrain extends TileAdvanced implements IFluidHandler
return false;
}
}).init(new Vector3(this).translate(ForgeDirection.getOrientation(this.getBlockMetadata()).getOpposite()));
}).init(new Vector3(this).add(ForgeDirection.getOrientation(this.getBlockMetadata()).getOpposite()));
for (Vector3 node : finder.results)
{

View file

@ -9,7 +9,7 @@ import net.minecraft.world.World;
import resonant.lib.prefab.item.ItemBlockSaved;
import resonant.lib.utility.LanguageUtility;
import resonant.lib.utility.nbt.NBTUtility;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
/** Handheld thermometer */
public class ItemBlockThermometer extends ItemBlockSaved

View file

@ -7,12 +7,12 @@ import li.cil.oc.api.network.Callback;
import li.cil.oc.api.network.Context;
import li.cil.oc.api.network.SimpleComponent;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.network.packet.Packet;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import net.minecraft.world.IBlockAccess;
import resonant.lib.content.module.TileBase;
import resonant.lib.network.PacketHandler;
@ -22,7 +22,7 @@ import resonant.lib.thermal.ThermalGrid;
import resonant.lib.utility.inventory.InventoryUtility;
import resonantinduction.core.Reference;
import resonantinduction.core.ResonantInduction;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import universalelectricity.api.vector.VectorWorld;
import cpw.mods.fml.common.Optional;
import cpw.mods.fml.relauncher.Side;
@ -36,7 +36,7 @@ import dan200.computercraft.api.peripheral.IPeripheral;
public class TileThermometer extends TileBase implements IPeripheral, SimpleComponent
{
public static final int MAX_THRESHOLD = 5000;
private static Icon iconSide;
private static IIcon iconSide;
@Synced
public float detectedTemperature = 295;
@ -63,14 +63,14 @@ public class TileThermometer extends TileBase implements IPeripheral, SimpleComp
}
@Override
public Icon getIcon(int side, int meta)
public IIcon getIcon(int side, int meta)
{
return side == 1 || side == 0 ? super.getIcon(side, meta) : iconSide;
}
@SideOnly(Side.CLIENT)
@Override
public void registerIcons(IconRegister iconRegister)
public void registerIcons(IIconRegister iconRegister)
{
super.registerIcons(iconRegister);
iconSide = iconRegister.registerIcon(Reference.PREFIX + "machine");

View file

@ -3,10 +3,10 @@ package resonantinduction.atomic.schematic;
import java.util.HashMap;
import atomic.Atomic;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.lib.schematic.Schematic;
import resonant.lib.type.Pair;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
public class SchematicAccelerator extends Schematic
{

View file

@ -3,11 +3,11 @@ package resonantinduction.atomic.schematic;
import java.util.HashMap;
import net.minecraft.block.Block;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.lib.schematic.Schematic;
import resonant.lib.type.Pair;
import atomic.Atomic;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
public class SchematicBreedingReactor extends Schematic
{

View file

@ -4,10 +4,10 @@ import java.util.HashMap;
import atomic.Atomic;
import net.minecraft.block.Block;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.lib.schematic.Schematic;
import resonant.lib.type.Pair;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
public class SchematicFissionReactor extends Schematic
{
@ -91,7 +91,7 @@ public class SchematicFissionReactor extends Schematic
}
}
returnMap.put(targetPosition.clone().translate(offset), new Pair(Block.pistonStickyBase.blockID, rotationMetadata));
returnMap.put(targetPosition.clone().add(offset), new Pair(Block.pistonStickyBase.blockID, rotationMetadata));
}
else if (x == -r || x == r || z == -r || z == r)
{

View file

@ -3,10 +3,10 @@ package resonantinduction.atomic.schematic;
import java.util.HashMap;
import atomic.Atomic;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.lib.schematic.Schematic;
import resonant.lib.type.Pair;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
public class SchematicFusionReactor extends Schematic
{
@ -45,7 +45,7 @@ public class SchematicFusionReactor extends Schematic
if (magnitude >= 1)
{
double yDeviation = (y == 0 ? size / 3 : -size / 3) + (y == 0 ? -1 : 1) * Math.sin(magnitude / radius * Math.PI) * size / 2d;
Vector3 newPos = position.clone().translate(0, yDeviation, 0);
Vector3 newPos = position.clone().add(0, yDeviation, 0);
returnMap.put(newPos.round(), new Pair(Atomic.blockElectromagnet.blockID, 1));
}
}

View file

@ -10,7 +10,7 @@ import net.minecraft.world.World;
import net.minecraftforge.common.MinecraftForge;
import resonant.lib.render.fx.FxLaser;
import universalelectricity.api.vector.IVector3;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import cpw.mods.fml.client.FMLClientHandler;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;

View file

@ -9,7 +9,7 @@ import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.ChatMessageComponent;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.event.ForgeSubscribe;
import net.minecraftforge.event.entity.player.PlayerInteractEvent;
import net.minecraftforge.event.entity.player.PlayerInteractEvent.Action;

View file

@ -8,7 +8,7 @@ import java.awt.Color;
import net.minecraft.world.World;
import resonant.lib.prefab.ProxyBase;
import universalelectricity.api.vector.IVector3;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
/** @author Calclavia */
public class CommonProxy extends ProxyBase

View file

@ -5,9 +5,9 @@ import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.oredict.OreDictionary;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import universalelectricity.api.vector.VectorWorld;
import codechicken.lib.vec.BlockCoord;
import codechicken.multipart.TMultiPart;

View file

@ -4,10 +4,10 @@ import java.util.List;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.item.ItemStack;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import resonant.lib.prefab.block.BlockTile;
import resonantinduction.core.Reference;
@ -20,7 +20,7 @@ import resonantinduction.core.Reference;
public class BlockIndustrialStone extends BlockTile
{
String[] iconNames = new String[] { "material_stone_brick", "material_stone_brick2", "material_stone_chiseled", "material_stone_cobble", "material_stone_cracked", "material_stone", "material_stone_slab", "material_stone_mossy", "material_steel_dark", "material_steel_tint", "material_steel" };
Icon[] icons = new Icon[iconNames.length];
IIcon[] icons = new IIcon[iconNames.length];
public BlockIndustrialStone(int id)
{
@ -36,18 +36,18 @@ public class BlockIndustrialStone extends BlockTile
}
@Override
public Icon getIcon(int side, int metadata)
public IIcon getIcon(int side, int metadata)
{
return icons[metadata];
}
@Override
public void registerIcons(IconRegister par1IconRegister)
public void registerIcons(IIconRegister par1IIconRegister)
{
this.blockIcon = par1IconRegister.registerIcon(this.getTextureName());
this.blockIcon = par1IIconRegister.registerIcon(this.getTextureName());
for (int i = 0; i < iconNames.length; i++)
icons[i] = par1IconRegister.registerIcon(Reference.PREFIX + iconNames[i]);
icons[i] = par1IIconRegister.registerIcon(Reference.PREFIX + iconNames[i]);
}
@Override

View file

@ -2,7 +2,7 @@ package resonantinduction.core.debug;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.world.World;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.api.grid.INode;
import resonant.api.grid.INodeProvider;
import codechicken.multipart.TMultiPart;

View file

@ -1,6 +1,6 @@
package resonantinduction.core.grid;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.api.grid.INode;
import resonant.api.grid.INodeProvider;
import codechicken.multipart.PartMap;

View file

@ -1,6 +1,6 @@
package resonantinduction.core.grid.fluid;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.FluidTank;
import net.minecraftforge.fluids.FluidTankInfo;

View file

@ -7,13 +7,13 @@ import java.util.Map.Entry;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.world.World;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.FluidTank;
import net.minecraftforge.fluids.IFluidHandler;
import resonant.lib.grid.Node;
import resonant.lib.grid.TickingGrid;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import codechicken.multipart.TMultiPart;
@SuppressWarnings("deprecation")
@ -210,7 +210,7 @@ public class FluidPressureNode extends Node<IPressureNodeProvider, TickingGrid,
for (ForgeDirection dir : ForgeDirection.VALID_DIRECTIONS)
{
TileEntity tile = position().translate(dir).getTileEntity(world());
TileEntity tile = position().add(dir).getTileEntity(world());
if (tile instanceof IPressureNodeProvider)
{

View file

@ -2,12 +2,12 @@ package resonantinduction.core.grid.fluid;
import net.minecraft.block.material.Material;
import net.minecraft.tileentity.TileEntity;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.FluidTankInfo;
import resonant.lib.utility.WorldUtility;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
/**
* A prefab class for tiles that use the fluid network.
@ -102,7 +102,7 @@ public abstract class TileFluidDistribution extends TileFluidNode implements IFl
for (ForgeDirection dir : ForgeDirection.VALID_DIRECTIONS)
{
this.validateConnectionSide(new Vector3(this).translate(dir).getTileEntity(worldObj), dir);
this.validateConnectionSide(new Vector3(this).add(dir).getTileEntity(worldObj), dir);
}
/** Only send packet updates if visuallyConnected changed. */

View file

@ -12,7 +12,7 @@ import resonant.lib.network.IPacketReceiverWithID;
import resonant.lib.network.PacketHandler;
import resonant.lib.utility.FluidUtility;
import resonantinduction.core.ResonantInduction;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import com.google.common.io.ByteArrayDataInput;

View file

@ -1,7 +1,7 @@
package resonantinduction.core.grid.fluid;
import net.minecraft.block.material.Material;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.FluidContainerRegistry;
import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.FluidTank;

View file

@ -1,10 +1,10 @@
package resonantinduction.core.interfaces;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.api.grid.INode;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
/** Applied to any node that will act as a mechanical object in the network
/** Applied to any node that will act as a resonantinduction.mechanical object in the network
*
* @author Darkguardsman */
public interface IMechanicalNode extends INode
@ -15,7 +15,7 @@ public interface IMechanicalNode extends INode
/** The Rotational speed of the object */
public double getAngularSpeed();
/** Applies rotational force and velocity to the mechanical object */
/** Applies rotational force and velocity to the resonantinduction.mechanical object */
public void apply(Object source, double torque, double angularVelocity);

View file

@ -2,11 +2,11 @@ package resonantinduction.core.items;
import java.util.List;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import resonantinduction.core.Reference;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@ -22,13 +22,13 @@ import cpw.mods.fml.relauncher.SideOnly;
public class ItemFlour extends Item {
@SideOnly(Side.CLIENT)
Icon doughIcon;
IIcon doughIcon;
/*@SideOnly(Side.CLIENT)
Icon bakingtrayIcon;
IIcon bakingtrayIcon;
@SideOnly(Side.CLIENT)
Icon bakingtraywithdoughIcon;*/
IIcon bakingtraywithdoughIcon;*/
public ItemFlour(int par1) {
@ -37,7 +37,7 @@ public class ItemFlour extends Item {
}
@Override
public Icon getIconFromDamage(int meta) {
public IIcon getIconFromDamage(int meta) {
switch (meta) {
case 1:
return doughIcon;
@ -56,7 +56,7 @@ public class ItemFlour extends Item {
}
@Override
public void registerIcons(IconRegister iconRegister) {
public void registerIcons(IIconRegister iconRegister) {
super.registerIcons(iconRegister);
this.doughIcon = iconRegister.registerIcon(Reference.PREFIX + "dough");
/*this.bakingtrayIcon = iconRegister.registerIcon(Reference.PREFIX + "bakingtray");

View file

@ -7,11 +7,11 @@ import net.minecraft.entity.item.EntityItem;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.api.IFilterable;
import resonant.api.IRotatable;
import resonant.lib.content.module.prefab.TileInventory;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
public abstract class TileFilterable extends TileInventory implements IRotatable, IFilterable
{

View file

@ -8,7 +8,7 @@ import net.minecraft.network.packet.Packet;
import net.minecraft.tileentity.TileEntity;
import resonant.lib.network.IPacketReceiver;
import resonant.lib.network.PacketType;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import codechicken.multipart.TMultiPart;
import codechicken.multipart.TileMultipart;

View file

@ -7,7 +7,7 @@ import java.util.List;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.util.MovingObjectPosition;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import codechicken.lib.data.MCDataInput;
import codechicken.lib.data.MCDataOutput;
import codechicken.lib.vec.Cuboid6;

View file

@ -8,12 +8,12 @@ import net.minecraft.client.renderer.RenderBlocks;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import net.minecraft.util.MovingObjectPosition;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import universalelectricity.api.net.IConnector;
import universalelectricity.api.net.INodeNetwork;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import universalelectricity.api.vector.VectorHelper;
import codechicken.lib.data.MCDataInput;
import codechicken.lib.data.MCDataOutput;
@ -68,7 +68,7 @@ public abstract class PartFramedConnection<M extends Enum, C extends IConnector<
private ForgeDirection testingSide;
@SideOnly(Side.CLIENT)
protected Icon breakIcon;
protected IIcon breakIcon;
public PartFramedConnection(Item insulationType)
{
@ -322,7 +322,7 @@ public abstract class PartFramedConnection<M extends Enum, C extends IConnector<
@Override
public boolean canConnect(ForgeDirection direction, Object source)
{
Vector3 connectPos = new Vector3(tile()).translate(direction);
Vector3 connectPos = new Vector3(tile()).add(direction);
TileEntity connectTile = connectPos.getTileEntity(world());
return !isConnectionPrevented(connectTile, direction);
}

View file

@ -9,9 +9,9 @@ import net.minecraft.client.renderer.RenderBlocks;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import net.minecraft.util.MovingObjectPosition;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.api.grid.INode;
import resonant.api.grid.INodeProvider;
import resonant.lib.grid.Node;
@ -70,7 +70,7 @@ public abstract class PartFramedNode<M extends Enum, N extends Node, T extends I
private ForgeDirection testingSide;
@SideOnly(Side.CLIENT)
protected Icon breakIcon;
protected IIcon breakIcon;
public PartFramedNode(Item insulationType)
{
@ -141,13 +141,13 @@ public abstract class PartFramedNode<M extends Enum, N extends Node, T extends I
}
@Override
public Icon getBreakingIcon(Object subPart, int side)
public IIcon getBreakingIcon(Object subPart, int side)
{
return breakIcon;
}
@Override
public Icon getBrokenIcon(int side)
public IIcon getBrokenIcon(int side)
{
return breakIcon;
}

View file

@ -4,7 +4,7 @@ import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.inventory.ISidedInventory;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.api.IExternalInventory;
import resonant.api.IExternalInventoryBox;
import resonant.lib.utility.inventory.ExternalInventory;

View file

@ -7,7 +7,7 @@ import java.util.List;
import net.minecraft.block.material.Material;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.nbt.NBTTagList;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.common.util.ForgeDirection;
import resonant.api.IRotatable;
import resonant.api.grid.INode;
import resonant.api.grid.INodeProvider;

View file

@ -3,9 +3,9 @@ package resonantinduction.core.render;
import net.minecraft.block.Block;
import net.minecraft.client.Minecraft;
import net.minecraft.client.renderer.texture.TextureMap;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import net.minecraft.world.IBlockAccess;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
/** Used to store info on a block mainly used for rendering */
public class BlockRenderInfo
@ -17,7 +17,7 @@ public class BlockRenderInfo
/** Block to pull info from */
public Block baseBlock = Block.sand;
/** Override render texture */
public Icon texture = null;
public IIcon texture = null;
/** meta data to use for block the block */
public int meta = 0;
@ -28,21 +28,21 @@ public class BlockRenderInfo
}
/** Gets the block texture from the given side */
public Icon getBlockTextureFromSide(int side)
public IIcon getBlockTextureFromSide(int side)
{
return this.getBlockIconFromSideAndMetadata(side, meta);
}
/** Gets the block texture from side and meta */
public Icon getBlockIconFromSideAndMetadata(int side, int meta)
public IIcon getBlockIconFromSideAndMetadata(int side, int meta)
{
return this.getIconSafe(baseBlock.getIcon(side, meta));
}
/** Gets the icon and does some safty checks */
public Icon getIconSafe(Icon par1Icon)
public IIcon getIconSafe(IIcon par1Icon)
{
Icon icon = par1Icon;
IIcon icon = par1Icon;
if (this.texture != null)
{
icon = texture;

View file

@ -11,7 +11,7 @@ import net.minecraft.util.MovingObjectPosition;
import resonant.lib.render.RenderUtility;
import resonantinduction.core.prefab.imprint.ItemImprint;
import resonantinduction.core.prefab.imprint.TileFilterable;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@ -48,11 +48,11 @@ public abstract class RenderImprintable extends TileEntitySpecialRenderer
{
if (((TileFilterable) tileEntity).isInverted())
{
RenderUtility.renderFloatingText(filterStack.getTooltip(player, Minecraft.getMinecraft().gameSettings.advancedItemTooltips).get(0).toString(), new Vector3(x, y, z).translate(0.5, i * 0.25f - 1f, z + 0.5f), 0xFF8888);
RenderUtility.renderFloatingText(filterStack.getTooltip(player, Minecraft.getMinecraft().gameSettings.advancedItemTooltips).get(0).toString(), new Vector3(x, y, z).add(0.5, i * 0.25f - 1f, z + 0.5f), 0xFF8888);
}
else
{
RenderUtility.renderFloatingText(filterStack.getTooltip(player, Minecraft.getMinecraft().gameSettings.advancedItemTooltips).get(0).toString(), new Vector3(x, y, z).translate(0.5, i * 0.25f - 1f, z + 0.5f), 0x88FF88);
RenderUtility.renderFloatingText(filterStack.getTooltip(player, Minecraft.getMinecraft().gameSettings.advancedItemTooltips).get(0).toString(), new Vector3(x, y, z).add(0.5, i * 0.25f - 1f, z + 0.5f), 0x88FF88);
}
i++;
}

View file

@ -1,6 +1,6 @@
package resonantinduction.core.resource;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.client.renderer.texture.IIconRegister;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import resonant.lib.prefab.item.ItemTooltip;
@ -17,7 +17,7 @@ public class ItemBiomass extends ItemTooltip
@SideOnly(Side.CLIENT)
@Override
public void registerIcons(IconRegister iconRegister)
public void registerIcons(IIconRegister iconRegister)
{
this.itemIcon = iconRegister.registerIcon(this.getUnlocalizedName().replace("item.", ""));
}

View file

@ -19,7 +19,7 @@ import net.minecraft.item.ItemStack;
import net.minecraft.item.crafting.FurnaceRecipes;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.nbt.NBTTagList;
import net.minecraft.util.Icon;
import net.minecraft.util.IIcon;
import net.minecraft.util.ResourceLocation;
import net.minecraftforge.client.event.TextureStitchEvent;
import net.minecraftforge.event.ForgeSubscribe;
@ -58,7 +58,7 @@ public class ResourceGenerator implements IVirtualObject
public static final ResourceGenerator INSTANCE = new ResourceGenerator();
public static final HashBiMap<String, Integer> materials = HashBiMap.create();
static final HashMap<String, Integer> materialColorCache = new HashMap<String, Integer>();
static final HashMap<Icon, Integer> iconColorCache = new HashMap<Icon, Integer>();
static final HashMap<IIcon, Integer> iconColorCache = new HashMap<IIcon, Integer>();
static
{
@ -249,7 +249,7 @@ public class ResourceGenerator implements IVirtualObject
try
{
Icon icon = item.getIconIndex(itemStack);
IIcon icon = item.getIconIndex(itemStack);
if (iconColorCache.containsKey(icon))
{

View file

@ -19,8 +19,8 @@ import resonantinduction.electrical.render.FXElectricBolt;
import resonantinduction.electrical.tesla.RenderTesla;
import resonantinduction.electrical.tesla.TileTesla;
import resonantinduction.electrical.transformer.RenderTransformer;
import resonantinduction.quantum.gate.RenderQuantumGlyph;
import universalelectricity.api.vector.Vector3;
import resonantinduction.atomic.gate.RenderQuantumGlyph;
import universalelectricity.core.transform.vector.Vector3;
import codechicken.multipart.TMultiPart;
import codechicken.multipart.TileMultipart;
import cpw.mods.fml.client.FMLClientHandler;

View file

@ -10,7 +10,7 @@ import resonantinduction.electrical.encoder.TileEncoder;
import resonantinduction.electrical.encoder.gui.ContainerEncoder;
import resonantinduction.electrical.multimeter.ContainerMultimeter;
import resonantinduction.electrical.multimeter.PartMultimeter;
import universalelectricity.api.vector.Vector3;
import universalelectricity.core.transform.vector.Vector3;
import codechicken.multipart.TMultiPart;
import codechicken.multipart.TileMultipart;

View file

@ -35,7 +35,7 @@ import resonantinduction.electrical.tesla.TileTesla;
import resonantinduction.electrical.transformer.ItemTransformer;
import resonantinduction.electrical.wire.EnumWireMaterial;
import resonantinduction.electrical.wire.ItemWire;
import resonantinduction.quantum.gate.ItemQuantumGlyph;
import resonantinduction.atomic.gate.ItemQuantumGlyph;
import cpw.mods.fml.common.Loader;
import cpw.mods.fml.common.Mod;
import cpw.mods.fml.common.Mod.EventHandler;

Some files were not shown because too many files have changed in this diff Show more