diff --git a/src/main/java/world/bentobox/caveblock/Settings.java b/src/main/java/world/bentobox/caveblock/Settings.java index cbf838f..06774b7 100644 --- a/src/main/java/world/bentobox/caveblock/Settings.java +++ b/src/main/java/world/bentobox/caveblock/Settings.java @@ -662,78 +662,130 @@ public class Settings implements DataObject, WorldSettings } + /** + * This method returns the worldDepth value. + * @return the value of worldDepth. + */ public int getWorldDepth() { return worldDepth; } + /** + * This method returns the normalRoof value. + * @return the value of normalRoof. + */ public boolean isNormalRoof() { return normalRoof; } + /** + * This method returns the normalFloor value. + * @return the value of normalFloor. + */ public boolean isNormalFloor() { return normalFloor; } + /** + * This method returns the normalMainBlock value. + * @return the value of normalMainBlock. + */ public Material getNormalMainBlock() { return normalMainBlock; } + /** + * This method returns the normalBlocks value. + * @return the value of normalBlocks. + */ public List getNormalBlocks() { return normalBlocks; } + /** + * This method returns the netherFloor value. + * @return the value of netherFloor. + */ public boolean isNetherFloor() { return netherFloor; } + /** + * This method returns the netherMainBlock value. + * @return the value of netherMainBlock. + */ public Material getNetherMainBlock() { return netherMainBlock; } + /** + * This method returns the netherBlocks value. + * @return the value of netherBlocks. + */ public List getNetherBlocks() { return netherBlocks; } + /** + * This method returns the endRoof value. + * @return the value of endRoof. + */ public boolean isEndRoof() { return endRoof; } + /** + * This method returns the endFloor value. + * @return the value of endFloor. + */ public boolean isEndFloor() { return endFloor; } + /** + * This method returns the endMainBlock value. + * @return the value of endMainBlock. + */ public Material getEndMainBlock() { return endMainBlock; } + /** + * This method returns the endBlocks value. + * @return the value of endBlocks. + */ public List getEndBlocks() { return endBlocks; } + /** + * This method returns the numberOfBlockGenerationTries value. + * @return the value of numberOfBlockGenerationTries. + */ public int getNumberOfBlockGenerationTries() { return numberOfBlockGenerationTries; @@ -1361,78 +1413,143 @@ public class Settings implements DataObject, WorldSettings } + /** + * This method sets the worldDepth value. + * @param worldDepth the worldDepth new value. + * + */ public void setWorldDepth(int worldDepth) { this.worldDepth = worldDepth; } + /** + * This method sets the normalRoof value. + * @param normalRoof the normalRoof new value. + * + */ public void setNormalRoof(boolean normalRoof) { this.normalRoof = normalRoof; } + /** + * This method sets the normalFloor value. + * @param normalFloor the normalFloor new value. + * + */ public void setNormalFloor(boolean normalFloor) { this.normalFloor = normalFloor; } + /** + * This method sets the normalMainBlock value. + * @param normalMainBlock the normalMainBlock new value. + * + */ public void setNormalMainBlock(Material normalMainBlock) { this.normalMainBlock = normalMainBlock; } + /** + * This method sets the normalBlocks value. + * @param normalBlocks the normalBlocks new value. + * + */ public void setNormalBlocks(List normalBlocks) { this.normalBlocks = normalBlocks; } + /** + * This method sets the netherFloor value. + * @param netherFloor the netherFloor new value. + * + */ public void setNetherFloor(boolean netherFloor) { this.netherFloor = netherFloor; } + /** + * This method sets the netherMainBlock value. + * @param netherMainBlock the netherMainBlock new value. + * + */ public void setNetherMainBlock(Material netherMainBlock) { this.netherMainBlock = netherMainBlock; } + /** + * This method sets the netherBlocks value. + * @param netherBlocks the netherBlocks new value. + * + */ public void setNetherBlocks(List netherBlocks) { this.netherBlocks = netherBlocks; } + /** + * This method sets the endRoof value. + * @param endRoof the endRoof new value. + * + */ public void setEndRoof(boolean endRoof) { this.endRoof = endRoof; } + /** + * This method sets the endFloor value. + * @param endFloor the endFloor new value. + * + */ public void setEndFloor(boolean endFloor) { this.endFloor = endFloor; } + /** + * This method sets the endMainBlock value. + * @param endMainBlock the endMainBlock new value. + * + */ public void setEndMainBlock(Material endMainBlock) { this.endMainBlock = endMainBlock; } + /** + * This method sets the endBlocks value. + * @param endBlocks the endBlocks new value. + * + */ public void setEndBlocks(List endBlocks) { this.endBlocks = endBlocks; } + /** + * This method sets the numberOfBlockGenerationTries value. + * @param numberOfBlockGenerationTries the numberOfBlockGenerationTries new value. + * + */ public void setNumberOfBlockGenerationTries(int numberOfBlockGenerationTries) { this.numberOfBlockGenerationTries = numberOfBlockGenerationTries; @@ -1548,9 +1665,15 @@ public class Settings implements DataObject, WorldSettings @ConfigEntry(path = "world.normal.main-block", needsReset = true) private Material normalMainBlock = Material.STONE; - @ConfigComment("Rare blocks that will be randomly placed around world. 1-material, 2-rarity, 3-pack size") - @ConfigComment("F.E. DIAMOND_ORE:1:3 means that diamond has ~0.1% chance being spawned and max of 3 blocks.") - @ConfigComment("Rarity index can be over 100. It will be summed and rarity for block will be BLOCK_RARITY/RARITY_SUM * 10.") + @ConfigComment("Blocks that will occasionally replace main block by random chance.") + @ConfigComment("Blocks will replace only main-block and will try to create packs that") + @ConfigComment("are set in their strings. Chance of spawning also is required.") + @ConfigComment("For materials first string must be MATERIAL, for entity: ENTITY.") + @ConfigComment("Entities spawned via generator are not protected from despawing.") + @ConfigComment("Working only with 2 high mobs currently.") + @ConfigComment("Example:") + @ConfigComment("MATERIAL:DIAMOND:100:5 - means there is 100% chace of spawing diamonds") + @ConfigComment("where max amount in pack are 5 per each subchunk!") @ConfigEntry(path = "world.normal.blocks", needsReset = true) private List normalBlocks = new ArrayList<>(); @@ -1591,9 +1714,15 @@ public class Settings implements DataObject, WorldSettings @ConfigEntry(path = "world.nether.main-block", needsReset = true) private Material netherMainBlock = Material.STONE; - @ConfigComment("Rare blocks that will be randomly placed around world. 1-material, 2-rarity, 3-pack size") - @ConfigComment("F.E. DIAMOND_ORE:1:3 means that diamond has ~0.1% chance being spawned and max of 3 blocks.") - @ConfigComment("Rarity index can be over 100. It will be summed and rarity for block will be BLOCK_RARITY/RARITY_SUM * 10.") + @ConfigComment("Blocks that will occasionally replace main block by random chance.") + @ConfigComment("Blocks will replace only main-block and will try to create packs that") + @ConfigComment("are set in their strings. Chance of spawning also is required.") + @ConfigComment("For materials first string must be MATERIAL, for entity: ENTITY.") + @ConfigComment("Entities spawned via generator are not protected from despawing.") + @ConfigComment("Working only with 2 high mobs currently.") + @ConfigComment("Example:") + @ConfigComment("MATERIAL:DIAMOND:100:5 - means there is 100% chace of spawing diamonds") + @ConfigComment("where max amount in pack are 5 per each subchunk!") @ConfigEntry(path = "world.nether.blocks", needsReset = true) private List netherBlocks = new ArrayList<>(); @@ -1619,9 +1748,15 @@ public class Settings implements DataObject, WorldSettings @ConfigEntry(path = "world.end.main-block", needsReset = true) private Material endMainBlock = Material.STONE; - @ConfigComment("Rare blocks that will be randomly placed around world. 1-material, 2-rarity, 3-pack size") - @ConfigComment("F.E. DIAMOND_ORE:1:3 means that diamond has ~0.1% chance being spawned and max of 3 blocks.") - @ConfigComment("Rarity index can be over 100. It will be summed and rarity for block will be BLOCK_RARITY/RARITY_SUM * 10.") + @ConfigComment("Blocks that will occasionally replace main block by random chance.") + @ConfigComment("Blocks will replace only main-block and will try to create packs that") + @ConfigComment("are set in their strings. Chance of spawning also is required.") + @ConfigComment("For materials first string must be MATERIAL, for entity: ENTITY.") + @ConfigComment("Entities spawned via generator are not protected from despawing.") + @ConfigComment("Working only with 2 high mobs currently.") + @ConfigComment("Example:") + @ConfigComment("MATERIAL:DIAMOND:100:5 - means there is 100% chace of spawing diamonds") + @ConfigComment("where max amount in pack are 5 per each subchunk!") @ConfigEntry(path = "world.end.blocks", needsReset = true) private List endBlocks = new ArrayList<>(); diff --git a/src/main/resources/config.yml b/src/main/resources/config.yml index 562cf96..36f6868 100644 --- a/src/main/resources/config.yml +++ b/src/main/resources/config.yml @@ -2,7 +2,6 @@ # This config file is dynamic and saved when the server is shutdown. # You cannot edit it while the server is running because changes will # be lost! Use in-game settings GUI or edit when server is offline. -# world: # Friendly name for this world. Used in admin commands. Must be a single word friendly-name: CaveBlock @@ -18,7 +17,7 @@ world: # This value cannot be changed mid-game and the plugin will not start if it is different. distance-between-islands: 64 # Default protection range radius in blocks. Cannot be larger than distance. - # Admins can change protection sizes for players individually using /bsbadmin range set + # Admins can change protection sizes for players individually using /cbadmin range set # or set this permission: caveblock.island.range. protection-range: 50 # Start islands at these coordinates. This is where new islands will start in the @@ -38,9 +37,9 @@ world: # /!\ This feature is experimental and might not work as expected or might not work at all. use-own-generator: true # Sea height (don't changes this mid-game unless you delete the world) - # Minimum is 0, which means you are playing Skyblock! + # Minimum is 0, which means you are playing CaveBlock! # If sea height is less than about 10, then players will drop right through it - # if it exists. Makes for an interesting variation on skyblock. + # if it exists. Makes for an interesting variation on caveblock. sea-height: 0 # Maximum number of islands in the world. Set to -1 or 0 for unlimited. # If the number of islands is greater than this number, it will stop players from creating islands. @@ -58,29 +57,37 @@ world: # This is cave... no height... only depth. Max 256. # Should not be less then island height. world-depth: 256 + # This indicate how many times block should be tried to generate. generation-tries: 2 - # World settings. normal: + # # Make over world roof of bedrock, if false, it will be made from stone roof: true # Make over world floor of bedrock, if false, it will be made from stone floor: true # Main block of which world will be generated. main-block: STONE - # Rare blocks that will be randomly placed around world. 1-material, 2-rarity, 3-pack size - # F.E. DIAMOND_ORE:1:3 means that diamond has ~1% chance being spawned and max of 3 blocks. + # Blocks that will occasionally replace main block by random chance. + # Blocks will replace only main-block and will try to create packs that + # are set in their strings. Chance of spawning also is required. + # For materials first string must be MATERIAL, for entity: ENTITY. + # Entities spawned via generator are not protected from despawing. + # Working only with 2 high mobs currently. + # Example: + # MATERIAL:DIAMOND:100:5 - means there is 100% chace of spawing diamonds + # where max amount in pack are 5 per each subchunk! blocks: - - MATERIAL:DIAMOND_ORE:1:3 - - MATERIAL:GOLD_ORE:5:4 - - MATERIAL:IRON_ORE:5:4 - - MATERIAL:COAL_ORE:10:6 - - MATERIAL:EMERALD_ORE:1:1 - - MATERIAL:CLAY:10:6 - - MATERIAL:DIRT:10:10 - - MATERIAL:GRAVEL:20:6 - - MATERIAL:GRANITE:20:10 - - MATERIAL:ANDESITE:20:10 - - MATERIAL:DIORITE:30:8 + - MATERIAL:DIAMOND_ORE:1:3 + - MATERIAL:GOLD_ORE:5:4 + - MATERIAL:IRON_ORE:5:4 + - MATERIAL:COAL_ORE:10:6 + - MATERIAL:EMERALD_ORE:1:1 + - MATERIAL:CLAY:10:6 + - MATERIAL:DIRT:10:10 + - MATERIAL:GRAVEL:20:6 + - MATERIAL:GRANITE:20:10 + - MATERIAL:ANDESITE:20:10 + - MATERIAL:DIORITE:30:8 nether: # Generate Nether - if this is false, the nether world will not be made and access to # the nether will not occur. Other plugins may still enable portal usage. @@ -93,61 +100,60 @@ world: # Nether trees are made if a player grows a tree in the nether (gravel and glowstone) # Applies to both vanilla and islands Nether trees: true - # Make the nether roof of bedrock, if false, it will be made from netherrack/soulsand - # Change to false if lag is a problem from the generation - # Only applies to islands Nether - roof: true - # Make the nether floor of bedrock, if false, it will be made from netherrack/soulsand - # Change to false if lag is a problem from the generation - # Only applies to islands Nether - floor: true - # Main block of which world will be generated. - main-block: NETHERRACK - # Rare blocks that will be randomly placed around world. 1-material, 2-rarity, 3-pack size - # F.E. DIAMOND_ORE:1:3 means that diamond has ~1% chance being spawned and max of 3 blocks. - blocks: - - MATERIAL:QUARTZ_ORE:30:5 - - MATERIAL:SOUL_SAND:40:10 - - MATERIAL:MAGMA_BLOCK:10:3 - - MATERIAL:GLOWSTONE:20:8 - - MATERIAL:LAVA:10:1 # Nether spawn protection radius - this is the distance around the nether spawn # that will be protected from player interaction (breaking blocks, pouring lava etc.) # Minimum is 0 (not recommended), maximum is 100. Default is 25. # Only applies to vanilla nether spawn-radius: 25 - end: - # Generate The End - if this is false, the nether world will not be made and access to - # the the end will not occur. Other plugins may still enable portal usage. - # Note: Some default challenges will not be possible if there is no end. - # Note that with a standard theend all players arrive at the same portal and entering a - # portal will return them back to their islands. - generate: true - # Islands in the end. Change to false for standard vanilla end. - islands: true - # Make the nether roof of bedrock, if false, it will be made from netherrack/soulsand - # Change to false if lag is a problem from the generation - # Only applies to islands Nether + # Make over world roof of bedrock, if false, it will be made from stone roof: true - # Make the nether floor of bedrock, if false, it will be made from netherrack/soulsand - # Change to false if lag is a problem from the generation - # Only applies to islands Nether + # Make over world floor of bedrock, if false, it will be made from stone + floor: true + # Main block of which world will be generated. + main-block: NETHERRACK + # Blocks that will occasionally replace main block by random chance. + # Blocks will replace only main-block and will try to create packs that + # are set in their strings. Chance of spawning also is required. + # For materials first string must be MATERIAL, for entity: ENTITY. + # Entities spawned via generator are not protected from despawing. + # Working only with 2 high mobs currently. + # Example: + # MATERIAL:DIAMOND:100:5 - means there is 100% chace of spawing diamonds + # where max amount in pack are 5 per each subchunk! + blocks: + - MATERIAL:QUARTZ_ORE:30:5 + - MATERIAL:SOUL_SAND:40:10 + - MATERIAL:MAGMA_BLOCK:10:3 + - MATERIAL:GLOWSTONE:20:8 + - MATERIAL:LAVA:10:1 + end: + generate: true + islands: true + # /!\ This feature is experimental and might not work as expected or might not work at all. + dragon-spawn: false + # Make over world roof of bedrock, if false, it will be made from stone + roof: true + # Make over world floor of bedrock, if false, it will be made from stone floor: true # Main block of which world will be generated. main-block: END_STONE - # Rare blocks that will be randomly placed around world. 1-material, 2-rarity, 3-pack size - # F.E. DIAMOND_ORE:1:3 means that diamond has ~0.1% chance being spawned and max of 3 blocks. - # Rarity index can be over 100. It will be summed and rarity for block will be BLOCK_RARITY/RARITY_SUM * 10. + # Blocks that will occasionally replace main block by random chance. + # Blocks will replace only main-block and will try to create packs that + # are set in their strings. Chance of spawning also is required. + # For materials first string must be MATERIAL, for entity: ENTITY. + # Entities spawned via generator are not protected from despawing. + # Working only with 2 high mobs currently. + # Example: + # MATERIAL:DIAMOND:100:5 - means there is 100% chace of spawing diamonds + # where max amount in pack are 5 per each subchunk! blocks: - - ENTITY:SHULKER:1:1 - # /!\ This feature is experimental and might not work as expected or might not work at all. - dragon-spawn: false - # Mob white list - these mobs will NOT be removed when logging in or doing /island + - ENTITY:SHULKER:1:1 + # Mob white list - these mobs will NOT be removed when logging in or doing /cave remove-mobs-whitelist: - - ENDERMAN - - ZOMBIE_VILLAGER - - PIG_ZOMBIE - - WITHER + - ZOMBIE_VILLAGER + - WITHER + - PIG_ZOMBIE + - ENDERMAN # World flags. These are boolean settings for various flags for this world flags: CREEPER_DAMAGE: true @@ -183,34 +189,34 @@ world: BREEDING: 500 HURT_VILLAGERS: 500 TNT: 500 - FROST_WALKER: 500 TURTLE_EGGS: 500 + FROST_WALKER: 500 COLLECT_LAVA: 500 LEVER: 500 - RIDING: 500 HURT_MONSTERS: 0 - ARMOR_STAND: 500 + RIDING: 500 NAME_TAG: 500 + ARMOR_STAND: 500 TRADING: 0 EGGS: 500 ITEM_DROP: 0 NOTE_BLOCK: 0 NETHER_PORTAL: 500 - CROP_TRAMPLE: 500 ITEM_PICKUP: 0 - DROPPER: 500 + CROP_TRAMPLE: 500 BREWING: 500 + DROPPER: 500 COLLECT_WATER: 500 BUTTON: 500 FIRE_EXTINGUISH: 500 BEACON: 500 TRAPDOOR: 500 PRESSURE_PLATE: 0 - ITEM_FRAME: 500 PLACE_BLOCKS: 500 + ITEM_FRAME: 500 CRAFTING: 0 - ENCHANTING: 0 SHEARING: 500 + ENCHANTING: 0 SPAWN_EGGS: 500 BED: 500 MILKING: 0 @@ -219,8 +225,8 @@ world: EXPERIENCE_PICKUP: 500 HOPPER: 500 LEASH: 500 - BREAK_BLOCKS: 500 MOUNT_INVENTORY: 500 + BREAK_BLOCKS: 500 CHORUS_FRUIT: 500 CONTAINER: 500 JUKEBOX: 500 @@ -237,17 +243,17 @@ world: visible-settings: [] # Visitor banned commands - Visitors to islands cannot use these commands in this world visitor-banned-commands: - - spawner - - spawnmob + - spawner + - spawnmob island: # Default max team size - # Permission size cannot be less than the default below. + # Permission size cannot be less than the default below. max-team-size: 4 # Default maximum number of homes a player can have. Min = 1 - # Accessed via /is sethome or /is go + # Accessed via /cave sethome or /cave go max-homes: 1 reset: - # How many resets a player is allowed (override with /bsbadmin clearresets ) + # How many resets a player is allowed (override with /cbadmin clearresets ) # Value of -1 means unlimited, 0 means hardcore - no resets. # Example, 2 resets means they get 2 resets or 3 islands lifetime reset-limit: -1 @@ -308,36 +314,36 @@ protection: # Geo restrict mobs. # Mobs that exit the island space where they were spawned will be removed. geo-limit-settings: - - GHAST - - BAT - - BLAZE + - GHAST + - BAT + - BLAZE # Invincible visitors. List of damages that will not affect visitors. # Make list blank if visitors should receive all damages invincible-visitors: - - BLOCK_EXPLOSION - - CONTACT - - CUSTOM - - DROWNING - - ENTITY_ATTACK - - ENTITY_EXPLOSION - - FALL - - FALLING_BLOCK - - FIRE - - FIRE_TICK - - LAVA - - LIGHTNING - - MAGIC - - POISON - - PROJECTILE - - STARVATION - - SUFFOCATION - - THORNS - - WITHER - - DRAGON_BREATH - - FLY_INTO_WALL - - HOT_FLOOR - - CRAMMING - - VOID + - BLOCK_EXPLOSION + - CONTACT + - CUSTOM + - DROWNING + - ENTITY_ATTACK + - ENTITY_EXPLOSION + - FALL + - FALLING_BLOCK + - FIRE + - FIRE_TICK + - LAVA + - LIGHTNING + - MAGIC + - POISON + - PROJECTILE + - STARVATION + - SUFFOCATION + - THORNS + - WITHER + - DRAGON_BREATH + - FLY_INTO_WALL + - HOT_FLOOR + - CRAMMING + - VOID panel: # Whether GUIs should be closed when the player clicks outside. close-on-click-outside: true