<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Can PythonStartup path be set with .mod modules? in MotionBuilder Forum</title>
    <link>https://forums.autodesk.com/t5/motionbuilder-forum/can-pythonstartup-path-be-set-with-mod-modules/m-p/13886545#M3831</link>
    <description>&lt;P&gt;Hi,&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/4515326"&gt;@FirespriteNate&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Though module description files (.mod) will not modify PythonStartup, it is possible to specify some custom path for MotionBuilder to look into at startup.&lt;/P&gt;&lt;P&gt;For example, put this .mod file in the directory as &lt;A href="https://help.autodesk.com/view/MOBPRO/2026/ENU/?guid=MotionBuilder_SDK_DistributingUsingModules_InstallingModules_html" target="_blank" rel="noopener"&gt;the Developer Help&lt;/A&gt; describes.&lt;/P&gt;&lt;LI-CODE lang="general"&gt;+ CustomPythonStartup 0.1 C:/Mobu_Python/Forum/CustomPythonStartup
python: startup_scripts
python_sys_path: path_for_syspath&lt;/LI-CODE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Ndgt_1-1762587931043.png" style="width: 400px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1586632iF6D06288EE2CF738/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Ndgt_1-1762587931043.png" alt="Ndgt_1-1762587931043.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is the result output of startup.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Ndgt_2-1762588060674.png" style="width: 999px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1586633i227BEAB203564D0A/image-size/large?v=v2&amp;amp;px=999" role="button" title="Ndgt_2-1762588060674.png" alt="Ndgt_2-1762588060674.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Of course, we can specify the module path as startup path directly.&lt;/P&gt;&lt;LI-CODE lang="general"&gt;+ CustomPythonStartup 0.1 C:/Mobu_Python/Forum/CustomPythonStartup
python: .&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;With this .mod file, the scripts under the CustomPythonStartup will be executed at startup.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Ndgt&lt;/P&gt;</description>
    <pubDate>Sat, 08 Nov 2025 08:00:10 GMT</pubDate>
    <dc:creator>Ndgt</dc:creator>
    <dc:date>2025-11-08T08:00:10Z</dc:date>
    <item>
      <title>Can PythonStartup path be set with .mod modules?</title>
      <link>https://forums.autodesk.com/t5/motionbuilder-forum/can-pythonstartup-path-be-set-with-mod-modules/m-p/13885442#M3830</link>
      <description>&lt;P&gt;We need to set a custom &lt;STRONG&gt;PythonStartup&lt;/STRONG&gt; path that is on our project work drives under P4 control. At the moment I am setting it (along with other stuff) using a launch script, something like this:&lt;/P&gt;&lt;LI-CODE lang="general"&gt;motionbuilder.exe -verbosePython d:\mobu\start.py&lt;/LI-CODE&gt;&lt;P&gt;and in&amp;nbsp;&lt;STRONG&gt;start.py&lt;/STRONG&gt; is something like:&lt;/P&gt;&lt;LI-CODE lang="python"&gt;from pyfbsdk import *
config = FBConfigFile("@Application.txt")
config.Set("Python", "PythonStartup", "d:\\mobu\\start_dir", "Set by start.py")&lt;/LI-CODE&gt;&lt;P&gt;This is grossly oversimplified for clarity, but is there any way to ditch all this and just set this custom &lt;STRONG&gt;PythonStartup&lt;/STRONG&gt; path from within a .mod file?&lt;/P&gt;</description>
      <pubDate>Fri, 07 Nov 2025 10:34:01 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/motionbuilder-forum/can-pythonstartup-path-be-set-with-mod-modules/m-p/13885442#M3830</guid>
      <dc:creator>FirespriteNate</dc:creator>
      <dc:date>2025-11-07T10:34:01Z</dc:date>
    </item>
    <item>
      <title>Re: Can PythonStartup path be set with .mod modules?</title>
      <link>https://forums.autodesk.com/t5/motionbuilder-forum/can-pythonstartup-path-be-set-with-mod-modules/m-p/13886545#M3831</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/4515326"&gt;@FirespriteNate&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Though module description files (.mod) will not modify PythonStartup, it is possible to specify some custom path for MotionBuilder to look into at startup.&lt;/P&gt;&lt;P&gt;For example, put this .mod file in the directory as &lt;A href="https://help.autodesk.com/view/MOBPRO/2026/ENU/?guid=MotionBuilder_SDK_DistributingUsingModules_InstallingModules_html" target="_blank" rel="noopener"&gt;the Developer Help&lt;/A&gt; describes.&lt;/P&gt;&lt;LI-CODE lang="general"&gt;+ CustomPythonStartup 0.1 C:/Mobu_Python/Forum/CustomPythonStartup
python: startup_scripts
python_sys_path: path_for_syspath&lt;/LI-CODE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Ndgt_1-1762587931043.png" style="width: 400px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1586632iF6D06288EE2CF738/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Ndgt_1-1762587931043.png" alt="Ndgt_1-1762587931043.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is the result output of startup.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Ndgt_2-1762588060674.png" style="width: 999px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1586633i227BEAB203564D0A/image-size/large?v=v2&amp;amp;px=999" role="button" title="Ndgt_2-1762588060674.png" alt="Ndgt_2-1762588060674.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Of course, we can specify the module path as startup path directly.&lt;/P&gt;&lt;LI-CODE lang="general"&gt;+ CustomPythonStartup 0.1 C:/Mobu_Python/Forum/CustomPythonStartup
python: .&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;With this .mod file, the scripts under the CustomPythonStartup will be executed at startup.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Ndgt&lt;/P&gt;</description>
      <pubDate>Sat, 08 Nov 2025 08:00:10 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/motionbuilder-forum/can-pythonstartup-path-be-set-with-mod-modules/m-p/13886545#M3831</guid>
      <dc:creator>Ndgt</dc:creator>
      <dc:date>2025-11-08T08:00:10Z</dc:date>
    </item>
    <item>
      <title>Re: Can PythonStartup path be set with .mod modules?</title>
      <link>https://forums.autodesk.com/t5/motionbuilder-forum/can-pythonstartup-path-be-set-with-mod-modules/m-p/13888446#M3832</link>
      <description>&lt;P&gt;Many thanks, that seems to work!&lt;/P&gt;&lt;P&gt;I started setting this up on MoBu 2022 which has no modules, hence the rather convoluted&amp;nbsp;&lt;STRONG&gt;PythonStartup&lt;/STRONG&gt; approach, but this is much better.&lt;/P&gt;&lt;P&gt;I knew I could add paths to a module, but I didn't realise adding a path to "&lt;STRONG&gt;python&lt;/STRONG&gt;" would auto-run the files within it!&lt;/P&gt;</description>
      <pubDate>Mon, 10 Nov 2025 11:47:31 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/motionbuilder-forum/can-pythonstartup-path-be-set-with-mod-modules/m-p/13888446#M3832</guid>
      <dc:creator>FirespriteNate</dc:creator>
      <dc:date>2025-11-10T11:47:31Z</dc:date>
    </item>
  </channel>
</rss>

