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

    c4d-Module attribute problem

    Scheduled Pinned Locked Moved PYTHON Development
    3 Posts 0 Posters 601 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 27/04/2011 at 04:18, xxxxxxxx wrote:

      Hi.

      My plugin can handle multiple cases. It can do stuff if doc.GetMode() is in (c4d.Mpoints,c4d.Medges,c4d.Mpolygons).

      The problem is, on startup, the module seems to be not complete, so this code:

        
      class MyCommandData(CommandData) :  
        
        VALIDMODES  = (c4d.Mpoints,c4d.Medges,c4d.Mpolygons)  
        def __init__(self) :  
            # self.VALIDMODES  = (c4d.Mpoints,c4d.Medges,c4d.Mpolygons) : doesnt work, too  
            pass  
      

      Raises an attribute error.

      Of course i could create that VALIDMODES attribute before i need it, but i just wonder why it doesnt work.

      Thanks, nux

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

        On startup the symbolcache is not built yet. Please define them manually or better later.

        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 27/04/2011 at 05:55, xxxxxxxx wrote:

          Thanks !

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