Adding SAO rewards saving for heroes

This commit is contained in:
2023-05-30 14:29:50 -04:00
parent a2fe11d654
commit e466ddce55
4 changed files with 17305 additions and 3 deletions

View File

@ -246,6 +246,14 @@ class SaoStaticData(BaseData):
return None
return [list[2] for list in result.fetchall()]
def get_hero_id(self, heroLogId: int) -> Optional[Dict]:
sql = hero.select(hero.c.heroLogId == heroLogId)
result = self.execute(sql)
if result is None:
return None
return result.fetchone()
def get_hero_ids(self, version: int, enabled: bool) -> Optional[List[Dict]]:
sql = hero.select(hero.c.version == version and hero.c.enabled == enabled).order_by(
hero.c.heroLogId.asc()