We have a server that is years old, and once every few months we have to do maintenance on it because sometimes a random mob will die, or for one reason or another will produce an item. Then, a zombie picks up that item, causing it to become permanent. So, to combat this, we have to do a /kill on each of the hostile mob types, followed by a /kill @e[type=item]. This only gets the loaded areas, so it's still difficult.
Just because a skeleton stepped in some lava flow shouldn't be the reason a zombie now is carrying a bone in its hand and is forever wandering the server now. I'd propose a fix of tracking where an item originates, and only use items from a player, dropper, or dispenser to make a mob persistent when picking up items.
Expected behavior: Mobs should despawn when left alone and not interacted with deliberately by a player.
Current behavior: Zombies (and other mobs) can become persistent on their own by picking up random items dropped by mobs that happen to die on their own, preventing them from ever despawning in the first place.
Linked issues
is duplicated by 8
Attachments
Comments 15
Zombies, Zombie Villagers, Husks, and Drowned will no longer pick up glow ink sacs as of 1.17.1 Pre-release 1.
As a potential solution, zombies (drowned, husks, zombie villagers) may ignore the natural mob drops, as the mob may randomly die in a cave at any point. There is no reason to prevent blocks from being picked up as they aren't going to be dropped without the player's input. Since the glow ink sac is already ignored by zombies, implementing this fix shouldn't be hard or take much time. Here's the list of items which should be ignored by zombies, based on mobs that are quite common in caves:
Rotten Flesh
Bones
Arrows
Gunpowder
String
Slime Balls
Ender Pearl
Eggs, Raw Chicken, Feathers (baby zombie chicken jockey)
Ink Sac (squids may also spawn in open underwater ravines, causing their drop to be washed inside of caves, potentially being picked up by zombies)
The following factors may cause the death of a mob:
Lava/fire
Falling on top of dripstone
Getting pushed off the edge by another mob (fall damage)
Suffocation (fish, squid)
While being rare enough to not be considered a problem, the mobs are going to eventually die and get their loot dropped, zombies on hard difficulty have a high chance of being able to pick up items from the ground. It would be especially noticable on servers and inside of spawn chunks which are always loaded.
EDIT: Also new axolotls attack squids, fish, drowned. This will eventually cause zombie overpopulation to occure for sure.
Potentially the following drop ignorance should also be considered, although these are unlikely to cause issues:
Fish drops, including bone meal (fish can also be commonly washed into caves from ravines)
Witch drops, although it is quite unlikely a witch is going to die on its own due to healing and fire resistance.
This is still an issue in 1.17.1-pre1. Spider string seems to be most common because spiders repeatedly climb walls, fall, and kill themselves over time.
I had the idea of excluding all drops that can naturally occur as well, but the list is actually much longer:
arrow and bone
bamboo (panda)
wheat, seed, carrot, potato, bread, beetroot seed, beetroot (villager farming)
cactus
egg, feather, leather, raw and cooked beef, porkchop, chicken, mutton, rabbit, all the fish, all the wool
emerald, rabbit's foot, rabbit hide (fox)
ender pearl
glass bottles, glowstone, gunpowder, redstone, spider eye, sugar, stick
glow and regular ink sak
iron, poppy
rotten flesh, nautilus shell
ominous banner
(phantom membrane)
prismarine shards and crystals
string
scute, seagrass
slime
Excluding all of these items from being picked up by zombies would of course not be a good idea, it would just be a big guessing game whether a zombie just can't pick up items or whether you forgot something, every time you actually want to give them something. I didn't even list any drops here that can occur in limited amounts naturally, like flowers generating in the air and then updating or sandstone from a mob activating the desert temple TNT trap.
One possible proper fix would be to add a tag to items that says whether they were created by some natural process (mob dying from fall damage, cactus growing, etc.) and then not letting zombies become persistent when they pick up those items.
This NEEDS to be fixed. I've got 10+ command blocks on a clock that are working to kill the mobs that are holding eggs. It's really quite unacceptable.
This issue happens to me in 1.19.4. In my survival world, it has a cave fill with a bunch of zombies that hold bone, gunpowder, etc.
This is also an issue in Bedrock Edition, but over there it can break mob farms (MCPE-125111, MCPE-60552).