How to set light color from the texture of the object located behind the light.

Look at here

Looks like this is what you need.