Hostile mobs can spawn on blocks occupied by a door or trapdoor when the light level is 7 or lower.
This is a bug because doors are redstone components and mobs should not spawn on redstone components.
Steps to Reproduce:
Summon a large platform of both doors and trapdoors.
/fill ~1 ~ ~1 ~30 ~ ~30 minecraft:polished_andesite
/fill ~1 ~1 ~1 ~30 ~1 ~15 minecraft:oak_door[half=lower,open=true]
/fill ~1 ~2 ~1 ~30 ~2 ~15 minecraft:oak_door[half=upper,open=true]
/fill ~1 ~1 ~16 ~30 ~1 ~30 minecraft:oak_trapdoor[half=bottom,open=true]
Ensure that the "doMobSpawning" gamerule is set to "true".
Set the time to "midnight" and wait around ten seconds to allow hostile mobs to spawn.
If no hostile mobs spawned within the doors or trapdoors after this time, kill all non-player entities by using the following command to repeat the spawning process of hostile mobs once again.
/kill @e[type=!minecraft:player]
Take note as to whether or not mobs can spawn within doors and trapdoors.
Attachments
Comments 9
Can confirm in 1.19.2. Here are some steps on how to go about easily reproducing this issue.
Steps to Reproduce:
Summon a large platform of both doors and trapdoors.
/fill ~1 ~ ~1 ~30 ~ ~30 minecraft:polished_andesite
/fill ~1 ~1 ~1 ~30 ~1 ~15 minecraft:oak_door[half=lower,open=true]
/fill ~1 ~2 ~1 ~30 ~2 ~15 minecraft:oak_door[half=upper,open=true]
/fill ~1 ~1 ~16 ~30 ~1 ~30 minecraft:oak_trapdoor[half=bottom,open=true]
Ensure that the "doMobSpawning" gamerule is set to "true".
Set the time to "midnight" and wait around ten seconds to allow hostile mobs to spawn.
If no hostile mobs spawned within the doors or trapdoors after this time, kill all non-player entities by using the following command to repeat the spawning process of hostile mobs once again.
/kill @e[type=!minecraft:player]
Take note as to whether or not mobs can spawn within doors and trapdoors.
Hey, the reason why I believe it is a bug is because mobs cannot spawn on blocks that have redstone components such as buttons, levers, etc occupying the same block. And doors/trapdoors are in the redstone category of the creative inventory, so logically it should apply for them as well.