Fixed all remaining compile errors (mind the TODOs, a lot of things are disabled)

This commit is contained in:
Frank 2021-12-07 17:42:18 +01:00
parent 108d2bd710
commit 6c89c76c26
34 changed files with 241 additions and 430 deletions

View file

@ -1,16 +1,18 @@
package ru.betterend.integration.rei;
import java.util.List;
import java.util.stream.Collectors;
import com.google.common.collect.Lists;
import me.shedaniel.rei.api.client.plugins.REIClientPlugin;
import me.shedaniel.rei.api.client.registry.category.CategoryRegistry;
import me.shedaniel.rei.api.client.registry.display.DisplayRegistry;
import me.shedaniel.rei.api.common.category.CategoryIdentifier;
import me.shedaniel.rei.api.common.entry.EntryIngredient;
import me.shedaniel.rei.api.common.entry.EntryStack;
import me.shedaniel.rei.api.common.util.EntryIngredients;
import me.shedaniel.rei.api.common.util.EntryStacks;
import me.shedaniel.rei.plugin.common.DefaultPlugin;
import net.fabricmc.fabric.impl.content.registry.FuelRegistryImpl;
import net.minecraft.resources.ResourceLocation;
import net.minecraft.world.item.ItemStack;
import net.minecraft.world.item.crafting.BlastingRecipe;
@ -24,10 +26,6 @@ import ru.betterend.recipe.builders.AlloyingRecipe;
import ru.betterend.recipe.builders.InfusionRecipe;
import ru.betterend.registry.EndBlocks;
import java.util.Collections;
import java.util.List;
import java.util.stream.Collectors;
//https://github.com/shedaniel/RoughlyEnoughItems/blob/6.x-1.17/default-plugin/src/main/java/me/shedaniel/rei/plugin/client/DefaultClientPlugin.java
public class REIPlugin implements REIClientPlugin {
public final static ResourceLocation PLUGIN_ID = BetterEnd.makeID("rei_plugin");
@ -54,13 +52,14 @@ public class REIPlugin implements REIClientPlugin {
registry.registerRecipeFiller(BlastingRecipe.class, RecipeType.BLASTING, REIBlastingDisplay::new);
registry.registerRecipeFiller(AnvilRecipe.class, AnvilRecipe.TYPE, REIAnvilDisplay::new);
registry.registerRecipeFiller(InfusionRecipe.class, InfusionRecipe.TYPE, REIInfusionDisplay::new);
FuelRegistryImpl.INSTANCE.getFuelTimes().forEach((item, time) -> {
if (time >= 2000) {
final List<EntryIngredient> list = Collections.singletonList(EntryIngredients.of(item));
registry.add(new REIAlloyingFuelDisplay(list, time));
}
});
//TODO: 1.18 REI fix this
// FuelRegistryImpl.INSTANCE.getFuelTimes().forEach((item, time) -> {
// if (time >= 2000) {
// final List<EntryIngredient> list = Collections.singletonList(EntryIngredients.of(item));
// registry.add(new REIAlloyingFuelDisplay(list, time));
// }
// });
}
@Override