13 static const UserSettings& get() {
return sInstance; }
15 uint32_t MaxGridCells{1u << 26};
16 uint64_t AgentTimeoutUSecs{0};
17 float AStarViaCostFactor{1.0f};
19 uint WindowSize[2]{1024, 768};
20 float PointSize{1.0f};
22 uint SidePaneWidth{256};
23 uint LockSteppingGranularity{0};
24 uint ActionDelayUSecs{0};
25 bool EnableRendering{
true};
27 bool GridLinesVisible{
false};
28 bool GridPointsVisible{
false};
29 bool FootprintsVisible{
false};
30 bool RatsNestVisible{
false};
31 bool TriangulationVisible{
false};
32 bool RoutePreview{
true};
36 float PerDisconnect{-5.0f};
37 float AnyDisconnect{0.0f};
44 static void LoadFile(
const std::string &path);
45 static void LoadJSON(
const std::string &json) { sInstance.loadJSON(json); }
46 void AddPath(
const std::string_view &s);
48 void sleepForActionDelay(uint times = 1)
const;
50 std::string str()
const;
52 static UserSettings& edit() {
return sInstance; }
56 void loadJSON(
const std::string &json);
58 static UserSettings sInstance;