17
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-11-09 02:50:59 +01:00

feat(editor): buttons in the switch tool setting a model of timbers on all the switches and crossings of the scenery at once, one for each model of timbers of the scenery data and one for the model of eu07.ini, in one step of the undo; the selftest switchtimbers does the same

(cherry picked from commit 81a6b855d0)
This commit is contained in:
maj00r
2026-10-24 01:40:47 +02:00
parent a83d5c6978
commit 36904c2815
5 changed files with 180 additions and 0 deletions

View File

@@ -324,6 +324,15 @@ editor_mode::selftest_result editor_mode::selftest_rails(std::string const &comm
WriteLog(format("SELFTEST geom total: tracks %d, vertices %zu, hash %016llx, exact %016llx", tracks, vertices, static_cast<unsigned long long>(total), static_cast<unsigned long long>(exacttotal)));
return selftest_result::handled;
}
if (command == "switchtimbers")
{
std::string model;
words >> model;
if (model == "none")
model.clear();
WriteLog(format("SELFTEST switchtimbers %s: %zu tracks", model.c_str(), set_switch_timbers(model)));
return selftest_result::handled;
}
if (command == "frogkey")
{
std::string name, value;