-
Bug
-
Resolution: Works As Intended
-
None
-
24w40a
-
None
-
Confirmed
-
(Unassigned)
The operation type add_multiplied_base behaves as if it was add_multiplied_total.
How to recreate:
1. create a new world in the specified version and add yourself an attribute modifier like this:
/attribute @s minecraft:armor modifier add armor1 1 add_value
This will create a new attribute modifier and add it to you. Use the command
/attribute @s minecraft:armor get
to retrive the calculated attribute value. It should be 1.
2. add your self a second attribute modifier like this:
/attribute @s minecraft:armor modifier add armor2 1 add_multiplied_base
Use the command
/attribute @s minecraft:armor get
to retrive the calculated attribute value.
What should happen:
The base of the minecraft:armor attribute is 0.0d by default. This means that when adding a value that was multiplied by this base it should always add 0. Therefore result should be 1.
What actually happens:
The modifier uses the total value of the attribute which is 1.0d and multiplies it by 1. It then adds the value to the attribute resulting in a total value of 2.0d. Therefore the result is 2.