diff --git a/__pycache__/adventurers.cpython-312.pyc b/__pycache__/adventurers.cpython-312.pyc index b1c4837..5e74106 100644 Binary files a/__pycache__/adventurers.cpython-312.pyc and b/__pycache__/adventurers.cpython-312.pyc differ diff --git a/__pycache__/main.cpython-312.pyc b/__pycache__/main.cpython-312.pyc index 2df65b9..2db55a8 100644 Binary files a/__pycache__/main.cpython-312.pyc and b/__pycache__/main.cpython-312.pyc differ diff --git a/adventurers.py b/adventurers.py index 59010bb..165d194 100755 --- a/adventurers.py +++ b/adventurers.py @@ -19,6 +19,7 @@ class Adventurer: self.constitution = attributes.get('constitution', roll_dice(3,6)) self.charisma = attributes.get('charisma', roll_dice(3,6)) self.hp = 1 + self.gold= roll_dice(3,6) self.torches = roll_dice(1,6) self.rations = roll_dice(1,6) self.equipment = [ 'backpack', 'tinderbox', 'waterskin' ] @@ -37,26 +38,26 @@ class Adventurer: def character_sheet(self): sheet = [] - sheet.append('{0: <26}'.format(f"| {self.player_class.title()} - Level {self.level}")) + sheet.append('{0: <28}'.format(f"| {self.player_class.title()} - Level {self.level}")) for key, val in self.get_attributes().items(): - key_string = "| " + '{0:12}'.format(f"{key}").capitalize() + f" {val}" - sheet += ['{0: <26}'.format(key_string)] - sheet.append('| ----------------------- ') - sheet.append('{0: <26}'.format(f"| HP: {self.hp} AC: {self.ac}")) - sheet.append('{0: <26}'.format(f"| Torches: {self.torches}")) - sheet.append('{0: <26}'.format(f"| Rations: {self.rations}")) - sheet.append('{0: <26}'.format(f"| Armor: {self.armor}")) - sheet.append('{0: <26}'.format(f"| Weapons:")) - sheet.append('{0: <26}'.format(f"| {self.weapons[0]['name'].title()}")) - sheet.append('{0: <26}'.format(f"| {self.weapons[1]['name'].title()}")) - sheet.append('{0: <26}'.format(f"| Equipment:")) - sheet.append('{0: <26}'.format(f"| ")) - sheet.append('{0: <26}'.format(f"| Gold:")) - sheet.append('| ----------------------- ') + key_string = "| " + '{0:16}'.format(f"{key}").capitalize() + f" {val}" + sheet += ['{0: <28}'.format(key_string)] + sheet.append('| ------------------------- ') + sheet.append('{0: <28}'.format(f"| HP: {self.hp} AC: {self.ac}")) + sheet.append('{0: <28}'.format(f"| Torches: {self.torches}")) + sheet.append('{0: <28}'.format(f"| Rations: {self.rations}")) + sheet.append('{0: <28}'.format(f"| Armor: {self.armor}")) + sheet.append('{0: <28}'.format(f"| Weapons:")) + sheet.append('{0: <28}'.format(f"| {self.weapons[0]['name'].title()}")) + sheet.append('{0: <28}'.format(f"| {self.weapons[1]['name'].title()}")) + sheet.append('{0: <28}'.format(f"| Equipment:")) + sheet.append('{0: <28}'.format(f"| ")) + sheet.append('{0: <28}'.format(f"| Gold: {self.gold}")) + sheet.append('| ------------------------- ') for key, val in self.progression[self.level]['saves'].items(): - key_string = "| " + '{0:12}'.format(f"{key}").capitalize() + f" {val}" - sheet += ['{0: <26}'.format(key_string)] - sheet.append('| ----------------------- ') + key_string = "| " + '{0:22}'.format(f"{key}").title() + f" {val}" + sheet += ['{0: <28}'.format(key_string)] + sheet.append('| ------------------------- ') # append a | to each string, after the formatted whitespace sheet = [ line + "|" for line in sheet ] return sheet @@ -79,20 +80,20 @@ class Fighter(Adventurer): prime_requisite = "strength" requirements = None progression = [ - { "level" : 1, "xp" : 0, "hit-dice" : 1, "thac0" : 19, "saves" : { "death" : 12, "wands" : 13, "paralysis" : 14, "breath" : 15, "spells" : 16 }}, - { "level" : 2, "xp" : 2000, "hit-dice" : 2, "thac0" : 19, "saves" : { "death" : 12, "wands" : 13, "paralysis" : 14, "breath" : 15, "spells" : 16 }}, - { "level" : 3, "xp" : 4000, "hit-dice" : 3, "thac0" : 19, "saves" : { "death" : 12, "wands" : 13, "paralysis" : 14, "breath" : 15, "spells" : 16 }}, - { "level" : 4, "xp" : 8000, "hit-dice" : 4, "thac0" : 17, "saves" : { "death" : 10, "wands" : 11, "paralysis" : 12, "breath" : 13, "spells" : 14 }}, - { "level" : 5, "xp" : 16000, "hit-dice" : 5, "thac0" : 17, "saves" : { "death" : 10, "wands" : 11, "paralysis" : 12, "breath" : 13, "spells" : 14 }}, - { "level" : 6, "xp" : 32000, "hit-dice" : 6, "thac0" : 17, "saves" : { "death" : 10, "wands" : 11, "paralysis" : 12, "breath" : 13, "spells" : 14 }}, - { "level" : 7, "xp" : 64000, "hit-dice" : 7, "thac0" : 14, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 10, "breath" : 10, "spells" : 12 }}, - { "level" : 8, "xp" : 120000, "hit-dice" : 8, "thac0" : 14, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 10, "breath" : 10, "spells" : 12 }}, - { "level" : 9, "xp" : 240000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 10, "breath" : 10, "spells" : 12 }}, - { "level" : 10, "xp" : 360000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death" : 6, "wands" : 7, "paralysis" : 8, "breath" : 8, "spells" : 10 }}, - { "level" : 11, "xp" : 480000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death" : 6, "wands" : 7, "paralysis" : 8, "breath" : 8, "spells" : 10 }}, - { "level" : 12, "xp" : 600000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death" : 6, "wands" : 7, "paralysis" : 8, "breath" : 8, "spells" : 10 }}, - { "level" : 13, "xp" : 720000, "hit-dice" : 9, "thac0" : 10, "saves" : { "death" : 4, "wands" : 5, "paralysis" : 6, "breath" : 5, "spells" : 8 }}, - { "level" : 14, "xp" : 840000, "hit-dice" : 9, "thac0" : 10, "saves" : { "death" : 4, "wands" : 5, "paralysis" : 6, "breath" : 5, "spells" : 8 }} + { "level" : 1, "xp" : 0, "hit-dice" : 1, "thac0" : 19, "saves" : { "death / poison" : 12, "wands" : 13, "paralysis / petrify" : 14, "breath attack" : 15, "spells / rods / staves" : 16 }}, + { "level" : 2, "xp" : 2000, "hit-dice" : 2, "thac0" : 19, "saves" : { "death / poison" : 12, "wands" : 13, "paralysis / petrify" : 14, "breath attack" : 15, "spells / rods / staves" : 16 }}, + { "level" : 3, "xp" : 4000, "hit-dice" : 3, "thac0" : 19, "saves" : { "death / poison" : 12, "wands" : 13, "paralysis / petrify" : 14, "breath attack" : 15, "spells / rods / staves" : 16 }}, + { "level" : 4, "xp" : 8000, "hit-dice" : 4, "thac0" : 17, "saves" : { "death / poison" : 10, "wands" : 11, "paralysis / petrify" : 12, "breath attack" : 13, "spells / rods / staves" : 14 }}, + { "level" : 5, "xp" : 16000, "hit-dice" : 5, "thac0" : 17, "saves" : { "death / poison" : 10, "wands" : 11, "paralysis / petrify" : 12, "breath attack" : 13, "spells / rods / staves" : 14 }}, + { "level" : 6, "xp" : 32000, "hit-dice" : 6, "thac0" : 17, "saves" : { "death / poison" : 10, "wands" : 11, "paralysis / petrify" : 12, "breath attack" : 13, "spells / rods / staves" : 14 }}, + { "level" : 7, "xp" : 64000, "hit-dice" : 7, "thac0" : 14, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 10, "breath attack" : 10, "spells / rods / staves" : 12 }}, + { "level" : 8, "xp" : 120000, "hit-dice" : 8, "thac0" : 14, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 10, "breath attack" : 10, "spells / rods / staves" : 12 }}, + { "level" : 9, "xp" : 240000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 10, "breath attack" : 10, "spells / rods / staves" : 12 }}, + { "level" : 10, "xp" : 360000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death / poison" : 6, "wands" : 7, "paralysis / petrify" : 8, "breath attack" : 8, "spells / rods / staves" : 10 }}, + { "level" : 11, "xp" : 480000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death / poison" : 6, "wands" : 7, "paralysis / petrify" : 8, "breath attack" : 8, "spells / rods / staves" : 10 }}, + { "level" : 12, "xp" : 600000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death / poison" : 6, "wands" : 7, "paralysis / petrify" : 8, "breath attack" : 8, "spells / rods / staves" : 10 }}, + { "level" : 13, "xp" : 720000, "hit-dice" : 9, "thac0" : 10, "saves" : { "death / poison" : 4, "wands" : 5, "paralysis / petrify" : 6, "breath attack" : 5, "spells / rods / staves" : 8 }}, + { "level" : 14, "xp" : 840000, "hit-dice" : 9, "thac0" : 10, "saves" : { "death / poison" : 4, "wands" : 5, "paralysis / petrify" : 6, "breath attack" : 5, "spells / rods / staves" : 8 }} ] def __init__(self, level, attributes={}) -> None: Adventurer.__init__(self, level, attributes) @@ -105,20 +106,20 @@ class MagicUser(Adventurer): prime_requisite = "intelligence" requirements = None progression = [ - { "level" : 1, "xp" : 0, "hit-dice" : 1, "thac0" : 19, "saves" : { "death" : 13, "wands" : 14, "paralysis" : 13, "breath" : 16, "spells" : 15 }}, - { "level" : 2, "xp" : 2500, "hit-dice" : 2, "thac0" : 19, "saves" : { "death" : 13, "wands" : 14, "paralysis" : 13, "breath" : 16, "spells" : 15 }}, - { "level" : 3, "xp" : 5000, "hit-dice" : 3, "thac0" : 19, "saves" : { "death" : 13, "wands" : 14, "paralysis" : 13, "breath" : 16, "spells" : 15 }}, - { "level" : 4, "xp" : 10000, "hit-dice" : 4, "thac0" : 19, "saves" : { "death" : 13, "wands" : 14, "paralysis" : 13, "breath" : 16, "spells" : 15 }}, - { "level" : 5, "xp" : 20000, "hit-dice" : 5, "thac0" : 19, "saves" : { "death" : 13, "wands" : 14, "paralysis" : 13, "breath" : 16, "spells" : 15 }}, - { "level" : 6, "xp" : 40000, "hit-dice" : 6, "thac0" : 17, "saves" : { "death" : 11, "wands" : 12, "paralysis" : 11, "breath" : 11, "spells" : 12 }}, - { "level" : 7, "xp" : 80000, "hit-dice" : 7, "thac0" : 17, "saves" : { "death" : 11, "wands" : 12, "paralysis" : 11, "breath" : 11, "spells" : 12 }}, - { "level" : 8, "xp" : 150000, "hit-dice" : 8, "thac0" : 17, "saves" : { "death" : 11, "wands" : 12, "paralysis" : 11, "breath" : 11, "spells" : 12 }}, - { "level" : 9, "xp" : 300000, "hit-dice" : 9, "thac0" : 17, "saves" : { "death" : 11, "wands" : 12, "paralysis" : 11, "breath" : 11, "spells" : 12 }}, - { "level" : 10, "xp" : 450000, "hit-dice" : 9, "thac0" : 17, "saves" : { "death" : 11, "wands" : 12, "paralysis" : 11, "breath" : 11, "spells" : 12 }}, - { "level" : 11, "xp" : 600000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 8, "breath" : 8, "spells" : 8 }}, - { "level" : 12, "xp" : 750000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 8, "breath" : 8, "spells" : 8 }}, - { "level" : 13, "xp" : 900000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 8, "breath" : 8, "spells" : 8 }}, - { "level" : 14, "xp" : 1050000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 8, "breath" : 8, "spells" : 8 }} + { "level" : 1, "xp" : 0, "hit-dice" : 1, "thac0" : 19, "saves" : { "death / poison" : 13, "wands" : 14, "paralysis / petrify" : 13, "breath attack" : 16, "spells / rods / staves" : 15 }}, + { "level" : 2, "xp" : 2500, "hit-dice" : 2, "thac0" : 19, "saves" : { "death / poison" : 13, "wands" : 14, "paralysis / petrify" : 13, "breath attack" : 16, "spells / rods / staves" : 15 }}, + { "level" : 3, "xp" : 5000, "hit-dice" : 3, "thac0" : 19, "saves" : { "death / poison" : 13, "wands" : 14, "paralysis / petrify" : 13, "breath attack" : 16, "spells / rods / staves" : 15 }}, + { "level" : 4, "xp" : 10000, "hit-dice" : 4, "thac0" : 19, "saves" : { "death / poison" : 13, "wands" : 14, "paralysis / petrify" : 13, "breath attack" : 16, "spells / rods / staves" : 15 }}, + { "level" : 5, "xp" : 20000, "hit-dice" : 5, "thac0" : 19, "saves" : { "death / poison" : 13, "wands" : 14, "paralysis / petrify" : 13, "breath attack" : 16, "spells / rods / staves" : 15 }}, + { "level" : 6, "xp" : 40000, "hit-dice" : 6, "thac0" : 17, "saves" : { "death / poison" : 11, "wands" : 12, "paralysis / petrify" : 11, "breath attack" : 11, "spells / rods / staves" : 12 }}, + { "level" : 7, "xp" : 80000, "hit-dice" : 7, "thac0" : 17, "saves" : { "death / poison" : 11, "wands" : 12, "paralysis / petrify" : 11, "breath attack" : 11, "spells / rods / staves" : 12 }}, + { "level" : 8, "xp" : 150000, "hit-dice" : 8, "thac0" : 17, "saves" : { "death / poison" : 11, "wands" : 12, "paralysis / petrify" : 11, "breath attack" : 11, "spells / rods / staves" : 12 }}, + { "level" : 9, "xp" : 300000, "hit-dice" : 9, "thac0" : 17, "saves" : { "death / poison" : 11, "wands" : 12, "paralysis / petrify" : 11, "breath attack" : 11, "spells / rods / staves" : 12 }}, + { "level" : 10, "xp" : 450000, "hit-dice" : 9, "thac0" : 17, "saves" : { "death / poison" : 11, "wands" : 12, "paralysis / petrify" : 11, "breath attack" : 11, "spells / rods / staves" : 12 }}, + { "level" : 11, "xp" : 600000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 8, "breath attack" : 8, "spells / rods / staves" : 8 }}, + { "level" : 12, "xp" : 750000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 8, "breath attack" : 8, "spells / rods / staves" : 8 }}, + { "level" : 13, "xp" : 900000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 8, "breath attack" : 8, "spells / rods / staves" : 8 }}, + { "level" : 14, "xp" : 1050000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 8, "breath attack" : 8, "spells / rods / staves" : 8 }} ] def __init__(self, level, attributes={}) -> None: Adventurer.__init__(self, level, attributes) @@ -134,20 +135,20 @@ class Cleric(Adventurer): prime_requisite = "wisdom" requirements = None progression = [ - { "level" : 1, "xp" : 0, "hit-dice" : 1, "thac0" : 19, "saves" : { "death" : 11, "wands" : 12, "paralysis" : 14, "breath" : 16, "spells" : 15 }}, - { "level" : 2, "xp" : 1500, "hit-dice" : 2, "thac0" : 19, "saves" : { "death" : 11, "wands" : 12, "paralysis" : 14, "breath" : 16, "spells" : 15 }}, - { "level" : 3, "xp" : 3000, "hit-dice" : 3, "thac0" : 19, "saves" : { "death" : 11, "wands" : 12, "paralysis" : 14, "breath" : 16, "spells" : 15 }}, - { "level" : 4, "xp" : 6000, "hit-dice" : 4, "thac0" : 19, "saves" : { "death" : 11, "wands" : 12, "paralysis" : 14, "breath" : 16, "spells" : 15 }}, - { "level" : 5, "xp" : 12000, "hit-dice" : 5, "thac0" : 17, "saves" : { "death" : 9, "wands" : 10, "paralysis" : 12, "breath" : 14, "spells" : 12 }}, - { "level" : 6, "xp" : 25000, "hit-dice" : 6, "thac0" : 17, "saves" : { "death" : 9, "wands" : 10, "paralysis" : 12, "breath" : 14, "spells" : 12 }}, - { "level" : 7, "xp" : 50000, "hit-dice" : 7, "thac0" : 17, "saves" : { "death" : 9, "wands" : 10, "paralysis" : 12, "breath" : 14, "spells" : 12 }}, - { "level" : 8, "xp" : 100000, "hit-dice" : 8, "thac0" : 17, "saves" : { "death" : 9, "wands" : 10, "paralysis" : 12, "breath" : 14, "spells" : 12 }}, - { "level" : 9, "xp" : 200000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death" : 6, "wands" : 7, "paralysis" : 9, "breath" : 14, "spells" : 9 }}, - { "level" : 10, "xp" : 300000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death" : 6, "wands" : 7, "paralysis" : 9, "breath" : 11, "spells" : 9 }}, - { "level" : 11, "xp" : 400000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death" : 6, "wands" : 7, "paralysis" : 9, "breath" : 11, "spells" : 9 }}, - { "level" : 12, "xp" : 500000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death" : 6, "wands" : 7, "paralysis" : 9, "breath" : 11, "spells" : 9 }}, - { "level" : 13, "xp" : 600000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death" : 3, "wands" : 5, "paralysis" : 7, "breath" : 8, "spells" : 7 }}, - { "level" : 14, "xp" : 700000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death" : 3, "wands" : 5, "paralysis" : 7, "breath" : 8, "spells" : 7 }} + { "level" : 1, "xp" : 0, "hit-dice" : 1, "thac0" : 19, "saves" : { "death / poison" : 11, "wands" : 12, "paralysis / petrify" : 14, "breath attack" : 16, "spells / rods / staves" : 15 }}, + { "level" : 2, "xp" : 1500, "hit-dice" : 2, "thac0" : 19, "saves" : { "death / poison" : 11, "wands" : 12, "paralysis / petrify" : 14, "breath attack" : 16, "spells / rods / staves" : 15 }}, + { "level" : 3, "xp" : 3000, "hit-dice" : 3, "thac0" : 19, "saves" : { "death / poison" : 11, "wands" : 12, "paralysis / petrify" : 14, "breath attack" : 16, "spells / rods / staves" : 15 }}, + { "level" : 4, "xp" : 6000, "hit-dice" : 4, "thac0" : 19, "saves" : { "death / poison" : 11, "wands" : 12, "paralysis / petrify" : 14, "breath attack" : 16, "spells / rods / staves" : 15 }}, + { "level" : 5, "xp" : 12000, "hit-dice" : 5, "thac0" : 17, "saves" : { "death / poison" : 9, "wands" : 10, "paralysis / petrify" : 12, "breath attack" : 14, "spells / rods / staves" : 12 }}, + { "level" : 6, "xp" : 25000, "hit-dice" : 6, "thac0" : 17, "saves" : { "death / poison" : 9, "wands" : 10, "paralysis / petrify" : 12, "breath attack" : 14, "spells / rods / staves" : 12 }}, + { "level" : 7, "xp" : 50000, "hit-dice" : 7, "thac0" : 17, "saves" : { "death / poison" : 9, "wands" : 10, "paralysis / petrify" : 12, "breath attack" : 14, "spells / rods / staves" : 12 }}, + { "level" : 8, "xp" : 100000, "hit-dice" : 8, "thac0" : 17, "saves" : { "death / poison" : 9, "wands" : 10, "paralysis / petrify" : 12, "breath attack" : 14, "spells / rods / staves" : 12 }}, + { "level" : 9, "xp" : 200000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death / poison" : 6, "wands" : 7, "paralysis / petrify" : 9, "breath attack" : 14, "spells / rods / staves" : 9 }}, + { "level" : 10, "xp" : 300000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death / poison" : 6, "wands" : 7, "paralysis / petrify" : 9, "breath attack" : 11, "spells / rods / staves" : 9 }}, + { "level" : 11, "xp" : 400000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death / poison" : 6, "wands" : 7, "paralysis / petrify" : 9, "breath attack" : 11, "spells / rods / staves" : 9 }}, + { "level" : 12, "xp" : 500000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death / poison" : 6, "wands" : 7, "paralysis / petrify" : 9, "breath attack" : 11, "spells / rods / staves" : 9 }}, + { "level" : 13, "xp" : 600000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death / poison" : 3, "wands" : 5, "paralysis / petrify" : 7, "breath attack" : 8, "spells / rods / staves" : 7 }}, + { "level" : 14, "xp" : 700000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death / poison" : 3, "wands" : 5, "paralysis / petrify" : 7, "breath attack" : 8, "spells / rods / staves" : 7 }} ] def __init__(self, level, attributes={}) -> None: Adventurer.__init__(self, level, attributes) @@ -165,20 +166,20 @@ class Thief(Adventurer): prime_requisite = "dexterity" requirements = None progression = [ - { "level" : 1, "xp" : 0, "hit-dice" : 1, "thac0" : 19, "saves" : { "death" : 13, "wands" : 14, "paralysis" : 13, "breath" : 16, "spells" : 15 }}, - { "level" : 2, "xp" : 1200, "hit-dice" : 2, "thac0" : 19, "saves" : { "death" : 13, "wands" : 14, "paralysis" : 13, "breath" : 16, "spells" : 15 }}, - { "level" : 3, "xp" : 2400, "hit-dice" : 3, "thac0" : 19, "saves" : { "death" : 13, "wands" : 14, "paralysis" : 13, "breath" : 16, "spells" : 15 }}, - { "level" : 4, "xp" : 4800, "hit-dice" : 4, "thac0" : 19, "saves" : { "death" : 13, "wands" : 14, "paralysis" : 13, "breath" : 16, "spells" : 15 }}, - { "level" : 5, "xp" : 9600, "hit-dice" : 5, "thac0" : 17, "saves" : { "death" : 12, "wands" : 13, "paralysis" : 11, "breath" : 14, "spells" : 13 }}, - { "level" : 6, "xp" : 20000, "hit-dice" : 6, "thac0" : 17, "saves" : { "death" : 12, "wands" : 13, "paralysis" : 11, "breath" : 14, "spells" : 13 }}, - { "level" : 7, "xp" : 40000, "hit-dice" : 7, "thac0" : 17, "saves" : { "death" : 12, "wands" : 13, "paralysis" : 11, "breath" : 14, "spells" : 13 }}, - { "level" : 8, "xp" : 80000, "hit-dice" : 8, "thac0" : 17, "saves" : { "death" : 12, "wands" : 13, "paralysis" : 11, "breath" : 14, "spells" : 13 }}, - { "level" : 9, "xp" : 160000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death" : 10, "wands" : 11, "paralysis" : 9, "breath" : 11, "spells" : 10 }}, - { "level" : 10, "xp" : 280000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death" : 10, "wands" : 11, "paralysis" : 9, "breath" : 11, "spells" : 10 }}, - { "level" : 11, "xp" : 400000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death" : 10, "wands" : 11, "paralysis" : 9, "breath" : 11, "spells" : 10 }}, - { "level" : 12, "xp" : 520000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death" : 10, "wands" : 11, "paralysis" : 9, "breath" : 11, "spells" : 10 }}, - { "level" : 13, "xp" : 640000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 7, "breath" : 10, "spells" : 8 }}, - { "level" : 14, "xp" : 760000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 7, "breath" : 10, "spells" : 8 }} + { "level" : 1, "xp" : 0, "hit-dice" : 1, "thac0" : 19, "saves" : { "death / poison" : 13, "wands" : 14, "paralysis / petrify" : 13, "breath attack" : 16, "spells / rods / staves" : 15 }}, + { "level" : 2, "xp" : 1200, "hit-dice" : 2, "thac0" : 19, "saves" : { "death / poison" : 13, "wands" : 14, "paralysis / petrify" : 13, "breath attack" : 16, "spells / rods / staves" : 15 }}, + { "level" : 3, "xp" : 2400, "hit-dice" : 3, "thac0" : 19, "saves" : { "death / poison" : 13, "wands" : 14, "paralysis / petrify" : 13, "breath attack" : 16, "spells / rods / staves" : 15 }}, + { "level" : 4, "xp" : 4800, "hit-dice" : 4, "thac0" : 19, "saves" : { "death / poison" : 13, "wands" : 14, "paralysis / petrify" : 13, "breath attack" : 16, "spells / rods / staves" : 15 }}, + { "level" : 5, "xp" : 9600, "hit-dice" : 5, "thac0" : 17, "saves" : { "death / poison" : 12, "wands" : 13, "paralysis / petrify" : 11, "breath attack" : 14, "spells / rods / staves" : 13 }}, + { "level" : 6, "xp" : 20000, "hit-dice" : 6, "thac0" : 17, "saves" : { "death / poison" : 12, "wands" : 13, "paralysis / petrify" : 11, "breath attack" : 14, "spells / rods / staves" : 13 }}, + { "level" : 7, "xp" : 40000, "hit-dice" : 7, "thac0" : 17, "saves" : { "death / poison" : 12, "wands" : 13, "paralysis / petrify" : 11, "breath attack" : 14, "spells / rods / staves" : 13 }}, + { "level" : 8, "xp" : 80000, "hit-dice" : 8, "thac0" : 17, "saves" : { "death / poison" : 12, "wands" : 13, "paralysis / petrify" : 11, "breath attack" : 14, "spells / rods / staves" : 13 }}, + { "level" : 9, "xp" : 160000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death / poison" : 10, "wands" : 11, "paralysis / petrify" : 9, "breath attack" : 11, "spells / rods / staves" : 10 }}, + { "level" : 10, "xp" : 280000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death / poison" : 10, "wands" : 11, "paralysis / petrify" : 9, "breath attack" : 11, "spells / rods / staves" : 10 }}, + { "level" : 11, "xp" : 400000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death / poison" : 10, "wands" : 11, "paralysis / petrify" : 9, "breath attack" : 11, "spells / rods / staves" : 10 }}, + { "level" : 12, "xp" : 520000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death / poison" : 10, "wands" : 11, "paralysis / petrify" : 9, "breath attack" : 11, "spells / rods / staves" : 10 }}, + { "level" : 13, "xp" : 640000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 7, "breath attack" : 10, "spells / rods / staves" : 8 }}, + { "level" : 14, "xp" : 760000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 7, "breath attack" : 10, "spells / rods / staves" : 8 }} ] def __init__(self, level, attributes={}) -> None: Adventurer.__init__(self, level, attributes) @@ -192,18 +193,18 @@ class Dwarf(Adventurer): prime_requisite = "strength" requirements = {'constitution' : 9 } progression = [ - { "level" : 1, "xp" : 0, "hit-dice" : 1, "thac0" : 19, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 10, "breath" : 13, "spells" : 12 }}, - { "level" : 2, "xp" : 2200, "hit-dice" : 2, "thac0" : 19, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 10, "breath" : 13, "spells" : 12 }}, - { "level" : 3, "xp" : 4400, "hit-dice" : 3, "thac0" : 19, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 10, "breath" : 13, "spells" : 12 }}, - { "level" : 4, "xp" : 8800, "hit-dice" : 4, "thac0" : 17, "saves" : { "death" : 6, "wands" : 7, "paralysis" : 8, "breath" : 10, "spells" : 10 }}, - { "level" : 5, "xp" : 17000, "hit-dice" : 5, "thac0" : 17, "saves" : { "death" : 6, "wands" : 7, "paralysis" : 8, "breath" : 10, "spells" : 10 }}, - { "level" : 6, "xp" : 35000, "hit-dice" : 6, "thac0" : 17, "saves" : { "death" : 6, "wands" : 7, "paralysis" : 8, "breath" : 10, "spells" : 10 }}, - { "level" : 7, "xp" : 70000, "hit-dice" : 7, "thac0" : 14, "saves" : { "death" : 4, "wands" : 5, "paralysis" : 6, "breath" : 7, "spells" : 8 }}, - { "level" : 8, "xp" : 140000, "hit-dice" : 8, "thac0" : 14, "saves" : { "death" : 4, "wands" : 5, "paralysis" : 6, "breath" : 7, "spells" : 8 }}, - { "level" : 9, "xp" : 270000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death" : 4, "wands" : 5, "paralysis" : 6, "breath" : 7, "spells" : 8 }}, - { "level" : 10, "xp" : 400000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death" : 2, "wands" : 3, "paralysis" : 4, "breath" : 4, "spells" : 6 }}, - { "level" : 11, "xp" : 530000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death" : 2, "wands" : 3, "paralysis" : 4, "breath" : 4, "spells" : 6 }}, - { "level" : 12, "xp" : 660000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death" : 2, "wands" : 3, "paralysis" : 4, "breath" : 4, "spells" : 6 }} + { "level" : 1, "xp" : 0, "hit-dice" : 1, "thac0" : 19, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 10, "breath attack" : 13, "spells / rods / staves" : 12 }}, + { "level" : 2, "xp" : 2200, "hit-dice" : 2, "thac0" : 19, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 10, "breath attack" : 13, "spells / rods / staves" : 12 }}, + { "level" : 3, "xp" : 4400, "hit-dice" : 3, "thac0" : 19, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 10, "breath attack" : 13, "spells / rods / staves" : 12 }}, + { "level" : 4, "xp" : 8800, "hit-dice" : 4, "thac0" : 17, "saves" : { "death / poison" : 6, "wands" : 7, "paralysis / petrify" : 8, "breath attack" : 10, "spells / rods / staves" : 10 }}, + { "level" : 5, "xp" : 17000, "hit-dice" : 5, "thac0" : 17, "saves" : { "death / poison" : 6, "wands" : 7, "paralysis / petrify" : 8, "breath attack" : 10, "spells / rods / staves" : 10 }}, + { "level" : 6, "xp" : 35000, "hit-dice" : 6, "thac0" : 17, "saves" : { "death / poison" : 6, "wands" : 7, "paralysis / petrify" : 8, "breath attack" : 10, "spells / rods / staves" : 10 }}, + { "level" : 7, "xp" : 70000, "hit-dice" : 7, "thac0" : 14, "saves" : { "death / poison" : 4, "wands" : 5, "paralysis / petrify" : 6, "breath attack" : 7, "spells / rods / staves" : 8 }}, + { "level" : 8, "xp" : 140000, "hit-dice" : 8, "thac0" : 14, "saves" : { "death / poison" : 4, "wands" : 5, "paralysis / petrify" : 6, "breath attack" : 7, "spells / rods / staves" : 8 }}, + { "level" : 9, "xp" : 270000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death / poison" : 4, "wands" : 5, "paralysis / petrify" : 6, "breath attack" : 7, "spells / rods / staves" : 8 }}, + { "level" : 10, "xp" : 400000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death / poison" : 2, "wands" : 3, "paralysis / petrify" : 4, "breath attack" : 4, "spells / rods / staves" : 6 }}, + { "level" : 11, "xp" : 530000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death / poison" : 2, "wands" : 3, "paralysis / petrify" : 4, "breath attack" : 4, "spells / rods / staves" : 6 }}, + { "level" : 12, "xp" : 660000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death / poison" : 2, "wands" : 3, "paralysis / petrify" : 4, "breath attack" : 4, "spells / rods / staves" : 6 }} ] def __init__(self, level, attributes={}) -> None: Adventurer.__init__(self, level, attributes) @@ -217,16 +218,16 @@ class Elf(Adventurer): prime_requisite = "intellgence" requirements = {'intelligence' : 9 } progression = [ - { "level" : 1, "xp" : 0, "hit-dice" : 1, "thac0" : 19, "saves" : { "death" : 12, "wands" : 13, "paralysis" : 13, "breath" : 15, "spells" : 15 }}, - { "level" : 2, "xp" : 4000, "hit-dice" : 2, "thac0" : 19, "saves" : { "death" : 12, "wands" : 13, "paralysis" : 13, "breath" : 15, "spells" : 15 }}, - { "level" : 3, "xp" : 8000, "hit-dice" : 3, "thac0" : 19, "saves" : { "death" : 12, "wands" : 13, "paralysis" : 13, "breath" : 15, "spells" : 15 }}, - { "level" : 4, "xp" : 16000, "hit-dice" : 4, "thac0" : 17, "saves" : { "death" : 10, "wands" : 11, "paralysis" : 11, "breath" : 13, "spells" : 12 }}, - { "level" : 5, "xp" : 32000, "hit-dice" : 5, "thac0" : 17, "saves" : { "death" : 10, "wands" : 11, "paralysis" : 11, "breath" : 13, "spells" : 12 }}, - { "level" : 6, "xp" : 64000, "hit-dice" : 6, "thac0" : 17, "saves" : { "death" : 10, "wands" : 11, "paralysis" : 11, "breath" : 13, "spells" : 12 }}, - { "level" : 7, "xp" : 120000, "hit-dice" : 7, "thac0" : 14, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 9, "breath" : 10, "spells" : 10 }}, - { "level" : 8, "xp" : 250000, "hit-dice" : 8, "thac0" : 14, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 9, "breath" : 10, "spells" : 10 }}, - { "level" : 9, "xp" : 400000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 9, "breath" : 10, "spells" : 10 }}, - { "level" : 10, "xp" : 600000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death" : 6, "wands" : 7, "paralysis" : 8, "breath" : 8, "spells" : 8 }} + { "level" : 1, "xp" : 0, "hit-dice" : 1, "thac0" : 19, "saves" : { "death / poison" : 12, "wands" : 13, "paralysis / petrify" : 13, "breath attack" : 15, "spells / rods / staves" : 15 }}, + { "level" : 2, "xp" : 4000, "hit-dice" : 2, "thac0" : 19, "saves" : { "death / poison" : 12, "wands" : 13, "paralysis / petrify" : 13, "breath attack" : 15, "spells / rods / staves" : 15 }}, + { "level" : 3, "xp" : 8000, "hit-dice" : 3, "thac0" : 19, "saves" : { "death / poison" : 12, "wands" : 13, "paralysis / petrify" : 13, "breath attack" : 15, "spells / rods / staves" : 15 }}, + { "level" : 4, "xp" : 16000, "hit-dice" : 4, "thac0" : 17, "saves" : { "death / poison" : 10, "wands" : 11, "paralysis / petrify" : 11, "breath attack" : 13, "spells / rods / staves" : 12 }}, + { "level" : 5, "xp" : 32000, "hit-dice" : 5, "thac0" : 17, "saves" : { "death / poison" : 10, "wands" : 11, "paralysis / petrify" : 11, "breath attack" : 13, "spells / rods / staves" : 12 }}, + { "level" : 6, "xp" : 64000, "hit-dice" : 6, "thac0" : 17, "saves" : { "death / poison" : 10, "wands" : 11, "paralysis / petrify" : 11, "breath attack" : 13, "spells / rods / staves" : 12 }}, + { "level" : 7, "xp" : 120000, "hit-dice" : 7, "thac0" : 14, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 9, "breath attack" : 10, "spells / rods / staves" : 10 }}, + { "level" : 8, "xp" : 250000, "hit-dice" : 8, "thac0" : 14, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 9, "breath attack" : 10, "spells / rods / staves" : 10 }}, + { "level" : 9, "xp" : 400000, "hit-dice" : 9, "thac0" : 14, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 9, "breath attack" : 10, "spells / rods / staves" : 10 }}, + { "level" : 10, "xp" : 600000, "hit-dice" : 9, "thac0" : 12, "saves" : { "death / poison" : 6, "wands" : 7, "paralysis / petrify" : 8, "breath attack" : 8, "spells / rods / staves" : 8 }} ] def __init__(self, level, attributes={}) -> None: Adventurer.__init__(self, level, attributes) @@ -240,14 +241,14 @@ class Halfling(Adventurer): prime_requisite = "dexterity" requirements = {'constitution' : 9, 'dexterity' : 9 } progression = [ - { "level" : 1, "xp" : 0, "hit-dice" : 1, "thac0" : 19, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 10, "breath" : 13, "spells" : 12 }}, - { "level" : 2, "xp" : 2000, "hit-dice" : 2, "thac0" : 19, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 10, "breath" : 13, "spells" : 12 }}, - { "level" : 3, "xp" : 4000, "hit-dice" : 3, "thac0" : 19, "saves" : { "death" : 8, "wands" : 9, "paralysis" : 10, "breath" : 13, "spells" : 12 }}, - { "level" : 4, "xp" : 8000, "hit-dice" : 4, "thac0" : 17, "saves" : { "death" : 6, "wands" : 7, "paralysis" : 8, "breath" : 10, "spells" : 10 }}, - { "level" : 5, "xp" : 16000, "hit-dice" : 5, "thac0" : 17, "saves" : { "death" : 6, "wands" : 7, "paralysis" : 8, "breath" : 10, "spells" : 10 }}, - { "level" : 6, "xp" : 32000, "hit-dice" : 6, "thac0" : 17, "saves" : { "death" : 6, "wands" : 7, "paralysis" : 8, "breath" : 10, "spells" : 10 }}, - { "level" : 7, "xp" : 64000, "hit-dice" : 7, "thac0" : 14, "saves" : { "death" : 4, "wands" : 5, "paralysis" : 6, "breath" : 7, "spells" : 8 }}, - { "level" : 8, "xp" : 120000, "hit-dice" : 8, "thac0" : 14, "saves" : { "death" : 4, "wands" : 5, "paralysis" : 6, "breath" : 7, "spells" : 8 }}, + { "level" : 1, "xp" : 0, "hit-dice" : 1, "thac0" : 19, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 10, "breath attack" : 13, "spells / rods / staves" : 12 }}, + { "level" : 2, "xp" : 2000, "hit-dice" : 2, "thac0" : 19, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 10, "breath attack" : 13, "spells / rods / staves" : 12 }}, + { "level" : 3, "xp" : 4000, "hit-dice" : 3, "thac0" : 19, "saves" : { "death / poison" : 8, "wands" : 9, "paralysis / petrify" : 10, "breath attack" : 13, "spells / rods / staves" : 12 }}, + { "level" : 4, "xp" : 8000, "hit-dice" : 4, "thac0" : 17, "saves" : { "death / poison" : 6, "wands" : 7, "paralysis / petrify" : 8, "breath attack" : 10, "spells / rods / staves" : 10 }}, + { "level" : 5, "xp" : 16000, "hit-dice" : 5, "thac0" : 17, "saves" : { "death / poison" : 6, "wands" : 7, "paralysis / petrify" : 8, "breath attack" : 10, "spells / rods / staves" : 10 }}, + { "level" : 6, "xp" : 32000, "hit-dice" : 6, "thac0" : 17, "saves" : { "death / poison" : 6, "wands" : 7, "paralysis / petrify" : 8, "breath attack" : 10, "spells / rods / staves" : 10 }}, + { "level" : 7, "xp" : 64000, "hit-dice" : 7, "thac0" : 14, "saves" : { "death / poison" : 4, "wands" : 5, "paralysis / petrify" : 6, "breath attack" : 7, "spells / rods / staves" : 8 }}, + { "level" : 8, "xp" : 120000, "hit-dice" : 8, "thac0" : 14, "saves" : { "death / poison" : 4, "wands" : 5, "paralysis / petrify" : 6, "breath attack" : 7, "spells / rods / staves" : 8 }}, ] def __init__(self, level, attributes={}) -> None: Adventurer.__init__(self, level, attributes) diff --git a/main.py b/main.py index 32fe95c..d598dac 100755 --- a/main.py +++ b/main.py @@ -73,10 +73,6 @@ class PartyGenerator(): def __str__(self): return f"{self.adventurers}" -# functions -def roll_dice(count, sides): - return sum(random.randint(1,sides) for _ in range(count)) - def returnSheets(foo): new_party = PartyGenerator() new_party.gen_party()