Hi,
Brainspoon got a very good idea that got implemented in Maya Templates ( It will be in XSI and 3ds Max ones also ) : Ability for the Templates to trigger the execution of another script.
To do that I just added 4 function call in each templates, if the functions are defined, they will be executed otherwise nothing will happen.
From those 4 functions callbacks, 2 are pre process callbacks and executed before the Template execution and 2 are post process callbacks executed after the Template execution.
A set of pre / post callbacks is shared among the templates while the other set is specific to each template :
- sIBL_Maya_preProcessCallback()
- sIBL_Maya_VRay_preProcessCallback()
- [... Template Sauce ...]
- sIBL_Maya_postProcessCallback()
- sIBL_Maya_VRay_postProcessCallback()
You basically just need to fill functions like that :
Code:global proc sIBL_Maya_preProcessCallback()
{}
global proc sIBL_Maya_postProcessCallback()
{}
Voilà

KS