Connect light rotation to rgb vector

Hi,

 Is there a way to get the directional light's rotation (direction) and use it to drive a rgb value (vector) in a material? 

​

Please be descriptive if you can help.

Thanks!

1 Like

Yes man
you need to create a dinamic material, inside you need to define a parameter vector.

Than you get the rotation value, (you have to convert it to a vector or something)
for example you can get the rotation , break it in floats, and remake her in a vector.

Cast to the material paramenter and set the vector.

2 Likes