mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Fix CAO light calculation issue
This commit is contained in:
parent
a83d81ff45
commit
e92a217bd1
1 changed files with 1 additions and 1 deletions
|
@ -872,7 +872,7 @@ void GenericCAO::updateLight(u32 day_night_ratio)
|
|||
MapNode n = m_env->getMap().getNode(pos[i], &this_ok);
|
||||
if (this_ok) {
|
||||
u16 this_light = getInteriorLight(n, 0, m_client->ndef());
|
||||
u8 this_light_intensity = MYMAX(this_light & 0xFF, (this_light >> 8) && 0xFF);
|
||||
u8 this_light_intensity = MYMAX(this_light & 0xFF, this_light >> 8);
|
||||
if (this_light_intensity > light_at_pos_intensity) {
|
||||
light_at_pos = this_light;
|
||||
light_at_pos_intensity = this_light_intensity;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue