Okay, I’ve given this a shot, and it flat-out doesn’t seem to work. Using ProcMon from SysInternals it doesn’t appear that Unity is reading this file at all; it will see the file in Editor folder when it iterates through it, but that’s all that happens - it’s like it ignores it.
As with other posts that were never answered, the PostprocessBuildPlayer does work from the command line. In fact, here it is:
#!/usr/local/bin/perl
open (MYFILE, '>>c:/1.txt');
print MYFILE "Mumble\n";
close (MYFILE);
Has anyone gotten PostprocessBuildPlayer to work under Windows, or is the work-around with a custom menu item to call build the only solution? Can we get a proper answer from Unity Support on this question? It seems to have been a very long-term issue.
Having it work is no problem, but you must write it in a language for which you have installed the environment.
On windows, thats batch script normally unless you installed perl as well - on osx you can use perl cause osx as most *nix have it integrated as part of the core install.
That is the standard stock answer and it doesn’t work - “perl PostprocessBuildPlayer” from the command line in the Assets/Editor folder works with no issues. The documentation says no extension, and the file should be in perl. Perl is installed. Do you have this working yourself under Windows? If so, can you post your working example and show how you have your environment configured?
Ive also had the same problem on windows. I think this is a problem with unity not calling the script properly after building not any problem with the scripts themselves(assuming you run them from the command line and they still work). Has anyone filed a bug report?