diff --git a/McZapkie/MOVER.h b/McZapkie/MOVER.h index 4cc866b4..13be3c19 100644 --- a/McZapkie/MOVER.h +++ b/McZapkie/MOVER.h @@ -1465,7 +1465,8 @@ class TMoverParameters { float temp_min{-1}; // lowest accepted temperature float temp_max{-1}; // highest accepted temperature - } config; + }; + heater_config_t config; // ld inputs bool breaker{false}; // device is allowed to operate bool is_enabled{false}; // device is requested to operate @@ -1500,12 +1501,17 @@ class TMoverParameters float temp_cooling{-1}; // active cooling activation point float temp_flow{-1}; // fluid flow activation point bool shutters{false}; // the radiator has shutters to assist the cooling - } config; + }; + circuit_config_t config; bool is_cold{false}; // fluid is too cold bool is_warm{false}; // fluid is too hot bool is_hot{false}; // fluid temperature crossed cooling threshold bool is_flowing{false}; // fluid is being pushed through the circuit - } water, water_aux, oil, engine; + }; + fluid_circuit_t water; + fluid_circuit_t water_aux; + fluid_circuit_t oil; + fluid_circuit_t engine; // output, state of affected devices bool PA{false}; // malfunction flag float rpmw{0.0}; // current main circuit fan revolutions diff --git a/global_include/interfaces/IMaterial.h b/global_include/interfaces/IMaterial.h index 92a8043e..c6f3d123 100644 --- a/global_include/interfaces/IMaterial.h +++ b/global_include/interfaces/IMaterial.h @@ -19,7 +19,7 @@ struct IMaterial virtual texture_handle GetTexture(int slot) const = 0; static IMaterial *null_material() { - static struct NullMaterial : public IMaterial + struct NullMaterial : public IMaterial { void finalize(bool Loadnow) override { /* null implementation, nothing to do */ } bool update() override @@ -54,7 +54,8 @@ struct IMaterial { return 0; } - } null_material{}; + }; + static NullMaterial null_material{}; return &null_material; } virtual ~IMaterial() = default; diff --git a/global_include/interfaces/ITexture.h b/global_include/interfaces/ITexture.h index 187d99b1..ce123829 100644 --- a/global_include/interfaces/ITexture.h +++ b/global_include/interfaces/ITexture.h @@ -23,7 +23,7 @@ struct ITexture virtual void update_from_memory(size_t width, size_t height, const uint8_t *data) = 0; static ITexture *null_texture() { - static struct NullTexture : public ITexture + struct NullTexture : public ITexture { bool create(bool Static = false) override { @@ -70,7 +70,8 @@ struct ITexture void set_components_hint(int hint) override { /* null implementation, nothing to do */ } void make_from_memory(size_t width, size_t height, const uint8_t *data) override { /* null implementation, nothing to do */ } void update_from_memory(size_t width, size_t height, const uint8_t *data) override { /* null implementation, nothing to do */ } - } null_texture{}; + }; + static NullTexture null_texture{}; return &null_texture; } virtual ~ITexture() = default; diff --git a/simulation/simulationtime.cpp b/simulation/simulationtime.cpp index 0ab60d46..ec4892a8 100644 --- a/simulation/simulationtime.cpp +++ b/simulation/simulationtime.cpp @@ -67,7 +67,8 @@ scenario_time::init(std::time_t timestamp) { long DaylightBias; SYSTEMTIME StandardDate; SYSTEMTIME DaylightDate; - } timezoneinfo = { -60, 0, -60, { 0, 10, 0, 5, 3, 0, 0, 0 }, { 0, 3, 0, 5, 2, 0, 0, 0 } }; + }; + registry_time_zone_info timezoneinfo = { -60, 0, -60, { 0, 10, 0, 5, 3, 0, 0, 0 }, { 0, 3, 0, 5, 2, 0, 0, 0 } }; convert_transition_time( timezoneinfo.StandardDate ); convert_transition_time( timezoneinfo.DaylightDate ); diff --git a/widgets/map_objects.h b/widgets/map_objects.h index 7dfc2bbb..3754a146 100644 --- a/widgets/map_objects.h +++ b/widgets/map_objects.h @@ -45,7 +45,8 @@ struct launcher : public map_object enum type_e { track_switch, level_crossing - } type; + }; + type_e type; gfx::basic_vertex vertex() override { return gfx::basic_vertex(location, glm::vec3(),