Hi all,
This works:
srchDir = GetDir #scripts
scripts = getfiles (srchDir + "\\" + "CoronaConverter_v*.ms")
sort scripts
CoronaConverterlatest = scripts[scripts.count]
global CoronaConverterGUI = try(CoronaConverterNoGui = true)catch()
global CoronaConverterMacro = try(macros.run "Corona Renderer" "CoronaConverter")catch()
if CoronaConverterMacro != false then (
CoronaConverterlatest
try(include "C:\Program Files\Autodesk\3ds Max 2015\scripts\coronaConverter_v1.12.ms")catch()
try(CoronaConverter.destroyGui())catch()
StartCoronaConverter
CoronaConverter.converterSettings.switchRenderEngine = true
CoronaConverter.converterSettings.printInfo = true
CoronaConverter.converterSettings.silent = true
CoronaConverter.converterSettings.useTryCatchBugReporting = true
CoronaConverter.converterTools.resetMtlEdit()
CoronaConverter.converterTools.SetMaxDisplacementLevel 1.0
CoronaConverter.converterTools.showMapsInVP true
CoronaConverter.convertScene()
)
gc()But when I change:
try(include "C:\Program Files\Autodesk\3ds Max 2015\scripts\coronaConverter_v1.12.ms")catch()
To:
try(include CoronaConverterlatest)catch()
It doesn't work with the error described in the subject.
Although running:
CoronaConverterlatest
include CoronaConverterlatest
after the fact runs just fine.
Has anyone came across a similar problem before. Thanks.
Script which this code runs is found on the Corona forum here & here:
https://corona-renderer.com/forum/index.php/topic,126.0.html
http://www.racoon-artworks.de/?p=154
By 3dwannab · 2015-06-16