mojira.dev
MC-305818

Trader llamas spawned from breeding can despawn

Steps to Reproduce:

  1. Prepare two Trader Llamas.

  2. Tame two Trader Llamas.

  3. Breed the Trader Llamas using Hay Bale.

  4. Wait for the Trader Llamas to reach adulthood, then wait 2-3 in-game days.

Observed Results:
Trader Llamas that transition from juvenile to adult will despawn.

Expected Results:
Trader Llamas that transition from juvenile to adult will not despawn.

Environment

Windows 11

Linked issues

Comments 1

Bred trader llamas still use the TraderLlama despawn timer. TraderLlama sets int despawnDelay = 47999;. Breeding (makeNewLlama with BREEDING) doesn’t disable despawning. Every tick aiStep() calls this.maybeDespawn(), and because the baby is not tamed by default canDespawn() stays true and with the timer counting down eventuallydiscard() is called. The canDespawn() check returns false if the llama is tamed, leashed to something other than the wandering trader, or has a player passenger.

jn.njjp

(Unassigned)

Confirmed

Platform

Important

Mob behaviour

1.21.11

Retrieved