Some surface spawns have become cave spawns
Since 1.14.0 was released, some mob spawns that should be surface spawns are now producing cave mobs instead. Specifically, if the block with sky access is a bottom slab or non-solid block, a mob spawning in the first open space below it should be tagged as a surface mob (i.e. subject to the surface mob density cap), but as of 1.14.0 they are not being tagged and are instead subject to the cave mob density cap.
This issue can cause mob farms to spawn more slowly than they ought to. In fact, a simple mob farm that was built such that it only generated surface monsters would no longer spawn anything.
I have attached a world that demonstrates this problem.
World Description:
The world has 3 locations you will use: A Spawn Room, a Testing Room, and the Surface. Command blocks are provided to teleport you between these locations.
The world is designed so that only monsters can spawn in it, and only on the spawn floor. (Technically, bats, slimes, and wandering traders can also spawn, but they're immediately killed by repeating command blocks.)
You spawn on the surface in front of a blue square centered in a yellow ring and, farther out, a purple ring. The spawn floor is at Y=68 below the blue square; it is one chunk in size. The purple ring encloses the density cap measurement area for spawns on the spawn floor; it is 9 x 9 chunks in size. The yellow ring encloses the area you need to stay within to prevent mobs from spawning outside the density cap area.
Except for the Spawn Room and the Testing Room, which are mobproofed, the density cap area is entirely filled with stone. This ensures that only monsters can spawn during the test and they can only spawn on the spawn floor. It also ensures that there are no unknown monsters taking up part of the density cap.
The Testing Room is at Y=43, just outside the spawn floor chunk. It's like an AFK room in that when the player is within it, all blocks of the spawn floor are within spawning range The Testing Room also has a lever that controls the "mobspawning" game rule, and a repeating command block that every 10 seconds reports what mobs are present on the spawn floor.
Steps to reproduce:
1. Open the attached world Monster Spawn Lab 2.mcworld.
2. Press the button to teleport to the Spawn Room. Verify that there are no mobs on the spawn floor or in the mob holding pen. If there are, use the Kill Mobs On Spawn Floor button to get rid of them.)
3. Go to the Testing Room and flip the lever to enable mob spawning. A repeating command block will start outputing a list every 10 seconds of any mobs found on the spawn floor or in the holding pen. Wait until 8 mobs are listed; it should take less than 5 minutes. (The density cap for hostile mobs is 8, so no more will spawn if you wait longer.)
4. Disable mob spawning.
5. Go to the Spawn Room. You should see 8 mobs on the spawn floor. Use the button to teleport them to the holding pen. (Note that the pen is outside the spawn floor chunk, but still inside its density cap area.)
6. Go to the surface.
7. Place a bottom slab or any non-solid block in front of the bottommost observer. Command blocks will replicate your block over the entire chunk, so that every block of the spawn floor has your block on the surface above it. This configuration should spawn surface cap monsters.
8. Return to the Testing Room and enable mob spawning again. Wait a few minutes to see if any monsters spawn.
Expected results:
The monsters currently in the holding pen are all cave mobs, but no surface mobs have been spawned so far, so up to 8 new monsters will spawn on the spawn floor.
Actual results:
No more monsters spawn. If at this point you kill the monsters in the holding pen (there's a button for that purpose), the cave density cap will be opened again and up to 8 new monsters will spawn. The fact that they are cave spawns can be verified by checking the Surface property of the entity for each mob.
Created Issue:
Some surface spawns have become cave spawns
Since 1.14.0 was released, some mob spawns that should be surface spawns are now producing cave mobs instead. Specifically, if the block with sky access is a bottom slab or non-solid block, a mob spawning in the first open space below it should be tagged as a surface mob (i.e. subject to the surface mob density cap), but as of 1.14.0 they are not being tagged and are instead subject to the cave mob density cap.
This issue can cause mob farms to spawn more slowly than they ought to. In fact, a simple mob farm that was built such that it only generated surface monsters would no longer spawn anything.
I have attached a world that demonstrates this problem.
World Description:
The world has 3 locations you will use: A Spawn Room, a Testing Room, and the Surface. Command blocks are provided to teleport you between these locations.
The world is designed so that only monsters can spawn in it, and only on the spawn floor. (Technically, bats, slimes, and wandering traders can also spawn, but they're immediately killed by repeating command blocks.)
You spawn on the surface in front of a blue square centered in a yellow ring and, farther out, a purple ring. The spawn floor is at Y=68 below the blue square; it is one chunk in size. The purple ring encloses the density cap measurement area for spawns on the spawn floor; it is 9 x 9 chunks in size. The yellow ring encloses the area you need to stay within to prevent mobs from spawning outside the density cap area.
Except for the Spawn Room and the Testing Room, which are mobproofed, the density cap area is entirely filled with stone. This ensures that only monsters can spawn during the test and they can only spawn on the spawn floor. It also ensures that there are no unknown monsters taking up part of the density cap.
The Testing Room is at Y=43, just outside the spawn floor chunk. It's like an AFK room in that when the player is within it, all blocks of the spawn floor are within spawning range The Testing Room also has a lever that controls the "mobspawning" game rule, and a repeating command block that every 10 seconds reports what mobs are present on the spawn floor.
Steps to reproduce:
1. Open the attached world Monster Spawn Lab 2.mcworld.
2. Press the button to teleport to the Spawn Room. Verify that there are no mobs on the spawn floor or in the mob holding pen. If there are, use the Kill Mobs On Spawn Floor button to get rid of them.)
3. Go to the Testing Room and flip the lever to enable mob spawning. A repeating command block will start outputing a list every 10 seconds of any mobs found on the spawn floor or in the holding pen. Wait until 8 mobs are listed; it should take less than 5 minutes. (The density cap for hostile mobs is 8, so no more will spawn if you wait longer.)
4. Disable mob spawning.
5. Go to the Spawn Room. You should see 8 mobs on the spawn floor. Use the button to teleport them to the holding pen. (Note that the pen is outside the spawn floor chunk, but still inside its density cap area.)
6. Go to the surface.
7. Place a bottom slab or any non-solid block in front of the bottommost observer. Command blocks will replicate your block over the entire chunk, so that every block of the spawn floor has your block on the surface above it. This configuration should spawn surface cap monsters.
8. Return to the Testing Room and enable mob spawning again. Wait a few minutes to see if any monsters spawn.Expected results:
The monsters currently in the holding pen are all cave mobs, but no surface mobs have been spawned so far, so up to 8 new monsters will spawn on the spawn floor.Actual results:
No more monsters spawn. If at this point you kill the monsters in the holding pen (there's a button for that purpose), the cave density cap will be opened again and up to 8 new monsters will spawn. The fact that they are cave spawns can be verified by checking the Surface property of the entity for each mob.
relates to
relates to
relates to
relates to
Developers: A code analyzer on the TechRock Discord discovered what they think is the cause of this problem, using reverse engineering. They posted their explanation in the comment above. It was then realized that the same bug would likely cause surface spawns to be converted to cave spawns, so I verified that it did and created MCPE-58670 to report it. If the analysis is correct, the fix should be checked to ensure that it fixes both bugs.
I did some testing and have found that in 1.14 slabs, stairs, leaves, and farmland on top of solid blocks no longer trigger surface spawns underneath. However, carpet still does!
Consequently:
- If you have a monster farm that was designed to take advantage of surface spawns in a dark, enclosed area during the day, you will need to replace the slabs or or whatever on the top with carpet.
- Monsters now spawn on top of stairs, leaves, etc. They’ve been all over the roofs of my village. Not sure if this applies to naturally generated tree leaves, but it definitely applies to placed leaves. Lower slabs and carpet are the only spawn-proof blocks as far as I can tell.
In my opinion, they’ve swung the pendulum too far in the other direction. At least we still have carpet— maybe don’t tell the devs they overlooked it!
Edit: Just realized you are now tracking this at MCPE-58670 and MCPE-54241.
Due to MCPE-58670 (= resolution to MCPE-41273?) there should be no problem in 1.14 with pillager patrols and raids spawning inside enclosed farms like the one shown in the picture. Anyone still have a problem?
However, now patrols can spawn in new places because of MCPE-54241.
I am still in favor of some kind of restriction on patrol spawning. I tried imprisoning a captain like Eyeth suggested, but it despawned!
@Christopher how interesting, it looks like that website interpolated the Java last build statement into their announcement. The official changelog does not include it: https://feedback.minecraft.net/hc/en-us/articles/360038848252
@Travis Pluff MCPE-59682 affected most all non-solid blocks, not just slabs. It applied just as much to leaf and glass roofs. And it prevented not only mob farms from working, but also things like animal spawns under trees. On the flip side, the carpet workaround for MCPE-59682 should still work, at least in local worlds—see MCPE-58670.
The 1.14.1 behavior described in this bug report, as well as the 1.14.0 behavior described in MCPE-54241 and MCPE-58670, were rolled back in 1.14.20. As a result, 1.14.20 and 1.14.30 should have the same spawning algorithm as 1.13. (Please note though that I can speak only on the basis of my own testing and the comments of other users, especially the comments made on MCPE-41273 since 1.14.20 was released.) If you think there is something else amiss please do provide whatever information/evidence you have.
Developers: A code analyzer on the TechRock Discord discovered what they think is the cause of this problem, using reverse engineering. They were actually researching
MCPE-54241and posted their explanation in a comment there. It was then realized that the same bug would likely cause this problem, so I verified that it did and created this ticket to report it. If the analysis is correct, the fix should be checked to ensure that it fixes both bugs.Related to this, mobs can actually spawn on a bottom half slab and transparent blocks such as glass, leaves, chests, etc.
Thank you for mentioning that. I had meant to link that issue but entered the wrong ticket number in the "relates to" link. Corrected now.
I have been testing different spawn surfaces in a single-player superflat world with spawn platforms at y=40 & 43 and lava covering the ground below across the entire simulation distance. I have found:
That said, I am confused by this bug report. Is this "bug" not just the (intended?) resolution to
MCPE-41273? Is there some middle ground that you think ought be achieved between the two?For what it's worth, this "bug" also seems to resolve MCPE-45183 and
MCPE-58285(the latter at least as it pertains to enclosed villager-base farms like the one shown in the picture attached to that report).MCPE-41273was about surface spawns happening anywhere under leaves, slabs, and stairs, no matter how deep the space was where the spawn happens. I think everybody would agree that it doesn't make sense to call a mob spawning at Y=6 a "surface" mob (unless the whole chunk has been dug out and the surface really is that far down). This ticket is about the opposite site of the coin: flagging spawns as cave spawns when they're actually occurring on the surface (in the sense of "surface" that the game uses).You have to take a larger view of the issues, not just look at rules based on block types.
MCPE-41273was to get these "deep surface" spawns eliminated, but not to change how spawning works near the actual surface. I tried to suggest a depth limit in that ticket, though I don't know enough to predict what effect that would have, so I really left it up to the game designers to decide how the exception logic might need to be changed.This ticket is about those near-surface spawns, the ones that are "surface" only because of the exceptions. As explained above, it's important that leaves, slabs, and stairs are not considered surfaces for spawning, so that the spawn locations will get pushed downward to the actual ground under a tree or floor in a building. That does not conflict with leaving deep spawns as cave spawns. I'm looking for that middle ground you speculated about.
I do expect the fix for this bug to have consequences for other tickets, possibly even to resolve them. Quite a lot of the spawning logic seems to be generic, used for all mobs and situations, so interactions are to be expected. However, without detailed documentation about how spawning works and with no access to the code, we can't predict how a particular patch will manifest in those interactions. It's an extremely complex system, and we have to leave it up to the developers whether to try to fix just the specific bug or to ask the designers to come up with a more generic solution that solves multiple problems.
This issue was fixed in 1.14.1 with the fix for
MCPE-54241.