This commit is contained in:
Shane Freeder 2019-12-10 23:56:33 +00:00
parent 4d2f85630a
commit 76169471d8
No known key found for this signature in database
GPG key ID: A3F61EA5A085289C
28 changed files with 146 additions and 160 deletions

View file

@ -1,4 +1,4 @@
From b23ef215ad1b3b0fa3048ea44fd244d0e42164a6 Mon Sep 17 00:00:00 2001
From c2f8a5c4612e7ece86b19e5a3f731c04949ec86f Mon Sep 17 00:00:00 2001
From: Zach Brown <zach@zachbr.io>
Date: Mon, 27 May 2019 01:10:06 -0500
Subject: [PATCH] Version Command 2.0
@ -72,7 +72,7 @@ index 72c5501e..c0ff133d 100644
// Paper end
}
diff --git a/src/main/java/org/bukkit/command/defaults/VersionCommand.java b/src/main/java/org/bukkit/command/defaults/VersionCommand.java
index 9d8360f7..b3345cba 100644
index cbce5244..0486abd1 100644
--- a/src/main/java/org/bukkit/command/defaults/VersionCommand.java
+++ b/src/main/java/org/bukkit/command/defaults/VersionCommand.java
@@ -1,5 +1,6 @@
@ -98,17 +98,7 @@ index 9d8360f7..b3345cba 100644
public VersionCommand(@NotNull String name) {
super(name);
@@ -41,8 +51,7 @@ public class VersionCommand extends BukkitCommand {
if (args.length == 0) {
sender.sendMessage("This server is running " + Bukkit.getName() + " version " + Bukkit.getVersion() + " (Implementing API version " + Bukkit.getBukkitVersion() + ")");
- sender.sendMessage(ChatColor.YELLOW + "This is a final build for 1.14.4. Please see https://www.spigotmc.org/go/1.14.4 for details about upgrading.");
- // sendVersion(sender);
+ sendVersion(sender); // Paper - Not dead yet, Jim!
} else {
StringBuilder name = new StringBuilder();
@@ -151,18 +160,18 @@ public class VersionCommand extends BukkitCommand {
@@ -150,18 +160,18 @@ public class VersionCommand extends BukkitCommand {
private void sendVersion(@NotNull CommandSender sender) {
if (hasVersion) {
@ -130,7 +120,7 @@ index 9d8360f7..b3345cba 100644
return;
}
versionWaiters.add(sender);
@@ -184,7 +193,12 @@ public class VersionCommand extends BukkitCommand {
@@ -183,7 +193,12 @@ public class VersionCommand extends BukkitCommand {
private void obtainVersion() {
String version = Bukkit.getVersion();
@ -144,7 +134,7 @@ index 9d8360f7..b3345cba 100644
if (version.startsWith("git-Spigot-")) {
String[] parts = version.substring("git-Spigot-".length()).split("-");
int cbVersions = getDistance("craftbukkit", parts[1].substring(0, parts[1].indexOf(' ')));
@@ -214,6 +228,9 @@ public class VersionCommand extends BukkitCommand {
@@ -213,6 +228,9 @@ public class VersionCommand extends BukkitCommand {
} else {
setVersionMessage("Unknown version, custom build?");
}
@ -154,7 +144,7 @@ index 9d8360f7..b3345cba 100644
}
private void setVersionMessage(@NotNull String msg) {
@@ -223,8 +240,13 @@ public class VersionCommand extends BukkitCommand {
@@ -222,8 +240,13 @@ public class VersionCommand extends BukkitCommand {
try {
hasVersion = true;
versionTaskStarted = false;
@ -169,7 +159,7 @@ index 9d8360f7..b3345cba 100644
}
versionWaiters.clear();
} finally {
@@ -232,6 +254,15 @@ public class VersionCommand extends BukkitCommand {
@@ -231,6 +254,15 @@ public class VersionCommand extends BukkitCommand {
}
}