Skip to content

allow applying modifiers multiple times#290

Closed
sawyergt wants to merge 8 commits into
GTNewHorizons:masterfrom
sawyergt:feature-batch-modify
Closed

allow applying modifiers multiple times#290
sawyergt wants to merge 8 commits into
GTNewHorizons:masterfrom
sawyergt:feature-batch-modify

Conversation

@sawyergt
Copy link
Copy Markdown

The current behaviour of the Tool Station/Tool Forge is to consume and apply only one modifier material per slot to a tool when craft. This PR changes it to allow the modifier to be applied multiple times in the same craft.

preview.webm

Previous behaviour would have resulted in only two lapis being consumed and applied to the modifiers for the pickaxe.

sawyergt added 7 commits May 28, 2026 20:09
couldn't figure out how to modify `addToolTip` in a reasonable way
previous approach had some issues in that addons could override `ItemModifier`'s methods, which meant that it would only really work with tinker's modifiers

any incompatible mod would apply the modifier once and then void all items in the tool slot

this, while hacky, should retain compatibility with every addon

P.S: i also modified `ToolStationContainer`/`ToolForgeContainer`, but they dont seem to be used, at least not in my testing
@sawyergt
Copy link
Copy Markdown
Author

with the current changes, it works for modifiers such as lapis, redstone, etc. and tool repairs
but for modifiers implemented with ModInteger (such as reinforcements and moss) i couldn't think of a clean way to support them

ideas are welcome

@sawyergt sawyergt marked this pull request as ready for review May 31, 2026 14:33
@FrostyFire1
Copy link
Copy Markdown
Member

Hi!
It appears that i have made a similar PR (#294) not knowing you opened this one. My implementation is slightly different as it allows more items to be present in the station than the modifier needs. We might want to discuss what to do here; if you wanna talk on discord i'm @FrostyFire1

@sawyergt
Copy link
Copy Markdown
Author

sawyergt commented Jun 3, 2026

closing in favor of #294

@sawyergt sawyergt closed this Jun 3, 2026
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.

3 participants