[Closed] Creating FootControls
I am following Paul Neale’s rigging tutorial and I can’t run the script for creating footcontrols on an attribute holder, he shows us. It may be just a small mistake but I’m pretty sure I wrote the same script he did. Could someone help me please?
Here is my error: – Error occurred in anonymous codeblock; filename: d:\utilisateurs\0930920\Desktop\footScript.ms; position: 372; line: 15
– Type error: Call needs function or class, got: undefined
Here is my script.
ca=attributes footcontrols
(
parameters params rollout:footR
(
footroll type:#float ui:footrollsp
toe1 type:#float ui:toe1sp
toe2 ype:#float ui:toe2sp
toe3 ype:#float ui:toe3sp
)
rollout footR “Footcontrols”
(
local range=[-90,90,0]
spinner footrollsp “Foot Roll” range:range
spinner toe1sp “Big Toe” range:range
spinner toe2sp “Mid Toe” range:range
spinner toe3sp “Small Toe” range:range
)
)
custattributes.add $.modifiers[1] ca
Thanks.
okay that was a stupid mistake.
But is still get this error
– Error occurred in anonymous codeblock; filename: d:\utilisateurs\0930920\Desktop\footScript.ms; position: 473; line: 19
– Type error: custAttributes.add requires MSCustAttribDef, got: undefined
It looks like the script may be wanting to operate on a selection. “$” do you have the proper selection in viewport?
yes I do. I a have an editable spline selected who has an attribute holder.
When I run the script with the fixed typo’s it works fine. Make sure your evaluating the entire script and that there isn’t already a definition in the attribute holder. It seems like the first part of your script didn’t get evaluated and therefore there was no definition to add to the attribute holder.