mirror of
https://gitea.tendokyu.moe/Hay1tsme/artemis.git
synced 2026-02-15 04:07:29 +08:00
diva: add register, fixes, start still busted
This commit is contained in:
@@ -27,21 +27,7 @@ class PreStartRequest(BaseRequest):
|
||||
|
||||
|
||||
class PreStartResponse(BaseResponse):
|
||||
player_name: str
|
||||
sort_kind: str
|
||||
lv_efct_id: str
|
||||
lv_plt_id: str
|
||||
lv_str: str
|
||||
lv_num: str
|
||||
lv_pnt: str
|
||||
vcld_pts: str
|
||||
skn_eqp: str
|
||||
btn_se_eqp: str
|
||||
sld_se_eqp: str
|
||||
chn_sld_se_eqp: str
|
||||
sldr_tch_se_eqp: str
|
||||
passwd_stat: str
|
||||
mdl_eqp_tm: str
|
||||
|
||||
|
||||
def __init__(self, cmd_id: str, req_id: int, pd_id: int) -> None:
|
||||
super().__init__(cmd_id, req_id)
|
||||
@@ -51,6 +37,21 @@ class PreStartResponse(BaseResponse):
|
||||
self.nblss_ltt_stts = -1
|
||||
self.nblss_ltt_tckt = -1
|
||||
self.nblss_ltt_is_opn = -1
|
||||
self.player_name: str = ""
|
||||
self.sort_kind: str = ""
|
||||
self.lv_efct_id: str = ""
|
||||
self.lv_plt_id: str = ""
|
||||
self.lv_str: str = ""
|
||||
self.lv_num: str = ""
|
||||
self.lv_pnt: str = ""
|
||||
self.vcld_pts: str = ""
|
||||
self.skn_eqp: str = ""
|
||||
self.btn_se_eqp: str = ""
|
||||
self.sld_se_eqp: str = ""
|
||||
self.chn_sld_se_eqp: str = ""
|
||||
self.sldr_tch_se_eqp: str = ""
|
||||
self.passwd_stat: str = ""
|
||||
self.mdl_eqp_tm: str = ""
|
||||
# Ideally this would be a real array that would get converted later
|
||||
# But this is how it's stored in the db, so w/e for now
|
||||
self.mdl_eqp_ary = "-999,-999,-999"
|
||||
@@ -100,6 +101,11 @@ class StartResponse(BaseResponse):
|
||||
self.dsp_intrm_rnk: int = 0
|
||||
self.dsp_clr_sts: int = 0
|
||||
self.rgo_sts: int = 0
|
||||
self.cv_cid: str = "-1,-1,-1,-1"
|
||||
self.cv_sc: str = "-1,-1,-1,-1"
|
||||
#self.cv_bv: str = "-1,-1,-1,-1"
|
||||
self.cv_bv: str = "-1,-1,-1,-1"
|
||||
self.cv_bf: str = "-1,-1,-1,-1"
|
||||
self.my_qst_id: str = ",".join(["-1"] * 25)
|
||||
self.my_qst_sts: str = ",".join("0" * 5) + "," + ",".join(["-1"] * 20)
|
||||
self.my_qst_prgrs: str = ",".join("0" * 5) + "," + ",".join(["-1"] * 20)
|
||||
@@ -109,3 +115,28 @@ class StartResponse(BaseResponse):
|
||||
self.mdl_eqp_ary = ",".join(["-999"] * 3)
|
||||
self.c_itm_eqp_ary = ",".join(["-999"] * 12)
|
||||
self.ms_itm_flg_ary = ",".join(["1"] * 12)
|
||||
|
||||
class RegisterRequest(BaseRequest):
|
||||
pmm: str
|
||||
idm: str
|
||||
mmgameid: str
|
||||
mmuid: str
|
||||
a_code: str
|
||||
aime_a_code: str
|
||||
player_name: str
|
||||
passwd: str
|
||||
|
||||
def __init__(self, raw: str) -> None:
|
||||
super().__init__(raw)
|
||||
try:
|
||||
self.aime_id = int(self.aime_id)
|
||||
self.key_obj_type = int(self.key_obj_type)
|
||||
|
||||
except AttributeError as e:
|
||||
raise DivaRequestParseException(f"RegisterRequest: {e}")
|
||||
|
||||
class RegisterResponse(BaseResponse):
|
||||
def __init__(self, cmd_id: str, req_id: int, pv_id: int) -> None:
|
||||
super().__init__(cmd_id, req_id)
|
||||
self.cd_adm_result: int = 1
|
||||
self.pd_id: int = pv_id
|
||||
|
||||
Reference in New Issue
Block a user