config schema — minetuner.json
Location: <fabric config dir>/minetuner.json. Gson, pretty-printed, atomic write
(.tmp + ATOMIC_MOVE). See
architecture.html#config-lifecycle for load/save/corruption-recovery behavior — this page is
just the field list. Source: config/MineTunerConfig.java.
There is no versioned migration system. Backward compat is handled ad hoc per-field in
load()/backFill() (null-guards, one explicit rename:
anchorDx/anchorDy → anchorFracX/anchorFracY).
If you hand-edit this file, know that an unparseable result gets backed up as
minetuner.json.bak-<epoch-ms> and replaced with fresh defaults — it does not merge or repair.
root object
| field | type | default | notes |
nextId | int | 1 | next id handed to a new StatListConfig; not reused after delete. |
lists | StatListConfig[] | [list#0] | see per-list schema below. |
overlayEnabled | bool | true | global show/hide. Same switch as the Toggle Overlay keybind. |
hardwareSensorsEnabled | bool | false | see hardware-sensors.html. |
hardwareSensorBaseUrl | string | http://localhost:8085 | LHM Remote Web Server base URL, no trailing slash. |
hardwareSensorPollIntervalMs | int | 1500 | clamped ≥100 by clampGuiTuning(). Read live by the poller thread every cycle. |
hardwareSensorRequestTimeoutMs | int | 300 | clamped ≥50. Baked into the poller's HttpClient at construction — changing this restarts the poller (see reconcileWithConfig()). |
reorderPanelMaxVisibleRows | int | 16 | clamped ≥3. |
panelRowHeight | int (px) | 13 | clamped ≥6. |
panelWidth | int (px) | 160 | clamped ≥60. Standard editor panel width. |
widePanelWidth | int (px) | 216 | clamped ≥ panelWidth. "Edit Stats" panel only. |
panelPadding | int (px) | 4 | clamped ≥0. |
dragSnapThresholdPx | int (px) | 6 | clamped ≥0. |
textScaleMin | float | 0.5 | clamped ≥0.1. |
textScaleMax | float | 2.0 | clamped ≥ textScaleMin. |
StatListConfig — one per HUD panel, in lists[]
| field | type | default | notes |
id | int | — | stable identity. TemplateEngine's parse cache and warned-token set are keyed by this. |
name | string | "List <id>" | — |
statEnabled | map<Stat name, bool> | all false | every stat starts disabled on a new list — nothing is on by default, contrary to older builds. |
statOrder | string[] | enum declaration order | display order for classic mode. getVisibleStats() filters to enabled + dedupes. |
statSettings | map<Stat name, StatSettings> | lazy per-stat | see below. |
statThresholds | map<Stat name, ThresholdSettings> | built from each stat's own defaults | only present for stats in THRESHOLD_STATS. |
anchorCorner | enum | TOP_LEFT | TOP_LEFT / TOP_RIGHT / BOTTOM_LEFT / BOTTOM_RIGHT. |
anchorFracX, anchorFracY | double | 0.01, 0.01 | offset from anchor corner as a fraction of screen w/h — scale-independent by design. |
anchorDx, anchorDy | Integer (nullable) | null | legacy. Pre-normalization raw pixel offsets. Migrated into anchorFrac* on first load if non-null, then nulled out. Don't write these in a new config. |
showBackground | bool | true | — |
textShadow | bool | false | — |
useCustomColor | bool | false | when true, overrideColor replaces every stat's normal/threshold color for this list. |
overrideColor | int (ARGB) | 0xFFFFFFFF | — |
textScale | float | 1.0 | clamped to [textScaleMin, textScaleMax] by the +/- controls; not force-clamped on raw JSON load. |
snapX | enum | NONE | NONE / LEFT_ON_CENTER / CENTER_ON_CENTER / RIGHT_ON_CENTER. |
snapY | enum | NONE | NONE / TOP_ON_CENTER / CENTER_ON_CENTER / BOTTOM_ON_CENTER. |
useTemplate | bool | false | false = classic per-stat-line mode. |
templateLines | string[] | [] | only rendered when useTemplate is true. See template-mode.html. |
StatSettings — per (list, stat) pair
| field | type | default | notes |
showPrefix | bool | true | classic mode only — shows/hides the "Label: " prefix. |
decimals | int | 1 | ignored if the stat's supportsDecimals() is false. |
renderAsGraph | bool | false | ignored if the stat's supportsGraph() is false. |
graphStyle | GraphStyle | see below | used only when renderAsGraph is true. |
GraphStyle
| field | type | default | notes |
showPanelBackground | bool | true | — |
showGridlines | bool | true | — |
showPeakMarkers | bool | true | — |
valueDisplay | enum | CURRENT | NONE / CURRENT / MIN_CURRENT_MAX. |
smoothing | int | 0 | 0 = off, else moving-average window size (2/3/4 in the UI stepper). |
autoScale | bool | true | when false, uses fixedMin/fixedMax instead of scaling to observed range. |
fixedMin, fixedMax | float | 0, 100 | only used when autoScale is false. |
width, height | int (px) | 80, 28 | — |
colorMode | enum | CURRENT_THRESHOLD | see below. |
accentColor | int (ARGB) | 0xFF55FF55 | used only when colorMode == FIXED_ACCENT. |
colorMode values:
CURRENT_THRESHOLD — whole graph tinted by the current value's threshold color.
PER_SEGMENT_THRESHOLD — each historical sample colored by its own value at record time.
FIXED_ACCENT — single user-chosen color for the whole graph, from accentColor.
GRADIENT — smooth interpolation across the visible range, blue→green→yellow→red.
ThresholdSettings
| field | type | default | notes |
enabled | bool | false | false = ignore goodMin/warnMin, use the stat's own built-in defaultGoodMin()/defaultWarnMin() instead. |
goodMin | float | stat-specific | cutoff for the green band. Direction (higher-is-better vs lower-is-better) is per-stat, see StatDefinition.higherIsBetter(). |
warnMin | float | stat-specific | cutoff for yellow vs red, same direction as goodMin. |
minimal example
{
"nextId": 1,
"lists": [
{
"id": 0,
"name": "List 0",
"statEnabled": { "TPS": true, "FPS": true },
"statOrder": ["TPS", "FPS", "..."],
"statSettings": {},
"statThresholds": {},
"anchorCorner": "TOP_LEFT",
"anchorFracX": 0.01,
"anchorFracY": 0.01,
"showBackground": true,
"textShadow": false,
"useCustomColor": false,
"overrideColor": -1,
"textScale": 1.0,
"snapX": "NONE",
"snapY": "NONE",
"useTemplate": false,
"templateLines": []
}
],
"overlayEnabled": true,
"hardwareSensorsEnabled": false,
"hardwareSensorBaseUrl": "http://localhost:8085"
}
(overrideColor: -1 is 0xFFFFFFFF as a signed 32-bit int — Gson serializes
ARGB colors as plain signed ints, not hex strings.)