Multi-modal mobility for rustsim.
This crate is the glue layer that lets pedestrians, cyclists, cars, taxis, buses, trains, and lifts participate in the same simulation without any one domain crate having to know about the others.
It provides:
- [
leg] — a trip broken into per-mode legs with waypoints in 2-D or 3-D. - [
mode_state] — a deterministic state machine that advances a traveller through their legs (walk → board → ride → alight → walk → drive → park → walk → …). - [
obstacle] — a shared [Obstacle] trait every domain can implement, so crowd models can see vehicles and vehicles can see crowd clusters. - [
router] — a multi-modal Dijkstra over mode-tagged graphs, with construction helpers forrustsim-trafficlink metadata. - [
policy] — cross-domain queue, dispatch, dwell, and control policy contracts re-exported for multimodal orchestration.
The crate is deliberately small and opinionated — it is not a full MATSim/SUMO replacement, it is the engineering contract that keeps domain crates decoupled while still allowing them to interact.