Started by
GaussianWonder
on
Topic category: Help with Minecraft modding (Java Edition)
I can't find any way to get the crafting recipes + ingredients of all registered items :(
I don't necessarily want all of them at once (although that would be nice since I could be done with the whole process at config event by registering a hashmap)
What I want to know is the crafting recipe of an item that's on slot(0) of my machine.
I found only one post about this topic, but it is using mc 1.12. ForgeRegistries.RECIPES does not exist anymore and ForgeRegisitries.RECIPE_SERIALIZERS seems to deal with serialization only :(
for(Map.Entry<RegistryKey<IRecipeSerializer<?>>, IRecipeSerializer<?>> entry: ForgeRegistries.RECIPE_SERIALIZERS.getEntries()) {
RegistryKey<IRecipeSerializer<?>> key = entry.getKey();
IRecipeSerializer<?> value = entry.getValue();
System.out.println("Key Location: " + key.getLocation());
System.out.println("Key Registry Name: " + key.getRegistryName());
System.out.println("Value Registry Name: " + value.getRegistryName());
}
This didn't really help me either