When the world border is smaller than 30 blocks mobs do not spawn naturally. This number may vary a little depending on decimal fraction of worldborder center coordinates. This issue does not seem to appear in 1.20.6.
Steps to reproduce:
Place an always active repeating command block with the following command:
/execute as @e run effect give @s glowing infinite
Run the following commands in order:
/worldborder center ~ ~ /worldborder set 28 /tick sprint 12d
Notice that no hostile mobs are spawning underground ❌
Increase the world border size to 32:
/worldborder set 32
Hostile mobs do spawn ✔
Attachments
Comments 2
Can confirm
Steps to reproduce:
Place an always active repeating command block with thefollowing command:
/execute as @e run effect give @s glowing infinite
Run the following commands in an order:
/worldborder center ~ ~ /worldborder set 28 /tick sprint 12d
Notice that no hostile mobs are spawning underground
Increase the world border size to 32:
/worldborder set 32
Hostile mobs do spawn
Relates to MC-277053
Update: Can confirm.