コード例 #1
0
 def __init__(self, cr):
     ModPlayer.__init__(self, cr)
     BaseLocalAvatar.__init__(self)
     self.moneyGui = MoneyGUI()
     self.waveGui = WaveGUI()
     self.waveReportGui = WaveReportGUI()
     self.codeGUI = CodeGUI()
コード例 #2
0
    def handleHealthChange(self, hp, oldHp):
        BaseLocalAvatar.handleHealthChange(self, hp, oldHp)

        delta = hp - oldHp
        if delta == 0:
            return

        CIGlobals.makeDeltaTextEffect(delta, base.a2dBottomLeft,
                                      (0.07, 0, 0.1))
コード例 #3
0
    def stopPlay(self):
        if not self.playState:
            self.notify.warning("Redundant call to stopPlay()")
            return

        self.hideBookButton()
        self.hideFriendButton()

        BaseLocalAvatar.stopPlay(self)

        self.stopTrackAnimToSpeed()
コード例 #4
0
    def startPlay(self,
                  gags=False,
                  book=False,
                  friends=False,
                  laff=False,
                  chat=False,
                  wantMouse=1):
        if self.playState:
            self.notify.warning("Redundant call to startPlay()")
            return

        if book:
            self.showBookButton()
        if friends:
            self.showFriendButton()
        if chat:
            self.createChatInput()

        self.startTrackAnimToSpeed()

        BaseLocalAvatar.startPlay(self, gags, laff, wantMouse)
コード例 #5
0
 def enableAvatarControls(self, wantMouse=0):
     BaseLocalAvatar.enableAvatarControls(self, wantMouse)
     self.accept('jumpStart', self.__jump)
コード例 #6
0
 def setupAttacks(self):
     DistributedPlayerToon.setupAttacks(self)
     BaseLocalAvatar.setupAttacks(self)
コード例 #7
0
 def updateAttackAmmo(self, attackId, ammo, maxAmmo, ammo2, maxAmmo2, clip,
                      maxClip):
     DistributedPlayerToon.updateAttackAmmo(self, attackId, ammo, maxAmmo,
                                            ammo2, maxAmmo2, clip, maxClip)
     BaseLocalAvatar.updateAttackAmmo(self, attackId, ammo, maxAmmo, ammo2,
                                      maxAmmo2, clip, maxClip)
コード例 #8
0
 def setEquippedAttack(self, gagId):
     DistributedPlayerToon.setEquippedAttack(self, gagId)
     BaseLocalAvatar.setEquippedAttack(self, gagId)
コード例 #9
0
 def areGagsAllowed(self):
     return (BaseLocalAvatar.areGagsAllowed(self) and
             (self.chatInput is not None
              and self.chatInput.fsm.getCurrentState().getName() == 'idle'))
コード例 #10
0
 def setupAttacks(self):
     ModPlayer.setupAttacks(self)
     BaseLocalAvatar.setupAttacks(self)
コード例 #11
0
 def updateAttackAmmo(self, attackId, ammo, maxAmmo, ammo2, maxAmmo2, clip,
                      maxClip):
     ModPlayer.updateAttackAmmo(self, attackId, ammo, maxAmmo, ammo2,
                                maxAmmo2, clip, maxClip)
     BaseLocalAvatar.updateAttackAmmo(self, attackId, ammo, maxAmmo, ammo2,
                                      maxAmmo2, clip, maxClip)
コード例 #12
0
 def handleDamage(self, x, y, z):
     BaseLocalAvatar.handleDamage(self, x, y, z)
コード例 #13
0
 def setEquippedAttack(self, gagId):
     ModPlayer.setEquippedAttack(self, gagId)
     BaseLocalAvatar.setEquippedAttack(self, gagId)