diff --git a/addons/weather/functions/fnc_updateWeather.sqf b/addons/weather/functions/fnc_updateWeather.sqf index b5495d67c5..d7f629147d 100644 --- a/addons/weather/functions/fnc_updateWeather.sqf +++ b/addons/weather/functions/fnc_updateWeather.sqf @@ -20,8 +20,8 @@ missionNamespace setVariable [QGVAR(currentOvercast), overcast, true]; [] call FUNC(updateTemperature); [] call FUNC(updateHumidity); -// Wind simulation -if (GVAR(windSimulation) && CBA_missionTime > GVAR(next_wind_udpate)) then { +// Wind simulation, take API for temporarily disabling into account along with setting +if (GVAR(windSimulation) && {!(missionNamespace getVariable [QGVAR(disableWindSimulation), false])} && {CBA_missionTime > GVAR(next_wind_udpate)}) then { GVAR(current_wind_direction) = GVAR(next_wind_direction); GVAR(current_wind_speed) = GVAR(next_wind_speed); diff --git a/addons/weather/functions/fnc_updateWind.sqf b/addons/weather/functions/fnc_updateWind.sqf index 0a821b19c0..af3d414a18 100644 --- a/addons/weather/functions/fnc_updateWind.sqf +++ b/addons/weather/functions/fnc_updateWind.sqf @@ -15,6 +15,9 @@ * Public: No */ +// Public API to temporarily disable wind simulation +if (missionNamespace getVariable [QGVAR(disableWindSimulation), false]) exitWith {}; + private _speed = linearConversion [GVAR(last_wind_update), GVAR(next_wind_udpate), CBA_missionTime, GVAR(current_wind_speed), GVAR(next_wind_speed), true]; private _direction = linearConversion [GVAR(last_wind_update), GVAR(next_wind_udpate), CBA_missionTime, GVAR(current_wind_direction), GVAR(next_wind_direction), true]; diff --git a/docs/wiki/framework/weather-framework.md b/docs/wiki/framework/weather-framework.md index 4c42ef6ab2..3abdc9d247 100644 --- a/docs/wiki/framework/weather-framework.md +++ b/docs/wiki/framework/weather-framework.md @@ -19,3 +19,10 @@ ACE3 Weather extends the existing weather by temperature, humidity and air press The additional wind simulation, which is also influenced by the season and the geographical location, can be deactivated if necessary. Cloud cover, rain and fog can still be set via the mission settings. + + +## 2. Wind Simulation + +## 2.1 Temporarily Pause Wind Simulation + +When Wind Simulation is enabled at mission start, it can be temporarily disabled by setting `ace_weather_disableWindSimulation = true`. To reenable wind simulation, the variable must either be set to `false` or `nil`. \ No newline at end of file