Fix JEI compat

This commit is contained in:
Nicholas Ignoffo 2017-01-02 01:18:02 -08:00
parent 4ec321aaac
commit 574056203d
23 changed files with 100 additions and 244 deletions

View file

@ -1,5 +1,7 @@
package WayofTime.bloodmagic.compat.jei.armourDowngrade;
import WayofTime.bloodmagic.compat.jei.BloodMagicPlugin;
import com.google.common.collect.Lists;
import lombok.Getter;
import mezz.jei.api.ingredients.IIngredients;
import mezz.jei.api.recipe.BlankRecipeWrapper;
@ -8,6 +10,8 @@ import WayofTime.bloodmagic.api.recipe.LivingArmourDowngradeRecipe;
import WayofTime.bloodmagic.api.util.helper.ItemHelper.LivingUpgrades;
import WayofTime.bloodmagic.registry.ModItems;
import java.util.List;
public class ArmourDowngradeRecipeJEI extends BlankRecipeWrapper
{
@Getter
@ -20,7 +24,9 @@ public class ArmourDowngradeRecipeJEI extends BlankRecipeWrapper
@Override
public void getIngredients(IIngredients ingredients) {
// TODO - inputs
List<List<ItemStack>> expanded = BloodMagicPlugin.jeiHelper.getStackHelper().expandRecipeItemStackInputs(recipe.getInput());
expanded.add(Lists.newArrayList(recipe.getKey()));
ingredients.setInputLists(ItemStack.class, expanded);
ItemStack upgradeStack = new ItemStack(ModItems.UPGRADE_TOME);
LivingUpgrades.setUpgrade(upgradeStack, recipe.getRecipeOutput());
ingredients.setOutput(ItemStack.class, upgradeStack);