What are Modular Dungeons?
Modular dungeons are a dungeon system introduced in BetterStructures 2.0.0 and later. Instead of spawning as one fixed schematic, modular dungeons are dynamically assembled from smaller, handcrafted modules. This approach allows for large, multi-floor dungeons that feel unique in every world while still fitting seamlessly into vanilla Minecraft.
How are modular dungeons generated
-
Modules Each module is typically built at a configurable size (default 16x16x16 blocks, though some content packs use 32x16x32 or other dimensions). Modules are designed with standardized connection points using a border tag system so they can attach to other modules without gaps or overlaps. The dimensions for a dungeon are set using the
moduleSizeXZandmoduleSizeYconfiguration options in the module generator config. Modules can contain corridors, rooms, staircases, or special encounter spaces. -
Generation process When a modular dungeon generates in a new chunk, BetterStructures uses a Wave Function Collapse (WFC) algorithm to procedurally assemble modules from the available pool. The system randomly selects compatible modules based on border tag matching and "stitches" them together into a complete dungeon. Generation time varies based on server performance, dungeon size (radius), vertical range, module count, and constraint complexity. The system uses workload distribution to prevent server lag during generation.
-
Dungeon size Dungeons can be configured to generate at various sizes using the radius parameter. Larger radius values create significantly bigger dungeons that can span hundreds of blocks. Most dungeons include multiple floors, linked through stair modules or vertical shafts. Vertical connections between floors are achieved through modules with
upIsPassableanddownIsPassableset to true.
Variety and pack integration
-
Free Pack The Dungeoneering Modules Free Pack includes 15 modules. This functions as a fully playable dungeon on its own.
-
Premium Pack The Dungeoneering Modules Premium Pack adds 38 additional modules. When combined with the Free Pack, both sets intertwine into a single dungeon system with a much larger module pool. This reduces repetition and increases variety in the generated layouts.
-
Props integration If you also install the BetterStructures Prop Pack (via FreeMinecraftModels), modular dungeons will display custom model props throughout the builds, as shown in our showcase screenshots. Without the prop pack, the dungeons will still function normally, but without the decorative models.
EliteMobs Integration
While most of the dungeon relies only on BetterStructures and vanilla MineCraft mobs, some dungeons feature boss encounters:
- If EliteMobs and FreeMinecraftModels are both installed → full custom boss fight with model.
- If only FreeMinecraftModels is installed → boss model appears as a decorative prop.
- If neither is installed → boss room will simply be empty.
The system uses a sign-based spawn system with special tags like [spawn] and [pool: poolname] to place bosses in designated areas. Boss levels scale based on distance from the dungeon center, providing appropriate challenge throughout the structure.
If EliteMobs is not installed but a content pack requires it, administrators will receive a warning message.
This design keeps modular dungeons compatible with vanilla-style setups, while still offering deeper integration for users with additional plugins.
MythicMobs Integration
BetterStructures also supports MythicMobs integration for custom mob encounters within modular dungeons.
When MythicMobs is installed, structure packs can spawn custom MythicMobs as part of dungeon generation. This allows for more sophisticated mob encounters and boss fights beyond what vanilla Minecraft or EliteMobs provide.
If MythicMobs is not installed, the plugin will notify administrators with appropriate permissions and provide a download link.
FMM Integration
Modular dungeons can also take advantage of FreeMinecraftModels (FMM) props during creation.
- If FMM is installed, any props placed by the module creator or builder will appear in the generated dungeon.
- Props are purely decorative and do not affect gameplay, but they enhance the visual fidelity and immersion of the environment.
- If FMM is not installed, the dungeon will still generate normally, but these custom props will not be displayed.
This ensures that creators can design dungeons with extra detail while maintaining compatibility for players who do not have FMM installed.
Module Dimensions
Important: Module size is configurable, not fixed.
Each module generator defines its standard module size using:
moduleSizeXZ: Width and depth in blocks (default: 16)moduleSizeY: Height in blocks (default: 16)
Default size: 16×16×16 blocks Common alternative: 32×16×32 blocks (used in some content packs)
For module creators:
- Check your generator config for
moduleSizeXZandmoduleSizeYvalues - Build ALL modules for that generator to match these exact dimensions
- Mismatched sizes will cause connection failures
Setting custom dimensions: In your module generator config file:
moduleSizeXZ: 32 # Width and depth
moduleSizeY: 16 # Height
Note: All modules in a generator must use the same dimensions. You cannot mix 16×16×16 and 32×16×32 modules in the same dungeon system.
Module Generator Config Fields
Beyond moduleSizeXZ and moduleSizeY, the module generator config supports the following fields:
| Field | Default | Description |
|---|---|---|
radius | 1 | Dungeon radius in chunks |
edges | false | Whether edge modules are generated |
startModule | — | List of starting module(s) for generation |
minChunkY | 0 | Minimum vertical chunk bound |
maxChunkY | 0 | Maximum vertical chunk bound |
moduleSizeXZ | 16 | Width and depth of modules in blocks |
moduleSizeY | 16 | Height of modules in blocks |
debug | false | Enables debug mode for generation troubleshooting |
useGradientLevels | false | Enables gradient-based level scaling for spawned entities |
spawnPoolSuffix | — | Suffix appended to spawn pool names for this generator |
isWorldGeneration | false | Whether this generator is used for world generation |
treasureFile | — | Treasure configuration file |
validWorlds | — | List of valid world names where the dungeon can generate |
validWorldEnvironments | — | List of valid world environments |
centerModuleAltitude | 0 | Altitude for the center module |
Per-Module Config Fields
Each individual module can define the following configuration fields:
| Field | Default | Description |
|---|---|---|
isEnabled | true | Whether this module is enabled |
weight | 100 | Selection weight for this module during generation |
repetitionPenalty | 0 | Penalty applied when this module is selected multiple times |
noRepeat | false | Prevents this module from repeating |
northIsPassable | true | Whether the north face allows connections |
southIsPassable | true | Whether the south face allows connections |
eastIsPassable | true | Whether the east face allows connections |
westIsPassable | true | Whether the west face allows connections |
upIsPassable | true | Whether the top face allows connections |
downIsPassable | true | Whether the bottom face allows connections |
enforceVerticalRotation | false | Enforces vertical rotation constraints |
enforceHorizontalRotation | false | Enforces horizontal rotation constraints |
minY | -4 | Minimum Y level for this module |
maxY | 20 | Maximum Y level for this module |
biome | default | Biome requirement for this module |
minecraftBiome | null | Minecraft biome requirement for this module |
treasureFile | — | Treasure configuration file for this module |
borders | — | Border tag map defining connection compatibility |
cloneConfig | — | Clone settings from another module config file |
compoundModule | — | Links this module as part of a compound (multi-part) module |
isAutomaticallyPlaced | true | Whether the module is automatically placed during generation |