Closed RichardScottOZ closed 2 years ago
--------------------------------------------------------------------------- AttributeError Traceback (most recent call last) ~\AppData\Local\Temp/ipykernel_38768/420916305.py in <module> ----> 1 arena = Encounter(level2, 'badger') j:\clone\dnd-battler\DnD_battler\encounter\_base.py in __init__(self, *lineup) 20 self.combattants.extend(lineup) 21 for chap in lineup: ---> 22 self.append(chap) 23 24 def blank(self, hard=True): j:\clone\dnd-battler\DnD_battler\encounter\_base.py in append(self, newbie) 45 self.combattants.append(newbie) 46 newbie.arena = self ---> 47 self.blank() 48 49 def extend(self, iterable): j:\clone\dnd-battler\DnD_battler\encounter\_base.py in blank(self, hard) 24 def blank(self, hard=True): 25 # this resets the teams ---> 26 self.sides = set([dude.alignment for dude in self]) 27 self.tally['battles'] = 0 28 self.tally['rounds'] = 0 j:\clone\dnd-battler\DnD_battler\encounter\_base.py in <listcomp>(.0) 24 def blank(self, hard=True): 25 # this resets the teams ---> 26 self.sides = set([dude.alignment for dude in self]) 27 self.tally['battles'] = 0 28 self.tally['rounds'] = 0 AttributeError: 'str' object has no attribute 'alignment'
This is I am guessing not converting to a class instance problem?
Believe this is good.