18
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-12-04 23:45:17 +01:00
Files
jerrrrycho fc722cdc62 feat(physics): flank contacts in monitor, foul vehicles in trackcheck, ladders and editor changes
Review of #591:

- physics.collisions monitor (with physics.collisions.flank yes) now finds the
  flank contacts and only logs them: "flank collision monitor: <a> would hit
  <b> at ..." and "flank collision monitor: <a> and <b> apart again,
  overlapped by up to ... m". Nothing slows down or derails. The neighbour
  search on a switch keeps its legacy behaviour there; since it takes a
  vehicle on the other way beside the searcher for one ahead of it, only
  the couplings (not the neighbours) make a pair joined for the monitor.
- physics.trackcheck yes lists, once at the first update, the vehicles with a
  corner of the body closer to the axis of the other way of a switch than
  half the 3.50 m of the fouling point, up to that fouling point:
  "trackcheck: <vehicle>: stands foul of the switch <switch>, <d> m into the
  room of its other way", and a count. It works with any collisions model,
  so the data can be checked before the flank contacts act on it.
- The zone of a switch walks both ways of every switch it runs onto from
  the points (flank::ZoneReach(), a ladder), up to the fouling distance plus
  the 30 m margin. Before it took way 0 only, so a vehicle on the diverging
  way of the next switch of a ladder was outside the zone.
- The editor's track observer (tracks_committed, track_split) marks the
  zones stale (vehicle_table::tracks_changed()), so a switch moved,
  reshaped, reconnected or retired in place gets its zone made anew at the
  next update; before only an added rail track did that.
- docs/behaviour-changes.md: the entry of the flank contacts.

Unit test: the ladder walk (both ways of the next switch, the limit, a loop
walked once).
2026-12-04 19:50:07 +01:00
..