Fix the GTCEu EMI plugin failing to initialize on dedicated servers#4935
Merged
Conversation
Contributor
|
does this still work if you launch a dedicated server and connect to it? and also locally |
Contributor
Author
Yes. If you connect to a dedicated server, it works fine, and so does just singleplayer. |
jurrejelle
approved these changes
Jun 17, 2026
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.
What
This check is 1.21 specific, it is not present in 1.20.1, checked the branch.
When connected to a dedicated server, in
BreweryLogic#getPotionBrewing(), theGTCEu.isClientThread()check falls through, andGTCEu.getMinecraftServer()gets called, which returns null, because the client is not connected to an internal server.Implementation Details
The check has been rewritten to check if
GTCEu.getMinecraftServer()is not null, and if it is, runs the client side check.AI Usage
Outcome
Players or people testing out the 1.21 branch can see recipes when testing on a dedicated server.
How Was This Tested
Ran a dedicated server with just GT; then after observing the issue on the client, made this change, put the fixed jar on both the server and client, and observed the EMI plugin initializing correctly.