Пример #1
0
    def unstoppable(self):
        tempHp = utils.getD6() + utils.getD6() + self.getConstitutionModifier()
        self.receiveTemporaryHealth(tempHp)
        print 'unstoppable:', tempHp

        taskMgr.doMethodLater(1.5, self.stopDefenseAnimation, 'stopDefenseAnimationTask')

        self._hudRef.printFeedback('Unstoppable activated', False)

        duration = 30.0 # Half a minute (30 seconds) duration of temp hp
        taskMgr.doMethodLater(duration, self.removeTempHp, 'removeTempHpTask')

        return True
Пример #2
0
    def getDamageBonus(self):
        randomDamage = 0
        if self.damageRange == 4:
            randomDamage = utils.getD4()
        elif self.damageRange == 6:
            randomDamage = utils.getD6()
        elif self.damageRange == 8:
            randomDamage = utils.getD8()
        elif self.damageRange == 10:
            randomDamage = utils.getD10()

        return self.getStrengthModifier() + randomDamage + self.damageBonus
Пример #3
0
    def getDamageBonus(self):
        randomDamage = 0
        if self.damageRange == 4:
            randomDamage = utils.getD4()
        elif self.damageRange == 6:
            randomDamage = utils.getD6()
        elif self.damageRange == 8:
            randomDamage = utils.getD8()
        elif self.damageRange == 10:
            randomDamage = utils.getD10()

        return self.getStrengthModifier() + randomDamage + self.damageBonus