Skip to content

Commit

Permalink
Update to 1.20.2
Browse files Browse the repository at this point in the history
  • Loading branch information
isXander committed Sep 28, 2023
1 parent 8dd5acf commit ac6bb40
Show file tree
Hide file tree
Showing 17 changed files with 56 additions and 161 deletions.
6 changes: 3 additions & 3 deletions PATCHED.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,8 @@
| Basic | [MC-116379](https://bugs.mojang.com/browse/MC-116379) | Punching with a cast fishing rod in the off-hand detaches fishing line from rod |
| Basic | [MC-121772](https://bugs.mojang.com/browse/MC-121772) | Can't scroll while holding SHIFT on macOS |
| Basic | [MC-122627](https://bugs.mojang.com/browse/MC-122627) | Tab suggestion box has missing padding on right side |
| Basic | [MC-123739](https://bugs.mojang.com/browse/MC-123739) | Recipe book entries are not sorted in any meaningful manner. In fact, the order can even change randomly after a reload. |
| Basic | [MC-122477](https://bugs.mojang.com/browse/MC-122477) | Linux/GNU: Opening chat sometimes writes 't |
| Basic | [MC-127970](https://bugs.mojang.com/browse/MC-127970) | Using riptide on a trident with an item in your off-hand causes visual glitch with the item in your offhand |
| Basic | [MC-140646](https://bugs.mojang.com/browse/MC-140646) | Text fields don't scroll while selecting text with Shift |
| Basic | [MC-143474](https://bugs.mojang.com/browse/MC-143474) | Respawning causes your hotbar to reset to the first space |
| Basic | [MC-159163](https://bugs.mojang.com/browse/MC-159163) | Quickly pressing the sneak key causes the sneak animation to play twice |
| Basic | [MC-165381](https://bugs.mojang.com/browse/MC-165381) | Block breaking can be delayed by dropping/throwing the tool while breaking a block | |
Expand All @@ -50,7 +48,6 @@
| Basic | [MC-81773](https://bugs.mojang.com/browse/MC-81773) | Bows and tridents drawn in survival/creative/adventure mode can be released in spectator mode |
| Basic | [MC-88371](https://bugs.mojang.com/browse/MC-88371) | Ender Dragon flies down in the void when the exit portal is destroyed |
| Basic | [MC-89146](https://bugs.mojang.com/browse/MC-89146) | Pistons forget update when being reloaded |
| Basic | [MC-90084](https://bugs.mojang.com/browse/MC-90084) | When sitting in boats and boats with chest mobs legs penetrate the hull |
| Basic | [MC-93018](https://bugs.mojang.com/browse/MC-93018) | Wild wolves show breeding hearts but do not breed |
| Basic | [MC-100991](https://bugs.mojang.com/browse/MC-100991) | Killing entities with a fishing rod doesn't count as a kill |
| Basic | [MC-119417](https://bugs.mojang.com/browse/MC-119417) | A spectator can occupy a bed if they enter it and then are switched to spectator mode |
Expand Down Expand Up @@ -97,3 +94,6 @@ Bugs that this mod has patched but has been superseded by a vanilla update.
| [MC-228976](https://bugs.mojang.com/browse/MC-228976) | Entity collision is run on render thread | 1.19.3-pre3 |
| [MC-165595](https://bugs.mojang.com/browse/MC-165595) | Guardian beam does not render when over a certain "Time" in level.dat | 23w03a |
| [MC-162253](https://bugs.mojang.com/browse/MC-162253) | Lag spike when crossing certain chunk borders | 23w16a |
| [MC-121772](https://bugs.mojang.com/browse/MC-121772) | Can't scroll while holding SHIFT on macOS | 23w31a |
| [MC-140646](https://bugs.mojang.com/browse/MC-140646) | Text fields don't scroll while selecting text with Shift | 23w31a |
| [MC-90084](https://bugs.mojang.com/browse/MC-90084) | When sitting in boats and boats with chest mobs legs penetrate the hull | 23w31a |
7 changes: 4 additions & 3 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import ru.vyarus.gradle.plugin.python.task.PythonTask
plugins {
java

id("fabric-loom") version "1.2.+"
id("io.github.juuxel.loom-quiltflower") version "1.10.+"
id("fabric-loom") version "1.3.+"
id("io.github.juuxel.loom-vineflower") version "1.11.+"

id("com.modrinth.minotaur") version "2.7.+"
id("me.hypherionmc.cursegradle") version "2.+"
Expand All @@ -19,7 +19,7 @@ plugins {
}

group = "dev.isxander"
version = "1.20.1+2.0"
version = "1.20.2+1.0"

loom {
splitEnvironmentSourceSets()
Expand Down Expand Up @@ -71,6 +71,7 @@ repositories {
maven("https://maven.isxander.dev/snapshots")
maven("https://maven.terraformersmc.com")
maven("https://maven.quiltmc.org/repository/release")
maven("https://oss.sonatype.org/content/repositories/snapshots")
}

val minecraftVersion: String by project
Expand Down
4 changes: 4 additions & 0 deletions changelogs/1.20.2/1.20.2+1.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
- Update to 1.20.2
- Remove MC-121772 as it was fixed
- Remove MC-140646 as it was fixed
- Remove MC-90084 as it was fixed
14 changes: 7 additions & 7 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@ org.gradle.jvmargs=-Xmx4G
org.gradle.parallel=true
org.gradle.parallel.threads=2

minecraftVersion=1.20.1
fabricLoaderVersion=0.14.21
qmBuild=13
minecraftVersion=1.20.2
fabricLoaderVersion=0.14.22
qmBuild=1

# Libraries
fabricApiVersion=0.85.0+1.20.1
yaclVersion=3.0.3+1.20
mixinExtrasVersion=0.2.0-beta.8
modMenuVersion=7.0.0
fabricApiVersion=0.89.1+1.20.2
yaclVersion=3.2.1+1.20.2
mixinExtrasVersion=0.2.0-rc.4
modMenuVersion=8.0.0-beta.2
Original file line number Diff line number Diff line change
Expand Up @@ -50,14 +50,14 @@ protected void init() {

@Override
public void render(GuiGraphics graphics, int mouseX, int mouseY, float delta) {
this.renderBackground(graphics);
super.render(graphics, mouseX, mouseY, delta);

graphics.drawCenteredString(font, title, width / 2, 70, -1);
int y = 90;
for (FormattedCharSequence line : wrappedText) {
graphics.drawCenteredString(font, line, width / 2, y, -1);
y += font.lineHeight;
}
super.render(graphics, mouseX, mouseY, delta);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
import net.minecraft.world.level.block.entity.BlockEntity;

@BugFix(id = "MC-112730", category = FixCategory.BASIC, env = BugFix.Env.CLIENT)
@Mixin(targets = "net.minecraft.client.renderer.chunk.ChunkRenderDispatcher$RenderChunk$RebuildTask")
@Mixin(targets = "net.minecraft.client.renderer.chunk.SectionRenderDispatcher$RenderSection$RebuildTask")
public class ChunkRenderDispatcherRenderChunkRebuildTaskMixin {
/**
* Extremely annoying to make because:
Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,22 @@
import dev.isxander.debugify.fixes.BugFix;
import dev.isxander.debugify.fixes.FixCategory;
import net.minecraft.client.Minecraft;
import net.minecraft.client.multiplayer.ClientCommonPacketListenerImpl;
import net.minecraft.client.multiplayer.ClientPacketListener;
import net.minecraft.client.multiplayer.CommonListenerCookie;
import net.minecraft.client.player.LocalPlayer;
import net.minecraft.network.Connection;
import org.spongepowered.asm.mixin.Final;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.Shadow;
import org.spongepowered.asm.mixin.injection.At;

@BugFix(id = "MC-143474", category = FixCategory.BASIC, env = BugFix.Env.CLIENT)
@Mixin(ClientPacketListener.class)
public class ClientPacketListenerMixin {
@Shadow @Final private Minecraft minecraft;
public abstract class ClientPacketListenerMixin extends ClientCommonPacketListenerImpl {
protected ClientPacketListenerMixin(Minecraft client, Connection connection, CommonListenerCookie commonListenerCookie) {
super(client, connection, commonListenerCookie);
}

@ModifyExpressionValue(method = "handleRespawn", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/multiplayer/MultiPlayerGameMode;createPlayer(Lnet/minecraft/client/multiplayer/ClientLevel;Lnet/minecraft/stats/StatsCounter;Lnet/minecraft/client/ClientRecipeBook;ZZ)Lnet/minecraft/client/player/LocalPlayer;"))
private LocalPlayer persistInventorySlot(LocalPlayer newPlayer) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
import dev.isxander.debugify.fixes.BugFix;
import dev.isxander.debugify.fixes.FixCategory;
import net.minecraft.client.Minecraft;
import net.minecraft.client.multiplayer.ClientCommonPacketListenerImpl;
import net.minecraft.client.multiplayer.ClientPacketListener;
import net.minecraft.client.multiplayer.CommonListenerCookie;
import net.minecraft.network.Connection;
import net.minecraft.network.protocol.game.ClientGamePacketListener;
import net.minecraft.network.protocol.game.ClientboundSetEntityDataPacket;
import net.minecraft.network.syncher.EntityDataSerializers;
Expand All @@ -18,8 +21,10 @@

@BugFix(id = "MC-159163", category = FixCategory.BASIC, env = BugFix.Env.CLIENT)
@Mixin(ClientPacketListener.class)
public abstract class ClientPacketListenerMixin implements ClientGamePacketListener {
@Final @Shadow private Minecraft minecraft;
public abstract class ClientPacketListenerMixin extends ClientCommonPacketListenerImpl implements ClientGamePacketListener {
protected ClientPacketListenerMixin(Minecraft client, Connection connection, CommonListenerCookie commonListenerCookie) {
super(client, connection, commonListenerCookie);
}

@Inject(method = "handleSetEntityData", at = @At(value = "INVOKE", target = "Lnet/minecraft/network/syncher/SynchedEntityData;assignValues(Ljava/util/List;)V"), locals = LocalCapture.CAPTURE_FAILSOFT)
public void removeLocalEntityPose(ClientboundSetEntityDataPacket packet, CallbackInfo info, Entity entity) {
Expand Down
3 changes: 0 additions & 3 deletions src/client/resources/debugify.client.mixins.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,10 @@
"basic.mc111516.PlayerRendererMixin",
"basic.mc112730.ChunkRenderDispatcherRenderChunkRebuildTaskMixin",
"basic.mc116379.FishingHookRendererMixin",
"basic.mc121772.MouseHandlerMixin",
"basic.mc122477.EditBoxMixin",
"basic.mc122477.RenderSystemMixin",
"basic.mc122627.CommandSuggestionsMixin",
"basic.mc123739.ClientRecipeBookMixin",
"basic.mc127970.ItemInHandRendererMixin",
"basic.mc140646.EditBoxMixin",
"basic.mc143474.ClientPacketListenerMixin",
"basic.mc159163.ClientPacketListenerMixin",
"basic.mc165381.LocalPlayerMixin",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,13 @@

import dev.isxander.debugify.Debugify;
import dev.isxander.debugify.fixes.BugFixData;
import org.objectweb.asm.tree.ClassNode;
import org.spongepowered.asm.mixin.extensibility.IMixinConfig;
import org.spongepowered.asm.mixin.extensibility.IMixinErrorHandler;
import org.spongepowered.asm.mixin.extensibility.IMixinInfo;
import org.spongepowered.asm.service.MixinService;

import java.io.IOException;
import java.util.HashSet;
import java.util.Optional;
import java.util.Set;
Expand All @@ -24,7 +27,14 @@ public ErrorAction onApplyError(String targetClassName, Throwable th, IMixinInfo
}

private ErrorAction handleError(ErrorAction usualAction, IMixinInfo mixin) {
Optional<BugFixData> bugFix = MixinPlugin.getBugFixForMixin(mixin.getClassNode(0));
ClassNode classNode;
try {
classNode = MixinService.getService().getBytecodeProvider().getClassNode(mixin.getClassName(), false);
} catch (ClassNotFoundException | IOException e) {
return usualAction;
}

Optional<BugFixData> bugFix = MixinPlugin.getBugFixForMixin(classNode);
if (bugFix.isEmpty())
return usualAction;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@
import com.llamalad7.mixinextras.injector.ModifyExpressionValue;
import dev.isxander.debugify.fixes.BugFix;
import dev.isxander.debugify.fixes.FixCategory;
import net.minecraft.network.Connection;
import net.minecraft.server.MinecraftServer;
import net.minecraft.server.level.ServerPlayer;
import net.minecraft.server.network.CommonListenerCookie;
import net.minecraft.server.network.ServerCommonPacketListenerImpl;
import net.minecraft.server.network.ServerGamePacketListenerImpl;
import org.spongepowered.asm.mixin.Final;
import org.spongepowered.asm.mixin.Mixin;
Expand All @@ -13,11 +16,13 @@

@BugFix(id = "MC-14923", category = FixCategory.BASIC, env = BugFix.Env.SERVER)
@Mixin(ServerGamePacketListenerImpl.class)
public class ServerGamePacketListenerImplMixin {
@Shadow @Final private MinecraftServer server;

public abstract class ServerGamePacketListenerImplMixin extends ServerCommonPacketListenerImpl {
@Shadow public ServerPlayer player;

public ServerGamePacketListenerImplMixin(MinecraftServer server, Connection connection, CommonListenerCookie commonListenerCookie) {
super(server, connection, commonListenerCookie);
}

/**
* Currently, Minecraft checks if a player is OP to know to kick for spamming,
* but in singleplayer, with cheats off, you are not op-ed.
Expand Down

This file was deleted.

1 change: 0 additions & 1 deletion src/main/resources/debugify.mixins.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@
"basic.mc7569.RconConsoleSourceMixin",
"basic.mc88371.DragonLandingPhaseMixin",
"basic.mc89146.ChunkAccessMixin",
"basic.mc90084.BoatMixin",
"basic.mc93018.AnimalMixin",
"gameplay.mc31819.PlayerMixin",
"gameplay.mc8187.MixinTreeFeature"
Expand Down
4 changes: 2 additions & 2 deletions src/main/resources/fabric.mod.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@
],
"accessWidener": "debugify.accesswidener",
"depends": {
"fabricloader": ">=0.14.10",
"minecraft": "1.20.1",
"fabricloader": ">=0.14.22",
"minecraft": "1.20.2",
"java": ">=17",
"fabric-resource-loader-v0": "*"
},
Expand Down

0 comments on commit ac6bb40

Please sign in to comment.