mojira.dev
MC-262646

Cannot modify a tamed wolf's health.

The Bug

You cannot /summon a wolf with modified health AND an Owner UUID. You also cannot use /data to modify the wolf's health data if it is tamed (i.e. it has an Owner UUID).

 

What I expected to happen was...

When executing (the Owner UUID used here is a random number):

/summon minecraft:wolf ~ ~ ~ {Health:200,Owner:[I;-1953028026,-856931226,-1240793240,-1598231354],Attributes:[

{Name:"generic.max_health",Base:200f}]}

The wolf will be summoned with the correct owner, max health of 200, and current health of 200.

When executing:

/data merge entity @e[type=wolf,limit=1] {Attribute:[

{Name:"minecraft:generic.max_health",Base:30}]}

On a wolf that is already tamed, the max health will be changed to 30.

 

What actually happened was...

When executing:

/summon minecraft:wolf ~ ~ ~ {Health:200,Owner:[I;-1953028026,-856931226,-1240793240,-1598231354],Attributes:[

{Name:"generic.max_health",Base:200f}]}

The wolf will be summoned with the correct owner, but the health changes are not present.

When executing:

/data merge entity @e[type=wolf,limit=1] {Attribute:[

{Name:"minecraft:generic.max_health",Base:30}]}

On a wolf that is already tamed, the health changes are not present; nothing happens even though the chat/command block output will say "Modified entity data of Wolf".

 

Steps to reproduce:

  1. Play on a 1.19.4 Minecraft world with cheats enabled (I have only tested this bug on 1.19.4, it could be present in more versions).

  2. Execute the following command through chat, command block, or some other means: /summon minecraft:wolf ~ ~ ~ {Health:200,Owner:[I;-1953028026,-856931226,-1240793240,-1598231354],Attributes:[ {Name:"generic.max_health",Base:200f}
    ]}

  1. Check the wolf's data using: /data get entity @e[type=wolf,sort=nearest,limit=1]

  2. Notice the wolf's Owner data is successfully set, but not the max health or current health data.

OR

  1. Play on a 1.19.4 Minecraft world with cheats enabled.

  2. Execute the following command through chat, command block, or some other means: /summon minecraft:wolf ~ ~ ~

  3. Execute: /data merge entity @e[type=wolf,limit=1] {Attribute:[ {Name:"minecraft:generic.max_health",Base:30}
    ]}

  1. Check the wolf's data using: /data get entity @e[type=wolf,sort=nearest,limit=1]

  2. Notice the wolf's max health and current health data are still the default values.

 

Linked issues

Comments 2

Duplicate of MC-193202; modify = save, merge, load the NBT.

Thank you for your report!
We're tracking this issue in MC-193202, so this ticket is being resolved and linked as a duplicate.

If you would like to add a vote and any extra information to the main ticket it would be appreciated.

If you haven't already, you might like to make use of the search feature to see if the issue has already been mentioned.

Quick Links:
📓 Bug Tracker Guidelines – 💬 Community Support – 📧 Mojang Support
📓 Project Summary – ✍️ Feedback and Suggestions – 📖 Game Wiki

ItsMoorbinTime

(Unassigned)

Unconfirmed

(Unassigned)

Owner, OwnerUUID, Wolf, command, health, maxHealth, max_health, owner, wolf, wolves

1.19.4

Retrieved