17
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-10-20 23:23:30 +02:00

feat(editor): a scenery begun from nothing is asked for its terrain as the first track is laid

With the lay tool on, a scenery with no tracks nor terrain chunks gets the offer of the terrain model and the aerial photos
around the camera; without a place yet it asks for the PUWG 1992 coordinates of this point, as geoportal.gov.pl gives them,
and keeps them as the place of its orthophoto. The offer can be turned off (editor setting terrain_offer). Self-test
nmtoffer.
This commit is contained in:
maj00r
2026-10-18 13:02:01 +02:00
parent 5af699fba4
commit 5a00d88be9
7 changed files with 129 additions and 0 deletions

View File

@@ -104,6 +104,8 @@ bool editorSettings::load()
parse(value, m_palette);
else if (key == "first_steps")
m_first_steps = (value == "1");
else if (key == "terrain_offer")
m_terrain_offer = (value == "1");
else if (key == "track_tools_all")
m_track_tools_more = (value == "1");
else if (key.rfind(origin_prefix, 0) == 0)
@@ -150,6 +152,7 @@ bool editorSettings::save()
stream << "nodebank_card " << m_nodebank_card << "\n";
stream << "colours " << m_palette << "\n";
stream << "first_steps " << (m_first_steps ? 1 : 0) << "\n";
stream << "terrain_offer " << (m_terrain_offer ? 1 : 0) << "\n";
stream << "track_tools_all " << (m_track_tools_more ? 1 : 0) << "\n";
stream << std::fixed << std::setprecision(3);
for (auto const &origin : m_orthophoto_origins)