@Override
@SideOnly(Side.CLIENT)
public void initModel() {
StateMapperBase ignoreState = new StateMapperBase() {
@Override
protected ModelResourceLocation getModelResourceLocation(IBlockState iBlockState) {
return ModelPipeBaked.BAKED_MODEL;
}
};
ModelLoader.setCustomStateMapper(this, ignoreState);
ModelResourceLocation itemModelResourceLocation = new ModelResourceLocation(getRegistryName(), "inventory");
//for(PipeType type : PipeType.values())
// Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(Item.getItemFromBlock(this), type.getMeta(), itemModelResourceLocation);
for(PipeType type : PipeType.values())
ModelLoader.setCustomModelResourceLocation(Item.getItemFromBlock(this), type.getMeta(), itemModelResourceLocation);
ClientRegistry.bindTileEntitySpecialRenderer(TileEntityPipe.class, new TileEntityPipeRenderer());
}
BlockPipe.java 文件源码
java
阅读 25
收藏 0
点赞 0
评论 0
项目:CrystalMod
作者:
评论列表
文章目录