Dangerous Structures
Dangerous Structures: Compatibility
MC 1.20.1Forge~4 min read
On this page (6)
Dangerous Structures is built to coexist with large Forge 1.20.1 modpacks. When another mod overlaps with part of its behavior, the design policy (CompatReport) is to detect, log, and stand down rather than escalate event priorities or undo another mod’s cancellation.
Server-side-only multiplayer
mods.tomlsetsdisplayTest = "IGNORE_SERVER_VERSION".- No blocks, items, entities, recipes, or network packets are registered.
- All chat messages, command feedback, and elite mob names use
Component.literal(...)plain text instead of translation keys, so clients without the JAR never see raw translation keys. - Installing on clients is completely optional (only needed if you play singleplayer/LAN hosts).
Automatic mod detection (/ds compat)
On ServerStartedEvent, CompatReport.detect() checks ModList for six specific mod IDs, logs findings to the server log, and exposes them via /ds compat:
Detected mod (modId) |
Interaction & recommended action |
|---|---|
Apotheosis ( apotheosis) |
Apotheosis spawns its own named, glowing, geared bosses/invaders. By default ( eliteSpawns.compatMode = AUTO), Dangerous Structures automatically disables its own elite system so mobs don’t get double-elited. Set compatMode = FORCE_ON if you want both. |
Adaptive Performance Tweaks (Spawn) ( adaptive_performance_tweaks_spawn) |
APTweaks caps and throttles entity spawns globally and cancels FinalizeSpawn events when limits are reached. MobFactory respects the veto and counts it under Blocked by another mod in /ds spawns. Add affected structure mobs to APTweaks’ allowList if needed. |
Anti Mob Farm ( anti_mob_farm) |
Anti Mob Farm reduces loot and XP after repeated kills in the same chunk — which collides with players fighting periodic reinforcements inside one dungeon. Informational warning only. |
Respawning Structures ( respawningstructures) |
Respawning Structures also enhances mobs inside structures and regenerates cleared buildings. Consider lowering Dangerous Structures’ armor settings to avoid excessive stacking, and run /ds forget [radius] after a structure regenerates so initial population runs again. |
Mob Sunscreen ( mobsunscreen) |
Mob Sunscreen already manages daylight burning for mobs, making periodicSpawning.fireMode redundant. Consider setting fireMode = NONE. |
Structure Essentials ( structureessentials) |
Structure Essentials modifies structure placement and lookup; Dangerous Structures reads the resulting registry/world state automatically, so no action is required. |
Attribute & XP mod composition
- Health & affix attributes (
EliteAffix,MobEnhancer): Applied as permanentAttributeModifiers with stable UUIDs (MULTIPLY_BASEorADDITION) instead of rewriting base attribute values. This stacks cleanly with ApothicAttributes, Scaling Health, Champions, and similar mods. - Outgoing damage (
MobBehaviourHandler): Elite damage scaling multipliesLivingHurtEventdamage rather than modifyingATTACK_DAMAGE, so ranged and explosive mobs benefit accurately. - Bonus XP (
LivingExperienceDropEvent): Adds bonus XP to the mob’s dropped experience pool rather than callinggiveExperiencePoints, so XP-merging mods such as Clumps and enchanting triggers handle orbs normally. - Elite loot path: The shipped loot table lives at
data/dangerousstructures/loot_tables/gameplay/elite_bonus.json(rolled withLootContextParamSets.CHEST) rather than underloot_tables/entities/, avoiding validation errors from mods such as Botania that inject entity-parameter pools into everyentities/loot table.
Boss Guard
To stop random rooms from spawning modded world bosses registered under MobCategory.MONSTER, BossGuard enforces three layers plus an enhancement exclusion tag:
- Must be selectable:
type.getCategory() == MobCategory.MONSTERandtype.canSummon() == true. - Datapack exclusion (
#dangerousstructures:never_spawn): Ships pre-populated with Vanilla bosses (ender_dragon,wither,warden,elder_guardian), L_Ender’s Cataclysm (ender_guardian,ignis,netherite_monstrosity,old_netherite_monstrosity,the_harbinger,the_leviathan,the_baby_leviathan,ancient_remnant,ancient_ancient_remnant,modern_remnant,maledictus,scylla,wither_howitzer), Bosses of Mass Destruction (gauntlet,lich,obsidilith,void_blossom), Mowzie’s Mobs (ferrous_wroughtnaut,frostmaw,umvuthi,sculptor,naga), Ice and Fire (fire_dragon,ice_dragon,lightning_dragon,hydra,dread_lich,dread_queen,myrmex_queen,cyclops,sea_serpent,gorgon,death_worm), Block Factory’s Bosses (infernal_dragon,kraken,pirate_captain), and Alex’s Mobs (void_worm,warped_mosco). - Health threshold (
mobs.maxSpawnableMaxHealth, default100.0): After constructing an entity, if baseMAX_HEALTH > limit(whenlimit > 0), the spawn is discarded, counted inRejected as too strong(/ds spawns), and thatEntityTypeis memoized inBossGuard.REJECTEDfor the session (cleared on/ds reloador datapack reload). - No-enhance tag (
#dangerousstructures:never_enhance): Mobs in this tag may still spawn, but are skipped by armor, fire behavior, and elite enhancements (BossGuard.mayEnhance). Ships withslime,magma_cube,ghast,blaze,phantom,shulker,vex,silverfish,endermite,guardian,elder_guardian,ender_dragon,wither, andwarden.
Modded structures & dimensions
- Modded structures: Included automatically when
autoDetectStructures = true(minus protected villages).MobSelectorcallsstructure.getModifiedStructureSettings().spawnOverrides()so Forge structure modifiers and datapack overrides work seamlessly. - Modded dimensions: Active automatically under the default
dimensionMode = DENYLIST. Add any peaceful or utility dimensions you want untouched toother.deniedDimensions.
Java API for mod developers
com.otectus.dangerousstructures.api.DangerousStructuresAPI is stable across 1.2.x:
import com.otectus.dangerousstructures.api.DangerousStructuresAPI;
import net.minecraft.core.BlockPos;
import net.minecraft.resources.ResourceLocation;
import net.minecraft.server.level.ServerLevel;
// Mark a structure dangerous when autoDetectStructures = false (overridden by blacklists/village rules)
DangerousStructuresAPI.registerDangerousStructure(new ResourceLocation("mymod", "my_dungeon"));
// Remove a previous API registration
DangerousStructuresAPI.unregisterDangerousStructure(new ResourceLocation("mymod", "my_dungeon"));
// Check whether a position is inside a dangerous structure (returns false in protected villages)
boolean dangerous = DangerousStructuresAPI.isPositionDangerous(serverLevel, blockPos);
// Read-only view of API-registered structure IDs
Set<ResourceLocation> registered = DangerousStructuresAPI.getApiRegisteredStructures();