mojira.dev
MCPE-162063

Durability bar doesn't appear anymore when using tools/weapons/armors

When using tools and weapons, the durability bar does not appear, even though the durability of the item gets decreased. 

Reproducing the issue:

  1. Pick a gold weapon or tool

  2. Hit a mob or break some blocks with the tools

Eventually, the item will break after a few uses, but no durability bar is shown.

Observed:

The durability bar does not appear.

Expected:

The durability bar appears.

Code analysis (post-1.19.40)

Can be find in my comment below.

Linked issues

MC-256154 Issue with the durrability Resolved MCPE-162062 All items which have health no longer wear down and are immediately repaired during world load Resolved MCPE-162121 Tool Damage bar not showing Resolved MCPE-162238 Durability bar does not appear on items that have spent their durability Resolved MCPE-162292 Tools and equient take no damage Resolved

Attachments

Comments 5

Fix confirmed in 1.19.40.23 preview.

Just to clarify, anyone with a resource pack that contains a pre-1.19.40 ui_common.json file will probably still be affected to this. It doesn't mean that this ticket needs to be reopened, but just to prevent duplicates like MCPE-163774 to still happen after 1.19.40.

I have the same issue in 1.19.40.02 with a ressource pack

This issue has been sucefully fixed in 1.19.40.23 preview in the vanilla resource pack. However, any resource pack that contains a ui_common.json file (which has some of the coding for the durability bar) is highly probable to still be affected to this.

One of the pre-19.40 bindings in the codes of the durability bar has a part called 'binding_name_override'. After further looking, the binding has a different definition from the post-1.19.40.23 one, and can also be seen below:

1.19.30

"durability_bar": {
    },
    "bindings": [
      { 
        "binding_name_override": "#progress_bar_visible",

1.19.40

"durability_bar": {
    },     
    "bindings": [
      { 
        "binding_name_override": "#touch_progress_bar_visible",

Notice how the 'binding_name_override' has changed from "#progress_bar_visible" to "#touch_progress_bar_visible". This explains how any resource pack that has that code included still triggers this bug.

Note that below these codes, there's also a code called "durability_bar_grabbed@durability_bar" that has the same binding_name_override, and like the one i showed above, depending of the version of the file you are using, it will also still trigger this bug. Both binding_name_override code definitions needs to be updated to make the durability bar appear again.

Pedro Barbosa Bruno

(Unassigned)

882957

Confirmed

Multiple

durability-bar, hud, missing, ui

1.19.40.22 Preview, 1.19.40.21 Preview, 1.19.40.20 Preview

1.19.40.23 Preview

Retrieved