[Closed] mzp moving file to wrong $temp
Hello, first post here.
I’ve got an issue running an mzp that I made based on the Outliner (and many other) mzp structure.
code in the run.mzp :
name "toolbox"
version 1.0
extract to $temp oolbox
run installer\installer_dialog.ms
drop installer\installer_dialog.ms
clear temp on MAX exit
zipping and running the mzp folder extracts the toolbox folder to the system temp :
C:\Users\me\AppData\Local\Temp
while it should be :
C:\Users\me\AppData\Local\Autodesk\3dsMax\2012 - 64bit\enu emp
I tried with other scripts and the behaviour is correct, while when i do zip and rename myself the folder to .mzp it fails to copy to the correct folder.
I haven’t found any clue on the forum yet.
from the doc
If there is no mzp.run control file in the package, MAXScript will unzip all the files in it to a unique temporary directory in the system temp directory
although i triple-checked the name of my file, the problem is still happening.
It happens also when I unzip a working mzp and zipp it again (with the windows tool send to -> compressed folder) and run it.
In my mzp installers I have:
- install.ms
- run.mzp
- “folderWithFiles” folder. All files that have to be installed are in this folder
My mzp code:
name "miauu"
version 1.00
treeMove "folderWithFiles" to "$temp"
run "install.ms"
drop "install.ms"
clear temp
Works with no errors so far. Tested on
win2000+max9,
winXP, winVista, Win7, Win8 – max2009 to 2014
Thanks for the response but I don’t think that the structure of the mzp is the problem, since when I put myself a copy of my tree in the autodesk temp folder I can run the install without problems.
What I found in the documentation :
If there is no mzp.run control file in the package, MAXScript will unzip all the files in it to a unique temporary directory in the system temp directory and run all the executable script files it finds, in unspecified order.
It seems to be my case since I can get the GUI of my installer but also a bit of scripts running.
Is there any reason that autodesk wouldn’t recognize the mzp.run in my folder after I built it myself ?
(Sorry if my answer comes a bit late, i’m living in france)
Ok, now i feel shameful as it was just winrar who created a new folder level in my zip folder
thanks for the response anyway. Thread can be closed I guess.