Update JEI compat to latest
This commit is contained in:
parent
d51a908f6b
commit
0f26cbedd7
6 changed files with 31 additions and 52 deletions
|
@ -7,15 +7,8 @@ import WayofTime.bloodmagic.compat.jei.binding.BindingRecipeCategory;
|
|||
import WayofTime.bloodmagic.compat.jei.binding.BindingRecipeHandler;
|
||||
import WayofTime.bloodmagic.compat.jei.binding.BindingRecipeMaker;
|
||||
import mezz.jei.api.IModPlugin;
|
||||
import mezz.jei.api.IModRegistry;
|
||||
import mezz.jei.api.JEIPlugin;
|
||||
import mezz.jei.api.recipe.IRecipeCategory;
|
||||
import mezz.jei.api.recipe.IRecipeHandler;
|
||||
import mezz.jei.api.recipe.IRecipeTransferHelper;
|
||||
|
||||
import javax.annotation.Nonnull;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
@JEIPlugin
|
||||
public class BloodMagicPlugin implements IModPlugin {
|
||||
|
@ -26,38 +19,18 @@ public class BloodMagicPlugin implements IModPlugin {
|
|||
}
|
||||
|
||||
@Override
|
||||
@Nonnull
|
||||
public Iterable<? extends IRecipeCategory> getRecipeCategories() {
|
||||
return Arrays.asList(
|
||||
public void register(IModRegistry registry) {
|
||||
registry.addRecipeCategories(
|
||||
new AltarRecipeCategory(),
|
||||
new BindingRecipeCategory()
|
||||
);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Nonnull
|
||||
public Iterable<? extends IRecipeHandler> getRecipeHandlers() {
|
||||
return Arrays.asList(
|
||||
registry.addRecipeHandlers(
|
||||
new AltarRecipeHandler(),
|
||||
new BindingRecipeHandler()
|
||||
);
|
||||
}
|
||||
|
||||
@Nonnull
|
||||
public Iterable<? extends IRecipeTransferHelper> getRecipeTransferHelpers() {
|
||||
return Arrays.asList(
|
||||
|
||||
);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Nonnull
|
||||
public Iterable<Object> getRecipes() {
|
||||
List<Object> recipes = new ArrayList<Object>();
|
||||
|
||||
recipes.addAll(AltarRecipeMaker.getRecipes());
|
||||
recipes.addAll(BindingRecipeMaker.getRecipes());
|
||||
|
||||
return recipes;
|
||||
registry.addRecipes(AltarRecipeMaker.getRecipes());
|
||||
registry.addRecipes(BindingRecipeMaker.getRecipes());
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue