mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Smooth day-night transitions
This commit is contained in:
parent
041585a78e
commit
804a7875a2
7 changed files with 87 additions and 23 deletions
|
@ -163,6 +163,16 @@ struct MapNode
|
|||
return blend_light(daylight_factor, lightday, lightnight);
|
||||
}
|
||||
|
||||
// 0.0 <= daylight_factor <= 1.0
|
||||
// 0 <= return value <= LIGHT_SUN
|
||||
u8 getLightBlendF1(float daylight_factor, INodeDefManager *nodemgr) const
|
||||
{
|
||||
u8 lightday = 0;
|
||||
u8 lightnight = 0;
|
||||
getLightBanks(lightday, lightnight, nodemgr);
|
||||
return blend_light_f1(daylight_factor, lightday, lightnight);
|
||||
}
|
||||
|
||||
u8 getFaceDir(INodeDefManager *nodemgr) const;
|
||||
u8 getWallMounted(INodeDefManager *nodemgr) const;
|
||||
v3s16 getWallMountedDir(INodeDefManager *nodemgr) const;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue