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

    SetModelingAxis() Example Is Outdated [SOLVED]

    Bugs
    0
    2
    433
    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
      Helper
      last edited by

      On 31/12/2016 at 16:13, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:    
      Platform:      
      Language(s) :     C++  ;

      ---------
      The docs are still using the outdated ToolData for the SetModelingAxis() example instead of BasePlugin.
      Here's how I'm doing it in R13.

      //This is a custom method that changes the Axis tool's attributes  
      //Select a polygon or point then look at the modeling axis tool's pallet  
      //When this method is executed it changes the axis mode to free  
        
      void SetToolData(BaseDocument *doc, LONG pluginid, LONG dataid, const GeData &dat)  
      {  
        BasePlugin *plug = static_cast<BasePlugin*>(FindPlugin(pluginid, PLUGINTYPE_TOOL));  
        if (!plug) return;  
        plug->SetParameter(DescID(dataid), dat, DESCFLAGS_SET_0);  
      }  
        
      //Call the above method like this from in one of you plugin's overridden methods  
        SetToolData(doc, ID_MODELING_LIVESELECTION, MDATA_AXIS_MODE, MDATA_AXIS_MODE_FREE);
      

      -ScottA

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

        On 02/01/2017 at 03:08, xxxxxxxx wrote:

        Hi ScottA, thanks for writing us.

        We're grate for spotting out this on our documentation. We've marked it and going to modify the documentation hopefully within the next update cycle.

        Best, Riccardo

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