This commit is contained in:
modmuss50 2015-05-04 19:07:50 +01:00
commit 37b5aa73ba
5 changed files with 268 additions and 0 deletions

View file

@ -0,0 +1,62 @@
package techreborn.blocks;
import net.minecraft.block.Block;
import net.minecraft.block.BlockContainer;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.IIcon;
import net.minecraft.util.MathHelper;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
import techreborn.Core;
import techreborn.client.GuiHandler;
import techreborn.client.TechRebornCreativeTab;
import techreborn.tiles.TileAlloySmelter;
import techreborn.tiles.TileBlastFurnace;
import techreborn.tiles.TileMachineCasing;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class BlockAesu extends BlockMachineBase {
@SideOnly(Side.CLIENT)
private IIcon iconFront;
@SideOnly(Side.CLIENT)
private IIcon iconTop;
@SideOnly(Side.CLIENT)
private IIcon iconBottom;
public BlockAesu(Material material)
{
super(material);
setBlockName("techreborn.aesu");
}
@Override
@SideOnly(Side.CLIENT)
public void registerBlockIcons(IIconRegister icon)
{
this.blockIcon = icon.registerIcon("techreborn:machine/aesu_side");
this.iconFront = icon.registerIcon("techreborn:machine/aesu_front");
this.iconTop = icon.registerIcon("techreborn:machine/aesu_side");
this.iconBottom = icon.registerIcon("techreborn:machine/aesu_side");
}
@SideOnly(Side.CLIENT)
public IIcon getIcon(int side, int metadata)
{
return metadata == 0 && side == 3 ? this.iconFront
: side == 1 ? this.iconTop :
side == 0 ? this.iconBottom: (side == 0 ? this.iconTop
: (side == metadata ? this.iconFront : this.blockIcon));
}
}

View file

@ -0,0 +1,62 @@
package techreborn.blocks;
import net.minecraft.block.Block;
import net.minecraft.block.BlockContainer;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.IIcon;
import net.minecraft.util.MathHelper;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
import techreborn.Core;
import techreborn.client.GuiHandler;
import techreborn.client.TechRebornCreativeTab;
import techreborn.tiles.TileAlloySmelter;
import techreborn.tiles.TileBlastFurnace;
import techreborn.tiles.TileMachineCasing;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class BlockLesu extends BlockMachineBase {
@SideOnly(Side.CLIENT)
private IIcon iconFront;
@SideOnly(Side.CLIENT)
private IIcon iconTop;
@SideOnly(Side.CLIENT)
private IIcon iconBottom;
public BlockLesu(Material material)
{
super(material);
setBlockName("techreborn.lesu");
}
@Override
@SideOnly(Side.CLIENT)
public void registerBlockIcons(IIconRegister icon)
{
this.blockIcon = icon.registerIcon("techreborn:machine/lesu_side");
this.iconFront = icon.registerIcon("techreborn:machine/lesu_front");
this.iconTop = icon.registerIcon("techreborn:machine/lesu_side");
this.iconBottom = icon.registerIcon("techreborn:machine/lesu_side");
}
@SideOnly(Side.CLIENT)
public IIcon getIcon(int side, int metadata)
{
return metadata == 0 && side == 3 ? this.iconFront
: side == 1 ? this.iconTop :
side == 0 ? this.iconBottom: (side == 0 ? this.iconTop
: (side == metadata ? this.iconFront : this.blockIcon));
}
}

View file

@ -0,0 +1,62 @@
package techreborn.blocks;
import net.minecraft.block.Block;
import net.minecraft.block.BlockContainer;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.IIcon;
import net.minecraft.util.MathHelper;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
import techreborn.Core;
import techreborn.client.GuiHandler;
import techreborn.client.TechRebornCreativeTab;
import techreborn.tiles.TileAlloySmelter;
import techreborn.tiles.TileBlastFurnace;
import techreborn.tiles.TileMachineCasing;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class BlockSupercondensator extends BlockMachineBase {
@SideOnly(Side.CLIENT)
private IIcon iconFront;
@SideOnly(Side.CLIENT)
private IIcon iconTop;
@SideOnly(Side.CLIENT)
private IIcon iconBottom;
public BlockSupercondensator(Material material)
{
super(material);
setBlockName("techreborn.supercondensator");
}
@Override
@SideOnly(Side.CLIENT)
public void registerBlockIcons(IIconRegister icon)
{
this.blockIcon = icon.registerIcon("techreborn:machine/supercondensator_side");
this.iconFront = icon.registerIcon("techreborn:machine/supercondensator_front");
this.iconTop = icon.registerIcon("techreborn:machine/supercondensator_side");
this.iconBottom = icon.registerIcon("techreborn:machine/supercondensator_side");
}
@SideOnly(Side.CLIENT)
public IIcon getIcon(int side, int metadata)
{
return metadata == 0 && side == 3 ? this.iconFront
: side == 1 ? this.iconTop :
side == 0 ? this.iconBottom: (side == 0 ? this.iconTop
: (side == metadata ? this.iconFront : this.blockIcon));
}
}

View file

@ -0,0 +1,62 @@
package techreborn.blocks;
import net.minecraft.block.Block;
import net.minecraft.block.BlockContainer;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.IIcon;
import net.minecraft.util.MathHelper;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
import techreborn.Core;
import techreborn.client.GuiHandler;
import techreborn.client.TechRebornCreativeTab;
import techreborn.tiles.TileAlloySmelter;
import techreborn.tiles.TileBlastFurnace;
import techreborn.tiles.TileMachineCasing;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class BlockWoodenshelf extends BlockMachineBase {
@SideOnly(Side.CLIENT)
private IIcon iconFront;
@SideOnly(Side.CLIENT)
private IIcon iconTop;
@SideOnly(Side.CLIENT)
private IIcon iconBottom;
public BlockWoodenshelf(Material material)
{
super(material);
setBlockName("techreborn.woodenshelf");
}
@Override
@SideOnly(Side.CLIENT)
public void registerBlockIcons(IIconRegister icon)
{
this.blockIcon = icon.registerIcon("techreborn:machine/wood_shelf_side");
this.iconFront = icon.registerIcon("techreborn:machine/wood_shelf_empty");
this.iconTop = icon.registerIcon("techreborn:machine/wood_shelf_side");
this.iconBottom = icon.registerIcon("techreborn:machine/wood_shelf_side");
}
@SideOnly(Side.CLIENT)
public IIcon getIcon(int side, int metadata)
{
return metadata == 0 && side == 3 ? this.iconFront
: side == 1 ? this.iconTop :
side == 0 ? this.iconBottom: (side == 0 ? this.iconTop
: (side == metadata ? this.iconFront : this.blockIcon));
}
}

View file

@ -4,6 +4,7 @@ import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.item.ItemStack;
import net.minecraftforge.oredict.OreDictionary;
import techreborn.blocks.BlockAesu;
import techreborn.blocks.BlockAlloyFurnace;
import techreborn.blocks.BlockAlloySmelter;
import techreborn.blocks.BlockAssemblingMachine;
@ -19,6 +20,7 @@ import techreborn.blocks.BlockIDSU;
import techreborn.blocks.BlockImplosionCompressor;
import techreborn.blocks.BlockIndustrialElectrolyzer;
import techreborn.blocks.BlockLathe;
import techreborn.blocks.BlockLesu;
import techreborn.blocks.BlockMachineCasing;
import techreborn.blocks.BlockMagicEnergyAbsorber;
import techreborn.blocks.BlockMagicEnergyConverter;
@ -30,7 +32,9 @@ import techreborn.blocks.BlockQuantumTank;
import techreborn.blocks.BlockRollingMachine;
import techreborn.blocks.BlockSemiFluidGenerator;
import techreborn.blocks.BlockStorage;
import techreborn.blocks.BlockSupercondensator;
import techreborn.blocks.BlockThermalGenerator;
import techreborn.blocks.BlockWoodenshelf;
import techreborn.client.TechRebornCreativeTab;
import techreborn.itemblocks.ItemBlockMachineCasing;
import techreborn.itemblocks.ItemBlockOre;
@ -79,6 +83,10 @@ public class ModBlocks {
public static Block lathe;
public static Block platecuttingmachine;
public static Block Idsu;
public static Block Aesu;
public static Block Lesu;
public static Block Supercondensator;
public static Block Woodenshelf;
public static Block ore;
public static Block storage;
@ -193,6 +201,18 @@ public class ModBlocks {
Idsu = new BlockIDSU(Material.rock);
GameRegistry.registerBlock(Idsu, "idsu");
Aesu = new BlockAesu(Material.rock);
GameRegistry.registerBlock(Aesu, "aesu");
Lesu = new BlockLesu(Material.rock);
GameRegistry.registerBlock(Lesu, "lesu");
Supercondensator = new BlockSupercondensator(Material.rock);
GameRegistry.registerBlock(Supercondensator, "supercondensator");
Woodenshelf = new BlockWoodenshelf(Material.wood);
GameRegistry.registerBlock(Woodenshelf, "woodenshelf");
registerOreDict();
}