2021-06-11 14:02:28 +02:00
|
|
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
2022-08-01 16:01:20 +02:00
|
|
|
From: Nassim Jahnke <nassim@njahnke.dev>
|
2021-06-11 14:02:28 +02:00
|
|
|
Date: Fri, 26 Mar 2021 11:23:17 +0100
|
|
|
|
Subject: [PATCH] Expose protocol version
|
|
|
|
|
|
|
|
|
|
|
|
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
2024-10-24 19:29:35 +02:00
|
|
|
index e53610ac0ef0c80932e6e50f0c3971938b4bcf9b..e546cf93d79b109d50840ebf1fb133ad3c9331d3 100644
|
2021-06-11 14:02:28 +02:00
|
|
|
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
|
|
|
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
2024-10-21 00:06:54 +02:00
|
|
|
@@ -527,6 +527,11 @@ public final class CraftMagicNumbers implements UnsafeValues {
|
2024-04-27 01:43:59 +02:00
|
|
|
public String getMainLevelName() {
|
|
|
|
return ((net.minecraft.server.dedicated.DedicatedServer) net.minecraft.server.MinecraftServer.getServer()).getProperties().levelName;
|
2021-06-11 14:02:28 +02:00
|
|
|
}
|
|
|
|
+
|
|
|
|
+ @Override
|
|
|
|
+ public int getProtocolVersion() {
|
|
|
|
+ return net.minecraft.SharedConstants.getCurrentVersion().getProtocolVersion();
|
|
|
|
+ }
|
|
|
|
// Paper end
|
|
|
|
|
2024-05-11 23:48:37 +02:00
|
|
|
@Override
|