Skip to content

Commit

Permalink
Add dimension checking for the visualizer
Browse files Browse the repository at this point in the history
  • Loading branch information
ReaganAR committed Jun 2, 2024
1 parent 6354621 commit 946f20b
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,12 @@ object VisualiserOverlayRender extends WorldOverlayRenderer {
val stack = Client.player.inventory.getCurrentItem
if (stack != null && stack.getItem == ItemVisualiser) {

// Do not render if in a different dimension from the bound network
val networkDim = stack.getTagCompound.getInteger("dim")
if (networkDim != Client.world.provider.dimensionId) {
return
}

val mode = ItemVisualiser.getMode(stack)

GL11.glPushAttrib(GL11.GL_ENABLE_BIT)
Expand Down

0 comments on commit 946f20b

Please sign in to comment.