C4DAtom.SetParameter/GetParameter help
-
Hello,
I would like to get and set the 'Strength' parameter of an inheritance effector inside a python node of Xpresso, but I'm not sure how to do this properly. According to the doc (https://developers.maxon.net/docs/py/2024_4_0a/classic_resource/object/oeinheritance.html), I need to pass in the flag, c4d.MGINHERITANCEEFFECTOR_STRENGTH, but it looks like I also need to pass in a descriptor flag and not sure what that is all about. Could someone provide an example of how to do this properly?
Thanks in advance for any help!
-
Ah, I found out that using the brackets to set/get the parameter values is much simpler!
For example: inheritanceEffector[c4d.MGINHERITANCEEFFECTOR_STRENGTH] = 1.0 -
Hi @ops,
Thanks for reaching out to us and thanks for sharing your solution with the community, this is highly appreciated!
You're right, the most common way of accessing object's attributes is by using subscript operator.
Cheers,
Ilia