Notifications
Clear all
[Closed] Scripted CustomAttributes questions
Apr 12, 2011 8:17 pm
Hi!
I’m doing some tests with scripted Custom Attributes to store informations directly on objects.
*Note that I’m not pro to MAXScript :hmm:
I don’t fully understand how scripted customAttributes works yet, but at this point I can add attributes to my objects via a function like this:
fn addTestDataAttribFN obj=
(
test_attibCA = attributes "Test Data"
(
parameters main
(
--
)
)
CustAttributes.add obj test_attibCA BaseObject:false
)
fn addMainAttributesFN obj=
(
test_mainAttibCA = attributes "Test mainAttrib"
(
parameters main
(
mainAttrib1 type:#string default:"mainAttrib1" animatable:false
mainAttrib2 type:#string default:"mainAttrib2" animatable:false
mainAttrib3 type:#string default:"mainAttrib3" animatable:false
)
)
CustAttributes.add obj.testData test_mainAttibCA BaseObject:false
)--end addMainAttributesFN
addTestDataAttribFN $
addMainAttributesFN $
I don’t know if there is a better way to do it…if yes, I’ll really appreciate if someone can clarify it to me.
And supposing I have around 10 attributes like that on a rig of ±200 objects, is there a chance that it slow down the rig in the viewport?
hope it make sense…