Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware API
      • ZBrush Python API
      • ZBrush GoZ API
      • Code Examples on Github
    • Forum
    • Downloads
    • Support
      • Support Procedures
      • Registered Developer Program
      • Plugin IDs
      • Contact Us
    • Categories
      • Overview
      • News & Information
      • Cinema 4D SDK Support
      • Cineware SDK Support
      • ZBrush 4D SDK Support
      • Bugs
      • General Talk
    • Unread
    • Recent
    • Tags
    • Users
    • Login

    SearchObject and GetWeightTag

    SDK Help
    0
    4
    397
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • H
      Helper
      last edited by

      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.

      1 Reply Last reply Reply Quote 0
      • H
        Helper
        last edited by

        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

        1 Reply Last reply Reply Quote 0
        • H
          Helper
          last edited by

          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[URL-REMOVED] and non-recursive[URL-REMOVED] hierarchy iteration.


          [URL-REMOVED] @maxon: This section contained a non-resolving link which has been removed.

          1 Reply Last reply Reply Quote 0
          • H
            Helper
            last edited by

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

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

            1 Reply Last reply Reply Quote 0
            • First post
              Last post