Uploaded image for project: 'Minecraft: Java Edition'
  1. Minecraft: Java Edition
  2. MC-252157

'CustomName' NBT tag still prevents wardens from digging down

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • 1.19 Pre-release 5
    • 1.19 Pre-release 2, 1.19 Pre-release 3, 1.19 Pre-release 4
    • None
    • Confirmed
    • (Unassigned)

      Warden AI has changed in 1.19 pre-release 2 so that they won't dig down when they have the PersistenceRequired flag to be consistent with other mobs. However this behavior is still controlled by the CustomName flag even if the warden has PersistenceRequired:0b set, which seems like an oversight from the fix of MC-251500.

      This causes issues like wardens with custom names (summoned from commands) not behaving like naturally spawned ones even when they don't have PersistenceRequired (they'll never dig down).

      Fixing this won't change any survival behavior as naming wardens with name tags already grants them PersistenceRequired like all other hostile mobs, making the CustomName check redundant.

      How to reproduce

      1. Execute the following command:
        /summon warden ~ ~ ~ {CustomName:'{"text":"test"}',PersistenceRequired:0b,Brain:{memories:{"dig_cooldown":{value:{},ttl:1200L}}}}
        
      1. Wait for a minute.
      2. The warden won't dig down.

            grum [Mojang] Grum (Erik Broes)
            Chavamix700 syarumi
            Votes:
            3 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:
              CHK: