Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix many diesel_engine_fuel_types not being registered if one is inco… #128

Open
wants to merge 1 commit into
base: 1.20.1
Choose a base branch
from

Conversation

Amronos
Copy link

@Amronos Amronos commented Feb 6, 2025

…rrect

When defining custom fuel types using datapacks, if you get a JSON file incorrect or a fuel added there, is not present in-game, the registering process for fuels stops due to the return; statements. This causes the other correctly defined fuels to not get registered, including the ones registered by default in this mod. I have fixed this by removing the return;, reversing the two if statements in which they were, and adding the necessary code inside those if statements.
Also, my IDE did some formatting and renamed cdgJei.java to CDGJEI.java. If you are not ok with these changes I can revert them.

@george8188625
Copy link
Owner

So that return is a mistake, I should have used continue, or do it the way you proposed. About the renaming of CDGJEI, I've already renamed this in the un-released update. I renamed and refactored almost everything. The update is almost done, I just need to fix a bug and do some polishing.

I don't think I'm gonna merge this pr, because I'm gonna refactor that class either way, but thanks for pointing out that mistake. I'm gonna fix that.

@Amronos
Copy link
Author

Amronos commented Feb 6, 2025

Thanks!

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.

2 participants