Start on Iron furnace
This commit is contained in:
parent
a84075ff69
commit
961e821402
3 changed files with 67 additions and 1 deletions
59
src/main/java/techreborn/blocks/BlockIronFurnace.java
Normal file
59
src/main/java/techreborn/blocks/BlockIronFurnace.java
Normal file
|
@ -0,0 +1,59 @@
|
|||
package techreborn.blocks;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
import reborncore.common.blocks.BlockMachineBase;
|
||||
import reborncore.common.blocks.IRotationTexture;
|
||||
import techreborn.Core;
|
||||
import techreborn.client.GuiHandler;
|
||||
import techreborn.client.TechRebornCreativeTab;
|
||||
import techreborn.tiles.TileAlloyFurnace;
|
||||
|
||||
public class BlockIronFurnace extends BlockMachineBase implements IRotationTexture {
|
||||
|
||||
public BlockIronFurnace() {
|
||||
super();
|
||||
setUnlocalizedName("techreborn.ironfurnace");
|
||||
setCreativeTab(TechRebornCreativeTab.instance);
|
||||
}
|
||||
|
||||
@Override
|
||||
public TileEntity createNewTileEntity(World world, int p_149915_2_) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onBlockActivated(World world, int x, int y, int z, EntityPlayer player, int side, float hitX, float hitY, float hitZ) {
|
||||
// if (!player.isSneaking())
|
||||
// player.openGui(Core.INSTANCE, GuiHandler.alloyFurnaceID, world, x, y, z);
|
||||
return true;
|
||||
}
|
||||
|
||||
private final String prefix = "techreborn:blocks/machine/";
|
||||
|
||||
@Override
|
||||
public String getFrontOff() {
|
||||
return prefix + "alloy_furnace_front_off";
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getFrontOn() {
|
||||
return prefix + "alloy_furnace_front_on";
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getSide() {
|
||||
return prefix + "alloy_furnace_side";
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getTop() {
|
||||
return prefix + "alloy_furnace_top";
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getBottom() {
|
||||
return prefix + "machine_bottom";
|
||||
}
|
||||
}
|
|
@ -1,5 +1,7 @@
|
|||
package techreborn.client.gui;
|
||||
|
||||
import org.lwjgl.util.Color;
|
||||
|
||||
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||
import net.minecraft.client.renderer.GlStateManager;
|
||||
import net.minecraft.client.resources.I18n;
|
||||
|
@ -35,8 +37,9 @@ public class GuiCompressor extends GuiContainer {
|
|||
int j = 0;
|
||||
|
||||
j = compressor.getProgressScaled(24);
|
||||
// System.out.println("" + j);
|
||||
if (j > 0) {
|
||||
this.drawTexturedModalRect(k + 50, l + 36, 176, 14, j + 1, 16);
|
||||
this.drawTexturedModalRect(k + 80, l + 35, 176, 14, j + 2, 16);
|
||||
}
|
||||
|
||||
j = compressor.getEnergyScaled(12);
|
||||
|
|
|
@ -135,6 +135,7 @@ public class ModBlocks {
|
|||
public static Block storage2;
|
||||
public static Block machineframe;
|
||||
public static Block reinforcedglass;
|
||||
public static Block ironFurnace;
|
||||
|
||||
public static Block rubberLog;
|
||||
public static Block rubberLeaves;
|
||||
|
@ -364,6 +365,9 @@ public class ModBlocks {
|
|||
|
||||
reinforcedglass = new BlockReinforcedGlass(Material.glass);
|
||||
GameRegistry.registerBlock(reinforcedglass, "reinforcedglass");
|
||||
|
||||
ironFurnace = new BlockIronFurnace();
|
||||
GameRegistry.registerBlock(ironFurnace, "ironfurnace");
|
||||
|
||||
registerOreDict();
|
||||
Core.logHelper.info("TechReborns Blocks Loaded");
|
||||
|
|
Loading…
Add table
Reference in a new issue