[Closed] Two questions
Hi guys,
Just two quick questions,
1: Is there an elegant way to get the base object from within a scripted modifier? I’d like to be able to manipulate some properties of the baseobject from my modifier (namely vertex coloring toggle), but I don’t want to use “$” for fear of the user “pinning” the stack, changing the currently selected object but leaving the modifier open. Using “$” also disallows maxscript access since any code in the modifier referencing “$” could be potentially anything (dangerous). I’m finding myself scope-blocked, as it were.
And 2: Is there any MXS access to the “pinned” state of the modifier panel? I can’t find anything in the docs, and searching here yields nothing. I’m thinking there isn’t any access, but just want to make sure.
I’ve coded around these problems for now, but its led to a bunch of convoluted if conditionals that I’d rather avoid… if only there was a this.node property or something similar. Thanks for any help you can give.
Hey kees,
this.delegate yields the modifier that the scripted modifier inherits, but not the underlying object that the modifier is applied to, unless I’m misusing it? There is also the attachedToNode event which yields the node the modifier is applied to, but its not possible to store this as a parameter as it would create a circular dependency. So I’m looking for a reference similar to “this,” “delegate,” etc that gives me the node, but maybe it doesn’t exist.
ok…I must understood.
You said ‘base object’.
The INode (scene node) is not the base object.
-Kees