SearchObject and GetWeightTag



  • On 21/05/2015 at 20:55, xxxxxxxx wrote:

    User Information:
    Cinema 4D Version:    
    Platform:      
    Language(s) :

    ---------
    These functions are similar in the conudrum I have. With Search object if I happen to have say a 'hips' joint and there's like several of them, all named the same in the scene, it appears SearchObject just picks one. Just so happens the one it does seems to always be the one I need, but what if I'd like to find all the 'hips' joints for a script functionality? GetWeightTag is similar, I have a joint, say 'hips' again and I call its GetWeightTag function. Well GetWeightTag returns a single Weight tag that luckily once again happens to be what I need, but there's like five objects in the scene that I know have weight tags with the 'hips' joint in them.

    My question is how can I get these functions to return all the objects the are related to their result.



  • On 22/05/2015 at 01:57, xxxxxxxx wrote:

    Hi,

    Could you re-write your question please? Return all the objects that are related to their result: which result? I will try to answer your question if I understand your question.

    Greetings,
    Casimir Smets



  • On 22/05/2015 at 07:45, xxxxxxxx wrote:

    Hi,

    SearchObject() and GetWeightTag() can both return only one object/tag.
    If you need to find more, you will need to walk the object hierarchy (or the tag list) on your own.
    It's easy and can be done in various ways. Here are two articles on recursive and non-recursive hierarchy iteration.



  • On 23/05/2015 at 07:03, xxxxxxxx wrote:

    I see, I'll have to think about this one then. Thanks.


Log in to reply