mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-07 03:51:50 +00:00
add 'sky_tint', 'clouds_tint', 'min_sky_light' weather parameters
This commit is contained in:
parent
1194379f99
commit
e037462615
22 changed files with 80 additions and 31 deletions
|
|
@ -23,6 +23,9 @@ dv::value WeatherPreset::serialize() const {
|
|||
root["fog_opacity"] = fogOpacity;
|
||||
root["fog_dencity"] = fogDencity;
|
||||
root["fog_curve"] = fogCurve;
|
||||
root["sky_tint"] = dv::to_value(skyTint);
|
||||
root["clouds_tint"] = dv::to_value(cloudsTint);
|
||||
root["min_sky_light"] = dv::to_value(minSkyLight);
|
||||
root["clouds"] = clouds;
|
||||
root["thunder_rate"] = thunderRate;
|
||||
|
||||
|
|
@ -51,6 +54,9 @@ void WeatherPreset::deserialize(const dv::value& src) {
|
|||
src.at("fog_opacity").get(fogOpacity);
|
||||
src.at("fog_dencity").get(fogDencity);
|
||||
src.at("fog_curve").get(fogCurve);
|
||||
dv::get_vec(src, "sky_tint", skyTint);
|
||||
dv::get_vec(src, "clouds_tint", cloudsTint);
|
||||
dv::get_vec(src, "min_sky_light", minSkyLight);
|
||||
src.at("clouds").get(clouds);
|
||||
src.at("thunder_rate").get(thunderRate);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue