Files
Shiroha/shiroha-server/minecraft-patches/features/0038-Add-config-for-server-mod-name.patch
T
NanaChiyo0721 d1786e96ef
Shiroha CI / build (push) Canceled after 0s
Shiroha CI / Event File (push) Canceled after 0s
Reduce allocation in SignalGetter
2026-08-07 15:51:57 +08:00

20 lines
1018 B
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: MrHua269 <mrhua269@gmail.com>
Date: Sat, 18 Apr 2026 09:08:52 +0800
Subject: [PATCH] Add config for server mod name
diff --git a/net/minecraft/server/MinecraftServer.java b/net/minecraft/server/MinecraftServer.java
index 63fecdde56650fb056fa8de352abdf927b0549f8..3ecedf303384c172a5e2a19c9e6ac0c3a43cef74 100644
--- a/net/minecraft/server/MinecraftServer.java
+++ b/net/minecraft/server/MinecraftServer.java
@@ -2071,7 +2071,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
}
public String getServerModName() {
- return io.papermc.paper.ServerBuildInfo.buildInfo().brandName(); // Paper
+ return io.nanachiyo0721.shiroha.config.modules.misc.ServerModNameConfig.fakeVanilla ? "vanilla" : io.nanachiyo0721.shiroha.config.modules.misc.ServerModNameConfig.serverModName; // Paper // Shiroha - Add config for server mod name
}
public ServerClockManager clockManager() {