From ba42dcb7d84f072cc4ccda2a73e1e4e044a916ca Mon Sep 17 00:00:00 2001 From: Loudrob Date: Tue, 21 Jul 2015 12:04:01 -0400 Subject: [PATCH] Top Toons: More appropriate --- toontown/ai/ToontownAIRepository.py | 4 ++-- toontown/uberdog/ToontownUberRepository.py | 4 ++-- ...istributedTopToonsManagerAI.py => TopToonsManagerAI.py} | 3 +-- ...istributedTopToonsManagerUD.py => TopToonsManagerUD.py} | 7 +++---- 4 files changed, 8 insertions(+), 10 deletions(-) rename toontown/uberdog/{DistributedTopToonsManagerAI.py => TopToonsManagerAI.py} (90%) rename toontown/uberdog/{DistributedTopToonsManagerUD.py => TopToonsManagerUD.py} (96%) diff --git a/toontown/ai/ToontownAIRepository.py b/toontown/ai/ToontownAIRepository.py index d272506b..39a4b4c3 100755 --- a/toontown/ai/ToontownAIRepository.py +++ b/toontown/ai/ToontownAIRepository.py @@ -51,7 +51,7 @@ from toontown.toon import NPCToons from toontown.toonbase import ToontownGlobals from toontown.tutorial.TutorialManagerAI import TutorialManagerAI from toontown.uberdog.DistributedPartyManagerAI import DistributedPartyManagerAI -from toontown.uberdog.DistributedTopToonsManagerAI import DistributedTopToonsManagerAI +from toontown.uberdog.TopToonsManagerAI import TopToonsManagerAI #from toontown.uberdog.DistributedLobbyManagerAI import DistributedLobbyManagerAI class ToontownAIRepository(ToontownInternalRepository): @@ -73,7 +73,6 @@ class ToontownAIRepository(ToontownInternalRepository): self.lawOfficeMgr = None self.countryClubMgr = None self.groupManager = GroupManagerAI(self) - self.topToonsMgr = DistributedTopToonsManagerAI(self) self.zoneAllocator = UniqueIdAllocator(ToontownGlobals.DynamicZonesBegin, ToontownGlobals.DynamicZonesEnd) @@ -122,6 +121,7 @@ class ToontownAIRepository(ToontownInternalRepository): self.buildingQueryMgr = DistributedBuildingQueryMgrAI(self) self.buildingQueryMgr.generateWithRequired(2) self.groupManager.generateWithRequired(2) + self.topToonsMgr = TopToonsManagerAI(self) if self.wantKarts: self.leaderboardMgr = LeaderboardMgrAI(self) if self.wantFishing: diff --git a/toontown/uberdog/ToontownUberRepository.py b/toontown/uberdog/ToontownUberRepository.py index 88958d61..e26c536a 100755 --- a/toontown/uberdog/ToontownUberRepository.py +++ b/toontown/uberdog/ToontownUberRepository.py @@ -4,7 +4,7 @@ from otp.distributed.OtpDoGlobals import * from otp.distributed.DistributedDirectoryAI import DistributedDirectoryAI from toontown.distributed.ToontownInternalRepository import ToontownInternalRepository import toontown.minigame.MinigameCreatorAI -from toontown.uberdog.DistributedTopToonsManagerUD import DistributedTopToonsManagerUD +from toontown.uberdog.TopToonsManagerUD import TopToonsManagerUD if config.GetBool('want-rpc-server', False): from toontown.rpc.ToontownRPCServer import ToontownRPCServer @@ -39,5 +39,5 @@ class ToontownUberRepository(ToontownInternalRepository): self.friendsManager = simbase.air.generateGlobalObject(OTP_DO_ID_TTS_FRIENDS_MANAGER, 'TTSFriendsManager') self.globalPartyMgr = simbase.air.generateGlobalObject(OTP_DO_ID_GLOBAL_PARTY_MANAGER, 'GlobalPartyManager') self.groupManager = simbase.air.generateGlobalObject(OPT_DO_ID_GROUP_MANAGER, 'GroupManager') - self.topToonsMgr = DistributedTopToonsManagerUD(self) + self.topToonsMgr = TopToonsManagerUD(self) diff --git a/toontown/uberdog/DistributedTopToonsManagerAI.py b/toontown/uberdog/TopToonsManagerAI.py similarity index 90% rename from toontown/uberdog/DistributedTopToonsManagerAI.py rename to toontown/uberdog/TopToonsManagerAI.py index f91ae38d..5b41ac26 100644 --- a/toontown/uberdog/DistributedTopToonsManagerAI.py +++ b/toontown/uberdog/TopToonsManagerAI.py @@ -1,8 +1,7 @@ -from direct.distributed.DistributedObjectAI import * from direct.showbase.DirectObject import * import TopToonsGlobals -class DistributedTopToonsManagerAI(DirectObject): +class TopToonsManagerAI(DirectObject): def __init__(self, air): self.air = air diff --git a/toontown/uberdog/DistributedTopToonsManagerUD.py b/toontown/uberdog/TopToonsManagerUD.py similarity index 96% rename from toontown/uberdog/DistributedTopToonsManagerUD.py rename to toontown/uberdog/TopToonsManagerUD.py index eb0b55a5..6fd93293 100644 --- a/toontown/uberdog/DistributedTopToonsManagerUD.py +++ b/toontown/uberdog/TopToonsManagerUD.py @@ -2,7 +2,6 @@ from direct.directnotify import DirectNotifyGlobal from direct.fsm.FSM import FSM -from direct.distributed.DistributedObjectUD import * from direct.showbase.DirectObject import * from toontown.toon.ToonDNA import ToonDNA, getSpeciesName import TopToonsGlobals @@ -186,8 +185,8 @@ class SiteUploadFSM(FSM): return (success, error), res -class DistributedTopToonsManagerUD(DirectObject): - notify = DirectNotifyGlobal.directNotify.newCategory('DistributedTopToonsManagerUD') +class TopToonsManagerUD(DirectObject): + notify = DirectNotifyGlobal.directNotify.newCategory('TopToonsManagerUD') def __init__(self, air): self.air = air @@ -225,7 +224,7 @@ class DistributedTopToonsManagerUD(DirectObject): return task.done - taskMgr.doMethodLater(timeToNextMonth() + 1, _nm, 'DistributedTopToonsManagerUD-nextMonth') + taskMgr.doMethodLater(timeToNextMonth() + 1, _nm, 'TopToonsManagerUD-nextMonth') def saveSite(self): if self.air.dbConn: