mojira.dev
MC-112730

Beacon beam and structure block render twice per frame

The bug

Beacon beams and structure block outlines will render themselves twice per frame if the chunk sector that the block entity is in is in view.

This can be observed by the opacity of a beacon beam changing:

[media]

The decreased opacity when looking upward indicates there is only a single render.

As side note this bug was introduced in the fix to MC-68247

Affected blocks

Last updated for 1.11.2

  • beacon

  • structure_block

Code analysis

Based on 1.11.2 decompiled using MCP 9.35 rc1

This happens because the method net.minecraft.client.renderer.RenderGlobal.renderEntities(Entity, ICamera, float) first renders all tile entities and then all "global" tile entities. These are in the set net.minecraft.client.renderer.RenderGlobal.setTileEntities because their overridden method net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer.isGlobalRenderer(T) returns true.

Linked issues

Comments 2

Can this still be reproduced in the latest 1.17 development snapshot?

Yes, I can confirm in 1.19.2.

Paul Fulham

(Unassigned)

Confirmed

Platform

Normal

Beacon, Rendering

beacon, beam, block-entity, rendering, structure_block

Minecraft 1.11.2, Minecraft 1.12 Pre-Release 6, Minecraft 17w47b, 1.15.1, 1.16.3, 1.16.4, 20w48a, 1.19.2, 1.21.1, 1.21.3

25w21a

Retrieved