18
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-11-19 06:26:01 +01:00

feat: bistable hold coil lever of the line breaker (eu07/maszyna#364)

main_off_bt declared with "type: toggle" in the cab's .mmd is now the
line breaker's hold coil lever of the ET22 and EP09: it stays where it is
put. Off, it opens the line breaker and keeps it from closing (also
cancelling a closing armed by a held main_on_bt); back on, it only feeds
the coil again. The single keyboard key puts the lever back on before
closing, and a line breaker closed by the AI or through the control
cable puts the lever back on to match.

TGauge now remembers whether type: was given, since every control
defaults to toggle. Without type: on main_off_bt (all vehicles today)
nothing changes.

Data (SVN, not part of this commit): add "type: toggle" to main_off_bt:
in dynamic/pkp/et22_v3/*.mmd and dynamic/pkp/ep09_v1, ep09_v2/*.mmd.
Older exes ignore it.
This commit is contained in:
jerrrrycho
2026-11-07 18:10:59 +01:00
parent 939e42b611
commit d7c66fa7bc
5 changed files with 112 additions and 2 deletions

View File

@@ -249,6 +249,7 @@ TGauge::Load_mapping( cParser &Input, TGauge::scratch_data &Scratchpad ) {
gaugetype == "delayed" ? push_delayed :
gaugetype == "pushtoggle" ? pushtoggle :
toggle; // "toggle" and default
m_typedeclared = true;
}
else if( key == "soundinc:" ) {
m_soundfxincrease.deserialize( Input, sound_type::single );