mojira.dev
MC-123784

Structure blocks don't display their mode and name when looked at

The Bug

When you hover over a structure block, it used to display the mode and name, allowing players to determine which structure loads which without accessing the GUI. Now it's gone.

Steps to Reproduce:

  1. Summon a structure block with its "mode" set to "data" by using the command provided below.

    /setblock ~ ~ ~ minecraft:structure_block[mode=data]
  2. Look at the structure block and take note as to whether or not it displays its mode when looked at.

Observed Behavior

Structure blocks don't display their mode when looked at.

Expected Behavior

Structure blocks would display their mode when looked at.

Code Analysis

See @unknown's comment.

Linked issues

Attachments

Comments

Carretero Martínez

Affects 1.16.2

Earthcomputer

Confirmed for 1.16.3

This is caused by a refactor, which looks like it happened in 1.13, to block entity rendering. In 1.12, `BlockEntityRenderer.render` used to render the display name of a block entity if it had a name to display. `StructureBlockRenderer.render` used to call the superclass method. Now (at least in 1.16), the `BlockEntityRenderer.render` method is abstract and the code for rendering nameplates appears to have been removed (either by accident or by proguard).

As a side note, in 1.12, most block entities didn't call `super.render` even though the corresponding block entities overrode the method to get the nameplate, so didn't end up displaying the nameplate, which was probably a bug.

Avoma

Can confirm in 21w03a.

Avoma

Can confirm in 21w05b.

Avoma

Can confirm in 21w06a.

Avoma

Can confirm in 1.16.5 and 21w08b.

Avoma

Can confirm in 1.17.1. Video attached.

ampolive

Can confirm in 21w37a.

Avoma

I am able to confirm this behavior in 21w41a. Here are some extra details regarding this problem.

The Bug:

Structure blocks don't display their mode when looked at.

Steps to Reproduce:

  • Summon a structure block with its "mode" set to "data".

/setblock ~ ~ ~ minecraft:structure_block[mode=data]
  • Look at the structure block and take note as to whether or not it displays its mode when looked at.

Observed Behavior:

Structure blocks don't display their mode when looked at.

Expected Behavior:

Structure blocks would display their mode when looked at.

Avoma

Can confirm in 1.18.1.

Avoma

Can confirm in 1.18.2.

Avoma

Can confirm in 1.19 and 22w24a.

CivetKitty

(Unassigned)

Confirmed

Platform

Low

Rendering

structure_block

Minecraft 18w01a, Minecraft 18w08b, Minecraft 18w16a, Minecraft 18w20c, Minecraft 1.13, ..., 22w24a, 1.19.3, 1.19.4, 23w14a, 1.20.1

Retrieved