Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improved weather parameters #209

Open
wants to merge 9 commits into
base: master
Choose a base branch
from
Open

Conversation

brndd
Copy link

@brndd brndd commented Jul 9, 2019

The current weather parameters from the env_parameters module don't actually seem to work. This is for numerous reasons:

  1. ACE wind overrides all the setWind etc. settings.
  2. setWindStr works as a multiplier on the total wind speed, same as the sliders in Environment settings do, but what it's actually multiplying is undefined. In practice the old "Violent storm" setting seemed to usually result in wind speeds of like 10 metres per second, which are far from a storm let alone a violent one.
  3. looks like there were only two reasons

I fixed this by making this parameter use the setWind command instead, which sets the wind to an absolute value. I also added a parameter for wind direction. Gusts didn't seem to do anything with setWind so there's no parameter for those.

I also added a parameter to enable/disable the ACE dynamic wind. Disabling it is necessary for the other two parameters to work. If ACE isn't installed in the first place, this parameter shouldn't do anything at all, but it will still show up. Don't know if there's any easy way to change this. This defaults to mission/server default.

setWind should be synced across clients (as per the Bohemia wiki) so this should work. Seemed to work fine on dedi but I could only test it with one player.

The change to start_in_vehicle's CfgFunctions.hpp is because Git wouldn't stop thinking there were modifications to that file until I committed it even though I had a completely fresh clone of the repo. Had something to do with the missing newline or something, I think.

1562647310670 1562651685537

@EM-Creations
Copy link

@brndd Would you have any objections to me including this in my fork of the framework?

@brndd
Copy link
Author

brndd commented Nov 16, 2019

It's implicitly MIT licensed so feel free to do whatever with it.

class StartInVehicle {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks like a purely formatting change, so maybe remove it from the pull request?

};
};

_wind = "Wind" call BIS_fnc_getParamValue;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In my fork's implementation I've called the "getParamValue" function using the alternative syntax (i.e. specifying a default value) just as a note if this gets merged into the Olsen Framework.

class Fog {
title = "Fog";
texts[] = {"Mission default", "No Fog", "Slightly Foggy", "Foggy", "Very Foggy", "Random"};
values[] = {-1, 0, 1, 2, 3, -10};
texts[] = {"Mission default", "No Fog", "Slightly Foggy", "Foggy", "Very Foggy"};

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did you intend to remove the functionality for random fog?

@@ -63,27 +63,19 @@ if (isMultiplayer) then {
0 setOvercast (_overcast / 10);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Towards the top of this file, _windDir should be declared as a private variable, as per the other parameters.

@EM-Creations
Copy link

Merged into The Bear Cave Framework here: https://github.com/EM-Creations/TheBearCave-Framework-ArmA-3/pull/18

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants