The bug
When a villager that has been traded with is zombified, it will not be able to despawn (see MC-159300). However, it still counts towards the mob cap.
To reproduce
Summon a villager and give it a workstation
Trade with the villager
Open F3 screen, and observe the mob cap line (starting with "SC") from now on
Summon a zombie to zombify the villager
The "M" value ("monsters") increases by 1 when you spawn the zombie, indicating that the zombie counts towards the mob cap
When the villager is zombified, the "M" value increases again
→ ❌ This means that the mob cap increased again/tp ~ ~200 ~
Observe that the "M" value now decreased by one since the zombie despawned
/tp ~ ~-200 ~
→ ❌ The zombie despawned, while the zombie villager did not, but the zombie villager still counts towards the mob cap
Credit
Found by @unknown in this video: https://youtu.be/uJVkdTpdI2o?t=559
Attachments
Comments 9
At this point i would prefer this to be WAI, as it is a reasonable and interesting way for hostile mob switches.
It survived the snapshots, rc and 1.16.x versions, it could as well stay now.
Tt seems to be half fixed in 20w45a. Zombie villagers that player traded with and got killed by Zombie will count into mobcap ONLY if they aren't in boats/minecarts, is means that you can't keep them in boats/minecrts in order to make mobswitch.
[media][media]I consider this WAI, as it was part of the changelog of the first 1.16 snapshot and a useful but not overpowered mechanic.
Btw Ray didnt find it (or at least not in that video) as ilmangos video about mobswitches (which talks about the zombie villager thing) came out in February and the video you linked came out in April