From b2d956d1a40f5e3d40fa33a9f01862137e018347 Mon Sep 17 00:00:00 2001 From: John Cote Date: Thu, 5 Dec 2019 23:10:13 -0500 Subject: [PATCH] general: some cleanup --- toontown/ai/ToontownAIRepository.py | 2 +- toontown/ai/WelcomeValleyManagerAI.py | 3 ++- toontown/building/DistributedTrophyMgrAI.py | 8 ++++++-- 3 files changed, 9 insertions(+), 4 deletions(-) diff --git a/toontown/ai/ToontownAIRepository.py b/toontown/ai/ToontownAIRepository.py index 6d2bbca..f46313f 100644 --- a/toontown/ai/ToontownAIRepository.py +++ b/toontown/ai/ToontownAIRepository.py @@ -294,7 +294,7 @@ class ToontownAIRepository(ToontownInternalRepository): return kartPads, kartPadGroups - def findStartingBlocks(self, dnaData, racePad): + def findStartingBlocks(self, dnaData, kartPad): return [] # TODO def findLeaderBoards(self, dnaData, zoneId): diff --git a/toontown/ai/WelcomeValleyManagerAI.py b/toontown/ai/WelcomeValleyManagerAI.py index ccb39b5..c937b13 100644 --- a/toontown/ai/WelcomeValleyManagerAI.py +++ b/toontown/ai/WelcomeValleyManagerAI.py @@ -25,7 +25,8 @@ class WelcomeValleyManagerAI(DistributedObjectAI): if ZoneUtil.isWelcomeValley(zoneId) and not inWelcomeValley: self.air.districtStats.b_setNewAvatarCount(self.air.districtStats.getNewAvatarCount() + 1) self.accept(event, lambda newZoneId, _: self.toonSetZone(doId, newZoneId)) - self.accept(self.air.getAvatarExitEvent(doId), self.toonSetZone, extraArgs=[doId, 2000]) + self.accept(self.air.getAvatarExitEvent(doId), self.toonSetZone, + extraArgs=[doId, ToontownGlobals.ToontownCentral]) elif (not ZoneUtil.isWelcomeValley(zoneId)) and inWelcomeValley: self.air.districtStats.b_setNewAvatarCount(self.air.districtStats.getNewAvatarCount() - 1) self.ignore(event) diff --git a/toontown/building/DistributedTrophyMgrAI.py b/toontown/building/DistributedTrophyMgrAI.py index 450aeba..df35b2a 100644 --- a/toontown/building/DistributedTrophyMgrAI.py +++ b/toontown/building/DistributedTrophyMgrAI.py @@ -5,13 +5,17 @@ from direct.distributed.DistributedObjectAI import DistributedObjectAI class DistributedTrophyMgrAI(DistributedObjectAI): notify = DirectNotifyGlobal.directNotify.newCategory('DistributedTrophyMgrAI') + def __init__(self, air): + DistributedObjectAI.__init__(self, air) + self.leaderInfo = ([], [], []) + def requestTrophyScore(self): pass def getLeaderInfo(self): - return [], [], [] + return self.leaderInfo - def addTrophy(self, *args, **kwargs): + def addTrophy(self, avId, name, numFloors): pass def removeTrophy(self, avId, numFloors):