Posted September 26, 20169 yr I've been trying to solve this for days now... I've made some custom doors and the door item refuses to find Its model... Sorry for additional post, but for the life of me, nothing works. The door block renders and functions normally. MAIN public static Block AppleDoor; public static Item AppleDoorItem; ... @EventHandler public void init(FMLInitializationEvent event) { String wood = "apple"; AppleDoor = createDoor(wood); AppleDoorItem = create_door(wood,(BlockDoor)AppleDoor); Minecraft.getMinecraft().getRenderItem().getItemModelMesher() .register(AppleDoorItem, 0, new ModelResourceLocation(MODID+":"+wood +"_door", "inventory")); System.out.println(AppleDoorItem); } private static BlockDoor createDoor(String wood){ BlockDoor block = new BlockVarietyDoor(wood); block.setUnlocalizedName(MODID+"."+wood+"_door"); GameRegistry.registerBlock(block,null,wood+"_door"); return block; } private static Item create_door(String wood,BlockDoor door){ Item i = new ItemVarietyDoor(wood,door); i.setUnlocalizedName(MODID+"."+wood+"_door"); String regName = wood+"_door"; GameRegistry.registerItem(i, regName); return i; } ItemVarietyDoor public class ItemVarietyDoor extends ItemDoor{ public ItemVarietyDoor(String wood,Block block) { super(block); this.setUnlocalizedName(VarietyTrees.MODID+"."+wood+"_door"); } } models/item/apple_door.json { "parent": "item/door_item", "textures": { "bottom": "varietytrees:blocks/door_apple_lower", "top": "varietytrees:blocks/door_apple_upper" } } models/block/apple_door_XXX all look basically like this { "parent": "block/door_top", "textures": { "bottom": "varietytrees:blocks/door_apple_lower", "top": "varietytrees:blocks/door_apple_upper" } } blockstates.json { "variants": { "facing=east,half=lower,hinge=left,open=false,powered=false": { "model": "varietytrees:apple_door_bottom" }, "facing=south,half=lower,hinge=left,open=false,powered=false": { "model": "varietytrees:apple_door_bottom", "y": 90 }, "facing=west,half=lower,hinge=left,open=false,powered=false": { "model": "varietytrees:apple_door_bottom", "y": 180 }, "facing=north,half=lower,hinge=left,open=false,powered=false": { "model": "varietytrees:apple_door_bottom", "y": 270 }, "facing=east,half=lower,hinge=right,open=false,powered=false": { "model": "varietytrees:apple_door_bottom_rh" }, "facing=south,half=lower,hinge=right,open=false,powered=false": { "model": "varietytrees:apple_door_bottom_rh", "y": 90 }, "facing=west,half=lower,hinge=right,open=false,powered=false": { "model": "varietytrees:apple_door_bottom_rh", "y": 180 }, "facing=north,half=lower,hinge=right,open=false,powered=false": { "model": "varietytrees:apple_door_bottom_rh", "y": 270 }, "facing=east,half=lower,hinge=left,open=true,powered=false": { "model": "varietytrees:apple_door_bottom_rh", "y": 90 }, "facing=south,half=lower,hinge=left,open=true,powered=false": { "model": "varietytrees:apple_door_bottom_rh", "y": 180 }, "facing=west,half=lower,hinge=left,open=true,powered=false": { "model": "varietytrees:apple_door_bottom_rh", "y": 270 }, "facing=north,half=lower,hinge=left,open=true,powered=false": { "model": "varietytrees:apple_door_bottom_rh" }, "facing=east,half=lower,hinge=right,open=true,powered=false": { "model": "varietytrees:apple_door_bottom", "y": 270 }, "facing=south,half=lower,hinge=right,open=true,powered=false": { "model": "varietytrees:apple_door_bottom" }, "facing=west,half=lower,hinge=right,open=true,powered=false": { "model": "varietytrees:apple_door_bottom", "y": 90 }, "facing=north,half=lower,hinge=right,open=true,powered=false": { "model": "varietytrees:apple_door_bottom", "y": 180 }, "facing=east,half=upper,hinge=left,open=false,powered=false": { "model": "varietytrees:apple_door_top" }, "facing=south,half=upper,hinge=left,open=false,powered=false": { "model": "varietytrees:apple_door_top", "y": 90 }, "facing=west,half=upper,hinge=left,open=false,powered=false": { "model": "varietytrees:apple_door_top", "y": 180 }, "facing=north,half=upper,hinge=left,open=false,powered=false": { "model": "varietytrees:apple_door_top", "y": 270 }, "facing=east,half=upper,hinge=right,open=false,powered=false": { "model": "varietytrees:apple_door_top_rh" }, "facing=south,half=upper,hinge=right,open=false,powered=false": { "model": "varietytrees:apple_door_top_rh", "y": 90 }, "facing=west,half=upper,hinge=right,open=false,powered=false": { "model": "varietytrees:apple_door_top_rh", "y": 180 }, "facing=north,half=upper,hinge=right,open=false,powered=false": { "model": "varietytrees:apple_door_top_rh", "y": 270 }, "facing=east,half=upper,hinge=left,open=true,powered=false": { "model": "varietytrees:apple_door_top_rh", "y": 90 }, "facing=south,half=upper,hinge=left,open=true,powered=false": { "model": "varietytrees:apple_door_top_rh", "y": 180 }, "facing=west,half=upper,hinge=left,open=true,powered=false": { "model": "varietytrees:apple_door_top_rh", "y": 270 }, "facing=north,half=upper,hinge=left,open=true,powered=false": { "model": "varietytrees:apple_door_top_rh" }, "facing=east,half=upper,hinge=right,open=true,powered=false": { "model": "varietytrees:apple_door_top", "y": 270 }, "facing=south,half=upper,hinge=right,open=true,powered=false": { "model": "varietytrees:apple_door_top" }, "facing=west,half=upper,hinge=right,open=true,powered=false": { "model": "varietytrees:apple_door_top", "y": 90 }, "facing=north,half=upper,hinge=right,open=true,powered=false": { "model": "varietytrees:apple_door_top", "y": 180 }, "facing=east,half=lower,hinge=left,open=false,powered=true": { "model": "varietytrees:apple_door_bottom" }, "facing=south,half=lower,hinge=left,open=false,powered=true": { "model": "varietytrees:apple_door_bottom", "y": 90 }, "facing=west,half=lower,hinge=left,open=false,powered=true": { "model": "varietytrees:apple_door_bottom", "y": 180 }, "facing=north,half=lower,hinge=left,open=false,powered=true": { "model": "varietytrees:apple_door_bottom", "y": 270 }, "facing=east,half=lower,hinge=right,open=false,powered=true": { "model": "varietytrees:apple_door_bottom_rh" }, "facing=south,half=lower,hinge=right,open=false,powered=true": { "model": "varietytrees:apple_door_bottom_rh", "y": 90 }, "facing=west,half=lower,hinge=right,open=false,powered=true": { "model": "varietytrees:apple_door_bottom_rh", "y": 180 }, "facing=north,half=lower,hinge=right,open=false,powered=true": { "model": "varietytrees:apple_door_bottom_rh", "y": 270 }, "facing=east,half=lower,hinge=left,open=true,powered=true": { "model": "varietytrees:apple_door_bottom_rh", "y": 90 }, "facing=south,half=lower,hinge=left,open=true,powered=true": { "model": "varietytrees:apple_door_bottom_rh", "y": 180 }, "facing=west,half=lower,hinge=left,open=true,powered=true": { "model": "varietytrees:apple_door_bottom_rh", "y": 270 }, "facing=north,half=lower,hinge=left,open=true,powered=true": { "model": "varietytrees:apple_door_bottom_rh" }, "facing=east,half=lower,hinge=right,open=true,powered=true": { "model": "varietytrees:apple_door_bottom", "y": 270 }, "facing=south,half=lower,hinge=right,open=true,powered=true": { "model": "varietytrees:apple_door_bottom" }, "facing=west,half=lower,hinge=right,open=true,powered=true": { "model": "varietytrees:apple_door_bottom", "y": 90 }, "facing=north,half=lower,hinge=right,open=true,powered=true": { "model": "varietytrees:apple_door_bottom", "y": 180 }, "facing=east,half=upper,hinge=left,open=false,powered=true": { "model": "varietytrees:apple_door_top" }, "facing=south,half=upper,hinge=left,open=false,powered=true": { "model": "varietytrees:apple_door_top", "y": 90 }, "facing=west,half=upper,hinge=left,open=false,powered=true": { "model": "varietytrees:apple_door_top", "y": 180 }, "facing=north,half=upper,hinge=left,open=false,powered=true": { "model": "varietytrees:apple_door_top", "y": 270 }, "facing=east,half=upper,hinge=right,open=false,powered=true": { "model": "varietytrees:apple_door_top_rh" }, "facing=south,half=upper,hinge=right,open=false,powered=true": { "model": "varietytrees:apple_door_top_rh", "y": 90 }, "facing=west,half=upper,hinge=right,open=false,powered=true": { "model": "varietytrees:apple_door_top_rh", "y": 180 }, "facing=north,half=upper,hinge=right,open=false,powered=true": { "model": "varietytrees:apple_door_top_rh", "y": 270 }, "facing=east,half=upper,hinge=left,open=true,powered=true": { "model": "varietytrees:apple_door_top_rh", "y": 90 }, "facing=south,half=upper,hinge=left,open=true,powered=true": { "model": "varietytrees:apple_door_top_rh", "y": 180 }, "facing=west,half=upper,hinge=left,open=true,powered=true": { "model": "varietytrees:apple_door_top_rh", "y": 270 }, "facing=north,half=upper,hinge=left,open=true,powered=true": { "model": "varietytrees:apple_door_top_rh" }, "facing=east,half=upper,hinge=right,open=true,powered=true": { "model": "varietytrees:apple_door_top", "y": 270 }, "facing=south,half=upper,hinge=right,open=true,powered=true": { "model": "varietytrees:apple_door_top" }, "facing=west,half=upper,hinge=right,open=true,powered=true": { "model": "varietytrees:apple_door_top", "y": 90 }, "facing=north,half=upper,hinge=right,open=true,powered=true": { "model": "varietytrees:apple_door_top", "y": 180 } } } Console Output: [FML]: Model definition for location varietytrees:apple_door#inventory not found I've read plenty of tutorials and troubleshooting on this, so please don't send those, either it's not that or I'm not doing it right. Help!
September 26, 20169 yr Add an inventory tag ie "inventory": "modid:texture location" VANILLA MINECRAFT CLASSES ARE THE BEST RESOURCES WHEN MODDING I will be posting 1.15.2 modding tutorials on this channel. If you want to be notified of it do the normal YouTube stuff like subscribing, ect. Forge and vanilla BlockState generator.
September 26, 20169 yr Author appending "inventory": {"texture": "varietytrees:items/door_apple"} to my blockstates didn't work and crashed the game with "Missing model, expected to find a string" file was valid json.
September 26, 20169 yr You need to specify it as an object, not an array: "inventory": [{ "texture": "varietytrees:items/door_apple" }], Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable. If you think this is the case, JUST REPORT ME. Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice. Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked. DO NOT PM ME WITH PROBLEMS. No help will be given.
September 27, 20169 yr Author hm. That changed stuff but didn't fix it. now Ive got: MultiModel minecraft:builtin/missing is empty (no base model or parts were provided/resolved) Which I don't think is important. And "Model definition not found" went away, but the item is still the missing model cube.
September 27, 20169 yr hm. That changed stuff but didn't fix it. now Ive got: MultiModel minecraft:builtin/missing is empty (no base model or parts were provided/resolved) Which I don't think is important. And "Model definition not found" went away, but the item is still the missing model cube. You shoudl be using ModelLoader.setCustomModelResourceLocation(...) instead of the ItemModelMesher.register(...) and it belongs in preInit. VANILLA MINECRAFT CLASSES ARE THE BEST RESOURCES WHEN MODDING I will be posting 1.15.2 modding tutorials on this channel. If you want to be notified of it do the normal YouTube stuff like subscribing, ect. Forge and vanilla BlockState generator.
September 27, 20169 yr Author How do I do that when It requires my item to be instantiated which also requires my door, which happens in Init? If I do it in preinit, I get a null pointer crash. If I do it where I had it, it changes nothing.
September 27, 20169 yr Blocks and Items need to be registered in preInit. You call ModelLoader.setCustomModelResourceLocation in your ClientProxy at the end of preInit, so your Blocks and Items will already be registered. Also, you need to update to 1.10.2. 1.7.10 is no longer supported, and 1.8 won't be supported very soon, if it isn't already. 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/
September 29, 20169 yr Author Unfortunately, that also did not work, and I have no other useful info to give. And i'm developing for 1.8 through 1.10.2, I just start with 1.8.
September 29, 20169 yr Unfortunately, that also did not work, and I have no other useful info to give. And i'm developing for 1.8 through 1.10.2, I just start with 1.8. You should post updated code and the log if there are any errors. VANILLA MINECRAFT CLASSES ARE THE BEST RESOURCES WHEN MODDING I will be posting 1.15.2 modding tutorials on this channel. If you want to be notified of it do the normal YouTube stuff like subscribing, ect. Forge and vanilla BlockState generator.
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.