Add missing removeRecipe patch (#477)

This commit is contained in:
IzzelAliz 2022-02-08 12:04:39 +08:00
parent d11631c656
commit 5061aa5b6c
No known key found for this signature in database
GPG Key ID: EE50E123A11D8338

View File

@ -129,6 +129,13 @@ public abstract class RecipeManagerMixin implements RecipeManagerBridge {
addRecipe(recipe);
}
public boolean removeRecipe(ResourceLocation mcKey) {
for (var recipes : recipes.values()) {
recipes.remove(mcKey);
}
return byName.remove(mcKey) != null;
}
public void clearRecipes() {
this.recipes = new HashMap<>();
for (RecipeType<?> type : Registry.RECIPE_TYPE) {