1
0
mirror of https://github.com/t-affeldt/regional_weather.git synced 2025-07-20 01:10:29 +02:00

Add new textures, tweak effects, add fog and freezing of river water

This commit is contained in:
Till Affeldt
2020-04-22 00:54:27 +02:00
parent e0b8d6d835
commit 32ab2c4d23
27 changed files with 223 additions and 65 deletions

View File

@ -1,5 +1,4 @@
local name = "regional_weather:ambient"
local CLOUD_SPEED = 1.8
local conditions = {}
@ -8,9 +7,9 @@ local function generate_effects(params)
local override = {}
local wind = climate_api.environment.get_wind()
local skybox = {}
local skybox = {priority = 0}
skybox.cloud_data = {
size = climate_api.utility.rangelim(params.humidity / 100, 0.25, 0.98),
density = climate_api.utility.rangelim(params.humidity / 100, 0.25, 0.98),
speed = vector.multiply(wind, CLOUD_SPEED),
thickness = climate_api.utility.rangelim(params.base_humidity * 0.2, 1, 18)
}
@ -18,7 +17,6 @@ local function generate_effects(params)
if params.height > -100 and params.humidity > 65 then
skybox.sky_data = {
type = "regular",
--base_color = { r = 106, g = 130, b = 142 },
clouds = true,
sky_color = {
day_sky = "#6a828e",
@ -31,7 +29,7 @@ local function generate_effects(params)
}
end
override["climate_api:skybox"] = skybox
--override["climate_api:skybox"] = skybox
local movement = params.player:get_player_velocity()
local movement_direction