[EXPERIMENTAL] Load and Save Mastersplines

Discussion in 'World Editor' started by AlexKidd71, Dec 14, 2025.

  1. AlexKidd71

    AlexKidd71
    Expand Collapse

    Joined:
    Mar 16, 2022
    Messages:
    824
    I’ve made an experimental mod for saving and loading Masterspline settings in the Masterspline Tool.

    It is based on the current 0.38.2 version and will almost certainly break the whole masterspline functionality with any hotfixes or updates affecting the masterspline feature. Then just delete the mod from mods folder.

    The mod saves all your Mastersplines from the current session (along with all linked splines) to a JSON file. The hardest part was preventing duplicates in the Scene Tree when reloading the file in a new session, but I managed to get it working—even with the quirky decals.

    Important: Don't rename the folders in the scenetree (at least the guids have to stay) because the matching of the splines saved in json is done with that. It is no problem to move the folders to another folder.

    More details can be found in the README file inside the zip. Just put the zip in your mods folder. Testers are welcome!

    @Dave_ It would be great if you could take a look at the code and make a small review. Perhaps my ideas may be a good starting point if you plan to add a load/save feature to the official BeamNG codebase. I have included an implementation description in the zip file as well.

    why I do all these efforts is explained here:
    https://www.beamng.com/threads/building-real-life-maps-in-beamng-sneak-preview.107781/
    It’s a part of something bigger I currently work on.



    Update 2025/29/12
    Added toggle button to mastersplinetool which toggles the visibility between all mastersplines or only the selected one.
     

    Attached Files:

    #1 AlexKidd71, Dec 14, 2025
    Last edited: Dec 29, 2025
    • Like Like x 4
  2. SPittlebug

    SPittlebug
    Expand Collapse

    Joined:
    May 14, 2023
    Messages:
    147
    thats awesome! saving the splines would be a great help for my workflow.. will try this out asap and get back with some feedback!
     
    • Like Like x 3
  3. AlexKidd71

    AlexKidd71
    Expand Collapse

    Joined:
    Mar 16, 2022
    Messages:
    824
    That would be nice. No one else tested it up to now.
     
  4. AlexKidd71

    AlexKidd71
    Expand Collapse

    Joined:
    Mar 16, 2022
    Messages:
    824
    With a lot of mastersplines the performance gets very bad. I decided to add a toggle button for either render/show all splines or only the selected one.
    All:
    upload_2025-12-29_0-13-11.png
    Only selected:
    upload_2025-12-29_0-14-30.png
     
    • Like Like x 2
  5. SPittlebug

    SPittlebug
    Expand Collapse

    Joined:
    May 14, 2023
    Messages:
    147
    have been using this a few times and it's great! it really should be there by default!
    thanks for making this and allowing us to go and sleep without having sweaty nightmares of unfished roads! :)
     
    • Like Like x 1
    • Agree Agree x 1
  6. verymoko

    verymoko
    Expand Collapse

    Joined:
    Apr 4, 2023
    Messages:
    14
    Thanks a lot! Very nice, very helpful. So strange, that it's not the standart feature.

    Somehow forest and biome tools crash the game, and I lost my 2 hours progress with Master Spline. Stock saving method works odd, so I went here to find help.

    My game crashed again, but your mod saved my progress! Also I noticed, it saves Linked roads and their properties — ❤️❤️❤️!
     
    • Like Like x 1
  7. AlexKidd71

    AlexKidd71
    Expand Collapse

    Joined:
    Mar 16, 2022
    Messages:
    824
    That was the idea: To save all the related linked splines. It was a tough one for the decal spline because decals are not really splines, haha. Nice that it works for you. It's not perfectly debugged but if I find the time I will do some additions.
     
  8. SilvanCR

    SilvanCR
    Expand Collapse

    Joined:
    Feb 27, 2026
    Messages:
    4
    Hello, first of all thank you so much for creating this mod and making it free for everyone to use. I just wanted to see if there was something you could help me with, my hometown does not have very accurate data and for some reason it shows parts of the ocean as being -25000m on the coast, which I believe is the cause for some issues ive been encountering, does anyone know how I could fix this? Or perhaps add a function to exclude certain elevations? Such as an option to select a minimum and maximum elevation? When I tried changing the values in base height and maximum height to try and eliminate this problem it generated a flat map. Additionally, I am not sure if this is possible but if I could rotate the selection on the map, such as choosing a diagonal box, this would also solve my problem. Thanks again
     
  9. AlexKidd71

    AlexKidd71
    Expand Collapse

    Joined:
    Mar 16, 2022
    Messages:
    824
    I should test it. Can you send me the coordinates and the service you downloaded the geotiff?
     
  10. SilvanCR

    SilvanCR
    Expand Collapse

    Joined:
    Feb 27, 2026
    Messages:
    4
    Hello, we talked a bit on YouTube, the coordinates are SW: 9.897705°, -85.678249° NE: 9.971543°, -85.603774° Center: 9.934624°, -85.641011°. I did manage to fix the issue already though by opening the tif file in QGIS and running this equation in the raster calculator: ("YourLayer@1" >= 0) * "YourLayer@1". This set all the negative values to zero. Perhaps it would be possible to add this as a feature into your program? In any case it is no problem, since its quick and easy to do in QGIS but maybe it will help some other people who do not know how to use QGIS.
     
    • Like Like x 1
  11. Pivou

    Pivou
    Expand Collapse

    Joined:
    Nov 16, 2025
    Messages:
    8
    I’ve been working with the mod for quite a while now and wonder why it still isn't included in the MasterSpline tool by default.
    The only issue I’m encountering is that the decal road splines get duplicated whenever I reload the MasterSpline (after having moved them into a folder).

    Anyway, thank you Alex for this useful Tool!
     
    • Like Like x 1
  12. AlexKidd71

    AlexKidd71
    Expand Collapse

    Joined:
    Mar 16, 2022
    Messages:
    824
    I didn’t work on the mod after my first shot. There is room for improvement. If the devs don’t change the functionality in 0.39 I will spend some hours on it.
     
    • Like Like x 1
  13. Pivou

    Pivou
    Expand Collapse

    Joined:
    Nov 16, 2025
    Messages:
    8
    That's great to hear! And yes, better wait for 0.39 (I wish they would add your mod as default, as it is so useful) Have a nice time in Bretagne!
     
    #13 Pivou, Jun 20, 2026
    Last edited: Jun 20, 2026
    • Like Like x 1
    • Agree Agree x 1
  14. AlexKidd71

    AlexKidd71
    Expand Collapse

    Joined:
    Mar 16, 2022
    Messages:
    824
    We must definitely do a meet and greet in Berlin.
     
    • Like Like x 1
  15. Pivou

    Pivou
    Expand Collapse

    Joined:
    Nov 16, 2025
    Messages:
    8
    Yes, we can certainly do that sometime.
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice