• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers

Run Python script at startup

Explorer ,
Jan 30, 2023 Jan 30, 2023

Copy link to clipboard


We are working on a heavily automated workflow with lots of assets of the same kind.
Therefore we need a lot of tools and scripts to make it work. To perform an automated Task on a Substance Project per command line, we currently do the following:
* We have a custom plugin location with the necessary sub-directories.
* We set the "SUBSTANCE_PAINTER_PLUGINS_PATH" environment variable to this location.
* We save all necessary arguments, that we want to pass into substance, in other environment variables. (Like a path to a mesh or a resource.)
* The script that we want to run is placed in the custom startup plugins folder.
* Then we start Substance Painter and it will use the startup plugin directory and execute the script from there.Overall this feels very hacky.
And it's a lot of work, because for each script I have to create a different directory with the three mandatory sub-directories. Only then I can create a separate new script in there. We would love to be able to pass the path of Python script right into the command line arguments. Example C:\Program Files\Adobe\Adobe Substance 3D Painter\Adobe Substance 3D Painter.exe -p "C:\Location\Of\My\Script.py" Ideally one should be able to pass on all command line arguments into the python script.
Also the program should return meaningful exit codes or return the exit code, that was called in python. See other programs like Blender as reference.

Idea No status






Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
no replies

Have something to add?

Join the conversation