Fix custom-block icon and display name in value panel (#426)#427
Merged
tastybento merged 1 commit intodevelopfrom May 8, 2026
Merged
Fix custom-block icon and display name in value panel (#426)#427tastybento merged 1 commit intodevelopfrom
tastybento merged 1 commit intodevelopfrom
Conversation
The /is value panel rendered Oraxen/Nexo/ItemsAdder blocks as paper with the prettified config key as the name. Look up the real ItemStack from the plugin's registry and use it as the icon, plus the item meta display name when present. Lookup helper is extracted to Utils so DetailsPanel and ValuePanel share it. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Summary
/is valuepanel rendered Oraxen / Nexo / ItemsAdder blocks asMaterial.PAPERwith the prettified config key as the nameValuePanelnow looks up the real custom-blockItemStackfrom the plugin's registry and uses it as the icon (so the texture / model data is preserved) and uses the item'sItemMetadisplay name when presentgetCustomBlockItemStacklookup (already inDetailsPanel) plus a newgetCustomBlockDisplayNamehelper intoUtilsso both panels share the same logicCraftEngine custom blocks still fall back to
Material.PAPERbecauseCraftEngineHookin BentoBox core does not yet expose an item-by-id lookup — that's a separate change in BentoBox.Test plan
mvn test— 216 tests pass/is valuepanel shows correct icon and display name for Oraxen blocks/is valuepanel shows correct icon and display name for Nexo blocks/is valuepanel shows correct icon and display name for ItemsAdder blocks🤖 Generated with Claude Code