Gas Meter - user-grinch/ModelExtras GitHub Wiki
Overview
The fixed gauge accepts x_gauge_fixed*, x_gasmeter, x_gm, and petrolok. Despite the legacy gas-meter names, it does not read fuel: the current implementation picks a random fixed needle position when the vehicle model is initialized. It is a decorative/static gauge and does not change as fuel is consumed.
Setup
-
Needle Node Dummy (
x_gm):- Place the fixed-gauge node at the pivot point where the needle should rotate.
x_gmis one accepted name. - Ensure the pivot/origin is properly aligned so that rotation visually sweeps from Empty to Full.
- Place the fixed-gauge node at the pivot point where the needle should rotate.
-
Texture and Alignment:
- The needle mesh should resemble the desired fixed gauge indicator.
- Design the gauge background with markings appropriate for the chosen display.
The selected angle is random within its configured range (default 30–120 degrees) and stays fixed for that initialized vehicle. See the gauges page for minangle and maxangle JSONC fields.
{
"gauges": {
"x_gm": {
"minangle": 30.0,
"maxangle": 120.0
}
}
}
Example Hierarchy
Dashboard
└── x_gm (Needle that rotates)