Hirazi Blue
08-21-2008, 03:39 AM
I am trying to move some points on some "hair"-geometry in Python.
First I freeze my hair-object, having read somewhere the PositionArray cannot be altered unless the object is frozen.
"oldPosition = myHair.ActivePrimitive.Geometry.Points.PositionArr ay "
gets me the position-array.
And I know "oldPosition" is a tuple, I have to convert to a list to change and re-convert to a tuple (in this example called newPosition) to feed it back to the PositionArray.
However, when I try:
myHair.ActivePrimitive.Geometry.Points.PositionArr ay = newPosition
(to get the new array into place)
myHair.ActivePrimitive.Geometry.Points.PositionArr ay = oldPosition
(just merely feeding the old values back in the PositionArray)
both times I get an "Access Denied"-error.
I can tell, I am obviously making some very stupid mistake, but have looked at this code for almost two days now, I've given up hope, of finding it by myself. Please help...
edit: the Space between "Arr" and "ay" shouldn't be there, weird!
First I freeze my hair-object, having read somewhere the PositionArray cannot be altered unless the object is frozen.
"oldPosition = myHair.ActivePrimitive.Geometry.Points.PositionArr ay "
gets me the position-array.
And I know "oldPosition" is a tuple, I have to convert to a list to change and re-convert to a tuple (in this example called newPosition) to feed it back to the PositionArray.
However, when I try:
myHair.ActivePrimitive.Geometry.Points.PositionArr ay = newPosition
(to get the new array into place)
myHair.ActivePrimitive.Geometry.Points.PositionArr ay = oldPosition
(just merely feeding the old values back in the PositionArray)
both times I get an "Access Denied"-error.
I can tell, I am obviously making some very stupid mistake, but have looked at this code for almost two days now, I've given up hope, of finding it by myself. Please help...
edit: the Space between "Arr" and "ay" shouldn't be there, weird!