Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package com.wwy.mod.blocks.techno;
- import com.wwy.mod.alpha.Main;
- import com.wwy.mod.te.techno.TETechnoReplenisher;
- import net.minecraft.block.ITileEntityProvider;
- import net.minecraft.client.renderer.texture.IIconRegister;
- import net.minecraft.creativetab.CreativeTabs;
- import net.minecraft.entity.player.EntityPlayer;
- import net.minecraft.tileentity.TileEntity;
- import net.minecraft.util.IIcon;
- import net.minecraft.world.World;
- public class BlockTechnoReplenisher extends BlockTechnoMachine implements ITileEntityProvider {
- // TETechnoReplenisher replenisher;
- IIcon[] icons = new IIcon[6];
- IIcon inactive;
- IIcon active;
- public BlockTechnoReplenisher() {
- this.setBlockName("blockTechnoReplenisher");
- this.setBlockTextureName(Main.MODID + ":" + "blockTechnoReplenisher");
- this.setCreativeTab(CreativeTabs.tabMisc);
- }
- @Override
- public boolean onBlockActivated(World world, int x, int y, int z,
- EntityPlayer player, int p_149727_6_, float p_149727_7_,
- float p_149727_8_, float p_149727_9_) {
- // TODO Auto-generated method stub
- TETechnoReplenisher replenisher = (TETechnoReplenisher) world.getTileEntity(x, y, z);
- if (world.isRemote) {
- replenisher.printInfo();
- }
- return false;
- }
- @Override
- public TileEntity createNewTileEntity(World p_149915_1_, int p_149915_2_) {
- // this.replenisher = new TETechnoReplenisher();
- // return replenisher;
- return new TETechnoReplenisher();
- }
- /*
- @Override
- public void onBlockDestroyedByPlayer(World world, int x, int y, int z, int meta) {
- this.replenisher = null;
- }
- /*
- @Override
- public void registerBlockIcons(IIconRegister reg) {
- this.icons[0] = reg.registerIcon(this.textureName + "_" + "top");
- for (int i = 1; i < 5; i++) {
- this.icons[i] = reg.registerIcon(this.textureName + "_" + "side");
- }
- this.icons[5] = reg.registerIcon(this.textureName + "_" + "bottom");
- }
- */
- @Override
- public IIcon getIcon(int side, int meta) {
- if (meta == 0) {
- return this.blockIcon;
- } else if (meta == 1) {
- return this.blockIcon;
- }
- return this.blockIcon;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment