In Part 1 of this tutorial, we came across different types of connections and learned how to use Wire Parameters to control the parameters of an object, but sometimes, we want our object to be controlled by a slider or a spinner instead of any object or helper.
It’s very common problem for beginners to control the object’s parameters with a slider.
We can do this by following these simple steps.
Let’s start by creating a box in Viewport. Now, add a modifier called Attribute Holder to your box.
Tip: Attribute Holder is an empty modifier generally used to save custom attributes for our rigs.
Now, go to Animation > Parameter Editor… (Alt+1), it will bring up the Parameter Editor dialog. Under Attribute Rollout, set the type to Selected Object’s Current Modifier. Set the UI type to Slider, name your slider and just click on Add button. Now, Notice that slider is added to the Attribute Holder modifier.
Select the box and right click > Wire Parameters…, then Modified Object > Attribute Holder > Custom_Attributes > My_Slider (your slider name will appear here).
Now click one more time on box then follow Transform > Rotation > Z Rotation.
In Parameter Wiring dialog, use the last connection going from left to right as we want our left parameter to control the right one.
Check the setup by sliding the slider. Notice that our box starts rotating when we slide the slider.
I hope you find this tutorial helpful.