diff options
| author | shedaniel <daniel@shedaniel.me> | 2020-01-02 14:31:16 +0800 |
|---|---|---|
| committer | shedaniel <daniel@shedaniel.me> | 2020-01-02 14:31:16 +0800 |
| commit | 5e2eccadbd91171c01cdb209d1338bcfb7786b1c (patch) | |
| tree | 6c7387de5baea8b335e8abe58651018f77ad2d41 /src/main/java/me/shedaniel/rei/plugin/cooking/DefaultCookingDisplay.java | |
| parent | e8714fe8fc1dcaec7ad299c63e2b657870c8fb40 (diff) | |
| download | RoughlyEnoughItems-5e2eccadbd91171c01cdb209d1338bcfb7786b1c.tar.gz RoughlyEnoughItems-5e2eccadbd91171c01cdb209d1338bcfb7786b1c.tar.bz2 RoughlyEnoughItems-5e2eccadbd91171c01cdb209d1338bcfb7786b1c.zip | |
3.3
Fix #58
Close #134
Close #158
Fix #227
Diffstat (limited to 'src/main/java/me/shedaniel/rei/plugin/cooking/DefaultCookingDisplay.java')
| -rw-r--r-- | src/main/java/me/shedaniel/rei/plugin/cooking/DefaultCookingDisplay.java | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/main/java/me/shedaniel/rei/plugin/cooking/DefaultCookingDisplay.java b/src/main/java/me/shedaniel/rei/plugin/cooking/DefaultCookingDisplay.java index 7eec9a749..f1c33dd81 100644 --- a/src/main/java/me/shedaniel/rei/plugin/cooking/DefaultCookingDisplay.java +++ b/src/main/java/me/shedaniel/rei/plugin/cooking/DefaultCookingDisplay.java @@ -28,7 +28,7 @@ public abstract class DefaultCookingDisplay implements TransferRecipeDisplay { private AbstractCookingRecipe recipe; private List<List<EntryStack>> input; private List<EntryStack> output; - + public DefaultCookingDisplay(AbstractCookingRecipe recipe) { this.recipe = recipe; this.input = recipe.getPreviewInputs().stream().map(i -> { @@ -41,49 +41,49 @@ public abstract class DefaultCookingDisplay implements TransferRecipeDisplay { this.input.add(FurnaceBlockEntity.createFuelTimeMap().keySet().stream().map(Item::getStackForRender).map(EntryStack::create).map(e -> e.setting(EntryStack.Settings.TOOLTIP_APPEND_EXTRA, stack -> Collections.singletonList(Formatting.YELLOW.toString() + I18n.translate("category.rei.smelting.fuel")))).collect(Collectors.toList())); this.output = Collections.singletonList(EntryStack.create(recipe.getOutput())); } - + @Override public Optional<Identifier> getRecipeLocation() { return Optional.ofNullable(recipe).map(AbstractCookingRecipe::getId); } - + @Override public List<List<EntryStack>> getInputEntries() { return input; } - + @Override public List<EntryStack> getOutputEntries() { return output; } - + public List<EntryStack> getFuel() { return input.get(1); } - + @Override public List<List<EntryStack>> getRequiredEntries() { return input; } - + @Deprecated public Optional<AbstractCookingRecipe> getOptionalRecipe() { return Optional.ofNullable(recipe); } - + @Override public int getWidth() { return 1; } - + @Override public int getHeight() { return 1; } - + @Override public List<List<EntryStack>> getOrganisedInputEntries(ContainerInfo<Container> containerInfo, Container container) { return CollectionUtils.map(recipe.getPreviewInputs(), i -> CollectionUtils.map(i.getMatchingStacksClient(), EntryStack::create)); } - + } |
