Skip to content

Fix opening GUI outside of worlds#6386

Merged
Big-Iron-Cheems merged 11 commits intoMeteorDevelopment:masterfrom
machiecodes:itemstack-fix
May 9, 2026
Merged

Fix opening GUI outside of worlds#6386
Big-Iron-Cheems merged 11 commits intoMeteorDevelopment:masterfrom
machiecodes:itemstack-fix

Conversation

@machiecodes
Copy link
Copy Markdown
Contributor

@machiecodes machiecodes commented May 7, 2026

Type of change

  • Bug fix
  • New feature

Description

In 26.1 Itemstacks now require components to be loaded from registry entries that are only provided when we join a world, however since we only need a few specific components that are stored client-side we can simply construct our own stacks for rendering that contain only those.

Implemented utils/DisplayItemUtils which creates these stacks and replaced all getDefaultInstance() calls in rendering contexts with DisplayItemUtils#toStack(Item item)

Breaking for addons, any addon that defines category icons will need to do so using the new util as well or NPE

Also added a few placeholder items in inventoryhud that show while outside of a world

Related issues

#6361

How Has This Been Tested?

8mb.video-3Zp-cu0PskvZ.mp4

Checklist:

  • My code follows the style guidelines of this project.
  • I have added comments to my code in more complex areas.
  • I have tested the code in both development and production environments.

@xvrrv
Copy link
Copy Markdown
Contributor

xvrrv commented May 7, 2026

related issue may be this one
#6361

@machiecodes
Copy link
Copy Markdown
Contributor Author

Actually yea that is related I am simply blind :3 thanks

@Big-Iron-Cheems Big-Iron-Cheems merged commit 0d784ae into MeteorDevelopment:master May 9, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants