On 05/09/2016 at 05:45, xxxxxxxx wrote:
Hi,
some objects need some work done on initialization. Therefor MSG_MENUPREPARE is used. In the new C++ SDK Docs, there are a few more words on it in the manual about General Plugin Functionality.
For example, the Correction Deformer needs to create a Tpolygon and a Tpoint tag in there in order to be fully functional.
So to make it work your code looks like this:
corr = c4d.BaseObject(1024542) #define the correction deformer
corr.Message(c4d.MSG_MENUPREPARE)
doc.InsertObject(corr)
c4d.EventAdd()
If you have the possibility to compile the C++ SDK examples, there's a nice little tool in there. The "Active Object Dialog". With this you can take a look into the scene. Great for understanding object caches. And in your case, you would see the two hidden tags on the Correction Deformer, which is a good hint, that the object probably needs MSG_MENUPREPARE.