On Mon, Jun 20, 2016 at 9:21 AM sam williams <[email protected]> wrote:
> i had already done this for a few variables like you show me before. But > is it weird to initialise every variable used throughout the script in a > config module? > Yea it would be weird because they would be out of context and implementation details of the various stuff you are calling. A config module is meant to store setup details and not really a big scratch pad for the ongoing state of the entire operation. It seems to me that we wont be able to achieve much more without doing something like a full code review. Are you saying that you need to pass multiple state objects that you have already created, into your functions? >From the naming, it seemed like one was like, a list, and a counter, etc. They didn't seem like more complex objects. Anyways, you just have to find a way for your operations to be grouped into similar behaviour and store state as opposed to passing the entire state around as large collected of basic objects. > > > > On 19 June 2016 at 22:13, <[email protected]> wrote: > >> i guess i can just go through my script and find all the created >> variables and put them all in the config module. So i can store all my >> variables under one object name. Then i would only need to reference that >> one object for access to any variable i needed. >> >> is this sort of what you're saying? >> >> thanks, >> Sam >> >> -- >> > 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/SvBxVxv7uog/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/ba277fa5-06d4-4e59-91c0-4700e275d8d4%40googlegroups.com >> . >> 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/CA%2BGceHUaybqRjxdbtnj55y2gqz2s0%2BtWEPK0kYd_6PKHg-DR%3Dg%40mail.gmail.com > <https://groups.google.com/d/msgid/python_inside_maya/CA%2BGceHUaybqRjxdbtnj55y2gqz2s0%2BtWEPK0kYd_6PKHg-DR%3Dg%40mail.gmail.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/CAPGFgA3Ak5qHLpTAVD1BCr00G9RqJRcOYVoq%2BZ0_Eq2BX-%2BcgA%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
