public class MinecraftDedicatedServer extends MinecraftServer implements DedicatedServer
| Modifier and Type | Field and Description |
|---|---|
private List<PendingServerCommand> |
commandQueue |
private class_5514 |
field_26898 |
private DedicatedServerGui |
gui |
private static Logger |
LOGGER |
private ServerPropertiesLoader |
propertiesLoader |
private QueryResponseHandler |
queryResponseHandler |
private RconCommandOutput |
rconCommandOutput |
private RconListener |
rconServer |
private static Pattern |
SHA1_PATTERN |
DEMO_LEVEL_INFO, lastTickLengths, proxy, registryManager, saveHandler, saveProperties, session, USER_CACHE_FILEDUMMY| Constructor and Description |
|---|
MinecraftDedicatedServer(Thread thread,
DynamicRegistryManager.Impl impl,
LevelStorage.Session session,
ResourcePackManager resourcePackManager,
ServerResourceManager serverResourceManager,
SaveProperties saveProperties,
ServerPropertiesLoader serverPropertiesLoader,
com.mojang.datafixers.DataFixer dataFixer,
com.mojang.authlib.minecraft.MinecraftSessionService minecraftSessionService,
com.mojang.authlib.GameProfileRepository gameProfileRepository,
UserCache userCache,
WorldGenerationProgressListenerFactory worldGenerationProgressListenerFactory) |
addServerGuiTickable, canExecute, close, convertLevel, createTask, createWorlds, dump, enableProfiler, executeTask, forcePlayerSampleUpdate, getAdvancementLoader, getBossBarManager, getCommandFunctionManager, getCommandManager, getCommandSource, getCurrentPlayerCount, getDataCommandStorage, getDataFixer, getDataPackManager, getDefaultGameMode, getFile, getGameProfileRepo, getGameRules, getIconFile, getKeyPair, getLootManager, getMaxPlayerCount, getMetricsData, getNetworkIo, getOverworld, getPermissionLevel, getPlayerIdleTimeout, getPlayerNames, getPredicateManager, getProfiler, getRecipeManager, getRegistryManager, getResourcePackHash, getResourcePackUrl, getRunDirectory, getSavePath, getSaveProperties, getScoreboard, getServerIp, getServerMetadata, getServerModName, getServerMotd, getServerPort, getServerStartTime, getSessionService, getSnooper, getSpawnRadius, getStructureManager, getTagManager, getThread, getTicks, getTickTime, getUserCache, getUserName, getVersion, getWorld, getWorldHeight, getWorldRegistryKeys, getWorlds, hasIconFile, isDebugRunning, isDemo, isEnforceWhitelist, isFlightEnabled, isLoading, isOnlineMode, isPvpEnabled, isRunning, isSinglePlayer, isStopped, isStopping, kickNonWhitelistedPlayers, loadDataPacks, loadWorld, loadWorldResourcePack, method_16208, method_31400, reloadResources, runServer, runTask, save, sendSystemMessage, setCrashReport, setDefaultGameMode, setDemo, setDifficulty, setDifficultyLocked, setEnforceWhitelist, setFlightEnabled, setForceGameMode, setMotd, setOnlineMode, setPlayerManager, setPreventProxyConnections, setPvpEnabled, setResourcePack, setServerId, setServerIp, setServerName, setServerPort, setWorldHeight, shouldExecuteAsync, shouldForceGameMode, shouldPreventProxyConnections, shouldReceiveFeedback, shouldTrackOutput, startServer, stop, stopDebug, tickhasRunningTaskscancelTasks, execute, getName, getTaskCount, isOnThread, runTasks, runTasks, send, submit, submit, submitAndJoin, waitForTasksclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetCurrentPlayerCount, getMaxPlayerCount, getPlayerNames, getVersionask, create, method_27918private static final Logger LOGGER
private static final Pattern SHA1_PATTERN
private final List<PendingServerCommand> commandQueue
private QueryResponseHandler queryResponseHandler
private final RconCommandOutput rconCommandOutput
private RconListener rconServer
private final ServerPropertiesLoader propertiesLoader
@Nullable private DedicatedServerGui gui
@Nullable private final class_5514 field_26898
public MinecraftDedicatedServer(Thread thread, DynamicRegistryManager.Impl impl, LevelStorage.Session session, ResourcePackManager resourcePackManager, ServerResourceManager serverResourceManager, SaveProperties saveProperties, ServerPropertiesLoader serverPropertiesLoader, com.mojang.datafixers.DataFixer dataFixer, com.mojang.authlib.minecraft.MinecraftSessionService minecraftSessionService, com.mojang.authlib.GameProfileRepository gameProfileRepository, UserCache userCache, WorldGenerationProgressListenerFactory worldGenerationProgressListenerFactory)
public boolean setupServer()
throws IOException
setupServer in class MinecraftServerIOExceptionpublic boolean shouldSpawnAnimals()
shouldSpawnAnimals in class MinecraftServerpublic boolean isMonsterSpawningEnabled()
isMonsterSpawningEnabled in class MinecraftServerpublic boolean shouldSpawnNpcs()
shouldSpawnNpcs in class MinecraftServerpublic String createResourcePackHash()
public ServerPropertiesHandler getProperties()
getProperties in interface DedicatedServerpublic void method_27731()
method_27731 in class MinecraftServerpublic boolean isHardcore()
isHardcore in class MinecraftServerpublic CrashReport populateCrashReport(CrashReport report)
populateCrashReport in class MinecraftServerpublic Optional<String> getModdedStatusMessage()
getModdedStatusMessage in class MinecraftServerpublic void exit()
exit in class MinecraftServerpublic void tickWorlds(BooleanSupplier shouldKeepTicking)
tickWorlds in class MinecraftServerpublic boolean isNetherAllowed()
isNetherAllowed in class MinecraftServerpublic void addSnooperInfo(Snooper snooper)
addSnooperInfo in interface SnooperListeneraddSnooperInfo in class MinecraftServerpublic void enqueueCommand(String command, ServerCommandSource commandSource)
public void executeQueuedCommands()
public boolean isDedicated()
isDedicated in class MinecraftServerpublic int getRateLimit()
getRateLimit in class MinecraftServerpublic boolean isUsingNativeTransport()
isUsingNativeTransport in class MinecraftServerpublic DedicatedPlayerManager getPlayerManager()
getPlayerManager in class MinecraftServerpublic boolean isRemote()
isRemote in class MinecraftServerpublic String getHostname()
getHostname in interface DedicatedServerpublic int getPort()
getPort in interface DedicatedServerpublic String getMotd()
getMotd in interface DedicatedServerpublic void createGui()
public boolean hasGui()
hasGui in class MinecraftServerpublic boolean openToLan(GameMode gameMode, boolean cheatsAllowed, int port)
openToLan in class MinecraftServergameMode - the game mode connecting players will have set by defaultcheatsAllowed - whether players on the server have operator permissionsport - the port to open up to LAN connectionspublic boolean areCommandBlocksEnabled()
areCommandBlocksEnabled in class MinecraftServerpublic int getSpawnProtectionRadius()
getSpawnProtectionRadius in class MinecraftServerpublic boolean isSpawnProtected(ServerWorld world, BlockPos pos, PlayerEntity player)
isSpawnProtected in class MinecraftServerpublic boolean acceptsStatusQuery()
acceptsStatusQuery in class MinecraftServerpublic int getOpPermissionLevel()
getOpPermissionLevel in class MinecraftServerpublic int getFunctionPermissionLevel()
getFunctionPermissionLevel in class MinecraftServerpublic void setPlayerIdleTimeout(int playerIdleTimeout)
setPlayerIdleTimeout in class MinecraftServerpublic boolean shouldBroadcastRconToOps()
shouldBroadcastRconToOps in class MinecraftServerpublic boolean shouldBroadcastConsoleToOps()
shouldBroadcastConsoleToOps in interface CommandOutputpublic int getMaxWorldBorderRadius()
getMaxWorldBorderRadius in class MinecraftServerpublic int getNetworkCompressionThreshold()
getNetworkCompressionThreshold in class MinecraftServerprotected boolean convertData()
private void sleepFiveSeconds()
public long getMaxTickTime()
public String getPlugins()
getPlugins in interface DedicatedServerpublic String executeRconCommand(String command)
executeRconCommand in interface DedicatedServerpublic void setUseWhitelist(boolean bool)
public void shutdown()
shutdown in class MinecraftServerpublic boolean isHost(com.mojang.authlib.GameProfile profile)
isHost in class MinecraftServerpublic int adjustTrackingDistance(int initialDistance)
adjustTrackingDistance in class MinecraftServerpublic String getLevelName()
getLevelName in interface DedicatedServerpublic boolean syncChunkWrites()
syncChunkWrites in class MinecraftServer@Nullable public class_5513 method_31371(ServerPlayerEntity serverPlayerEntity)
method_31371 in class MinecraftServer