mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-10-30 23:40:29 +01:00
Sieć trakcyjna: przęsła wg typów sieci, wysięgniki z katalogu, bramki, kotwienia i edytor sieci
Sam kod exe z gałęzi siec-trakcyjna (bez testów, notatek i danych z tests/catenary). Dane (data/traction_*.txt) leżą poza repozytorium. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019Tqn7T8D1Gx3ptKtZgNtX5
This commit is contained in:
@@ -19,6 +19,7 @@ http://mozilla.org/MPL/2.0/.
|
||||
#include "vehicle/Driver.h"
|
||||
#include "utilities/Logs.h"
|
||||
#include "utilities/utilities.h"
|
||||
#include "world/catenary_span.h"
|
||||
#include "Console.h"
|
||||
#include "scripting/PyInt.h"
|
||||
#include "utilities/Timer.h"
|
||||
@@ -590,6 +591,20 @@ bool global_settings::ConfigParseSimulation(cParser& Parser, const std::string&
|
||||
return true;
|
||||
}
|
||||
|
||||
if (token == "catenary.procedural")
|
||||
{
|
||||
ParseOne(Parser, CatenaryProcedural);
|
||||
return true;
|
||||
}
|
||||
|
||||
if (token == "catenary.solidrange")
|
||||
{
|
||||
// zasięg rysowania przewodów sieci trakcyjnej jako brył [m]; 0 wyłącza
|
||||
ParseOne(Parser, CatenarySettings.solid_range);
|
||||
CatenarySettings.solid_range = std::clamp(CatenarySettings.solid_range, 0.f, 2000.f);
|
||||
return true;
|
||||
}
|
||||
|
||||
if (token == "splinefidelity")
|
||||
{
|
||||
float splinefidelity = 0.f;
|
||||
@@ -1624,6 +1639,8 @@ global_settings::export_as_text( std::ostream &Output ) const {
|
||||
export_as_text( Output, "gfx.smoke", Smoke );
|
||||
export_as_text( Output, "gfx.smoke.fidelity", SmokeFidelity );
|
||||
export_as_text( Output, "smoothtraction", bSmoothTraction );
|
||||
export_as_text( Output, "catenary.procedural", CatenaryProcedural );
|
||||
export_as_text( Output, "catenary.solidrange", CatenarySettings.solid_range );
|
||||
export_as_text( Output, "splinefidelity", SplineFidelity );
|
||||
export_as_text( Output, "sleeperdistance", SleeperDistance );
|
||||
export_as_text( Output, "rendercab", render_cab );
|
||||
|
||||
Reference in New Issue
Block a user