From c6b67bd7dffa561d5d8ed5231fd6dd255ae268c4 Mon Sep 17 00:00:00 2001 From: JustRed23 Date: Thu, 27 Jun 2024 22:32:53 +0200 Subject: [PATCH 1/3] Fix bundle jar manifest to support the javaagent --- build_forge.gradle | 1 + 1 file changed, 1 insertion(+) diff --git a/build_forge.gradle b/build_forge.gradle index 5a22bc9e94..52a87faf67 100644 --- a/build_forge.gradle +++ b/build_forge.gradle @@ -1009,6 +1009,7 @@ tasks.register('kettingJar', Jar) { manifest{ attributes 'Main-Class': 'org.kettingpowered.launcher.Main' attributes 'Launcher-Agent-Class': 'org.kettingpowered.launcher.Main' + attributes 'Premain-Class': 'org.kettingpowered.launcher.Main' attributes 'Automatic-Module-Name': 'org.kettingpowered.kettinglauncher' attributes 'Bundled': 'true' attributes 'MinecraftVersion': MC_VERSION From a86484b7e1dc16819096aa2e578c560292266c63 Mon Sep 17 00:00:00 2001 From: JustRed23 Date: Thu, 27 Jun 2024 22:46:20 +0200 Subject: [PATCH 2/3] Fix datapacks taking a huge hit out of the server TPS --- .../minecraft/net/minecraft/commands/Commands.java.patch | 9 ++++++++- .../minecraft/server/ServerFunctionManager.java.patch | 2 +- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/patches/minecraft/net/minecraft/commands/Commands.java.patch b/patches/minecraft/net/minecraft/commands/Commands.java.patch index 266da11418..8074ef7401 100644 --- a/patches/minecraft/net/minecraft/commands/Commands.java.patch +++ b/patches/minecraft/net/minecraft/commands/Commands.java.patch @@ -218,12 +218,19 @@ if (commandnode.canUse(p_82115_)) { ArgumentBuilder argumentbuilder = (ArgumentBuilder)commandnode.createBuilder(); argumentbuilder.requires((p_82126_) -> { -@@ -358,7 +_,48 @@ +@@ -357,8 +_,55 @@ + }; } ++ //Ketting start - dispatcher redirection ++ public CommandDispatcher getDirectDispatcher() { ++ return this.dispatcher; ++ } ++ public CommandDispatcher getDispatcher() { + if (org.kettingpowered.ketting.common.utils.DispatcherRedirector.needsRedirect()) + return getForgeDispatcher().unwrap(); ++ //Ketting end return this.dispatcher; + } + diff --git a/patches/minecraft/net/minecraft/server/ServerFunctionManager.java.patch b/patches/minecraft/net/minecraft/server/ServerFunctionManager.java.patch index 82de7cedd7..4e776dcf04 100644 --- a/patches/minecraft/net/minecraft/server/ServerFunctionManager.java.patch +++ b/patches/minecraft/net/minecraft/server/ServerFunctionManager.java.patch @@ -5,7 +5,7 @@ public CommandDispatcher getDispatcher() { - return this.server.getCommands().getDispatcher(); -+ return this.server.vanillaCommandDispatcher.getDispatcher(); // CraftBukkit ++ return this.server.vanillaCommandDispatcher.getDirectDispatcher(); // CraftBukkit //Ketting - no need for redirecting } public void tick() { From 120b353bf64f519ab072b79814cc36e220647dbe Mon Sep 17 00:00:00 2001 From: JustRed23 Date: Thu, 27 Jun 2024 22:46:50 +0200 Subject: [PATCH 3/3] Version 0.2.32 --- gradle.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle.properties b/gradle.properties index adba5e2826..45e3151ddd 100644 --- a/gradle.properties +++ b/gradle.properties @@ -6,7 +6,7 @@ org.gradle.daemon=false JAVA_VERSION=17 MC_VERSION=1.20.1 FORGE_VERSION=47.3.1 -KETTING_VERSION=0.2.31 +KETTING_VERSION=0.2.32 MC_NEXT_VERSION=1.21 MCP_VERSION=20230612.114412 MAPPING_CHANNEL=official