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

    GetActiveToolData() doesn't work for Mirror Tool

    Cinema 4D SDK
    windows s26 python 2023
    2
    5
    844
    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.
    • G
      Gaal Dornik
      last edited by

      Hi, i'm trying to change Mirror Tool settings, but when i get them using GetActiveToolData() it returns me 'None'. Also i've noticed that changing tool settings in the Attributes tab doesn't show up anything in the Script Log, usually i can see tool setting's name and corresponding value in the log.

      Tried both in C4D R26 and 2023.2.0.

      Is it a bug or i'm missing something?

      Thanks.

      import c4d
      
      def main():
          doc = c4d.documents.GetActiveDocument()
          
          c4d.CallCommand(14038) # Mirror
          settings = doc.GetActiveToolData()
          print("settings: %s" % settings)
          
          settings[c4d.MDATA_MIRROR_VALUE] = 0.0
          settings[c4d.MDATA_MIRROR_SYSTEM] = 0
      
          c4d.EventAdd()
      
      # Execute main()
      if __name__=='__main__':
          main()
      
      1 Reply Last reply Reply Quote 0
      • i_mazlovI
        i_mazlov
        last edited by

        Hi @Gaal-Dornik ,

        You're not missing anything, this is actually due to the way the new symmetry system was implemented. You could also have spotted it by not being able to select parameters as well as having different context menu in there:
        22e61108-5278-455b-83dd-651e36e3e72b-image.png

        There's not much you can do about it as the parameters aren't exposed.

        Cheers,
        Ilia

        MAXON SDK Specialist
        developers.maxon.net

        1 Reply Last reply Reply Quote 0
        • G
          Gaal Dornik
          last edited by

          Are there any workarounds for this?

          1 Reply Last reply Reply Quote 0
          • i_mazlovI
            i_mazlov
            last edited by

            Hi @Gaal-Dornik ,

            Sorry for the delayed answer.

            Doesn't look like there're any with the Mirror tool. If you elaborate on what you're trying to achieve, we could try figuring it out with other means.

            Cheers,
            Ilia

            MAXON SDK Specialist
            developers.maxon.net

            1 Reply Last reply Reply Quote 0
            • G
              Gaal Dornik
              last edited by

              I want to mirror a polygon selection along specified modeling axis, but i'm kinda stuck since i can't apply the dedicated Mirror Tool, the basic Scale Tool also doesn't allow to set the tool settings...

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