package world.bentobox.boxed; import java.util.ArrayList; import java.util.HashMap; import java.util.HashSet; import java.util.List; import java.util.Map; import java.util.Set; import org.bukkit.Difficulty; import org.bukkit.GameMode; import org.bukkit.entity.EntityType; import world.bentobox.bentobox.api.configuration.ConfigComment; import world.bentobox.bentobox.api.configuration.ConfigEntry; import world.bentobox.bentobox.api.configuration.StoreAt; import world.bentobox.bentobox.api.configuration.WorldSettings; import world.bentobox.bentobox.api.flags.Flag; import world.bentobox.bentobox.database.objects.adapters.Adapter; import world.bentobox.bentobox.database.objects.adapters.FlagSerializer; import world.bentobox.bentobox.database.objects.adapters.FlagSerializer2; /** * All the plugin settings are here * @author Tastybento */ @StoreAt(filename="config.yml", path="addons/Boxed") // Explicitly call out what name this should have. @ConfigComment("Boxed Configuration [version]") public class Settings implements WorldSettings { /* Commands */ @ConfigComment("Player Command. What command users will run to access their area.") @ConfigComment("To define alias, just separate commands with white space.") @ConfigEntry(path = "boxed.command.player") private String playerCommandAliases = "box bx boxed"; @ConfigComment("The admin command.") @ConfigComment("To define alias, just separate commands with white space.") @ConfigEntry(path = "boxed.command.admin") private String adminCommandAliases = "boxedadmin"; @ConfigComment("The default action for new player command call.") @ConfigComment("Sub-command of main player command that will be run on first player command call.") @ConfigComment("By default it is sub-command 'create'.") @ConfigEntry(path = "boxed.command.new-player-action") private String defaultNewPlayerAction = "create"; @ConfigComment("The default action for player command.") @ConfigComment("Sub-command of main player command that will be run on each player command call.") @ConfigComment("By default it is sub-command 'go'.") @ConfigEntry(path = "boxed.command.default-action") private String defaultPlayerAction = "go"; /* Boxed */ @ConfigComment("Ignore advancements.") @ConfigComment("If this is true, advancements will not change the size of the box.") @ConfigEntry(path = "boxed.ignore-advancements") private boolean ignoreAdvancements = false; @ConfigComment("Announce advancements. We recommend you set the game rule `/gamerule announceAdvancements false`") @ConfigComment("but that blocks all new advancement announcements. This setting tells Boxed to broadcast new advancements.") @ConfigEntry(path = "boxed.broadcast-advancements") private boolean broadcastAdvancements; @ConfigComment("Deny advancements for visitors.") @ConfigComment("Visitors cannot get an advancement. Note visitors will still get the reward, e.g., experience") @ConfigEntry(path = "boxed.deny-visitor-advancements") private boolean denyVisitorAdvancements = true; /* WORLD */ @ConfigComment("Friendly name for this world. Used in admin commands. Must be a single word") @ConfigEntry(path = "world.friendly-name") private String friendlyName = "Boxed"; @ConfigComment("Name of the world - if it does not exist then it will be generated.") @ConfigComment("It acts like a prefix for nether and end (e.g. boxed_world, boxed_world_nether, boxed_world_end)") @ConfigEntry(path = "world.world-name") private String worldName = "boxed_world"; @ConfigComment("World seed.") @ConfigEntry(path = "world.generator.seed", needsReset = true) private long seed = 602103456450L; @ConfigComment("World difficulty setting - PEACEFUL, EASY, NORMAL, HARD") @ConfigComment("Other plugins may override this setting") @ConfigEntry(path = "world.difficulty") private Difficulty difficulty = Difficulty.NORMAL; @ConfigComment("Spawn limits. These override the limits set in bukkit.yml") @ConfigComment("If set to a negative number, the server defaults will be used") @ConfigEntry(path = "world.spawn-limits.monsters") private int spawnLimitMonsters = -1; @ConfigEntry(path = "world.spawn-limits.animals") private int spawnLimitAnimals = -1; @ConfigEntry(path = "world.spawn-limits.water-animals") private int spawnLimitWaterAnimals = -1; @ConfigEntry(path = "world.spawn-limits.ambient") private int spawnLimitAmbient = -1; @ConfigComment("Setting to 0 will disable animal spawns, but this is not recommended. Minecraft default is 400.") @ConfigComment("A negative value uses the server default") @ConfigEntry(path = "world.spawn-limits.ticks-per-animal-spawns") private int ticksPerAnimalSpawns = -1; @ConfigComment("Setting to 0 will disable monster spawns, but this is not recommended. Minecraft default is 400.") @ConfigComment("A negative value uses the server default") @ConfigEntry(path = "world.spawn-limits.ticks-per-monster-spawns") private int ticksPerMonsterSpawns = -1; @ConfigComment("Radius of player area. (So distance between player starting spots is twice this)") @ConfigComment("It is the same for every dimension : Overworld, Nether and End.") @ConfigEntry(path = "world.area-radius", needsReset = true) private int islandDistance = 320; @ConfigComment("Starting size of boxed spaces. This is a radius so 1 = a 2x2 area.") @ConfigComment("Admins can adjust via the /boxadmin range set command") @ConfigEntry(path = "world.starting-protection-range") private int islandProtectionRange = 1; @ConfigComment("Start to place players at these coordinates. This is where players will start in the") @ConfigComment("world. This must be a multiple of your area radius, but the plugin will auto") @ConfigComment("calculate the closest location on the grid. Players are placed around this location") @ConfigComment("in a spiral manner.") @ConfigComment("If none of this makes sense, leave it at 0,0.") @ConfigEntry(path = "world.start-x") private int islandStartX = 0; @ConfigEntry(path = "world.start-z") private int islandStartZ = 0; @ConfigComment("Maximum number of player areas in the world. Set to -1 or 0 for unlimited.") @ConfigComment("If the number of areas is greater than this number, it will stop players from joining the world.") @ConfigEntry(path = "world.max-areas") private int maxIslands = -1; @ConfigComment("Area height") @ConfigComment("It is the y coordinate of the bedrock block in the blueprint.") @ConfigEntry(path = "world.area-height") private int islandHeight = 8; @ConfigComment("The maximum number of players a player can ban at any one time in this game mode.") @ConfigComment("The permission boxed.ban.maxlimit.X where X is a number can also be used per player") @ConfigComment("-1 = unlimited") @ConfigEntry(path = "world.ban-limit") private int banLimit = -1; // Nether @ConfigComment("Generate Nether - if this is false, the nether world will not be made and access to") @ConfigComment("the nether will not occur. Other plugins may still enable portal usage.") @ConfigComment("Note: Some default challenges will not be possible if there is no nether.") @ConfigComment("Note that with a standard nether all players arrive at the same portal and entering a") @ConfigComment("portal will return them back to their areas.") @ConfigEntry(path = "world.nether.generate") private boolean netherGenerate = true; @ConfigComment("This option indicates if nether portals should be linked via dimensions.") @ConfigComment("Option will simulate vanilla portal mechanics that links portals together") @ConfigComment("or creates a new portal, if there is not a portal in that dimension.") @ConfigEntry(path = "world.nether.create-and-link-portals", since = "1.0.3") private boolean makeNetherPortals = false; // End @ConfigComment("End World - if this is false, the end world will not be made and access to") @ConfigComment("the end will not occur. Other plugins may still enable portal usage.") @ConfigEntry(path = "world.end.generate") private boolean endGenerate = true; @ConfigComment("Mob white list - these mobs will NOT be removed when logging in or doing /boxed") @ConfigEntry(path = "world.remove-mobs-whitelist") private Set removeMobsWhitelist = new HashSet<>(); @ConfigComment("World flags. These are boolean settings for various flags for this world") @ConfigEntry(path = "world.flags") private Map worldFlags = new HashMap<>(); @ConfigComment("These are the default protection settings for new areas.") @ConfigComment("The value is the minimum area rank required allowed to do the action") @ConfigComment("Ranks are the following:") @ConfigComment(" VISITOR = 0") @ConfigComment(" COOP = 200") @ConfigComment(" TRUSTED = 400") @ConfigComment(" MEMBER = 500") @ConfigComment(" SUB-OWNER = 900") @ConfigComment(" OWNER = 1000") @ConfigEntry(path = "world.default-area-flags") @Adapter(FlagSerializer.class) private Map defaultIslandFlags = new HashMap<>(); @ConfigComment("These are the default settings for new areas") @ConfigEntry(path = "world.default-area-settings") @Adapter(FlagSerializer2.class) private Map defaultIslandSettings = new HashMap<>(); @ConfigComment("These settings/flags are hidden from users") @ConfigComment("Ops can toggle hiding in-game using SHIFT-LEFT-CLICK on flags in settings") @ConfigEntry(path = "world.hidden-flags") private List hiddenFlags = new ArrayList<>(); @ConfigComment("Visitor banned commands - Visitors to areas cannot use these commands in this world") @ConfigEntry(path = "world.visitor-banned-commands") private List visitorBannedCommands = new ArrayList<>(); @ConfigComment("Falling banned commands - players cannot use these commands when falling") @ConfigComment("if the PREVENT_TELEPORT_WHEN_FALLING world setting flag is active") @ConfigEntry(path = "world.falling-banned-commands") private List fallingBannedCommands = new ArrayList<>(); // --------------------------------------------- /* ISLAND */ @ConfigComment("Default max team size") @ConfigComment("Permission size cannot be less than the default below. ") @ConfigEntry(path = "area.max-team-size") private int maxTeamSize = 4; @ConfigComment("Default maximum number of coop rank members per area") @ConfigComment("Players can have the boxed.coop.maxsize. permission to be bigger but") @ConfigComment("permission size cannot be less than the default below. ") @ConfigEntry(path = "area.max-coop-size") private int maxCoopSize = 4; @ConfigComment("Default maximum number of trusted rank members per area") @ConfigComment("Players can have the boxed.trust.maxsize. permission to be bigger but") @ConfigComment("permission size cannot be less than the default below. ") @ConfigEntry(path = "area.max-trusted-size") private int maxTrustSize = 4; @ConfigComment("Default maximum number of homes a player can have. Min = 1") @ConfigComment("Accessed via /is sethome or /is go ") @ConfigEntry(path = "area.max-homes") private int maxHomes = 5; // Reset @ConfigComment("How many resets a player is allowed (manage with /boxadmin reset add/remove/reset/set command)") @ConfigComment("Value of -1 means unlimited, 0 means hardcore - no resets.") @ConfigComment("Example, 2 resets means they get 2 resets or 3 areas lifetime") @ConfigEntry(path = "area.reset.reset-limit") private int resetLimit = -1; @ConfigComment("Kicked or leaving players lose resets") @ConfigComment("Players who leave a team will lose an area reset chance") @ConfigComment("If a player has zero resets left and leaves a team, they cannot make a new") @ConfigComment("area by themselves and can only join a team.") @ConfigComment("Leave this true to avoid players exploiting free areas") @ConfigEntry(path = "area.reset.leavers-lose-reset") private boolean leaversLoseReset = false; @ConfigComment("Allow kicked players to keep their inventory.") @ConfigComment("Overrides the on-leave inventory reset for kicked players.") @ConfigEntry(path = "area.reset.kicked-keep-inventory") private boolean kickedKeepInventory = false; @ConfigComment("What the addon should reset when the player joins or creates an area") @ConfigComment("Reset Money - if this is true, will reset the player's money to the starting money") @ConfigComment("Recommendation is that this is set to true, but if you run multi-worlds") @ConfigComment("make sure your economy handles multi-worlds too.") @ConfigEntry(path = "area.reset.on-join.money") private boolean onJoinResetMoney = false; @ConfigComment("Reset inventory - if true, the player's inventory will be cleared.") @ConfigComment("Note: if you have MultiInv running or a similar inventory control plugin, that") @ConfigComment("plugin may still reset the inventory when the world changes.") @ConfigEntry(path = "area.reset.on-join.inventory") private boolean onJoinResetInventory = false; @ConfigComment("Reset health - if true, the player's health will be reset.") @ConfigEntry(path = "area.reset.on-join.health") private boolean onJoinResetHealth = true; @ConfigComment("Reset hunger - if true, the player's hunger will be reset.") @ConfigEntry(path = "area.reset.on-join.hunger") private boolean onJoinResetHunger = true; @ConfigComment("Reset experience points - if true, the player's experience will be reset.") @ConfigEntry(path = "area.reset.on-join.exp") private boolean onJoinResetXP = false; @ConfigComment("Reset Ender Chest - if true, the player's Ender Chest will be cleared.") @ConfigEntry(path = "area.reset.on-join.ender-chest") private boolean onJoinResetEnderChest = false; @ConfigComment("Reset advancements.") @ConfigEntry(path = "area.reset.on-join.reset-advancements") private boolean onJoinResetAdvancements = true; @ConfigComment("Grant these advancements") @ConfigEntry(path = "area.reset.on-join.grant-advancements") private List onJoinGrantAdvancements = new ArrayList<>(); @ConfigComment("What the plugin should reset when the player leaves or is kicked from an area") @ConfigComment("Reset Money - if this is true, will reset the player's money to the starting money") @ConfigComment("Recommendation is that this is set to true, but if you run multi-worlds") @ConfigComment("make sure your economy handles multi-worlds too.") @ConfigEntry(path = "area.reset.on-leave.money") private boolean onLeaveResetMoney = false; @ConfigComment("Reset inventory - if true, the player's inventory will be cleared.") @ConfigComment("Note: if you have MultiInv running or a similar inventory control plugin, that") @ConfigComment("plugin may still reset the inventory when the world changes.") @ConfigEntry(path = "area.reset.on-leave.inventory") private boolean onLeaveResetInventory = false; @ConfigComment("Reset health - if true, the player's health will be reset.") @ConfigEntry(path = "area.reset.on-leave.health") private boolean onLeaveResetHealth = false; @ConfigComment("Reset hunger - if true, the player's hunger will be reset.") @ConfigEntry(path = "area.reset.on-leave.hunger") private boolean onLeaveResetHunger = false; @ConfigComment("Reset experience - if true, the player's experience will be reset.") @ConfigEntry(path = "area.reset.on-leave.exp") private boolean onLeaveResetXP = false; @ConfigComment("Reset Ender Chest - if true, the player's Ender Chest will be cleared.") @ConfigEntry(path = "area.reset.on-leave.ender-chest") private boolean onLeaveResetEnderChest = false; @ConfigComment("Reset advancements.") @ConfigEntry(path = "area.reset.on-leave.reset-advancements") private boolean onLeaveResetAdvancements = false; @ConfigComment("Grant these advancements") @ConfigEntry(path = "area.reset.on-leave.grant-advancements") private List onLeaveGrantAdvancements = new ArrayList<>(); @ConfigComment("Toggles the automatic area creation upon the player's first login on your server.") @ConfigComment("If set to true,") @ConfigComment(" * Upon connecting to your server for the first time, the player will be told that") @ConfigComment(" an area will be created for him.") @ConfigComment(" * Make sure you have a Blueprint Bundle called \"default\": this is the one that will") @ConfigComment(" be used to create the area.") @ConfigComment(" * An area will be created for the player without needing him to run the create command.") @ConfigComment("If set to false, this will disable this feature entirely.") @ConfigComment("Warning:") @ConfigComment(" * If you are running multiple gamemodes on your server, and all of them have") @ConfigComment(" this feature enabled, an area in all the gamemodes will be created simultaneously.") @ConfigComment(" However, it is impossible to know on which area the player will be teleported to afterwards.") @ConfigComment(" * Island creation can be resource-intensive, please consider the options below to help mitigate") @ConfigComment(" the potential issues, especially if you expect a lot of players to connect to your server") @ConfigComment(" in a limited period of time.") @ConfigEntry(path = "area.create-area-on-first-login.enable") private boolean createIslandOnFirstLoginEnabled; @ConfigComment("Time in seconds after the player logged in, before his area gets created.") @ConfigComment("If set to 0 or less, the area will be created directly upon the player's login.") @ConfigComment("It is recommended to keep this value under a minute's time.") @ConfigEntry(path = "area.create-area-on-first-login.delay") private int createIslandOnFirstLoginDelay = 5; @ConfigComment("Toggles whether the area creation should be aborted if the player logged off while the") @ConfigComment("delay (see the option above) has not worn off yet.") @ConfigComment("If set to true,") @ConfigComment(" * If the player has logged off the server while the delay (see the option above) has not") @ConfigComment(" worn off yet, this will cancel the area creation.") @ConfigComment(" * If the player relogs afterward, since he will not be recognized as a new player, no area") @ConfigComment(" would be created for him.") @ConfigComment(" * If the area creation started before the player logged off, it will continue.") @ConfigComment("If set to false, the player's area will be created even if he went offline in the meantime.") @ConfigComment("Note this option has no effect if the delay (see the option above) is set to 0 or less.") @ConfigEntry(path = "area.create-area-on-first-login.abort-on-logout") private boolean createIslandOnFirstLoginAbortOnLogout = true; @ConfigComment("Toggles whether the player should be teleported automatically to his area when it is created.") @ConfigComment("If set to false, the player will be told his area is ready but will have to teleport to his area using the command.") @ConfigEntry(path = "area.teleport-player-to-area-when-created") private boolean teleportPlayerToIslandUponIslandCreation = true; // Commands @ConfigComment("List of commands to run when a player joins an area or creates one.") @ConfigComment("These commands are run by the console, unless otherwise stated using the [SUDO] prefix,") @ConfigComment("in which case they are executed by the player.") @ConfigComment("") @ConfigComment("Available placeholders for the commands are the following:") @ConfigComment(" * [name]: name of the player") @ConfigComment("") @ConfigComment("Here are some examples of valid commands to execute:") @ConfigComment(" * \"[SUDO] bbox version\"") @ConfigComment(" * \"boxadmin deaths set [player] 0\"") @ConfigEntry(path = "area.commands.on-join") private List onJoinCommands = new ArrayList<>(); @ConfigComment("List of commands to run when a player leaves an area, resets his area or gets kicked from it.") @ConfigComment("These commands are run by the console, unless otherwise stated using the [SUDO] prefix,") @ConfigComment("in which case they are executed by the player.") @ConfigComment("") @ConfigComment("Available placeholders for the commands are the following:") @ConfigComment(" * [name]: name of the player") @ConfigComment("") @ConfigComment("Here are some examples of valid commands to execute:") @ConfigComment(" * '[SUDO] bbox version'") @ConfigComment(" * 'boxadmin deaths set [player] 0'") @ConfigComment("") @ConfigComment("Note that player-executed commands might not work, as these commands can be run with said player being offline.") @ConfigEntry(path = "area.commands.on-leave") private List onLeaveCommands = new ArrayList<>(); @ConfigComment("List of commands that should be executed when the player respawns after death if Flags.ISLAND_RESPAWN is true.") @ConfigComment("These commands are run by the console, unless otherwise stated using the [SUDO] prefix,") @ConfigComment("in which case they are executed by the player.") @ConfigComment("") @ConfigComment("Available placeholders for the commands are the following:") @ConfigComment(" * [name]: name of the player") @ConfigComment("") @ConfigComment("Here are some examples of valid commands to execute:") @ConfigComment(" * '[SUDO] bbox version'") @ConfigComment(" * 'bsbadmin deaths set [player] 0'") @ConfigComment("") @ConfigComment("Note that player-executed commands might not work, as these commands can be run with said player being offline.") @ConfigEntry(path = "area.commands.on-respawn", since = "1.14.0") private List onRespawnCommands = new ArrayList<>(); // Sethome @ConfigComment("Allow setting home in the nether.") @ConfigEntry(path = "area.sethome.nether.allow") private boolean allowSetHomeInNether = true; @ConfigEntry(path = "area.sethome.nether.require-confirmation") private boolean requireConfirmationToSetHomeInNether = true; @ConfigComment("Allow setting home in the end.") @ConfigEntry(path = "area.sethome.the-end.allow") private boolean allowSetHomeInTheEnd = true; @ConfigEntry(path = "area.sethome.the-end.require-confirmation") private boolean requireConfirmationToSetHomeInTheEnd = true; // Deaths @ConfigComment("Whether deaths are counted or not.") @ConfigEntry(path = "area.deaths.counted") private boolean deathsCounted = true; @ConfigComment("Maximum number of deaths to count. The death count can be used by add-ons.") @ConfigEntry(path = "area.deaths.max") private int deathsMax = 10; @ConfigComment("When a player joins a team, reset their death count") @ConfigEntry(path = "area.deaths.team-join-reset") private boolean teamJoinDeathReset = true; @ConfigComment("Reset player death count when they start a new area or reset an area") @ConfigEntry(path = "area.deaths.reset-on-new-area") private boolean deathsResetOnNewIsland = true; // --------------------------------------------- /* PROTECTION */ @ConfigComment("Geo restrict mobs.") @ConfigComment("Mobs that exit the area space where they were spawned will be removed.") @ConfigEntry(path = "protection.geo-limit-settings") private List geoLimitSettings = new ArrayList<>(); @ConfigComment("Blocked mobs.") @ConfigComment("List of mobs that should not spawn in Boxed.") @ConfigEntry(path = "protection.block-mobs") private List mobLimitSettings = new ArrayList<>(); // Invincible visitor settings @ConfigComment("Invincible visitors. List of damages that will not affect visitors.") @ConfigComment("Make list blank if visitors should receive all damages") @ConfigEntry(path = "protection.invincible-visitors") private List ivSettings = new ArrayList<>(); //---------------------------------------------------------------------------------------/ @ConfigComment("These settings should not be edited") @ConfigEntry(path = "do-not-edit-these-settings.reset-epoch") private long resetEpoch = 0; /** * @return the friendlyName */ @Override public String getFriendlyName() { return friendlyName; } /** * @return the worldName */ @Override public String getWorldName() { return worldName; } /** * @return the difficulty */ @Override public Difficulty getDifficulty() { return difficulty; } /** * @return the islandDistance */ @Override public int getIslandDistance() { return islandDistance; } /** * @return the islandProtectionRange */ @Override public int getIslandProtectionRange() { return islandProtectionRange; } /** * @return the islandStartX */ @Override public int getIslandStartX() { return islandStartX; } /** * @return the islandStartZ */ @Override public int getIslandStartZ() { return islandStartZ; } /** * @return the islandXOffset */ @Override public int getIslandXOffset() { return 0; } /** * @return the islandZOffset */ @Override public int getIslandZOffset() { return 0; } /** * @return the islandHeight */ @Override public int getIslandHeight() { return islandHeight; } /** * @return the useOwnGenerator */ @Override public boolean isUseOwnGenerator() { return false; } /** * @return the seaHeight */ @Override public int getSeaHeight() { return 0; } /** * @return the maxIslands */ @Override public int getMaxIslands() { return maxIslands; } /** * @return the defaultGameMode */ @Override public GameMode getDefaultGameMode() { return GameMode.SURVIVAL; } /** * @return the netherGenerate */ @Override public boolean isNetherGenerate() { return netherGenerate; } /** * @return the netherIslands */ @Override public boolean isNetherIslands() { return true; } /** * @return the netherSpawnRadius */ @Override public int getNetherSpawnRadius() { return 32; } /** * @return the endGenerate */ @Override public boolean isEndGenerate() { return endGenerate; } /** * @return the endIslands */ @Override public boolean isEndIslands() { return false; } /** * @return the dragonSpawn */ @Override public boolean isDragonSpawn() { return false; } /** * @return the removeMobsWhitelist */ @Override public Set getRemoveMobsWhitelist() { return removeMobsWhitelist; } /** * @return the worldFlags */ @Override public Map getWorldFlags() { return worldFlags; } /** * @return the defaultIslandFlags */ @Override public Map getDefaultIslandFlags() { return defaultIslandFlags; } /** * @return the defaultIslandSettings */ @Override public Map getDefaultIslandSettings() { return defaultIslandSettings; } /** * @return the hidden flags */ @Override public List getHiddenFlags() { return hiddenFlags; } /** * @return the visitorBannedCommands */ @Override public List getVisitorBannedCommands() { return visitorBannedCommands; } /** * @return the fallingBannedCommands */ @Override public List getFallingBannedCommands() { return fallingBannedCommands; } /** * @return the maxTeamSize */ @Override public int getMaxTeamSize() { return maxTeamSize; } /** * @return the maxHomes */ @Override public int getMaxHomes() { return maxHomes; } /** * @return the resetLimit */ @Override public int getResetLimit() { return resetLimit; } /** * @return the leaversLoseReset */ @Override public boolean isLeaversLoseReset() { return leaversLoseReset; } /** * @return the kickedKeepInventory */ @Override public boolean isKickedKeepInventory() { return kickedKeepInventory; } /** * This method returns the createIslandOnFirstLoginEnabled boolean value. * @return the createIslandOnFirstLoginEnabled value * @since 1.9.0 */ @Override public boolean isCreateIslandOnFirstLoginEnabled() { return createIslandOnFirstLoginEnabled; } /** * This method returns the createIslandOnFirstLoginDelay int value. * @return the createIslandOnFirstLoginDelay value * @since 1.9.0 */ @Override public int getCreateIslandOnFirstLoginDelay() { return createIslandOnFirstLoginDelay; } /** * This method returns the createIslandOnFirstLoginAbortOnLogout boolean value. * @return the createIslandOnFirstLoginAbortOnLogout value * @since 1.9.0 */ @Override public boolean isCreateIslandOnFirstLoginAbortOnLogout() { return createIslandOnFirstLoginAbortOnLogout; } /** * @return the onJoinResetMoney */ @Override public boolean isOnJoinResetMoney() { return onJoinResetMoney; } /** * @return the onJoinResetInventory */ @Override public boolean isOnJoinResetInventory() { return onJoinResetInventory; } /** * @return the onJoinResetEnderChest */ @Override public boolean isOnJoinResetEnderChest() { return onJoinResetEnderChest; } /** * @return the onLeaveResetMoney */ @Override public boolean isOnLeaveResetMoney() { return onLeaveResetMoney; } /** * @return the onLeaveResetInventory */ @Override public boolean isOnLeaveResetInventory() { return onLeaveResetInventory; } /** * @return the onLeaveResetEnderChest */ @Override public boolean isOnLeaveResetEnderChest() { return onLeaveResetEnderChest; } /** * @return the isDeathsCounted */ @Override public boolean isDeathsCounted() { return deathsCounted; } /** * @return the allowSetHomeInNether */ @Override public boolean isAllowSetHomeInNether() { return allowSetHomeInNether; } /** * @return the allowSetHomeInTheEnd */ @Override public boolean isAllowSetHomeInTheEnd() { return allowSetHomeInTheEnd; } /** * @return the requireConfirmationToSetHomeInNether */ @Override public boolean isRequireConfirmationToSetHomeInNether() { return requireConfirmationToSetHomeInNether; } /** * @return the requireConfirmationToSetHomeInTheEnd */ @Override public boolean isRequireConfirmationToSetHomeInTheEnd() { return requireConfirmationToSetHomeInTheEnd; } /** * @return the deathsMax */ @Override public int getDeathsMax() { return deathsMax; } /** * @return the teamJoinDeathReset */ @Override public boolean isTeamJoinDeathReset() { return teamJoinDeathReset; } /** * @return the geoLimitSettings */ @Override public List getGeoLimitSettings() { return geoLimitSettings; } /** * @return the ivSettings */ @Override public List getIvSettings() { return ivSettings; } /** * @return the resetEpoch */ @Override public long getResetEpoch() { return resetEpoch; } /** * @param friendlyName the friendlyName to set */ public void setFriendlyName(String friendlyName) { this.friendlyName = friendlyName; } /** * @param worldName the worldName to set */ public void setWorldName(String worldName) { this.worldName = worldName; } /** * @param difficulty the difficulty to set */ @Override public void setDifficulty(Difficulty difficulty) { this.difficulty = difficulty; } /** * @param islandDistance the islandDistance to set */ public void setIslandDistance(int islandDistance) { this.islandDistance = islandDistance; } /** * @param islandProtectionRange the islandProtectionRange to set */ public void setIslandProtectionRange(int islandProtectionRange) { this.islandProtectionRange = islandProtectionRange; } /** * @param islandStartX the islandStartX to set */ public void setIslandStartX(int islandStartX) { this.islandStartX = islandStartX; } /** * @param islandStartZ the islandStartZ to set */ public void setIslandStartZ(int islandStartZ) { this.islandStartZ = islandStartZ; } /** * @param maxIslands the maxIslands to set */ public void setMaxIslands(int maxIslands) { this.maxIslands = maxIslands; } /** * @param netherGenerate the netherGenerate to set */ public void setNetherGenerate(boolean netherGenerate) { this.netherGenerate = netherGenerate; } /** * @param endGenerate the endGenerate to set */ public void setEndGenerate(boolean endGenerate) { this.endGenerate = endGenerate; } /** * @param removeMobsWhitelist the removeMobsWhitelist to set */ public void setRemoveMobsWhitelist(Set removeMobsWhitelist) { this.removeMobsWhitelist = removeMobsWhitelist; } /** * @param worldFlags the worldFlags to set */ public void setWorldFlags(Map worldFlags) { this.worldFlags = worldFlags; } /** * @param defaultIslandFlags the defaultIslandFlags to set */ public void setDefaultIslandFlags(Map defaultIslandFlags) { this.defaultIslandFlags = defaultIslandFlags; } /** * @param defaultIslandSettings the defaultIslandSettings to set */ public void setDefaultIslandSettings(Map defaultIslandSettings) { this.defaultIslandSettings = defaultIslandSettings; } /** * @param hiddenFlags the hidden flags to set */ public void setHiddenFlags(List hiddenFlags) { this.hiddenFlags = hiddenFlags; } /** * @param visitorBannedCommands the visitorBannedCommands to set */ public void setVisitorBannedCommands(List visitorBannedCommands) { this.visitorBannedCommands = visitorBannedCommands; } /** * @param fallingBannedCommands the fallingBannedCommands to set */ public void setFallingBannedCommands(List fallingBannedCommands) { this.fallingBannedCommands = fallingBannedCommands; } /** * @param maxTeamSize the maxTeamSize to set */ public void setMaxTeamSize(int maxTeamSize) { this.maxTeamSize = maxTeamSize; } /** * @param maxHomes the maxHomes to set */ public void setMaxHomes(int maxHomes) { this.maxHomes = maxHomes; } /** * @param resetLimit the resetLimit to set */ public void setResetLimit(int resetLimit) { this.resetLimit = resetLimit; } /** * @param leaversLoseReset the leaversLoseReset to set */ public void setLeaversLoseReset(boolean leaversLoseReset) { this.leaversLoseReset = leaversLoseReset; } /** * @param kickedKeepInventory the kickedKeepInventory to set */ public void setKickedKeepInventory(boolean kickedKeepInventory) { this.kickedKeepInventory = kickedKeepInventory; } /** * @param onJoinResetMoney the onJoinResetMoney to set */ public void setOnJoinResetMoney(boolean onJoinResetMoney) { this.onJoinResetMoney = onJoinResetMoney; } /** * @param onJoinResetInventory the onJoinResetInventory to set */ public void setOnJoinResetInventory(boolean onJoinResetInventory) { this.onJoinResetInventory = onJoinResetInventory; } /** * @param onJoinResetEnderChest the onJoinResetEnderChest to set */ public void setOnJoinResetEnderChest(boolean onJoinResetEnderChest) { this.onJoinResetEnderChest = onJoinResetEnderChest; } /** * @param onLeaveResetMoney the onLeaveResetMoney to set */ public void setOnLeaveResetMoney(boolean onLeaveResetMoney) { this.onLeaveResetMoney = onLeaveResetMoney; } /** * @param onLeaveResetInventory the onLeaveResetInventory to set */ public void setOnLeaveResetInventory(boolean onLeaveResetInventory) { this.onLeaveResetInventory = onLeaveResetInventory; } /** * @param onLeaveResetEnderChest the onLeaveResetEnderChest to set */ public void setOnLeaveResetEnderChest(boolean onLeaveResetEnderChest) { this.onLeaveResetEnderChest = onLeaveResetEnderChest; } /** * @param createIslandOnFirstLoginEnabled the createIslandOnFirstLoginEnabled to set */ public void setCreateIslandOnFirstLoginEnabled(boolean createIslandOnFirstLoginEnabled) { this.createIslandOnFirstLoginEnabled = createIslandOnFirstLoginEnabled; } /** * @param createIslandOnFirstLoginDelay the createIslandOnFirstLoginDelay to set */ public void setCreateIslandOnFirstLoginDelay(int createIslandOnFirstLoginDelay) { this.createIslandOnFirstLoginDelay = createIslandOnFirstLoginDelay; } /** * @param createIslandOnFirstLoginAbortOnLogout the createIslandOnFirstLoginAbortOnLogout to set */ public void setCreateIslandOnFirstLoginAbortOnLogout(boolean createIslandOnFirstLoginAbortOnLogout) { this.createIslandOnFirstLoginAbortOnLogout = createIslandOnFirstLoginAbortOnLogout; } /** * @param deathsCounted the deathsCounted to set */ public void setDeathsCounted(boolean deathsCounted) { this.deathsCounted = deathsCounted; } /** * @param deathsMax the deathsMax to set */ public void setDeathsMax(int deathsMax) { this.deathsMax = deathsMax; } /** * @param teamJoinDeathReset the teamJoinDeathReset to set */ public void setTeamJoinDeathReset(boolean teamJoinDeathReset) { this.teamJoinDeathReset = teamJoinDeathReset; } /** * @param geoLimitSettings the geoLimitSettings to set */ public void setGeoLimitSettings(List geoLimitSettings) { this.geoLimitSettings = geoLimitSettings; } /** * @param ivSettings the ivSettings to set */ public void setIvSettings(List ivSettings) { this.ivSettings = ivSettings; } /** * @param allowSetHomeInNether the allowSetHomeInNether to set */ public void setAllowSetHomeInNether(boolean allowSetHomeInNether) { this.allowSetHomeInNether = allowSetHomeInNether; } /** * @param allowSetHomeInTheEnd the allowSetHomeInTheEnd to set */ public void setAllowSetHomeInTheEnd(boolean allowSetHomeInTheEnd) { this.allowSetHomeInTheEnd = allowSetHomeInTheEnd; } /** * @param requireConfirmationToSetHomeInNether the requireConfirmationToSetHomeInNether to set */ public void setRequireConfirmationToSetHomeInNether(boolean requireConfirmationToSetHomeInNether) { this.requireConfirmationToSetHomeInNether = requireConfirmationToSetHomeInNether; } /** * @param requireConfirmationToSetHomeInTheEnd the requireConfirmationToSetHomeInTheEnd to set */ public void setRequireConfirmationToSetHomeInTheEnd(boolean requireConfirmationToSetHomeInTheEnd) { this.requireConfirmationToSetHomeInTheEnd = requireConfirmationToSetHomeInTheEnd; } /** * @param resetEpoch the resetEpoch to set */ @Override public void setResetEpoch(long resetEpoch) { this.resetEpoch = resetEpoch; } @Override public String getPermissionPrefix() { return "boxed"; } @Override public boolean isWaterUnsafe() { return false; } /** * @return the banLimit */ @Override public int getBanLimit() { return banLimit; } /** * @param banLimit the banLimit to set */ public void setBanLimit(int banLimit) { this.banLimit = banLimit; } /** * @return the playerCommandAliases */ @Override public String getPlayerCommandAliases() { return playerCommandAliases; } /** * @param playerCommandAliases the playerCommandAliases to set */ public void setPlayerCommandAliases(String playerCommandAliases) { this.playerCommandAliases = playerCommandAliases; } /** * @return the adminCommandAliases */ @Override public String getAdminCommandAliases() { return adminCommandAliases; } /** * @param adminCommandAliases the adminCommandAliases to set */ public void setAdminCommandAliases(String adminCommandAliases) { this.adminCommandAliases = adminCommandAliases; } /** * @return the deathsResetOnNew */ @Override public boolean isDeathsResetOnNewIsland() { return deathsResetOnNewIsland; } /** * @param deathsResetOnNew the deathsResetOnNew to set */ public void setDeathsResetOnNewIsland(boolean deathsResetOnNew) { this.deathsResetOnNewIsland = deathsResetOnNew; } /** * @return the onJoinCommands */ @Override public List getOnJoinCommands() { return onJoinCommands; } /** * @param onJoinCommands the onJoinCommands to set */ public void setOnJoinCommands(List onJoinCommands) { this.onJoinCommands = onJoinCommands; } /** * @return the onLeaveCommands */ @Override public List getOnLeaveCommands() { return onLeaveCommands; } /** * @param onLeaveCommands the onLeaveCommands to set */ public void setOnLeaveCommands(List onLeaveCommands) { this.onLeaveCommands = onLeaveCommands; } /** * @return the onRespawnCommands */ @Override public List getOnRespawnCommands() { return onRespawnCommands; } /** * Sets on respawn commands. * * @param onRespawnCommands the on respawn commands */ public void setOnRespawnCommands(List onRespawnCommands) { this.onRespawnCommands = onRespawnCommands; } /** * @return the onJoinResetHealth */ @Override public boolean isOnJoinResetHealth() { return onJoinResetHealth; } /** * @param onJoinResetHealth the onJoinResetHealth to set */ public void setOnJoinResetHealth(boolean onJoinResetHealth) { this.onJoinResetHealth = onJoinResetHealth; } /** * @return the onJoinResetHunger */ @Override public boolean isOnJoinResetHunger() { return onJoinResetHunger; } /** * @param onJoinResetHunger the onJoinResetHunger to set */ public void setOnJoinResetHunger(boolean onJoinResetHunger) { this.onJoinResetHunger = onJoinResetHunger; } /** * @return the onJoinResetXP */ @Override public boolean isOnJoinResetXP() { return onJoinResetXP; } /** * @param onJoinResetXP the onJoinResetXP to set */ public void setOnJoinResetXP(boolean onJoinResetXP) { this.onJoinResetXP = onJoinResetXP; } /** * @return the onLeaveResetHealth */ @Override public boolean isOnLeaveResetHealth() { return onLeaveResetHealth; } /** * @param onLeaveResetHealth the onLeaveResetHealth to set */ public void setOnLeaveResetHealth(boolean onLeaveResetHealth) { this.onLeaveResetHealth = onLeaveResetHealth; } /** * @return the onLeaveResetHunger */ @Override public boolean isOnLeaveResetHunger() { return onLeaveResetHunger; } /** * @param onLeaveResetHunger the onLeaveResetHunger to set */ public void setOnLeaveResetHunger(boolean onLeaveResetHunger) { this.onLeaveResetHunger = onLeaveResetHunger; } /** * @return the onLeaveResetXP */ @Override public boolean isOnLeaveResetXP() { return onLeaveResetXP; } /** * @param onLeaveResetXP the onLeaveResetXP to set */ public void setOnLeaveResetXP(boolean onLeaveResetXP) { this.onLeaveResetXP = onLeaveResetXP; } /** * @return the pasteMissingIslands */ @Override public boolean isPasteMissingIslands() { return false; } /** * Toggles whether the player should be teleported automatically to his island when it is created. * @return {@code true} if the player should be teleported automatically to his island when it is created, * {@code false} otherwise. * @since 1.10.0 */ @Override public boolean isTeleportPlayerToIslandUponIslandCreation() { return teleportPlayerToIslandUponIslandCreation; } /** * @param teleportPlayerToIslandUponIslandCreation the teleportPlayerToIslandUponIslandCreation to set * @since 1.10.0 */ public void setTeleportPlayerToIslandUponIslandCreation(boolean teleportPlayerToIslandUponIslandCreation) { this.teleportPlayerToIslandUponIslandCreation = teleportPlayerToIslandUponIslandCreation; } /** * @return the spawnLimitMonsters */ public int getSpawnLimitMonsters() { return spawnLimitMonsters; } /** * @param spawnLimitMonsters the spawnLimitMonsters to set */ public void setSpawnLimitMonsters(int spawnLimitMonsters) { this.spawnLimitMonsters = spawnLimitMonsters; } /** * @return the spawnLimitAnimals */ public int getSpawnLimitAnimals() { return spawnLimitAnimals; } /** * @param spawnLimitAnimals the spawnLimitAnimals to set */ public void setSpawnLimitAnimals(int spawnLimitAnimals) { this.spawnLimitAnimals = spawnLimitAnimals; } /** * @return the spawnLimitWaterAnimals */ public int getSpawnLimitWaterAnimals() { return spawnLimitWaterAnimals; } /** * @param spawnLimitWaterAnimals the spawnLimitWaterAnimals to set */ public void setSpawnLimitWaterAnimals(int spawnLimitWaterAnimals) { this.spawnLimitWaterAnimals = spawnLimitWaterAnimals; } /** * @return the spawnLimitAmbient */ public int getSpawnLimitAmbient() { return spawnLimitAmbient; } /** * @param spawnLimitAmbient the spawnLimitAmbient to set */ public void setSpawnLimitAmbient(int spawnLimitAmbient) { this.spawnLimitAmbient = spawnLimitAmbient; } /** * @return the ticksPerAnimalSpawns */ public int getTicksPerAnimalSpawns() { return ticksPerAnimalSpawns; } /** * @param ticksPerAnimalSpawns the ticksPerAnimalSpawns to set */ public void setTicksPerAnimalSpawns(int ticksPerAnimalSpawns) { this.ticksPerAnimalSpawns = ticksPerAnimalSpawns; } /** * @return the ticksPerMonsterSpawns */ public int getTicksPerMonsterSpawns() { return ticksPerMonsterSpawns; } /** * @param ticksPerMonsterSpawns the ticksPerMonsterSpawns to set */ public void setTicksPerMonsterSpawns(int ticksPerMonsterSpawns) { this.ticksPerMonsterSpawns = ticksPerMonsterSpawns; } /** * @return the maxCoopSize */ @Override public int getMaxCoopSize() { return maxCoopSize; } /** * @param maxCoopSize the maxCoopSize to set */ public void setMaxCoopSize(int maxCoopSize) { this.maxCoopSize = maxCoopSize; } /** * @return the maxTrustSize */ @Override public int getMaxTrustSize() { return maxTrustSize; } /** * @param maxTrustSize the maxTrustSize to set */ public void setMaxTrustSize(int maxTrustSize) { this.maxTrustSize = maxTrustSize; } /** * @return the defaultNewPlayerAction */ @Override public String getDefaultNewPlayerAction() { return defaultNewPlayerAction; } /** * @param defaultNewPlayerAction the defaultNewPlayerAction to set */ public void setDefaultNewPlayerAction(String defaultNewPlayerAction) { this.defaultNewPlayerAction = defaultNewPlayerAction; } /** * @return the defaultPlayerAction */ @Override public String getDefaultPlayerAction() { return defaultPlayerAction; } /** * @param defaultPlayerAction the defaultPlayerAction to set */ public void setDefaultPlayerAction(String defaultPlayerAction) { this.defaultPlayerAction = defaultPlayerAction; } /** * @return the mobLimitSettings */ @Override public List getMobLimitSettings() { return mobLimitSettings; } /** * @param mobLimitSettings the mobLimitSettings to set */ public void setMobLimitSettings(List mobLimitSettings) { this.mobLimitSettings = mobLimitSettings; } /** * @return the seed */ public long getSeed() { return seed; } /** * @param seed the seed to set */ public void setSeed(long seed) { this.seed = seed; } @Override public boolean isCheckForBlocks() { // Do not check for blocks when looking for a new island spot return false; } /** * @return the onJoinResetAdvancements */ public boolean isOnJoinResetAdvancements() { return onJoinResetAdvancements; } /** * @param onJoinResetAdvancements the onJoinResetAdvancements to set */ public void setOnJoinResetAdvancements(boolean onJoinResetAdvancements) { this.onJoinResetAdvancements = onJoinResetAdvancements; } /** * @return the onJoinGrantAdvancements */ public List getOnJoinGrantAdvancements() { return onJoinGrantAdvancements; } /** * @param onJoinGrantAdvancements the onJoinGrantAdvancements to set */ public void setOnJoinGrantAdvancements(List onJoinGrantAdvancements) { this.onJoinGrantAdvancements = onJoinGrantAdvancements; } /** * @return the onLeaveGrantAdvancements */ public List getOnLeaveGrantAdvancements() { return onLeaveGrantAdvancements; } /** * @param onLeaveGrantAdvancements the onLeaveGrantAdvancements to set */ public void setOnLeaveGrantAdvancements(List onLeaveGrantAdvancements) { this.onLeaveGrantAdvancements = onLeaveGrantAdvancements; } /** * @return the onLeaveResetAdvancements */ public boolean isOnLeaveResetAdvancements() { return onLeaveResetAdvancements; } /** * @param onLeaveResetAdvancements the onLeaveResetAdvancements to set */ public void setOnLeaveResetAdvancements(boolean onLeaveResetAdvancements) { this.onLeaveResetAdvancements = onLeaveResetAdvancements; } /** * @return the makeNetherPortals */ @Override public boolean isMakeNetherPortals() { return makeNetherPortals; } /** * Sets make nether portals. * @param makeNetherPortals the make nether portals */ public void setMakeNetherPortals(boolean makeNetherPortals) { this.makeNetherPortals = makeNetherPortals; } /** * @return the broadcastAdvancements */ public boolean isBroadcastAdvancements() { return broadcastAdvancements; } /** * @param broadcastAdvancements the broadcastAdvancements to set */ public void setBroadcastAdvancements(boolean broadcastAdvancements) { this.broadcastAdvancements = broadcastAdvancements; } /** * @return the denyVisitorAdvancements */ public boolean isDenyVisitorAdvancements() { return denyVisitorAdvancements; } /** * @param denyVisitorAdvancements the denyVisitorAdvancements to set */ public void setDenyVisitorAdvancements(boolean denyVisitorAdvancements) { this.denyVisitorAdvancements = denyVisitorAdvancements; } /** * @return the seedX */ public int getSeedX() { return 0; } /** * @return the seedZ */ public int getSeedZ() { return 0; } /** * @return the netherSeedX */ public int getNetherSeedX() { return 0; } /** * @return the netherSeedZ */ public int getNetherSeedZ() { return 0; } /** * @return the endSeedX */ public int getEndSeedX() { return 0; } /** * @return the endSeedZ */ public int getEndSeedZ() { return 0; } /** * @param islandHeight the islandHeight to set */ public void setIslandHeight(int islandHeight) { this.islandHeight = islandHeight; } /** * @return the ignoreAdvancements */ public boolean isIgnoreAdvancements() { return ignoreAdvancements; } /** * @param ignoreAdvancements the ignoreAdvancements to set */ public void setIgnoreAdvancements(boolean ignoreAdvancements) { this.ignoreAdvancements = ignoreAdvancements; } }