Class CustomFlatGenerator
java.lang.Object
org.bukkit.generator.ChunkGenerator
ua.mcchickenstudio.opencreative.utils.world.generators.WorldGenerator
ua.mcchickenstudio.opencreative.utils.world.generators.AbstractFlatGenerator
ua.mcchickenstudio.opencreative.utils.world.generators.CustomFlatGenerator
- All Implemented Interfaces:
ExtensionContent
CustomFlatGenerator
This class represents a custom flat world generator, that has generation pattern to set blocks.-
Nested Class Summary
Nested classes/interfaces inherited from class org.bukkit.generator.ChunkGenerator
org.bukkit.generator.ChunkGenerator.BiomeGrid, org.bukkit.generator.ChunkGenerator.ChunkData -
Field Summary
Fields inherited from class AbstractFlatGenerator
biome, blocks, generateTreesModifier and TypeFieldDescriptionprotected org.bukkit.block.Biomeprotected boolean -
Constructor Summary
ConstructorsConstructorDescriptionCustomFlatGenerator(@NotNull String id, @NotNull org.bukkit.inventory.ItemStack displayIcon, @NotNull String generation, boolean generateTrees) -
Method Summary
Methods inherited from class AbstractFlatGenerator
afterCreation, canSpawn, generateSurface, getDefaultBiomeProvider, getDefaultPopulators, getFixedSpawnLocation, modifyWorldCreatorModifier and TypeMethodDescriptionvoidafterCreation(@NotNull org.bukkit.World world) Executes world operations, when it's created or loaded.booleancanSpawn(@NotNull org.bukkit.World world, int x, int z) voidgenerateSurface(@NotNull org.bukkit.generator.WorldInfo worldInfo, @NotNull Random random, int chunkX, int chunkZ, @NotNull org.bukkit.generator.ChunkGenerator.ChunkData chunkData) @Nullable org.bukkit.generator.BiomeProvidergetDefaultBiomeProvider(@NotNull org.bukkit.generator.WorldInfo worldInfo) @NotNull List<org.bukkit.generator.BlockPopulator> getDefaultPopulators(@NotNull org.bukkit.World world) @Nullable org.bukkit.LocationgetFixedSpawnLocation(@NotNull org.bukkit.World world, @NotNull Random random) voidmodifyWorldCreator(@NotNull org.bukkit.WorldCreator creator, @NotNull String biome) Changes world creator before creating or loading world.Methods inherited from class WorldGenerator
getDisplayIcon, getID, getLocaleName, getNameModifier and TypeMethodDescriptionorg.bukkit.inventory.ItemStackReturns an icon that will be used in world generation menu.final @NotNull StringgetID()Returns id of world generator, that will be used to find it in registry.@NotNull StringReturns localized name for displaying.@NotNull StringgetName()Returns name of world generator for displaying in registry by converting id.Methods inherited from class org.bukkit.generator.ChunkGenerator
createChunkData, generateBedrock, generateCaves, generateChunkData, generateNoise, getBaseHeight, isParallelCapable, shouldGenerateBedrock, shouldGenerateCaves, shouldGenerateCaves, shouldGenerateDecorations, shouldGenerateDecorations, shouldGenerateMobs, shouldGenerateMobs, shouldGenerateNoise, shouldGenerateNoise, shouldGenerateStructures, shouldGenerateStructures, shouldGenerateSurface, shouldGenerateSurface
-
Constructor Details
-
CustomFlatGenerator
public CustomFlatGenerator(@NotNull @NotNull String id, @NotNull @NotNull org.bukkit.inventory.ItemStack displayIcon, @NotNull @NotNull String generation, boolean generateTrees) - Parameters:
id- id of generator.displayIcon- icon to display.generation- generation pattern, that consists of amounts and material layers."bedrock" // Generates only 1 layer with bedrock "bedrock,2*sand" // Generates bedrock on Y = 0, and sand on Y = 1, 2. "bedrock,2*air,stone" // Generates bedrock on Y = 0, and stone on Y = 3. "bedrock,grass_block;ice_spikes" // Generates bedrock, grass_block with ice_spikes biome.generateTrees- generate trees or not.
-
-
Method Details
-
getExtensionId
Description copied from interface:ExtensionContentReturns lower-cased simple id of extension. Will be used to identify author of content.ID "default" is reserved for OpenCreative+ developers.
- Returns:
- id of extension.
-
getDescription
Description copied from interface:ExtensionContentReturns description of extension content. Describes purpose of new additional content.- Returns:
- description of content.
-