mojira.dev
MC-279596

Deleted structure block still shows structure if the RenderSection is now empty

Reproduction steps:

  • Fly a few dozens of blocks above ground (i.e. to an empty RenderSection).

  • Run `/setblock ~ ~ ~ minecraft:structure_block`

  • Change the structure block to SAVE mode.

  • Set a structure size of 2x2x2

  • Confirm and make sure that the bounding box is shown

  • Delete the structure block

  • Notice that the bounding box is still shown!

Expected behavior:

Once the structure block is deleted, it should not show a bounding box anymore.

 

Suggested fix:

This issue seems to happen with global block entities only, which don't get updated for empty sections. Adding `RenderSection.this.updateGlobalBlockEntities(Set.of())` in `RebuildTask#doTask` right before `RenderSection.this.setCompiled(SectionRenderDispatcher.CompiledSection.EMPTY)` seems to fix the issue.

Attachments

Comments 1

I am able to reproduce the reported behavior. It was introduced in 24w21a.

Technici4n

(Unassigned)

Community Consensus

Platform

Normal

Rendering

24w21a, 1.21.4

Retrieved