mojira.dev
MC-311607

Items with the `weapon` component with `disable_blocking_for_seconds` set no longer disable items with the `blocks_attacks` component

When an instance of damage is applied to a player using an item with the blocks_attacks component (both through the damage command and normal attacks) the item’s ability to block attacks is no longer disabled if the source entity has an item in its mainhand with the disable_blocking_for_seconds field set in the weapon component. When the damage command is used to apply the instance of damage which should disable blocking, the command fails with the message “Target is invulnerable to the given damage type“.

Previously, items with the blocks_attacks component had their ability to block damage disabled when an instance of damage was applied (both through the damage command and normal attacks) from a source entity wielding an item with disable_blocking_for_seconds set in the weapon component.


Steps to Reproduce

  1. Summon a hostile mob and replace its mainhand slot with an item which has the disable_blocking_for_seconds field set in the weapon component, like an axe.

  2. Begin blocking attacks from the summoned mob using an item with the blocks_attacks component, like a shield.

Expected Result
The item’s ability to block attacks is disabled for the time specified in the weapon component.

Actual Result

The item’s ability to block attacks is not disabled.

Attachments

Comments 1

Thank you for helping us improve Minecraft! We saved your files:

[media][media]

ARKIITeKK

Thomas Mojang

Confirmed

Platform HC

Normal

Commands

26.3 Pre-Release 1

26.3 Release Candidate 1

Retrieved