Fix T42074, textured lamps influncing other layers

The solution is to do the multiplication with the energy in the shader
after texture application.

We might be able to avoid setting dyncol completely, but this needs
better investigation. Some shader paths also look a bit redundant.

Also, texture mapping is not supported very well for light lamps, might
also need investigation.
Cleanup to previous commit, we can reuse set_rgb instead of new function
Fix T41957: Shadow color texture mapping was using wrong factor
Cleanup: use bool