aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/me/shedaniel/rei/plugin/smithing/DefaultSmithingDisplay.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/me/shedaniel/rei/plugin/smithing/DefaultSmithingDisplay.java')
-rw-r--r--src/main/java/me/shedaniel/rei/plugin/smithing/DefaultSmithingDisplay.java13
1 files changed, 10 insertions, 3 deletions
diff --git a/src/main/java/me/shedaniel/rei/plugin/smithing/DefaultSmithingDisplay.java b/src/main/java/me/shedaniel/rei/plugin/smithing/DefaultSmithingDisplay.java
index 05b5bbc87..97ea39ed7 100644
--- a/src/main/java/me/shedaniel/rei/plugin/smithing/DefaultSmithingDisplay.java
+++ b/src/main/java/me/shedaniel/rei/plugin/smithing/DefaultSmithingDisplay.java
@@ -27,7 +27,8 @@ import com.google.common.collect.Lists;
import me.shedaniel.rei.api.EntryStack;
import me.shedaniel.rei.api.RecipeDisplay;
import me.shedaniel.rei.plugin.DefaultPlugin;
-import me.shedaniel.rei.utils.CollectionUtils;
+import net.fabricmc.api.EnvType;
+import net.fabricmc.api.Environment;
import net.minecraft.recipe.SmithingRecipe;
import net.minecraft.util.Identifier;
import org.jetbrains.annotations.NotNull;
@@ -37,6 +38,7 @@ import java.util.Collections;
import java.util.List;
import java.util.Optional;
+@Environment(EnvType.CLIENT)
public class DefaultSmithingDisplay implements RecipeDisplay {
@NotNull
private List<List<EntryStack>> input;
@@ -48,8 +50,8 @@ public class DefaultSmithingDisplay implements RecipeDisplay {
public DefaultSmithingDisplay(@NotNull SmithingRecipe recipe) {
this(
Lists.newArrayList(
- EntryStack.create(recipe.base),
- EntryStack.create(recipe.addition)
+ EntryStack.ofIngredient(recipe.base),
+ EntryStack.ofIngredient(recipe.addition)
),
Collections.singletonList(EntryStack.create(recipe.getOutput())),
recipe.getId()
@@ -74,6 +76,11 @@ public class DefaultSmithingDisplay implements RecipeDisplay {
}
@Override
+ public List<List<EntryStack>> getRequiredEntries() {
+ return getInputEntries();
+ }
+
+ @Override
public Identifier getRecipeCategory() {
return DefaultPlugin.SMITHING;
}