Some class renaming, move TextureSubmap to API and improve its methods

This commit is contained in:
tterrag1098 committed 2015-04-23 17:31:25 -04:00
1 parent 59d5a9d259
commit 56d90a8321
36 files changed
+373 -294

No files matched your search

@@ -0,0 +1,57 @@
package com.cricketcraft.chisel.block;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.util.IIcon;
import com.cricketcraft.chisel.client.render.RendererMultiLayer;
public abstract class BlockMultiLayerBase extends Block {
public int currentPass;
public Block base;
public IIcon icon;
String iconFile;
public BlockMultiLayerBase(Material mat, Block base) {
super(mat);
this.base = base;
}
public BlockMultiLayerBase(Material mat, String iconFile) {
super(mat);
this.iconFile = iconFile;
}
@Override
public boolean renderAsNormalBlock() {
return false;
}
@Override
public int getRenderType() {
return RendererMultiLayer.id;
}
@Override
public int getRenderBlockPass() {
return 1;
}
@Override
public boolean canRenderInPass(int pass) {
currentPass = pass;
return pass == 1 || pass == 0;
}
@Override
public void registerBlockIcons(IIconRegister register) {
if (iconFile != null)
icon = register.registerIcon(iconFile);
}
}