Posted June 11, 201411 yr Hi, I'd like to know the best way to make custom iron bars. In my mod, I want to make bars you can file away. I just have problems making the block render like iron panes. Any help? [shadow=gray,left][glow=red,2,300]KEEGAN[/glow][/shadow]
June 12, 201411 yr In the getRenderType, use the render type of the iron bars block. Don't PM me with questions. They will be ignored! Make a thread on the appropriate board for support. 1.12 -> 1.13 primer by williewillus. 1.7.10 and older versions of Minecraft are no longer supported due to it's age! Update to the latest version for support. http://www.howoldisminecraft1710.today/
June 13, 201411 yr Author Which id is that? I can't find a list that is updated to include at least iron bars/glass panes [shadow=gray,left][glow=red,2,300]KEEGAN[/glow][/shadow]
June 13, 201411 yr Blocks.iron_bars.getRenderType(); As simple as that... Was that so hard to figure out? Don't PM me with questions. They will be ignored! Make a thread on the appropriate board for support. 1.12 -> 1.13 primer by williewillus. 1.7.10 and older versions of Minecraft are no longer supported due to it's age! Update to the latest version for support. http://www.howoldisminecraft1710.today/
June 15, 201411 yr Author Doh! I was thinking that method worked more as a set method than a get. Not sure why, it is called getRenderId() or Type() or whatever. I'm not at home right now so I have no clue. [shadow=gray,left][glow=red,2,300]KEEGAN[/glow][/shadow]
June 17, 201411 yr Author I did that, but it tells me that it can't cast my block to a BlockPane. I would chnage my super to BlockPane but I'm unsure of the first two and last variable i need to pass in. I know it's (String,string,material,boolean) I know the two strings are texture and blockname(from setBlockName), but which is which i'm not sure. The boolean, no clue. [shadow=gray,left][glow=red,2,300]KEEGAN[/glow][/shadow]
June 19, 201411 yr Author I changed my super to BlockPane, and had this in my constructor super("blockIronBarsBroken", "portalcube:blockIronBarsBroken", p_i45394_1_, false); And I get this error shortly after I either place a block or enter a world with the block in it. java.lang.NullPointerException: Unexpected error at net.minecraft.client.renderer.RenderBlocks.renderBlockPane(RenderBlocks.java:3110) at net.minecraft.client.renderer.RenderBlocks.renderBlockByRenderType(RenderBlocks.java:282) at net.minecraft.client.renderer.WorldRenderer.updateRenderer(WorldRenderer.java:181) at net.minecraft.client.renderer.RenderGlobal.updateRenderers(RenderGlobal.java:1522) at net.minecraft.client.renderer.EntityRenderer.renderWorld(EntityRenderer.java:1178) at net.minecraft.client.renderer.EntityRenderer.updateCameraAndRender(EntityRenderer.java:1011) at net.minecraft.client.Minecraft.runGameLoop(Minecraft.java:945) at net.minecraft.client.Minecraft.run(Minecraft.java:835) at net.minecraft.client.main.Main.main(SourceFile:103) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at net.minecraft.launchwrapper.Launch.launch(Launch.java:134) at net.minecraft.launchwrapper.Launch.main(Launch.java:28) In the version of forge I'm running, there's no source attachments, so I can't track the problem down. [shadow=gray,left][glow=red,2,300]KEEGAN[/glow][/shadow]
June 20, 201411 yr Author Yes. A superclass is a 'parent class' if you will. The superclass is whatever your class extends, which is where the super() methods come from. [shadow=gray,left][glow=red,2,300]KEEGAN[/glow][/shadow]
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.