SPIGOT-3461: Standardise plugin load timing

This commit is contained in:
md_5 2017-07-26 13:20:29 +10:00
parent d35483b0e1
commit b1b9ab0df9
2 changed files with 12 additions and 11 deletions

View File

@ -108,16 +108,20 @@
this.r = new EULA(new File("eula.txt"));
if (!this.r.a()) {
DedicatedServer.LOGGER.info("You need to agree to the EULA in order to run the server. Go to eula.txt for more info.");
@@ -136,6 +183,8 @@
@@ -136,6 +183,12 @@
return false;
}
+ this.a((PlayerList) (new DedicatedPlayerList(this))); // CraftBukkit
+ // CraftBukkit start
+ this.a((PlayerList) (new DedicatedPlayerList(this)));
+ server.loadPlugins();
+ server.enablePlugins(org.bukkit.plugin.PluginLoadOrder.STARTUP);
+ // CraftBukkit end
+
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.");
@@ -150,7 +199,7 @@
@@ -150,7 +203,7 @@
if (!NameReferencingFileConverter.a(this.propertyManager)) {
return false;
} else {
@ -126,7 +130,7 @@
long j = System.nanoTime();
if (this.S() == null) {
@@ -198,7 +247,7 @@
@@ -198,7 +251,7 @@
DedicatedServer.LOGGER.info("Done ({})! For help, type \"help\" or \"?\"", s3);
if (this.propertyManager.a("announce-player-achievements")) {
@ -135,7 +139,7 @@
this.propertyManager.b("announce-player-achievements");
this.propertyManager.savePropertiesFile();
}
@@ -213,7 +262,18 @@
@@ -213,7 +266,18 @@
DedicatedServer.LOGGER.info("Starting remote control listener");
this.p = new RemoteControlListener(this);
this.p.a();
@ -154,7 +158,7 @@
if (this.aT() > 0L) {
Thread thread1 = new Thread(new ThreadWatchdog(this));
@@ -298,11 +358,11 @@
@@ -298,11 +362,11 @@
return crashreport;
}
@ -168,7 +172,7 @@
super.D();
this.aP();
}
@@ -333,7 +393,15 @@
@@ -333,7 +397,15 @@
while (!this.serverCommandQueue.isEmpty()) {
ServerCommand servercommand = (ServerCommand) this.serverCommandQueue.remove(0);
@ -185,7 +189,7 @@
}
}
@@ -536,16 +604,70 @@
@@ -536,16 +608,70 @@
}
public String getPlugins() {

View File

@ -256,9 +256,6 @@ public final class CraftServer implements Server {
chunkGCPeriod = configuration.getInt("chunk-gc.period-in-ticks");
chunkGCLoadThresh = configuration.getInt("chunk-gc.load-threshold");
loadIcon();
loadPlugins();
enablePlugins(PluginLoadOrder.STARTUP);
}
public boolean getCommandBlockOverride(String command) {