Ensure that EmiRecipeHandler#craft automatically returns to the previous screen
raoulvdberge opened this issue ยท 1 comments
Currently, I need to do something like this myself:
@Override
public boolean craft(final EmiRecipe recipe, final EmiCraftContext<CraftingGridContainerMenu> context) {
final List<List<ItemResource>> inputs = recipe.getInputs()
.stream()
.map(this::getStacks)
.toList();
context.getScreenHandler().transferRecipe(inputs);
Minecraft.getInstance().setScreen(context.getScreen());
return true;
}