Friends asked me if it would be possible to merge two routes which were made using completely different coordinates. One route uses real word Lat/Lon data MSTS map projection, the other route is placed somewhere else.
Here is the same palce in two routes. You can see that not only World Tile doesn't match, but even xyz coordinates. So, it would not be possible to merge them using the old ways of copying and pasting world files.


So, In two days I made new merging software using TSRE. It doesn't just copy files, but reads objects from second route and places them in a new place on a main route.
How does it work?
Merging routes.
1.
Find the same place in two routes and note both coordinates of this place.
I decided to choose one of the junctions. It is best choice if you want to merge tracks nicely.


Convert Tile XY+xyz coordinates to xyz coordinates.
resultX = X*2048 + x
resultZ = Z*2048 + z
Calculate offset between these two points:
result = second route - main route
Result for X and Z values must be rounded, so it can be divided by 128. Using other values may result in a bad quality of merged terrain, but if you wish to retexture terrain anyway, you can ignore it.
For me it ended with -8448, 81.47992, -9600
2.
Place new line in settings.txt:
routeMergeString = second_route_dir:X:Y:Z
For me it is:
routeMergeString = Poznan- Olsztyn:-8448:81.47992:-9600
3.
Make sure that autoFix is disabled and loadAllWFiles is enabled in settings.txt first!
Run TSRE and select main route.
After some time and nice progress bars you should see the merged route:


As you can see, you can nicely merge routes regardless of it's coordinates.
Also you can see on the images above that routes must be prepared first before merging.
So, start from the beginning.
Preparing routes.
1. First you have to decide which signals and speedposts you want to keep if routes use different sigcfg.dat, speedpost.dat files.
When you decide:
Place new line in settings.txt:
objectsToRemove = signal:speedpost
Enable autoFix and loadAllWFiles.
Run the route you want to remove signals and speedposts.
When loading is finished, see Errors and Messages Window. Signals and Speedposts should be removed from route World Files and autoFix should fix all TDB errors related to this issue.

Save route and quit.
Paste choosen sigcfg.dat, sigscr.dat and speedpost.dat files into main route directory.
2. Now you have to decide which overlapping objects you want to keep.
When you decide, open route in TSRE where you want to clear overlapping area.
For multiple selection, select terrain patches using Shift + mouse and choose Select Objects" option.


Delete and repeat until you are satisfied with the result.
3. Use autoFix on both routes to remove broken objects before merging the routes.
4. Paste assets from Terrtex, Textures and Shapes directories from second route to the main route.
5. Merge routes using instructions above.

Now the result is much better.
6. You can use dynamic track Flex Tool to easy merge tracks from two routes:

7. New, merged route is ready to run in OR.

===
More work needs to be done, like merging ssource.dat, ttype.dat and .ref files. But it can be done by hand.
Tool will be available in next TSRE version.