Skip to content
This repository has been archived by the owner on Sep 20, 2024. It is now read-only.

Commit

Permalink
Merge pull request #573 from pypeclub/feature/maya-add-look-assigner
Browse files Browse the repository at this point in the history
Maya: add look assigner to pype menu even if scriptsmenu is not available
  • Loading branch information
mkolar authored Oct 2, 2020
2 parents 9eac97e + 826f437 commit 932bc19
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion pype/hosts/maya/menu.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,19 @@ def add_build_workfiles_item():
command=lambda *args: BuildWorkfile().process()
)

def add_look_assigner_item():
import mayalookassigner
cmds.menuItem(
"Look assigner",
parent=pipeline._menu,
command=lambda *args: mayalookassigner.show()
)

log.info("Attempting to install scripts menu..")

add_build_workfiles_item()
add_look_assigner_item()

try:
import scriptsmenu.launchformaya as launchformaya
import scriptsmenu.scriptsmenu as scriptsmenu
Expand All @@ -42,7 +53,6 @@ def add_build_workfiles_item():
"Skipping studio.menu install, because "
"'scriptsmenu' module seems unavailable."
)
add_build_workfiles_item()
return

# load configuration of custom menu
Expand Down

0 comments on commit 932bc19

Please sign in to comment.