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

    Set Asset Paths in python

    Cinema 4D SDK
    python r20
    2
    5
    1.6k
    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.
    • B
      bonsak
      last edited by r_gigante

      Hi
      How can i set asset paths programatically in r20? It doesnt seem possible to set asset paths with environment variables so i need to figure out a way to do this with a python script on start up.
      Any help appreciated.

      Bonsak

      1 Reply Last reply Reply Quote 0
      • B
        bonsak
        last edited by

        That was easy 🙂
        Paths[c4d.PREF_TEXPATHS] = 'D:/path/number/one\nC:/path/number/two'

        1 Reply Last reply Reply Quote 0
        • B
          bonsak
          last edited by

          Even better!
          c4d.SetGlobalTexturePaths([['D:/path/number/one',True],['D:/path/number/two',True]])
          I just love it when im all alone in here answering myself 🙂

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

            Hi Bonsak,

            I'm glad you found the solution yourself.

            One reminder:
            Please try to make use of tags, when posting, to help us keeping this place tidy. For this thread I already added some.

            Cheers,
            Andreas

            1 Reply Last reply Reply Quote 0
            • B
              bonsak
              last edited by

              Cool. Will do.

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