mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-14 00:55:20 +02:00
Fix lighting of the wield mesh (#12341)
* Assign node light to player before final color blend. Fixes day/night lightbank ratio for wield meshes * Update wield mesh light when changing mesh
This commit is contained in:
@@ -305,6 +305,7 @@ void ClientEnvironment::step(float dtime)
|
||||
node_at_lplayer = m_map->getNode(p);
|
||||
|
||||
u16 light = getInteriorLight(node_at_lplayer, 0, m_client->ndef());
|
||||
lplayer->light_color = encode_light(light, 0); // this transfers light.alpha
|
||||
final_color_blend(&lplayer->light_color, light, day_night_ratio);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user