Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NukkitX standard generator [old branch] #1221

Closed

Conversation

DaMatrix
Copy link
Member

@DaMatrix DaMatrix commented Feb 25, 2020

Moved to #1303

This PR intends to provide a highly extensible and customizable terrain generator. The goal is to have nearly every aspect of generation be controlled by configuration files. A variety of basic block replacers and populators will be provided by default, and plugins will have the ability to register their own. In addition, configuration presets for simple overworld and nether worlds will also be provided.

Structure generation will be a huge project beyond the scope of this PR and will be implemented separately. However, some boilerplate code for structures may make its way in.

Breaking changes:

  • All code in cn.nukkit.level.generator.* and cn.nukkit.level.biome.* has completely changed or been deleted
  • NukkitRandom has been removed
  • All overloads of NukkitMath#randomRange have been removed

temp commit because i have to go and will need to access from home when i get there
customization will come later
generation actually works now, as does the demo superflat generator!

also added a void generator for empty worlds.
…needed `NukkitRandom` allocations by using `ThreadLocalRandom`
…write

# Conflicts:
#	src/main/java/cn/nukkit/Server.java
#	src/main/java/cn/nukkit/level/generator/NormalGenerator.java
#	src/main/java/cn/nukkit/level/generator/SimpleChunkManager.java
#	src/main/java/cn/nukkit/level/manager/LevelChunkManager.java
this is probably the same bug that's been causing cut off trees in nukkit and pmmp for years
…write

# Conflicts:
#	src/main/java/cn/nukkit/Server.java
#	src/main/java/cn/nukkit/level/LevelBuilder.java
#	src/main/java/cn/nukkit/level/LevelData.java
#	src/main/java/cn/nukkit/level/generator/FlatGenerator.java
#	src/main/java/cn/nukkit/level/generator/Generator.java
#	src/main/java/cn/nukkit/level/generator/GeneratorFactory.java
#	src/main/java/cn/nukkit/level/generator/NetherGenerator.java
#	src/main/java/cn/nukkit/level/generator/NormalGenerator.java
…write

# Conflicts:
#	src/main/java/cn/nukkit/level/generator/FlatGenerator.java
…write

# Conflicts:
#	src/main/java/cn/nukkit/level/chunk/Chunk.java
#	src/main/java/cn/nukkit/level/generator/PopChunkManager.java
#	src/main/java/cn/nukkit/level/generator/function/ChunkGenerateFunction.java
#	src/main/java/cn/nukkit/level/generator/function/ChunkPopulateFunction.java
…nerator

# Conflicts:
#	src/main/java/cn/nukkit/registry/GeneratorRegistry.java
…write

# Conflicts:
#	src/main/java/cn/nukkit/utils/Identifier.java
…-generator

# Conflicts:
#	src/main/java/cn/nukkit/level/generator/populator/impl/PopulatorLava.java
DaMatrix added 11 commits March 14, 2020 14:07
…-generator

# Conflicts:
#	pom.xml
#	src/main/java/cn/nukkit/block/BlockGrass.java
#	src/main/java/cn/nukkit/block/BlockMushroom.java
#	src/main/java/cn/nukkit/block/BlockMycelium.java
#	src/main/java/cn/nukkit/block/BlockSapling.java
#	src/main/java/cn/nukkit/block/BlockTNT.java
#	src/main/java/cn/nukkit/item/food/FoodChorusFruit.java
#	src/main/java/cn/nukkit/level/biome/EnumBiome.java
#	src/main/java/cn/nukkit/level/biome/impl/iceplains/IcePlainsSpikesBiome.java
#	src/main/java/cn/nukkit/level/generator/FlatGenerator.java
#	src/main/java/cn/nukkit/level/generator/Generator.java
#	src/main/java/cn/nukkit/level/generator/GeneratorFactory.java
#	src/main/java/cn/nukkit/level/generator/NetherGenerator.java
#	src/main/java/cn/nukkit/level/generator/NormalGenerator.java
#	src/main/java/cn/nukkit/level/generator/SimpleChunkManager.java
#	src/main/java/cn/nukkit/level/generator/function/ChunkGenerateFunction.java
#	src/main/java/cn/nukkit/level/generator/function/ChunkPopulateFunction.java
#	src/main/java/cn/nukkit/level/generator/object/BasicGenerator.java
#	src/main/java/cn/nukkit/level/generator/object/ObjectTallGrass.java
#	src/main/java/cn/nukkit/level/generator/object/mushroom/BigMushroom.java
#	src/main/java/cn/nukkit/level/generator/object/ore/OreType.java
#	src/main/java/cn/nukkit/level/generator/object/tree/HugeTreesGenerator.java
#	src/main/java/cn/nukkit/level/generator/object/tree/NewJungleTree.java
#	src/main/java/cn/nukkit/level/generator/object/tree/ObjectBigSpruceTree.java
#	src/main/java/cn/nukkit/level/generator/object/tree/ObjectDarkOakTree.java
#	src/main/java/cn/nukkit/level/generator/object/tree/ObjectJungleBigTree.java
#	src/main/java/cn/nukkit/level/generator/object/tree/ObjectSavannaTree.java
#	src/main/java/cn/nukkit/level/generator/object/tree/ObjectSpruceTree.java
#	src/main/java/cn/nukkit/level/generator/object/tree/ObjectSwampTree.java
#	src/main/java/cn/nukkit/level/generator/object/tree/ObjectTree.java
#	src/main/java/cn/nukkit/level/generator/object/tree/TreeGenerator.java
#	src/main/java/cn/nukkit/level/generator/populator/impl/MushroomPopulator.java
#	src/main/java/cn/nukkit/level/generator/populator/impl/PopulatorDoublePlant.java
#	src/main/java/cn/nukkit/level/generator/populator/impl/PopulatorGlowStone.java
#	src/main/java/cn/nukkit/level/generator/populator/impl/PopulatorLava.java
#	src/main/java/cn/nukkit/level/generator/populator/impl/PopulatorOre.java
#	src/main/java/cn/nukkit/level/generator/populator/impl/PopulatorSugarcane.java
#	src/main/java/cn/nukkit/level/generator/populator/impl/PopulatorTree.java
#	src/main/java/cn/nukkit/level/generator/populator/impl/tree/DarkOakTreePopulator.java
#	src/main/java/cn/nukkit/level/generator/populator/impl/tree/JungleBigTreePopulator.java
#	src/main/java/cn/nukkit/level/generator/populator/impl/tree/JungleFloorPopulator.java
#	src/main/java/cn/nukkit/level/generator/populator/impl/tree/JungleTreePopulator.java
#	src/main/java/cn/nukkit/level/generator/populator/impl/tree/SavannaTreePopulator.java
#	src/main/java/cn/nukkit/level/generator/populator/impl/tree/SpruceBigTreePopulator.java
#	src/main/java/cn/nukkit/level/generator/populator/impl/tree/SpruceMegaTreePopulator.java
#	src/main/java/cn/nukkit/level/generator/populator/impl/tree/SwampTreePopulator.java
#	src/main/java/cn/nukkit/level/manager/LevelChunkManager.java
#	src/main/java/cn/nukkit/math/BedrockRandom.java
#	src/main/java/cn/nukkit/math/BlockFace.java
protocol-lib changed levelchunkmanager stuff
@DaMatrix DaMatrix mentioned this pull request Mar 18, 2020
@SupremeMortal SupremeMortal mentioned this pull request Mar 18, 2020
10 tasks
@DaMatrix DaMatrix changed the title NukkitX standard generator NukkitX standard generator [old branch] Mar 28, 2020
@DaMatrix
Copy link
Member Author

I'm pushing directly to the NukkitX repo rather than my fork due to demand, this PR has moved to #1303.

@DaMatrix DaMatrix closed this Mar 28, 2020
@DaMatrix DaMatrix deleted the dev/nukkitx-standard-generator branch March 28, 2020 20:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants