8,452
edits
Paradox-01 (talk | contribs) m (one step away from addon creation?) |
Paradox-01 (talk | contribs) mNo edit summary |
||
Line 52: | Line 52: | ||
'''new notes [in progress]''' | '''new notes [in progress]''' | ||
* so, simply putting scripts into folders didn't worked, they must be "plugins" (file extension is the same e.g. vbs but they do also something else) | * so, simply putting scripts into folders didn't worked, they must be "plugins" (file extension is the same e.g. vbs but they do also something else) | ||
* a script can run on | * a script can run on another computer if its content is found under a command, and plugin register that new command(s) | ||
* [...] | * [...] | ||
'''old notes''' | '''old notes''' | ||
* It Seems not to work with script file (but embedded code does), the [http://xsisupport.com/2012/04/30/packaging-toolbars-and-script-commands-into-addons/ alternate method] (File > Add-On > Package... ) doesn't work at all with ModTool ... "Add-Ons cannot be created with Softimage Demo Version." | |||
* The problem with embedded code: | |||
: Let's say you want to integrate a toolbar into the xsiaddon file. The toolbar button was created as '''Script Button''' and holds: ''CreatePrim "Cube", "MeshSurface"'' | |||
: When using that button it will also call the cube's property page. Imagine what happens if you make a script that creates hundreds of objects. Right, the user would have to close all those property pages. | |||
: The property pages (PPG) will not open if the button was created as '''Script Command''' linking to an external script file. But xsiaddon seems unable to ship the script file's location as relative path. The relative path is needed because other user could have Mod Tool installed in a different location. What now? | |||
: '''''ExecuteScript XSIUtils.ResolvePath("$XSI_USERHOME/")''' & "Addons\Oni_TRGV_tools\Application\Plugins\add_TV.vbs"'' This example use ''ExecuteScript'' to lunch a script file and ''XSIUtils.ResolvePath("$XSI_USERHOME/")'' to get the first part of it's location. The rest of the path depends how the author stores the files on the system where the addon was created. | |||
: That combination of embedded code and extern script file could create the cube without opening the PPG. | |||
edits