Maya and Mari Scripts
I moved all my scripts to Gumroad!
Maya Hotkeys, Marking Menus and Tricks
s – set key to selected channel in channelbox
$selectedAttrs = `channelBox -q -sma mainChannelBox`;
for( $attr in $selectedAttrs ) {
setKeyframe -at $attr;
}
shift i – toggle isolate selection
$currentPanel = `getPanel -wf`;
$state = `isolateSelect -q -state $currentPanel`;
$state = ($state == 0 ? "1" : "0");
enableIsolateSelect $currentPanel $state;
alt d – duplicate with input connections
duplicate -ic;
One imported snippet of code that I always have in the marking menu with the other cameras. It allows you to swap to the camera named ‘shotCam’.
lookThroughModelPanel shotCam `getPanel -wf`;
Annoyed at Maya not being able to load a friggin plugin? Add this to a file called userSetup.mel.
if(!`pluginInfo -q -l -n vrayformaya`) loadPlugin "vrayformaya";
Reset the locked axis after hitting “w”, “e” or “r” (shortcuts for move, rotate and scale). Add these to the corresponding press hotkeys:
buildTranslateMM;
buildRotateMM;
buildScaleMM;
Add these to the release hotkeys:
destroySTRSMarkingMenu MoveTool;\ndR_setActiveTransformAxis 3;
destroySTRSMarkingMenu RotateTool;\ndR_setActiveTransformAxis 3;
destroySTRSMarkingMenu ScaleTool;\ndR_setActiveTransformAxis 3;