17
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-10-20 19:37:44 +02:00
Commit Graph

8 Commits

Author SHA1 Message Date
maj00r
d25f20a56c feat(track): 3D sleepers and switch timbers, blade heel and throw from templates, one rail carving pass
- sleepers3d / sleepers3dplain / sleepers3dbed in eu07.ini: timbers put together from the begin, main and end parts of a model
  and stretched to their length, plain sleepers of their own model; tracks whose plain sleepers would touch are laid as one
  cluster, lines of timbers led by priority and turned to the bisectors of frogs and crossings at a limited rate, whole timbers
  under crossings, split ones between tracks with room to part them, gaps filled per rail and overlaps shortened or dropped;
  clusters worked out in a background thread while driving, on demand in the editor
- the ballast can be left out under the beams (sleepers3dbed no)
- blades get their heel and throw from the switch template or blades <heel> <throw> in the scenery; blades of double switches
  run on into the track linking them to the next switch
- rail cutting at frogs, wing rails, movable noses and switch crossings done by one carving pass (RailCarve)
- tint of the rail treads applied to the colour only, without the matte band at the frog
- a switch trailed through with a movable nose set the other way derails the vehicle
- self-tests: sleepercheck, sharedzones, beamsnear, throw, sleepersbg
2026-10-17 23:32:43 +02:00
maj00r
21eca4d9a6 fix(track): the tip of a blade is where the diverging track of the switch is broken into pieces near the start, as a template lays it from the scheme of the switch, so blades of 60E1 and 49E1 switches keep the cut tips of their tables at 1.248, 1.500, 2.165, 2.633 and 3.335 m and blades of S42 switches start at the end of their pre-blade stretch; without such a break a blade is told angled or tangent by its angle to the stock rail taken back to where it touches it, read from the nearest point of the other rail instead of its nearest sample, which took the blade of the main track of an S42-190-1:6,6 for a tangent one 2026-10-17 23:32:43 +02:00
maj00r
2c3ab90db5 fix(track): the tip of a blade lying tangent to its stock rail, as in 60E1 and 49E1 switches with cut tips, is where its theoretical arc gets 5 mm off the gauge face of the stock rail less the 125 mm the nose is planed over, instead of where it gets 3 mm off, so the tips lie 1.25, 1.60, 2.11, 2.63 and 3.34 m from the start of the switch at R190, 300, 500, 760 and 1200 as in the tables of these switches instead of 0.2 to 0.65 m nearer it; blades cutting into the stock rail at an angle, as in S42 switches, keep their tips 2026-10-17 23:32:43 +02:00
maj00r
513daa52cc merge feat/rail-crossings: the split rail code, mitred wide crossings, guard rail treads, check rail spacers and frogs for every rail profile, with the geometric switch blades moved into RailCrossings, their shape in track_rails::switch_blade and the lowering of the head in loft_span 2026-10-17 23:32:43 +02:00
maj00r
3307cb94e8 feat(track): frogs, crossings, guard rails with their castings and spacers, check rails and shared running surfaces for every rail profile again, not only for tracks without a profile, default, s60, uic60 and s39; grooved profiles keep their shared grooves without check rails 2026-10-17 23:29:08 +02:00
maj00r
306555a654 feat(track): a check rail is held to its running rail by spacer blocks every 0.5 m along its straight part, laid in the same way as the spacers of a guard rail at a wide crossing, below the head from the web of the running rail to the face of the check rail, so the flangeway stays open above them; a check rail replaced by a wing rail gets none; the spacing of spacers and castings is shared by guard rails and check rails 2026-10-17 23:29:08 +02:00
maj00r
697592c4aa refactor(track): the crossings of the rails are found in steps, the tracks nearby, the meeting of two rails with its refined place and the crossing made of it, and the crossings of the neighbours mapped on this track, and the check rails are planned, merged, kept clear of blocks and cut in separate functions instead of two long functions; path_count and path_neighbour replace the repeated choice of the paths and the ends of a switch or a plain track 2026-10-17 23:29:08 +02:00
maj00r
f67380f843 refactor(track): the rail code is split by concern into gauge lines, crossings and check rails, rail materials, rail profile measuring, planning the cuts and laying the geometry, instead of one TrackRails.cpp; rail_offset reuses nearest_distance and lateral; TTrack::rail_dimensions measures the profile through track_rails::measure_rail 2026-10-17 23:29:08 +02:00