proc sc_pRigger_GUI()
{
if (`window -exists "sc_pRig_gui"`) deleteUI "sc_pRig_gui";
window -w 150 -h 300 -t "Locator Randomiser" -maximizeButton false -minimizeButton false sc_pRig_gui;
string $layout = `formLayout`;
string $layoutTabs = `tabLayout -innerMarginWidth 5 -innerMarginHeight 5`;
formLayout -edit
-attachForm $layoutTabs "top" 0
-attachForm $layoutTabs"left" 0
-attachForm $layoutTabs "bottom" 0
-attachForm $layoutTabs "right" 0
$layout;
string $base = `rowColumnLayout -numberOfColumns 3
-columnWidth 1 5
-columnWidth 2 200
-columnWidth 3 5`;
button -vis 0;
textFieldGrp -l "Number of Emitters: " -cw2 100 100 -tx 1 numOfEmits;
button -vis 0;
button -vis 0;
textFieldGrp -l "Rig Type: " -cw2 100 100 rigType;
button -vis 0;
button -vis 0;
button -l "Create" -c sc_pRigger_cube;
button -vis 0;
setParent..;
string $geo = `rowColumnLayout -numberOfColumns 5`;
setParent..;
string $forces = `rowColumnLayout -numberOfColumns 5`;
setParent..;
tabLayout -edit
-tabLabel $base "Emitters" -tabLabel $geo "Geometry" -tabLabel $forces "Forces" $layoutTabs;
showWindow sc_pRig_gui;
}
proc sc_pRigger_cube()
{
int $counter = (`textFieldGrp -q -tx numOfEmits`);
if ($counter>0)
{
polyCube -sx $counter;
rename pRigCube;
emitter -pos 0 0 0 -type omni -r 100 -sro 0 -nuv 0 -cye none -cyi 1 -spd 1 -srn 0 -nsp 1 -tsp 0 -mxd 0 -mnd 0 -dx 1 -dy 0 -dz 0 -sp 0 ;
rename pRigEmit;
particle;
rename pRigPart;
}
}
sc_pRigger_GUI()
No comments:
Post a Comment