Revert "Potential street teleport fix"

This reverts commit e0ea00b3bd.
This commit is contained in:
Loudrob 2015-03-29 11:55:35 -04:00
parent 325c705ae0
commit c79f5498e1
3 changed files with 9 additions and 7 deletions

View file

@ -1899,10 +1899,12 @@ class OTPClientRepository(ClientRepositoryBase):
pass
def identifyAvatar(self, doId):
if self.doId2do.has_key(doId):
return self.doId2do[doId]
info = self.doId2do.get(doId)
if info:
return info
else:
return self.identifyFriend(doId)
info = self.identifyFriend(doId)
return info
def sendDisconnect(self):
if self.isConnected():

View file

@ -251,7 +251,7 @@ class PlayerFriendsManager(DistributedObjectGlobal):
return returnList
def identifyAvatar(self, doId):
if base.cr.doId2do.has_key(doId)
if doId in base.cr.doId2do:
return base.cr.doId2do[doId]
else:
return self.identifyFriend(doId)

View file

@ -679,11 +679,11 @@ class ToontownClientRepository(OTPClientRepository.OTPClientRepository):
self.friendsMap[avatar.doId] = avatar
def identifyFriend(self, doId, source = None):
if self.friendsMap.has_key(doId):
if doId in self.friendsMap:
teleportNotify.debug('friend %s in friendsMap' % doId)
return self.friendsMap[doId]
avatar = None
if self.doId2do.has_key(doId):
if doId in self.doId2do:
teleportNotify.debug('found friend %s in doId2do' % doId)
avatar = self.doId2do[doId]
elif self.cache.contains(doId):
@ -716,7 +716,7 @@ class ToontownClientRepository(OTPClientRepository.OTPClientRepository):
return base.cr.playerFriendsManager.getFriendInfo(pId)
def identifyAvatar(self, doId):
if self.doId2do.has_key(doId):
if doId in self.doId2do:
return self.doId2do[doId]
else:
return self.identifyFriend(doId)