GetVirtualObjects - do not recreate objects
-
On 24/01/2013 at 09:09, xxxxxxxx wrote:
interesting.
I just noticed that if I have my undos the way I have them right now (see above), INIT function is called twice, but if I don't have StartUndo, AddUndo, EndUndo - then INIT is called only once.Does that make any sence?
However, I am not really sure what you mean with your first statement:) (sorry, dummy here). You say it's better to use op.GetDocument() instead of doc = c4d.documents.GetActiveDocument(), right? I just want to be sure:)
By the way, R12 and R13 does act the same. I just tested it aswell.
-
On 24/01/2013 at 09:21, xxxxxxxx wrote:
Originally posted by xxxxxxxx
I just noticed that if I have my undos the way I have them right now (see above), INIT function is called twice, but if I don't have StartUndo, AddUndo, EndUndo - then INIT is called only once.
This is intended. When you create an undo for your object, Cinema creates a copy of it. And the copy
must be initialized in some way, too, hm?Yes, using doc=op.GetDocument() is the correct way, the other is semantically wrong.
-Niklas
-
On 24/01/2013 at 10:07, xxxxxxxx wrote:
doc=op.GetDocument()
check:)
I want to stress undo weirdness once again. I just check hyper mega advanced plugin Py-DoubleCircle. While you move handles in viewport and change radius this way - undo works just fine. BUT is you enter numeric values to Radius in Object tab, then undo don't work (let's say it works but in a weir way)
So maybe Niklas you ARE right. Maybe that's suppose to be like.
Any ways, appreciate your input. I learned a lot today. Thank you.