Exemplo n.º 1
0
 def destroy(self):
     if self.av:
         ToontownIntervals.cleanup(self.av.uniqueName('laffMeterBoing') + '-' + str(self.this))
         ToontownIntervals.cleanup(self.av.uniqueName('laffMeterBoing') + '-' + str(self.this) + '-play')
         self.ignore(self.av.uniqueName('hpChange'))
     
     del self.style
     del self.av
     del self.hp
     del self.maxHp
     if self.isToon:
         del self.frown
         del self.smile
         del self.openSmile
         del self.tooth1
         del self.tooth2
         del self.tooth3
         del self.tooth4
         del self.tooth5
         del self.tooth6
         del self.teeth
         del self.fractions
         del self.maxLabel
         del self.hpLabel
     
     DirectFrame.destroy(self)
Exemplo n.º 2
0
 def showTimer(self, duration, timerExpiredCallback = None):
     if self._timer is None:
         self._initTimer()
     self._timer.setTime(duration)
     self._timer.countdown(duration, timerExpiredCallback)
     self._presentTimerIval = ToontownIntervals.start(ToontownIntervals.getPresentGuiIval(self._timer, 'present_timer', startPos=(0, 0, 0.35)))
     return
Exemplo n.º 3
0
 def destroy(self):
     ToontownIntervals.cleanup('memocount_pulse')
     self._countLabel.removeNode()
     del self._countLabel
     self._memoIcon.removeNode()
     del self._memoIcon
     DirectFrame.destroy(self)
 def showNumber(self, bossIndex):
     self._markers[bossIndex].setHit(False)
     self._markers[bossIndex].showNumber()
     self._markersShown += 1
     if self._markersShown == self._codeLength:
         self._openDoor.unstash()
         self._closedDoor.stash()
         ToontownIntervals.start(ToontownIntervals.getPulseLargerIval(self._openDoor, 'bosscodedoor'))
 def delete(self):
     DistributedObject.DistributedObject.delete(self)
     ToontownIntervals.cleanup(self.__pulseIvalName())
     if self.model:
         self.model.removeNode()
         del self.model
         self.model = None
     self.ignore(self.uniqueName('enterbarrelSphere'))
 def startGame(self, firstMessage):
     self._presentGuiIval = ToontownIntervals.start(
         Sequence(
             ToontownIntervals.getPresentGuiIval(self._bossGui, "", startPos=(0, 0, -0.15)),
             Func(self.mazeMapGui.show),
             ToontownIntervals.getPulseLargerIval(self.mazeMapGui, "", scale=self.mazeMapGui.getScale()),
             Func(self.setMessage, firstMessage),
             name="present_gui",
         )
     )
    def destroy(self):
        ToontownIntervals.cleanup('bosscodedoor')
        self._model.removeNode()
        del self._model
        self._titleLabel.removeNode()
        del self._titleLabel
        for marker in self._markers:
            marker.destroy()

        del self._markers
        DirectFrame.destroy(self)
 def animatedEffect(self, delta):
     if delta == 0 or self.av == None:
         return
     name = self.av.uniqueName('laffMeterBoing') + '-' + str(self.this)
     ToontownIntervals.cleanup(name)
     if delta > 0:
         ToontownIntervals.start(ToontownIntervals.getPulseLargerIval(self.container, name))
     else:
         ToontownIntervals.start(ToontownIntervals.getPulseSmallerIval(self.container, name))
     return
 def showSpamWarning(self):
     if self._spamWarning.isHidden():
         self._spamWarning.show()
         taskMgr.remove(self._spamWarningIvalName)
         Sequence(
             ToontownIntervals.getPulseLargerIval(self._spamWarning, ""),
             Wait(PartyGlobals.CogActivitySpamWarningShowTime),
             Func(self.hideSpamWarning),
             name=self._spamWarningIvalName,
             autoFinish=1,
         ).start()
 def showMoveControls(self):
     if self._moveKeys.isHidden() and not self._attackKeys.isHidden():
         self._moveKeys.show()
         taskMgr.remove(self._moveIvalName)
         Sequence(
             ToontownIntervals.getPulseLargerIval(self._moveKeys, "", scale=0.15),
             Wait(PartyGlobals.CogActivityControlsShowTime),
             Func(self.hideMoveControls),
             name=self._moveIvalName,
             autoFinish=1,
         ).start()
 def destroy(self):
     ToontownIntervals.cleanup('present_fuel_gui')
     ToontownIntervals.cleanup('present_timer_gui')
     ToontownIntervals.cleanup('present_memo_gui')
     ToontownIntervals.cleanup('present_progress_gui')
     self._refuelGui.destroy()
     self._refuelGui = None
     self._memoGui.destroy()
     self._memoGui = None
     self._progressGui.destroy()
     self._progressGui = None
     self.destroyTimer()
     self._messageDisplay.destroy()
     self._messageDisplay = None
     self.root.removeNode()
     self.root = None
 def destroy(self):
     ToontownIntervals.cleanup('present_gui')
     ToontownIntervals.cleanup('present_timer')
     ToontownIntervals.cleanup('present_memo')
     self._hud.destroy()
     self._hud = None
     self._memoGui.destroy()
     self._memoGui = None
     if self._bossGui is not None:
         self._bossGui.destroy()
         self._bossGui = None
     self.messageDisplay.destroy()
     self.messageDisplay = None
     self.destroyMazeMap()
     self.destroyTimer()
     if self._presentGuiIval:
         self._presentGuiIval.pause()
         self._presentGuiIval = None
     if self._presentTimerIval:
         self._presentTimerIval.pause()
         self._presentTimerIval = None
 def showNumber(self):
     self.setHit(False)
     self._bossIconX.show()
     ToontownIntervals.cleanup('boss_code%i' % self._id)
     ToontownIntervals.start(Sequence(Parallel(ToontownIntervals.getPresentGuiIval(self._bossIcon, '', startPos=(0, 0, -0.15))), Wait(1.0), ToontownIntervals.getPulseLargerIval(self._bg, ''), name='boss_code%i' % self._id))
Exemplo n.º 14
0
 def presentTimerGui(self):
     ToontownIntervals.start(ToontownIntervals.getPresentGuiIval(self._timer, 'present_timer_gui'))
Exemplo n.º 15
0
 def setGrab(self, avId):
     toonup = CogdoBarrelRoomConsts.ToonUp
     if avId == base.localAvatar.doId:
         ToontownIntervals.start(ToontownIntervals.getPulseIval(self.model, self.__pulseIvalName(), 1.15, duration=0.2))
         self.setState(CogdoBarrelRoomConsts.StateUsed)
         self.brLaff = random.randint(toonup[0], toonup[1])
 def destroy(self):
     ToontownIntervals.cleanup('boss_code%i' % self._id)
     DirectFrame.destroy(self)
 def setGrab(self, avId):
     if avId == base.localAvatar.doId:
         ToontownIntervals.start(ToontownIntervals.getPulseIval(self.model, self.__pulseIvalName(), 1.15, duration=0.2))
         self.setState(CogdoBarrelRoomConsts.StateUsed)
Exemplo n.º 18
0
 def showPickupCounter(self):
     ToontownIntervals.start(ToontownIntervals.getPresentGuiIval(self._memoGui, 'present_memo'))
Exemplo n.º 19
0
 def presentProgressGui(self):
     ToontownIntervals.start(ToontownIntervals.getPresentGuiIval(self._progressGui, 'present_progress_gui'))
 def presentProgressGui(self):
     ToontownIntervals.start(
         ToontownIntervals.getPresentGuiIval(self._progressGui,
                                             'present_progress_gui'))
Exemplo n.º 21
0
 def startGame(self, firstMessage):
     self._presentGuiIval = ToontownIntervals.start(Sequence(ToontownIntervals.getPresentGuiIval(self._bossGui, '', startPos=(0, 0, -0.15)), Func(self.mazeMapGui.show), ToontownIntervals.getPulseLargerIval(self.mazeMapGui, '', scale=self.mazeMapGui.getScale()), Func(self.setMessage, firstMessage), name='present_gui'))
Exemplo n.º 22
0
 def setGrab(self, avId):
     if avId == base.localAvatar.doId:
         ToontownIntervals.start(ToontownIntervals.getPulseIval(self.model, self.__pulseIvalName(), 1.15, duration=0.2))
         self.setState(CogdoBarrelRoomConsts.StateUsed)
Exemplo n.º 23
0
 def showMoveControls(self):
     if self._moveKeys.isHidden() and not self._attackKeys.isHidden():
         self._moveKeys.show()
         taskMgr.remove(self._moveIvalName)
         Sequence(ToontownIntervals.getPulseLargerIval(self._moveKeys, '', scale=0.15), Wait(PartyGlobals.CogActivityControlsShowTime), Func(self.hideMoveControls), name=self._moveIvalName, autoFinish=1).start()
Exemplo n.º 24
0
 def showSpamWarning(self):
     if self._spamWarning.isHidden():
         self._spamWarning.show()
         taskMgr.remove(self._spamWarningIvalName)
         Sequence(ToontownIntervals.getPulseLargerIval(self._spamWarning, ''), Wait(PartyGlobals.CogActivitySpamWarningShowTime), Func(self.hideSpamWarning), name=self._spamWarningIvalName, autoFinish=1).start()
 def presentMemoGui(self):
     ToontownIntervals.start(
         ToontownIntervals.getPresentGuiIval(self._memoGui,
                                             'present_memo_gui'))
 def presentTimerGui(self):
     ToontownIntervals.start(
         ToontownIntervals.getPresentGuiIval(self._timer,
                                             'present_timer_gui'))
 def presentRefuelGui(self):
     ToontownIntervals.start(
         ToontownIntervals.getPresentGuiIval(self._refuelGui,
                                             'present_fuel_gui'))
 def setGrab(self, avId):
     toonup = CogdoBarrelRoomConsts.ToonUp
     if avId == base.localAvatar.doId:
         ToontownIntervals.start(ToontownIntervals.getPulseIval(self.model, self.__pulseIvalName(), 1.15, duration=0.2))
         self.setState(CogdoBarrelRoomConsts.StateUsed)
         self.brLaff = random.randint(toonup[0], toonup[1])
Exemplo n.º 29
0
 def setCount(self, count):
     self._countLabel['text'] = str(count)
     self._countLabel.setText()
     ToontownIntervals.cleanup('memocount_pulse')
     ToontownIntervals.start(ToontownIntervals.getPulseLargerIval(self._memoIcon, 'memocount_pulse', scale=MEMOICON_SCALE))
Exemplo n.º 30
0
 def presentRefuelGui(self):
     ToontownIntervals.start(ToontownIntervals.getPresentGuiIval(self._refuelGui, 'present_fuel_gui'))
Exemplo n.º 31
0
 def showPickupCounter(self):
     ToontownIntervals.start(
         ToontownIntervals.getPresentGuiIval(self._memoGui, 'present_memo'))
Exemplo n.º 32
0
 def presentMemoGui(self):
     ToontownIntervals.start(ToontownIntervals.getPresentGuiIval(self._memoGui, 'present_memo_gui'))
Exemplo n.º 33
0
 def destroy(self):
     ToontownIntervals.cleanup('boss_code%i' % self._id)
     DirectFrame.destroy(self)
 def showNumber(self):
     self.setHit(False)
     self._bossIconX.show()
     ToontownIntervals.cleanup('boss_code%i' % self._id)
     ToontownIntervals.start(Sequence(Parallel(ToontownIntervals.getPresentGuiIval(self._bossIcon, '', startPos=(0, 0, -0.15))), Wait(1.0), ToontownIntervals.getPulseLargerIval(self._bg, ''), name='boss_code%i' % self._id))
Exemplo n.º 35
0
 def setCount(self, count):
     self._countLabel['text'] = str(count)
     self._countLabel.setText()
     ToontownIntervals.cleanup('memocount_pulse')
     ToontownIntervals.start(ToontownIntervals.getPulseLargerIval(self._memoIcon, 'memocount_pulse', scale = MEMOICON_SCALE))