from memory I think you need to do these 2 things
- _isVirtual I think should return *True* - make sure you inherit from the nt module IE blahNode( pymel.nt.Transform) On Wed, Jun 22, 2011 at 10:25 PM, Geordie Martinez < [email protected]> wrote: > Here is a simple example. > _preCreateVirtual is not being called in this virtual class. I can't > figure out why. Any insight? > > -------CODE > import pymel.all as pm > class blahNode( pm.Transform): > > @classmethod > def _preCreateVirtual(cls, **kwargs ): > print ' _preCreateVirtual ' > return kwargs > > @classmethod > def _isVirtual( cls, obj, name ): > """PyMEL code should not be used inside the callback, only API > and maya.cmds. """ > print '_isVirtual ' > > > pm.factories.registerVirtualClass( blahNode,nameRequired=False) > > loc = pm.spaceLocator() > > > > -- > view archives: http://groups.google.com/group/python_inside_maya > change your subscription settings: > http://groups.google.com/group/python_inside_maya/subscribe > -- David Moulder http://www.google.com/profiles/squish3d -- view archives: http://groups.google.com/group/python_inside_maya change your subscription settings: http://groups.google.com/group/python_inside_maya/subscribe
