Fix black plantlike_rooted without smoothlighting

There was code to take the light of the node above, but the color was not updated.
To reproduce, don't set paramtype="light", (i.e. not what all the devtest nodes do).
This commit is contained in:
Desour 2025-01-07 14:53:41 +01:00 committed by DS
parent 6a1b4a93c7
commit c4bfa65201

View file

@ -1267,7 +1267,8 @@ void MapblockMeshGenerator::drawPlantlikeRootedNode()
getSmoothLightFrame();
} else {
MapNode ntop = data->m_vmanip.getNodeNoEx(blockpos_nodes + cur_node.p);
cur_node.light = LightPair(getInteriorLight(ntop, 0, nodedef)); // FIXME: unused write
cur_node.light = LightPair(getInteriorLight(ntop, 0, nodedef));
cur_node.color = encode_light(cur_node.light, cur_node.f->light_source);
}
drawPlantlike(tile, true);
cur_node.p.Y--;