From f6781606decaad30e7cf4c6c5d97d3247a2f1620 Mon Sep 17 00:00:00 2001 From: Kayla Man Date: Wed, 17 Jul 2024 19:40:31 +0800 Subject: [PATCH] load ornatrix cache needs to select to show on HairStackDialog --- client/ayon_maya/plugins/load/load_ornatrix_cache.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/client/ayon_maya/plugins/load/load_ornatrix_cache.py b/client/ayon_maya/plugins/load/load_ornatrix_cache.py index 1123ade7..cbfa50e9 100644 --- a/client/ayon_maya/plugins/load/load_ornatrix_cache.py +++ b/client/ayon_maya/plugins/load/load_ornatrix_cache.py @@ -36,13 +36,13 @@ def load(self, context, name=None, namespace=None, data=None): path = self.filepath_from_context(context) settings = self.read_settings(path) - # read the fursettings nodes = [] for setting in settings["nodes"]: nodes.extend(self.create_node(namespace, path, setting)) - # Show dialog so the user can directly start working with the - # newly created nodes. + # Select the node and show dialog so the user can directly + # start working with the newly created nodes. + cmds.select(nodes) cmds.OxShowHairStackDialog() self[:] = nodes @@ -70,6 +70,7 @@ def update(self, container, context): for node in cmds.ls(nodes, type="HairFromGuidesNode"): cmds.setAttr(f"{node}.cacheFilePath", path, type="string") + cmds.select(nodes) # Update the representation cmds.setAttr( container["objectName"] + ".representation",