From cbc94f56bbf3e00bbb854e6eee574f0aa7ea5eee Mon Sep 17 00:00:00 2001 From: DenialMC Date: Wed, 6 May 2015 21:04:18 +0300 Subject: [PATCH] Added a bunch of new decoration and games, but those games dont work --- toontown/parties/Decoration.py | 32 +------------- toontown/parties/PartyEditor.py | 27 +++--------- toontown/parties/PartyEditorListElement.py | 31 +------------- toontown/parties/PartyGlobals.py | 42 +------------------ toontown/shtiker/EventsPage.py | 2 - toontown/toon/DistributedNPCPartyPerson.py | 4 -- toontown/toon/DistributedNPCPartyPersonAI.py | 6 +-- toontown/toon/NPCToons.py | 5 +-- toontown/toonbase/TTLocalizerEnglish.py | 3 -- toontown/uberdog/DistributedPartyManager.py | 11 ----- toontown/uberdog/DistributedPartyManagerAI.py | 4 -- 11 files changed, 14 insertions(+), 153 deletions(-) diff --git a/toontown/parties/Decoration.py b/toontown/parties/Decoration.py index 43543df9..60dc60f1 100644 --- a/toontown/parties/Decoration.py +++ b/toontown/parties/Decoration.py @@ -123,26 +123,6 @@ class Decoration(NodePath): balloonRight.reparentTo(balloonRightLocator) self.heartBanner.loop('idle') self.heartBanner.reparentTo(self) - elif self.name == 'Hydra' or self.name == 'StageWinter': - if self.name == 'StageWinter': - self.hydra = Actor.Actor('phase_13/models/parties/tt_r_ara_pty_winterProps', {'dance': 'phase_13/models/parties/tt_a_ara_pty_hydra_dance'}) - else: - self.hydra = Actor.Actor('phase_13/models/parties/tt_a_ara_pty_hydra_default', {'dance': 'phase_13/models/parties/tt_a_ara_pty_hydra_dance'}) - st = random.randint(0, 10) - animIval = ActorInterval(self.hydra, 'dance') - animIvalDur = animIval.getDuration() - self.decSfx = loader.loadSfx('phase_13/audio/sfx/tt_s_ara_pty_propsShow_dance.ogg') - soundIval = SoundInterval(self.decSfx, node=self.hydra, listenerNode=base.localAvatar, volume=PartyGlobals.DECORATION_VOLUME, cutOff=PartyGlobals.DECORATION_CUTOFF, duration=animIvalDur) - self.animSeq = Parallel(animIval, soundIval) - self.animSeq.loop(st) - collisions = self.hydra.find('**/*collision*') - collisions.setPos(0, 0, -5) - self.hydra.flattenStrong() - self.hydra.reparentTo(self) - if self.name == 'StageWinter': - stageBounds = self.hydra.find('**/stage').node().getBounds() - self.hydra.node().setBounds(stageBounds) - self.hydra.node().setFinal(1) elif self.name == 'TubeCogVictory': self.tubeCog = Actor.Actor('phase_5.5/models/estate/tt_a_ara_pty_tubeCogVictory_default', {'wave': 'phase_5.5/models/estate/tt_a_ara_pty_tubeCogVictory_wave'}) st = random.randint(0, 10) @@ -179,10 +159,6 @@ class Decoration(NodePath): self.decorationModel = loader.loadModel('phase_13/models/parties/tt_m_ara_pty_cogDoodleVictory') self.decorationModel.reparentTo(self) self.decorationShadow = self.setupAnimSeq() - elif self.name == 'CogIceCreamVictory': - self.decorationModel = loader.loadModel('phase_13/models/parties/tt_m_ara_pty_cogIceCreamVictory') - self.decorationModel.reparentTo(self) - self.decorationShadow = self.setupAnimSeq() elif self.name == 'cogIceCreamWinter': self.decorationModel = loader.loadModel('phase_13/models/parties/tt_m_ara_pty_cogIceCreamWinter') self.decorationModel.reparentTo(self) @@ -247,12 +223,6 @@ class Decoration(NodePath): del self.globeSphere self.partyGlobe.removeNode() del self.partyGlobe - elif self.name == 'Hydra' or self.name == 'StageWinter': - self.cleanUpAnimSequences() - self.hydra.removeNode() - del self.hydra - if hasattr(self, 'decSfx'): - del self.decSfx elif self.name == 'TubeCogVictory': self.cleanUpAnimSequences() self.tubeCog.removeNode() @@ -274,7 +244,7 @@ class Decoration(NodePath): elif self.name == 'CannonVictory': self.cannonVictory.removeNode() del self.cannonVictory - elif self.name == 'CogIceCreamVictory' or self.name == 'CogStatueVictory' or self.name == 'cogIceCreamWinter' or self.name == 'CogStatueWinter': + elif self.name == 'CogStatueVictory' or self.name == 'cogIceCreamWinter' or self.name == 'CogStatueWinter': self.cleanUpAnimSequences() self.decorationModel.removeNode() self.decorationShadow.removeNode() diff --git a/toontown/parties/PartyEditor.py b/toontown/parties/PartyEditor.py index 2bbb3fe2..55d5fb2a 100644 --- a/toontown/parties/PartyEditor.py +++ b/toontown/parties/PartyEditor.py @@ -47,30 +47,15 @@ class PartyEditor(DirectObject, FSM): self.partyPlanner.gui.find('**/activitiesButtonDown_rollover'), self.partyPlanner.gui.find('**/activitiesButtonDown_inactive')), incButton_relief=None, incButton_pos=(-0.05, 0.0, -0.94), itemFrame_pos=(pos[0], pos[1], pos[2] + 0.04), itemFrame_relief=None, numItemsVisible=1, items=[]) holidayIds = base.cr.newsManager.getHolidayIdList() - isWinter = ToontownGlobals.WINTER_DECORATIONS in holidayIds or ToontownGlobals.WACKY_WINTER_DECORATIONS in holidayIds - isVictory = ToontownGlobals.VICTORY_PARTY_HOLIDAY in holidayIds - isValentine = ToontownGlobals.VALENTINES_DAY in holidayIds for activityId in PartyGlobals.PartyEditorActivityOrder: - if not isVictory and activityId in PartyGlobals.VictoryPartyActivityIds or not isWinter and activityId in PartyGlobals.WinterPartyActivityIds or not isValentine and activityId in PartyGlobals.ValentinePartyActivityIds: - pass - elif isVictory and activityId in PartyGlobals.VictoryPartyReplacementActivityIds or isWinter and activityId in PartyGlobals.WinterPartyReplacementActivityIds or isValentine and activityId in PartyGlobals.ValentinePartyReplacementActivityIds: - pass - else: - pele = PartyEditorListElement(self, activityId) - self.elementList.addItem(pele) - if activityId == PartyGlobals.ActivityIds.PartyClock: - self.partyClockElement = pele + pele = PartyEditorListElement(self, activityId) + self.elementList.addItem(pele) + if activityId == PartyGlobals.ActivityIds.PartyClock: + self.partyClockElement = pele for decorationId in PartyGlobals.DecorationIds: - if not isVictory and decorationId in PartyGlobals.VictoryPartyDecorationIds or not isWinter and decorationId in PartyGlobals.WinterPartyDecorationIds or not isValentine and decorationId in PartyGlobals.ValentinePartyDecorationIds: - pass - elif isVictory and decorationId in PartyGlobals.VictoryPartyReplacementDecorationIds or isValentine and decorationId in PartyGlobals.ValentinePartyReplacementDecorationIds: - pass - elif decorationId in PartyGlobals.TTUUnreleasedDecor: - pass - else: - pele = PartyEditorListElement(self, decorationId, isDecoration=True) - self.elementList.addItem(pele) + pele = PartyEditorListElement(self, decorationId, isDecoration=True) + self.elementList.addItem(pele) self.elementList.refresh() self.elementList['command'] = self.scrollItemChanged diff --git a/toontown/parties/PartyEditorListElement.py b/toontown/parties/PartyEditorListElement.py index 4c9e1bd1..85c4087a 100644 --- a/toontown/parties/PartyEditorListElement.py +++ b/toontown/parties/PartyEditorListElement.py @@ -13,8 +13,6 @@ class PartyEditorListElement(DirectButton): self.partyEditor = partyEditor self.id = id self.isDecoration = isDecoration - self.unreleased = self.calcUnreleased(id) - self.comingSoonTextScale = 1.0 if self.isDecoration: self.name = TTLocalizer.PartyDecorationNameDict[self.id]['editor'] colorList = ((1.0, 0.0, 1.0, 1.0), @@ -22,10 +20,8 @@ class PartyEditorListElement(DirectButton): (0.0, 1.0, 1.0, 1.0), (0.5, 0.5, 0.5, 1.0)) assetName = PartyGlobals.DecorationIds.getString(self.id) - if assetName == 'Hydra': - assetName = 'StageSummer' geom = self.partyEditor.decorationModels.find('**/partyDecoration_%s' % assetName) - if geom.isEmpty() or self.unreleased: + if geom.isEmpty(): helpGui = loader.loadModel('phase_3.5/models/gui/tt_m_gui_brd_help') helpImageList = (helpGui.find('**/tt_t_gui_brd_helpUp'), helpGui.find('**/tt_t_gui_brd_helpDown'), @@ -35,12 +31,11 @@ class PartyEditorListElement(DirectButton): geom3_color = (0.5, 0.5, 0.5, 1.0) scale = Vec3(2.5, 2.5, 2.5) geom_pos = (0.0, 0.0, 0.0) - self.comingSoonTextScale = 0.035 else: geom_pos = (0.0, 0.0, -3.0) geom3_color = (0.5, 0.5, 0.5, 1.0) scale = Vec3(0.06, 0.0001, 0.06) - if self.id in [PartyGlobals.DecorationIds.CogStatueVictory, PartyGlobals.DecorationIds.TubeCogVictory, PartyGlobals.DecorationIds.CogIceCreamVictory]: + if self.id in [PartyGlobals.DecorationIds.CogStatueVictory, PartyGlobals.DecorationIds.TubeCogVictory]: geom_pos = (0.0, 0.0, -3.9) scale = Vec3(0.05, 0.0001, 0.05) else: @@ -58,7 +53,6 @@ class PartyEditorListElement(DirectButton): scale = 0.35 geom3_color = (0.5, 0.5, 0.5, 1.0) geom_pos = (0.0, 0.0, 0.0) - self.comingSoonTextScale = 0.25 optiondefs = (('geom', geom, None), ('geom3_color', geom3_color, None), ('geom_pos', geom_pos, None), @@ -80,23 +74,6 @@ class PartyEditorListElement(DirectButton): self.partyEditorGridElements.append(PartyEditorGridElement(self.partyEditor, self.id, self.isDecoration, self.checkSoldOutAndAffordability)) self.activeGridElementIndex = -1 - self.adjustForUnreleased() - return - - def calcUnreleased(self, id): - if base.cr.partyManager.allowUnreleasedClient(): - self.unreleased = False - elif self.isDecoration: - self.unreleased = id in PartyGlobals.UnreleasedDecorationIds - else: - self.unreleased = id in PartyGlobals.UnreleasedActivityIds - return self.unreleased - - def adjustForUnreleased(self): - if self.unreleased: - textScale = self.comingSoonTextScale - comingSoon = DirectLabel(parent=self, text=TTLocalizer.PartyPlannerComingSoon, text_scale=textScale, text_fg=(1.0, 0, 0, 1.0), text_shadow=(0, 0, 0, 1), relief=None) - self['state'] = DirectGuiGlobals.DISABLED return def clearPartyGrounds(self): @@ -157,10 +134,6 @@ class PartyEditorListElement(DirectButton): self['state'] = DirectGuiGlobals.NORMAL self.partyEditor.partyPlanner.elementBuyButton['text'] = TTLocalizer.PartyPlannerBuy self.partyEditor.partyPlanner.elementBuyButton['state'] = DirectGuiGlobals.NORMAL - if self.unreleased: - self['state'] = DirectGuiGlobals.DISABLED - self.partyEditor.partyPlanner.elementBuyButton['text'] = TTLocalizer.PartyPlannerCantBuy - self.partyEditor.partyPlanner.elementBuyButton['state'] = DirectGuiGlobals.DISABLED def clicked(self, mouseEvent): PartyEditorListElement.notify.debug("Element %s's icon was clicked" % self.name) diff --git a/toontown/parties/PartyGlobals.py b/toontown/parties/PartyGlobals.py index a848f417..cb04ef98 100644 --- a/toontown/parties/PartyGlobals.py +++ b/toontown/parties/PartyGlobals.py @@ -110,14 +110,6 @@ PartyEditorActivityOrder = [ ActivityIds.PartyClock, ActivityIds.PartyCog, ActivityIds.PartyWinterCog, ActivityIds.PartyFireworks] -UnreleasedActivityIds = (ActivityIds.PartyWinterCog, - ActivityIds.PartyValentineJukebox, - ActivityIds.PartyValentineJukebox40, - ActivityIds.PartyValentineTrampoline, - ActivityIds.PartyWinterTrampoline, - ActivityIds.PartyWinterCatch, - ActivityIds.PartyValentineDance, - ActivityIds.PartyValentineDance20) MutuallyExclusiveActivities = ((ActivityIds.PartyJukebox, ActivityIds.PartyJukebox40), (ActivityIds.PartyValentineJukebox, ActivityIds.PartyValentineJukebox40), (ActivityIds.PartyDance, ActivityIds.PartyDance20), @@ -152,41 +144,22 @@ DecorationIds = PythonUtil.Enum(('BalloonAnvil', 'HeartTarget', 'HeartBanner', 'FlyingHeart', - 'Hydra', 'BannerVictory', 'CannonVictory', 'CogStatueVictory', 'TubeCogVictory', - 'CogIceCreamVictory', 'cogIceCreamWinter', 'StageWinter', 'CogStatueWinter', 'snowman', 'snowDoodle', 'BalloonAnvilValentine')) -TTUUnreleasedDecor = [DecorationIds.HeartTarget, - DecorationIds.HeartBanner, - DecorationIds.FlyingHeart, - DecorationIds.Hydra, - DecorationIds.BannerVictory, - DecorationIds.CannonVictory, - DecorationIds.CogStatueVictory, - DecorationIds.TubeCogVictory, - DecorationIds.CogIceCreamVictory, - DecorationIds.cogIceCreamWinter, - DecorationIds.StageWinter, - DecorationIds.CogStatueWinter, - DecorationIds.snowman, - DecorationIds.snowDoodle, - DecorationIds.BalloonAnvilValentine] DECORATION_VOLUME = 1.0 DECORATION_CUTOFF = 45 -VictoryPartyDecorationIds = frozenset([DecorationIds.Hydra, - DecorationIds.BannerVictory, +VictoryPartyDecorationIds = frozenset([DecorationIds.BannerVictory, DecorationIds.CannonVictory, DecorationIds.CogStatueVictory, - DecorationIds.TubeCogVictory, - DecorationIds.CogIceCreamVictory]) + DecorationIds.TubeCogVictory]) WinterPartyDecorationIds = frozenset([DecorationIds.cogIceCreamWinter, DecorationIds.StageWinter, DecorationIds.CogStatueWinter, @@ -198,7 +171,6 @@ ValentinePartyDecorationIds = frozenset([DecorationIds.BalloonAnvilValentine, DecorationIds.HeartTarget, DecorationIds.FlyingHeart]) ValentinePartyReplacementDecorationIds = frozenset([DecorationIds.BalloonAnvil, DecorationIds.BannerJellyBean]) -UnreleasedDecorationIds = () GoToPartyStatus = PythonUtil.Enum(('AllowedToGo', 'PartyFull', 'PrivateParty', @@ -418,11 +390,6 @@ DecorationInformationDict = {DecorationIds.BalloonAnvil: {'cost': int(10 * Party 'numberPerPurchase': 1, 'limitPerParty': 5, 'gridAsset': 'decoration_1x1'}, - DecorationIds.Hydra: {'cost': int(25 * PartyCostMultiplier), - 'gridsize': (2, 2), - 'numberPerPurchase': 1, - 'limitPerParty': 5, - 'gridAsset': 'decoration_propStage_2x2'}, DecorationIds.BannerVictory: {'cost': int(25 * PartyCostMultiplier), 'gridsize': (1, 1), 'numberPerPurchase': 1, @@ -443,11 +410,6 @@ DecorationInformationDict = {DecorationIds.BalloonAnvil: {'cost': int(10 * Party 'numberPerPurchase': 1, 'limitPerParty': 5, 'gridAsset': 'decoration_1x1'}, - DecorationIds.CogIceCreamVictory: {'cost': int(25 * PartyCostMultiplier), - 'gridsize': (1, 1), - 'numberPerPurchase': 1, - 'limitPerParty': 5, - 'gridAsset': 'decoration_1x1'}, DecorationIds.cogIceCreamWinter: {'cost': int(25 * PartyCostMultiplier), 'gridsize': (1, 1), 'numberPerPurchase': 1, diff --git a/toontown/shtiker/EventsPage.py b/toontown/shtiker/EventsPage.py index 3567b350..12d7c50d 100644 --- a/toontown/shtiker/EventsPage.py +++ b/toontown/shtiker/EventsPage.py @@ -157,8 +157,6 @@ class EventsPage(ShtikerPage.ShtikerPage): else: textForDecoration = decorationName + ' x ' + str(count) assetName = PartyGlobals.DecorationIds.getString(decorBase.decorId) - if assetName == 'Hydra': - assetName = 'StageSummer' label = DirectLabel(relief=None, geom=self.decorationModels.find('**/partyDecoration_%s' % assetName), text=textForDecoration, text_scale=TTLocalizer.EPdecorationItemLabel, text_align=TextNode.ACenter, text_pos=(-0.01, -0.43), text_wordwrap=7.0) label['geom_scale'] = (2.6, 0.01, 0.05) label['geom_pos'] = (0.0, 0.0, -0.33) diff --git a/toontown/toon/DistributedNPCPartyPerson.py b/toontown/toon/DistributedNPCPartyPerson.py index 3760ceb4..b8f2c002 100644 --- a/toontown/toon/DistributedNPCPartyPerson.py +++ b/toontown/toon/DistributedNPCPartyPerson.py @@ -161,10 +161,6 @@ class DistributedNPCPartyPerson(DistributedNPCToonBase): chatStr = TTLocalizer.PartyPlannerHostingTooMany self.setChatAbsolute(chatStr, CFSpeech | CFTimeout) self.resetPartyPerson() - elif mode == NPCToons.PARTY_MOVIE_COMINGSOON: - chatStr = TTLocalizer.PartyPlannerNpcComingSoon - self.setChatAbsolute(chatStr, CFSpeech | CFTimeout) - self.resetPartyPerson() elif mode == NPCToons.PARTY_MOVIE_MINCOST: chatStr = TTLocalizer.PartyPlannerNpcMinCost % PartyGlobals.MinimumPartyCost self.setChatAbsolute(chatStr, CFSpeech | CFTimeout) diff --git a/toontown/toon/DistributedNPCPartyPersonAI.py b/toontown/toon/DistributedNPCPartyPersonAI.py index 2188f6e2..9069fecf 100644 --- a/toontown/toon/DistributedNPCPartyPersonAI.py +++ b/toontown/toon/DistributedNPCPartyPersonAI.py @@ -30,11 +30,7 @@ class DistributedNPCPartyPersonAI(DistributedNPCToonBaseAI): self.busy = avId self.acceptOnce(self.air.getAvatarExitEvent(avId), self.__handleUnexpectedExit, extraArgs=[avId]) parties = av.hostedParties - if not self.air.partyManager.canBuyParties(): - flag = NPCToons.PARTY_MOVIE_COMINGSOON - self.d_setMovie(avId, flag) - self.sendClearMovie(None) - elif av.getTotalMoney() < PartyGlobals.MinimumPartyCost: + if av.getTotalMoney() < PartyGlobals.MinimumPartyCost: flag = NPCToons.PARTY_MOVIE_MINCOST self.d_setMovie(avId, flag) self.sendClearMovie(None) diff --git a/toontown/toon/NPCToons.py b/toontown/toon/NPCToons.py index 841c2f58..a6ab3356 100644 --- a/toontown/toon/NPCToons.py +++ b/toontown/toon/NPCToons.py @@ -49,9 +49,8 @@ PARTY_MOVIE_START = 1 PARTY_MOVIE_COMPLETE = 2 PARTY_MOVIE_ALREADYHOSTING = 3 PARTY_MOVIE_MAYBENEXTTIME = 4 -PARTY_MOVIE_COMINGSOON = 6 -PARTY_MOVIE_MINCOST = 7 -PARTY_MOVIE_TIMEOUT = 8 +PARTY_MOVIE_MINCOST = 6 +PARTY_MOVIE_TIMEOUT = 7 BLOCKER_MOVIE_CLEAR = 0 BLOCKER_MOVIE_START = 1 BLOCKER_MOVIE_TIMEOUT = 8 diff --git a/toontown/toonbase/TTLocalizerEnglish.py b/toontown/toonbase/TTLocalizerEnglish.py index 0e989eed..d4059f27 100644 --- a/toontown/toonbase/TTLocalizerEnglish.py +++ b/toontown/toonbase/TTLocalizerEnglish.py @@ -3463,8 +3463,6 @@ PartyPlannerInvitationWhoseSentence = '%s Party' PartyPlannerInvitationTheme = 'Theme' PartyPlannerInvitationWhenSentence = 'It will be on %s,\nat %s Toontown Time.\nHope you can make it!' PartyPlannerInvitationWhenSentenceNoFriends = 'It will be on %s,\nat %s Toontown Time.\nToontastic!' -PartyPlannerComingSoon = 'Coming Soon' -PartyPlannerCantBuy = "Can't Buy" PartyPlannerGenericName = 'Party Planner' PartyJukeboxOccupied = 'Someone else is using the jukebox. Try again later.' PartyJukeboxNowPlaying = 'The song you chose is now playing on the jukebox!' @@ -3685,7 +3683,6 @@ PartyDoYouWantToPlan = 'Would you like to plan a new party right now?' PartyPlannerOnYourWay = 'Have fun planning your party!' PartyPlannerMaybeNextTime = 'Maybe next time. Have a good day!' PartyPlannerHostingTooMany = 'You can only host one party at a time, sorry.' -PartyPlannerNpcComingSoon = 'Parties are coming soon! Try again later.' PartyPlannerNpcMinCost = 'It costs a minimum of %d Jellybeans to plan a party.' PartyHatPublicPartyChoose = 'Do you want to go to the 1st available public party?' PartyGateTitle = 'Public Parties' diff --git a/toontown/uberdog/DistributedPartyManager.py b/toontown/uberdog/DistributedPartyManager.py index 8e732f15..14aa3979 100644 --- a/toontown/uberdog/DistributedPartyManager.py +++ b/toontown/uberdog/DistributedPartyManager.py @@ -16,7 +16,6 @@ class DistributedPartyManager(DistributedObject): def __init__(self, cr): DistributedObject.__init__(self, cr) base.cr.partyManager = self - self.allowUnreleased = False self.partyPlannerStyle = None self.partyPlannerName = None self.showDoid = False @@ -42,16 +41,6 @@ class DistributedPartyManager(DistributedObject): def deallocateZoneIdFromPlannedParty(self, zoneId): self.sendUpdate('freeZoneIdFromPlannedParty', [base.localAvatar.doId, zoneId]) - def allowUnreleasedClient(self): - return self.allowUnreleased - - def setAllowUnreleaseClient(self, newValue): - self.allowUnreleased = newValue - - def toggleAllowUnreleasedClient(self): - self.allowUnreleased = not self.allowUnreleased - return self.allowUnreleased - def sendAddParty(self, hostId, startTime, endTime, isPrivate, inviteTheme, activities, decorations, inviteeIds): self.sendUpdate('addPartyRequest', [hostId, startTime, diff --git a/toontown/uberdog/DistributedPartyManagerAI.py b/toontown/uberdog/DistributedPartyManagerAI.py index fc021d58..4c59acfd 100644 --- a/toontown/uberdog/DistributedPartyManagerAI.py +++ b/toontown/uberdog/DistributedPartyManagerAI.py @@ -57,10 +57,6 @@ class DistributedPartyManagerAI(DistributedObjectAI): # well fuck. ud died. self.notify.warning("uberdog lost!") - def canBuyParties(self): - return True - - def addPartyRequest(self, hostId, startTime, endTime, isPrivate, inviteTheme, activities, decorations, inviteeIds): if hostId != simbase.air.getAvatarIdFromSender(): self.air.writeServerEvent('suspicious',simbase.air.getAvatarIdFromSender(),'Toon tried to create a party as someone else!')