Paper config files

== AT ==
public org.spigotmc.SpigotWorldConfig getBoolean(Ljava/lang/String;Z)Z
public org.spigotmc.SpigotWorldConfig getDouble(Ljava/lang/String;)D
public org.spigotmc.SpigotWorldConfig getDouble(Ljava/lang/String;D)D
public org.spigotmc.SpigotWorldConfig getInt(Ljava/lang/String;)I
public org.spigotmc.SpigotWorldConfig getInt(Ljava/lang/String;I)I
public org.spigotmc.SpigotWorldConfig getList(Ljava/lang/String;Ljava/lang/Object;)Ljava/util/List;
public org.spigotmc.SpigotWorldConfig getString(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
public net.minecraft.server.dedicated.DedicatedServerProperties reload(Lnet/minecraft/core/RegistryAccess;Ljava/util/Properties;Ljoptsimple/OptionSet;)Lnet/minecraft/server/dedicated/DedicatedServerProperties;
public net.minecraft.world.level.NaturalSpawner SPAWNING_CATEGORIES
This commit is contained in:
Jake Potrebic
2022-06-08 22:20:16 -07:00
parent e954a5a260
commit 769119f918
81 changed files with 4997 additions and 103 deletions

View File

@@ -967,6 +967,7 @@ public final class CraftServer implements Server {
}
org.spigotmc.SpigotConfig.init((File) this.console.options.valueOf("spigot-settings")); // Spigot
this.console.paperConfigurations.reloadConfigs(this.console);
for (ServerLevel world : this.console.getAllLevels()) {
world.serverLevelData.setDifficulty(config.difficulty);
world.setSpawnSettings(config.spawnMonsters);

View File

@@ -142,6 +142,19 @@ public class Main {
.defaultsTo(new File("spigot.yml"))
.describedAs("Yml file");
// Spigot End
// Paper start
acceptsAll(asList("paper-dir", "paper-settings-directory"), "Directory for Paper settings")
.withRequiredArg()
.ofType(File.class)
.defaultsTo(new File(io.papermc.paper.configuration.PaperConfigurations.CONFIG_DIR))
.describedAs("Config directory");
acceptsAll(asList("paper", "paper-settings"), "File for Paper settings")
.withRequiredArg()
.ofType(File.class)
.defaultsTo(new File("paper.yml"))
.describedAs("Yml file");
// Paper end
}
};