mirror of
https://github.com/ynput/ayon-core.git
synced 2026-01-02 00:44:52 +01:00
Maya: Refactor Create Rig to new publisher
This commit is contained in:
parent
e57b7aaf17
commit
fadf3a111a
1 changed files with 13 additions and 13 deletions
|
|
@ -1,25 +1,25 @@
|
|||
from maya import cmds
|
||||
|
||||
from openpype.hosts.maya.api import (
|
||||
lib,
|
||||
plugin
|
||||
)
|
||||
from openpype.hosts.maya.api import plugin
|
||||
|
||||
|
||||
class CreateRig(plugin.Creator):
|
||||
class CreateRig(plugin.MayaCreator):
|
||||
"""Artist-friendly rig with controls to direct motion"""
|
||||
|
||||
name = "rigDefault"
|
||||
identifier = "io.openpype.creators.maya.rig"
|
||||
label = "Rig"
|
||||
family = "rig"
|
||||
icon = "wheelchair"
|
||||
|
||||
def process(self):
|
||||
def create(self, subset_name, instance_data, pre_create_data):
|
||||
|
||||
with lib.undo_chunk():
|
||||
instance = super(CreateRig, self).process()
|
||||
instance = super(CreateRig, self).create(subset_name,
|
||||
instance_data,
|
||||
pre_create_data)
|
||||
|
||||
self.log.info("Creating Rig instance set up ...")
|
||||
controls = cmds.sets(name="controls_SET", empty=True)
|
||||
pointcache = cmds.sets(name="out_SET", empty=True)
|
||||
cmds.sets([controls, pointcache], forceElement=instance)
|
||||
instance_node = instance.get("instance_node")
|
||||
|
||||
self.log.info("Creating Rig instance set up ...")
|
||||
controls = cmds.sets(name="controls_SET", empty=True)
|
||||
pointcache = cmds.sets(name="out_SET", empty=True)
|
||||
cmds.sets([controls, pointcache], forceElement=instance_node)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue