Vindicta
Vindicta copied to clipboard
Added Random Weather
After cracking my brain on how SQF worked, I managed to whip up this simple script that's able to change the mission's weather. It also does this over time giving the game a less static environment. I like the sun, but cloudy weather is also nice sometimes!
That's definitely a step in the right direction, as we didn't have any 'weather system' in the mission before.
@Lazejun suggested that it would be nice to be able to disable this, and I think that we should really try to add a CBA settings option to enable/disable this. Here's a suggestion of how it might work:
- Add a global variable
gWeatherScriptwhich stores the handler of that spawned script. - At game start, spawn the script if the bool is enabled.
- When user enables it, spawn the script.
- When user disables it,
terminatethe script, and probably set some generic sunny weather. - Be super careful whenever you are about to
spawnthe script, because we don't want to spawn it twice. Therefore, ifgWeatherScriptis not null (for whatever reason), terminate the old one.