Author Topic: plugin environment variable not working  (Read 547 times)

Hey Guys,
I'm exploring the new python plugins for painter, pretty happy to have this finally.
However, I'm trying to boot strap a plugin using the documented environment variable "SUBSTANCE_PAINTER_PLUGINS_PATH," and I'm finding some bizarre behavior.

I'll add a link to a zip file containing the batch file I've set up to test and replicate the issue, as well as a test plugin directory I've made.
https://drive.google.com/open?id=1z0n4OLciUvSXrI3HrEfDIb0PKL6Kvdo

The fundamental issue is.
When we add the environment variable in DOS and run painter,
painter does not pick up the new path (the hello plugin is not loaded).
If we try to call the environment key though python in painter, we get a key error.
However, we can tell that the variable is in fact in the environment as we have a javascript plugin that can print the window environment
Our test is very simple. Here's what are batch file is doing.

Code: [Select]
set SUBSTANCE_PAINTER_PLUGINS_PATH = %cd%\module
call "C:\Program Files\Allegorithmic\Substance Painter\Substance Painter.exe"


https://drive.google.com/open?id=1TttdHnt0A0UhuYsKfY1x1TO8DNazgErV
Can someone clue me in as to what I might be doing wrong?
Last Edit: May 13, 2020, 07:07:08 pm
Senior Technical Artist
Bethesda Game Studios

Can someone shed some light on this, please?
it's literally been months :D
Senior Technical Artist
Bethesda Game Studios