Skip to content

Commit

Permalink
Fixed Brewing & Cauldron recipes including ingredient and `ingredie…
Browse files Browse the repository at this point in the history
…nts` option.
  • Loading branch information
WolfyScript committed Feb 10, 2022
1 parent 13ec344 commit e0db05b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,7 @@ public Ingredient getIngredient(int slot) {
return slot == 0 ? this.ingredients : this.allowedItems;
}

@JsonIgnore
public Ingredient getIngredient() {
return getIngredient(0);
}
Expand All @@ -170,6 +171,7 @@ private void setIngredient(int slot, Ingredient ingredient) {
}
}

@JsonIgnore
public void setIngredient(Ingredient ingredient) {
setIngredient(0, ingredient);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
import me.wolfyscript.customcrafting.gui.recipebook.ClusterRecipeBook;
import me.wolfyscript.lib.com.fasterxml.jackson.annotation.JacksonInject;
import me.wolfyscript.lib.com.fasterxml.jackson.annotation.JsonCreator;
import me.wolfyscript.lib.com.fasterxml.jackson.annotation.JsonIgnore;
import me.wolfyscript.lib.com.fasterxml.jackson.annotation.JsonProperty;
import me.wolfyscript.lib.com.fasterxml.jackson.core.JsonGenerator;
import me.wolfyscript.lib.com.fasterxml.jackson.databind.JsonNode;
Expand Down Expand Up @@ -175,6 +176,7 @@ public void setHandItem(CustomItem handItem) {
this.handItem = handItem;
}

@JsonIgnore
public Ingredient getIngredient() {
return getIngredient(0);
}
Expand All @@ -184,6 +186,7 @@ public Ingredient getIngredient(int slot) {
return this.ingredients;
}

@JsonIgnore
public void setIngredient(Ingredient ingredients) {
setIngredient(0, ingredients);
}
Expand Down

0 comments on commit e0db05b

Please sign in to comment.