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

    CopyTo active instance question

    Scheduled Pinned Locked Moved SDK Help
    4 Posts 0 Posters 342 Views
    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 Offline
      Helper
      last edited by

      THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

      On 13/12/2007 at 03:19, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:   10.5 
      Platform:   Windows  ; Mac  ;  Mac OSX  ; 
      Language(s) :     C++  ;

      ---------
      Greetings,

      Is there any way to find out if an instance of an ObjectData plugin created by CopyTo is active or not?

      For instance, if somebody copies the object in object manager it is still active since it is being used, and if an instance is copied for undo (eg a handle is moved), it isn't active until someone actually clicks the undo button.

      The reason i'm asking this is because i have to somehow remove BackgroundHandler from those undo copies, and add it again when they are actually being used.

      Thanks in advance,
      Miha

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

        THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

        On 13/12/2007 at 10:02, xxxxxxxx wrote:

        Ok i think i somewhat solved it with using Message (since message on 'active' instances is called after creation, and isn't in instances copied by c4d for undo).

        I would still be very grateful if someone would come up with a more elegant solution 🙂

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

          THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

          On 14/12/2007 at 03:00, xxxxxxxx wrote:

          Quote: Originally posted by vuce on 13 December 2007
          >
          > * * *
          >
          > Ok i think i somewhat solved it with using Message (since message on 'active' instances is called after creation, and isn't in instances copied by c4d for undo).
          >
          > I would still be very grateful if someone would come up with a more elegant solution 🙂
          >
          >
          > * * *

          found out it doesn't work exactly as planned, so i'm still seeking for solution

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

            THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

            On 14/12/2007 at 06:18, xxxxxxxx wrote:

            Personally, I don't think there is a tried-and-true way to know under what circumstances the CopyTo() is being called. It could be for a copy in the Object Manager, an undo/redo, or a document cache for render or some other facility requiring a cache.

            Messages are sometimes a good way to distinguish circumstances but as you've probably noticed they are not always unique enough. I had already requested messages be passed when an object is being copied for undo or redo but not holding breath. 🙂

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