From 7c3fb0d0c5277df87be876de98a85353db2602e7 Mon Sep 17 00:00:00 2001 From: aardschok Date: Tue, 27 Jun 2017 13:57:50 +0200 Subject: [PATCH] cosmetics --- colorbleed/plugins/maya/load/load_model.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/colorbleed/plugins/maya/load/load_model.py b/colorbleed/plugins/maya/load/load_model.py index bfb0decaca..bdcdd56ca2 100644 --- a/colorbleed/plugins/maya/load/load_model.py +++ b/colorbleed/plugins/maya/load/load_model.py @@ -1,6 +1,7 @@ from maya import cmds from avalon import api +from avalon import maya class ModelLoader(api.Loader): @@ -14,7 +15,7 @@ class ModelLoader(api.Loader): representations = ["ma"] def process(self, name, namespace, context): - from avalon import maya + with maya.maintained_selection(): nodes = cmds.file( self.fname, @@ -22,7 +23,7 @@ class ModelLoader(api.Loader): reference=True, returnNewNodes=True, groupReference=True, - groupName=namespace + ":" + name + groupName="{}:{}".format(namespace, name) ) # Assign default shader to meshes