From 4a12f647ee9696ba56754429f67a8c71bb1cb211 Mon Sep 17 00:00:00 2001 From: Alexander Date: Sat, 8 Aug 2015 22:24:05 -0400 Subject: [PATCH] Fix game crashing now? --- toontown/building/DistributedBuildingMgrAI.py | 4 ++-- toontown/uberdog/ClientServicesManagerUD.py | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/toontown/building/DistributedBuildingMgrAI.py b/toontown/building/DistributedBuildingMgrAI.py index 8bc2f8d8..438e02f6 100755 --- a/toontown/building/DistributedBuildingMgrAI.py +++ b/toontown/building/DistributedBuildingMgrAI.py @@ -197,7 +197,7 @@ class DistributedBuildingMgrAI: if not self.air.dbConn: simbase.backups.save('block-info', (self.air.districtId, self.branchId), backups) else: - street = {'district': self.air.districtId, 'branch': self.branchID} + street = {'district': self.air.districtId, 'branch': self.branchId} try: self.air.dbGlobalCursor.blockInfo.update(street, {'$setOnInsert': street, '$set': {'buildings': backups}}, upsert=True) except AutoReconnect: @@ -209,7 +209,7 @@ class DistributedBuildingMgrAI: blocks = simbase.backups.load('block-info', (self.air.districtId, self.branchId), default={}) return blocks self.air.dbGlobalCursor.blockInfo.ensure_index([('district', 1), ('branch', 1)]) - street = {'district': self.air.districtId, 'branch': self.branchID} + street = {'district': self.air.districtId, 'branch': self.branchId} try: doc = self.air.dbGlobalCursor.blockInfo.find_one(street) except AutoReconnect: diff --git a/toontown/uberdog/ClientServicesManagerUD.py b/toontown/uberdog/ClientServicesManagerUD.py index 680a2bf7..344a27dd 100755 --- a/toontown/uberdog/ClientServicesManagerUD.py +++ b/toontown/uberdog/ClientServicesManagerUD.py @@ -182,7 +182,7 @@ class DeveloperAccountDB(AccountDB): 'notAfter': 0}, callback) -class RemoteAccountDB(AccountDB): +class RemoteAccountDB: # TO DO FOR NAMES: # CURRENTLY IT MAKES n REQUESTS FOR EACH AVATAR # IN THE FUTURE, MAKE ONLY 1 REQUEST @@ -190,6 +190,8 @@ class RemoteAccountDB(AccountDB): # ^ done, check before removing todo note notify = directNotify.newCategory('RemoteAccountDB') + def __init__(self, csm): + self.csm = csm def addNameRequest(self, avId, name, accountID = None): username = avId