aboutsummaryrefslogtreecommitdiff
path: root/forge
diff options
context:
space:
mode:
Diffstat (limited to 'forge')
-rw-r--r--forge/build.gradle4
-rw-r--r--forge/src/main/java/me/shedaniel/rei/impl/client/forge/CommandSenderImpl.java60
-rw-r--r--forge/src/main/java/me/shedaniel/rei/impl/client/gui/forge/ScreenOverlayImplForge.java3
-rw-r--r--forge/src/main/java/me/shedaniel/rei/mixin/forge/MixinTagLoader.java3
-rw-r--r--forge/src/main/resources/META-INF/accesstransformer.cfg7
5 files changed, 9 insertions, 68 deletions
diff --git a/forge/build.gradle b/forge/build.gradle
index 2aa93e09e..25dd8cc0a 100644
--- a/forge/build.gradle
+++ b/forge/build.gradle
@@ -215,7 +215,7 @@ unifiedPublishing {
project {
displayName = "[Forge $rootProject.supported_version] v$project.version"
releaseType = "beta"
- gameVersions = ["1.19", "1.19.1", "1.19.2"]
+ gameVersions = ["1.19.3"]
gameLoaders = ["forge"]
changelog = rootProject.releaseChangelog
@@ -255,7 +255,7 @@ unifiedPublishing {
project {
displayName = "[Forge $rootProject.supported_version] v$project.version"
releaseType = "release"
- gameVersions = ["1.19", "1.19.1", "1.19.2"]
+ gameVersions = ["1.19.3"]
gameLoaders = ["forge"]
changelog = rootProject.releaseChangelog
diff --git a/forge/src/main/java/me/shedaniel/rei/impl/client/forge/CommandSenderImpl.java b/forge/src/main/java/me/shedaniel/rei/impl/client/forge/CommandSenderImpl.java
deleted file mode 100644
index 7916f8adc..000000000
--- a/forge/src/main/java/me/shedaniel/rei/impl/client/forge/CommandSenderImpl.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * This file is licensed under the MIT License, part of Roughly Enough Items.
- * Copyright (c) 2018, 2019, 2020, 2021, 2022, 2023 shedaniel
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in all
- * copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
- * SOFTWARE.
- */
-
-package me.shedaniel.rei.impl.client.forge;
-
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.player.LocalPlayer;
-import net.minecraftforge.fml.util.ObfuscationReflectionHelper;
-
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-
-public class CommandSenderImpl {
- public static void sendCommand(String command) {
- LocalPlayer player = Minecraft.getInstance().player;
- if (player == null) return;
- Method method = null;
- try {
- // 1.19
- method = ObfuscationReflectionHelper.findMethod(LocalPlayer.class, "m_234156_", String.class);
- } catch (ObfuscationReflectionHelper.UnableToFindMethodException ignored) {
- }
- if (method == null) {
- try {
- // 1.19.1
- method = ObfuscationReflectionHelper.findMethod(LocalPlayer.class, "m_242614_", String.class);
- } catch (ObfuscationReflectionHelper.UnableToFindMethodException ignored) {
- }
- }
- if (method == null) {
- throw new RuntimeException("Unable to find method");
- }
-
- try {
- method.invoke(player, command);
- } catch (IllegalAccessException | InvocationTargetException e) {
- throw new RuntimeException(e);
- }
- }
-}
diff --git a/forge/src/main/java/me/shedaniel/rei/impl/client/gui/forge/ScreenOverlayImplForge.java b/forge/src/main/java/me/shedaniel/rei/impl/client/gui/forge/ScreenOverlayImplForge.java
index ab013f179..832bd0b1d 100644
--- a/forge/src/main/java/me/shedaniel/rei/impl/client/gui/forge/ScreenOverlayImplForge.java
+++ b/forge/src/main/java/me/shedaniel/rei/impl/client/gui/forge/ScreenOverlayImplForge.java
@@ -31,6 +31,7 @@ import me.shedaniel.rei.api.common.util.CollectionUtils;
import me.shedaniel.rei.impl.client.gui.ScreenOverlayImpl;
import net.minecraft.client.gui.screens.Screen;
import net.minecraft.client.gui.screens.inventory.tooltip.ClientTooltipComponent;
+import net.minecraft.client.gui.screens.inventory.tooltip.DefaultTooltipPositioner;
import net.minecraft.network.chat.Component;
import net.minecraft.world.inventory.tooltip.TooltipComponent;
import net.minecraft.world.item.ItemStack;
@@ -61,7 +62,7 @@ public class ScreenOverlayImplForge extends ScreenOverlayImpl {
}
}
screen.tooltipStack = itemStack;
- screen.renderTooltipInternal(matrices, components, mouseX, mouseY);
+ screen.renderTooltipInternal(matrices, components, mouseX, mouseY, DefaultTooltipPositioner.INSTANCE);
screen.tooltipStack = ItemStack.EMPTY;
matrices.popPose();
}
diff --git a/forge/src/main/java/me/shedaniel/rei/mixin/forge/MixinTagLoader.java b/forge/src/main/java/me/shedaniel/rei/mixin/forge/MixinTagLoader.java
index 2f066b6ca..43a5b95c2 100644
--- a/forge/src/main/java/me/shedaniel/rei/mixin/forge/MixinTagLoader.java
+++ b/forge/src/main/java/me/shedaniel/rei/mixin/forge/MixinTagLoader.java
@@ -32,6 +32,7 @@ import me.shedaniel.rei.api.common.util.CollectionUtils;
import me.shedaniel.rei.impl.common.InternalLogger;
import me.shedaniel.rei.plugin.common.displays.tag.TagNodes;
import net.minecraft.core.Registry;
+import net.minecraft.core.registries.BuiltInRegistries;
import net.minecraft.resources.ResourceKey;
import net.minecraft.resources.ResourceLocation;
import net.minecraft.tags.TagEntry;
@@ -66,7 +67,7 @@ public class MixinTagLoader<T> {
TagNodes.TAG_DATA_MAP.put(resourceKey, new HashMap<>());
Map<ResourceLocation, TagNodes.TagData> tagDataMap = TagNodes.TAG_DATA_MAP.get(resourceKey);
if (tagDataMap == null) return;
- Registry<T> registry = ((Registry<Registry<T>>) Registry.REGISTRY).get((ResourceKey<Registry<T>>) resourceKey);
+ Registry<T> registry = ((Registry<Registry<T>>) BuiltInRegistries.REGISTRY).get((ResourceKey<Registry<T>>) resourceKey);
Stopwatch stopwatch = Stopwatch.createStarted();
Iterator<Map.Entry<TagNodes.CollectionWrapper<?>, TagNodes.RawTagData>> entryIterator = TagNodes.RAW_TAG_DATA_MAP.getOrDefault(directory, Reference2ObjectMaps.emptyMap())
diff --git a/forge/src/main/resources/META-INF/accesstransformer.cfg b/forge/src/main/resources/META-INF/accesstransformer.cfg
index 5d520302f..f421615ee 100644
--- a/forge/src/main/resources/META-INF/accesstransformer.cfg
+++ b/forge/src/main/resources/META-INF/accesstransformer.cfg
@@ -22,8 +22,7 @@ public net.minecraft.world.item.alchemy.PotionBrewing$Mix f_43533_
public net.minecraft.world.item.alchemy.PotionBrewing$Mix f_43534_
public net.minecraft.world.item.crafting.UpgradeRecipe f_44519_
public net.minecraft.world.item.crafting.UpgradeRecipe f_44518_
-public net.minecraft.world.item.CreativeModeTab f_40763_
-public net.minecraft.client.gui.GuiComponent m_93112_(Lcom/mojang/math/Matrix4f;IIIIIFFFF)V
+public net.minecraft.client.gui.GuiComponent m_93112_(Lorg/joml/Matrix4f;IIIIIFFFF)V
public net.minecraft.client.gui.screens.Screen m_7787_(Lnet/minecraft/client/gui/components/events/GuiEventListener;)Lnet/minecraft/client/gui/components/events/GuiEventListener;
public net.minecraft.client.gui.screens.Screen m_7856_()V
public net.minecraft.client.gui.screens.Screen m_6697_(Ljava/lang/String;Z)V
@@ -31,8 +30,8 @@ public net.minecraft.client.gui.screens.Screen m_96583_(Ljava/lang/String;CI)Z
public-f net.minecraft.client.gui.screens.inventory.AbstractContainerScreen f_97711_
protected net.minecraft.client.gui.screens.Screen m_6575_(Lnet/minecraft/client/Minecraft;II)V
public net.minecraft.client.gui.screens.Screen m_142416_(Lnet/minecraft/client/gui/components/events/GuiEventListener;)Lnet/minecraft/client/gui/components/events/GuiEventListener;
-public net.minecraft.client.gui.screens.Screen m_169394_(Lnet/minecraft/client/gui/components/Widget;)Lnet/minecraft/client/gui/components/Widget;
-public net.minecraft.client.gui.screens.Screen m_169383_(Lcom/mojang/blaze3d/vertex/PoseStack;Ljava/util/List;II)V
+public net.minecraft.client.gui.screens.Screen m_169394_(Lnet/minecraft/client/gui/components/Renderable;)Lnet/minecraft/client/gui/components/Renderable;
+public net.minecraft.client.gui.screens.Screen m_262809_(Lcom/mojang/blaze3d/vertex/PoseStack;Ljava/util/List;IILnet/minecraft/client/gui/screens/inventory/tooltip/ClientTooltipPositioner;)V # renderTooltipInternal
public net.minecraft.client.gui.screens.Screen tooltipStack
public net.minecraft.client.renderer.RenderType m_173209_(Ljava/lang/String;Lcom/mojang/blaze3d/vertex/VertexFormat;Lcom/mojang/blaze3d/vertex/VertexFormat$Mode;ILnet/minecraft/client/renderer/RenderType$CompositeState;)Lnet/minecraft/client/renderer/RenderType$CompositeRenderType;
public net.minecraft.client.renderer.RenderType$OutlineProperty