Class ServerConfiguration
java.lang.Object
be.seeseemelk.mockbukkit.configuration.ServerConfiguration
Represents all configuration options that can be retrieved from a
Server
.
This class is used internally, and should not be considered public API.
As such, breaking changes may occur here at any time.- See Also:
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic enum
Enum representing all different world types. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionint
int
int
@NotNull net.kyori.adventure.text.Component
int
it.unimi.dsi.fastutil.objects.Object2IntOpenHashMap<SpawnCategory>
it.unimi.dsi.fastutil.objects.Object2LongOpenHashMap<SpawnCategory>
int
boolean
boolean
boolean
boolean
boolean
boolean
boolean
boolean
boolean
void
setAllowEnd
(boolean allowEnd) void
setAllowFlight
(boolean allowFlight) void
setAllowNether
(boolean allowNether) void
setEnforceSecureProfiles
(boolean enforceSecureProfiles) void
setGenerateStructures
(boolean generateStructures) void
setHardcore
(boolean hardcore) void
setHideOnlinePlayers
(boolean hideOnlinePlayers) void
setLevelType
(ServerConfiguration.LevelType levelType) void
setMaxChainedNeighbourUpdates
(int maxChainedNeighbourUpdates) void
setMaxWorldSize
(int maxWorldSize) void
setOnlineMode
(boolean onlineMode) void
setPvpEnabled
(boolean pvpEnabled) void
setServerIp
(String serverIp) void
setServerPort
(int serverPort) void
setShouldSendChatPreviews
(boolean shouldSendChatPreviews) void
setShutdownMessage
(@NotNull net.kyori.adventure.text.Component shutdownMessage) void
setSimulationDistance
(int simulationDistance) void
setUpdateFolder
(String updateFolder) void
setViewDistance
(int viewDistance) boolean
-
Constructor Details
-
ServerConfiguration
public ServerConfiguration()
-
-
Method Details
-
getViewDistance
public int getViewDistance()- Returns:
- The view distance.
- See Also:
-
setViewDistance
public void setViewDistance(int viewDistance) - Parameters:
viewDistance
- The view distance.- See Also:
-
getLevelType
- Returns:
- The level type.
- See Also:
-
setLevelType
- Parameters:
levelType
- The level type.- See Also:
-
isGenerateStructures
public boolean isGenerateStructures()- Returns:
- Generate structures.
- See Also:
-
setGenerateStructures
public void setGenerateStructures(boolean generateStructures) - Parameters:
generateStructures
- Generate structures.- See Also:
-
isAllowEnd
public boolean isAllowEnd()- Returns:
- Allow end.
- See Also:
-
setAllowEnd
public void setAllowEnd(boolean allowEnd) - Parameters:
allowEnd
- Allow end.- See Also:
-
isAllowNether
public boolean isAllowNether()- Returns:
- Allow nether.
- See Also:
-
setAllowNether
public void setAllowNether(boolean allowNether) - Parameters:
allowNether
- Allow end.- See Also:
-
getUpdateFolder
- Returns:
- Update folder.
-
setUpdateFolder
- Parameters:
updateFolder
- Update folder.- See Also:
-
shouldSendChatPreviews
public boolean shouldSendChatPreviews()- Returns:
- Send chat previews.
- See Also:
-
setShouldSendChatPreviews
public void setShouldSendChatPreviews(boolean shouldSendChatPreviews) - Parameters:
shouldSendChatPreviews
- Send chat previews.- See Also:
-
isEnforceSecureProfiles
public boolean isEnforceSecureProfiles()- Returns:
- Enforce secure profiles.
- See Also:
-
setEnforceSecureProfiles
public void setEnforceSecureProfiles(boolean enforceSecureProfiles) - Parameters:
enforceSecureProfiles
- Enforce secure profiles.- See Also:
-
isOnlineMode
public boolean isOnlineMode()- Returns:
- Online mode.
- See Also:
-
setOnlineMode
public void setOnlineMode(boolean onlineMode) - Parameters:
onlineMode
- Online mode.- See Also:
-
isAllowFlight
public boolean isAllowFlight()- Returns:
- Allow flight.
- See Also:
-
setAllowFlight
public void setAllowFlight(boolean allowFlight) - Parameters:
allowFlight
- Allow flight.- See Also:
-
isHardcore
public boolean isHardcore()- Returns:
- Hardcore mode.
- See Also:
-
setHardcore
public void setHardcore(boolean hardcore) - Parameters:
hardcore
- Hardcore mode.- See Also:
-
getMaxChainedNeighbourUpdates
public int getMaxChainedNeighbourUpdates()- Returns:
- Max chained neighbour updates.
- See Also:
-
setMaxChainedNeighbourUpdates
public void setMaxChainedNeighbourUpdates(int maxChainedNeighbourUpdates) - Parameters:
maxChainedNeighbourUpdates
- Max chained neighbour updates.- See Also:
-
getShutdownMessage
@NotNull public @NotNull net.kyori.adventure.text.Component getShutdownMessage()- Returns:
- Shutdown message.
- See Also:
-
setShutdownMessage
public void setShutdownMessage(@NotNull @NotNull net.kyori.adventure.text.Component shutdownMessage) - Parameters:
shutdownMessage
- Shutdown message.- See Also:
-
getMaxWorldSize
public int getMaxWorldSize()- Returns:
- Max world size.
- See Also:
-
setMaxWorldSize
public void setMaxWorldSize(int maxWorldSize) - Parameters:
maxWorldSize
- Max world size.- See Also:
-
getSimulationDistance
public int getSimulationDistance()- Returns:
- Simulation distance.
- See Also:
-
setSimulationDistance
public void setSimulationDistance(int simulationDistance) - Parameters:
simulationDistance
- Simulation distance.- See Also:
-
isHideOnlinePlayers
public boolean isHideOnlinePlayers()- Returns:
- Hide online players.
- See Also:
-
setHideOnlinePlayers
public void setHideOnlinePlayers(boolean hideOnlinePlayers) - Parameters:
hideOnlinePlayers
- Hide online players- See Also:
-
getServerIp
- Returns:
- The server listen IP
- See Also:
-
setServerIp
- Parameters:
serverIp
- The server listen IP- See Also:
-
getServerPort
public int getServerPort()- Returns:
- The server listen port
- See Also:
-
setServerPort
public void setServerPort(int serverPort) - Parameters:
serverPort
- The server listen port- See Also:
-
isPvpEnabled
public boolean isPvpEnabled()- Returns:
- PVP enabled
-
setPvpEnabled
public void setPvpEnabled(boolean pvpEnabled) - Parameters:
pvpEnabled
- PVP enabled
-
getTicksPerSpawn
- Returns:
- The ticks per spawn for each spawn category.
-
getSpawnLimits
- Returns:
- The spawn limits for each spawn category.
-