Added basic tile for metalShelf
This commit is contained in:
parent
b56487b680
commit
4f800c8a83
3 changed files with 164 additions and 5 deletions
|
@ -9,7 +9,16 @@ import cpw.mods.fml.relauncher.SideOnly;
|
|||
public class BlockMetalShelf extends BlockMachineBase {
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
private IIcon iconFront;
|
||||
private IIcon iconFrontEmpty;
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
private IIcon iconFrontBooks;
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
private IIcon iconFrontCans;
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
private IIcon iconFrontPaper;
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
private IIcon iconTop;
|
||||
|
@ -28,7 +37,7 @@ public class BlockMetalShelf extends BlockMachineBase {
|
|||
public void registerBlockIcons(IIconRegister icon)
|
||||
{
|
||||
this.blockIcon = icon.registerIcon("techreborn:machine/machine_side");
|
||||
this.iconFront = icon.registerIcon("techreborn:machine/metal_shelf_empty");
|
||||
this.iconFrontEmpty = icon.registerIcon("techreborn:machine/metal_shelf_empty");
|
||||
this.iconTop = icon.registerIcon("techreborn:machine/machine_top");
|
||||
this.iconBottom = icon.registerIcon("techreborn:machine/machine_bottom");
|
||||
}
|
||||
|
@ -36,11 +45,10 @@ public class BlockMetalShelf extends BlockMachineBase {
|
|||
@SideOnly(Side.CLIENT)
|
||||
public IIcon getIcon(int side, int metadata)
|
||||
{
|
||||
|
||||
return metadata == 0 && side == 3 ? this.iconFront
|
||||
return metadata == 0 && side == 3 ? this.iconFrontEmpty
|
||||
: side == 1 ? this.iconTop :
|
||||
side == 0 ? this.iconBottom: (side == 0 ? this.iconTop
|
||||
: (side == metadata ? this.iconFront : this.blockIcon));
|
||||
: (side == metadata ? this.iconFrontEmpty : this.blockIcon));
|
||||
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue