mirror of
https://github.com/Ellpeck/ActuallyAdditions.git
synced 2024-11-26 00:38:35 +01:00
r144
also update jei deprecations
This commit is contained in:
parent
ebda3195bb
commit
6e46026e68
10 changed files with 83 additions and 72 deletions
|
@ -14,7 +14,7 @@ buildscript {
|
||||||
apply plugin: 'net.minecraftforge.gradle.forge'
|
apply plugin: 'net.minecraftforge.gradle.forge'
|
||||||
apply plugin: 'idea'
|
apply plugin: 'idea'
|
||||||
|
|
||||||
version = "1.12.2-r143"
|
version = "1.12.2-r144"
|
||||||
group = "de.ellpeck.actuallyadditions"
|
group = "de.ellpeck.actuallyadditions"
|
||||||
archivesBaseName = "ActuallyAdditions"
|
archivesBaseName = "ActuallyAdditions"
|
||||||
|
|
||||||
|
|
|
@ -10,20 +10,21 @@
|
||||||
|
|
||||||
package de.ellpeck.actuallyadditions.mod.jei.booklet;
|
package de.ellpeck.actuallyadditions.mod.jei.booklet;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
import de.ellpeck.actuallyadditions.api.booklet.IBookletChapter;
|
import de.ellpeck.actuallyadditions.api.booklet.IBookletChapter;
|
||||||
import de.ellpeck.actuallyadditions.api.booklet.IBookletPage;
|
import de.ellpeck.actuallyadditions.api.booklet.IBookletPage;
|
||||||
import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
|
import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
|
||||||
import de.ellpeck.actuallyadditions.mod.jei.RecipeWrapperWithButton;
|
import de.ellpeck.actuallyadditions.mod.jei.RecipeWrapperWithButton;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.StringUtil;
|
import de.ellpeck.actuallyadditions.mod.util.StringUtil;
|
||||||
import mezz.jei.api.ingredients.IIngredients;
|
import mezz.jei.api.ingredients.IIngredients;
|
||||||
|
import mezz.jei.api.ingredients.VanillaTypes;
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.util.text.TextFormatting;
|
import net.minecraft.util.text.TextFormatting;
|
||||||
import net.minecraftforge.fluids.FluidStack;
|
import net.minecraftforge.fluids.FluidStack;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
public class BookletRecipeWrapper extends RecipeWrapperWithButton {
|
public class BookletRecipeWrapper extends RecipeWrapperWithButton {
|
||||||
|
|
||||||
public final IBookletPage thePage;
|
public final IBookletPage thePage;
|
||||||
|
@ -36,13 +37,13 @@ public class BookletRecipeWrapper extends RecipeWrapperWithButton{
|
||||||
public void getIngredients(IIngredients ingredients) {
|
public void getIngredients(IIngredients ingredients) {
|
||||||
List<ItemStack> itemList = new ArrayList<ItemStack>();
|
List<ItemStack> itemList = new ArrayList<ItemStack>();
|
||||||
this.thePage.getItemStacksForPage(itemList);
|
this.thePage.getItemStacksForPage(itemList);
|
||||||
ingredients.setInputs(ItemStack.class, itemList);
|
ingredients.setInputs(VanillaTypes.ITEM, itemList);
|
||||||
ingredients.setOutputs(ItemStack.class, itemList);
|
ingredients.setOutputs(VanillaTypes.ITEM, itemList);
|
||||||
|
|
||||||
List<FluidStack> fluidList = new ArrayList<FluidStack>();
|
List<FluidStack> fluidList = new ArrayList<FluidStack>();
|
||||||
this.thePage.getFluidStacksForPage(fluidList);
|
this.thePage.getFluidStacksForPage(fluidList);
|
||||||
ingredients.setInputs(FluidStack.class, fluidList);
|
ingredients.setInputs(VanillaTypes.FLUID, fluidList);
|
||||||
ingredients.setOutputs(FluidStack.class, fluidList);
|
ingredients.setOutputs(VanillaTypes.FLUID, fluidList);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -26,6 +26,7 @@ import de.ellpeck.actuallyadditions.mod.items.metalists.TheMiscItems;
|
||||||
import de.ellpeck.actuallyadditions.mod.jei.RecipeWrapperWithButton;
|
import de.ellpeck.actuallyadditions.mod.jei.RecipeWrapperWithButton;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.StringUtil;
|
import de.ellpeck.actuallyadditions.mod.util.StringUtil;
|
||||||
import mezz.jei.api.ingredients.IIngredients;
|
import mezz.jei.api.ingredients.IIngredients;
|
||||||
|
import mezz.jei.api.ingredients.VanillaTypes;
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
|
|
||||||
|
@ -50,9 +51,9 @@ public class CoffeeMachineRecipeWrapper extends RecipeWrapperWithButton {
|
||||||
list.add(s);
|
list.add(s);
|
||||||
list.add(this.cup);
|
list.add(this.cup);
|
||||||
list.add(this.coffeeBeans);
|
list.add(this.coffeeBeans);
|
||||||
ingredients.setInputs(ItemStack.class, list);
|
ingredients.setInputs(VanillaTypes.ITEM, list);
|
||||||
|
|
||||||
ingredients.setOutput(ItemStack.class, this.theOutput);
|
ingredients.setOutput(VanillaTypes.ITEM, this.theOutput);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -19,6 +19,7 @@ import de.ellpeck.actuallyadditions.mod.booklet.misc.BookletUtils;
|
||||||
import de.ellpeck.actuallyadditions.mod.jei.RecipeWrapperWithButton;
|
import de.ellpeck.actuallyadditions.mod.jei.RecipeWrapperWithButton;
|
||||||
import de.ellpeck.actuallyadditions.mod.tile.TileEntityCompost;
|
import de.ellpeck.actuallyadditions.mod.tile.TileEntityCompost;
|
||||||
import mezz.jei.api.ingredients.IIngredients;
|
import mezz.jei.api.ingredients.IIngredients;
|
||||||
|
import mezz.jei.api.ingredients.VanillaTypes;
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
|
|
||||||
|
@ -32,8 +33,8 @@ public class CompostRecipeWrapper extends RecipeWrapperWithButton {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void getIngredients(IIngredients ingredients) {
|
public void getIngredients(IIngredients ingredients) {
|
||||||
ingredients.setInputs(ItemStack.class, Arrays.asList(recipe.getInput().getMatchingStacks()));
|
ingredients.setInputs(VanillaTypes.ITEM, Arrays.asList(recipe.getInput().getMatchingStacks()));
|
||||||
ingredients.setOutput(ItemStack.class, recipe.getOutput());
|
ingredients.setOutput(VanillaTypes.ITEM, recipe.getOutput());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -22,6 +22,7 @@ import de.ellpeck.actuallyadditions.mod.jei.RecipeWrapperWithButton;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.StackUtil;
|
import de.ellpeck.actuallyadditions.mod.util.StackUtil;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.StringUtil;
|
import de.ellpeck.actuallyadditions.mod.util.StringUtil;
|
||||||
import mezz.jei.api.ingredients.IIngredients;
|
import mezz.jei.api.ingredients.IIngredients;
|
||||||
|
import mezz.jei.api.ingredients.VanillaTypes;
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
|
|
||||||
|
@ -35,14 +36,14 @@ public class CrusherRecipeWrapper extends RecipeWrapperWithButton{
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void getIngredients(IIngredients ingredients) {
|
public void getIngredients(IIngredients ingredients) {
|
||||||
ingredients.setInputs(ItemStack.class, Arrays.asList(theRecipe.getInput().getMatchingStacks()));
|
ingredients.setInputs(VanillaTypes.ITEM, Arrays.asList(theRecipe.getInput().getMatchingStacks()));
|
||||||
|
|
||||||
List<ItemStack> list = new ArrayList<>();
|
List<ItemStack> list = new ArrayList<>();
|
||||||
list.add(this.theRecipe.getOutputOne());
|
list.add(this.theRecipe.getOutputOne());
|
||||||
if (StackUtil.isValid(this.theRecipe.getOutputTwo())) {
|
if (StackUtil.isValid(this.theRecipe.getOutputTwo())) {
|
||||||
list.add(this.theRecipe.getOutputTwo());
|
list.add(this.theRecipe.getOutputTwo());
|
||||||
}
|
}
|
||||||
ingredients.setOutputs(ItemStack.class, list);
|
ingredients.setOutputs(VanillaTypes.ITEM, list);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -19,6 +19,7 @@ import de.ellpeck.actuallyadditions.mod.blocks.InitBlocks;
|
||||||
import de.ellpeck.actuallyadditions.mod.booklet.misc.BookletUtils;
|
import de.ellpeck.actuallyadditions.mod.booklet.misc.BookletUtils;
|
||||||
import de.ellpeck.actuallyadditions.mod.jei.RecipeWrapperWithButton;
|
import de.ellpeck.actuallyadditions.mod.jei.RecipeWrapperWithButton;
|
||||||
import mezz.jei.api.ingredients.IIngredients;
|
import mezz.jei.api.ingredients.IIngredients;
|
||||||
|
import mezz.jei.api.ingredients.VanillaTypes;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
|
|
||||||
public class EmpowererRecipeWrapper extends RecipeWrapperWithButton {
|
public class EmpowererRecipeWrapper extends RecipeWrapperWithButton {
|
||||||
|
@ -43,8 +44,8 @@ public class EmpowererRecipeWrapper extends RecipeWrapperWithButton{
|
||||||
for (ItemStack s : theRecipe.getStandFour().getMatchingStacks())
|
for (ItemStack s : theRecipe.getStandFour().getMatchingStacks())
|
||||||
inputs.add(s);
|
inputs.add(s);
|
||||||
|
|
||||||
ingredients.setInputs(ItemStack.class, inputs);
|
ingredients.setInputs(VanillaTypes.ITEM, inputs);
|
||||||
ingredients.setOutput(ItemStack.class, this.theRecipe.getOutput());
|
ingredients.setOutput(VanillaTypes.ITEM, this.theRecipe.getOutput());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -18,6 +18,7 @@ import mezz.jei.api.IGuiHelper;
|
||||||
import mezz.jei.api.gui.IDrawable;
|
import mezz.jei.api.gui.IDrawable;
|
||||||
import mezz.jei.api.gui.IRecipeLayout;
|
import mezz.jei.api.gui.IRecipeLayout;
|
||||||
import mezz.jei.api.ingredients.IIngredients;
|
import mezz.jei.api.ingredients.IIngredients;
|
||||||
|
import mezz.jei.api.ingredients.VanillaTypes;
|
||||||
import mezz.jei.api.recipe.IRecipeCategory;
|
import mezz.jei.api.recipe.IRecipeCategory;
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
|
@ -61,8 +62,8 @@ public class ReconstructorRecipeCategory implements IRecipeCategory<Reconstructo
|
||||||
@Override
|
@Override
|
||||||
public void setRecipe(IRecipeLayout recipeLayout, ReconstructorRecipeWrapper wrapper, IIngredients ingredients) {
|
public void setRecipe(IRecipeLayout recipeLayout, ReconstructorRecipeWrapper wrapper, IIngredients ingredients) {
|
||||||
recipeLayout.getItemStacks().init(0, true, 4, 18);
|
recipeLayout.getItemStacks().init(0, true, 4, 18);
|
||||||
recipeLayout.getItemStacks().set(0, ingredients.getInputs(ItemStack.class).get(0).get(0));
|
recipeLayout.getItemStacks().set(0, ingredients.getInputs(VanillaTypes.ITEM).get(0).get(0));
|
||||||
recipeLayout.getItemStacks().init(1, false, 66, 18);
|
recipeLayout.getItemStacks().init(1, false, 66, 18);
|
||||||
recipeLayout.getItemStacks().set(1, ingredients.getOutputs(ItemStack.class).get(0).get(0));
|
recipeLayout.getItemStacks().set(1, ingredients.getOutputs(VanillaTypes.ITEM).get(0).get(0));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,6 +19,7 @@ import de.ellpeck.actuallyadditions.mod.booklet.misc.BookletUtils;
|
||||||
import de.ellpeck.actuallyadditions.mod.jei.RecipeWrapperWithButton;
|
import de.ellpeck.actuallyadditions.mod.jei.RecipeWrapperWithButton;
|
||||||
import de.ellpeck.actuallyadditions.mod.recipe.EnchBookConversion;
|
import de.ellpeck.actuallyadditions.mod.recipe.EnchBookConversion;
|
||||||
import mezz.jei.api.ingredients.IIngredients;
|
import mezz.jei.api.ingredients.IIngredients;
|
||||||
|
import mezz.jei.api.ingredients.VanillaTypes;
|
||||||
import mezz.jei.api.recipe.IRecipeWrapperFactory;
|
import mezz.jei.api.recipe.IRecipeWrapperFactory;
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.init.Items;
|
import net.minecraft.init.Items;
|
||||||
|
@ -42,8 +43,8 @@ public class ReconstructorRecipeWrapper extends RecipeWrapperWithButton {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void getIngredients(IIngredients ingredients) {
|
public void getIngredients(IIngredients ingredients) {
|
||||||
ingredients.setInputs(ItemStack.class, Arrays.asList(this.theRecipe.getInput().getMatchingStacks()));
|
ingredients.setInputs(VanillaTypes.ITEM, Arrays.asList(this.theRecipe.getInput().getMatchingStacks()));
|
||||||
ingredients.setOutput(ItemStack.class, this.theRecipe.getOutput());
|
ingredients.setOutput(VanillaTypes.ITEM, this.theRecipe.getOutput());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -86,8 +87,8 @@ public class ReconstructorRecipeWrapper extends RecipeWrapperWithButton {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void getIngredients(IIngredients ingredients) {
|
public void getIngredients(IIngredients ingredients) {
|
||||||
ingredients.setInput(ItemStack.class, BOOK);
|
ingredients.setInput(VanillaTypes.ITEM, BOOK);
|
||||||
ingredients.setOutput(ItemStack.class, OUT);
|
ingredients.setOutput(VanillaTypes.ITEM, OUT);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,3 +1,7 @@
|
||||||
|
# 1.12.2-r144
|
||||||
|
* Phantom Breakers should function properly again.
|
||||||
|
* Greenhouse Glass functions again (wasn't broken, but it works now)
|
||||||
|
|
||||||
# 1.12.2-r143
|
# 1.12.2-r143
|
||||||
* Greenhouse Glass will now work with any non-opaque block below it, instead of only air below it. Yes, this means they can stack.
|
* Greenhouse Glass will now work with any non-opaque block below it, instead of only air below it. Yes, this means they can stack.
|
||||||
* Greenhouse Glass should no longer crash if it is over the void.
|
* Greenhouse Glass should no longer crash if it is over the void.
|
||||||
|
|
|
@ -8,4 +8,4 @@
|
||||||
1.11.2=110
|
1.11.2=110
|
||||||
1.12=118
|
1.12=118
|
||||||
1.12.1=121
|
1.12.1=121
|
||||||
1.12.2=143
|
1.12.2=144
|
Loading…
Reference in a new issue