diff options
Diffstat (limited to 'nms-patches/DedicatedServer.patch')
-rw-r--r-- | nms-patches/DedicatedServer.patch | 37 |
1 files changed, 18 insertions, 19 deletions
diff --git a/nms-patches/DedicatedServer.patch b/nms-patches/DedicatedServer.patch index a1ce3652..9085d707 100644 --- a/nms-patches/DedicatedServer.patch +++ b/nms-patches/DedicatedServer.patch @@ -68,11 +68,10 @@ } } catch (IOException ioexception) { DedicatedServer.LOGGER.error("Exception handling console input", ioexception); -@@ -67,13 +93,35 @@ +@@ -65,6 +91,27 @@ + } + }; - thread.setDaemon(true); - thread.start(); -+ + // CraftBukkit start - TODO: handle command-line logging arguments + java.util.logging.Logger global = java.util.logging.Logger.getLogger(""); + global.setUseParentHandlers(false); @@ -94,9 +93,10 @@ + System.setErr(new PrintStream(new LoggerOutputStream(logger, Level.WARN), true)); + // CraftBukkit end + - DedicatedServer.LOGGER.info("Starting minecraft server version 1.8.5"); - if (Runtime.getRuntime().maxMemory() / 1024L / 1024L < 512L) { - DedicatedServer.LOGGER.warn("To start the server with more ram, launch it as \"java -Xmx1024M -Xms1024M -jar minecraft_server.jar\""); + thread.setDaemon(true); + thread.start(); + DedicatedServer.LOGGER.info("Starting minecraft server version 1.8.6"); +@@ -73,7 +120,7 @@ } DedicatedServer.LOGGER.info("Loading properties"); @@ -105,7 +105,7 @@ this.p = new EULA(new File("eula.txt")); if (!this.p.a()) { DedicatedServer.LOGGER.info("You need to agree to the EULA in order to run the server. Go to eula.txt for more info."); -@@ -129,6 +177,8 @@ +@@ -129,6 +176,8 @@ return false; } @@ -114,7 +114,7 @@ if (!this.getOnlineMode()) { DedicatedServer.LOGGER.warn("**** SERVER IS RUNNING IN OFFLINE/INSECURE MODE!"); DedicatedServer.LOGGER.warn("The server will make no attempt to authenticate usernames. Beware."); -@@ -143,7 +193,7 @@ +@@ -143,7 +192,7 @@ if (!NameReferencingFileConverter.a(this.propertyManager)) { return false; } else { @@ -123,13 +123,13 @@ long j = System.nanoTime(); if (this.U() == null) { -@@ -198,8 +248,19 @@ +@@ -198,7 +247,18 @@ DedicatedServer.LOGGER.info("Starting remote control listener"); this.n = new RemoteControlListener(this); this.n.a(); + this.remoteConsole = new org.bukkit.craftbukkit.command.CraftRemoteConsoleCommandSender(); // CraftBukkit - } - ++ } ++ + // CraftBukkit start + if (this.server.getBukkitSpawnRadius() > -1) { + DedicatedServer.LOGGER.info("'settings.spawn-radius' in bukkit.yml has been moved to 'spawn-protection' in server.properties. I will move your config for you."); @@ -137,13 +137,12 @@ + this.propertyManager.getInt("spawn-protection", this.server.getBukkitSpawnRadius()); + this.server.removeBukkitSpawnRadius(); + this.propertyManager.savePropertiesFile(); -+ } + } + // CraftBukkit end -+ + if (this.aS() > 0L) { Thread thread1 = new Thread(new ThreadWatchdog(this)); - -@@ -213,6 +274,12 @@ +@@ -213,6 +273,12 @@ } } @@ -156,7 +155,7 @@ public void setGamemode(WorldSettings.EnumGamemode worldsettings_enumgamemode) { super.setGamemode(worldsettings_enumgamemode); this.r = worldsettings_enumgamemode; -@@ -265,7 +332,7 @@ +@@ -265,7 +331,7 @@ System.exit(0); } @@ -165,7 +164,7 @@ super.B(); this.aO(); } -@@ -296,7 +363,14 @@ +@@ -296,7 +362,14 @@ while (!this.l.isEmpty()) { ServerCommand servercommand = (ServerCommand) this.l.remove(0); @@ -181,7 +180,7 @@ } } -@@ -491,13 +565,57 @@ +@@ -491,13 +564,57 @@ } public String getPlugins() { |