0
$\begingroup$

I would like to use an Empty to control color of a material, strength of a light, etc. I know some things can be controlled by Keyframes, but can they be controlled by empties or object positions. Intended uses: Light dimmer switch on a wall; character's eyes change color as empty gets closer. Additional: Eye color changes from blue to brown (bottom up) as coffee is consumed. I would greatly appreciate any help.

$\endgroup$
2
$\begingroup$

Everything you are talking about should be doable with drivers.

For example to make a dimmer switch, right click on the strength on the light, go to add driver, and select manually create later.

Now go to the Graph editor and switch from F-Curve to Drivers at the bottom menu. On the right, your light should be listed. Open all the menus until you reach 'Default Value(Strength)' and click on that. Bring up the properties panel with N, and switch to the drivers tab.

In the drivers tab, change Scripted Expression to Average Value, set the object to be your empty, and change the Type to Z Location.

Now you will have to adjust the curve on the graph to make the dimmer work as you want. The x-axis is the empty position and the y-axis is the light strength. Set the x-axis of the first point to be the lowest the empty will go on the z-axis, and the y-axis of the first point to be the strength of the fully dimmed light. Set the x-axis of the second point to be the highest the empty will go on the z-axis, and the y-axis to be the strength on the non-dimmed light.

Now if you go into rendered view with the empty selected and move it up and down the light intensity should change accordingly.

$\endgroup$
1
  • $\begingroup$ Perfect, took me a while to get the curve set, but it does just what I wanted. $\endgroup$
    – James C.
    Nov 19 '17 at 17:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.