Repository navigation
Refactor Configurable Maintenance Hatch to fix the UI - #5573
Open
DilithiumThoride wants to merge 12 commits into
Open
DilithiumThoride wants to merge 12 commits into
DilithiumThoride wants to merge 12 commits into
Conversation
…aintenance hatch literally just trying to fix the UI
YoungOnionMC
requested changes
Oct 19, 2026
| } | ||
|
|
||
| public static String formattedDecimalValue(int value, int decimalPlaces) { | ||
| String formatter = "%0" + (decimalPlaces + 1) + "d"; |
Member
There was a problem hiding this comment.
String.format? do we not have a string util to specify variable decmial places
Contributor
Author
There was a problem hiding this comment.
Not for this purpose?
YoungOnionMC
requested changes
Oct 22, 2026
# Conflicts: # src/generated/resources/assets/gtceu/lang/en_ud.json # src/generated/resources/assets/gtceu/lang/en_us.json
This branch has not been deployed
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
Fixes #5436 , fixing the hover tooltips and converting the text input into a +/- button interface.
Also refactors the entire Configurable Maintenance Hatch into being its own separate class rather than all packed into the base Maintenance Hatch class.
Also fixes the balance issue where Configurable Maintenance Hatches would make Generators burn 10% less fuel while also having less maintenance.
(Also fixes the UI widget for regular maintenance hatches using Tools with size 18 icons rather than size 16 icons, making them look weirdly stretched.)
Implementation Details
And creates a new
createDecimalInputWithButtonsmethod (and helpers) within GTMuiWidgets, allowing other UIs to make decimals rather than just ints or buckets. Implementation based on #5415 , including doing the input using ints as a proxy for fixed-point decimals. Also adds overrides for the button hover and increment methods to allow increment multipliers other than 4.This PR changes 1 lang entry and has a run of Datagen, however the Datagen task is currently broken on 1.21 likely due to something from #5538 (#5531)
AI Usage
Outcome