Minecraft – Why won’t zombie villager kid take the golden apple

minecraft-java-edition

I succesfully transformed a zombie villager kid into normal kid. However, sunce my first success, any further attempts fail.

What I do: with an armor on (or with care) I make a zombie kid follow me to a safe place, where I splash it with potion. When I (try to) give it an apple. If I succeded, color of bubbles aroud zombie changed.

But with the last 3 zombies I've found, I have that problem that clicking them with a golden apple has totally no effect – the eating animation attempts to start instead.

About baby zombies

If you didn't read wiki, here are some important facts:

  • Zombie kid can spawn anywhere in the overworld given sufficient light conditions
  • Zombie kid can also spawn from dead baby villager
  • They can be cured the same way adult zombie villagers are being cured
  • They can climb ladders, but they didn't seem to be able to climb vines

Notes:

  1. There is no (NO!) difference between zombie kid that has naturally spawned and zombie kid that has risen from dead villager kid. Read the wiki! (yeah, read it anyway)

  2. Abovementioned behavior may be a result of a bug. However, I'm still curious if someone else had the same problem.

Best Answer

The baby zombie you cured before was a baby villager zombie. Normal baby zombies can't be cured.

Here are two adorable baby zombies, one a villager and one a non-villager. I've hit them with a weakness potion and offered them both cookies golden apples. Only the baby villager zombie accepted the apple, as you can see by the dark red spirals around that one compared to the black spirals around the one on the right:

A baby villager zombie and a baby zombie. The baby villager zombie is in the process of being cured.

While I was writing this answer up, Harold (the baby villager zombie) had a complete recovery and is now ready to grow up and become a productive member of testificate society:

The cured baby villager zombie is now a normal baby villager.

Technical details

The NBT data for zombies contains two relevant flags: IsBaby and IsVillager. A baby villager zombie is exactly like a normal baby zombie except that it has IsVillager: true while the normal baby zombie has IsVillager: false.

Since the code for curing tests for IsVillager: true, the curing code is skipped if you try to cure a zombie that has IsVillager: false. This makes normal baby zombies incurable.

Where did the baby villager zombie come from?

It's commonly believed that baby villager zombies can only be created by a zombie killing a baby villager. I thought so myself, but this is apparently not true!

Digging through the decompiled game code provided by MCP, this is the line that controls what kind of zombie spawns:

par1EntityLivingData1 = new EntityZombieGroupData(this, this.worldObj.rand.nextFloat() < 0.05F, this.worldObj.rand.nextFloat() < 0.05F, (EntityZombieINNER1)null);

Notice the two calls to rand.nextFloat() < 0.05F. Those are what ultimately set IsBaby and IsVillager. The first call sets IsBaby true in 5% of zombies, while the second call sets IsVillager true in 5% of zombies. Notice that neither depends on the other.

The spawning probabilities in combination:

                   | Non-baby |    Baby
                   |   (95%)  |    (5%)
-------------------+----------+---------+
Non-villager (95%) |  90.25%  |   4.75% |
-------------------+----------+---------+
Villager     ( 5%) |   4.75%  |   0.25% |
-------------------+----------+---------+

So in summary, the chance of a zombie spawning for each type is:

Zombie type      Spawn chance (%)
-----------------------------
Normal            90.25
Baby               4.75
Villager           4.75
Baby Villager      0.25

Your baby villager zombie was likely a very rare 0.25% zombie spawn. You were very lucky to find it and catch it!