From e6586daeaa6f14a92f69d6107078b0601918fb36 Mon Sep 17 00:00:00 2001 From: AlphaKR93 Date: Tue, 28 May 2024 02:31:33 +0900 Subject: [PATCH] Fix startup --- patches/server/0004-Fork-friendly-Rebranding.patch | 12 ++++++------ patches/server/0006-Plazma-Configurations.patch | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/patches/server/0004-Fork-friendly-Rebranding.patch b/patches/server/0004-Fork-friendly-Rebranding.patch index c8b2bec6c..5c088df09 100644 --- a/patches/server/0004-Fork-friendly-Rebranding.patch +++ b/patches/server/0004-Fork-friendly-Rebranding.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Fork-friendly Rebranding diff --git a/build.gradle.kts b/build.gradle.kts -index c2a0dd63fe700484ac9473733b10615375d7c2b4..acca28dd3e99821e4f55794946ed27b7e8c780a5 100644 +index 80343712d0cb4e10d31581f36e487a0b35711cfe..afa4877ade6cf8b615ba70c1cf7a8c92040e924a 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -13,7 +13,7 @@ configurations.named(log4jPlugins.compileClasspathConfigurationName) { @@ -126,7 +126,7 @@ index 3cb56595822799926a8141e60a42f5d1edfc6de5..70d6e514870b5cdf529eb067137a5c15 .option(LineReader.Option.COMPLETE_IN_WORD, true); diff --git a/src/main/java/io/papermc/paper/ServerBrandConstants.java b/src/main/java/io/papermc/paper/ServerBrandConstants.java new file mode 100644 -index 0000000000000000000000000000000000000000..b085cb9b49f2b6b1ad72448959d57a5a7b1f1f21 +index 0000000000000000000000000000000000000000..af534fb15be2be3e5b4258c522e0e6c967c2bb1c --- /dev/null +++ b/src/main/java/io/papermc/paper/ServerBrandConstants.java @@ -0,0 +1,33 @@ @@ -137,7 +137,7 @@ index 0000000000000000000000000000000000000000..b085cb9b49f2b6b1ad72448959d57a5a +public enum ServerBrandConstants {; + + // Basic brand informations -+ protected static final String BRAND_NAME = "Plazma"; ++ public static final String BRAND_NAME = "Plazma"; + public static final String RESOURCE_PATH = "META-INF/maven/org.plazmamc.plazma/plazma-api/pom.properties"; + + @Nullable @@ -384,7 +384,7 @@ index 1090b7e36e3c1c105bc36135b82751c651f237d4..a5b3f9309393fd54c0aec2918410b331 private static CompoundTag readOversizedChunk(RegionFile regionfile, ChunkPos chunkCoordinate) throws IOException { diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java -index 549d01337e9a89b356287567db101de383d45c9c..234f1bf8be8838e1b10672c3209b9dde68114f2b 100644 +index 549d01337e9a89b356287567db101de383d45c9c..90d6650aa37247f3907f6bcf2fe5201cac4e05ea 100644 --- a/src/main/java/org/bukkit/craftbukkit/Main.java +++ b/src/main/java/org/bukkit/craftbukkit/Main.java @@ -143,7 +143,7 @@ public class Main { @@ -392,7 +392,7 @@ index 549d01337e9a89b356287567db101de383d45c9c..234f1bf8be8838e1b10672c3209b9dde this.acceptsAll(Main.asList("noconsole"), "Disables the console"); - this.acceptsAll(Main.asList("v", "version"), "Show the CraftBukkit Version"); -+ this.acceptsAll(Main.asList("v", "version"), "Show the " + io.papermc.paper.ServerBuildInfo.buildInfo().brandName() + " Version"); // Plazma - Fork-friendly Rebranding ++ this.acceptsAll(Main.asList("v", "version"), "Show the " + io.papermc.paper.ServerBrandConstants.BRAND_NAME + " Version"); // Plazma - Fork-friendly Rebranding this.acceptsAll(Main.asList("demo"), "Demo mode"); @@ -401,7 +401,7 @@ index 549d01337e9a89b356287567db101de383d45c9c..234f1bf8be8838e1b10672c3209b9dde .withRequiredArg() .ofType(String.class) - .defaultsTo("Unknown Server") -+ .defaultsTo("A " + io.papermc.paper.ServerBuildInfo.buildInfo().brandName() + " Server") // Plazma - Fork-friendly Rebranding ++ .defaultsTo("A " + io.papermc.paper.ServerBrandConstants.BRAND_NAME + " Server") // Plazma - Fork-friendly Rebranding .describedAs("Name"); // Paper end } diff --git a/patches/server/0006-Plazma-Configurations.patch b/patches/server/0006-Plazma-Configurations.patch index 273733528..82ac153e9 100644 --- a/patches/server/0006-Plazma-Configurations.patch +++ b/patches/server/0006-Plazma-Configurations.patch @@ -719,11 +719,11 @@ index 54c42f43981aee3da869343b078775fd39994b9e..58878900a1985d4dd23104ac594d5236 public void restart() { org.spigotmc.RestartCommand.restart(); diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java -index 234f1bf8be8838e1b10672c3209b9dde68114f2b..f84266bca823be3fe7d26ac59b181424e1e307ef 100644 +index 90d6650aa37247f3907f6bcf2fe5201cac4e05ea..24c3914ba4f144a2e43c17e98373b7a4ce1f6217 100644 --- a/src/main/java/org/bukkit/craftbukkit/Main.java +++ b/src/main/java/org/bukkit/craftbukkit/Main.java @@ -197,6 +197,14 @@ public class Main { - .defaultsTo("A " + io.papermc.paper.ServerBuildInfo.buildInfo().brandName() + " Server") // Plazma - Fork-friendly Rebranding + .defaultsTo("A " + io.papermc.paper.ServerBrandConstants.BRAND_NAME + " Server") // Plazma - Fork-friendly Rebranding .describedAs("Name"); // Paper end +