THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 17/12/2010 at 07:40, xxxxxxxx wrote:
Cinema 4D Version:
Platform: Windows ;
Language(s) : C.O.F.F.E.E ; XPRESSO ;
I'm writing a plugin in COFFEE and i need to test if an object is a clonerobject of MoGraph, but ..
I can't find anything about MoGraph or ClonerObject in the SDK ?
I found out that it's class ID is 1018544. But I don't want to need to remember this everytime when I want to do something with a cloner object.
On 17/12/2010 at 07:51, xxxxxxxx wrote:
The ID is the only way to identify the Colner object. This is true for most other object types too.
On 17/12/2010 at 17:00, xxxxxxxx wrote:
Oh, good to know. Thanks.
I have another question, I don't think it's worth opening a new thread.
I allocated a texturetag and wanted to set its Material with
while mat is a material from another tag taken with
"var mat = tag->GetMaterial();"
Asking The console, it tells me that the variable mat exists, but the material in the allocated tag is nil.
Any Idea ?
Thanks in advance, nux
On 18/12/2010 at 06:49, xxxxxxxx wrote:
Ok I'm trying to get how it works since about three hours, but it won't work !
I think I found a bug, take a look at this script:
> var obj = doc->GetActiveObject();
> var ttag = obj->GetFirstTag();
> var mat = doc->GetFirstMaterial();
> var newtag = AllocTag(ttexture);
> newtag#TEXTURETAG_MATERIAL = mat;
I tested it on a Object with just a texturetag with a material on it.
The Console prints the following:
What "GetMaterial" returns is not the same as it really is ?!
On 18/12/2010 at 13:11, xxxxxxxx wrote:
Really seems like GetMaterial(); does not return the right values.
But i found another way to get the material.
> var mat = ttag#TEXTURETAG_MATERIAL;