mojira.dev
MC-137906

物品属性不能叠加 Attributes don't stack

当持有/装备多个带有属性的物品时,属性不相互冲突的前提下,属性会优先选择最后装备的物品的属性,而无法叠加所有物品的属性。
When armor up equipments that have attribute nbts (do not conflict),only the last armored up works instead of adding all attributes up.
我只在玩家本身上做了这个实验,不清楚是否别的实体也无法叠加。
I only test this on players but not all mobs so it leaves unknown whether it works properly on other mobs.

give @p diamond_chestplate{Unbreakable:1,AttributeModifiers:[
{Slot:"chest",AttributeName:"generic.maxHealth",Name:"generic.maxHealth",Amount:12,Operation:0,UUIDLeast:1,UUIDMost:1}],HideFlags:63} 1
give @p diamond_helmet{Unbreakable:1,AttributeModifiers:[{Slot:"head",AttributeName:"generic.maxHealth",Name:"generic.maxHealth",Amount:8,Operation:0,UUIDLeast:1,UUIDMost:1}],HideFlags:63} 1

Comments 3

It is caused by the having the same pair of 'UUIDLeast' and 'UUIDMost' on both items. You need to use a different number in at least one of the values. For example, the first item can have UUIDLeast:1,UUIDMost:1, the second item can have UUIDLeast:1,UUIDMost:2.

...errBut this did no conflicts in 1.13.x?

I have had this issue myself in earlier versions. The game expects the UUID (Universally Unique IDentifier) to be unique, so it may cause strange intermittent issues when it is not actually unique. Even if it has worked in the past, it is not supposed to work.

Bill Wedge

(Unassigned)

Unconfirmed

Minecraft 18w43b

Retrieved