PaperMC/patches/server/0393-Expose-game-version.patch

25 lines
920 B
Diff
Raw Normal View History

2021-06-11 14:02:28 +02:00
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Mark Vainomaa <mikroskeem@mikroskeem.eu>
Date: Fri, 1 May 2020 17:39:26 +0300
Subject: [PATCH] Expose game version
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
2022-12-07 21:16:54 +01:00
index e28b973efe4f107d0a0d18dd2492f03ce2b424e9..c2e018cc05d6c6aaa615150ab4b62b85acfe1d05 100644
2021-06-11 14:02:28 +02:00
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
2022-12-07 21:16:54 +01:00
@@ -592,6 +592,13 @@ public final class CraftServer implements Server {
return this.bukkitVersion;
2021-06-11 14:02:28 +02:00
}
+ // Paper start - expose game version
+ @Override
+ public String getMinecraftVersion() {
+ return console.getServerVersion();
+ }
+ // Paper end
+
@Override
public List<CraftPlayer> getOnlinePlayers() {
return this.playerView;