Colossal Chests 2, Phase 7: Magnet wall - #226
Open
rubensworks wants to merge 1 commit into
Open
rubensworks wants to merge 1 commit into
rubensworks wants to merge 1 commit into
Conversation
A functional wall that pulls dropped items around it into its chest. Items are pulled towards the wall and inserted when they touch the chest, through the same automated insert as a hopper. Items with a pickup delay, such as ones a player just threw, and items the chest can not take are left alone. On by default, with the radius (default 8) and a toggle in the server config. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RSz5r6eowhjNuANBjZE2v6
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.
The Magnet wall, as its own PR (one feature per PR). It is independent of the Redstone wall PR (#225); whichever merges second needs a small merge of
WallType, the lang file and the pickaxe tag, which I'll do.Summary
magnet):magnetEnabled(default true) andmagnetRadius(default 8, 1 to 32).Design deviations
None. The design says "pulls items in a radius from that block. On by default; radius and toggle in config." The pickup delay and "only what fits" rules are my additions; tell me if you'd rather pull everything.
Validation
testMagnetWallPullsItemstestMagnetWallLeavesWhatDoesNotFitThe side case was found by the first test: items pressed against another face of the chest got stuck until inserts happened on contact with the whole chest.
Totals: 290 unit tests; game tests Fabric 75, Forge 73, NeoForge 73, all passing.
In-game (clientdevbridge): script and screenshots in
clientdevbridge-screenshots/phase7d-magnet. On NeoForge, an iron 3x3 with a Magnet wall on top:Not checked in-game on Fabric or Forge.
Known issues
🤖 Generated with Claude Code
https://claude.ai/code/session_01RSz5r6eowhjNuANBjZE2v6
Generated by Claude Code