dynamic weather not being dynamic (aka sunny times 24/7)

Zeehond23

Valued Member!
Hi,

For some time now I've been trying to get dynamic weather working on my namalsk 0.75 server.
I've removed these lines from the antihack
Code:
    drn_fnc_DynamicWeather_SetWeatherLocal = {};
    if (isNil 'dayzSetOvercast') then {dayzSetOvercast = 0;};
    if (!isNil 'dayzSetOvercast') then {0 setOvercast dayzSetOvercast;};
    if (!isNil 'dayzSetViewDistance') then {setViewDistance dayzSetViewDistance;};
    if (!isNil 'infiSTAR_SetDate') then {setDate infiSTAR_SetDate;};

and set up my dynamic weather like this:

Code:
private ["_initialFog", "_initialOvercast", "_initialRain","_initialSnow", "_initialWind", "_debug"];
private ["_minWeatherChangeTimeMin", "_maxWeatherChangeTimeMin", "_minTimeBetweenWeatherChangesMin", "_maxTimeBetweenWeatherChangesMin", "_rainIntervalRainProbability", "_snowIntervalSnowProbability", "_windChangeProbability"];
private ["_minimumFog", "_maximumFog", "_minimumOvercast", "_maximumOvercast", "_minimumRain", "_maximumRain", "_minimumSnow", "_maximumSnow", "_minimumWind", "_maximumWind", "_minRainIntervalTimeMin", "_maxRainIntervalTimeMin", "_forceRainToStopAfterOneRainInterval", "_maxWind"];

if (isNil "_this") then { _this = []; };
if (count _this > 0) then { _initialFog = _this select 0; } else { _initialFog = -1; };
if (count _this > 1) then { _initialOvercast = _this select 1; } else { _initialOvercast = -1; };
if (count _this > 2) then { _initialRain = _this select 2; } else { _initialRain = -1; };
if (count _this > 3) then { _initialSnow = _this select 3; } else { _initialSnow = -1; };
if (count _this > 4) then { _initialWind = _this select 4; } else { _initialWind = [-1, -1]; };
if (count _this > 5) then { _debug = _this select 5; } else { _debug = false; };

///////////////////////////////////////////////////////////////////////////////////////////////////////////////
// The following variables can be changed to tweak weather behaviour

// Minimum time in minutes for the weather (fog and overcast) to change. Must be greater than or equal to 1 and less than or equal to
// _maxWeatherChangeTimeMin. When weather changes, it is fog OR overcast that changes, not both at the same time. (Suggested value: 10).
_minWeatherChangeTimeMin = 10;

// Maximum time in minutes for the weather (fog and overcast) to change. Must be greater than or equal to _minWeatherChangeTimeMin.
// (Suggested value: 20).
_maxWeatherChangeTimeMin = 30;

// Minimum time in minutes that weather (fog and overcast) stays constant between weather changes. Must be less than or equal to 0 and
// greater than or equal to _minWeatherChangeTimeMin. (Suggested value: 5).
_minTimeBetweenWeatherChangesMin = 5;

// Maximum time in minutes that weather (fog and overcast) stays unchanged between weather changes. Must be greater than or equal to
// _minWeatherChangeTimeMin. (Suggested value: 10).
_maxTimeBetweenWeatherChangesMin = 10;

// Fog intensity never falls below this value. Must be between 0 and 1 and less than or equal to _maximumFog
// (0 = no fog, 1 = pea soup). (Suggested value: 0).
_minimumFog = 0.5;

// Fog intensity never exceeds this value. Must be between 0 and 1 and greater than or equal to _minimumFog
// (0 = no fog, 1 = pea soup). (Suggested value: 0.8).
_maximumFog = 1;

// Overcast intensity never falls below this value. Must be between 0 and 1 and less than or equal to _maximumOvercast
// (0 = no overcast, 1 = maximum overcast). (Suggested value: 0).
_minimumOvercast = 0.8;

// Overcast intensity never exceeds this value. Must be between 0 and 1 and greater than or equal to _minimumOvercast
// (0 = no overcast, 1 = maximum overcast). (Suggested value: 1).
_maximumOvercast = 1;

// When raining, rain intensity never falls below this value. Must be between 0 and 1 and less than or equal to _maximumRain
// (0 = no rain, 1 = maximum rain intensity). (Suggested value: 0);
_minimumRain = 0;

// When raining, rain intensity never exceeds this value. Must be between 0 and 1 and greater than or equal to _minimumRain
// (0 = no rain, 1 = maximum rain intensity). (Suggested value: 0.8);
_maximumRain = 0.8;

// When snow fall, snow intensity never falls below this value. Must be between 0 and 1 and less than or equal to _maximumSnow
// (0 = no snow, 1 = maximum snow intensity). (Suggested value: 0);
_minimumSnow = 0;

// When snow fall, snow intensity never exceeds this value. Must be between 0 and 1 and greater than or equal to _minimumSnow
// (0 = no snow, 1 = maximum snow intensity). (Suggested value: 0.8);
_maximumSnow = 0.3;

// Wind vector strength never falls below this value. Must be greater or equal to 0 and less than or equal to _maximumWind.
// (Suggested value: 0);
_minimumWind = 0;

// Wind vector strength never exceeds this value. Must be greater or equal to 0 and greater than or equal to _minimumWind.
// (Suggested value: 8).
_maximumWind = 8;

// Probability in percent for wind to change when weather changes. If set to 0 then wind will never change. If set to 100 then rain will
// change every time the weather (fog or overcast) start to change. (Suggested value: 25);
_windChangeProbability = 25;

// A "rain interval" is defined as "a time interval during which it may rain in any intensity (or it may not rain at all)". When overcast
// goes above 0.75, a chain of rain intervals (defined below) is started. It cycles on until overcast falls below 0.75. At overcast
// below 0.75 rain intervals never execute (thus it cannot rain).

// Probability in percent (0-100) for rain to start at every rain interval. Set this to 0 if you don't want rain at all. Set this to 100
// if you want it to rain constantly when overcast is greater than 0.75. In short: if you think that it generally rains to often then
// lower this value and vice versa. (Suggested value: 50).
_rainIntervalRainProbability = 30;
_snowIntervalSnowProbability = 10;

// Minimum time in minutes for rain intervals. Must be greater or equal to 0 and less than or equal to _maxRainIntervalTimeMin.
// (Suggested value: 0).
_minRainIntervalTimeMin = 0;

// Maximum time in minutes for rain intervals. Must be greater than or equal to _minRainIntervalTimeMin. (Suggested value:
// (_maxWeatherChangeTimeMin + _maxTimeBetweenWeatherChangesMin) / 2).
_maxRainIntervalTimeMin = (_maxWeatherChangeTimeMin + _maxTimeBetweenWeatherChangesMin) / 2;

// If set to true, then the rain is forced to stop after one rain interval during which it has rained (use this for example if you only want
// small occational cloudbursts ). If set to false, then the rain may stop, but it may also just change intensity for an
// immedeate new rain interval. (Suggested value: false).
_forceRainToStopAfterOneRainInterval = false;
(not changed anything beyond this point)


I've tried turning off the AH but that didn't change a thing.

My compiles is calling the file no problemo
Code:
player_spawnCheck =            compile preprocessFileLineNumbers "loot\player_spawnCheck.sqf";
building_spawnLoot =        compile preprocessFileLineNumbers "loot\building_spawnLoot.sqf";
  spawn_loot =                compile preprocessFileLineNumbers "loot\spawn_loot.sqf";
   player_useMeds =            compile preprocessFileLineNumbers "custom\player_useMeds.sqf";
    player_selectSlot =            compile preprocessFileLineNumbers "custom\ui_selectSlot.sqf";
   
    execVM "DynamicWeatherEffects.sqf";

I've even tried to run it form the init.sqf but to no avail.
Anyone know where I went wrong here?
 
Back
Top