Posted July 14, 201411 yr Ok so the title basically says it all: how can I create a non-standard block (block that is not a full 1 * 1 * 1 opaque cube) like an anvil, torch, repeater, etc from vanilla minecraft. I have looked in all of the relevant code but I didn't understand it further than fact that they all had these booleans and different textures for each side / part of the block. public boolean renderAsNormalBlock() { return false; } public boolean isOpaqueCube() { return false; } I have included both booleans in my code and have the following code rendering the different textures for the top, side and bottom of the block: protected IIcon MagStandBottom; protected IIcon MagStandSide; protected IIcon MagStandTop; @Override public void registerBlockIcons(IIconRegister p_149651_1_) { MagStandBottom = p_149651_1_.registerIcon("techcraft:MagStandBottom"); MagStandSide = p_149651_1_.registerIcon("techcraft:MagStandSide"); MagStandTop = p_149651_1_.registerIcon("techcraft:MagStandTop"); } @Override public IIcon getIcon(int side, int metadata) { if (side == 0) { return MagStandBottom; } else if (side==1) { return MagStandTop; } else { return MagStandSide; } } It renders the different sides and I can't place torches or redstone on it, but how can move the sides inwards or have legs on it (like the cauldron)? Thanks for helping, Toastrackenigma
July 14, 201411 yr Make a class implementing ISimpleBlockRendererHandler , and register this handler. There should be tutorials on the subject. Also, please use [ code ] tags for short snippets of code, and gists for longer snippets with line numbers and syntax highlighting.
July 14, 201411 yr Hi > Make a class implementing ISimpleBlockRendererHandler, and register this handler. There should be tutorials on the subject. What she said, plus this link which might help you understand what you're seeing in vanilla: http://greyminecraftcoder.blogspot.com.au/p/list-of-topics.html (See the Block Rendering topics) -TGG
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.