Commit Graph

3 Commits

Author SHA1 Message Date
Nicolas Sanchez d519a8b71b Replace removed Python 2 string-module functions
string.find/upper/join and string.letters were removed from the string module in Python 3, so these call sites raise AttributeError (or NameError) when reached. Replaced each with the str method equivalent:

- otp/chat/ChatGlobals.py, ChatManager.py: string.find(message, ...) -> message.find(...)
- otp/level/LevelSpec.py: string.upper(type) -> type.upper()
- toontown/pets/PetBase.py, DistributedPetProxyAI.py, DistributedPetProxy.py: string.upper(valueName[0]) -> valueName[0].upper()
- toontown/pets/PetshopGUI.py: string.join(descList, '\n') -> '\n'.join(descList)
- toontown/shtiker/PhotoAlbumPage.py: string.letters -> string.ascii_letters (and added the missing import string)

string.capwords and string.digits are still in the Py3 string module, so QuestPoster's capwords usage is untouched.
2026-05-29 20:22:17 -05:00
John Cote 3c14c14623 toontown: initial work on python 3.x support 2019-12-30 01:07:56 -05:00
John Cote 2c7d1a27da general: push the 2013 TTO code 2019-11-02 18:27:54 -04:00