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

    undo

    Scheduled Pinned Locked Moved SDK Help
    7 Posts 0 Posters 646 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 03/04/2008 at 13:10, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:   10.5 
      Platform:      
      Language(s) :   C.O.F.F.E.E  ;

      ---------Why would the constructor of my expressionplugin tag be called when I 'undo' in C4d?

      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 03/04/2008 at 13:39, xxxxxxxx wrote:

        I commented out the undo stuff I had in the execute function of the espressionplugintag and now it doesn't call the constructor when undoing.

            
            
            SplineNull::Execute(doc, op)  
            {  
             //pDoc->StartUndo();  
             //pDoc->AddUndo(UNDO_OBJECT_REC,op);  
             //pDoc->EndUndo();
        

        but I don't understand why, and I feel like I might need this undo stuff

        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 03/04/2008 at 14:58, xxxxxxxx wrote:

          In general, Undo will only make sense for MenuPlugins.
          (Push a button and something happens, didn't like it? Undo.
          (as many times back as you have set your prefs in Cinema)

          An expressionplugintag is executed each and every frame
          and, in principe, only the prev frame is "Undoable" unless you
          store each and every frame in history.

          I have not a single Undo in any of my expression plugin Tags.

          Cheers
          Lennart

          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 04/04/2008 at 05:38, xxxxxxxx wrote:

            Thanks for the insight Lennart.  I just changed my plugin from operating as a menuplugin to operating as an ExpressionPluginTag.  After reading this I am thinking that maybe I will put all of the functionality into a menuPlugin and just call the functions from an ExpressionPluginTag so that the plug can render.  Thanks Again

            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 04/04/2008 at 06:27, xxxxxxxx wrote:

              Howdy,

              Just be careful that you don't overload the undo stack. Using AddUndo() in an expression tag's Execute() function, or any node's Execute() function can seriously overload the undo stack by adding an undo at every screen refresh, whether you're running the animation or not. Calling a function that has an AddUndo() in it, from an Execute() function has the same effect.

              This can cause a long delay every time Undo is called by the user. The user will get the "spinning mouse" until Cinema 4D has finished clearing all the accumulated undo's. :o(

              Adios,
              Cactus Dan

              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 04/04/2008 at 06:53, xxxxxxxx wrote:

                Thanks C Dan, I'll watch for that.  Hmmmmmm  if that occurs I can't think of another option at the moment.

                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 04/04/2008 at 07:29, xxxxxxxx wrote:

                  Maybe you can give us a little insight on what you are trying to achieve?

                  cheers,
                  Matthias

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