Thursday, December 20, 2012

Back to Basics: Hotkeys

Hotkeys are old news for most, but we're going to be posting a lot of scripts so you should know how to use them.


The most basic way to run a script is to copy it into your script editor and press enter:





This is okay, but often you'll want to assign a script to a hotkey on your keyboard so you can easily repeat it. Access the hotkey editor through Window > Settings/Preferences > Hotkey Editor:

 

Once you have the Hotkey Editor open, follow the following instructions to make your hotkey:




1. Scroll down to the 'User' category in the leftmost pane.
2. Click the 'New' button on the far right to make your command. Note that you don't have to assign it to a hotkey immediately.
3. Give it a good name. Or a bad one
4. Copy your command into the command field.
5. Click the accept button.
6. Assign a hotkey to your command. Type the key in the 'Key" field, choose any Control/Option/Command modifier you want, and press Assign. It will overwrite any existing hotkey applied to that key.
7. Click 'Save' on the bottom of the window.

You can also middle mouse drag the actual mel/python code of a script up to a shelf to make a little shelf button.

This stuff is dull and setting it all up at first can be intimidating. But really it's not too tricky and will be well worth your time to figure out.


No comments:

Post a Comment