Dungeon generator minecraft

Dungeon generator minecraft DEFAULT

Dungeon Generation consists of manipulating the chunk population process in order to force the game to generate dungeons in specific locations. Generating dungeons can be interesting if you want many dungeons at the same location while having the possibilty to choose the location and the mob type.

The concept of Spawner generation[]

Spawner generation uses the fact that the game does not generate the dungeons at the same time as generating the blocks. Actually the generation is composed of two steps, first the game will generate the block, such as stone, dirt, sand, etc. making the global look of the chunk. In the second step the game will add ores, lava and water lakes, and trees for example, this step is called the 'chunk population' since it is the step which is adding life to the chunk. It will also generate all the structures of the game, the last structure in the overworld that is being generated is dungeons.

Dungeon generation does depend on the seed of the chunk and also on the blocks that are at the location at where the dungeon is trying to be placed. Having a mod or tool to predict the locations of apparition of the dungeons and building the convenient structure for the generation will force the game to generate dungeons at the population process.

Building the structure into an unpopulated chunk requires the player to be far away from the chunk, that's why a device that put blocks far away from the player is required, flying machines or pistons bridges are used for this purpose. Building the machine that pushes a certain structure into unloaded chunks at a precise locations is the most tedious part of Spawner Generation. Finnaly once the structure is placed, the game will populate the chunk when the player will get close enough from the chunk and will -if the location and the structure is correct- create a dungeon.

Chunk population and chunk seed[]

The Chunk creation[]

During the first phase of generation, when the chunk is created, the game generates the stone, the dirt, the sand, the caves, the water and the lava, (notice that lava at y level ~11 is generated during this step whereas lava lakes and water lakes are generated during population.)

The chunk population[]

During this step, Structures, lakes, dungeons, and finnaly terrain decoration(trees, grass, ores, granite...) are added to the chunk

public void populate(IChunkProvider chunkProvider, int chunkX, int chunkZ) { int posx = chunkX * 16; int posz = chunkZ * 16; BlockPos blockPos = new BlockPos(posx, 0, posz); BiomeGenBase biome = this.worldObj.getBiomeGenForCoords(blockPos.add(16, 0, 16)); this.rand.setSeed(this.worldObj.getSeed()); long j = this.rand.nextLong() / 2L * 2L + 1L; long k = this.rand.nextLong() / 2L * 2L + 1L; this.rand.setSeed((long)chunkX * j + (long)chunkZ * k ^ this.worldObj.getSeed()); if (--- && this.mapFeaturesEnabled) { this.mineshaftGenerator.gen(---); // mineshaft generation attempt } if (--- && this.mapFeaturesEnabled) { this.villageGenerator.gen(---); //village generation attempt } if (--- && this.mapFeaturesEnabled) { this.strongholdGenerator.gen(---); //strongold generation attempt } if (--- && this.mapFeaturesEnabled) { this.scatteredFeatureGenerator.gen(---); //temple generation attempt } if (-- && this.mapFeaturesEnabled) { this.oceanMonument.gen(---); //oceanmonument generation attempt } int x; int y; int z; if (biome != BiomeGenBase.desert && biome != BiomeGenBase.desertHills && ---&& this.rand.nextInt(4) == 0) { x = this.rand.nextInt(16) + 8; y = this.rand.nextInt(256); z = this.rand.nextInt(16) + 8; (new WorldGenLakes(Blocks.water)).generate(this.worldObj, this.rand, blockPos.add(x, y, z)); } if (--- && this.rand.nextInt(8) == 0) { x = this.rand.nextInt(16) + 8; y = this.rand.nextInt(this.rand.nextInt(248) + 8); z = this.rand.nextInt(16) + 8; if (y < 63 || this.rand.nextInt(10) { (new WorldGenLakes(Blocks.lava)).generate(this.worldObj, this.rand, blockPos.add(var14, var15, var16)); } } if (---) { for (int i = 0; i < 8; ++i) { x = this.rand.nextInt(16) + 8; y = this.rand.nextInt(256); z = this.rand.nextInt(16) + 8; (new WorldGenDungeons()).generate(this.worldObj, this.rand, blockPos.add(x, y, z)); //dungeon Generation. } } biome.worldDecoration(this.worldObj, this.rand, new BlockPos(posx, 0, posz)); //also do other things: add animals, snow and ice) }

The chunk seed[]

The generation uses a pseudo-random generator, called a RNG (the java random number generator). A pseudo-random generator is a generator that will output the same numbers from the same seed. the numbers will have no links between them but if you take the same seed you will get the same random numbers, that's why from the same seed you get the same world in minecraft. Everytime the random function is called it will generate a need seed from the old one and it will output a random number.

In the game each chunk has a random seed value associated with it in order to place structures, decorations, lakes randomly. The random value is calculated like this:

this.rand.setSeed(this.worldObj.getSeed()); long j = this.rand.nextLong() / 2L * 2L + 1L; long k = this.rand.nextLong() / 2L * 2L + 1L; this.rand.setSeed((long)chunkX * j + (long)chunkZ * k ^ this.worldObj.getSeed());

Everytime a structure is generated, it will call the random function in order to place blocks or generate coordinates for instance. If we take the water lake generation we can see that the this.rand.nextInt(range) functions is being called systematicly when it tries to place water lakes:

if (biome != BiomeGenBase.desert && biome != BiomeGenBase.desertHills && ---&& this.rand.nextInt(4) == 0) { x = this.rand.nextInt(16) + 8; y = this.rand.nextInt(256); z = this.rand.nextInt(16) + 8; (new WorldGenLakes(Blocks.water)).generate(this.worldObj, this.rand, blockPos.add(x, y, z)); }

If we compare it to the structure generation we can see that no random function is called:

if (--- && this.mapFeaturesEnabled) { this.mineshaftGenerator.gen(---); // mineshaft generation attempt } if (--- && this.mapFeaturesEnabled) { this.villageGenerator.gen(---); //village generation attempt } if (--- && this.mapFeaturesEnabled) { this.strongholdGenerator.gen(---); //strongold generation attempt } if (--- && this.mapFeaturesEnabled) { this.scatteredFeatureGenerator.gen(---); //temple generation attempt } if (-- && this.mapFeaturesEnabled) { this.oceanMonument.gen(---); //oceanmonument generation attempt }

Each structure (mineshaft, village, strongold, temple and ocean monument) won't modify the random value when they are not generated, however if they are generated they will modify the random seed in a way that is not really predictable by a simple 3rd party tool without using a big part of the game generation code (for example structures depends on the biomes, on caves...).

The LakeGenerator does modify the random seed, but the random calls does not depend on something else than the random seed. The random calls during the lake generation be be simplified as the following (note:the random value is not copied, that's why it will modify the original one):

public boolean generate(World worldIn, Random random) { int randomrange = random.nextInt(4) + 4; for (int i = 0; i < randomrange; ++i) { double var7 = random.nextDouble(); double var9 = random.nextDouble(); double var11 = random.nextDouble(); double var13 = random.nextDouble(); double var15 = random.nextDouble(); double var17 = random.nextDouble(); } return true; }

Dungeon generation[]

After the structure and lake generation, the dungeon generation process will occur. Since the coordinates are generated from the random chunk seed, it means that every step that happened before will have an impact on the dungeon coordinates.

In order to predictict the dungeon/spawner coordinate, a mod ,or a script that emulate the previous random calls in order to get the right seed need to be used.

for (int i = 0; i < 8; ++i) { x = this.rand.nextInt(16) + 8; y = this.rand.nextInt(256); z = this.rand.nextInt(16) + 8; (new WorldGenDungeons()).generate(this.worldObj, this.rand, blockPos.add(x, y, z)); }

By default the number of times the generator tries to build a dungeon is 8. That means that the maxium number of spawners per chunk can be bigger than 8. (Using the custom minecraft generator you can chooe the number of dungeon maximum per chunk).

Here is a screenshot of all the positions tested by the generation code in order to place some spawners. It was obtain using a modded version of minecraft and rectangles of the same color represents ungenerated dungeon located in the same chunk.

Ungenerated dungeons disualized.png

Spawner Creation[]

Block Conditon[]

The first part of the code that generates the dungeons is making sure that dungeons do not generate everywhere. When we see dungeons in caves we can see that the dungeon is never closed and also is never in the middle of the cave but rather in a area dug in the wall with an opening.

First when the dungeon generate function is called it will create the size of the dungeon from the random seed, the size in -x and x is the same, and the size in z and -z is the same, and it can be 3 or 4.

int sizeX = random.nextInt(2) + 3; int minX = -sizeX; int maxX = sizeX; int sizeZ = random.nextInt(2) + 3; int minZ = -sizeZ; int maxZ = sizeZ;

As a result the size of a dungeon can be 9x7, 7x9, 9x9 or 7x7, 49 blocks^2, 63 blocks^2 or 81 blocks^2

There are 3 conditions that needs to be fulfilled so that the dungeon can be placed:

  • The location needs to have a floor of solid block with the same size as the dungeon.
  • The location needs to have a roof at 3 blocks on top of the spawner with the same size of the dungeon.
  • The walls need to have an opening between 1 and 5 blocks. A wall is considered to be present whenever there is at least one block in the extremity of the dungeon at the same y level of the dungeon or at the upper block.
Dungeon wool.png

-Magenta wool: wool needed to count as a floor and a roof.

-Light blue wool: wool that is needed for the walls, only the 2 first layers count, and at least 1 counts as a wall.

-Pink wool: opening air blocks.

-White wool: neutral blocks: those blocks don't block the dungeon from being generated.

Dungeon generation:[]

When the position checked is correct, the game will now generate the blocks of the dungeon.It will empty the blocks in the dungeon (the blocks which aren't a roof, a floor or a wall).

Wall blocks will be converted into cobblestone blocks, the roof blocks will stay unchanged and the mossy stone will be placed randomly.

Floor generation[]

In order for the game to try to place a mossy stone or a cobblestone, it needs to have a solid block underneath, the mossy/cobble stone placement is determined by the random value of the chunk, thus it means that the random value of the chunk can be controlled by manipulating the number of blocks underneath the floor blocks. That way the correct amount of blocks can be chosen in order to get the right mod spawner (which is generated at the end), furthermore, we can manipulate the coordinates of the next dungeon in the chunk by modifying the random value using the floor blocks.

else if (worldIn.getBlockState(blockpos1).getMaterial().isSolid() && worldIn.getBlockState(blockpos1).getBlock() != Blocks.chest) { if (i4 == -1 && rand.nextInt(4) != 0){ worldIn.setBlockState(blockpos1, Blocks.mossy_cobblestone.getDefaultState(), 2); }else{ worldIn.setBlockState(blockpos1, Blocks.cobblestone.getDefaultState(), 2); }
2016-11-13 00.53.31.png
chest generation and spawner placement[]

The max number of chests per dungeon is 2, for each chest it will try to place it 3 times. for each try, a random location inside the dungeon is generated, (that also means that the random value is changed each time a coordinate is generated), and then it test it the location is correct, the chest is placed only if has only 1 adjacent solid block. Thus, chests can't be generated in the middle of the dungeon, but also in the corners since the chest would have 2 adjacent blocks.

In 1.8, chest generation modify the random value, giving more possibilities, however in 1.9 since the loottable were introduced, it doesn't anymore,that's why considering chest generation in now pointless, because it won't have any impact on the random value.

In 1.8, chest generation can be used to change the random value of the chunk even more, thus offering more possibilities, but since loot-tables were introduced in 1.9, only 1 random value is given as an argument for the chest generation. However walls block doesn't need to be connected with the floor, meaning that the game can't generate the chests, changing the random value as much as possible since the game will try to attempt to generate the chests.

Sours: https://technical-minecraft.fandom.com/wiki/Dungeon_Generation


 About This Mod

This mod brings a whole new level of dungeon crawling to the game of Minecraft. But these dungeons are nothing normal. Ancient spirits have hidden the true potential of these dungeons, and the only way to reveal this potential is to activate a dungeon heart. These dungeons bring impressive wealth to those who hunt them. But great loot comes with a great obstacle. Those who tread these ancient stones will be cursed with something beyond their imagination. 

This mod (sort of) contains a tutorial within it that teaches the player the basics of activating these dungeons, and what to do. Now, you might think that this is just another boring dungeon mod, but no! This mod adds in some custom mechanics, and loot that is impossible to get in survival mode. This loot contains impossible enchantments, a custom name, and a flawless totally perfect lore generator.

Of course, something that contains such powerful loot must be hard to get.

 Dungeon Traps

Dungeon Traps

Weapon ExamplesDungeon Loot

Dungeon loot was custom coded to allow for randomized enchantments, lores, and names. This works by setting a list full of variables, then using Random.nextInt. This probably isn't the most effective way to generate a random name/lore.

These dungeons can contain some very powerful loot. There are currently two tiers of loot, Normal Item Cases, and Mythical Item Cases. Both of these types can have enchantments beyond vanilla's possibility. Normal Items will have a cyan name, and Mythical Items will have a golden name.

All items will also have a lore, or story behind them. The lore may be a bit confusing, as it was basically a bunch of sentences randomly selected from a list, then put together. I just thought this would be a fun addition to the items and give them some more life. This lore generator is subject to change.

Most items that are given by any case will have a random amount of durability taken off of it. Mythical Items will have less durability taken off of them as they will consist of diamond and Netherite gear. Gear can consist of helmets, chestplates, leggings, boots, swords, and axes. I am planning to add bows eventually. 

Normal Item Cases are the most common item cases that are found in the dungeon. These items can be found in any chest around the dungeon. Items that are given by this case are either iron, or diamond gear.

Mythical Item Cases are very rare items, and can only be found in specific loot chests. These cases will give better items than normal Item Cases. Another special thing unique to normal Item Cases is that they can either give diamond, or even Netherite armor. Normal Loot Cases will give either iron armor and diamond armor.

And yes, I know the mythical item example does less damage than the normal item example. Ignore this.

 Loot Enchantment Graph

Possible Enchantments

 In the Dungeon

When activating a dungeon, you might notice that everything has became darker. This is because you have gained an effect called "Dungeon's Curse" or "Curse of the Dungeon". This effect will turn your brightness and render distance down. While you have this effect on, you cannot adjust these settings. I may make this togglable in the future. Once the effect has worn away, your previous settings will be restored (If something goes wrong, a message will be sent in chat).​

You may also notice a small little bar on the right of your hot bar. This bar will only show when you are in a dungeon, or have "Dungeon's Curse" applied. This is your sanity bar. Your sanity bar is sort of like sanity in the game Phasmophobia. If you are not within a light level of 10 or above, your sanity level will start dropping. Once your sanity gets to around 1-2 bars, you will start going insane. During this time, you are given a bunch of bad effects, more monsters will spawn around you, and you will basically be in a nightmare. In order to regenerate sanity, stay in a light level of 10 or above. It is important to have torches, or another light source on you at all times  in the dungeon. Sanity will regenerate faster than it will decline, so keep this in mind. 

Sanity Bar

There is another method to increase sanity, and this is to use the Potion of Stability. This potion can be brewed with a ghast tear going into Chorus Powder. This potion will increase your sanity, even when you are in the darkness. This can be helpful if you are either too poor to get enough torches (and have enough materials to make this potion), or if you just need your sanity to be increased for some time. 

Recipe for the Potion of Stability

Recipe for Potion

 Finding the Dungeons

If you want to enter a dungeon, you need to find one, of course. You will find dungeon entrances, which are decently rare, and can be found throughout the world. The dungeon entrance will look like a ruined structure with some pillars. These dungeon entrances will lead into a long spiral staircase that will go down to the dungeon heart. The dungeon heart will usually be located around y:45 to y:30.


Planned Features

  • Better Dungeon Generation
  • Multiple Levels to dungeons
  • More content (New rooms, Traps, and hallways)
  • Easier way to find dungeons (Explorer maps, compass?)
  • Server compatibility
  • More advancements

Known Issues

  • Dungeon parts will overlap each other occasionally
  • ❗ Dungeons might fail to generate correctly, and spawn the maze ending pieces
  • Mod may not work on servers 
  • Some major functions of the mod will not work on peaceful mode
  • ❗ When entering different worlds/servers while previously having Dungeon's Curse, the gamma and render distance may not revert.
  • Floor drop traps are too loud
  • "Dungeon Crawlers" will naturally spawn
  • (4/30/2021) Potion effect "Dungeon's Curse" will sometimes not be given to players in dungeon

Quick Tips

  • You can trigger bear traps by throwing an item on them
  • Floor drop traps can be triggered by right clicking on them and throwing an item on them
  • (Warning) Items will be deleted if they hit a spike trap and things like that
  • (Warning) Redstone torches will not increase sanity

All textures in this mod have been created by me, fishcute. Some of you may remember my Maze Generator mod. Now that I think of it, it didn't fit the "maze" part of it's name. This mod is a completely new version, and contains some very new mechanics. The old maze mod will no longer be updated.

Enjoy, and don't die!

Also, this is me rewriting this whole section as I accidently deleted all my recent progress.

If you have any suggestions or feedback (and bug reports), please let me know in the comments!

I am also currently very busy with a few other projects, so the update may not be complete for some time.



1.0.0 - Biggest update so far! Mod created.

Sours: https://mcreator.net/modification/73337/extensive-dungeon-generator
  1. Mobile on installment online
  2. Dell support printer
  3. Castration meaning in english
  4. 515 fitness inc
  5. Mohawk raceway programs

Please note: This project is not under active development and the last supported version is Minecraft 1.12. See the issue queue for more information.


MCDungeon will create a procedurally generated dungeon in a preexisting Minecraft map. It is not yet feature complete, but can already generate dungeons with quite a bit of variety.

Website: http://mcdungeon.bubblemod.org

Documentation: http://mcdungeon-docs.bubblemod.org


  • Automatically finds a good location on a map based on range, size, and depth parameters. Can detect player structures and try not to overwrite them. Avoids placing dungeons in the middle of the ocean.

  • Dungeons can be removed from a map later and the landscape allowed to regenerate.

  • Dungeons can be regenerated in place with a new layout, mobs, and treasure.

  • Can generate multiple dungeons in a map, or try to fill the map with as many dungeons as possible.

  • Generates room layouts based on a random weighted selection of rooms. Rooms are filled with random hallways, floors, room features, and ruins on the surface, all of which are configurable.

  • The density and placement of doors, portcullises, and torches are configurable. Option to place fewer torches as levels go down. Less light == more danger!

  • A "fill caves" mode that will fill in nearby natural caves in an attempt to concentrate random monster spawns inside the dungeon.

  • Places stairwells between levels, and a random entrance with a spiraling staircase. Some entrances have a configurable height so it can be seen from far away.

  • Places chests with loot around the dungeon in (probably) hard to reach places. An arbitrary number of loot tables can be configured to provide variety. The density of chests is configurable. Custom potions, magic items, and armor. The heads of legendary adventurers.

  • Places mob spawners throughout the dungeon. These will likely be near chests, but not always. Mob types are configurable. The density of spawners is configurable. Some 'non-standard' mobs are available. Custom mob spawners can be created with an NBT editor.

  • Optional in-game maps of dungeons.

  • Random placement of secret traps and puzzles.

  • Output floor maps to a terminal with color on ANSI systems.

  • Output entire dungeon maps to HTML.


  • More room, hall, floor, feature, and ruin types.
  • More traps!
  • Harder hard mode!
  • More stuff as Minecraft evolves!


The stand-alone versions for Windows and OS X, include a "launcher" script that will run in interactive mode. For advanced usage, run the mcdungeon executable from the command line like the python version.

List available subcommands and options:

Help on a specific subcommand:


  • Python 2.7
  • numpy
  • pyyaml
  • nbt2yaml
  • futures (Linux and OSX)


These also work for the stand-alone version. Just replace "python mcdungeon.py" with "mcdungeon"

Run in interactive mode. From here you can add, list, delete or regenerate dungeons.

Load a world named 'Dungeon', generate a 5x4x3 dungeon layout (5 rooms E/W, 4 rooms N/S, and 3 levels deep) and display the results in a terminal window. (In color on ANSI terminals only. Sorry Windows) The world files will not be modified, but are required. Basically a "dry run."

Generate five random dungeons between the sizes of 4x4x5 and 6x6x8 and save them to the world.


Several example configs are included. These can be copied and/or modifed to suit your own tastes.

  • default.cfg

    A little of everything. This one is heavily commented. If you want to know what a config option does, look here.

  • more_mobs.cfg

    This produces maps that are the same as the default, but with more types of monsters and more spawners.

  • caverns.cfg

    Mostly cavern type rooms. Very few "dungeon" looking rooms except the treasure chambers. It's a bit like exploring caves with the occasional dungeon room.

  • maze.cfg

    Basically bumps up the number of corridor type rooms and the number of loops the dungeon layout has. You'll end up with fewer rooms and lots of twisty halls to get lost in.

  • easy_mode.cfg

    Better treasure, fewer monsters and traps. Easier dungeon layout (very linear) and maps of every level.

  • hard_mode.cfg

    Less treasure in upper levels, more confusing dungeon layout (lots of loops) more monster spawners. Hidden spawners. Creepers are more common. Buffed monster spawners. No maps. It also fills in all the surrounding underground caves so that monsters spawn inside the dungeon much more frequently. No exit portals.


Thanks to the following for their code, interest, inspiration, and great ideas! (in no particular order)

BeeTLe BeTHLeHeM, codewarrior, Link1999, SoNick, Commander Keen, Yelik, NoiGren, whoiscraig, ChocolateySyrup, Sevminer, AnderZ EL, SuddenLee, Silre, NuclearDemon, bking1138, BarthVader, koredozo, janxious, compgurusteve, Meindratheal, ChosenLama, JiFish, djchrisblue, sshipway, denemanow.

Sours: https://github.com/orphu/mcdungeon
How to Use Jigsaw Blocks to make Custom Randomly Generated Structures

Dungeon Generator

Published on


Command that adds a machine with which you can create large, random dungeons, with rooms filled with random spawners and chests!

If you experience any problems with this command, one of the options below may help you. Should none of those options address your problem, you may want to report a bug using the checkbox at the bottom.

Commands often have problems when used on modded servers like Bukkit and Spigot. Sometimes they might work, but a lot of the time they do not work, partially or completely. It is recommended to use this command on the default Minecraft server.

If the command does not do anything and only gives an error message in the chat, it's very likely that you are using the command in the wrong Minecraft version. This command is only for Minecraft version 1.8.1.

I want to report a bug.

Frequently Asked Questions

Does this command work in Minecraft Bedrock?

No, this command only works in the Minecraft Java Edition.

Can I record this command for a video?

Yes. You can make videos about the command, stream it, or publish articles about it! But you need to give proper credit! For example, you can add the following to your description:

Command: Dungeon Generator by IJAMinecraft Get the command: https://ijaminecraft.com/cmd/dungeon_generator/

For more information, you should check out my Copyright License.

Can I reupload the command?

No, you are not allowed to reupload the command or modified versions of it. If you want to modify this command, you may only use it privately without sharing it publically.

How To Install

Select one of the following Minecraft versions to get a complete and easy-to-understand guide on how to install Dungeon Generator in the specific version of the Minecraft Java Edition!

  1. 1.8.1

Get the Command

By using this command, you accept the Copyright License.

Sours: https://ijaminecraft.com/cmd/dungeon_generator/

Generator minecraft dungeon

Their striptease turned into caresses. When I lapped them, I looked at their beautiful bodies, which were illuminated by the moonlight, the thought flashed through my head that nature had created. The only masterpiece in the world of a female body, it is so beautiful that it is difficult to take my eyes off it, it is not for nothing that artists from all over the world paint naked women.

Together we were one, our bodies merged in passionate hugs and kisses.

Random Dungeons in Minecraft (not using Jigsaw Blocks)

A little later, I caught up with her, pumping her ass with sperm. She lay, protruding her ass from which the sperm flowed. The back was in stripes from the whip, as well as the back. She was all wet.

Now discussing:

Years of rocking still gave their results, and many girls, shyly feeling my biceps, wondered if I had served in the special forces. In fact, I did not serve anywhere, and at the age of twenty I did not really dream of going through all the delights of military service, but in. Order not to destroy the impression, I nodded in the affirmative.

2459 2460 2461 2462 2463