Configurable Valves GUI (llwz-configurable-valves-gui)
Made for our own play experience. I don't promise to maintain it. Feel free to fork, reuse or rewrite it (license: MIT).
A panel beside the Configurable Valves window (by stringweasel): a mode drop-down (overflow, top up, one way) and a 0–100% threshold slider with a number field.
A Configurable Valves valve is a pump whose circuit condition is its setting: overflow I > x, top up O < x, one way I > O. The panel only reads and writes that condition, so blueprints, copy-paste, undo, the valve's hotkeys and the plain condition editor keep working. A hand-written condition shows as "Custom condition" until a mode is picked.
- Valve names come from the valve mod's
mod-configurable-valvesmod data, so valves other mods register there work too. - No per-tick work while no valve window is open; while one is, the panel re-reads the condition every 15 ticks to follow changes made elsewhere.
Build and test
- The mod zip is this folder as
llwz-configurable-valves-gui_<version>/, withoutbuild/,test/and this README. test/run.luaruns the control script against stubbed Factorio APIs and simulates the GUI events:lua5.2 test/run.luafrom this folder.