THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 26/11/2010 at 07:25, xxxxxxxx wrote:
Cinema 4D Version: R12
Platform: Windows ;
Language(s) : PYTHON ;
I know how to add the usual phong, protect, vertex tags etc like this :
doc = documents.GetActiveDocument()
obj = doc.GetActiveObject()
my_tag = c4d.BaseTag(c4d.Tphong)
But whenever I try to add any of the Character tags, like Tcaik, I get an error 'Tcaik is not defined'.
Same with hair tags etc
So my question is how can add tags belonging to the modules ?
On 27/11/2010 at 20:21, xxxxxxxx wrote:
I got an answer, which I'm copying here, so that those who search for the same problem in future can find it.
Thanks to sebastien for providing the info :
Hi, are you looking for the tag with the ID 1019561? You can define the ID manually in the code:
Tcaik = 1019561
tag = c4d.BaseTag(Tcaik)
How I got the ID? I created the tag manually in C4D and dragged it into the Py console.
Calling IK.GetType() returned the ID of the tag which is 1019561.
This method should work for all tags not defined in c4d.Basetag, so hair tags etc too.