Cage opened this issue on Dec 20, 2006 · 1232 posts
Cage posted Thu, 27 March 2008 at 3:14 PM
Boy, I had that last posted script all wrong. Hmm. I think this can be made to work, so I'm working on a complete re-write of the idea, even though it's a bit of a digression....
Okay, I read the new .pyd readme, and let's see if I now understand, or whether I'm confused. Can I generalize and say that any time I'm going to use one of the math operators on a vector, I should be prepared to be handling a reference, so I should use Clone() unless I definitely want to change the source vector?
tempvec = listvec[x]
tempvec += othervec # will alter listvec[x]
newvec = tempvec + othervec # will not alter listvec[x]
newvec = listvec[x] + othervec # will not alter listvec[x]
tempvec = listvec[x].Clone()
tempvec += othervec # will not alter listvec[x]
Is that correct? :hopeful:
===========================sigline======================================================
Cage can be an opinionated jerk who posts without thinking. He apologizes for this. He's honestly not trying to be a turkeyhead.
Cage had some freebies, compatible with Poser 11 and below. His Python scripts were saved at archive.org, along with the rest of the Morphography site, where they were hosted.