Skip to content

Properly defer machine registration (1.21) - #5412

Open
gustovafing wants to merge 8 commits into
gus/update-machine-builderfrom
gus/defer-machine-registration
Open

Properly defer machine registration (1.21)#5412
gustovafing wants to merge 8 commits into
gus/update-machine-builderfrom
gus/defer-machine-registration

Conversation

@gustovafing

Copy link
Copy Markdown
Member

What

Properly defers machines to the proper registration time, machine builder now returns a machine entry holder, which can be used in a lot of places where machinedefinitions could.
No AI

@gustovafing
gustovafing added this pull request to stack #5411 September 9, 2026 08:28
@gustovafing
gustovafing requested a review from a team as a code owner September 9, 2026 08:28
@gustovafing gustovafing added ignore changelog PR should not be added to the changelog. type: refactor Suggestion to refactor a section of code Release: API - X.0.0 Major Breaking Refactors that MUST be in a API-Breaking Release Ignore Version Sync Do not append this issue to the version sync issue tracker. 1.21 labels Sep 9, 2026
@github-actions github-actions Bot added the Tests: Failed Game Tests have failed on this PR label Sep 9, 2026
@gustovafing
gustovafing force-pushed the gus/defer-machine-registration branch from 96c840f to eeded09 Compare September 9, 2026 09:04
@github-actions github-actions Bot added Tests: Passed Game Tests have passed on this PR and removed Tests: Failed Game Tests have failed on this PR labels Sep 9, 2026

@screret screret left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Round 1/? (more coming; might PR some changes myself)

Comment thread src/main/java/com/gregtechceu/gtceu/api/multiblock/Predicates.java
Comment thread src/main/java/com/gregtechceu/gtceu/api/machine/MachineDefinition.java Outdated
protected final GTRegistrate registrate;
protected final String name;
SELF extends MachineBuilder<DEFINITION, MACHINE, SELF>>
extends AbstractBuilder<MachineDefinition, DEFINITION, GTRegistrate, SELF> {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add the P generic I mentioned instead of disallowing that entirely by hardcoding the parent to GTRegistrate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

1.21 ignore changelog PR should not be added to the changelog. Ignore Version Sync Do not append this issue to the version sync issue tracker. Release: API - X.0.0 Major Breaking Refactors that MUST be in a API-Breaking Release Tests: Passed Game Tests have passed on this PR type: refactor Suggestion to refactor a section of code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants