mojira.dev
MC-269226

The minecraft:generic.attack_knockback attribute remains unutilized for certain mobs capable of executing melee attacks.

Numerous mobs possess the capability for melee attacks, yet the

minecraft:generic.attack_knockback

attribute remains unutilized. This report diverges from MC-180199, as it describes a distinct issue. MC-180199 describes a scenario where entities lack this attribute entirely, resulting in error messages when attempting to modify it. In contrast, this bug report concerns entities that have the attribute but remain unused. Below is a list of such mobs where this attribute does not function:

  • Axolotl

  • Bee

  • Dolphin

  • Goat (MC-229507)

  • Iron Golem (MC-199161)

  • Magma cube

  • Polar bear

  • Pufferfish

  • Rabbit (Killer bunny)

  • Slime

  • Wolf

By default, the attribute for all these entities is set to 0.

The attribute works as expected for the following mobs:

 

Mob

Default value

Bogged

0

Cave spider

0

Drowned

0

Enderman

0

Endermite

0

Fox

0

Frog (see MC-269231)

0

Hoglin

1

Husk

0

Panda

0

Phantom

0

Piglin

0

Ravager

1.5

Silverfish

0

Skeleton

0

Spider

0

Stray

0

Vex

0

Vindicator

0

Warden

1.5

Wither Skeleton

0

Zoglin

1

Zombie

0

Zombie villager

0

Zombified piglin

0

This bug report is also related to MC-250205. In addition this bug report could be related to MC-213349.

 

Linked issues

Comments

migrated

steps to reproduce

  1. Spawn a bee

  2. /attribute @e[type=bee,limit=1] minecraft:generic.attack_knockback base set 5
  3. Hit the bee in survival mode

Observed: Despite the bee having an increased minecraft:generic.attack_knockback attribute, your knockback remained unchanged.

Expected: The attribute should enhance the knockback.

For the other listed mobs, slight adjustments to the command are required, but it should be manageable.

BugTracker

Can confirm.

migrated

(Unassigned)

Community Consensus

Platform

Normal

Combat, Mob behaviour

1.20.4, 24w10a, 24w11a

Retrieved