Class LobbySettings
java.lang.Object
ua.mcchickenstudio.opencreative.settings.LobbySettings
LobbySettings
This class represents settings of lobby world, where players will be teleported on server join, or by using /spawn command.-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanChecks whether explosions in lobby world should be cancelled without bypass permission.booleanChecks whether damaging mobs in lobby world should be cancelled without bypass permission.booleanChecks whether destroying blocks in lobby world should be cancelled without bypass permission.booleanChecks whether placing blocks in lobby world should be cancelled without bypass permission.booleanChecks whether spawning mobs in lobby world should be cancelled without bypass permission.booleanChecks whether using WorldEdit in lobby world should be cancelled without bypass permission.voidload()Loads settings of lobby from configuration.booleanshouldClearInventory(@NotNull org.bukkit.World world) Checks whether player's inventory should be cleared after teleporting between worlds.booleanshouldResetGameMode(@NotNull org.bukkit.World world) Checks whether player's inventory should be cleared after teleporting between worlds.booleanChecks whether resource pack will be reset on entering lobby or changing worlds.booleanChecks whether view and simulation distances will be reset on entering lobby or changing worlds.booleanChecks whether player will be teleported to lobby when he connects to server.
-
Constructor Details
-
LobbySettings
public LobbySettings()
-
-
Method Details
-
load
public void load()Loads settings of lobby from configuration. -
shouldClearInventory
public boolean shouldClearInventory(@NotNull @NotNull org.bukkit.World world) Checks whether player's inventory should be cleared after teleporting between worlds.- Parameters:
world- , where player currently is in.- Returns:
- true - will be cleared, false - not.
-
shouldResetGameMode
public boolean shouldResetGameMode(@NotNull @NotNull org.bukkit.World world) Checks whether player's inventory should be cleared after teleporting between worlds.- Parameters:
world- , where player currently is in.- Returns:
- true - will be reset, false - not.
-
areExplosionsDisabled
public boolean areExplosionsDisabled()Checks whether explosions in lobby world should be cancelled without bypass permission.- Returns:
- true - disable explosions, false - allow them.
-
isDamagingMobsDisallowed
public boolean isDamagingMobsDisallowed()Checks whether damaging mobs in lobby world should be cancelled without bypass permission.- Returns:
- true - disable damaging mobs, false - allow it.
-
isDestroyingBlocksDisallowed
public boolean isDestroyingBlocksDisallowed()Checks whether destroying blocks in lobby world should be cancelled without bypass permission.- Returns:
- true - disable destroying blocks, false - allow it.
-
isPlacingBlocksDisallowed
public boolean isPlacingBlocksDisallowed()Checks whether placing blocks in lobby world should be cancelled without bypass permission.- Returns:
- true - disable placing blocks, false - allow it.
-
isSpawningMobsDisallowed
public boolean isSpawningMobsDisallowed()Checks whether spawning mobs in lobby world should be cancelled without bypass permission.- Returns:
- true - disable spawning mobs, false - allow it.
-
isWorldEditDisallowed
public boolean isWorldEditDisallowed()Checks whether using WorldEdit in lobby world should be cancelled without bypass permission.- Returns:
- true - disable spawning mobs, false - allow it.
-
shouldResetViewDistance
public boolean shouldResetViewDistance()Checks whether view and simulation distances will be reset on entering lobby or changing worlds.- Returns:
- true - reset view and simulation distances, false - don't reset, but disable "Set View Distance" and "Set Simulation Distance" player actions.
-
shouldResetResourcePack
public boolean shouldResetResourcePack()Checks whether resource pack will be reset on entering lobby or changing worlds.- Returns:
- true - reset resource pack, false - don't reset, but disable "Set Resource Pack" player action.
-
shouldTeleportOnJoin
public boolean shouldTeleportOnJoin()Checks whether player will be teleported to lobby when he connects to server.- Returns:
- true - teleport to lobby on join, false - not.
-