Add ender-upgradable storage terminals with an ender chest tab - #213
Open
rubensworks wants to merge 1 commit into
Open
Add ender-upgradable storage terminals with an ender chest tab#213rubensworks wants to merge 1 commit into
rubensworks wants to merge 1 commit into
Conversation
Storage terminals can be ender-upgraded by right-clicking them with an eye of ender, which unlocks an additional Ender Storage tab that exposes the player's ender chest inventory. Portable storage terminals can be ender-upgraded by combining them with an eye of ender in a crafting grid, which retains the network they were linked to. Ender-upgraded terminals emit ender particles, and give back the eye of ender when they are broken. The ender chest tab uses regular container slots, so it has no channel selector, search field or variable filter slots. Tabs can now hide those via ITerminalStorageTabClient, and can apply regular quick move semantics via ITerminalStorageTabCommon#handleQuickMove. Based on the work in #191. Closes #177 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Kzc5LxSaedCXCK4pynhJV3
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.
Reworked and completed version of #191, targeting
master-1.21-lts.That PR targeted
master-1.19-ltsand used pre-1.21 APIs (NBT tags instead of data components, oldResourceLocationconstructors, ...), so this is a fresh implementation rather than an upmerge, keeping the original intent.Closes #177
What it does
Storage terminals can be ender-upgraded by right-clicking them with an Eye of Ender, which unlocks an additional Ender Storage tab that exposes the player's ender chest inventory.
integratedterminals:ender_upgradedboolean data component for the item.terminalStorageTabEnderChestEnabledserver config option.Changes compared to #191
HolderLookup.Provider,ItemStack.is, ...).ITerminalStorageTabCommon#handleQuickMove, whichContainerTerminalStorageBase#quickMoveStackcalls for the selected tab before falling back to the ingredient-based quick move handling.hasSearchField(),hasChannelField()andhasVariableFilterSlots()defaults onITerminalStorageTabClient. The search field placeholder box is simply not drawn for such tabs, so no separate gui texture is needed.ITerminalStorageTabRegistry#registerLast, becauseAttachCapabilitiesEventIngredientComponentis fired once per ingredient component, which would otherwise place this tab in-between the ingredient component tabs.Documentation
Terminals -> Storage Terminal -> Ender StorageTerminal Tutorials -> Ender-upgraded Storage Terminalintegratedterminals:storage_terminal_ender/ender_upgrade_storage_terminal, triggered by the newintegratedterminals:terminal_storage_ender_upgradedcriterion when a terminal is ender-upgraded by right-clicking it with an eye of ender.Only
en_us.jsonwas updated, as requested.Testing
./gradlew buildand./gradlew runGameTestServerpass (30 game tests, 6 of them new).New game tests cover the upgrade interaction, the eye of ender drop, tab availability before/after upgrading, shift-clicking into and out of the ender chest, the crafting recipe (including network link retention and refusing to upgrade twice), and the new advancement (positive and negative).
Everything was also verified in a dev client: placing and upgrading a terminal, the particles next to a vanilla ender chest for comparison, the tab layout with and without the hidden gui elements, shift-clicking and normal clicking in the ender slots (verified against the player's server-side
EnderItems), the portable terminal upgrade recipe and its gui, the advancement unlocking, and the new infobook pages.Note
While testing the infobook I ran into an unrelated pre-existing CyclopsCore crash:
RecipeAppendix#renderToolTipscallsrenderTooltipon item/fluid buttons of empty recipe slots, whose element isnulland whose position was never updated, so they sit at(0, 0). Hovering the top-left 16x16 pixels of the screen while any recipe appendix with an empty slot is shown throws an NPE inrenderItemTooltip/renderFluidTooltip. This reproduces on existing pages (e.g. the Drying Basin appendices in the Storage Terminal crafting section), so it is not caused by this PR, but it may be worth fixing in CyclopsCore.Generated by Claude Code