I play on ps5 bedrock edition. I'm trying to get zombie villagers to cure but every night I have to deal with a ton of phantoms which makes other mobs not spawn. Used to be only 2 or 3 to deal with, since recent update there's so many I can't do anything else. I'm playing on easy mode, so this shouldn't be an issue. Haven't seen a zombie villager yet since update.
Related issues
is duplicated by
Attachments
Comments

If you have a copy of the world available, you might like to upload a copy of it for investigation.
On Windows 10 you can use the Export world feature.
On Android or iOS you need to use a file explorer to navigate to Device storage > games > com.mojang > minecraftWorlds
On Xbox or Switch the only way is to upload it to a Realm, and then download the world on Windows 10 or Android/iOS. (Please do not purchase a Realms subscription just to provide a world to us - but if you have a Realm already this may be a viable option if you wish to do so.)
If the world is larger than 10MB you can upload the world to OneDrive or a similar file sharing site, and then share the link.

Did this start after the 1.16 update?

Yes...I also have not seen a ruined portal since the update.

According to the Wiki, phantoms spawn almost the same way as other hostile mobs (zombies, skeletons etc.), only that they spawn at the surface, and 20-34 blocks above the spawn location. This is most common when the player is at y=75. This is currently how it works, and is different from Java Edition, so it might be working as intended OR a bug/parity issue (the Wiki just records how the game currently works).
The 1.16 update improved mob (de)spawning so that more mobs can spawn, so it is likely that this increased phantom spawning (although such reports seem to have only cropped up more recently).
Ruined portals only generate in new chunks, so if you have a world that you explored before 1.16, those old chunks will not have ruined portals.
Also sleeping at least once every 3 days will help prevent phantom spawning.

(@Skaijie: the claim on the wiki about Y-level preference is doubtful. There was also a false statement that they only spawn when the player is at Y = 1-129, which I have removed.)
The issue here is that due to the expanded spawning range in 1.16.100, new phantoms can continue to spawn in chunks that are beyond the density check range of phantoms already circling the player. When they spawn, they immediately teleport to the area above the player's head, so they can continue to accumulate there based on spawning spots being available farther away. This makes their density limit of 5 ineffective. Moverver, phantoms are only rarely subject to random despawning because they hover between 25 and 34 blocks above the player, and can only despawn when >32 blocks away.
I've done some testing with behavior packs to try to find a balance by modifying the density limit, spawn weight, or spawn range of phantoms. To test, I wandered around a 50 x 50 area in a flat world and killed any non-phantom monsters I could reach for 2 minutes, then counted the phantoms at the end. Here are some results:
| Sim4 | Sim6 | Sim10 |
---|---|---|---|
Vanilla | 4 | 8 | 11 |
Density: 3 | 3 | 8 | 13 |
Weight: 60 | 2 | 5 | 8 |
Spawn range: 24-60 | 3 | 5 | 0 |
Spawn range: 24-84 | 4 | 12 | 8 |
I also tested a few combinations of weight and spawn range adjustments but did not find any that produced a better balance.
Another possibility would be to change phantom despawn rules. Setting their minimum despawn distance to 40 prevents them from despawning randomly unless the player moves very fast. This can partially counterbalance a reduced phantom spawn range of 24-64, which in turn ensures that spawn attempts cannot be made outside of the density check area. Combining these two changes gave the following result:
| Sim4 | Sim6 | Sim10 |
---|---|---|---|
Spawn 24-64, min despawn 40 | 5 | 5 | 2 |

I've figured out a workaround: the following behavior pack balances phantom spawning across different simulation distances by doing two things:
Restrict their spawning to 24-44 blocks around the player.
Putting them in the water_animal population control group.
The problem with phantoms is that the expanded spawn radius for sim6+ in 1.16.100 made their density cap ineffective. Apart from a complete overhaul of their spawning mechanics, the fix for that problem must be to restrict the distance from they player at which they can attempt to spawn. This has an unintended consequence, however. In vanilla they share the monster population cap with other monsters, so when only the the phantom spawn range is restricted, monsters spawning beyond that range will block phantoms. In gameplay testing I've found the blockage to be severe. The solution to that complication is to put phantoms into a different population control group. Water_animal is viable because it has plenty of extra space. The phantom density cap of 5 leaves plenty of room in the water_animal cap of 36 for fish to spawn in oceans and rivers.
I had first tried putting phantoms in the cat cap, which I thought would make sense because cats scare phantoms anyway. However, the cat cap is only 4, which isn't enough to accommodate both cats and phantoms--you would get no phantoms near villages. If the cat cap were 8 or 10 and cats had a density limit less then that, then it might work, since phantoms have the density cap of 5. Then they would mildly limit each other. But that would require hard-coded changes.
I also tried taking phantoms out of any population control group, but I found that if you don't assign any population control group then neither the spawn range component nor the density component function at all.
Another option for a relatively simple permanent solution might be to put phantoms in the pillager cap, since that cap is 8 and both patrols and phantoms are limited to 5. The pillager cap could perhaps be recharacterized as a "hunter" cap or something like that.

Affects 1.17.2