diff --git a/toontown/hood/HydrantOneAnimatedProp.py b/toontown/hood/HydrantOneAnimatedProp.py new file mode 100644 index 00000000..71f2bdde --- /dev/null +++ b/toontown/hood/HydrantOneAnimatedProp.py @@ -0,0 +1,32 @@ +from toontown.hood import ZeroAnimatedProp +from toontown.toonbase import ToontownGlobals +from direct.directnotify import DirectNotifyGlobal + +class HydrantOneAnimatedProp(ZeroAnimatedProp.ZeroAnimatedProp): + notify = DirectNotifyGlobal.directNotify.newCategory('HydrantOneAnimatedProp') + PauseTimeMult = base.config.GetFloat('zero-pause-mult', 1.0) + PhaseInfo = {0: ('tt_a_ara_ttc_hydrant_firstMoveArmUp1', 40 * PauseTimeMult), + 1: ('tt_a_ara_ttc_hydrant_firstMoveStruggle', 20 * PauseTimeMult), + 2: ('tt_a_ara_ttc_hydrant_firstMoveArmUp2', 10 * PauseTimeMult), + 3: ('tt_a_ara_ttc_hydrant_firstMoveJump', 8 * PauseTimeMult), + 4: ('tt_a_ara_ttc_hydrant_firstMoveJumpBalance', 6 * PauseTimeMult), + 5: ('tt_a_ara_ttc_hydrant_firstMoveArmUp3', 4 * PauseTimeMult), + 6: ('tt_a_ara_ttc_hydrant_firstMoveJumpSpin', 2 * PauseTimeMult)} + PhaseWeStartAnimating = 3 + + def __init__(self, node): + ZeroAnimatedProp.ZeroAnimatedProp.__init__(self, node, 'hydrant', self.PhaseInfo, ToontownGlobals.HYDRANT_ZERO_HOLIDAY) + + def startIfNeeded(self): + try: + self.curPhase = self.getPhaseToRun() + if self.curPhase >= self.PhaseWeStartAnimating: + self.request('DoAnim') + except: + pass + + def handleNewPhase(self, newPhase): + if newPhase < self.PhaseWeStartAnimating: + self.request('Off') + else: + self.startIfNeeded() diff --git a/toontown/hood/HydrantTwoAnimatedProp.py b/toontown/hood/HydrantTwoAnimatedProp.py new file mode 100644 index 00000000..c94435ec --- /dev/null +++ b/toontown/hood/HydrantTwoAnimatedProp.py @@ -0,0 +1,32 @@ +from toontown.hood import ZeroAnimatedProp +from toontown.toonbase import ToontownGlobals +from direct.directnotify import DirectNotifyGlobal + +class HydrantTwoAnimatedProp(ZeroAnimatedProp.ZeroAnimatedProp): + notify = DirectNotifyGlobal.directNotify.newCategory('HydrantTwoAnimatedProp') + PauseTimeMult = base.config.GetFloat('zero-pause-mult', 1.0) + PhaseInfo = {0: ('tt_a_ara_ttc_hydrant_firstMoveArmUp1', 40 * PauseTimeMult), + 1: ('tt_a_ara_ttc_hydrant_firstMoveStruggle', 20 * PauseTimeMult), + 2: ('tt_a_ara_ttc_hydrant_firstMoveArmUp2', 10 * PauseTimeMult), + 3: ('tt_a_ara_ttc_hydrant_firstMoveJump', 8 * PauseTimeMult), + 4: ('tt_a_ara_ttc_hydrant_firstMoveJumpBalance', 6 * PauseTimeMult), + 5: ('tt_a_ara_ttc_hydrant_firstMoveArmUp3', 4 * PauseTimeMult), + 6: ('tt_a_ara_ttc_hydrant_firstMoveJumpSpin', 2 * PauseTimeMult)} + PhaseWeStartAnimating = 5 + + def __init__(self, node): + ZeroAnimatedProp.ZeroAnimatedProp.__init__(self, node, 'hydrant', self.PhaseInfo, ToontownGlobals.HYDRANT_ZERO_HOLIDAY) + + def startIfNeeded(self): + try: + self.curPhase = self.getPhaseToRun() + if self.curPhase >= self.PhaseWeStartAnimating: + self.request('DoAnim') + except: + pass + + def handleNewPhase(self, newPhase): + if newPhase < self.PhaseWeStartAnimating: + self.request('Off') + else: + self.startIfNeeded() diff --git a/toontown/hood/HydrantZeroAnimatedProp.py b/toontown/hood/HydrantZeroAnimatedProp.py new file mode 100644 index 00000000..98249ad1 --- /dev/null +++ b/toontown/hood/HydrantZeroAnimatedProp.py @@ -0,0 +1,17 @@ +from toontown.hood import ZeroAnimatedProp +from toontown.toonbase import ToontownGlobals +from direct.directnotify import DirectNotifyGlobal + +class HydrantZeroAnimatedProp(ZeroAnimatedProp.ZeroAnimatedProp): + notify = DirectNotifyGlobal.directNotify.newCategory('HydrantZeroAnimatedProp') + PauseTimeMult = base.config.GetFloat('zero-pause-mult', 1.0) + PhaseInfo = {0: ('tt_a_ara_ttc_hydrant_firstMoveArmUp1', 40 * PauseTimeMult), + 1: ('tt_a_ara_ttc_hydrant_firstMoveStruggle', 20 * PauseTimeMult), + 2: ('tt_a_ara_ttc_hydrant_firstMoveArmUp2', 10 * PauseTimeMult), + 3: ('tt_a_ara_ttc_hydrant_firstMoveJump', 8 * PauseTimeMult), + 4: ('tt_a_ara_ttc_hydrant_firstMoveJumpBalance', 6 * PauseTimeMult), + 5: ('tt_a_ara_ttc_hydrant_firstMoveArmUp3', 4 * PauseTimeMult), + 6: ('tt_a_ara_ttc_hydrant_firstMoveJumpSpin', 2 * PauseTimeMult)} + + def __init__(self, node): + ZeroAnimatedProp.ZeroAnimatedProp.__init__(self, node, 'hydrant', self.PhaseInfo, ToontownGlobals.HYDRANT_ZERO_HOLIDAY) diff --git a/toontown/hood/MailboxOneAnimatedProp.py b/toontown/hood/MailboxOneAnimatedProp.py new file mode 100644 index 00000000..26ca187d --- /dev/null +++ b/toontown/hood/MailboxOneAnimatedProp.py @@ -0,0 +1,32 @@ +from toontown.hood import ZeroAnimatedProp +from toontown.toonbase import ToontownGlobals +from direct.directnotify import DirectNotifyGlobal + +class MailboxOneAnimatedProp(ZeroAnimatedProp.ZeroAnimatedProp): + notify = DirectNotifyGlobal.directNotify.newCategory('MailboxOneAnimatedProp') + PauseTimeMult = base.config.GetFloat('zero-pause-mult', 1.0) + PhaseInfo = {0: ('tt_a_ara_dod_mailbox_firstMoveFlagSpin1', 40 * PauseTimeMult), + 1: (('tt_a_ara_dod_mailbox_firstMoveStruggle', 'tt_a_ara_dod_mailbox_firstMoveJump'), 20 * PauseTimeMult), + 2: ('tt_a_ara_dod_mailbox_firstMoveFlagSpin2', 10 * PauseTimeMult), + 3: ('tt_a_ara_dod_mailbox_firstMoveFlagSpin3', 8 * PauseTimeMult), + 4: ('tt_a_ara_dod_mailbox_firstMoveJumpSummersault', 6 * PauseTimeMult), + 5: ('tt_a_ara_dod_mailbox_firstMoveJumpFall', 4 * PauseTimeMult), + 6: ('tt_a_ara_dod_mailbox_firstMoveJump3Summersaults', 2 * PauseTimeMult)} + PhaseWeStartAnimating = 3 + + def __init__(self, node): + ZeroAnimatedProp.ZeroAnimatedProp.__init__(self, node, 'mailbox', self.PhaseInfo, ToontownGlobals.MAILBOX_ZERO_HOLIDAY) + + def startIfNeeded(self): + try: + self.curPhase = self.getPhaseToRun() + if self.curPhase >= self.PhaseWeStartAnimating: + self.request('DoAnim') + except: + pass + + def handleNewPhase(self, newPhase): + if newPhase < self.PhaseWeStartAnimating: + self.request('Off') + else: + self.startIfNeeded() diff --git a/toontown/hood/MailboxTwoAnimatedProp.py b/toontown/hood/MailboxTwoAnimatedProp.py new file mode 100644 index 00000000..8c2472a7 --- /dev/null +++ b/toontown/hood/MailboxTwoAnimatedProp.py @@ -0,0 +1,32 @@ +from toontown.hood import ZeroAnimatedProp +from toontown.toonbase import ToontownGlobals +from direct.directnotify import DirectNotifyGlobal + +class MailboxTwoAnimatedProp(ZeroAnimatedProp.ZeroAnimatedProp): + notify = DirectNotifyGlobal.directNotify.newCategory('MailboxTwoAnimatedProp') + PauseTimeMult = base.config.GetFloat('zero-pause-mult', 1.0) + PhaseInfo = {0: ('tt_a_ara_dod_mailbox_firstMoveFlagSpin1', 40 * PauseTimeMult), + 1: (('tt_a_ara_dod_mailbox_firstMoveStruggle', 'tt_a_ara_dod_mailbox_firstMoveJump'), 20 * PauseTimeMult), + 2: ('tt_a_ara_dod_mailbox_firstMoveFlagSpin2', 10 * PauseTimeMult), + 3: ('tt_a_ara_dod_mailbox_firstMoveFlagSpin3', 8 * PauseTimeMult), + 4: ('tt_a_ara_dod_mailbox_firstMoveJumpSummersault', 6 * PauseTimeMult), + 5: ('tt_a_ara_dod_mailbox_firstMoveJumpFall', 4 * PauseTimeMult), + 6: ('tt_a_ara_dod_mailbox_firstMoveJump3Summersaults', 2 * PauseTimeMult)} + PhaseWeStartAnimating = 5 + + def __init__(self, node): + ZeroAnimatedProp.ZeroAnimatedProp.__init__(self, node, 'mailbox', self.PhaseInfo, ToontownGlobals.MAILBOX_ZERO_HOLIDAY) + + def startIfNeeded(self): + try: + self.curPhase = self.getPhaseToRun() + if self.curPhase >= self.PhaseWeStartAnimating: + self.request('DoAnim') + except: + pass + + def handleNewPhase(self, newPhase): + if newPhase < self.PhaseWeStartAnimating: + self.request('Off') + else: + self.startIfNeeded() diff --git a/toontown/hood/MailboxZeroAnimatedProp.py b/toontown/hood/MailboxZeroAnimatedProp.py new file mode 100644 index 00000000..2ccdf35b --- /dev/null +++ b/toontown/hood/MailboxZeroAnimatedProp.py @@ -0,0 +1,17 @@ +from toontown.hood import ZeroAnimatedProp +from toontown.toonbase import ToontownGlobals +from direct.directnotify import DirectNotifyGlobal + +class MailboxZeroAnimatedProp(ZeroAnimatedProp.ZeroAnimatedProp): + notify = DirectNotifyGlobal.directNotify.newCategory('MailboxZeroAnimatedProp') + PauseTimeMult = base.config.GetFloat('zero-pause-mult', 1.0) + PhaseInfo = {0: ('tt_a_ara_dod_mailbox_firstMoveFlagSpin1', 40 * PauseTimeMult), + 1: (('tt_a_ara_dod_mailbox_firstMoveStruggle', 'tt_a_ara_dod_mailbox_firstMoveJump'), 20 * PauseTimeMult), + 2: ('tt_a_ara_dod_mailbox_firstMoveFlagSpin2', 10 * PauseTimeMult), + 3: ('tt_a_ara_dod_mailbox_firstMoveFlagSpin3', 8 * PauseTimeMult), + 4: ('tt_a_ara_dod_mailbox_firstMoveJumpSummersault', 6 * PauseTimeMult), + 5: ('tt_a_ara_dod_mailbox_firstMoveJumpFall', 4 * PauseTimeMult), + 6: ('tt_a_ara_dod_mailbox_firstMoveJump3Summersaults', 2 * PauseTimeMult)} + + def __init__(self, node): + ZeroAnimatedProp.ZeroAnimatedProp.__init__(self, node, 'mailbox', self.PhaseInfo, ToontownGlobals.MAILBOX_ZERO_HOLIDAY) diff --git a/toontown/hood/TrashcanOneAnimatedProp.py b/toontown/hood/TrashcanOneAnimatedProp.py new file mode 100644 index 00000000..68d4331a --- /dev/null +++ b/toontown/hood/TrashcanOneAnimatedProp.py @@ -0,0 +1,32 @@ +from toontown.hood import ZeroAnimatedProp +from toontown.toonbase import ToontownGlobals +from direct.directnotify import DirectNotifyGlobal + +class TrashcanOneAnimatedProp(ZeroAnimatedProp.ZeroAnimatedProp): + notify = DirectNotifyGlobal.directNotify.newCategory('TrashcanOneAnimatedProp') + PauseTimeMult = base.config.GetFloat('zero-pause-mult', 1.0) + PhaseInfo = {0: ('tt_a_ara_dga_trashcan_firstMoveLidFlip1', 40 * PauseTimeMult), + 1: ('tt_a_ara_dga_trashcan_firstMoveStruggle', 20 * PauseTimeMult), + 2: ('tt_a_ara_dga_trashcan_firstMoveLidFlip2', 10 * PauseTimeMult), + 3: ('tt_a_ara_dga_trashcan_firstMoveJump', 8 * PauseTimeMult), + 4: ('tt_a_ara_dga_trashcan_firstMoveLidFlip3', 6 * PauseTimeMult), + 5: ('tt_a_ara_dga_trashcan_firstMoveJumpHit', 4 * PauseTimeMult), + 6: ('tt_a_ara_dga_trashcan_firstMoveJumpJuggle', 2 * PauseTimeMult)} + PhaseWeStartAnimating = 3 + + def __init__(self, node): + ZeroAnimatedProp.ZeroAnimatedProp.__init__(self, node, 'trashcan', self.PhaseInfo, ToontownGlobals.TRASHCAN_ZERO_HOLIDAY) + + def startIfNeeded(self): + try: + self.curPhase = self.getPhaseToRun() + if self.curPhase >= self.PhaseWeStartAnimating: + self.request('DoAnim') + except: + pass + + def handleNewPhase(self, newPhase): + if newPhase < self.PhaseWeStartAnimating: + self.request('Off') + else: + self.startIfNeeded() diff --git a/toontown/hood/TrashcanTwoAnimatedProp.py b/toontown/hood/TrashcanTwoAnimatedProp.py new file mode 100644 index 00000000..f0b86cec --- /dev/null +++ b/toontown/hood/TrashcanTwoAnimatedProp.py @@ -0,0 +1,32 @@ +from toontown.hood import ZeroAnimatedProp +from toontown.toonbase import ToontownGlobals +from direct.directnotify import DirectNotifyGlobal + +class TrashcanTwoAnimatedProp(ZeroAnimatedProp.ZeroAnimatedProp): + notify = DirectNotifyGlobal.directNotify.newCategory('TrashcanTwoAnimatedProp') + PauseTimeMult = base.config.GetFloat('zero-pause-mult', 1.0) + PhaseInfo = {0: ('tt_a_ara_dga_trashcan_firstMoveLidFlip1', 40 * PauseTimeMult), + 1: ('tt_a_ara_dga_trashcan_firstMoveStruggle', 20 * PauseTimeMult), + 2: ('tt_a_ara_dga_trashcan_firstMoveLidFlip2', 10 * PauseTimeMult), + 3: ('tt_a_ara_dga_trashcan_firstMoveJump', 8 * PauseTimeMult), + 4: ('tt_a_ara_dga_trashcan_firstMoveLidFlip3', 6 * PauseTimeMult), + 5: ('tt_a_ara_dga_trashcan_firstMoveJumpHit', 4 * PauseTimeMult), + 6: ('tt_a_ara_dga_trashcan_firstMoveJumpJuggle', 2 * PauseTimeMult)} + PhaseWeStartAnimating = 5 + + def __init__(self, node): + ZeroAnimatedProp.ZeroAnimatedProp.__init__(self, node, 'trashcan', self.PhaseInfo, ToontownGlobals.TRASHCAN_ZERO_HOLIDAY) + + def startIfNeeded(self): + try: + self.curPhase = self.getPhaseToRun() + if self.curPhase >= self.PhaseWeStartAnimating: + self.request('DoAnim') + except: + pass + + def handleNewPhase(self, newPhase): + if newPhase < self.PhaseWeStartAnimating: + self.request('Off') + else: + self.startIfNeeded() diff --git a/toontown/hood/TrashcanZeroAnimatedProp.py b/toontown/hood/TrashcanZeroAnimatedProp.py new file mode 100644 index 00000000..7b432ad9 --- /dev/null +++ b/toontown/hood/TrashcanZeroAnimatedProp.py @@ -0,0 +1,17 @@ +from toontown.hood import ZeroAnimatedProp +from toontown.toonbase import ToontownGlobals +from direct.directnotify import DirectNotifyGlobal + +class TrashcanZeroAnimatedProp(ZeroAnimatedProp.ZeroAnimatedProp): + notify = DirectNotifyGlobal.directNotify.newCategory('TrashcanZeroAnimatedProp') + PauseTimeMult = base.config.GetFloat('zero-pause-mult', 1.0) + PhaseInfo = {0: ('tt_a_ara_dga_trashcan_firstMoveLidFlip1', 40 * PauseTimeMult), + 1: ('tt_a_ara_dga_trashcan_firstMoveStruggle', 20 * PauseTimeMult), + 2: ('tt_a_ara_dga_trashcan_firstMoveLidFlip2', 10 * PauseTimeMult), + 3: ('tt_a_ara_dga_trashcan_firstMoveJump', 8 * PauseTimeMult), + 4: ('tt_a_ara_dga_trashcan_firstMoveLidFlip3', 6 * PauseTimeMult), + 5: ('tt_a_ara_dga_trashcan_firstMoveJumpHit', 4 * PauseTimeMult), + 6: ('tt_a_ara_dga_trashcan_firstMoveJumpJuggle', 2 * PauseTimeMult)} + + def __init__(self, node): + ZeroAnimatedProp.ZeroAnimatedProp.__init__(self, node, 'trashcan', self.PhaseInfo, ToontownGlobals.TRASHCAN_ZERO_HOLIDAY) diff --git a/toontown/suit/DistributedSuitPlannerAI.py b/toontown/suit/DistributedSuitPlannerAI.py index fd72e9b0..b85e0231 100755 --- a/toontown/suit/DistributedSuitPlannerAI.py +++ b/toontown/suit/DistributedSuitPlannerAI.py @@ -855,10 +855,17 @@ class DistributedSuitPlannerAI(DistributedObjectAI.DistributedObjectAI, SuitPlan pos = self.battlePosDict[canonicalZoneId] interactivePropTrackBonus = -1 - - if simbase.config.GetBool('props-buff-battles', True) and canonicalZoneId in self.cellToGagBonusDict: - interactivePropTrackBonus = self.cellToGagBonusDict[canonicalZoneId] - + if simbase.config.GetBool('props-buff-battles', True) and self.cellToGagBonusDict.has_key(canonicalZoneId): + tentativeBonusTrack = self.cellToGagBonusDict[canonicalZoneId] + trackToHolidayDict = { + ToontownBattleGlobals.SQUIRT_TRACK: ToontownGlobals.HYDRANTS_BUFF_BATTLES, + ToontownBattleGlobals.THROW_TRACK: ToontownGlobals.MAILBOXES_BUFF_BATTLES, + ToontownBattleGlobals.HEAL_TRACK: ToontownGlobals.TRASHCANS_BUFF_BATTLES } + if tentativeBonusTrack in trackToHolidayDict: + holidayId = trackToHolidayDict[tentativeBonusTrack] + if simbase.air.holidayManager.isHolidayRunning(holidayId):#and simbase.air.holidayManager.getCurPhase(holidayId) >= 1: + interactivePropTrackBonus = tentativeBonusTrack + self.battleMgr.newBattle( zoneId, zoneId, pos, suit, toonId, self.__battleFinished, self.SuitHoodInfo[self.hoodInfoIdx][self.SUIT_HOOD_INFO_SMAX], diff --git a/toontown/suit/SuitPlannerBase.py b/toontown/suit/SuitPlannerBase.py index 762ac16a..41f6698c 100755 --- a/toontown/suit/SuitPlannerBase.py +++ b/toontown/suit/SuitPlannerBase.py @@ -3,7 +3,7 @@ from direct.directnotify.DirectNotifyGlobal import * from toontown.hood import ZoneUtil, HoodUtil from toontown.toonbase import ToontownGlobals, ToontownBattleGlobals from toontown.building import SuitBuildingGlobals -from toontown.dna.DNAParser import DNASuitPoint, DNAInteractiveProp, DNAStorage, loadDNAFileAI +from toontown.dna.DNAParser import * class SuitPlannerBase: notify = directNotify.newCategory('SuitPlannerBase') @@ -544,18 +544,33 @@ class SuitPlannerBase: vg = self.dnaStore.getDNAVisGroupAI(i) zoneId = int(self.extractGroupName(vg.getName())) - if vg.getNumBattleCells() >= 1: + if vg.getNumBattleCells() == 1: battleCell = vg.getBattleCell(0) - self.battlePosDict[zoneId] = battleCell.getPos() - - for i in xrange(vg.getNumChildren()): - childDnaGroup = vg.at(i) + self.battlePosDict[zoneId] = vg.getBattleCell(0).getPos() + elif vg.getNumBattleCells() > 1: + self.notify.warning('multiple battle cells for zone: %d' % zoneId) + self.battlePosDict[zoneId] = vg.getBattleCell(0).getPos() + + if True: + for i in xrange(vg.getNumChildren()): + childDnaGroup = vg.at(i) - if isinstance(childDnaGroup, DNAInteractiveProp) and not zoneId in self.cellToGagBonusDict: - propType = HoodUtil.calcPropType(childDnaGroup.getName()) - - if propType in ToontownBattleGlobals.PropTypeToTrackBonus: - self.cellToGagBonusDict[zoneId] = ToontownBattleGlobals.PropTypeToTrackBonus[propType] + if isinstance(childDnaGroup, DNAInteractiveProp): + self.notify.debug('got interactive prop %s' % childDnaGroup) + battleCellId = childDnaGroup.getCellId() + + if battleCellId == -1: + self.notify.warning('interactive prop %s at %s not associated with a a battle' % (childDnaGroup, zoneId)) + + elif battleCellId == 0: + if self.cellToGagBonusDict.has_key(zoneId): + self.notify.error('FIXME battle cell at zone %s has two props %s %s linked to it' % (zoneId, self.cellToGagBonusDict[zoneId], childDnaGroup)) + else: + name = childDnaGroup.getName() + propType = HoodUtil.calcPropType(name) + if propType in ToontownBattleGlobals.PropTypeToTrackBonus: + trackBonus = ToontownBattleGlobals.PropTypeToTrackBonus[propType] + self.cellToGagBonusDict[zoneId] = trackBonus self.dnaStore.resetDNAGroups() self.dnaStore.resetDNAVisGroups() diff --git a/toontown/toon/InventoryNew.py b/toontown/toon/InventoryNew.py index 33d775b6..79a013c7 100755 --- a/toontown/toon/InventoryNew.py +++ b/toontown/toon/InventoryNew.py @@ -1207,4 +1207,4 @@ class InventoryNew(InventoryBase.InventoryBase, DirectFrame): goDark = LerpColorScaleInterval(flashObject, 0.5, Point4(0.1, 0.1, 0.1, 1.0), Point4(1, 1, 1, 1), blendType='easeIn') goBright = LerpColorScaleInterval(flashObject, 0.5, Point4(1, 1, 1, 1), Point4(0.1, 0.1, 0.1, 1.0), blendType='easeOut') newSeq = Sequence(goDark, goBright, Wait(0.2)) - self.propBonusIval.append(newSeq) \ No newline at end of file + self.propBonusIval.append(newSeq) diff --git a/toontown/toonbase/ToontownGlobals.py b/toontown/toonbase/ToontownGlobals.py index 04ce46a5..edcad7ec 100755 --- a/toontown/toonbase/ToontownGlobals.py +++ b/toontown/toonbase/ToontownGlobals.py @@ -883,8 +883,11 @@ BEAN_COUNTER_INVASION = 54 DOUBLE_TALKER_INVASION = 55 DOWNSIZER_INVASION = 56 WINTER_CAROLING = 57 +HYDRANT_ZERO_HOLIDAY = 58 VALENTINES_DAY = 59 SILLYMETER_HOLIDAY = 60 +MAILBOX_ZERO_HOLIDAY = 61 +TRASHCAN_ZERO_HOLIDAY = 62 SILLY_SURGE_HOLIDAY = 63 HYDRANTS_BUFF_BATTLES = 64 MAILBOXES_BUFF_BATTLES = 65 diff --git a/toontown/town/TownLoader.py b/toontown/town/TownLoader.py index fa82d440..c62afe4e 100755 --- a/toontown/town/TownLoader.py +++ b/toontown/town/TownLoader.py @@ -290,7 +290,7 @@ class TownLoader(StateData.StateData): for i in nodeList: animPropNodes = i.findAllMatches('**/animated_prop_*') numAnimPropNodes = animPropNodes.getNumPaths() - for j in xrange(numAnimPropNodes): + for j in range(numAnimPropNodes): animPropNode = animPropNodes.getPath(j) if animPropNode.getName().startswith('animated_prop_generic'): className = 'GenericAnimatedProp' @@ -309,7 +309,7 @@ class TownLoader(StateData.StateData): interactivePropNodes = i.findAllMatches('**/interactive_prop_*') numInteractivePropNodes = interactivePropNodes.getNumPaths() - for j in xrange(numInteractivePropNodes): + for j in range(numInteractivePropNodes): interactivePropNode = interactivePropNodes.getPath(j) className = 'InteractiveAnimatedProp' if 'hydrant' in interactivePropNode.getName():