Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware 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

    SaveWorldPreferences() in Python

    Cinema 4D SDK
    2
    5
    823
    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.
    • a_blockA
      a_block
      last edited by

      Hi,

      is there a chance, we could get SaveWorldPreferences() in Python.

      I store some licensing info inside the prefs container. If a user now manages to crash C4D after having entered the license information for my plugin, the licensing info is lost and user needs to enter it again. I would have never imagined this to get an issue. But unfortunately I was wrong...

      Would be cool to be able to save the prefs manually.

      Cheers,
      Andreas

      ferdinandF 1 Reply Last reply Reply Quote 0
      • ferdinandF
        ferdinand @a_block
        last edited by

        Hello @a_block,

        Thank you for reaching out to us. We have to discuss if we want to do this, but in the mean-time I would propose c4d.RestartMe() should this not be almost as good? You should be on the main thread when the license stuff is happening, so rebooting Cinema 4D should be no problem.

        Sure, it will take a bit longer, but you can print "Be-ba-boop: Rebooting Cinema 4D ..." to make it cool 😉

        Cheers,
        Ferdinand

        MAXON SDK Specialist
        developers.maxon.net

        1 Reply Last reply Reply Quote 0
        • a_blockA
          a_block
          last edited by

          I had pretty mixed results with latest releases and use of RestartMe(). Somethings rings in the back of my head its use beeing discouraged.
          And I think, a restart shouldn't be necessary at all. I'm even of the opinion restarting anything is almost neverr a good solution. Not even with "Be-ba-boop: Rebooting Cinema 4D...". I'd rather hope, to be able to simply save the prefs just like it is possible in the C++ SDK. So, I'll keep my fingers crossed and wait for the result of your discussion.

          ferdinandF 1 Reply Last reply Reply Quote 0
          • ferdinandF
            ferdinand @a_block
            last edited by

            Hello @a_block,

            We have discussed this, and we will add this function at some point, but I cannot give you an ETA. For now, you will have to live with either restarting Cinema 4D or with taking the risk of your data vanishing when Cinema 4D crashes.

            Cheers,
            Ferdinand

            MAXON SDK Specialist
            developers.maxon.net

            1 Reply Last reply Reply Quote 0
            • a_blockA
              a_block
              last edited by

              Hi Ferdinand,
              thanks a lot!
              No ETA needed, I'm grateful it will be added eventually.
              Cheers,
              Andreas

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