Scissors/patches/server/0001-Build-changes.patch

79 lines
4.1 KiB
Diff
Raw Normal View History

2021-06-12 18:04:04 +00:00
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
2022-03-13 01:39:38 +00:00
From: Luna <lunahatesgogle@gmail.com>
Date: Sat, 12 Mar 2022 22:22:22 -0300
2021-06-12 18:04:04 +00:00
Subject: [PATCH] Build changes
diff --git a/build.gradle.kts b/build.gradle.kts
2022-04-15 01:07:20 +00:00
index c236fe5dc388f8bc0a929f1de04af94c63514208..c7c8b00a34cbc39f1003b618097bc1e2858823a1 100644
2021-06-12 18:04:04 +00:00
--- a/build.gradle.kts
+++ b/build.gradle.kts
2022-04-15 01:07:20 +00:00
@@ -13,8 +13,8 @@ plugins {
2021-06-12 18:04:04 +00:00
}
dependencies {
2022-03-13 01:39:38 +00:00
- implementation(project(":Paper-API"))
- implementation(project(":Paper-MojangAPI"))
+ implementation(project(":Scissors-API")) // Scissors
+ implementation("io.papermc.paper:paper-mojangapi:1.17.1-R0.1-SNAPSHOT") // Scissors
2021-06-12 18:04:04 +00:00
// Paper start
implementation("org.jline:jline-terminal-jansi:3.21.0")
implementation("net.minecrell:terminalconsoleappender:1.3.0")
2022-04-15 01:07:20 +00:00
@@ -66,7 +66,7 @@ tasks.jar {
2021-08-25 04:06:30 +00:00
attributes(
"Main-Class" to "org.bukkit.craftbukkit.Main",
"Implementation-Title" to "CraftBukkit",
- "Implementation-Version" to "git-Paper-$implementationVersion",
2022-03-13 01:39:38 +00:00
+ "Implementation-Version" to "git-Scissors-$implementationVersion", // Scissors
2021-08-25 04:06:30 +00:00
"Implementation-Vendor" to date, // Paper
"Specification-Title" to "Bukkit",
"Specification-Version" to project.version,
2022-04-15 01:07:20 +00:00
@@ -193,7 +193,7 @@ tasks.test {
2022-03-13 01:39:38 +00:00
fun TaskContainer.registerRunTask(
name: String, block: JavaExec.() -> Unit
2021-06-16 06:28:10 +00:00
): TaskProvider<JavaExec> = register<JavaExec>(name) {
- group = "paper"
+ group = "paperweight"
standardInput = System.`in`
2022-03-13 01:39:38 +00:00
workingDir = rootProject.layout.projectDirectory.dir(
providers.gradleProperty("runWorkDir").forUseAtConfigurationTime().orElse("run")
2021-06-12 18:04:04 +00:00
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
2022-04-15 01:07:20 +00:00
index 8091a901106a1085da9dfd8627dadcbe50f00872..e6da0f7e755e6b0225afbced2c7a14e9df83b09d 100644
2021-06-12 18:04:04 +00:00
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
2022-03-13 01:39:38 +00:00
@@ -1729,7 +1729,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
2021-06-12 18:04:04 +00:00
@DontObfuscate
public String getServerModName() {
2021-09-25 02:10:14 +00:00
- return "Paper"; // Paper - Paper > // Spigot - Spigot > // CraftBukkit - cb > vanilla!
2022-03-13 01:39:38 +00:00
+ return "Scissors"; // Scissors - Scissors > // Paper - Paper > // Spigot - Spigot > // CraftBukkit - cb > vanilla!
2021-06-12 18:04:04 +00:00
}
2021-08-25 04:06:30 +00:00
public SystemReport fillSystemReport(SystemReport details) {
2021-06-12 18:04:04 +00:00
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
2022-03-13 01:39:38 +00:00
index 99a94898316b0601f55b333c15a9926eae24f8a2..cc797b45674163b5913e20031d110796d78b928b 100644
2021-06-12 18:04:04 +00:00
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
2022-03-13 01:39:38 +00:00
@@ -251,7 +251,7 @@ import javax.annotation.Nullable; // Paper
2021-06-12 18:04:04 +00:00
import javax.annotation.Nonnull; // Paper
public final class CraftServer implements Server {
- private final String serverName = "Paper"; // Paper
2022-03-13 01:39:38 +00:00
+ private final String serverName = "Scissors"; // Scissors // Paper
2021-06-12 18:04:04 +00:00
private final String serverVersion;
private final String bukkitVersion = Versioning.getBukkitVersion();
private final Logger logger = Logger.getLogger("Minecraft");
2021-08-25 04:06:30 +00:00
diff --git a/src/main/java/org/bukkit/craftbukkit/util/Versioning.java b/src/main/java/org/bukkit/craftbukkit/util/Versioning.java
2022-03-13 01:39:38 +00:00
index 774556a62eb240da42e84db4502e2ed43495be17..becf61c0adde1c27f3e462a1b8248544ab181797 100644
2021-08-25 04:06:30 +00:00
--- a/src/main/java/org/bukkit/craftbukkit/util/Versioning.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/Versioning.java
@@ -11,7 +11,7 @@ public final class Versioning {
public static String getBukkitVersion() {
String result = "Unknown-Version";
- InputStream stream = Bukkit.class.getClassLoader().getResourceAsStream("META-INF/maven/io.papermc.paper/paper-api/pom.properties");
2022-03-13 01:39:38 +00:00
+ InputStream stream = Bukkit.class.getClassLoader().getResourceAsStream("META-INF/maven/me.totalfreedom.scissors/scissors-api/pom.properties");
2021-08-25 04:06:30 +00:00
Properties properties = new Properties();
if (stream != null) {