Add option to advertise dedicated servers to LAN. (#9502)

This commit is contained in:
Paint_Ninja authored and LexManos committed 2023-07-14 07:07:36 -07:00
1 parent 2b5852072c
commit 301e7252b0
5 files changed
+55 -6

No files matched your search

@@ -30,6 +30,8 @@ public class ForgeConfig {
public final ConfigValue<String> permissionHandler;
public final BooleanValue advertiseDedicatedServerToLan;
Server(ForgeConfigSpec.Builder builder) {
builder.comment("Server configuration settings")
.push("server");
@@ -69,6 +71,11 @@ public class ForgeConfig {
.translation("forge.configgui.permissionHandler")
.define("permissionHandler", "forge:default_handler");
advertiseDedicatedServerToLan = builder
.comment("Set this to true to enable advertising the dedicated server to local LAN clients so that it shows up in the Multiplayer screen automatically.")
.translation("forge.configgui.advertiseDedicatedServerToLan")
.define("advertiseDedicatedServerToLan", true);
builder.pop();
}
}