The bug
Slimes, Magma Cubes, and Iron Golems fail to use the generic.attackDamage
attribute properly, meaning that their attack damage cannot be altered via commands or potions. This is the cause behind MC-5164 and MC-9600, and may also be related to MC-33285.
As a result, the following command will only work properly for melee-capable mobs which aren't affected by this bug:
summon MOB_TYPE_HERE ~ ~1 ~ {Attributes:[{Name:"generic.attackDamage",Base:10D}]}
Most melee-capable mobs, such as zombies, will deal exactly 5 hearts per hit on Normal difficulty. The mobs affected by this bug will instead deal their usual damage.
In addition, Strength and Weakness potions have no effect on these mobs.
Steps to Reproduce
Spawn a slime, magma cube, or iron golem (don't use a golem built manually from blocks; they don't become aggressive).
Allow it to attack you, and take note of the damage dealt.
Splash it with Strength II, or any desired level of Strength or Weakness.
Observe that the damage dealt is the same as before.
Technically this issue also applies to the Ender Dragon, but essentially no potion effects or attributes work on the dragon anyhow.
Affected entities
Affected entity | Note |
---|---|
slime | |
magma_cube | |
ocelot | attacking chicken |
villager_golem |
Linked issues
is cloned by 1
Comments 24
Confirmed for Slimes for
1.8.5 probably caused by the fact that their
Size
tag determine Health and AttackDamage (and it gets applied after the attributes are set by the command)
Magma cubes, post-fix, are tracked in MC-165508.
confirmed