rendermax: sunlight travels down stairs

develop
jj 2013-06-24 02:22:30 +02:00 committed by Warmist
parent 4d7a7425d0
commit de8a76e37f
1 changed files with 5 additions and 1 deletions

@ -339,13 +339,17 @@ void lightingEngineViewscreen::doOcupancyAndLights()
{ {
cellArray[block_x][block_y]=lightCell(0,0,0); cellArray[block_x][block_y]=lightCell(0,0,0);
} }
else if(basic_shape==df::tiletype_shape_basic::Floor || basic_shape==df::tiletype_shape_basic::Ramp || basic_shape==df::tiletype_shape_basic::Stair) else if(basic_shape==df::tiletype_shape_basic::Floor || basic_shape==df::tiletype_shape_basic::Ramp || shape==df::tiletype_shape::STAIR_UP)
{ {
if(ZZ!=window_z) if(ZZ!=window_z)
{ {
cellArray[block_x][block_y]=lightCell(0,0,0); cellArray[block_x][block_y]=lightCell(0,0,0);
} }
} }
else if(shape==df::tiletype_shape::STAIR_DOWN || shape==df::tiletype_shape::STAIR_UPDOWN)
{
cellArray[block_x][block_y]*=lightCell(0.9,0.9,0.9);
}
if(d.bits.liquid_type == df::enums::tile_liquid::Water && d.bits.flow_size) if(d.bits.liquid_type == df::enums::tile_liquid::Water && d.bits.flow_size)
{ {
cellArray[block_x][block_y] *= (lightCell(1,1,1) - (lightCell(1,1,1) - lightCell(0.63f,0.63f,0.75f))*((float)d.bits.flow_size/7.0f)); cellArray[block_x][block_y] *= (lightCell(1,1,1) - (lightCell(1,1,1) - lightCell(0.63f,0.63f,0.75f))*((float)d.bits.flow_size/7.0f));