diff --git a/build.gradle b/build.gradle index 1fa534a..dd9a7d1 100644 --- a/build.gradle +++ b/build.gradle @@ -37,7 +37,7 @@ minecraft { // // Use non-default mappings at your own risk. They may not always work. // Simply re-run your setup task after changing the mappings to update your workspace. - mappings channel: 'official', version: '1.18.1' + mappings channel: 'official', version: '1.18.2' // accessTransformer = file('src/main/resources/META-INF/accesstransformer.cfg') // Currently, this location cannot be changed from the default. @@ -132,7 +132,8 @@ repositories { dependencies { minecraft "net.minecraftforge:forge:${forge_version}" - implementation fg.deobf("mezz.jei:jei-${jei_version}") + implementation fg.deobf("mezz.jei:jei-${jei_version_api}") + implementation fg.deobf("mezz.jei:jei-${jei_version_core}") //runtimeOnly fg.deobf("mezz.jei:jei-${jei_version}") implementation fg.deobf("slimeknights.mantle:Mantle:${mantle_version}") diff --git a/gradle.properties b/gradle.properties index ea0d711..42d7134 100644 --- a/gradle.properties +++ b/gradle.properties @@ -3,6 +3,7 @@ org.gradle.jvmargs=-Xmx3G org.gradle.daemon=false -forge_version=1.18.1-39.0.66 -jei_version=1.18.1:9.2.3.84 -mantle_version=1.18.1-1.8.35 \ No newline at end of file +forge_version=1.18.2-40.1.0 +jei_version_api=1.18.2-common-api:10.1.0.202 +jei_version_core=1.18.2-common:10.1.0.202 +mantle_version=1.18.2-1.9.27 \ No newline at end of file diff --git a/src/main/java/at/ridgo8/moreoverlays/api/lightoverlay/LightScannerBase.java b/src/main/java/at/ridgo8/moreoverlays/api/lightoverlay/LightScannerBase.java index 749b9d1..928da51 100644 --- a/src/main/java/at/ridgo8/moreoverlays/api/lightoverlay/LightScannerBase.java +++ b/src/main/java/at/ridgo8/moreoverlays/api/lightoverlay/LightScannerBase.java @@ -1,6 +1,7 @@ package at.ridgo8.moreoverlays.api.lightoverlay; import at.ridgo8.moreoverlays.config.Config; +import net.minecraft.core.Holder; import net.minecraft.world.entity.MobCategory; import net.minecraft.world.entity.player.Player; import net.minecraft.core.BlockPos; @@ -84,8 +85,8 @@ public boolean shouldCheck(BlockPos pos, Level world) { if (Config.light_IgnoreSpawnList.get()) { return true; } - Biome biome = world.getBiome(pos); - return biome.getMobSettings().getCreatureProbability() > 0 && !biome.getMobSettings().getMobs(MobCategory.MONSTER).isEmpty(); + Holder biome = world.getBiome(pos); + return biome.value().getMobSettings().getCreatureProbability() > 0 && !biome.value().getMobSettings().getMobs(MobCategory.MONSTER).isEmpty(); } public abstract byte getSpawnModeAt(BlockPos pos, Level world); diff --git a/src/main/java/at/ridgo8/moreoverlays/itemsearch/GuiRenderer.java b/src/main/java/at/ridgo8/moreoverlays/itemsearch/GuiRenderer.java index 65010e0..68d61ef 100644 --- a/src/main/java/at/ridgo8/moreoverlays/itemsearch/GuiRenderer.java +++ b/src/main/java/at/ridgo8/moreoverlays/itemsearch/GuiRenderer.java @@ -198,7 +198,7 @@ private void checkSlots(AbstractContainerScreen container) { private boolean isSearchedItem(ItemStack stack) { if (emptyFilter) return true; else if (stack.isEmpty()) return false; - for (Object ingredient : JeiModule.filter.getFilteredIngredients(VanillaTypes.ITEM)) { + for (Object ingredient : JeiModule.filter.getFilteredIngredients(VanillaTypes.ITEM_STACK)) { if (ItemUtils.ingredientMatches(ingredient, stack)) { return true; } diff --git a/src/main/java/at/ridgo8/moreoverlays/itemsearch/JeiModule.java b/src/main/java/at/ridgo8/moreoverlays/itemsearch/JeiModule.java index dcd2719..05ac69c 100644 --- a/src/main/java/at/ridgo8/moreoverlays/itemsearch/JeiModule.java +++ b/src/main/java/at/ridgo8/moreoverlays/itemsearch/JeiModule.java @@ -8,7 +8,7 @@ import mezz.jei.api.runtime.IIngredientFilter; import mezz.jei.api.runtime.IIngredientListOverlay; import mezz.jei.api.runtime.IJeiRuntime; -import mezz.jei.gui.overlay.IngredientListOverlay; +import mezz.jei.common.gui.overlay.IngredientListOverlay; import net.minecraft.client.gui.components.EditBox; import net.minecraft.resources.ResourceLocation; import net.minecraft.world.item.ItemStack; diff --git a/src/main/java/at/ridgo8/moreoverlays/lightoverlay/integration/CustomSpawnerLightScanner.java b/src/main/java/at/ridgo8/moreoverlays/lightoverlay/integration/CustomSpawnerLightScanner.java index 3fc39c8..035c2c0 100644 --- a/src/main/java/at/ridgo8/moreoverlays/lightoverlay/integration/CustomSpawnerLightScanner.java +++ b/src/main/java/at/ridgo8/moreoverlays/lightoverlay/integration/CustomSpawnerLightScanner.java @@ -2,6 +2,7 @@ import at.ridgo8.moreoverlays.lightoverlay.LightScannerVanilla; import net.minecraft.core.BlockPos; +import net.minecraft.core.Holder; import net.minecraft.world.level.Level; import net.minecraft.world.level.biome.Biome; @@ -13,8 +14,8 @@ public class CustomSpawnerLightScanner extends LightScannerVanilla { @Override public boolean shouldCheck(BlockPos pos, Level world) { - Biome biome = world.getBiome(pos); - return biome.getMobSettings().getCreatureProbability() <= 0; + Holder biome = world.getBiome(pos); + return biome.value().getMobSettings().getCreatureProbability() <= 0; /* EnvironmentSettings environment = CMSUtils.getEnvironment(world);