Sorry there is no query flag there ...
just simply :

if mc.objExists("g_FIX"):
  mc.delete("g_FIX")

and then continue ..
This way , everytime you run the code you will always end up with
"Ball" node.

On Jan 11, 11:16 am, Melvin3D <[email protected]> wrote:
> Hi there ,
> Check for existence of that name. If you find the name delete it and
> recreate it.
> like:
>
> if mc.objExists("Ball",q=True):
>   mc.delete("Ball")
> continue with your code ......
>
> On Jan 11, 11:10 am, Vitor Lôbo Ramos <[email protected]>
> wrote:
>
> > def test():
>
> >    cmds.sphere(n='ball')
>
> > #END
>
> > If I run the same script twice, the name 'ball', will ball1, ball2,
> > ball3 etc ...
>
> > How do I return to the original name "ball" if you run it more than
> > once?
>
>
-- 
http://groups.google.com/group/python_inside_maya

Reply via email to