1.15.2, 20w18a, 1.16.2, 20w51a, 21w03a, 1.16.5, 21w08b, 21w20a
MC-135247 no longer applies for normal phantoms since 19w08a, phantoms with size greater than 1 still have the attack damage attribute reset when the world is reloaded. It does temporarily work before reload, though, and phantoms of size 0 have the attribute persist even after world reload.
- Summon a phantom
- Run the command
- Check the value of the attack damage attribute (for size 40, it defaults to 46).
- Attempt to modify the attack damage attribute:
- Observe that the change did stick temporarily and that the value is now 99:
- Reload the world, and then run the above command.
→ The value will have reset to the default of 46 (for size 40).
19w08a no longer sets the attribute when NBT is read (it only modifies the hitbox). However, it does update the attribute (and hitbox) when the size entity metadata changes. Since the size entity metadata defaults to 0, no update is generated when the size is 0, as is the case for all naturally spawned phantoms.