Jump to content

[solved][1.13.2] how to use forge ore dictionary in recipes?


Recommended Posts

Posted (edited)

The recipes of my mod as used in 1.12.x are not working in 1.13.2.

the recipes are for example

Spoiler

{
  "type": "crafting_shaped",
  "pattern": [
    "  S",
    " - ",
    "N  "
  ],
  "key": {
    "S": {
      "type": "forge:ore_dict",
      "ore": "stone"
    },
    "-":{
      "type": "forge:ore_dict",
      "ore": "stickWood"
    },
    "N":{
      "type": "forge:ore_dict",
      "ore": "nuggetGold"
    }
  },
  "result": {
    "item": "buildhelper:fillwandstone_item"
  }
}

the error message I am receiving for this recipe is

Spoiler

[14:51:35.794] [Server thread/ERROR] [minecraft/RecipeManager]: Parsing error loading recipe buildhelper:fillwandstone_item
com.google.gson.JsonSyntaxException: Unknown ingredient type: forge:ore_dict
    at net.minecraftforge.common.crafting.CraftingHelper.getIngredient(CraftingHelper.java:216) ~[?:?]
    at net.minecraft.item.crafting.Ingredient.fromJson(Ingredient.java:189) ~[?:?]
    at net.minecraft.item.crafting.ShapedRecipe.deserializeKey(ShapedRecipe.java:259) ~[?:?]
    at net.minecraft.item.crafting.ShapedRecipe.access$000(ShapedRecipe.java:25) ~[?:?]
    at net.minecraft.item.crafting.ShapedRecipe$Serializer.read(ShapedRecipe.java:283) ~[?:?]
    at net.minecraft.item.crafting.ShapedRecipe$Serializer.read(ShapedRecipe.java:279) ~[?:?]
    at net.minecraft.item.crafting.RecipeSerializers.deserialize(RecipeSerializers.java:47) ~[?:?]
    at net.minecraft.item.crafting.RecipeManager.onResourceManagerReload(RecipeManager.java:54) [?:?]
    at net.minecraft.resources.SimpleReloadableResourceManager.triggerReloadListeners(SimpleReloadableResourceManager.java:125) [?:?]
    at net.minecraft.resources.SimpleReloadableResourceManager.reload(SimpleReloadableResourceManager.java:101) [?:?]
    at net.minecraft.server.MinecraftServer.loadDataPacks(MinecraftServer.java:1378) [?:?]
    at net.minecraft.server.MinecraftServer.loadDataPacks(MinecraftServer.java:375) [?:?]
    at net.minecraft.server.integrated.IntegratedServer.loadAllWorlds(IntegratedServer.java:75) [?:?]
    at net.minecraft.server.integrated.IntegratedServer.init(IntegratedServer.java:95) [?:?]
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:549) [?:?]
    at java.lang.Thread.run(Thread.java:745) [?:1.8.0_66]

How should I use the ingredient type in 1.13.2?

Edited by Torojima

running minecraft on Mac OS X - Sierra --- creating code since 1986 ... --- मेरा दिल भारतवासी है!

width=289 height=100http://www.arno-saxena.de/pictures/chococraft/banner_signature.png[/img]

Posted (edited)

yeah, the links are not really helping me, I know them already and my json syntax is good...

Edit: but it probably will help whoever is surfing in from somewhere reading this question :)

 

Anyway, the package net.minecraftforge.oredict has been removed from forge?! That's the reason the old entries are no longer valid. I've changed them all to minecraft items (except a few tags using the forge versions for the metal parts) and now it works.

 

Thus the correct answer would be to use the minecraft items in the recipes in 1.13.x since forge oredict is no longer available.

Edited by Torojima

running minecraft on Mac OS X - Sierra --- creating code since 1986 ... --- मेरा दिल भारतवासी है!

width=289 height=100http://www.arno-saxena.de/pictures/chococraft/banner_signature.png[/img]

Posted
3 hours ago, Torojima said:

yeah, the links are not really helping me, I know them already and my json syntax is good...

Edit: but it probably will help whoever is surfing in from somewhere reading this question :)

 

Anyway, the package net.minecraftforge.oredict has been removed from forge?! That's the reason the old entries are no longer valid. I've changed them all to minecraft items (except a few tags using the forge versions for the metal parts) and now it works.

 

Thus the correct answer would be to use the minecraft items in the recipes in 1.13.x since forge oredict is no longer available.

 

Tags are the replacement for the Ore Dictionary. To my knowledge, every Ore Dictionary entry that was provided by Forge itself has been replaced with a corresponding item tag.

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Posted

Makes sense :) because I now are using stuff like

"tag": "forge:nuggets/gold" and "tag": "forge:ingots/gold"

instead of formerly

"type": "forge:ore_dict","ore": "nuggetGold" and "type": "forge:ore_dict","ore": "ingotGold"

this is working well of course :D

 

But what I haven't found yet is a substitute for "type": "forge:ore_dict", "ore": "treeSapling", or "type": "forge:ore_dict","ore": "stickWood" so my mod would be able to use all other mods stick or sapling derivatives. I fell back to the minecraft vanilla "item": "minecraft:stick" and "tag": "minecraft:saplings". But now users can only use the vanilla items for the recipes obviously :)

 

The "tag": "forge:stick/wood" didn't do the trick... Is there a list of available forge tags to use. Since you (@Choonster) mentioned the forge oredict items are now probably available as tags, I would like to use them.

running minecraft on Mac OS X - Sierra --- creating code since 1986 ... --- मेरा दिल भारतवासी है!

width=289 height=100http://www.arno-saxena.de/pictures/chococraft/banner_signature.png[/img]

Posted (edited)
4 hours ago, Torojima said:

The "tag": "forge:stick/wood" didn't do the trick... Is there a list of available forge tags to use. Since you (@Choonster) mentioned the forge oredict items are now probably available as tags, I would like to use them.

 

All of the Forge and Vanilla tag JSON files should be visible in the Forge JAR in your IDE. You can see exactly which tags exist and which items they contain.

Edited by Choonster

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

  • 1 year later...
Posted (edited)

The sacred texts! I'm going to be crucified for necro-ing this, but how would one implement "tag": "minecraft:saplings" as a substitute for ore:treeSapling (or another way that includes all modded saplings)? I don't have IDE to refer to, as I'm asking for CraftTweaker rather than mod development. 

Edited by urbanxx001
Posted (edited)
2 hours ago, urbanxx001 said:

The sacred texts! I'm going to be crucified for necro-ing this

No shit. Start your own thread.

2 hours ago, urbanxx001 said:

I don't have IDE to refer to, as I'm asking for CraftTweaker rather than mod development.

Then why are you here and not asking for help where CraftTweaker is the subject? This is the Forge forums, we help people with Forge.

Secondly, with JSON recipes, CraftTweaker is completely unneccessary.

Edited by Draco18s

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.

Posted (edited)

 

Quote

Then why are you here?

Because Forge and CraftTweaker share syntaxI figured it out and it was indeed <tag:minecraft:sapling>. I prefer it over individual JSON files as all the recipes can be stored in one script, which is less daunting for larger modpacks. 

Edited by urbanxx001
  • Guest locked this topic
Guest
This topic is now closed to further replies.

Announcements



×
×
  • Create New...

Important Information

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