Skip to content

Require every track to name a track type and rework menu run flow - #123

Merged
vanlueckn merged 1 commit into
mainfrom
t3code/investigate-mixed-track-modules
Sep 2, 2026
Merged

Require every track to name a track type and rework menu run flow#123
vanlueckn merged 1 commit into
mainfrom
t3code/investigate-mixed-track-modules

Conversation

@vanlueckn

Copy link
Copy Markdown
Collaborator

Summary

  • Breaking change: every track edge must now name a track type — there is no built-in type and no reserved "default" name. Modules that leave it out fail to compile with CompileError::MissingTrackType(<edge>), and the route editor's rule check reports the same before a run.
  • Track types from other mods are dependencies like any other and must be named in depends:.
  • The lay tool in the route editor arms itself with the first installed type, so newly drawn track carries one from the start.
  • Consumers of track_type_at (audio roughness/reverb, precipitation reverb) now handle the Option explicitly instead of assuming a default.
  • Docs updated (README, MODS.md, STATUS.md, screenshot skill) to describe the new requirement and the removed "default" name.

Testing

  • Run cargo test --workspace — expecting 1136 tests green, including i18n key parity checks.
  • Verify a mod line without track_type fails to compile with MissingTrackType.
  • Verify the route editor rule check flags edges naming no type.
  • Confirm the lay tool pre-assigns the first installed track type to new track sections.
  • Check audio roughness/reverb and precipitation behavior on edges with and without assigned types.
  • Screenshot pass of the route editor selection panel and map tinting: not run.

- remove the built-in default type and the reserved "default" name; an edge without track_type now fails to compile (CompileError::MissingTrackType) and is flagged by the rule check
- content built-ins, the OSM importer (--track-type) and the route editor's lay tool write example:hauptbahn as an authoring default
- track_type_at returns an Option; consumers fall back on welded-mainline roughness/reverb
@vanlueckn
vanlueckn force-pushed the t3code/investigate-mixed-track-modules branch from dd8ab2e to a775299 Compare September 2, 2026 15:50
@vanlueckn
vanlueckn merged commit 8212922 into main Sep 2, 2026
@vanlueckn
vanlueckn deleted the t3code/investigate-mixed-track-modules branch September 2, 2026 15:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant