Posted May 20, 20169 yr I'm trying to create a wooden wall block that is a pane type block. I've written the code for the pane block and it works fine. The issue is, I want to create a wall block type for each type of wood in the game without coding each type individually. I have written a wood type class to store the wood types I want to use. How can I get all of the types to load in game using only one registry entry. WoodUtil: http://pastebin.com/3NG3e6jd Block Class: http://pastebin.com/jPi6iJb0 ModPaneBlock Class: http://pastebin.com/pERnHT8d
May 20, 20169 yr Author I do plan on adding wood blocks to my mod. So yes I'd like to be able to support them.
May 20, 20169 yr Author Could you have multiple blocks with 16 blockstates each to support them all? I would do this, but I want just one block with 6 different variants.
May 20, 20169 yr Author So I've written the code for the wall (looked at the BlockPlanks class for help) and the game crashes every time I try to load the game. WoodWall.class http://pastebin.com/DMamkFaW CommonProxy.class http://pastebin.com/Un6YXne4 Crash Report http://pastebin.com/P8GQAKfX
May 21, 20169 yr Author I've redone the WoodWall class. The game doesn't load if I try to make the WoodWall class extend BlockPane, but it does load if I just extend WoodWall from Block. When I extend the class from the Block class, 5 of the 6 blocks show up as type birch which is not what I want. New WoodWall.class http://pastebin.com/hgw8pkpt ItemBlockMeta.class http://pastebin.com/iAJxNqdj IMetaBlockName http://pastebin.com/3h9WdbQY
May 21, 20169 yr Author Originally I was going to use a switch statement, but decided against it. The only thing left I can't figure out is why I can't make this a PaneBlock.
May 21, 20169 yr Author Originally I was going to use a switch statement, but decided against it.Why? I don't know. I wasn't really thinking about what I was doing at the time. The only thing left I can't figure out is why I can't make this a PaneBlock. What's stopping you? (Hint: "it crashes" is not an answer to this question). Nothing is stopping me. I just have to figure out why exactly the game is crashing.
May 21, 20169 yr Author Nothing is stopping me. I just have to figure out why exactly the game is crashing. So your answer was "it's crashing" again. Crash Report http://pastebin.com/MSubae9U WoodWall.class http://pastebin.com/FFN9JZPW
May 22, 20169 yr Author I got the blocks working. One last question though. Do I have to make a .json model file for each variant of the block or do I need just one .json file (it'll be more than 1 because of all the direction .jsons needed for a pane block)
May 22, 20169 yr Author If I didn't want 1 blockstate json, would I need 12 model jsons for each variant plus a blockstate json for each variant?
May 22, 20169 yr Author I looked through the vanilla blockstates and models for the different stained glass panes. Each variant of the pane has it's own blockstate and each has 12 model jsons. I tried to do this for my panes as well and the models won't load. The inventory models load, but when placed in the world the block models don't load. Block Rendering Class http://pastebin.com/8Xr4007M Log when launching the game: (not sure if you needed this, but I included it anyway) http://pastebin.com/wJNir72c BlockState json for oak variant http://pastebin.com/i4nTMcGw
May 22, 20169 yr The blockstate.json is to lead to the different model variants of the block. The model.json is how it looks different from the other variants.
May 22, 20169 yr Author I did as you said to do and replaced ModelBakery.registerItemVariants and ItemModelMesher#register with ModelLoader.setCustomResourceLocation and the game crashes. Client Proxy http://pastebin.com/AkzMxzJk Crash Report http://pastebin.com/kt5g0RSN
May 22, 20169 yr Author Fixed client proxy, but the models still won't load Client Proxy http://pastebin.com/nJmf1EK3 Log http://pastebin.com/34xU7rKB WoodWall json http://pastebin.com/i4nTMcGw
May 22, 20169 yr Author There is no error in the log about anything called wood wall. This is why I'm confused. I can't figure it out. Here is what shows up in game.
May 22, 20169 yr Author Changed client proxy to select a variant, but nothing changed. The models still show up the same as before. http://pastebin.com/Tb4MVhFq
May 23, 20169 yr Author If I try to call registerBlocks from multiple classes, the game crashes with this error. http://pastebin.com/1Db2UUwm
May 23, 20169 yr Author I must have mis-interpreted what you meant. When you said, And why is registerBlocks called from the ClientProxy only? I though you meant call if from the CommonProxy as well.
May 23, 20169 yr Author I just noticed, you are not specifying any variant for your item model location. This means it will use "normal". How do I specify a variant? Also, what class could I look in for examples of PaneBlocks with variants?
May 23, 20169 yr Author I've written this model loading code to load my variants, but the blocks still show up as un-textured blocks. The models don't load either. The log is saying that it can't find the blockstate files, but I checked and they are in the blockstate folder. What am I doing wrong? ClientProxy: http://pastebin.com/XXK2yivY Log: http://pastebin.com/ZG4ZYH6h
May 23, 20169 yr Author Moved registerBlocks back to the CommonProxy. RegisterRender.RegisterModel is what registers the models for my items.(moved that up to preInit) BlockState Path C:\Users\Evan\Desktop\forge-1.8.9-11.15.1.1890-1.8.9-mdk\src\main\resources\assets\withermod\blockstates Model Path C:\Users\Evan\Desktop\forge-1.8.9-11.15.1.1890-1.8.9-mdk\src\main\resources\assets\withermod\blocks/models/block BlockState for woodWall_oak http://pastebin.com/UuP3E5aT BlockState for woodWall_spruce http://pastebin.com/7NWf7kAB Models for woodWall_oak http://pastebin.com/YwdV1RCP http://pastebin.com/y177VTZu http://pastebin.com/yDSyfiY2 http://pastebin.com/0BjPGBcu http://pastebin.com/EY78GRJw http://pastebin.com/ZHA30tjn http://pastebin.com/cH8pwMhy http://pastebin.com/y4jM6QH9 http://pastebin.com/ZHYR2H8s http://pastebin.com/Rt0nDfhQ http://pastebin.com/svCA20b1 http://pastebin.com/zUWs1a9U The model files for the spruce variant are the same except for the change in texture.
May 23, 20169 yr Author Moved registerBlocks back to the CommonProxy. RegisterRender.RegisterModel is what registers the models for my items.(moved that up to preInit) BlockState Path C:\Users\Evan\Desktop\forge-1.8.9-11.15.1.1890-1.8.9-mdk\src\main\resources\assets\withermod\blockstates Model Path C:\Users\Evan\Desktop\forge-1.8.9-11.15.1.1890-1.8.9-mdk\src\main\resources\assets\withermod\blocks/models/block BlockState for woodWall_oak http://pastebin.com/UuP3E5aT BlockState for woodWall_spruce http://pastebin.com/7NWf7kAB Models for woodWall_oak http://pastebin.com/YwdV1RCP http://pastebin.com/y177VTZu http://pastebin.com/yDSyfiY2 http://pastebin.com/0BjPGBcu http://pastebin.com/EY78GRJw http://pastebin.com/ZHA30tjn http://pastebin.com/cH8pwMhy http://pastebin.com/y4jM6QH9 http://pastebin.com/ZHYR2H8s http://pastebin.com/Rt0nDfhQ http://pastebin.com/svCA20b1 http://pastebin.com/zUWs1a9U The model files for the spruce variant are the same except for the change in texture.
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.