Files
MinecraftForge/patches/minecraft/net/minecraft/server/dedicated/DedicatedServer.java.patch
T
Christian 30d532f4fc Pass 1: Most patches are restored.
NOTES: 1. Network is completely broken. 2. GameRegistry is partially broken. 3. ID sync is not in.
2013-12-02 23:48:26 -05:00

45 lines
1.8 KiB
Diff

--- ../src-base/minecraft/net/minecraft/server/dedicated/DedicatedServer.java
+++ ../src-work/minecraft/net/minecraft/server/dedicated/DedicatedServer.java
@@ -1,5 +1,6 @@
package net.minecraft.server.dedicated;
+import cpw.mods.fml.common.FMLCommonHandler;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import java.io.BufferedReader;
@@ -109,6 +110,8 @@
field_155771_h.warn("To start the server with more ram, launch it as \"java -Xmx1024M -Xms1024M -jar minecraft_server.jar\"");
}
+ FMLCommonHandler.instance().onServerStart(this);
+
field_155771_h.info("Loading properties");
this.field_71340_o = new PropertyManager(new File("server.properties"));
@@ -180,6 +183,8 @@
field_155771_h.warn("To change this, set \"online-mode\" to \"true\" in the server.properties file.");
}
+ FMLCommonHandler.instance().onServerStarted();
+
this.func_71210_a(new DedicatedPlayerList(this));
long j = System.nanoTime();
@@ -225,6 +230,7 @@
this.func_71191_d((this.func_71207_Z() + 8) / 16 * 16);
this.func_71191_d(MathHelper.func_76125_a(this.func_71207_Z(), 64, 256));
this.field_71340_o.func_73667_a("max-build-height", Integer.valueOf(this.func_71207_Z()));
+ if (!FMLCommonHandler.instance().handleServerAboutToStart(this)) { return false; }
field_155771_h.info("Preparing level \"" + this.func_71270_I() + "\"");
this.func_71247_a(this.func_71270_I(), this.func_71270_I(), k, worldtype, s3);
long i1 = System.nanoTime() - j;
@@ -245,7 +251,7 @@
this.field_71339_n.func_72602_a();
}
- return true;
+ return FMLCommonHandler.instance().handleServerStarting(this);
}
public boolean func_71225_e()