Jump to content

[1.12] JSON crafting recipes


Reyn

Recommended Posts

For the life of me I can't figure out why this recipe doesn't work in the new JSON system. The log shows this error

[main/ERROR] [FML]: Parsing error loading recipe tm:tutorial_helmet
com.google.gson.JsonSyntaxException: Unknown item 'tm:tutorial_ingot'

 

And this is the JSON file

{
    "type": "minecraft:crafting_shaped",
    "pattern": [
        "III",
        "I I",
        "   "
    ],
    "key": {
        "I": {
            "item": "tm:tutorial_ingot"
        }
    },
    "result": {
        "item": "tm:tutorial_helmet"
    }
}

 

 

Edited by Reyn
Link to comment
Share on other sites

A mod ID that is only 2 characters long is not really a good idea. It's best if you make it at least 3, might be related to your other problem.

 

Also, if you have a completely blank row or column in a recipe (cough, you do) just omit it, or it forces the recipe into the top two rows.

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.

Link to comment
Share on other sites

1 hour ago, Reyn said:

What is the issue with 2 character modids?

Too easy for two different mods to try and use the same mod ID

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.

Link to comment
Share on other sites

1 hour ago, IceMetalPunk said:

In your case, are you registering the tm:tutorial_ingot in the RegistryEvent<Item> handler?

I was under the impression that the recipes only had to be in the recipe asset folder? If not how do I register the JSON recipe?

 

Also, in a test environment with only my mod, would the 2 character modid cause this issue?

Edited by Reyn
Link to comment
Share on other sites

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.