mojira.dev
MCPE-161076

Melee attacks inconsistently extend the duration of "minecraft:angry"

When using the component "minecraft:behavior.hurt_by_target", and no other target mechanism, melee attacks don't behave consistently when paired with the component "minecraft:angry". There may be other attack components, but these are the ones I tested.

Behavior:

  • minecraft:behavior.melee_attack: entity will continue to attack if permitted to execute an attack within the duration of "minecraft:angry". If target maintains distance outside attack range for duration of "minecraft:angry", duration will expire and event will fire.

  • minecraft:behavior.delayed_attack: regardless of engagement conditions (attacking or being attacked), "minecraft:angry" duration will expire and event will fire.

  • minecraft:behavior.stomp_attack: regardless of engagement conditions (attacking or being attacked), "minecraft:angry" duration will expire and event will fire.

  • minecraft:behavior.ocelotattack: regardless of engagement conditions (attacking or being attacked), "minecraft:angry" duration will expire and event will fire.

 

Expected behavior:

All attack behavior components should extend the duration of "minecraft:angry" if allowed to execute.

 

Steps to reproduce:

  1. Load a world with the attached Bug Test addon.

  2. Summon a Zombie Pigman with one of the following events:

    • as_melee

    • as_delayed_melee

    • as_stomp

    • as_ocelot

  3. Entity will behave as noted above when attacked.

Attachments

Comments 7

Considering how long the bug has not been updated, is this still an issue in 1.19.60?

Yes. I just tested the listed melee components using the test addon pack posted above. The issue still remains in 1.19.60.

Attempting to summon a Zombie Pigman using the above values while the behavior pack is installed does not appear to work, even if Holiday Creator Features and Upcoming Creator Features experimental toggles are enabled. Are any specific settings required, or does the command need to be inputted in a specific manner?

This ticket will automatically reopen when you reply.

No experiential features are required. I downloaded this test pack and tested it, again. My client is Bedrock Edition on Windows 10, v1.19.60. Please ensure that the pack is installed, is activated in the world, and has no other addons set higher in the load order.

"/summon zombie_pigman ~ ~ ~ as_stomp"

The above command will summon one of the variants. The angry time is set to 25 seconds. If the vanilla version was summoned (as_melee), it would continue to attack repeatably, without end, if it was allowed to land hits before the timer expired. Using the above example, the entity will attack continuously for 25 seconds then stop mid-combat. This tells me other versions of melee components are not feeding back into the minecraft:angry component to keep it active.

I've added two low resolution videos illustrating "as_melee" vs "as_stomp". The entity called with "as_melee" will continue attacking, while the entity called with "as_stomp" will cease attacking after ~25 seconds.

Is this still an issue in the latest version? If yes, can you please add it to the affected versions (or mention it if you are not the reporter)?

This ticket will automatically reopen when you reply.

I've confirmed this bug still exists in 1.20.30, and with precisely the same behavior.

bobmhac

(Unassigned)

1157022

Confirmed

Multiple

Windows 10

1.19.20, 1.19.60, 1.20.30

Retrieved