On Sun, 25 Oct 2015 4:15 PM Crest Christopher <[email protected]> wrote:
The script calls to be executed as such; Superscript.ui() ? No. "Superscript" is the name of the package (directory). Then you have some module which is the name of your file. So if you file is called myFile.py, then you do import Superscript.myFile Superscript.myFile.ui() AK Eric wrote: tl;dnr this whole thread. But you'd need to: import SuperScript.myModule SuperScript.myModule.myFunc() That's executing the myFunc function in the my myModule.py module living under /SuperScript dir. x:/../../pythonscripts/SuperScript/myModule.py Generally, I don't often put any code in the __init__.py (I do occasionally for very specific reasons). In general they're just there to get your package paths setup right, so you can import everything correctly without any fuss. -- You received this message because you are subscribed to a topic in the Google Groups "Python Programming for Autodesk Maya" group. To unsubscribe from this topic, visit https://groups.google.com/d/topic/python_inside_maya/8SgJdsUZ0b8/unsubscribe . To unsubscribe from this group and all its topics, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/c0949574-6c1c-43a8-9429-263e5b5b1649%40googlegroups.com <https://groups.google.com/d/msgid/python_inside_maya/c0949574-6c1c-43a8-9429-263e5b5b1649%40googlegroups.com?utm_medium=email&utm_source=footer> . For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/562C495E.8050405%40gmail.com <https://groups.google.com/d/msgid/python_inside_maya/562C495E.8050405%40gmail.com?utm_medium=email&utm_source=footer> . For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/CAPGFgA30jVV4gDir33QKW%3DVHLWWhxQ3rNRTP36Mb842S5HPrgg%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
