Fix light level calculation.