Quantcast
Channel: mel wiki
Viewing all articles
Browse latest Browse all 610

PyMel : Why doesn't my scriptTable creation code work?

$
0
0
So, it looks like the scriptTable is broken in Maya 2016 PyMel. Here's a hack around it: Make a regular maya.cmds wrapper for it, when created.
def scriptTable(*args, **kwargs):
    """
    PyMel errors when trying to execute the cellChangedCmd callback, but Python
    commands work, so we have to wrap our scriptTable calls in this hack.
    """
    import maya.cmds as mc
    return mc.scriptTable(*args, **kwargs)

Viewing all articles
Browse latest Browse all 610

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>