mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-11-27 21:45:16 +01:00
The main reservoir hoses (ctrain_scndpneumatic) exchanged the air explicitly inside each vehicle's step at the physics step of 0.01 s, as the brake hoses did before eu07/maszyna#387. One step through the hose (0.38 of area, whatever the vehicles) moves about 1.5 times the air which evens out the pipes on its ends (EN57 cars 8.3 l per bar against 5.5 l, SM40 8.6 against 5.7, passenger cars 9.3 against 6.3), and the vehicles with a main reservoir of their own feed the pipe from it in the same step. Where a vehicle has both, and hoses on both ends, the pipe can't settle: with all the main reservoirs held at 7.0 bar, the middle cars of a three unit EN57 kept jumping 0.8 bar to and fro between the steps for good (6.6/7.4), three SM40s in multiple traction the same, a two unit Impuls 1.7 bar. Freely evening out, the reservoirs of a three unit EN57 took 13.9 s at 0.01 s against 7.6 s at 0.001 s. A locomotive with passenger cars, whose pipe only it feeds, was stable already. The main reservoir pipe now goes through the brake pipe's mechanism: UpdateScndPipePressure() leaves the hose exchange to UpdatePipeCouplers() (GetScndDVc(), ScndPipeCouplersSubsteps(), 2 sub-steps for these vehicles), which vehicle_table::update_brake_pipes() calls after every vehicle stepped. The two pipes share the code and take their sub-steps apart, so the brake pipe's exchange is as it was. With it the EN57 pipes stand at 7.000, and its reservoirs even out in 7.0 s against 7.5 s at 0.001 s.