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

    MCOMMAND_SPLIT [not work]

    Scheduled Pinned Locked Moved PYTHON Development
    4 Posts 0 Posters 380 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

      On 08/02/2013 at 10:11, xxxxxxxx wrote:

      Hi 🙂
      i have  this script for split polygon face:

       
      import c4d
      from c4d import utils
        
      settings = c4d.BaseContainer()
      res = utils.SendModelingCommand(command = c4d. **MCOMMAND_SPLIT** ,
                                      list = [op],
                                      mode = c4d.MODELINGCOMMANDMODE_POLYGONSELECTION,
                                      bc = settings,
                                      doc = doc)
      c4d.EventAdd()
      

      but not work... 
      the new poygon is not created...  There is something that I entered wrong?

      Thanks!

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

        On 08/02/2013 at 10:58, xxxxxxxx wrote:

        what could help :

        create a copy both of your BaseDocument and your PolygonObject. Insert the poly copy into
        the copy of the BaseDocument and pass these two to SMC. Then insert the result into your
        active BaseDocment.

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

          On 08/02/2013 at 11:07, xxxxxxxx wrote:

          Try this:

          import c4d
          from c4d import utils
            
          settings = c4d.BaseContainer()
          res = utils.SendModelingCommand(command = c4d.MCOMMAND_SPLIT,
                                          list = [op],
                                          mode = c4d.MODELINGCOMMANDMODE_POLYGONSELECTION,
                                          bc = settings,
                                          doc = doc)
           **doc.InsertObject(res[0])**
          c4d.EventAdd()
          
          1 Reply Last reply Reply Quote 0
          • H Offline
            Helper
            last edited by

            On 09/02/2013 at 01:57, xxxxxxxx wrote:

            ferdinand and NiklasR, Thanks for your help 👍 🍺

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