mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-11-02 11:39:14 +01:00
refactor(track): what goes with unevenness in one place, readable
The rules stay in TrackUneven.h with no dependence on the engine, as they can be tested. Their use on the tracks moves out of Track.cpp to TrackUneven.cpp, split into steps: the group of switches, the values of its paths, the meeting of two ends. One set of helpers for the paths of a track takes the place of the same conditions written out in several places, and the value at the ends of a switch is worked out in one place. The clatter of an axle leaves the long Update of a vehicle. The fields in the editor say themselves when they show. No change in behaviour.
This commit is contained in:
@@ -96,6 +96,7 @@ set(SOURCES
|
||||
"model/Texture.cpp"
|
||||
"utilities/Timer.cpp"
|
||||
"world/Track.cpp"
|
||||
"world/TrackUneven.cpp"
|
||||
"world/Road.cpp"
|
||||
"world/Sweep.cpp"
|
||||
"world/RoadPoint.cpp"
|
||||
|
||||
Reference in New Issue
Block a user