From 2570a35b35ec29b6677e318f2bf3d5b6640bf106 Mon Sep 17 00:00:00 2001 From: Unknown Date: Sat, 13 Apr 2019 15:40:23 +0800 Subject: v2.7.3 Bug fixes Fix #56 --- .../java/me/shedaniel/rei/plugin/DefaultSmokingDisplay.java | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) (limited to 'src/main/java/me/shedaniel/rei/plugin/DefaultSmokingDisplay.java') diff --git a/src/main/java/me/shedaniel/rei/plugin/DefaultSmokingDisplay.java b/src/main/java/me/shedaniel/rei/plugin/DefaultSmokingDisplay.java index 988cd2b04..19adb3b97 100644 --- a/src/main/java/me/shedaniel/rei/plugin/DefaultSmokingDisplay.java +++ b/src/main/java/me/shedaniel/rei/plugin/DefaultSmokingDisplay.java @@ -8,7 +8,7 @@ import net.minecraft.item.ItemStack; import net.minecraft.recipe.cooking.SmokingRecipe; import net.minecraft.util.Identifier; -import java.util.Arrays; +import java.util.Collections; import java.util.List; import java.util.Optional; import java.util.stream.Collectors; @@ -21,14 +21,9 @@ public class DefaultSmokingDisplay implements RecipeDisplay { public DefaultSmokingDisplay(SmokingRecipe recipe) { this.display = recipe; - List fuel = Lists.newArrayList(); - this.input = Lists.newArrayList(); - fuel.addAll(FurnaceBlockEntity.createFuelTimeMap().keySet().stream().map(Item::getDefaultStack).collect(Collectors.toList())); - recipe.getPreviewInputs().forEach(ingredient -> { - input.add(Arrays.asList(ingredient.getStackArray())); - }); - input.add(fuel); - this.output = Arrays.asList(recipe.getOutput()); + this.input = Lists.newArrayList(recipe.getPreviewInputs().stream().map(i -> Lists.newArrayList(i.getStackArray())).collect(Collectors.toList())); + input.add(FurnaceBlockEntity.createFuelTimeMap().keySet().stream().map(Item::getDefaultStack).collect(Collectors.toList())); + this.output = Collections.singletonList(recipe.getOutput()); } @Override -- cgit