mirror of
https://github.com/minetest/minetest_game.git
synced 2024-12-22 06:02:25 +01:00
Set volumetric lighting strength
This commit is contained in:
parent
b23c44d980
commit
df8159436c
@ -1205,7 +1205,7 @@ Weather API
|
|||||||
-----------
|
-----------
|
||||||
|
|
||||||
The weather mod will constantly adjust weather effects seen by the player
|
The weather mod will constantly adjust weather effects seen by the player
|
||||||
(that is: cloud parameters and shadow intensity).
|
(that is: cloud parameters, shadow intensity and volumetric lighting).
|
||||||
These can be influenced using this API.
|
These can be influenced using this API.
|
||||||
|
|
||||||
#### `weather.get = function(player)`
|
#### `weather.get = function(player)`
|
||||||
|
@ -72,7 +72,8 @@ default:torch 99,default:cobble 99
|
|||||||
# Helps rivers create more sound, especially on level sections.
|
# Helps rivers create more sound, especially on level sections.
|
||||||
#river_source_sounds = false
|
#river_source_sounds = false
|
||||||
|
|
||||||
# Enable cloud and shadow intensity variation by the 'weather' mod.
|
# If enabled, the 'weather' mod will control cloud parameters, shadow intensity
|
||||||
|
# and volumetric lighting.
|
||||||
# Non-functional in V6 or Singlenode mapgens.
|
# Non-functional in V6 or Singlenode mapgens.
|
||||||
#enable_weather = true
|
#enable_weather = true
|
||||||
|
|
||||||
|
@ -11,7 +11,10 @@ local mg_name = minetest.get_mapgen_setting("mg_name")
|
|||||||
if mg_name == "v6" or mg_name == "singlenode" then
|
if mg_name == "v6" or mg_name == "singlenode" then
|
||||||
-- set a default shadow intensity for mgv6 and singlenode
|
-- set a default shadow intensity for mgv6 and singlenode
|
||||||
minetest.register_on_joinplayer(function(player)
|
minetest.register_on_joinplayer(function(player)
|
||||||
player:set_lighting({ shadows = { intensity = 0.33 } })
|
player:set_lighting({
|
||||||
|
shadows = { intensity = 0.33 },
|
||||||
|
volumetric_light = { strength = 0.2 },
|
||||||
|
})
|
||||||
end)
|
end)
|
||||||
|
|
||||||
return
|
return
|
||||||
@ -117,7 +120,8 @@ function weather.get(player)
|
|||||||
speed = {x = n_speedx * 4, z = n_speedz * 4},
|
speed = {x = n_speedx * 4, z = n_speedz * 4},
|
||||||
},
|
},
|
||||||
lighting = {
|
lighting = {
|
||||||
shadows = { intensity = 0.7 * (1 - density) }
|
shadows = { intensity = 0.7 * (1 - density) },
|
||||||
|
volumetric_light = { strength = 0.2 },
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
@ -72,7 +72,8 @@ engine_spawn (Use engine spawn search) bool false
|
|||||||
# Helps rivers create more sound, especially on level sections.
|
# Helps rivers create more sound, especially on level sections.
|
||||||
river_source_sounds (River source node sounds) bool false
|
river_source_sounds (River source node sounds) bool false
|
||||||
|
|
||||||
# Enable cloud and shadow intensity variation by the 'weather' mod.
|
# If enabled, the 'weather' mod will control cloud parameters, shadow intensity
|
||||||
|
# and volumetric lighting.
|
||||||
# Non-functional in V6 or Singlenode mapgens.
|
# Non-functional in V6 or Singlenode mapgens.
|
||||||
enable_weather (Enable weather) bool true
|
enable_weather (Enable weather) bool true
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user