The following constants/macroes can be used by natives such as CreateExtraWeather, SetExtraWeatherParam_RGB, SetExtraWeatherParam_RGBA, and the like.
Now, it is important that you understand how the in-game timecycle works, as this page is written under the assumption that you do so.
See our Into TheTimecycle I - the fundamental concepts which make up the in-game atmosphere guide for more info.
Generally speaking, there are two kinds of weather parameters - those that are part of a colour set, and those which are attributes of the weather types itself. The latter can be set by CreateExtraWeather, SetExtreWeatherParam_Flags, and SetExtraWeatherParam_Windyness respectively.
Parameters part of a colour set
The following parameters are part of a colour set, and have to be set for each in-game hour.
RGB parameters can be set using SetExtraWeatherParam_RGB.
|The ambient colour used for static map objects (or "buildings" as R* calls them).
|The ambient colour used for dynamic map objects.
|Same as WEATHERPARAM_RGB_AMBIENT, however this value is only used when trails are enabled, and the weather handling type is set to WEATHER_HANDLING_GTAVC.
|Same as WEATHERPARAM_RGB_AMBIENT_OBJ, however this value is only used when trails are enabled, and the weather handling type is set to WEATHER_HANDLING_GTAVC.
|An RGB multiplier for the material colours. It is only used when the Leeds building pipeline is attached to a model (e.g. the VCS neons)
|The colour of the directional light.
|The top colour of the sky gradient.
|The bottom colour of the sky gradient.
|The colour of the D3D fog.
|The colour of the "core" of the sun.
|The colour of the "corona" of the sun.
|The colour of the low, thinly stretched clouds.
|The colour of the lower fluffy clouds. It is used for the San Andreas clouds if the weather is created with WEATHER_HANDLING_DEFAULT, and is used for fluffy clouds if it is not.
|The colour of the upper fluffy clouds. The colour will be ignored if the handling type is set to WEATHER_HANDLING_DEFAULT.
RGBA parameters can be set using SetExtraWeatherParam_RGBA. It should be noted that the alpha component is a float, while the RGB components are integers.
|The colour of the in-game water.
|The colour of the primary postfx filter colour.
|The colour of the secondary postfx filter colour.
Integer parameters can be set using SetExtraWeatherParam_Int.
|Generic shadow strength (used everywhere except where the other shadow strength fields are used). The value can be anything between 0 and 255.
|Intensity for player shadows (CShadows::RenderExtraPlayerShadows). The name is from timecyc.dat, and is of course quite misleading. The value can be anything between 0 and 255.
|Pole shadow strength (used only for lamppost1, lamppost2, lamppost3, doublestreetlght1, and vgsstriptlights1). The value can be anything between 0 and 255.
|The intensity of the water fog effect. Setting this to 255 will be great for a typical lighthouse scene at night, with lots of fog everywhere.
|The radiosity intensity. It will be ignored unless VCS postfx is used. The value can be anything between 0 and 255. (6)
|The intensity limit for the radiosity effect. The value can be anything between 0 and 255. (6)
Float parameters can be set using SetExtraWeatherParam_Float.
|The size of the in-game sun.
|The size of 2dfx coronas.
|The brightness of 2dfx coronas.
|The far clipping distance.
|The distance at which fog will start appearing (not related to D3D fog). It is used for the fogging distance on the world camera:
|Brightness multiplier for pointlights.
|An auxiliary multiplier for the ambient RGB colours which makes the game world darker at nighttime. It is ony used when your extra weather uses WEATHER_HANDLING_BULLY as its interpreting type. Interestingly enough, a value of 1.0 should be used at daytime.
|The transparency of the GTA: SA cloud layer. Setting this to 0.0 if you aren't working with GTA: SA weather data is recommended.
|The blurring offset for the GTA: VCS trails. It is ignored unless the weather handling type is set to WEATHER_HANDLING_GTAVCS and the colour filter to COLOURFILTER_LEEDS.
Parameters part of the weather type itself
The following parameters are part of the weather type itself (and affect how colour set parameters are used).
Weather handling types
The weather handling type is assigned to a weather type when creating it through CreateExtraWeather. Weather handling types are used to tell the game how to interpret the weather data (as-in, which 3D era game).
|Interpret the data as GTA:SA data.
|Interpret the data as GTA:III data.
|Interpret the data as GTA:VC data.
|Interpret the data as GTA:LCS data.
|Interpret the data as GTA:VCS data.
|Interpret the data as Bully:SE data.
Weather (base) types
The weather (base) type is assigned to a weather type when creating it through CreateExtraWeather. Weather (base) types should not be confused with weather types. The following constants tell the game if the weather type is rainy, foggy, sunny, snowy, and so on. This means they can not be used by SetWeather and SetPlayerWeather.
|The "default" weather (base) type. It should be used for sunny weather.
|The created weather type is a rainy weather type. There will be lightning, heavy rainfall, road reflections, decreased traction, cars turning on their headlights, and San Andreas radio DJs will comment about stormy/rainy weather.
|The created weather type is a cloudy weather type. It does not have any effect, but we still recommend using it should this change in the future (assuming we will be able to keep working on this mod).
|The created weather type is a foggy weather type. Moving fog will be visible, and San Andreas radio DJs will comment about foggy weather.
|The created weather type is a hurricane. It is pretty much the same as WEATHERTYPE_RAINY. Hurricane weather types exist in GTA: VC and GTA: VCS (leftovers can be found on Bully: SE and GTA: LCS) and behave in the same manner. On GTA: UG, all hurricane weathers use WEATHERTYPE_HURRICANE, and so should you.
|It will start snowing once used. Like WEATHERTYPE_RAINY, there will be reduced traction and cars will turn on their headlights. (1)
|Like WEATHERTYPE_HURRICANE, it does not really differ from WEATHERTYPE_SNOWY. Only Bully's snowstorm weather type uses this. (1)
|The created weather type is a sandstorm weather type. Brown moving fog will appear, and San Andreas radio DJs will comment about the sandstorm(s).
Colour filter types
The colour filter type is assigned to a weather type when creating it through CreateExtraWeather. Pretty much all 3D era games use a colour filter. All of them take the values from WEATHERPARAM_RGBA_POSTFX1 (WEATHERPARAM_RGBA_POSTFX2 for SA) as input. The colour used is calculated for each pixel on the screen, and the calculation method differs for each colour filter type. Some use a pixel shader, while others do not.
|No colour filter will be drawn.
|The "default" colour filter. It should NOT be confused with COLOURFILTER_SA. (2)
|The colour filter used in GTA: III. (3)
|The colour filter used in GTA: VC. (3) (4)
|The colour filter used in GTA: SA (and in GTA: UG on San Andreas weather types).
|The colour filter used in GTA: LCS and GTA: VCS. (5)
Flags can be set using SetExtraWeatherParam_Flags. You can combine multiple flags (it is a bitfield).
|Enables a heat haze effect at daytime.
|Enables a sunglare effect. In Vice City, it is visible on vehicles, while it can also be seen on the in-game water.
|If this flag is set, clouds will not appear. This is typically used to separate SUNNY weather types from EXTRASUNNY types.
|Whether or not this weather is an 'extra sunny' weather type. It is only (indirectly) used for the thin, low clouds and the fluffy clouds which can be enabled/disabled through ToggleLowClouds and ToggleFluffyClouds.
|Allows this weather to create rainbows. This flag is typically set if the weather type is either rainy or sunny.
|An unknown effect from GTA: VC which is present on EXTRASUNNY_MIAMI.
- (1): If you set the wind speed to 0.0, snow will behave like it does in GTA: LCS. If you start increasing the wind speed, it will behave less and less like it does in GTA: LCS, and snowflakes will be affected more and more by the in-game wind speed and direction.
(2): The "default" colour filter is labeled as such for the following reasons:
- It is the most basic colour filter. It uses a pixel shader which blends the source colour with the interpolated WEATHERPARAM_RGBA_POSTFX1 value.
- Using COLOURFILTER_DEFAULT on a GTA: VC weather should give you the same results as COLOURFILTER_VC, but the trails option will be ignored.
- Using COLOURFILTER_DEFAULT on a Leeds (GTA:VCS/GTA:LCS) weather should give you the same results as COLOURFILTER_LEEDS, but the trails option will be ignored.
- (3): Once used, trails can be enabled/disabled in the pause menu.
- (4): Bully weather currently uses COLOURFILTER_VC as well, however they currently look very obnoxious. We still need to find a proper solution (it is not a bug!!), which may or may not result in changes to the weather parameters or even the natives themselves in a future update.
- (5): You should use this on Leeds (GTA:VCS/GTA:LCS) weather types. GTA:VCS has custom radiosity and trails, while GTA:LCS does not. See note (6) to find out how to disable it.
- (6): GTA: SA and GTA: VCS both have a radiosity effect. You can disable it by setting WEATHERPARAM_INT_RADIOSITYINT to 0, and WEATHERPARAM_INT_RADIOSITYINTLIMIT to 255. This method may change in a future update (assuming we will be able to keep working on this mod).