From 21f5867e6e732350a62f1b0d72c4aefb2c313f64 Mon Sep 17 00:00:00 2001 From: Allink Date: Tue, 9 May 2023 18:28:23 +0100 Subject: [PATCH] Updated to 1.19.4 Closes #14, #16 --- gradle.properties | 8 ++++---- .../songplayer/mixin/ClientPlayNetworkHandlerMixin.java | 5 ++--- .../github/hhhzzzsss/songplayer/mixin/InGameHudMixin.java | 4 ++-- src/main/resources/fabric.mod.json | 2 +- 4 files changed, 9 insertions(+), 10 deletions(-) diff --git a/gradle.properties b/gradle.properties index e9e9a4d..2008fdc 100644 --- a/gradle.properties +++ b/gradle.properties @@ -4,9 +4,9 @@ org.gradle.parallel=true # Fabric Properties # check these on https://fabricmc.net/use - minecraft_version=1.19.3 - yarn_mappings=1.19.3+build.5 - loader_version=0.14.12 + minecraft_version=1.19.4 + yarn_mappings=1.19.4+build.2 + loader_version=0.14.19 # Mod Properties mod_version = 2.0.3 @@ -15,4 +15,4 @@ org.gradle.parallel=true # Dependencies # currently not on the main fabric site, check on the maven: https://maven.fabricmc.net/net/fabricmc/fabric-api/fabric-api - fabric_version=0.71.0+1.19.3 + fabric_version=0.80.0+1.19.4 diff --git a/src/main/java/com/github/hhhzzzsss/songplayer/mixin/ClientPlayNetworkHandlerMixin.java b/src/main/java/com/github/hhhzzzsss/songplayer/mixin/ClientPlayNetworkHandlerMixin.java index 63abc5d..4319eb7 100644 --- a/src/main/java/com/github/hhhzzzsss/songplayer/mixin/ClientPlayNetworkHandlerMixin.java +++ b/src/main/java/com/github/hhhzzzsss/songplayer/mixin/ClientPlayNetworkHandlerMixin.java @@ -3,8 +3,8 @@ package com.github.hhhzzzsss.songplayer.mixin; import com.github.hhhzzzsss.songplayer.CommandProcessor; import com.github.hhhzzzsss.songplayer.playing.SongHandler; import com.github.hhhzzzsss.songplayer.playing.Stage; +import net.minecraft.network.packet.Packet; import net.minecraft.network.packet.s2c.play.PlayerRespawnS2CPacket; -import net.minecraft.text.Text; import org.spongepowered.asm.mixin.Mixin; import org.spongepowered.asm.mixin.Shadow; import org.spongepowered.asm.mixin.injection.At; @@ -15,7 +15,6 @@ import com.github.hhhzzzsss.songplayer.SongPlayer; import net.minecraft.client.network.ClientPlayNetworkHandler; import net.minecraft.network.ClientConnection; -import net.minecraft.network.Packet; import net.minecraft.network.packet.c2s.play.PlayerMoveC2SPacket; import net.minecraft.network.packet.s2c.play.GameJoinS2CPacket; @@ -28,7 +27,7 @@ public class ClientPlayNetworkHandlerMixin { connection = null; } - @Inject(at = @At("HEAD"), method = "sendPacket(Lnet/minecraft/network/Packet;)V", cancellable = true) + @Inject(at = @At("HEAD"), method = "sendPacket(Lnet/minecraft/network/packet/Packet;)V", cancellable = true) private void onSendPacket(Packet packet, CallbackInfo ci) { Stage stage = SongHandler.getInstance().stage; if (stage != null && packet instanceof PlayerMoveC2SPacket) { diff --git a/src/main/java/com/github/hhhzzzsss/songplayer/mixin/InGameHudMixin.java b/src/main/java/com/github/hhhzzzsss/songplayer/mixin/InGameHudMixin.java index 843162a..acc2739 100644 --- a/src/main/java/com/github/hhhzzzsss/songplayer/mixin/InGameHudMixin.java +++ b/src/main/java/com/github/hhhzzzsss/songplayer/mixin/InGameHudMixin.java @@ -21,8 +21,8 @@ public class InGameHudMixin { @Shadow private int heldItemTooltipFade; - @Inject(method = "render(Lnet/minecraft/client/util/math/MatrixStack;F)V", - at = @At(value = "INVOKE", target = "Lcom/mojang/blaze3d/systems/RenderSystem;enableBlend()V", ordinal = 4)) + @Inject(method = "render", + at = @At(value = "INVOKE", target = "Lcom/mojang/blaze3d/systems/RenderSystem;enableBlend()V", ordinal = 3)) private void onRender(MatrixStack matrixStack, float tickDelta, CallbackInfo ci) { ProgressDisplay.getInstance().onRenderHUD(matrixStack, scaledWidth, scaledHeight, heldItemTooltipFade); } diff --git a/src/main/resources/fabric.mod.json b/src/main/resources/fabric.mod.json index 6fe0003..52d2a81 100644 --- a/src/main/resources/fabric.mod.json +++ b/src/main/resources/fabric.mod.json @@ -28,7 +28,7 @@ "depends": { "fabricloader": ">=0.14.11", "fabric": "*", - "minecraft": "~1.19.3", + "minecraft": "~1.19.4", "java": ">=17" }, "suggests": {