Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to "verify" your details, making threats, or asking for money, are
spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the
password reset link.
Entire forum
➜ MUSHclient
➜ Python
➜ Saving Lists/Tuples/Dictionaries?
Saving Lists/Tuples/Dictionaries?
|
It is now over 60 days since the last post. This thread is closed.
Refresh page
Posted by
| Chronoti
USA (27 posts) Bio
|
Date
| Mon 27 Oct 2003 02:22 AM (UTC) |
Message
| Alright so I sort of figured this much out, I created a list, when i looked in a room, I saw a set of monsters, which I put in a list, but how can I access that list from outside of that trigger? It seems its not saved anywhere, how would i do save it? | Top |
|
Posted by
| Ked
Russia (524 posts) Bio
|
Date
| Reply #1 on Mon 27 Oct 2003 03:02 AM (UTC) Amended on Mon 27 Oct 2003 03:04 AM (UTC) by Ked
|
Message
| You would probably need to use a script file. Have the trigger call a function in that script file and fill a list variable defined globally. Then you can reuse the list in any other functions as long as you declare it global wherever you want to use it:
def function(name, output, wildcs):
global list
| Top |
|
The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).
To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.
9,669 views.
It is now over 60 days since the last post. This thread is closed.
Refresh page
top