Writing a tag based on the Protection tag
On 25/05/2013 at 10:26, xxxxxxxx wrote:
Cinema 4D Version: 14Studio
Platform: Windows ;
Language(s) : C++ ;
I want to write a new tag, based on the Protection tag.
Where is this tag defined? Cannot find it, have searched almost all files in C4D.
On 25/05/2013 at 10:31, xxxxxxxx wrote:
What do you mean by "defined"? The TagData subclass of the Protection Tag is not public, therefore
you can not inherit from it. What you could do to inherit its behavior, is to allocate a Tprotection
tag with the initialization of your own tag and redirect all calls to the allocated tag.
On 25/05/2013 at 11:02, xxxxxxxx wrote:
As Niklas notes, you can only derive from NodeData-based classes and utilize Xbase descriptions (where X is the type such as Obase, Tbase, etc.). Developers cannot extend built-in objects.
On 26/05/2013 at 09:11, xxxxxxxx wrote:
One point to mention is that you can 'extend' the Protection Tag (or anything else that shows its data in the Attributes Manager) using UserData.
On 26/05/2013 at 13:23, xxxxxxxx wrote:
Ok, now I learned this.
Why I would do it - the protection tag has no "Enabled" property, which I really miss.