Package net.minecraftforge.server
Class ServerLifecycleHooks
java.lang.Object
net.minecraftforge.server.ServerLifecycleHooks
-
Field Summary
Modifier and TypeFieldDescriptionprivate static AtomicBoolean
private static MinecraftServer
private static CountDownLatch
private static final org.apache.logging.log4j.Logger
private static final LevelResource
private static final org.apache.logging.log4j.Marker
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic RepositorySource
buildPackFinder
(Map<net.minecraftforge.forgespi.locating.IModFile, ? extends PathResourcePack> modResourcePacks) static void
static MinecraftServer
private static Path
getServerConfigPath
(MinecraftServer server) static void
handleExit
(int retVal) static boolean
static boolean
handleServerLogin
(ClientIntentionPacket packet, Connection manager) static void
handleServerStarted
(MinecraftServer server) static boolean
handleServerStarting
(MinecraftServer server) static void
handleServerStopped
(MinecraftServer server) static void
handleServerStopping
(MinecraftServer server) private static void
rejectConnection
(Connection manager, ConnectionType type, String message) private static void
serverPackFinder
(Map<net.minecraftforge.forgespi.locating.IModFile, ? extends PathResourcePack> modResourcePacks, Consumer<Pack> consumer, Pack.PackConstructor factory)
-
Field Details
-
LOGGER
private static final org.apache.logging.log4j.Logger LOGGER -
SERVERHOOKS
private static final org.apache.logging.log4j.Marker SERVERHOOKS -
SERVERCONFIG
-
exitLatch
-
currentServer
-
allowLogins
-
-
Constructor Details
-
ServerLifecycleHooks
public ServerLifecycleHooks()
-
-
Method Details
-
getServerConfigPath
-
handleServerAboutToStart
-
handleServerStarting
-
handleServerStarted
-
handleServerStopping
-
expectServerStopped
public static void expectServerStopped() -
handleServerStopped
-
getCurrentServer
-
handleServerLogin
-
rejectConnection
-
handleExit
public static void handleExit(int retVal) -
buildPackFinder
public static RepositorySource buildPackFinder(Map<net.minecraftforge.forgespi.locating.IModFile, ? extends PathResourcePack> modResourcePacks) -
serverPackFinder
private static void serverPackFinder(Map<net.minecraftforge.forgespi.locating.IModFile, ? extends PathResourcePack> modResourcePacks, Consumer<Pack> consumer, Pack.PackConstructor factory)
-