From 6b158bf18df6c86e2453fd5678e26b3893ba9ee2 Mon Sep 17 00:00:00 2001 From: Hay1tsme Date: Wed, 6 Dec 2023 18:24:20 -0500 Subject: [PATCH] diva: fix StageResultResponse --- titles/diva/base.py | 4 +++- titles/diva/handlers/pv.py | 30 +++++++++++++++--------------- 2 files changed, 18 insertions(+), 16 deletions(-) diff --git a/titles/diva/base.py b/titles/diva/base.py index a13f3a0..4d496f2 100644 --- a/titles/diva/base.py +++ b/titles/diva/base.py @@ -813,7 +813,9 @@ class DivaBase: resp.vcld_pts = int(profile['vcld_pts']) resp.prsnt_vcld_pts = int(profile['vcld_pts']) if "my_qst_id" not in profile: - resp.my_qst_id = profile['my_qst_id'] + quests = profile['my_qst_id'].split(",") + for x in range(len(quests)): + resp.my_qst_id[x] = int(quests[x]) response = "&chllng_kind=-1" response += f"&lv_num_old={int(profile['lv_num'])}" diff --git a/titles/diva/handlers/pv.py b/titles/diva/handlers/pv.py index 98ac404..e3ecae0 100644 --- a/titles/diva/handlers/pv.py +++ b/titles/diva/handlers/pv.py @@ -139,18 +139,18 @@ class StageResultResponse(BaseResponse): self.cerwd_value = -1 self.cerwd_str_0 = "***" self.cerwd_str_1 = "***" - self.ttl_str_ary = "xxx,xxx,xxx,xxx,xxx" - self.ttl_plt_id_ary = "xxx,xxx,xxx,xxx,xxx" - self.ttl_desc_ary = "xxx,xxx,xxx,xxx,xxx" - self.skin_id_ary = "xxx,xxx,xxx,xxx,xxx" - self.skin_name_ary = "xxx,xxx,xxx,xxx,xxx" - self.skin_illust_ary = "xxx,xxx,xxx,xxx,xxx" - self.skin_desc_ary = "xxx,xxx,xxx,xxx,xxx" - self.my_qst_id = "-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1" - self.my_qst_r_qid = "-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1" - self.my_qst_r_knd = "-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1" - self.my_qst_r_vl = "-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1" - self.my_qst_r_nflg = "-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1" - self.my_ccd_r_qid = "-1,-1,-1,-1,-1" - self.my_ccd_r_hnd = "-1,-1,-1,-1,-1" - self.my_ccd_r_vp = "-1,-1,-1,-1,-1" + self.ttl_str_ary = ["xxx"] * 5 + self.ttl_plt_id_ary = ["xxx"] * 5 + self.ttl_desc_ary = ["xxx"] * 5 + self.skin_id_ary = ["xxx"] * 5 + self.skin_name_ary = ["xxx"] * 5 + self.skin_illust_ary = ["xxx"] * 5 + self.skin_desc_ary = ["xxx"] * 5 + self.my_qst_id = [-1] * 25 + self.my_qst_r_qid = [-1] * 25 + self.my_qst_r_knd = [-1] * 25 + self.my_qst_r_vl = [-1] * 25 + self.my_qst_r_nflg = [-1] * 25 + self.my_ccd_r_qid = [-1] * 5 + self.my_ccd_r_hnd = [-1] * 5 + self.my_ccd_r_vp = [-1] * 5