adding size/speed to ancestry
This commit is contained in:
parent
a520ea249e
commit
12c643c542
|
@ -121,7 +121,6 @@ class Character(BaseObject, SlugMixin, SavingThrowsMixin, SkillsMixin):
|
||||||
hit_points = Column(Integer, default=1, nullable=False, info={"min": 0, "max": 999})
|
hit_points = Column(Integer, default=1, nullable=False, info={"min": 0, "max": 999})
|
||||||
max_hit_points = Column(Integer, default=1, nullable=False, info={"min": 0, "max": 999})
|
max_hit_points = Column(Integer, default=1, nullable=False, info={"min": 0, "max": 999})
|
||||||
temp_hit_points = Column(Integer, default=0, nullable=False, info={"min": 0, "max": 999})
|
temp_hit_points = Column(Integer, default=0, nullable=False, info={"min": 0, "max": 999})
|
||||||
speed = Column(Integer, nullable=False, default=30, info={"min": 0, "max": 99})
|
|
||||||
str = Column(Integer, nullable=False, default=10, info={"min": 0, "max": 30})
|
str = Column(Integer, nullable=False, default=10, info={"min": 0, "max": 30})
|
||||||
dex = Column(Integer, nullable=False, default=10, info={"min": 0, "max": 30})
|
dex = Column(Integer, nullable=False, default=10, info={"min": 0, "max": 30})
|
||||||
con = Column(Integer, nullable=False, default=10, info={"min": 0, "max": 30})
|
con = Column(Integer, nullable=False, default=10, info={"min": 0, "max": 30})
|
||||||
|
@ -147,6 +146,14 @@ class Character(BaseObject, SlugMixin, SavingThrowsMixin, SkillsMixin):
|
||||||
def traits(self):
|
def traits(self):
|
||||||
return self.ancestry.traits
|
return self.ancestry.traits
|
||||||
|
|
||||||
|
@property
|
||||||
|
def size(self):
|
||||||
|
return self.ancestry.size
|
||||||
|
|
||||||
|
@property
|
||||||
|
def speed(self):
|
||||||
|
return self.ancestry.speed
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def level(self):
|
def level(self):
|
||||||
return sum(mapping.level for mapping in self.class_map)
|
return sum(mapping.level for mapping in self.class_map)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user