mirror of
https://github.com/baiqwerdvd/ArknightsUID.git
synced 2025-05-04 19:17:33 +08:00
🔥 支持低版本py,改用msgspec读取excel
This commit is contained in:
parent
ef3067955c
commit
c0ff6960bf
2
.gitignore
vendored
2
.gitignore
vendored
@ -669,7 +669,7 @@ result.txt
|
||||
### ArknightsUID ###
|
||||
ArknightsUID/tools/
|
||||
upload_file.py
|
||||
|
||||
test.py
|
||||
|
||||
### Debug ###
|
||||
testnb2/
|
||||
|
@ -1,3 +1,4 @@
|
||||
from typing import Dict
|
||||
from gsuid_core.gss import gss
|
||||
from gsuid_core.logger import logger
|
||||
|
||||
@ -15,8 +16,8 @@ NOTICE = {
|
||||
}
|
||||
|
||||
|
||||
async def get_notice_list() -> dict[str, dict[str, dict]]:
|
||||
msg_dict: dict[str, dict[str, dict]] = {}
|
||||
async def get_notice_list() -> Dict[str, Dict[str, Dict]]:
|
||||
msg_dict: Dict[str, Dict[str, Dict]] = {}
|
||||
for _bot_id in gss.active_bot:
|
||||
user_list = await ArknightsUser.get_all_push_user_list()
|
||||
for user in user_list:
|
||||
@ -40,11 +41,11 @@ async def get_notice_list() -> dict[str, dict[str, dict]]:
|
||||
async def all_check(
|
||||
bot_id: str,
|
||||
raw_data: ArknightsPlayerInfoModel,
|
||||
push_data: dict,
|
||||
msg_dict: dict[str, dict[str, dict]],
|
||||
push_data: Dict,
|
||||
msg_dict: Dict[str, Dict[str, Dict]],
|
||||
user_id: str,
|
||||
uid: str,
|
||||
) -> dict[str, dict[str, dict]]:
|
||||
) -> Dict[str, Dict[str, Dict]]:
|
||||
for mode in NOTICE.keys():
|
||||
# 检查条件
|
||||
if push_data[f'{mode}_is_push'] is True:
|
||||
|
@ -1,3 +1,4 @@
|
||||
from typing import Dict
|
||||
from gsuid_core.utils.plugins_config.models import (
|
||||
GSC,
|
||||
GsBoolConfig,
|
||||
@ -5,7 +6,7 @@ from gsuid_core.utils.plugins_config.models import (
|
||||
GsStrConfig,
|
||||
)
|
||||
|
||||
CONIFG_DEFAULT: dict[str, GSC] = {
|
||||
CONIFG_DEFAULT: Dict[str, GSC] = {
|
||||
'SignTime': GsListStrConfig('每晚签到时间设置', '每晚森空岛签到时间设置(时,分)', ['0', '38']),
|
||||
'SignReportSimple': GsBoolConfig(
|
||||
'简洁签到报告',
|
||||
|
@ -1,4 +1,5 @@
|
||||
from pathlib import Path
|
||||
from typing import Dict, Union
|
||||
|
||||
import aiofiles
|
||||
from gsuid_core.help.draw_plugin_help import get_help
|
||||
@ -13,15 +14,15 @@ TEXT_PATH = Path(__file__).parent / 'texture2d'
|
||||
HELP_DATA = Path(__file__).parent / 'Help.json'
|
||||
|
||||
|
||||
async def get_help_data() -> dict[str, PluginHelp] | None:
|
||||
async def get_help_data() -> Union[Dict[str, PluginHelp], None]:
|
||||
if HELP_DATA.exists():
|
||||
async with aiofiles.open(HELP_DATA, 'rb') as file:
|
||||
return msgjson.decode(
|
||||
await file.read(), type=dict[str, PluginHelp],
|
||||
await file.read(), type=Dict[str, PluginHelp],
|
||||
)
|
||||
|
||||
|
||||
async def get_core_help() -> bytes | str:
|
||||
async def get_core_help() -> Union[bytes, str]:
|
||||
help_data = await get_help_data()
|
||||
if help_data is None:
|
||||
return '暂未找到帮助数据...'
|
||||
|
@ -2,7 +2,7 @@ import json
|
||||
from functools import cache
|
||||
from pathlib import Path
|
||||
from time import time
|
||||
from typing import Any, ClassVar
|
||||
from typing import Any, ClassVar, Dict, Union
|
||||
|
||||
from loguru import logger
|
||||
|
||||
@ -10,54 +10,58 @@ from ..utils.file import read_json
|
||||
|
||||
|
||||
class StoreData:
|
||||
data: dict[Any, Any]
|
||||
data: Dict[Any, Any]
|
||||
modification_time: float
|
||||
|
||||
def __init__(self, data: dict[Any, Any], modification_time: float) -> None:
|
||||
def __init__(self, data: Dict[Any, Any], modification_time: float) -> None:
|
||||
self.data = data
|
||||
self.modification_time = modification_time
|
||||
|
||||
|
||||
class CacheData:
|
||||
cached_data: ClassVar[dict[str, StoreData]] = {}
|
||||
cached_data: ClassVar[Dict[str, StoreData]] = {}
|
||||
|
||||
@classmethod
|
||||
@cache
|
||||
def get_cache(cls, local_path: Path) -> dict[Any, Any]:
|
||||
def get_cache(cls, local_path: Path) -> Dict[Any, Any]:
|
||||
data_name = local_path.stem
|
||||
if data_name in cls.cached_data:
|
||||
current_modification_time = local_path.stat().st_mtime
|
||||
if current_modification_time == cls.cached_data[data_name].modification_time:
|
||||
logger.debug(f'hit cached: {data_name}')
|
||||
return cls.cached_data[data_name].data
|
||||
return cls.set_cache(local_path, data_name)
|
||||
|
||||
@classmethod
|
||||
def set_cache(
|
||||
cls, local_path: Path | None, data_name: str, memory_data: dict | None = None
|
||||
) -> dict[Any, Any]:
|
||||
cls, local_path: Union[Path, None], data_name: str, memory_data: Union[Dict, None] = None
|
||||
) -> Dict[Any, Any]:
|
||||
data = read_json(local_path) if local_path else memory_data
|
||||
if data is None:
|
||||
raise FileNotFoundError
|
||||
modification_time = local_path.stat().st_mtime if local_path else time()
|
||||
cls.cached_data[data_name] = StoreData(data, modification_time)
|
||||
logger.debug(f'cached: {data_name}')
|
||||
return cls.cached_data[data_name].data
|
||||
|
||||
@classmethod
|
||||
def readFile(cls, local_path: Path) -> dict[Any, Any]:
|
||||
def readFile(cls, local_path: Path) -> Dict[Any, Any]:
|
||||
try:
|
||||
if isinstance(local_path, str):
|
||||
local_path = Path(local_path)
|
||||
logger.debug(f'loading: {local_path.stem}')
|
||||
return cls.get_cache(local_path)
|
||||
except json.decoder.JSONDecodeError as e:
|
||||
logger.error(f'Could not load file "{local_path}".')
|
||||
raise FileNotFoundError from e
|
||||
|
||||
@classmethod
|
||||
def readExcel(cls, table_name: str) -> dict[Any, Any]:
|
||||
def readExcel(cls, table_name: str) -> Dict[Any, Any]:
|
||||
logger.debug(f'loading: {table_name}.json')
|
||||
if table_name not in cls.cached_data:
|
||||
return {}
|
||||
return cls.cached_data[table_name].data
|
||||
|
||||
@classmethod
|
||||
def readBytesExcel(cls, table_name: str) -> bytes:
|
||||
logger.debug(f'loading: {table_name}.json')
|
||||
if table_name not in cls.cached_data:
|
||||
return bytes({})
|
||||
return json.dumps(cls.cached_data[table_name].data).encode('utf-8')
|
||||
|
@ -1,12 +1,14 @@
|
||||
import inspect
|
||||
from typing import Dict, Union
|
||||
from msgspec import json as msgjson
|
||||
|
||||
from ..utils.models.gamedata.ActivityTable import ActivityTable
|
||||
from ..utils.models.gamedata.AudioData import AudioData
|
||||
from ..utils.models.gamedata.BattleEquipTable import BattleEquipTable
|
||||
from ..utils.models.gamedata.BattleEquipTable import BattleEquipData
|
||||
from ..utils.models.gamedata.BuildingData import BuildingData
|
||||
from ..utils.models.gamedata.CampaignTable import CampaignTable
|
||||
from ..utils.models.gamedata.ChapterTable import ChapterTable
|
||||
from ..utils.models.gamedata.CharacterTable import CharacterTable
|
||||
from ..utils.models.gamedata.ChapterTable import ChapterData
|
||||
from ..utils.models.gamedata.CharacterTable import CharacterData
|
||||
from ..utils.models.gamedata.CharMetaTable import CharMetaTable
|
||||
from ..utils.models.gamedata.CharmTable import CharmTable
|
||||
from ..utils.models.gamedata.CharPatchTable import CharPatchTable
|
||||
@ -22,28 +24,28 @@ from ..utils.models.gamedata.GachaTable import GachaTable
|
||||
from ..utils.models.gamedata.GamedataConst import GamedataConst
|
||||
from ..utils.models.gamedata.HandbookInfoTable import HandbookInfoTable
|
||||
from ..utils.models.gamedata.HandbookTable import HandbookTable
|
||||
from ..utils.models.gamedata.HandbookTeamTable import HandbookTeamTable
|
||||
from ..utils.models.gamedata.HandbookTeamTable import HandbookTeam
|
||||
from ..utils.models.gamedata.ItemTable import ItemTable
|
||||
from ..utils.models.gamedata.MedalTable import MedalTable
|
||||
from ..utils.models.gamedata.MissionTable import MissionTable
|
||||
from ..utils.models.gamedata.OpenServerTable import OpenServerTable
|
||||
from ..utils.models.gamedata.PlayerAvatarTable import PlayerAvatarTable
|
||||
from ..utils.models.gamedata.RangeTable import RangeTable
|
||||
from ..utils.models.gamedata.ReplicateTable import ReplicateTable
|
||||
from ..utils.models.gamedata.RangeTable import Stage
|
||||
from ..utils.models.gamedata.ReplicateTable import ReplicateList
|
||||
from ..utils.models.gamedata.RetroTable import RetroTable
|
||||
from ..utils.models.gamedata.RoguelikeTable import RoguelikeTable
|
||||
from ..utils.models.gamedata.RoguelikeTopicTable import RoguelikeTopicTable
|
||||
from ..utils.models.gamedata.SandboxTable import SandboxTable
|
||||
from ..utils.models.gamedata.ShopClientTable import ShopClientTable
|
||||
from ..utils.models.gamedata.SkillTable import SkillTable
|
||||
from ..utils.models.gamedata.SkillTable import SkillDataBundle
|
||||
from ..utils.models.gamedata.SkinTable import SkinTable
|
||||
from ..utils.models.gamedata.StageTable import StageTable
|
||||
from ..utils.models.gamedata.StoryReviewMetaTable import StoryReviewMetaTable
|
||||
from ..utils.models.gamedata.StoryReviewTable import StoryReviewTable
|
||||
from ..utils.models.gamedata.StoryTable import StoryTable
|
||||
from ..utils.models.gamedata.StoryReviewTable import StoryReviewGroupClientData
|
||||
from ..utils.models.gamedata.StoryTable import StoryData
|
||||
from ..utils.models.gamedata.TechBuffTable import TechBuffTable
|
||||
from ..utils.models.gamedata.TipTable import TipTable
|
||||
from ..utils.models.gamedata.TokenTable import TokenTable
|
||||
from ..utils.models.gamedata.TokenTable import TokenCharacterData
|
||||
from ..utils.models.gamedata.UniequipData import UniequipData
|
||||
from ..utils.models.gamedata.UniequipTable import UniEquipTable
|
||||
from ..utils.models.gamedata.ZoneTable import ZoneTable
|
||||
@ -51,63 +53,58 @@ from .cachedata import CacheData
|
||||
|
||||
|
||||
class ExcelTableManager:
|
||||
activity_table_: ActivityTable | None = None
|
||||
audio_data_: AudioData | None = None
|
||||
battle_equip_table_: BattleEquipTable | None = None
|
||||
building_data_: BuildingData | None = None
|
||||
campaign_table_: CampaignTable | None = None
|
||||
chapter_table_: ChapterTable | None = None
|
||||
character_table_: CharacterTable | None = None
|
||||
char_meta_table_: CharMetaTable | None = None
|
||||
charm_table_: CharmTable | None = None
|
||||
char_patch_table_: CharPatchTable | None = None
|
||||
charword_table_: CharwordTable | None = None
|
||||
checkin_table_: CheckinTable | None = None
|
||||
climb_tower_table_: ClimbTowerTable | None = None
|
||||
clue_data_: ClueData | None = None
|
||||
crisis_table_: CrisisTable | None = None
|
||||
display_meta_table_: DisplayMetaTable | None = None
|
||||
enemy_handbook_table_: EnemyHandbookTable | None = None
|
||||
favor_table_: FavorTable | None = None
|
||||
gacha_table_: GachaTable | None = None
|
||||
gamedata_const_: GamedataConst | None = None
|
||||
handbook_info_table_: HandbookInfoTable | None = None
|
||||
handbook_table_: HandbookTable | None = None
|
||||
handbook_team_table_: HandbookTeamTable | None = None
|
||||
item_table_: ItemTable | None = None
|
||||
medal_table_: MedalTable | None = None
|
||||
mission_table_: MissionTable | None = None
|
||||
open_server_table_: OpenServerTable | None = None
|
||||
player_avatar_table_: PlayerAvatarTable | None = None
|
||||
range_table_: RangeTable | None = None
|
||||
replicate_table_: ReplicateTable | None = None
|
||||
retro_table_: RetroTable | None = None
|
||||
roguelike_table_: RoguelikeTable | None = None
|
||||
roguelike_topic_table_: RoguelikeTopicTable | None = None
|
||||
sandbox_table_: SandboxTable | None = None
|
||||
shop_client_table_: ShopClientTable | None = None
|
||||
skill_table_: SkillTable | None = None
|
||||
skin_table_: SkinTable | None = None
|
||||
stage_table_: StageTable | None = None
|
||||
story_review_meta_table_: StoryReviewMetaTable | None = None
|
||||
story_review_table_: StoryReviewTable | None = None
|
||||
story_table_: StoryTable | None = None
|
||||
tech_buff_table_: TechBuffTable | None = None
|
||||
tip_table_: TipTable | None = None
|
||||
token_table_: TokenTable | None = None
|
||||
uniequip_data_: UniequipData | None = None
|
||||
uniequip_table_: UniEquipTable | None = None
|
||||
zone_table_: ZoneTable | None = None
|
||||
activity_table_: Union[ActivityTable, None] = None
|
||||
audio_data_: Union[AudioData, None] = None
|
||||
battle_equip_table_: Union[Dict[str, BattleEquipData], None] = None
|
||||
building_data_: Union[BuildingData, None] = None
|
||||
campaign_table_: Union[CampaignTable, None] = None
|
||||
chapter_table_: Union[Dict[str, ChapterData], None] = None
|
||||
character_table_: Union[Dict[str, CharacterData], None] = None
|
||||
char_meta_table_: Union[CharMetaTable, None] = None
|
||||
charm_table_: Union[CharmTable, None] = None
|
||||
char_patch_table_: Union[CharPatchTable, None] = None
|
||||
charword_table_: Union[CharwordTable, None] = None
|
||||
checkin_table_: Union[CheckinTable, None] = None
|
||||
climb_tower_table_: Union[ClimbTowerTable, None] = None
|
||||
clue_data_: Union[ClueData, None] = None
|
||||
crisis_table_: Union[CrisisTable, None] = None
|
||||
display_meta_table_: Union[DisplayMetaTable, None] = None
|
||||
enemy_handbook_table_: Union[EnemyHandbookTable, None] = None
|
||||
favor_table_: Union[FavorTable, None] = None
|
||||
gacha_table_: Union[GachaTable, None] = None
|
||||
gamedata_const_: Union[GamedataConst, None] = None
|
||||
handbook_info_table_: Union[HandbookInfoTable, None] = None
|
||||
handbook_table_: Union[HandbookTable, None] = None
|
||||
handbook_team_table_: Union[Dict[str, HandbookTeam], None] = None
|
||||
item_table_: Union[ItemTable, None] = None
|
||||
medal_table_: Union[MedalTable, None] = None
|
||||
mission_table_: Union[MissionTable, None] = None
|
||||
open_server_table_: Union[OpenServerTable, None] = None
|
||||
player_avatar_table_: Union[PlayerAvatarTable, None] = None
|
||||
range_table_: Union[Dict[str, Stage], None] = None
|
||||
replicate_table_: Union[Dict[str, ReplicateList], None] = None
|
||||
retro_table_: Union[RetroTable, None] = None
|
||||
roguelike_table_: Union[RoguelikeTable, None] = None
|
||||
roguelike_topic_table_: Union[RoguelikeTopicTable, None] = None
|
||||
sandbox_table_: Union[SandboxTable, None] = None
|
||||
shop_client_table_: Union[ShopClientTable, None] = None
|
||||
skill_table_: Union[Dict[str, SkillDataBundle], None] = None
|
||||
skin_table_: Union[SkinTable, None] = None
|
||||
stage_table_: Union[StageTable, None] = None
|
||||
story_review_meta_table_: Union[StoryReviewMetaTable, None] = None
|
||||
story_review_table_: Union[Dict[str, StoryReviewGroupClientData], None] = None
|
||||
story_table_: Union[Dict[str, StoryData], None] = None
|
||||
tech_buff_table_: Union[TechBuffTable, None] = None
|
||||
tip_table_: Union[TipTable, None] = None
|
||||
token_table_: Union[Dict[str, TokenCharacterData], None] = None
|
||||
uniequip_data_: Union[UniequipData, None] = None
|
||||
uniequip_table_: Union[UniEquipTable, None] = None
|
||||
zone_table_: Union[ZoneTable, None] = None
|
||||
|
||||
@property
|
||||
def ACTIVITY_TABLE(self) -> ActivityTable:
|
||||
if not self.activity_table_:
|
||||
if hasattr(ActivityTable, 'model_validate'):
|
||||
self.activity_table_ = ActivityTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('activity_table')
|
||||
)
|
||||
else:
|
||||
self.activity_table_ = ActivityTable.parse_obj(
|
||||
self.activity_table_ = ActivityTable.convert(
|
||||
CacheData.readExcel('activity_table')
|
||||
)
|
||||
return self.activity_table_
|
||||
@ -115,33 +112,24 @@ class ExcelTableManager:
|
||||
@property
|
||||
def AUDIO_DATA(self) -> AudioData:
|
||||
if not self.audio_data_:
|
||||
if hasattr(AudioData, 'model_validate'):
|
||||
self.audio_data_ = AudioData.model_validate( # type: ignore
|
||||
CacheData.readExcel('audio_data')
|
||||
)
|
||||
else:
|
||||
self.audio_data_ = AudioData.parse_obj(
|
||||
self.audio_data_ = AudioData.convert(
|
||||
CacheData.readExcel('audio_data')
|
||||
)
|
||||
return self.audio_data_
|
||||
|
||||
@property
|
||||
def BATTLE_EQUIP_TABLE(self) -> BattleEquipTable:
|
||||
def BATTLE_EQUIP_TABLE(self) -> Dict[str, BattleEquipData]:
|
||||
if not self.battle_equip_table_:
|
||||
self.battle_equip_table_ = BattleEquipTable(
|
||||
CacheData.readExcel('battle_equip_table')
|
||||
self.battle_equip_table_ = msgjson.decode(
|
||||
CacheData.readBytesExcel('battle_equip_table'),
|
||||
type=Dict[str, BattleEquipData]
|
||||
)
|
||||
return self.battle_equip_table_
|
||||
|
||||
@property
|
||||
def BUILDING_DATA(self) -> BuildingData:
|
||||
if not self.building_data_:
|
||||
if hasattr(BuildingData, 'model_validate'):
|
||||
self.building_data_ = BuildingData.model_validate( # type: ignore
|
||||
CacheData.readExcel('building_data')
|
||||
)
|
||||
else:
|
||||
self.building_data_ = BuildingData.parse_obj(
|
||||
self.building_data_ = BuildingData.convert(
|
||||
CacheData.readExcel('building_data')
|
||||
)
|
||||
return self.building_data_
|
||||
@ -149,44 +137,33 @@ class ExcelTableManager:
|
||||
@property
|
||||
def CAMPAIGN_TABLE(self) -> CampaignTable:
|
||||
if not self.campaign_table_:
|
||||
if hasattr(CampaignTable, 'model_validate'):
|
||||
self.campaign_table_ = CampaignTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('campaign_table')
|
||||
)
|
||||
else:
|
||||
self.campaign_table_ = CampaignTable.parse_obj(
|
||||
self.campaign_table_ = CampaignTable.convert(
|
||||
CacheData.readExcel('campaign_table')
|
||||
)
|
||||
return self.campaign_table_
|
||||
|
||||
@property
|
||||
def CHAPTER_TABLE(self) -> ChapterTable:
|
||||
def CHAPTER_TABLE(self) -> Dict[str, ChapterData]:
|
||||
if not self.chapter_table_:
|
||||
self.chapter_table_ = ChapterTable(CacheData.readExcel('chapter_table'))
|
||||
self.chapter_table_ = msgjson.decode(
|
||||
CacheData.readBytesExcel('chapter_table'),
|
||||
type=Dict[str, ChapterData]
|
||||
)
|
||||
return self.chapter_table_
|
||||
|
||||
@property
|
||||
def CHARATER_TABLE(self) -> CharacterTable:
|
||||
def CHARATER_TABLE(self) -> Dict[str, CharacterData]:
|
||||
if not self.character_table_:
|
||||
if hasattr(CharacterTable, 'model_validate'):
|
||||
self.character_table_ = CharacterTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('character_table')
|
||||
)
|
||||
else:
|
||||
self.character_table_ = CharacterTable(
|
||||
CacheData.readExcel('character_table')
|
||||
self.character_table_ = msgjson.decode(
|
||||
CacheData.readBytesExcel('character_table'),
|
||||
type=Dict[str, CharacterData]
|
||||
)
|
||||
return self.character_table_
|
||||
|
||||
@property
|
||||
def CHAR_META_TABLE(self) -> CharMetaTable:
|
||||
if not self.char_meta_table_:
|
||||
if hasattr(CharMetaTable, 'model_validate'):
|
||||
self.char_meta_table_ = CharMetaTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('char_meta_table')
|
||||
)
|
||||
else:
|
||||
self.char_meta_table_ = CharMetaTable.parse_obj(
|
||||
self.char_meta_table_ = CharMetaTable.convert(
|
||||
CacheData.readExcel('char_meta_table')
|
||||
)
|
||||
return self.char_meta_table_
|
||||
@ -194,12 +171,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def CHARM_TABLE(self) -> CharmTable:
|
||||
if not self.charm_table_:
|
||||
if hasattr(CharmTable, 'model_validate'):
|
||||
self.charm_table_ = CharmTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('charm_table')
|
||||
)
|
||||
else:
|
||||
self.charm_table_ = CharmTable.parse_obj(
|
||||
self.charm_table_ = CharmTable.convert(
|
||||
CacheData.readExcel('charm_table')
|
||||
)
|
||||
return self.charm_table_
|
||||
@ -207,12 +179,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def CHAR_PATH_TABLE(self) -> CharPatchTable:
|
||||
if not self.char_patch_table_:
|
||||
if hasattr(CharPatchTable, 'model_validate'):
|
||||
self.char_patch_table_ = CharPatchTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('char_patch_table')
|
||||
)
|
||||
else:
|
||||
self.char_patch_table_ = CharPatchTable.parse_obj(
|
||||
self.char_patch_table_ = CharPatchTable.convert(
|
||||
CacheData.readExcel('char_patch_table')
|
||||
)
|
||||
return self.char_patch_table_
|
||||
@ -220,12 +187,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def CHARWORD_TABLE(self) -> CharwordTable:
|
||||
if not self.charword_table_:
|
||||
if hasattr(CharwordTable, 'model_validate'):
|
||||
self.charword_table_ = CharwordTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('charword_table')
|
||||
)
|
||||
else:
|
||||
self.charword_table_ = CharwordTable.parse_obj(
|
||||
self.charword_table_ = CharwordTable.convert(
|
||||
CacheData.readExcel('charword_table')
|
||||
)
|
||||
return self.charword_table_
|
||||
@ -233,12 +195,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def CHECKIN_TABLE(self) -> CheckinTable:
|
||||
if not self.checkin_table_:
|
||||
if hasattr(CheckinTable, 'model_validate'):
|
||||
self.checkin_table_ = CheckinTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('checkin_table')
|
||||
)
|
||||
else:
|
||||
self.checkin_table_ = CheckinTable.parse_obj(
|
||||
self.checkin_table_ = CheckinTable.convert(
|
||||
CacheData.readExcel('checkin_table')
|
||||
)
|
||||
return self.checkin_table_
|
||||
@ -246,12 +203,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def CLIMB_TOWER_TABLE(self) -> ClimbTowerTable:
|
||||
if not self.climb_tower_table_:
|
||||
if hasattr(ClimbTowerTable, 'model_validate'):
|
||||
self.climb_tower_table_ = ClimbTowerTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('climb_tower_table')
|
||||
)
|
||||
else:
|
||||
self.climb_tower_table_ = ClimbTowerTable.parse_obj(
|
||||
self.climb_tower_table_ = ClimbTowerTable.convert(
|
||||
CacheData.readExcel('climb_tower_table')
|
||||
)
|
||||
return self.climb_tower_table_
|
||||
@ -259,12 +211,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def CLUE_DATA(self) -> ClueData:
|
||||
if not self.clue_data_:
|
||||
if hasattr(ClueData, 'model_validate'):
|
||||
self.clue_data_ = ClueData.model_validate( # type: ignore
|
||||
CacheData.readExcel('clue_data')
|
||||
)
|
||||
else:
|
||||
self.clue_data_ = ClueData.parse_obj(
|
||||
self.clue_data_ = ClueData.convert(
|
||||
CacheData.readExcel('clue_data')
|
||||
)
|
||||
return self.clue_data_
|
||||
@ -272,12 +219,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def CRISIS_TABLE(self) -> CrisisTable:
|
||||
if not self.crisis_table_:
|
||||
if hasattr(CrisisTable, 'model_validate'):
|
||||
self.crisis_table_ = CrisisTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('crisis_table')
|
||||
)
|
||||
else:
|
||||
self.crisis_table_ = CrisisTable.parse_obj(
|
||||
self.crisis_table_ = CrisisTable.convert(
|
||||
CacheData.readExcel('crisis_table')
|
||||
)
|
||||
return self.crisis_table_
|
||||
@ -285,12 +227,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def DISPLAY_META_TABLE(self) -> DisplayMetaTable:
|
||||
if not self.display_meta_table_:
|
||||
if hasattr(DisplayMetaTable, 'model_validate'):
|
||||
self.display_meta_table_ = DisplayMetaTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('display_meta_table')
|
||||
)
|
||||
else:
|
||||
self.display_meta_table_ = DisplayMetaTable.parse_obj(
|
||||
self.display_meta_table_ = DisplayMetaTable.convert(
|
||||
CacheData.readExcel('display_meta_table')
|
||||
)
|
||||
return self.display_meta_table_
|
||||
@ -298,12 +235,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def ENEMY_HANDBOOK_TABLE(self) -> EnemyHandbookTable:
|
||||
if not self.enemy_handbook_table_:
|
||||
if hasattr(EnemyHandbookTable, 'model_validate'):
|
||||
self.enemy_handbook_table_ = EnemyHandbookTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('enemy_handbook_table')
|
||||
)
|
||||
else:
|
||||
self.enemy_handbook_table_ = EnemyHandbookTable.parse_obj(
|
||||
self.enemy_handbook_table_ = EnemyHandbookTable.convert(
|
||||
CacheData.readExcel('enemy_handbook_table')
|
||||
)
|
||||
return self.enemy_handbook_table_
|
||||
@ -311,12 +243,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def FAVOR_TABLE(self) -> FavorTable:
|
||||
if not self.favor_table_:
|
||||
if hasattr(FavorTable, 'model_validate'):
|
||||
self.favor_table_ = FavorTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('favor_table')
|
||||
)
|
||||
else:
|
||||
self.favor_table_ = FavorTable.parse_obj(
|
||||
self.favor_table_ = FavorTable.convert(
|
||||
CacheData.readExcel('favor_table')
|
||||
)
|
||||
return self.favor_table_
|
||||
@ -324,12 +251,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def GACHA_TABLE(self) -> GachaTable:
|
||||
if not self.gacha_table_:
|
||||
if hasattr(GachaTable, 'model_validate'):
|
||||
self.gacha_table_ = GachaTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('gacha_table')
|
||||
)
|
||||
else:
|
||||
self.gacha_table_ = GachaTable.parse_obj(
|
||||
self.gacha_table_ = GachaTable.convert(
|
||||
CacheData.readExcel('gacha_table')
|
||||
)
|
||||
return self.gacha_table_
|
||||
@ -337,12 +259,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def GAMEDATA_CONST(self) -> GamedataConst:
|
||||
if not self.gamedata_const_:
|
||||
if hasattr(GamedataConst, 'model_validate'):
|
||||
self.gamedata_const_ = GamedataConst.model_validate( # type: ignore
|
||||
CacheData.readExcel('gamedata_const')
|
||||
)
|
||||
else:
|
||||
self.gamedata_const_ = GamedataConst.parse_obj(
|
||||
self.gamedata_const_ = GamedataConst.convert(
|
||||
CacheData.readExcel('gamedata_const')
|
||||
)
|
||||
return self.gamedata_const_
|
||||
@ -350,12 +267,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def HANDBOOK_INFO_TABLE(self) -> HandbookInfoTable:
|
||||
if not self.handbook_info_table_:
|
||||
if hasattr(HandbookInfoTable, 'model_validate'):
|
||||
self.handbook_info_table_ = HandbookInfoTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('handbook_info_table')
|
||||
)
|
||||
else:
|
||||
self.handbook_info_table_ = HandbookInfoTable.parse_obj(
|
||||
self.handbook_info_table_ = HandbookInfoTable.convert(
|
||||
CacheData.readExcel('handbook_info_table')
|
||||
)
|
||||
return self.handbook_info_table_
|
||||
@ -363,38 +275,24 @@ class ExcelTableManager:
|
||||
@property
|
||||
def HANDBOOK_TABLE(self) -> HandbookTable:
|
||||
if not self.handbook_table_:
|
||||
if hasattr(HandbookTable, 'model_validate'):
|
||||
self.handbook_table_ = HandbookTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('handbook_table')
|
||||
)
|
||||
else:
|
||||
self.handbook_table_ = HandbookTable.parse_obj(
|
||||
self.handbook_table_ = HandbookTable.convert(
|
||||
CacheData.readExcel('handbook_table')
|
||||
)
|
||||
return self.handbook_table_
|
||||
|
||||
@property
|
||||
def HANDBOOK_TEAM_TABLE(self) -> HandbookTeamTable:
|
||||
def HANDBOOK_TEAM_TABLE(self) -> Dict[str, HandbookTeam]:
|
||||
if not self.handbook_team_table_:
|
||||
if hasattr(HandbookTeamTable, 'model_validate'):
|
||||
self.handbook_team_table_ = HandbookTeamTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('handbook_team_table')
|
||||
)
|
||||
else:
|
||||
self.handbook_team_table_ = HandbookTeamTable.parse_obj(
|
||||
CacheData.readExcel('handbook_team_table')
|
||||
self.handbook_team_table_ = msgjson.decode(
|
||||
CacheData.readBytesExcel('handbook_team_table'),
|
||||
type=Dict[str, HandbookTeam]
|
||||
)
|
||||
return self.handbook_team_table_
|
||||
|
||||
@property
|
||||
def ITEM_TABLE(self) -> ItemTable:
|
||||
if not self.item_table_:
|
||||
if hasattr(ItemTable, 'model_validate'):
|
||||
self.item_table_ = ItemTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('item_table')
|
||||
)
|
||||
else:
|
||||
self.item_table_ = ItemTable.parse_obj(
|
||||
self.item_table_ = ItemTable.convert(
|
||||
CacheData.readExcel('item_table')
|
||||
)
|
||||
return self.item_table_
|
||||
@ -402,12 +300,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def MEDAL_TABLE(self) -> MedalTable:
|
||||
if not self.medal_table_:
|
||||
if hasattr(MedalTable, 'model_validate'):
|
||||
self.medal_table_ = MedalTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('medal_table')
|
||||
)
|
||||
else:
|
||||
self.medal_table_ = MedalTable.parse_obj(
|
||||
self.medal_table_ = MedalTable.convert(
|
||||
CacheData.readExcel('medal_table')
|
||||
)
|
||||
return self.medal_table_
|
||||
@ -415,12 +308,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def MISSION_TABLE(self) -> MissionTable:
|
||||
if not self.mission_table_:
|
||||
if hasattr(MissionTable, 'model_validate'):
|
||||
self.mission_table_ = MissionTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('mission_table')
|
||||
)
|
||||
else:
|
||||
self.mission_table_ = MissionTable.parse_obj(
|
||||
self.mission_table_ = MissionTable.convert(
|
||||
CacheData.readExcel('mission_table')
|
||||
)
|
||||
return self.mission_table_
|
||||
@ -428,12 +316,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def OPEN_SERVER_TABLE(self) -> OpenServerTable:
|
||||
if not self.open_server_table_:
|
||||
if hasattr(OpenServerTable, 'model_validate'):
|
||||
self.open_server_table_ = OpenServerTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('open_server_table')
|
||||
)
|
||||
else:
|
||||
self.open_server_table_ = OpenServerTable.parse_obj(
|
||||
self.open_server_table_ = OpenServerTable.convert(
|
||||
CacheData.readExcel('open_server_table')
|
||||
)
|
||||
return self.open_server_table_
|
||||
@ -441,51 +324,33 @@ class ExcelTableManager:
|
||||
@property
|
||||
def PLAYER_AVATAR_TABLE(self) -> PlayerAvatarTable:
|
||||
if not self.player_avatar_table_:
|
||||
if hasattr(PlayerAvatarTable, 'model_validate'):
|
||||
self.player_avatar_table_ = PlayerAvatarTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('player_avatar_table')
|
||||
)
|
||||
else:
|
||||
self.player_avatar_table_ = PlayerAvatarTable.parse_obj(
|
||||
self.player_avatar_table_ = PlayerAvatarTable.convert(
|
||||
CacheData.readExcel('player_avatar_table')
|
||||
)
|
||||
return self.player_avatar_table_
|
||||
|
||||
@property
|
||||
def RANGE_TABLE(self) -> RangeTable:
|
||||
def RANGE_TABLE(self) -> Dict[str, Stage]:
|
||||
if not self.range_table_:
|
||||
if hasattr(RangeTable, 'model_validate'):
|
||||
self.range_table_ = RangeTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('range_table')
|
||||
)
|
||||
else:
|
||||
self.range_table_ = RangeTable.parse_obj(
|
||||
CacheData.readExcel('range_table')
|
||||
self.range_table_ = msgjson.decode(
|
||||
CacheData.readBytesExcel('range_table'),
|
||||
type=Dict[str, Stage]
|
||||
)
|
||||
return self.range_table_
|
||||
|
||||
@property
|
||||
def REPLICATE_TABLE(self) -> ReplicateTable:
|
||||
def REPLICATE_TABLE(self) -> Dict[str, ReplicateList]:
|
||||
if not self.replicate_table_:
|
||||
if hasattr(ReplicateTable, 'model_validate'):
|
||||
self.replicate_table_ = ReplicateTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('replicate_table')
|
||||
)
|
||||
else:
|
||||
self.replicate_table_ = ReplicateTable.parse_obj(
|
||||
CacheData.readExcel('replicate_table')
|
||||
self.replicate_table_ = msgjson.decode(
|
||||
CacheData.readBytesExcel('replicate_table'),
|
||||
type=Dict[str, ReplicateList]
|
||||
)
|
||||
return self.replicate_table_
|
||||
|
||||
@property
|
||||
def RETRO_TABLE(self) -> RetroTable:
|
||||
if not self.retro_table_:
|
||||
if hasattr(RetroTable, 'model_validate'):
|
||||
self.retro_table_ = RetroTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('retro_table')
|
||||
)
|
||||
else:
|
||||
self.retro_table_ = RetroTable.parse_obj(
|
||||
self.retro_table_ = RetroTable.convert(
|
||||
CacheData.readExcel('retro_table')
|
||||
)
|
||||
return self.retro_table_
|
||||
@ -493,12 +358,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def ROGUELIKE_TABLE(self) -> RoguelikeTable:
|
||||
if not self.roguelike_table_:
|
||||
if hasattr(RoguelikeTable, 'model_validate'):
|
||||
self.roguelike_table_ = RoguelikeTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('roguelike_table')
|
||||
)
|
||||
else:
|
||||
self.roguelike_table_ = RoguelikeTable.parse_obj(
|
||||
self.roguelike_table_ = RoguelikeTable.convert(
|
||||
CacheData.readExcel('roguelike_table')
|
||||
)
|
||||
return self.roguelike_table_
|
||||
@ -506,12 +366,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def ROGUELIKE_TOPIC_TABLE(self) -> RoguelikeTopicTable:
|
||||
if not self.roguelike_topic_table_:
|
||||
if hasattr(RoguelikeTopicTable, 'model_validate'):
|
||||
self.roguelike_topic_table_ = RoguelikeTopicTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('roguelike_topic_table')
|
||||
)
|
||||
else:
|
||||
self.roguelike_topic_table_ = RoguelikeTopicTable.parse_obj(
|
||||
self.roguelike_topic_table_ = RoguelikeTopicTable.convert(
|
||||
CacheData.readExcel('roguelike_topic_table')
|
||||
)
|
||||
return self.roguelike_topic_table_
|
||||
@ -519,12 +374,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def SANDBOX_TABLE(self) -> SandboxTable:
|
||||
if not self.sandbox_table_:
|
||||
if hasattr(SandboxTable, 'model_validate'):
|
||||
self.sandbox_table_ = SandboxTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('sandbox_table')
|
||||
)
|
||||
else:
|
||||
self.sandbox_table_ = SandboxTable.parse_obj(
|
||||
self.sandbox_table_ = SandboxTable.convert(
|
||||
CacheData.readExcel('sandbox_table')
|
||||
)
|
||||
return self.sandbox_table_
|
||||
@ -532,31 +382,24 @@ class ExcelTableManager:
|
||||
@property
|
||||
def SHOP_CLIENT_TABLE(self) -> ShopClientTable:
|
||||
if not self.shop_client_table_:
|
||||
if hasattr(ShopClientTable, 'model_validate'):
|
||||
self.shop_client_table_ = ShopClientTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('shop_client_table')
|
||||
)
|
||||
else:
|
||||
self.shop_client_table_ = ShopClientTable.parse_obj(
|
||||
self.shop_client_table_ = ShopClientTable.convert(
|
||||
CacheData.readExcel('shop_client_table')
|
||||
)
|
||||
return self.shop_client_table_
|
||||
|
||||
@property
|
||||
def SKILL_TABLE(self) -> SkillTable:
|
||||
def SKILL_TABLE(self) -> Dict[str, SkillDataBundle]:
|
||||
if not self.skill_table_:
|
||||
self.skill_table_ = SkillTable(CacheData.readExcel('skill_table'))
|
||||
self.skill_table_ = msgjson.decode(
|
||||
CacheData.readBytesExcel('skill_table'),
|
||||
type=Dict[str, SkillDataBundle]
|
||||
)
|
||||
return self.skill_table_
|
||||
|
||||
@property
|
||||
def SKIN_TABLE(self) -> SkinTable:
|
||||
if not self.skin_table_:
|
||||
if hasattr(SkinTable, 'model_validate'):
|
||||
self.skin_table_ = SkinTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('skin_table')
|
||||
)
|
||||
else:
|
||||
self.skin_table_ = SkinTable.parse_obj(
|
||||
self.skin_table_ = SkinTable.convert(
|
||||
CacheData.readExcel('skin_table')
|
||||
)
|
||||
return self.skin_table_
|
||||
@ -564,12 +407,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def STAGE_TABLE(self) -> StageTable:
|
||||
if not self.stage_table_:
|
||||
if hasattr(StageTable, 'model_validate'):
|
||||
self.stage_table_ = StageTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('stage_table')
|
||||
)
|
||||
else:
|
||||
self.stage_table_ = StageTable.parse_obj(
|
||||
self.stage_table_ = StageTable.convert(
|
||||
CacheData.readExcel('stage_table')
|
||||
)
|
||||
return self.stage_table_
|
||||
@ -577,39 +415,33 @@ class ExcelTableManager:
|
||||
@property
|
||||
def STORY_REVIEW_META_TABLE(self) -> StoryReviewMetaTable:
|
||||
if not self.story_review_meta_table_:
|
||||
if hasattr(StoryReviewMetaTable, 'model_validate'):
|
||||
self.story_review_meta_table_ = StoryReviewMetaTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('story_review_meta_table')
|
||||
)
|
||||
else:
|
||||
self.story_review_meta_table_ = StoryReviewMetaTable.parse_obj(
|
||||
self.story_review_meta_table_ = StoryReviewMetaTable.convert(
|
||||
CacheData.readExcel('story_review_meta_table')
|
||||
)
|
||||
return self.story_review_meta_table_
|
||||
|
||||
@property
|
||||
def STORY_REVIEW_TABLE(self) -> StoryReviewTable:
|
||||
def STORY_REVIEW_TABLE(self) -> Dict[str, StoryReviewGroupClientData]:
|
||||
if not self.story_review_table_:
|
||||
self.story_review_table_ = StoryReviewTable(
|
||||
CacheData.readExcel('story_review_table')
|
||||
self.story_review_table_ = msgjson.decode(
|
||||
CacheData.readBytesExcel('story_review_table'),
|
||||
type=Dict[str, StoryReviewGroupClientData]
|
||||
)
|
||||
return self.story_review_table_
|
||||
|
||||
@property
|
||||
def STORY_TABLE(self) -> StoryTable:
|
||||
def STORY_TABLE(self) -> Dict[str, StoryData]:
|
||||
if not self.story_table_:
|
||||
self.story_table_ = StoryTable(CacheData.readExcel('story_table'))
|
||||
self.story_table_ = msgjson.decode(
|
||||
CacheData.readBytesExcel('story_table'),
|
||||
type=Dict[str, StoryData]
|
||||
)
|
||||
return self.story_table_
|
||||
|
||||
@property
|
||||
def TECH_BUFF_TABLE(self) -> TechBuffTable:
|
||||
if not self.tech_buff_table_:
|
||||
if hasattr(TechBuffTable, 'model_validate'):
|
||||
self.tech_buff_table_ = TechBuffTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('tech_buff_table')
|
||||
)
|
||||
else:
|
||||
self.tech_buff_table_ = TechBuffTable.parse_obj(
|
||||
self.tech_buff_table_ = TechBuffTable.convert(
|
||||
CacheData.readExcel('tech_buff_table')
|
||||
)
|
||||
return self.tech_buff_table_
|
||||
@ -617,31 +449,24 @@ class ExcelTableManager:
|
||||
@property
|
||||
def TIP_TABLE(self) -> TipTable:
|
||||
if not self.tip_table_:
|
||||
if hasattr(TipTable, 'model_validate'):
|
||||
self.tip_table_ = TipTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('tip_table')
|
||||
)
|
||||
else:
|
||||
self.tip_table_ = TipTable.parse_obj(
|
||||
self.tip_table_ = TipTable.convert(
|
||||
CacheData.readExcel('tip_table')
|
||||
)
|
||||
return self.tip_table_
|
||||
|
||||
@property
|
||||
def TOKEN_TABLE(self) -> TokenTable:
|
||||
def TOKEN_TABLE(self) -> Dict[str, TokenCharacterData]:
|
||||
if not self.token_table_:
|
||||
self.token_table_ = TokenTable(CacheData.readExcel('token_table'))
|
||||
self.token_table_ = msgjson.decode(
|
||||
CacheData.readBytesExcel('token_table'),
|
||||
type=Dict[str, TokenCharacterData]
|
||||
)
|
||||
return self.token_table_
|
||||
|
||||
@property
|
||||
def UNIEQUIP_DATA(self) -> UniequipData:
|
||||
if not self.uniequip_data_:
|
||||
if hasattr(UniequipData, 'model_validate'):
|
||||
self.uniequip_data_ = UniequipData.model_validate( # type: ignore
|
||||
CacheData.readExcel('uniequip_data')
|
||||
)
|
||||
else:
|
||||
self.uniequip_data_ = UniequipData.parse_obj(
|
||||
self.uniequip_data_ = UniequipData.convert(
|
||||
CacheData.readExcel('uniequip_data')
|
||||
)
|
||||
return self.uniequip_data_
|
||||
@ -649,12 +474,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def UNIEQUIP_TABLE(self) -> UniEquipTable:
|
||||
if not self.uniequip_table_:
|
||||
if hasattr(UniEquipTable, 'model_validate'):
|
||||
self.uniequip_table_ = UniEquipTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('uniequip_table')
|
||||
)
|
||||
else:
|
||||
self.uniequip_table_ = UniEquipTable.parse_obj(
|
||||
self.uniequip_table_ = UniEquipTable.convert(
|
||||
CacheData.readExcel('uniequip_table')
|
||||
)
|
||||
return self.uniequip_table_
|
||||
@ -662,12 +482,7 @@ class ExcelTableManager:
|
||||
@property
|
||||
def ZONE_TABLE(self) -> ZoneTable:
|
||||
if not self.zone_table_:
|
||||
if hasattr(ZoneTable, 'model_validate'):
|
||||
self.zone_table_ = ZoneTable.model_validate( # type: ignore
|
||||
CacheData.readExcel('zone_table')
|
||||
)
|
||||
else:
|
||||
self.zone_table_ = ZoneTable.parse_obj(
|
||||
self.zone_table_ = ZoneTable.convert(
|
||||
CacheData.readExcel('zone_table')
|
||||
)
|
||||
return self.zone_table_
|
||||
|
@ -1,3 +1,4 @@
|
||||
from typing import List
|
||||
from gsuid_core.bot import Bot
|
||||
from gsuid_core.models import Event
|
||||
from gsuid_core.sv import SV
|
||||
@ -50,7 +51,7 @@ async def send_link_uid_msg(bot: Bot, ev: Event):
|
||||
)
|
||||
elif '切换' in ev.command:
|
||||
data = await ArknightsBind.switch_uid_by_game(qid, ev.bot_id, ark_uid)
|
||||
if isinstance(data, list):
|
||||
if isinstance(data, List):
|
||||
return await bot.send(f'切换ARK_UID{ark_uid}成功!')
|
||||
else:
|
||||
return await bot.send(f'尚未绑定该ARK_UID{ark_uid}')
|
||||
|
@ -3,7 +3,7 @@ import hashlib
|
||||
import json
|
||||
import time
|
||||
import hmac
|
||||
from typing import Any, ClassVar, Literal, cast
|
||||
from typing import Any, ClassVar, Dict, Literal, Tuple, Union, cast
|
||||
from urllib.parse import urlparse
|
||||
|
||||
import msgspec
|
||||
@ -24,7 +24,7 @@ proxy_url = core_plugins_config.get_config('proxy').data
|
||||
ssl_verify = core_plugins_config.get_config('MhySSLVerify').data
|
||||
|
||||
|
||||
_HEADER: dict[str, str] = {
|
||||
_HEADER: Dict[str, str] = {
|
||||
'Host': 'zonai.skland.com',
|
||||
'platform': '1',
|
||||
'Origin': 'https://www.skland.com',
|
||||
@ -49,9 +49,9 @@ class TokenRefreshFailed(Exception):
|
||||
|
||||
|
||||
class BaseArkApi:
|
||||
proxy_url: str | None = proxy_url if proxy_url else None
|
||||
proxy_url: Union[str, None] = proxy_url if proxy_url else None
|
||||
|
||||
async def _pass(self, gt: str, ch: str) -> tuple[str | None, str | None]:
|
||||
async def _pass(self, gt: str, ch: str) -> Tuple[Union[str, None], Union[str, None]]:
|
||||
_pass_api = core_plugins_config.get_config('_pass_API').data
|
||||
if _pass_api:
|
||||
data = await self._ark_request(
|
||||
@ -68,8 +68,8 @@ class BaseArkApi:
|
||||
|
||||
return validate, ch
|
||||
|
||||
async def get_game_player_info(self, uid: str) -> int | ArknightsPlayerInfoModel:
|
||||
cred: str | None = await ArknightsUser.get_user_attr_by_uid(uid=uid, attr='cred')
|
||||
async def get_game_player_info(self, uid: str) -> Union[int, ArknightsPlayerInfoModel]:
|
||||
cred: Union[str, None] = await ArknightsUser.get_user_attr_by_uid(uid=uid, attr='cred')
|
||||
if cred is None:
|
||||
return -60
|
||||
is_vaild = await self.check_cred_valid(cred)
|
||||
@ -92,8 +92,8 @@ class BaseArkApi:
|
||||
else:
|
||||
return msgspec.convert(unpack_data, type=ArknightsPlayerInfoModel)
|
||||
|
||||
async def skd_sign(self, uid: str) -> int | ArknightsAttendanceModel:
|
||||
cred: str | None = await ArknightsUser.get_user_attr_by_uid(uid=uid, attr='cred')
|
||||
async def skd_sign(self, uid: str) -> Union[int, ArknightsAttendanceModel]:
|
||||
cred: Union[str, None] = await ArknightsUser.get_user_attr_by_uid(uid=uid, attr='cred')
|
||||
if cred is None:
|
||||
return -60
|
||||
is_vaild = await self.check_cred_valid(cred)
|
||||
@ -127,8 +127,8 @@ class BaseArkApi:
|
||||
else:
|
||||
return msgspec.convert(unpack_data, ArknightsAttendanceModel)
|
||||
|
||||
async def get_sign_info(self, uid: str) -> int | ArknightsAttendanceCalendarModel:
|
||||
cred: str | None = await ArknightsUser.get_user_attr_by_uid(uid=uid, attr='cred')
|
||||
async def get_sign_info(self, uid: str) -> Union[int, ArknightsAttendanceCalendarModel]:
|
||||
cred: Union[str, None] = await ArknightsUser.get_user_attr_by_uid(uid=uid, attr='cred')
|
||||
if cred is None:
|
||||
return -60
|
||||
is_vaild = await self.check_cred_valid(cred)
|
||||
@ -163,8 +163,8 @@ class BaseArkApi:
|
||||
return msgspec.convert(unpack_data, ArknightsAttendanceCalendarModel)
|
||||
|
||||
async def check_cred_valid(
|
||||
self, cred: str | None = None, token: str | None = None, uid: str | None = None
|
||||
) -> bool | ArknightsUserMeModel:
|
||||
self, cred: Union[str, None] = None, token: Union[str, None] = None, uid: Union[str, None] = None
|
||||
) -> Union[bool, ArknightsUserMeModel]:
|
||||
if uid is not None:
|
||||
cred = cred if cred else await ArknightsUser.get_user_attr_by_uid(uid=uid, attr='cred')
|
||||
header = deepcopy(_HEADER)
|
||||
@ -181,14 +181,14 @@ class BaseArkApi:
|
||||
unpack_data = self.unpack(raw_data)
|
||||
return msgspec.convert(unpack_data, type=ArknightsUserMeModel)
|
||||
|
||||
def unpack(self, raw_data: dict) -> dict:
|
||||
def unpack(self, raw_data: Dict) -> Dict:
|
||||
try:
|
||||
data = raw_data['data']
|
||||
return data
|
||||
except KeyError:
|
||||
return raw_data
|
||||
|
||||
async def refresh_token(self, cred: str, uid: str | None = None) -> str:
|
||||
async def refresh_token(self, cred: str, uid: Union[str, None] = None) -> str:
|
||||
header = deepcopy(_HEADER)
|
||||
header['cred'] = cred
|
||||
header['sign_enable'] = 'false'
|
||||
@ -205,11 +205,11 @@ class BaseArkApi:
|
||||
async def set_sign(
|
||||
self,
|
||||
url: str,
|
||||
header: dict[str, Any],
|
||||
data: dict[str, Any] | None = None,
|
||||
params: dict[str, Any] | None = None,
|
||||
token: str | None = None,
|
||||
) -> dict:
|
||||
header: Dict[str, Any],
|
||||
data: Union[Dict[str, Any], None ]= None,
|
||||
params: Union[Dict[str, Any], None] = None,
|
||||
token: Union[str, None] = None,
|
||||
) -> Dict:
|
||||
parsed_url = urlparse(url)
|
||||
path = parsed_url.path
|
||||
timestamp = str(int(time.time()) - 2)
|
||||
@ -249,11 +249,11 @@ class BaseArkApi:
|
||||
self,
|
||||
url: str,
|
||||
method: Literal['GET', 'POST'] = 'GET',
|
||||
header: dict[str, Any] = _HEADER,
|
||||
params: dict[str, Any] | None = None,
|
||||
data: dict[str, Any] | None = None,
|
||||
use_proxy: bool | None = False,
|
||||
) -> dict | int:
|
||||
header: Dict[str, Any] = _HEADER,
|
||||
params: Union[Dict[str, Any], None] = None,
|
||||
data: Union[Dict[str, Any], None] = None,
|
||||
use_proxy: Union[bool, None] = False,
|
||||
) -> Union[Dict, int]:
|
||||
logger.debug(f'{url} {method} {header} {params} {data} {use_proxy}')
|
||||
try:
|
||||
raw_data = await self._ark_request(
|
||||
@ -281,11 +281,11 @@ class BaseArkApi:
|
||||
self,
|
||||
url: str,
|
||||
method: Literal['GET', 'POST'] = 'GET',
|
||||
header: dict[str, Any] = _HEADER,
|
||||
params: dict[str, Any] | None = None,
|
||||
data: dict[str, Any] | None = None,
|
||||
use_proxy: bool | None = False,
|
||||
) -> dict | int:
|
||||
header: Dict[str, Any] = _HEADER,
|
||||
params: Union[Dict[str, Any], None ]= None,
|
||||
data: Union[Dict[str, Any], None] = None,
|
||||
use_proxy: Union[bool, None] = False,
|
||||
) -> Union[Dict, int]:
|
||||
async with ClientSession(
|
||||
connector=TCPConnector(verify_ssl=ssl_verify)
|
||||
) as client:
|
||||
|
@ -1,4 +1,4 @@
|
||||
from typing import Literal
|
||||
from typing import Dict, Literal, Union
|
||||
|
||||
from gsuid_core.utils.database.base_models import Bind, Push, T_BaseIDModel, T_User, User, with_session, BaseModel
|
||||
from gsuid_core.webconsole.mount_app import GsAdminModel, PageSchema, site
|
||||
@ -8,14 +8,14 @@ from sqlalchemy.ext.asyncio import AsyncSession
|
||||
|
||||
|
||||
class ArknightsBind(Bind, table=True):
|
||||
uid: str | None = Field(default=None, title='明日方舟UID')
|
||||
uid: Union[str, None] = Field(default=None, title='明日方舟UID')
|
||||
|
||||
|
||||
class ArknightsUser(User, table=True):
|
||||
uid: str | None = Field(default=None, title='明日方舟UID')
|
||||
skd_uid: str | None = Field(default=None, title='SKD用户ID')
|
||||
cred: str | None = Field(default=None, title='SKD凭证')
|
||||
token: str | None = Field(default=None, title='SKD Token')
|
||||
uid: Union[str, None] = Field(default=None, title='明日方舟UID')
|
||||
skd_uid: Union[str, None] = Field(default=None, title='SKD用户ID')
|
||||
cred: Union[str, None] = Field(default=None, title='SKD凭证')
|
||||
token: Union[str, None] = Field(default=None, title='SKD Token')
|
||||
|
||||
@classmethod
|
||||
@with_session
|
||||
@ -23,19 +23,19 @@ class ArknightsUser(User, table=True):
|
||||
cls,
|
||||
session: AsyncSession,
|
||||
cred: str
|
||||
) -> BaseModel | None:
|
||||
) -> Union[BaseModel, None]:
|
||||
sql= select(cls).where(cls.cred == cred)
|
||||
result = await session.execute(sql)
|
||||
data = result.scalars().all()
|
||||
return data[0] if data else None
|
||||
|
||||
@classmethod
|
||||
async def get_token_by_cred(cls, cred: str) -> str | None:
|
||||
async def get_token_by_cred(cls, cred: str) -> Union[str, None]:
|
||||
result = await cls.select_data_by_cred(cred)
|
||||
return getattr(result, 'token') if result else None
|
||||
|
||||
@classmethod
|
||||
async def get_uid_by_cred(cls, cred: str) -> str | None:
|
||||
async def get_uid_by_cred(cls, cred: str) -> Union[str, None]:
|
||||
result = await cls.select_data_by_cred(cred)
|
||||
return getattr(result, 'uid') if result else None
|
||||
|
||||
@ -55,14 +55,14 @@ class ArknightsUser(User, table=True):
|
||||
|
||||
|
||||
class ArknightsPush(Push, table=True):
|
||||
uid: str | None = Field(default=None, title='明日方舟UID')
|
||||
skd_uid: str | None = Field(default=None, title='森空岛用户ID')
|
||||
ap_push: bool | None = Field(default=False, title='理智推送')
|
||||
ap_value: int | None = Field(default=110, title='理智推送阈值')
|
||||
ap_is_push: bool | None = Field(default=False, title='理智是否已经推送')
|
||||
training_push: bool | None = Field(default=False, title='训练室推送')
|
||||
training_value: int | None = Field(default=30, title='训练室推送阈值')
|
||||
training_is_push: bool | None = Field(default=False, title='训练室是否已经推送')
|
||||
uid: Union[str, None] = Field(default=None, title='明日方舟UID')
|
||||
skd_uid: Union[str, None] = Field(default=None, title='森空岛用户ID')
|
||||
ap_push: Union[bool, None] = Field(default=False, title='理智推送')
|
||||
ap_value: Union[int, None] = Field(default=110, title='理智推送阈值')
|
||||
ap_is_push: Union[bool, None] = Field(default=False, title='理智是否已经推送')
|
||||
training_push: Union[bool, None] = Field(default=False, title='训练室推送')
|
||||
training_value: Union[int, None] = Field(default=30, title='训练室推送阈值')
|
||||
training_is_push: Union[bool, None] = Field(default=False, title='训练室是否已经推送')
|
||||
|
||||
@classmethod
|
||||
async def insert_push_data(cls, uid: str, skd_uid: str):
|
||||
@ -79,7 +79,7 @@ class ArknightsPush(Push, table=True):
|
||||
)
|
||||
|
||||
@classmethod
|
||||
async def update_push_data(cls, uid: str, data: dict) -> bool:
|
||||
async def update_push_data(cls, uid: str, data: Dict) -> bool:
|
||||
retcode = -1
|
||||
if await cls.data_exist(uid=uid):
|
||||
retcode = await cls.update_data_by_uid(
|
||||
@ -99,7 +99,7 @@ class ArknightsPush(Push, table=True):
|
||||
@classmethod
|
||||
async def select_push_data(
|
||||
cls: type[T_BaseIDModel], uid: str
|
||||
) -> T_BaseIDModel | None:
|
||||
) -> Union[T_BaseIDModel, None]:
|
||||
return await cls.base_select_data(uid=uid)
|
||||
|
||||
@classmethod
|
||||
|
@ -1,6 +1,9 @@
|
||||
from typing import Union
|
||||
|
||||
|
||||
UID_HINT = '添加失败, 请先绑定明日方舟UID'
|
||||
|
||||
def get_error(retcode: int | str) -> str:
|
||||
def get_error(retcode: Union[int, str]) -> str:
|
||||
if retcode == 10000:
|
||||
return '请求异常, 请检查具体实现代码...'
|
||||
if retcode == 10001:
|
||||
|
@ -1,10 +1,11 @@
|
||||
import json
|
||||
from pathlib import Path
|
||||
from typing import Dict
|
||||
|
||||
from loguru import logger
|
||||
|
||||
|
||||
def read_json(file_path: Path, **kwargs) -> dict:
|
||||
def read_json(file_path: Path, **kwargs) -> Dict:
|
||||
"""
|
||||
Read a JSON file and return its contents as a dictionary.
|
||||
"""
|
||||
@ -16,7 +17,7 @@ def read_json(file_path: Path, **kwargs) -> dict:
|
||||
return {}
|
||||
|
||||
|
||||
def write_json(data: dict, file_path: Path) -> None:
|
||||
def write_json(data: Dict, file_path: Path) -> None:
|
||||
"""
|
||||
Write a dictionary to a JSON file.
|
||||
"""
|
||||
|
@ -1,4 +1,5 @@
|
||||
from pathlib import Path
|
||||
from typing import Union
|
||||
|
||||
from gsuid_core.utils.image.image_tools import CustomizeImage
|
||||
from PIL import Image
|
||||
@ -9,7 +10,7 @@ SP_BG_PATH = BG_PATH / 'sp_bg'
|
||||
|
||||
|
||||
async def get_simple_bg(
|
||||
based_w: int, based_h: int, image: str | None | Image.Image = None
|
||||
based_w: int, based_h: int, image: Union[str, Union[None, Image.Image]] = None
|
||||
) -> Image.Image:
|
||||
CIL = CustomizeImage(NM_BG_PATH)
|
||||
return CIL.get_image(image, based_w, based_h)
|
||||
|
@ -1,9 +1,9 @@
|
||||
from typing import Any
|
||||
from typing import Any, Dict, Union
|
||||
|
||||
from gsuid_core.bot import Bot
|
||||
|
||||
|
||||
async def send_diff_msg(bot: Bot, code: Any, data: dict | None = None):
|
||||
async def send_diff_msg(bot: Bot, code: Any, data: Union[Dict, None] = None):
|
||||
if data is None:
|
||||
data = {
|
||||
0: '绑定UID成功!',
|
||||
|
126
ArknightsUID/utils/models/common.py
Normal file
126
ArknightsUID/utils/models/common.py
Normal file
@ -0,0 +1,126 @@
|
||||
import base64
|
||||
import json
|
||||
from collections.abc import Callable, Iterable, Iterator
|
||||
from copy import copy, deepcopy
|
||||
from typing import Any, Dict, List, Tuple, TypeVar, Union
|
||||
|
||||
from msgspec import Meta, Struct, UnsetType, convert, field
|
||||
from msgspec import json as mscjson
|
||||
from typing_extensions import dataclass_transform
|
||||
|
||||
Model = TypeVar('Model', bound='BaseStruct')
|
||||
T = TypeVar("T")
|
||||
|
||||
|
||||
def transUnset(v: Union[T, UnsetType], d: Any = None) -> Union[T, Any]:
|
||||
return v if not isinstance(v, UnsetType) else d
|
||||
|
||||
|
||||
@dataclass_transform(field_specifiers=(field,))
|
||||
class BaseStruct(Struct, forbid_unknown_fields=True, omit_defaults=True, gc=False):
|
||||
class Config:
|
||||
encoder = mscjson.Encoder()
|
||||
|
||||
@classmethod
|
||||
def json_schema(cls) -> str:
|
||||
return (
|
||||
f"```json\n{json.dumps(mscjson.schema(cls), ensure_ascii=False, indent=2)}"
|
||||
)
|
||||
|
||||
@classmethod
|
||||
def convert(
|
||||
cls: type[Model],
|
||||
obj: Any,
|
||||
*,
|
||||
strict: bool = True,
|
||||
from_attributes: bool = False,
|
||||
dec_hook: Union[Callable[[type, Any], Any], None] = None,
|
||||
builtin_types: Union[Iterable[type], None] = None,
|
||||
str_keys: bool = False,
|
||||
) -> Model:
|
||||
return convert(
|
||||
obj=obj,
|
||||
type=cls,
|
||||
strict=strict,
|
||||
from_attributes=from_attributes,
|
||||
dec_hook=dec_hook,
|
||||
builtin_types=builtin_types,
|
||||
str_keys=str_keys
|
||||
)
|
||||
|
||||
def __post_init__(
|
||||
self,
|
||||
validate_whitespace: Union[List[str], None] = None,
|
||||
validate_num_with_range: Union[List[Tuple[str, Meta]], None] = None,
|
||||
validate_optional: Union[List[Tuple[str, Meta]], None] = None,
|
||||
validate_int: Union[List[str], None] = None,
|
||||
validate_base64: Union[List[str], None] = None,
|
||||
) -> None:
|
||||
if validate_base64 is None:
|
||||
validate_base64 = []
|
||||
if validate_int is None:
|
||||
validate_int = []
|
||||
if validate_optional is None:
|
||||
validate_optional = []
|
||||
if validate_num_with_range is None:
|
||||
validate_num_with_range = []
|
||||
if validate_whitespace is None:
|
||||
validate_whitespace = []
|
||||
for field_name in validate_whitespace:
|
||||
if (field_value := getattr(self, field_name)) is not None:
|
||||
if isinstance(field_value, str) and not field_value.strip():
|
||||
raise ValueError(
|
||||
f'child "{field_name}" fails because ["{field_name}" is not allowed to be empty]'
|
||||
)
|
||||
|
||||
for field_group in validate_num_with_range:
|
||||
if (field_value := getattr(self, field_group[0])) is not None:
|
||||
if field_value > (le := field_group[1].le or field_value):
|
||||
raise ValueError(f'"{field_group[0]}" must be less than {le}')
|
||||
if field_value < (ge := field_group[1].ge or field_value):
|
||||
raise ValueError(f'"{field_group[0]}" must be greater than {ge}')
|
||||
|
||||
for field_group in validate_optional:
|
||||
if (field_value := getattr(self, field_group[0])) is not None:
|
||||
if field_value not in field_group[1].examples:
|
||||
raise ValueError(
|
||||
f'"{field_group[0]}" must be one of {field_group[1]}'
|
||||
)
|
||||
|
||||
for field_name in validate_int:
|
||||
if (field_value := getattr(self, field_name)) is not None:
|
||||
if not field_value.isdigit():
|
||||
raise ValueError(
|
||||
f'child "{field_name}" fails because ["{field_name}" must be a number]'
|
||||
)
|
||||
|
||||
for field_name in validate_base64:
|
||||
try:
|
||||
base64.b64decode(getattr(self, field_name))
|
||||
except Exception as e:
|
||||
raise ValueError(
|
||||
f'child "{field_name}" fails because ["{field_name}" must be a valid base64 string]'
|
||||
) from e
|
||||
|
||||
def __iter__(self) -> Iterator[Tuple[str, Any]]:
|
||||
for field_name in self.__struct_fields__:
|
||||
yield field_name, getattr(self, field_name)
|
||||
|
||||
def __getattribute__(self, __name: str) -> Union[Any, None]:
|
||||
value = super().__getattribute__(__name)
|
||||
if isinstance(value, UnsetType):
|
||||
return None
|
||||
return value
|
||||
|
||||
def keys(self) -> Iterator[str]:
|
||||
yield from self.__struct_fields__
|
||||
|
||||
def values(self) -> Iterator[Any]:
|
||||
for field_name in self.__struct_fields__:
|
||||
yield getattr(self, field_name)
|
||||
|
||||
def model_dump(self) -> Dict[str, Any]:
|
||||
return mscjson.decode(mscjson.encode(self))
|
||||
|
||||
def model_copy(self: Model, *, deep: bool = False) -> Model:
|
||||
return deepcopy(self) if deep else copy(self)
|
File diff suppressed because it is too large
Load Diff
@ -1,19 +1,18 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class Bank(BaseModel):
|
||||
class BGMBank(BaseStruct):
|
||||
name: str
|
||||
|
||||
|
||||
class BGMBank(Bank):
|
||||
intro: str | None
|
||||
loop: str | None
|
||||
intro: Union[str, None]
|
||||
loop: Union[str, None]
|
||||
volume: float
|
||||
crossfade: float
|
||||
delay: float
|
||||
|
||||
|
||||
class SoundFXBankSoundFX(BaseModel):
|
||||
class SoundFXBankSoundFX(BaseStruct):
|
||||
asset: str
|
||||
weight: float
|
||||
important: bool
|
||||
@ -26,30 +25,32 @@ class SoundFXBankSoundFX(BaseModel):
|
||||
ignoreTimeScale: bool
|
||||
|
||||
|
||||
class SoundFXBank(Bank):
|
||||
sounds: list[SoundFXBankSoundFX] | None
|
||||
class SoundFXBank(BaseStruct):
|
||||
name: str
|
||||
sounds: Union[List[SoundFXBankSoundFX], None]
|
||||
maxSoundAllowed: int
|
||||
popOldest: bool
|
||||
customMixerGroup: str | None
|
||||
customMixerGroup: Union[str, None]
|
||||
loop: bool
|
||||
|
||||
|
||||
class SoundFXCtrlBank(Bank):
|
||||
class SoundFXCtrlBank(BaseStruct):
|
||||
name: str
|
||||
targetBank: str
|
||||
ctrlStop: bool
|
||||
ctrlStopFadetime: float
|
||||
|
||||
|
||||
class SnapshotBank(BaseStruct):
|
||||
name: str
|
||||
|
||||
|
||||
class SnapshotBank(Bank):
|
||||
targetSnapshot: str
|
||||
hookSoundFxBank: str
|
||||
delay: float
|
||||
duration: float
|
||||
targetFxBank: Bank | None = None
|
||||
targetFxBank: Union[str, None] = None
|
||||
|
||||
|
||||
class BattleVoiceOption(BaseModel):
|
||||
class BattleVoiceOption(BaseStruct):
|
||||
voiceType: int
|
||||
priority: int
|
||||
overlapIfSamePriority: bool
|
||||
@ -57,30 +58,27 @@ class BattleVoiceOption(BaseModel):
|
||||
delay: float
|
||||
|
||||
|
||||
class MusicData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class MusicData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
name: str
|
||||
bank: str
|
||||
|
||||
|
||||
class BattleVoiceData(BaseModel):
|
||||
class BattleVoiceData(BaseStruct):
|
||||
crossfade: float
|
||||
minTimeDeltaForEnemyEncounter: float
|
||||
minSpCostForImportantPassiveSkill: int
|
||||
voiceTypeOptions: list[BattleVoiceOption]
|
||||
voiceTypeOptions: List[BattleVoiceOption]
|
||||
|
||||
|
||||
class AudioData(BaseModel):
|
||||
class AudioData(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
bgmBanks: list[BGMBank]
|
||||
soundFXBanks: list[SoundFXBank]
|
||||
soundFXCtrlBanks: list[SoundFXCtrlBank]
|
||||
snapshotBanks: list[SnapshotBank]
|
||||
bgmBanks: List[BGMBank]
|
||||
soundFXBanks: List[SoundFXBank]
|
||||
soundFXCtrlBanks: List[SoundFXCtrlBank]
|
||||
snapshotBanks: List[SnapshotBank]
|
||||
battleVoice: BattleVoiceData
|
||||
musics: list[MusicData]
|
||||
soundFxVoiceLang: dict[str, dict[str, dict[str, str]]]
|
||||
bankAlias: dict[str, str]
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
musics: List[MusicData]
|
||||
soundFxVoiceLang: Dict[str, Dict[str, Dict[str, str]]]
|
||||
bankAlias: Dict[str, str]
|
||||
|
@ -1,80 +1,82 @@
|
||||
from pydantic import BaseModel
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
|
||||
|
||||
class CharacterDataUnlockCondition(BaseModel):
|
||||
class CharacterDataUnlockCondition(BaseStruct):
|
||||
phase: int
|
||||
level: int
|
||||
|
||||
|
||||
class Blackboard(BaseModel):
|
||||
class Blackboard(BaseStruct):
|
||||
key: str
|
||||
value: float | None = None
|
||||
valueStr: str | None = None
|
||||
value: Union[float, None] = None
|
||||
valueStr: Union[str, None] = None
|
||||
|
||||
|
||||
class TalentData(BaseModel):
|
||||
class TalentData(BaseStruct):
|
||||
unlockCondition: CharacterDataUnlockCondition
|
||||
requiredPotentialRank: int
|
||||
prefabKey: str | None
|
||||
name: str | None
|
||||
description: str | None
|
||||
rangeId: str | None
|
||||
blackboard: list[Blackboard]
|
||||
prefabKey: Union[str, None]
|
||||
name: Union[str, None]
|
||||
description: Union[str, None]
|
||||
rangeId: Union[str, None]
|
||||
blackboard: List[Blackboard]
|
||||
|
||||
|
||||
class EquipTalentData(TalentData):
|
||||
displayRangeId: bool
|
||||
upgradeDescription: str
|
||||
talentIndex: int
|
||||
tokenKey: Union[str, None] = None
|
||||
|
||||
|
||||
class CharacterDataEquipTalentDataBundle(BaseModel):
|
||||
candidates: list[EquipTalentData] | None
|
||||
class CharacterDataEquipTalentDataBundle(BaseStruct):
|
||||
candidates: Union[List[EquipTalentData], None]
|
||||
|
||||
|
||||
class CharacterDataTraitData(BaseModel):
|
||||
class CharacterDataTraitData(BaseStruct):
|
||||
unlockCondition: CharacterDataUnlockCondition
|
||||
requiredPotentialRank: int
|
||||
blackboard: list[Blackboard]
|
||||
overrideDescripton: str | None
|
||||
prefabKey: str | None
|
||||
rangeId: str | None
|
||||
blackboard: List[Blackboard]
|
||||
overrideDescripton: Union[str, None]
|
||||
prefabKey: Union[str, None]
|
||||
rangeId: Union[str, None]
|
||||
|
||||
|
||||
class CharacterDataEquipTraitData(BaseModel):
|
||||
additionalDescription: str | None
|
||||
class CharacterDataEquipTraitData(BaseStruct):
|
||||
additionalDescription: Union[str, None]
|
||||
unlockCondition: CharacterDataUnlockCondition
|
||||
requiredPotentialRank: int
|
||||
blackboard: List[Blackboard]
|
||||
overrideDescripton: Union[str, None]
|
||||
prefabKey: Union[str, None]
|
||||
rangeId: Union[str, None]
|
||||
|
||||
|
||||
class CharacterDataEquipTraitDataBundle(BaseModel):
|
||||
candidates: list[CharacterDataEquipTraitData] | None
|
||||
class CharacterDataEquipTraitDataBundle(BaseStruct):
|
||||
candidates: Union[List[CharacterDataEquipTraitData], None]
|
||||
|
||||
|
||||
class BattleUniEquipData(BaseModel):
|
||||
resKey: str | None
|
||||
class BattleUniEquipData(BaseStruct):
|
||||
resKey: Union[str, None]
|
||||
target: str
|
||||
isToken: bool
|
||||
addOrOverrideTalentDataBundle: CharacterDataEquipTalentDataBundle
|
||||
overrideTraitDataBundle: CharacterDataEquipTraitDataBundle
|
||||
|
||||
|
||||
class BattleEquipPerLevelPack(BaseModel):
|
||||
class BattleEquipPerLevelPack(BaseStruct):
|
||||
equipLevel: int
|
||||
parts: list[BattleUniEquipData]
|
||||
attributeBlackboard: list[Blackboard]
|
||||
tokenAttributeBlackboard: dict[str, list[Blackboard]]
|
||||
parts: List[BattleUniEquipData]
|
||||
attributeBlackboard: List[Blackboard]
|
||||
tokenAttributeBlackboard: Dict[str, List[Blackboard]]
|
||||
|
||||
|
||||
class BattleEquipData(BaseModel):
|
||||
phases: list[BattleEquipPerLevelPack]
|
||||
class BattleEquipData(BaseStruct):
|
||||
phases: List[BattleEquipPerLevelPack]
|
||||
|
||||
|
||||
class BattleEquipTable(BaseModel):
|
||||
class BattleEquipTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
equips: dict[str, BattleEquipData]
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
|
||||
def __init__(self, data: dict) -> None:
|
||||
super().__init__(equips=data)
|
||||
equips: Dict[str, BattleEquipData]
|
||||
|
@ -1,37 +1,39 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class BuildingDataRoomUnlockCondCondItem(BaseModel):
|
||||
type_: str = Field(alias='type')
|
||||
class BuildingDataRoomUnlockCondCondItem(BaseStruct):
|
||||
type_: str = field(name='type')
|
||||
level: int
|
||||
count: int
|
||||
|
||||
|
||||
class BuildingDataRoomUnlockCond(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
number: dict[str, BuildingDataRoomUnlockCondCondItem]
|
||||
class BuildingDataRoomUnlockCond(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
number: Dict[str, BuildingDataRoomUnlockCondCondItem]
|
||||
|
||||
|
||||
class GridPosition(BaseModel):
|
||||
class GridPosition(BaseStruct):
|
||||
row: int
|
||||
col: int
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class BuildingDataRoomDataBuildCost(BaseModel):
|
||||
items: list[ItemBundle]
|
||||
class BuildingDataRoomDataBuildCost(BaseStruct):
|
||||
items: List[ItemBundle]
|
||||
time: int
|
||||
labor: int
|
||||
|
||||
|
||||
class BuildingDataRoomDataPhaseData(BaseModel):
|
||||
overrideName: str | None
|
||||
overridePrefabId: str | None
|
||||
class BuildingDataRoomDataPhaseData(BaseStruct):
|
||||
overrideName: Union[str, None]
|
||||
overridePrefabId: Union[str, None]
|
||||
unlockCondId: str
|
||||
buildCost: BuildingDataRoomDataBuildCost
|
||||
electricity: int
|
||||
@ -39,20 +41,20 @@ class BuildingDataRoomDataPhaseData(BaseModel):
|
||||
manpowerCost: int
|
||||
|
||||
|
||||
class BuildingDataRoomData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class BuildingDataRoomData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
name: str
|
||||
description: str | None
|
||||
description: Union[str, None]
|
||||
defaultPrefabId: str
|
||||
canLevelDown: bool
|
||||
maxCount: int
|
||||
category: str
|
||||
size: GridPosition
|
||||
phases: list[BuildingDataRoomDataPhaseData]
|
||||
phases: List[BuildingDataRoomDataPhaseData]
|
||||
|
||||
|
||||
class BuildingDataLayoutDataRoomSlot(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class BuildingDataLayoutDataRoomSlot(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
cleanCostId: str
|
||||
costLabor: int
|
||||
provideLabor: int
|
||||
@ -62,133 +64,149 @@ class BuildingDataLayoutDataRoomSlot(BaseModel):
|
||||
storeyId: str
|
||||
|
||||
|
||||
class BuildingDataLayoutDataSlotCleanCostCountCost(BaseModel):
|
||||
items: list[ItemBundle]
|
||||
class BuildingDataLayoutDataSlotCleanCostCountCost(BaseStruct):
|
||||
items: List[ItemBundle]
|
||||
|
||||
|
||||
class BuildingDataLayoutDataSlotCleanCost(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
number: dict[str, BuildingDataLayoutDataSlotCleanCostCountCost]
|
||||
class BuildingDataLayoutDataSlotCleanCost(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
number: Dict[str, BuildingDataLayoutDataSlotCleanCostCountCost]
|
||||
|
||||
|
||||
class BuildingDataLayoutDataStoreyData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class BuildingDataLayoutDataStoreyData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
yOffset: int
|
||||
unlockControlLevel: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class BuildingDataLayoutData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
slots: dict[str, BuildingDataLayoutDataRoomSlot]
|
||||
cleanCosts: dict[str, BuildingDataLayoutDataSlotCleanCost]
|
||||
storeys: dict[str, BuildingDataLayoutDataStoreyData]
|
||||
class BuildingDataLayoutData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
slots: Dict[str, BuildingDataLayoutDataRoomSlot]
|
||||
cleanCosts: Dict[str, BuildingDataLayoutDataSlotCleanCost]
|
||||
storeys: Dict[str, BuildingDataLayoutDataStoreyData]
|
||||
|
||||
|
||||
class BuildingDataPrefabInfo(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
blueprintRoomOverrideId: str | None
|
||||
class BuildingDataPrefabInfo(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
blueprintRoomOverrideId: Union[str, None]
|
||||
size: GridPosition
|
||||
floorGridSize: GridPosition
|
||||
backWallGridSize: GridPosition
|
||||
obstacleId: str | None
|
||||
obstacleId: Union[str, None]
|
||||
|
||||
|
||||
class BuildingDataManufactPhase(BaseModel):
|
||||
speed: float | int
|
||||
class BuildingDataManufactPhase(BaseStruct, tag='BuildingDataManufactPhase'):
|
||||
speed: Union[float, int]
|
||||
outputCapacity: int
|
||||
|
||||
|
||||
class BuildingDataShopPhase(BaseModel):
|
||||
class BuildingDataShopPhase(BaseStruct, tag='BuildingDataShopPhase'):
|
||||
counterNum: int
|
||||
speed: float | int
|
||||
speed: Union[float, int]
|
||||
moneyCapacity: int
|
||||
|
||||
|
||||
class BuildingDataHirePhase(BaseModel):
|
||||
class BuildingDataHirePhase(BaseStruct, tag='BuildingDataHirePhase'):
|
||||
economizeRate: float
|
||||
resSpeed: int
|
||||
refreshTimes: int
|
||||
|
||||
|
||||
class BuildingDataDormPhase(BaseModel):
|
||||
class BuildingDataDormPhase(BaseStruct, tag='BuildingDataDormPhase'):
|
||||
manpowerRecover: int
|
||||
decorationLimit: int
|
||||
|
||||
|
||||
class BuildingDataMeetingPhase(BaseModel):
|
||||
class BuildingDataMeetingPhase(BaseStruct, tag='BuildingDataMeetingPhase'):
|
||||
friendSlotInc: int
|
||||
maxVisitorNum: int
|
||||
gatheringSpeed: int
|
||||
|
||||
|
||||
class BuildingDataTradingPhase(BaseModel):
|
||||
orderSpeed: float | int
|
||||
class BuildingDataTradingPhase(BaseStruct, tag='BuildingDataTradingPhase'):
|
||||
orderSpeed: Union[float, int]
|
||||
orderLimit: int
|
||||
orderRarity: int
|
||||
|
||||
|
||||
class BuildingDataWorkshopPhase(BaseModel):
|
||||
manpowerFactor: float | int
|
||||
class BuildingDataWorkshopPhase(BaseStruct, tag='BuildingDataWorkshopPhase'):
|
||||
manpowerFactor: Union[float, int]
|
||||
|
||||
|
||||
class BuildingDataTrainingPhase(BaseModel):
|
||||
class BuildingDataTrainingPhase(BaseStruct, tag='BuildingDataTrainingPhase'):
|
||||
specSkillLvlLimit: int
|
||||
|
||||
|
||||
class BuildingDataRoomBean(BaseModel):
|
||||
phases: list[BuildingDataManufactPhase | BuildingDataShopPhase | BuildingDataHirePhase | BuildingDataDormPhase | BuildingDataMeetingPhase | BuildingDataTradingPhase | BuildingDataWorkshopPhase | BuildingDataTrainingPhase] | None # noqa: E501
|
||||
class BuildingDataShopRoomBean(BaseStruct):
|
||||
phases: None = None
|
||||
# phases: Union[List[Union[Union[Union[Union[Union[Union[Union[BuildingDataManufactPhase, BuildingDataShopPhase], BuildingDataHirePhase], BuildingDataDormPhase], BuildingDataMeetingPhase], BuildingDataTradingPhase], BuildingDataWorkshopPhase], BuildingDataTrainingPhase]], None] # noqa: E501
|
||||
|
||||
|
||||
class BuildingDataControlRoomBean(BuildingDataRoomBean):
|
||||
class BuildingDataControlRoomBean(BaseStruct):
|
||||
basicCostBuff: int
|
||||
phases: None = None
|
||||
|
||||
|
||||
class BuildingDataManufactRoomBean(BuildingDataRoomBean):
|
||||
class BuildingDataManufactRoomBean(BaseStruct):
|
||||
basicSpeedBuff: float
|
||||
phases: List[BuildingDataManufactPhase]
|
||||
|
||||
|
||||
class BuildingDataHireRoomBean(BuildingDataRoomBean):
|
||||
class BuildingDataHireRoomBean(BaseStruct):
|
||||
basicSpeedBuff: float
|
||||
phases: List[BuildingDataHirePhase]
|
||||
|
||||
|
||||
class BuildingDataMeetingRoomBean(BuildingDataRoomBean):
|
||||
class BuildingDataDormRoomBean(BaseStruct):
|
||||
phases: List[BuildingDataDormPhase]
|
||||
|
||||
|
||||
class BuildingDataMeetingRoomBean(BaseStruct):
|
||||
basicSpeedBuff: float
|
||||
phases: List[BuildingDataMeetingPhase]
|
||||
|
||||
|
||||
class BuildingDataTradingRoomBean(BuildingDataRoomBean):
|
||||
class BuildingDataTradingRoomBean(BaseStruct):
|
||||
basicSpeedBuff: float
|
||||
phases: List[BuildingDataTradingPhase]
|
||||
|
||||
|
||||
class BuildingDataTrainingBean(BuildingDataRoomBean):
|
||||
class BuildingDataWorkShopRoomBean(BaseStruct):
|
||||
phases: List[BuildingDataWorkshopPhase]
|
||||
|
||||
|
||||
class BuildingDataTrainingBean(BaseStruct):
|
||||
basicSpeedBuff: float
|
||||
phases: List[BuildingDataTrainingPhase]
|
||||
|
||||
|
||||
class BuildingDataPowerRoomBean(BuildingDataRoomBean):
|
||||
class BuildingDataPowerRoomBean(BaseStruct):
|
||||
basicSpeedBuff: float
|
||||
phases: None = None
|
||||
|
||||
|
||||
class CharacterDataUnlockCondition(BaseModel):
|
||||
class CharacterDataUnlockCondition(BaseStruct):
|
||||
phase: int
|
||||
level: int
|
||||
|
||||
|
||||
class BuildingDataBuildingBuffCharSlotSlotItem(BaseModel):
|
||||
class BuildingDataBuildingBuffCharSlotSlotItem(BaseStruct):
|
||||
buffId: str
|
||||
cond: CharacterDataUnlockCondition
|
||||
|
||||
|
||||
class BuildingDataBuildingBuffCharSlot(BaseModel):
|
||||
buffData: list[BuildingDataBuildingBuffCharSlotSlotItem]
|
||||
class BuildingDataBuildingBuffCharSlot(BaseStruct):
|
||||
buffData: List[BuildingDataBuildingBuffCharSlotSlotItem]
|
||||
|
||||
|
||||
class BuildingDataBuildingCharacter(BaseModel):
|
||||
class BuildingDataBuildingCharacter(BaseStruct):
|
||||
charId: str
|
||||
maxManpower: int
|
||||
buffChar: list[BuildingDataBuildingBuffCharSlot]
|
||||
buffChar: List[BuildingDataBuildingBuffCharSlot]
|
||||
|
||||
|
||||
class BuildingDataBuildingBuff(BaseModel):
|
||||
class BuildingDataBuildingBuff(BaseStruct):
|
||||
buffId: str
|
||||
buffName: str
|
||||
buffIcon: str
|
||||
@ -201,13 +219,12 @@ class BuildingDataBuildingBuff(BaseModel):
|
||||
description: str
|
||||
|
||||
|
||||
class BuildingDataCustomDataFurnitureData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class BuildingDataCustomDataFurnitureData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
sortId: int
|
||||
name: str
|
||||
iconId: str
|
||||
interactType: str | None = None
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
subType: str
|
||||
location: str
|
||||
category: str
|
||||
@ -226,101 +243,102 @@ class BuildingDataCustomDataFurnitureData(BaseModel):
|
||||
processedProductId: str
|
||||
processedProductCount: int
|
||||
processedByProductPercentage: int
|
||||
processedByProductGroup: list
|
||||
processedByProductGroup: List
|
||||
canBeDestroy: bool
|
||||
isOnly: int
|
||||
quantity: int
|
||||
interactType: Union[str, None] = None
|
||||
|
||||
|
||||
class BuildingDataCustomDataThemeQuickSetupItem(BaseModel):
|
||||
class BuildingDataCustomDataThemeQuickSetupItem(BaseStruct):
|
||||
furnitureId: str
|
||||
pos0: int
|
||||
pos1: int
|
||||
dir_: int = Field(alias='dir')
|
||||
dir_: int = field(name='dir')
|
||||
|
||||
|
||||
class BuildingDataCustomDataThemeData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class BuildingDataCustomDataThemeData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
sortId: int
|
||||
name: str
|
||||
themeType: str
|
||||
desc: str
|
||||
quickSetup: list[BuildingDataCustomDataThemeQuickSetupItem]
|
||||
groups: list[str]
|
||||
furnitures: list[str]
|
||||
quickSetup: List[BuildingDataCustomDataThemeQuickSetupItem]
|
||||
groups: List[str]
|
||||
furnitures: List[str]
|
||||
|
||||
|
||||
class BuildingDataCustomDataGroupData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class BuildingDataCustomDataGroupData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
sortId: int
|
||||
name: str
|
||||
themeId: str
|
||||
comfort: int
|
||||
count: int
|
||||
furniture: list[str]
|
||||
furniture: List[str]
|
||||
|
||||
|
||||
class BuildingDataCustomDataFurnitureTypeData(BaseModel):
|
||||
type_: str = Field(alias='type')
|
||||
class BuildingDataCustomDataFurnitureTypeData(BaseStruct):
|
||||
type_: str = field(name='type')
|
||||
name: str
|
||||
|
||||
|
||||
class BuildingDataCustomDataFurnitureSubTypeData(BaseModel):
|
||||
class BuildingDataCustomDataFurnitureSubTypeData(BaseStruct):
|
||||
subType: str
|
||||
name: str
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
sortId: int
|
||||
|
||||
|
||||
class BuildingDataCustomDataDormitoryDefaultFurnitureItem(BaseModel):
|
||||
class BuildingDataCustomDataDormitoryDefaultFurnitureItem(BaseStruct):
|
||||
furnitureId: str
|
||||
xOffset: int
|
||||
yOffset: int
|
||||
defaultPrefabId: str
|
||||
|
||||
|
||||
class BuildingDataCustomDataInteractItem(BaseModel):
|
||||
class BuildingDataCustomDataInteractItem(BaseStruct):
|
||||
skinId: str
|
||||
|
||||
|
||||
class BuildingDataCustomDataDiyUISortTemplateListDataDiyUISortTemplateData(BaseModel):
|
||||
class BuildingDataCustomDataDiyUISortTemplateListDataDiyUISortTemplateData(BaseStruct):
|
||||
name: str
|
||||
sequences: list[str]
|
||||
sequences: List[str]
|
||||
stableSequence: str
|
||||
stableSequenceOrder: str
|
||||
|
||||
|
||||
class BuildingDataCustomDataDiyUISortTemplateListData(BaseModel):
|
||||
class BuildingDataCustomDataDiyUISortTemplateListData(BaseStruct):
|
||||
diyUIType: str
|
||||
expandState: str
|
||||
defaultTemplateIndex: int
|
||||
defaultTemplateOrder: str
|
||||
templates: list[BuildingDataCustomDataDiyUISortTemplateListDataDiyUISortTemplateData]
|
||||
templates: List[BuildingDataCustomDataDiyUISortTemplateListDataDiyUISortTemplateData]
|
||||
|
||||
|
||||
class BuildingDataCustomData(BaseModel):
|
||||
furnitures: dict[str, BuildingDataCustomDataFurnitureData]
|
||||
themes: dict[str, BuildingDataCustomDataThemeData]
|
||||
groups: dict[str, BuildingDataCustomDataGroupData]
|
||||
types: dict[str, BuildingDataCustomDataFurnitureTypeData]
|
||||
subTypes: dict[str, BuildingDataCustomDataFurnitureSubTypeData]
|
||||
defaultFurnitures: dict[str, list[BuildingDataCustomDataDormitoryDefaultFurnitureItem]]
|
||||
interactGroups: dict[str, list[BuildingDataCustomDataInteractItem]]
|
||||
diyUISortTemplates: dict[str, dict[str, BuildingDataCustomDataDiyUISortTemplateListData]]
|
||||
class BuildingDataCustomData(BaseStruct):
|
||||
furnitures: Dict[str, BuildingDataCustomDataFurnitureData]
|
||||
themes: Dict[str, BuildingDataCustomDataThemeData]
|
||||
groups: Dict[str, BuildingDataCustomDataGroupData]
|
||||
types: Dict[str, BuildingDataCustomDataFurnitureTypeData]
|
||||
subTypes: Dict[str, BuildingDataCustomDataFurnitureSubTypeData]
|
||||
defaultFurnitures: Dict[str, List[BuildingDataCustomDataDormitoryDefaultFurnitureItem]]
|
||||
interactGroups: Dict[str, List[BuildingDataCustomDataInteractItem]]
|
||||
diyUISortTemplates: Dict[str, Dict[str, BuildingDataCustomDataDiyUISortTemplateListData]]
|
||||
|
||||
|
||||
class BuildingDataManufactFormulaUnlockRoom(BaseModel):
|
||||
class BuildingDataManufactFormulaUnlockRoom(BaseStruct):
|
||||
roomId: str
|
||||
roomLevel: int
|
||||
roomCount: int
|
||||
|
||||
|
||||
class BuildingDataManufactFormulaUnlockStage(BaseModel):
|
||||
class BuildingDataManufactFormulaUnlockStage(BaseStruct):
|
||||
stageId: str
|
||||
rank: int
|
||||
|
||||
|
||||
class BuildingDataManufactFormula(BaseModel):
|
||||
class BuildingDataManufactFormula(BaseStruct):
|
||||
formulaId: str
|
||||
itemId: str
|
||||
count: int
|
||||
@ -328,43 +346,43 @@ class BuildingDataManufactFormula(BaseModel):
|
||||
costPoint: int
|
||||
formulaType: str
|
||||
buffType: str
|
||||
costs: list[ItemBundle]
|
||||
requireRooms: list[BuildingDataManufactFormulaUnlockRoom]
|
||||
requireStages: list[BuildingDataManufactFormulaUnlockStage]
|
||||
costs: List[ItemBundle]
|
||||
requireRooms: List[BuildingDataManufactFormulaUnlockRoom]
|
||||
requireStages: List[BuildingDataManufactFormulaUnlockStage]
|
||||
|
||||
|
||||
class BuildingDataShopFormulaUnlockRoom(BaseModel):
|
||||
class BuildingDataShopFormulaUnlockRoom(BaseStruct):
|
||||
roomId: str
|
||||
roomLevel: int
|
||||
|
||||
|
||||
class BuildingDataShopFormula(BaseModel):
|
||||
class BuildingDataShopFormula(BaseStruct):
|
||||
formulaId: str
|
||||
itemId: str
|
||||
formulaType: str
|
||||
costPoint: int
|
||||
gainItem: ItemBundle
|
||||
requireRooms: list[BuildingDataShopFormulaUnlockRoom]
|
||||
requireRooms: List[BuildingDataShopFormulaUnlockRoom]
|
||||
|
||||
|
||||
class BuildingDataWorkshopExtraWeightItem(BaseModel):
|
||||
class BuildingDataWorkshopExtraWeightItem(BaseStruct):
|
||||
weight: int
|
||||
itemId: str
|
||||
itemCount: int
|
||||
|
||||
|
||||
class BuildingDataWorkshopFormulaUnlockRoom(BaseModel):
|
||||
class BuildingDataWorkshopFormulaUnlockRoom(BaseStruct):
|
||||
roomId: str
|
||||
roomLevel: int
|
||||
roomCount: int
|
||||
|
||||
|
||||
class BuildingDataWorkshopFormulaUnlockStage(BaseModel):
|
||||
class BuildingDataWorkshopFormulaUnlockStage(BaseStruct):
|
||||
stageId: str
|
||||
rank: int
|
||||
|
||||
|
||||
class BuildingDataWorkshopFormula(BaseModel):
|
||||
class BuildingDataWorkshopFormula(BaseStruct):
|
||||
sortId: int
|
||||
formulaId: str
|
||||
rarity: int
|
||||
@ -375,23 +393,25 @@ class BuildingDataWorkshopFormula(BaseModel):
|
||||
formulaType: str
|
||||
buffType: str
|
||||
extraOutcomeRate: float
|
||||
extraOutcomeGroup: list[BuildingDataWorkshopExtraWeightItem]
|
||||
costs: list[ItemBundle]
|
||||
requireRooms: list[BuildingDataWorkshopFormulaUnlockRoom]
|
||||
requireStages: list[BuildingDataWorkshopFormulaUnlockStage]
|
||||
extraOutcomeGroup: List[BuildingDataWorkshopExtraWeightItem]
|
||||
costs: List[ItemBundle]
|
||||
requireRooms: List[BuildingDataWorkshopFormulaUnlockRoom]
|
||||
requireStages: List[BuildingDataWorkshopFormulaUnlockStage]
|
||||
|
||||
|
||||
class BuildingDataCreditFormulaValueModel(BaseModel):
|
||||
class BuildingDataCreditFormulaValueModel(BaseStruct):
|
||||
basic: int
|
||||
addition: int
|
||||
|
||||
|
||||
class BuildingDataCreditFormula(BaseModel):
|
||||
initiative: BuildingDataCreditFormulaValueModel | dict
|
||||
passive: BuildingDataCreditFormulaValueModel | dict
|
||||
class BuildingDataCreditFormula(BaseStruct):
|
||||
initiative: Dict
|
||||
passive: Dict
|
||||
# initiative: Union[BuildingDataCreditFormulaValueModel, Dict]
|
||||
# passive: Union[BuildingDataCreditFormulaValueModel, Dict]
|
||||
|
||||
|
||||
class BuildingData(BaseModel):
|
||||
class BuildingData(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
controlSlotId: str
|
||||
@ -411,8 +431,8 @@ class BuildingData(BaseModel):
|
||||
manufactStationBuff: float
|
||||
comfortManpowerRecoverFactor: int
|
||||
manpowerDisplayFactor: int
|
||||
shopOutputRatio: dict[str, int] | None
|
||||
shopStackRatio: dict[str, int] | None
|
||||
shopOutputRatio: Union[Dict[str, int], None]
|
||||
shopStackRatio: Union[Dict[str, int], None]
|
||||
basicFavorPerDay: int
|
||||
humanResourceLimit: int
|
||||
tiredApThreshold: int
|
||||
@ -429,32 +449,29 @@ class BuildingData(BaseModel):
|
||||
socialSlotNum: int
|
||||
furniDuplicationLimit: int
|
||||
assistFavorReport: int
|
||||
manufactManpowerCostByNum: list[int]
|
||||
tradingManpowerCostByNum: list[int]
|
||||
roomUnlockConds: dict[str, BuildingDataRoomUnlockCond]
|
||||
rooms: dict[str, BuildingDataRoomData]
|
||||
layouts: dict[str, BuildingDataLayoutData]
|
||||
prefabs: dict[str, BuildingDataPrefabInfo]
|
||||
manufactManpowerCostByNum: List[int]
|
||||
tradingManpowerCostByNum: List[int]
|
||||
roomUnlockConds: Dict[str, BuildingDataRoomUnlockCond]
|
||||
rooms: Dict[str, BuildingDataRoomData]
|
||||
layouts: Dict[str, BuildingDataLayoutData]
|
||||
prefabs: Dict[str, BuildingDataPrefabInfo]
|
||||
controlData: BuildingDataControlRoomBean
|
||||
manufactData: BuildingDataManufactRoomBean
|
||||
shopData: BuildingDataRoomBean
|
||||
shopData: BuildingDataShopRoomBean
|
||||
hireData: BuildingDataHireRoomBean
|
||||
dormData: BuildingDataRoomBean
|
||||
dormData: BuildingDataDormRoomBean
|
||||
meetingData: BuildingDataMeetingRoomBean
|
||||
tradingData: BuildingDataTradingRoomBean
|
||||
workshopData: BuildingDataRoomBean
|
||||
workshopData: BuildingDataWorkShopRoomBean
|
||||
trainingData: BuildingDataTrainingBean
|
||||
powerData: BuildingDataPowerRoomBean
|
||||
chars: dict[str, BuildingDataBuildingCharacter]
|
||||
buffs: dict[str, BuildingDataBuildingBuff]
|
||||
workshopBonus: dict[str, list[str]]
|
||||
chars: Dict[str, BuildingDataBuildingCharacter]
|
||||
buffs: Dict[str, BuildingDataBuildingBuff]
|
||||
workshopBonus: Dict[str, List[str]]
|
||||
customData: BuildingDataCustomData
|
||||
manufactFormulas: dict[str, BuildingDataManufactFormula]
|
||||
shopFormulas: dict[str, BuildingDataShopFormula]
|
||||
workshopFormulas: dict[str, BuildingDataWorkshopFormula]
|
||||
manufactFormulas: Dict[str, BuildingDataManufactFormula]
|
||||
shopFormulas: Dict[str, BuildingDataShopFormula]
|
||||
workshopFormulas: Dict[str, BuildingDataWorkshopFormula]
|
||||
creditFormula: BuildingDataCreditFormula
|
||||
goldItems: dict[str, int]
|
||||
assistantUnlock: list[int]
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
goldItems: Dict[str, int]
|
||||
assistantUnlock: List[int]
|
||||
|
@ -1,29 +1,31 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class CampaignDataBreakRewardLadder(BaseModel):
|
||||
class CampaignDataBreakRewardLadder(BaseStruct):
|
||||
killCnt: int
|
||||
breakFeeAdd: int
|
||||
rewards: list[ItemBundle]
|
||||
rewards: List[ItemBundle]
|
||||
|
||||
|
||||
class WeightItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
type_: str = Field(alias='type')
|
||||
class WeightItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
type_: str = field(name='type')
|
||||
dropType: str
|
||||
count: int
|
||||
weight: int
|
||||
|
||||
|
||||
class StageDataDisplayRewards_(BaseModel):
|
||||
type_: str = Field(alias='type')
|
||||
id_: str = Field(alias='id')
|
||||
class StageDataDisplayRewards_(BaseStruct):
|
||||
type_: str = field(name='type')
|
||||
id_: str = field(name='id')
|
||||
dropType: int
|
||||
|
||||
|
||||
@ -33,18 +35,18 @@ class StageDataDisplayDetailRewards_(StageDataDisplayRewards_):
|
||||
CannotGetPercent: float
|
||||
|
||||
|
||||
class CampaignDataCampaignDropInfo(BaseModel):
|
||||
firstPassRewards: list[ItemBundle] | None
|
||||
passRewards: list[list[WeightItemBundle]] | None
|
||||
displayDetailRewards: list[StageDataDisplayDetailRewards_] | None
|
||||
class CampaignDataCampaignDropInfo(BaseStruct):
|
||||
firstPassRewards: Union[List[ItemBundle], None]
|
||||
passRewards: Union[List[List[WeightItemBundle]], None]
|
||||
displayDetailRewards: Union[List[StageDataDisplayDetailRewards_], None]
|
||||
|
||||
|
||||
class CampaignDataDropLadder(BaseModel):
|
||||
class CampaignDataDropLadder(BaseStruct):
|
||||
killCnt: int
|
||||
dropInfo: CampaignDataCampaignDropInfo
|
||||
|
||||
|
||||
class CampaignDataGainLadder(BaseModel):
|
||||
class CampaignDataGainLadder(BaseStruct):
|
||||
killCnt: int
|
||||
apFailReturn: int
|
||||
favor: int
|
||||
@ -53,62 +55,62 @@ class CampaignDataGainLadder(BaseModel):
|
||||
displayDiamondShdNum: int
|
||||
|
||||
|
||||
class StageDataDisplayRewards(BaseModel):
|
||||
type_: str = Field(alias='type')
|
||||
id_: str = Field(alias='id')
|
||||
class StageDataDisplayRewards(BaseStruct):
|
||||
type_: str = field(name='type')
|
||||
id_: str = field(name='id')
|
||||
dropType: int
|
||||
|
||||
|
||||
class StageDataDisplayDetailRewards(BaseModel):
|
||||
class StageDataDisplayDetailRewards(BaseStruct):
|
||||
occPercent: int
|
||||
type_: str = Field(alias='type')
|
||||
id_: str = Field(alias='id')
|
||||
type_: str = field(name='type')
|
||||
id_: str = field(name='id')
|
||||
dropType: int
|
||||
|
||||
|
||||
class CampaignDataDropGainInfo(BaseModel):
|
||||
dropLadders: list[CampaignDataDropLadder]
|
||||
gainLadders: list[CampaignDataGainLadder]
|
||||
displayRewards: list[StageDataDisplayRewards]
|
||||
displayDetailRewards: list[StageDataDisplayDetailRewards]
|
||||
class CampaignDataDropGainInfo(BaseStruct):
|
||||
dropLadders: List[CampaignDataDropLadder]
|
||||
gainLadders: List[CampaignDataGainLadder]
|
||||
displayRewards: List[StageDataDisplayRewards]
|
||||
displayDetailRewards: List[StageDataDisplayDetailRewards]
|
||||
|
||||
|
||||
class CampaignData(BaseModel):
|
||||
class CampaignData(BaseStruct):
|
||||
stageId: str
|
||||
isSmallScale: int
|
||||
breakLadders: list[CampaignDataBreakRewardLadder]
|
||||
breakLadders: List[CampaignDataBreakRewardLadder]
|
||||
isCustomized: bool
|
||||
dropGains: dict[str, CampaignDataDropGainInfo]
|
||||
dropGains: Dict[str, CampaignDataDropGainInfo]
|
||||
|
||||
|
||||
class CampaignGroupData(BaseModel):
|
||||
class CampaignGroupData(BaseStruct):
|
||||
groupId: str
|
||||
activeCamps: list[str]
|
||||
activeCamps: List[str]
|
||||
startTs: int
|
||||
endTs: int
|
||||
|
||||
|
||||
class CampaignRegionData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class CampaignRegionData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
isUnknwon: int
|
||||
|
||||
|
||||
class CampaignZoneData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class CampaignZoneData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
name: str
|
||||
regionId: str
|
||||
templateId: str
|
||||
|
||||
|
||||
class CampaignMissionData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class CampaignMissionData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
sortId: int
|
||||
param: list[str]
|
||||
param: List[str]
|
||||
description: str
|
||||
breakFeeAdd: int
|
||||
|
||||
|
||||
class CampaignConstTable(BaseModel):
|
||||
class CampaignConstTable(BaseStruct):
|
||||
systemPreposedStage: str
|
||||
rotateStartTime: int
|
||||
rotatePreposedStage: str
|
||||
@ -117,42 +119,39 @@ class CampaignConstTable(BaseModel):
|
||||
sweepStartTime: int
|
||||
|
||||
|
||||
class CampaignRotateOpenTimeData(BaseModel):
|
||||
class CampaignRotateOpenTimeData(BaseStruct):
|
||||
groupId: str
|
||||
stageId: str
|
||||
mapId: str
|
||||
unknownRegions: list[str]
|
||||
unknownRegions: List[str]
|
||||
duration: int
|
||||
startTs: int
|
||||
endTs: int
|
||||
|
||||
|
||||
class CampaignTrainingOpenTimeData(BaseModel):
|
||||
class CampaignTrainingOpenTimeData(BaseStruct):
|
||||
groupId: str
|
||||
stages: list[str]
|
||||
stages: List[str]
|
||||
startTs: int
|
||||
endTs: int
|
||||
|
||||
|
||||
class CampaignTrainingAllOpenTimeData(BaseModel):
|
||||
class CampaignTrainingAllOpenTimeData(BaseStruct):
|
||||
groupId: str
|
||||
startTs: int
|
||||
endTs: int
|
||||
|
||||
|
||||
class CampaignTable(BaseModel):
|
||||
class CampaignTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
campaigns: dict[str, CampaignData]
|
||||
campaignGroups: dict[str, CampaignGroupData]
|
||||
campaignRegions: dict[str, CampaignRegionData]
|
||||
campaignZones: dict[str, CampaignZoneData]
|
||||
campaignMissions: dict[str, CampaignMissionData]
|
||||
stageIndexInZoneMap: dict[str, int]
|
||||
campaigns: Dict[str, CampaignData]
|
||||
campaignGroups: Dict[str, CampaignGroupData]
|
||||
campaignRegions: Dict[str, CampaignRegionData]
|
||||
campaignZones: Dict[str, CampaignZoneData]
|
||||
campaignMissions: Dict[str, CampaignMissionData]
|
||||
stageIndexInZoneMap: Dict[str, int]
|
||||
campaignConstTable: CampaignConstTable
|
||||
campaignRotateStageOpenTimes: list[CampaignRotateOpenTimeData]
|
||||
campaignTrainingStageOpenTimes: list[CampaignTrainingOpenTimeData]
|
||||
campaignTrainingAllOpenTimes: list[CampaignTrainingAllOpenTimeData]
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
campaignRotateStageOpenTimes: List[CampaignRotateOpenTimeData]
|
||||
campaignTrainingStageOpenTimes: List[CampaignTrainingOpenTimeData]
|
||||
campaignTrainingAllOpenTimes: List[CampaignTrainingAllOpenTimeData]
|
||||
|
@ -1,24 +1,19 @@
|
||||
from pydantic import BaseModel
|
||||
from typing import Dict, Union
|
||||
from ..common import BaseStruct
|
||||
|
||||
|
||||
class ChapterData(BaseModel):
|
||||
class ChapterData(BaseStruct):
|
||||
chapterId: str
|
||||
chapterName: str
|
||||
chapterName2: str
|
||||
chapterIndex: int
|
||||
preposedChapterId: str | None
|
||||
preposedChapterId: Union[str, None]
|
||||
startZoneId: str
|
||||
endZoneId: str
|
||||
chapterEndStageId: str
|
||||
|
||||
|
||||
class ChapterTable(BaseModel):
|
||||
class ChapterTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
chapters: dict[str, ChapterData]
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
|
||||
def __init__(self, data: dict) -> None:
|
||||
super().__init__(chapters=data)
|
||||
chapters: Dict[str, ChapterData]
|
||||
|
@ -1,27 +1,26 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class SpCharMissionData(BaseModel):
|
||||
class SpCharMissionData(BaseStruct):
|
||||
charId: str
|
||||
missionId: str
|
||||
sortId: int
|
||||
condType: str
|
||||
param: list[str]
|
||||
rewards: list[ItemBundle]
|
||||
param: List[str]
|
||||
rewards: List[ItemBundle]
|
||||
|
||||
|
||||
class CharMetaTable(BaseModel):
|
||||
class CharMetaTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
|
||||
spCharGroups: dict[str, list[str]]
|
||||
spCharMissions: dict[str, dict[str, SpCharMissionData]]
|
||||
spCharVoucherSkinTime: dict[str, int]
|
||||
spCharGroups: Dict[str, List[str]]
|
||||
spCharMissions: Dict[str, Dict[str, SpCharMissionData]]
|
||||
spCharVoucherSkinTime: Dict[str, int]
|
||||
|
@ -1,39 +1,41 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class CharPatchDataPatchInfo(BaseModel):
|
||||
tmplIds: list[str]
|
||||
class CharPatchDataPatchInfo(BaseStruct):
|
||||
tmplIds: List[str]
|
||||
default: str
|
||||
|
||||
|
||||
class CharacterDataUnlockCondition(BaseModel):
|
||||
class CharacterDataUnlockCondition(BaseStruct):
|
||||
phase: int
|
||||
level: int
|
||||
|
||||
|
||||
class Blackboard(BaseModel):
|
||||
class Blackboard(BaseStruct):
|
||||
key: str
|
||||
value: float | None = None
|
||||
valueStr: str | None = None
|
||||
value: Union[float, None] = None
|
||||
valueStr: Union[str, None] = None
|
||||
|
||||
|
||||
class CharacterDataTraitData(BaseModel):
|
||||
class CharacterDataTraitData(BaseStruct):
|
||||
unlockCondition: CharacterDataUnlockCondition
|
||||
requiredPotentialRank: int
|
||||
blackboard: list[Blackboard]
|
||||
overrideDescripton: str | None
|
||||
prefabKey: str | None
|
||||
rangeId: str | None
|
||||
blackboard: List[Blackboard]
|
||||
overrideDescripton: Union[str, None]
|
||||
prefabKey: Union[str, None]
|
||||
rangeId: Union[str, None]
|
||||
|
||||
|
||||
class CharacterDataTraitDataBundle(BaseModel):
|
||||
candidates: list[CharacterDataTraitData]
|
||||
class CharacterDataTraitDataBundle(BaseStruct):
|
||||
candidates: List[CharacterDataTraitData]
|
||||
|
||||
|
||||
class AttributesData(BaseModel):
|
||||
class AttributesData(BaseStruct):
|
||||
maxHp: int
|
||||
atk: int
|
||||
def_: int = Field(alias='def')
|
||||
def_: int = field(name='def')
|
||||
magicResistance: float
|
||||
cost: int
|
||||
blockCnt: int
|
||||
@ -55,54 +57,55 @@ class AttributesData(BaseModel):
|
||||
levitateImmune: bool
|
||||
|
||||
|
||||
class CharacterDataAttributesKeyFrame(BaseModel):
|
||||
class CharacterDataAttributesKeyFrame(BaseStruct):
|
||||
level: int
|
||||
data: AttributesData
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class CharacterDataPhaseData(BaseModel):
|
||||
class CharacterDataPhaseData(BaseStruct):
|
||||
characterPrefabKey: str
|
||||
rangeId: str | None
|
||||
rangeId: Union[str, None]
|
||||
maxLevel: int
|
||||
attributesKeyFrames: list[CharacterDataAttributesKeyFrame]
|
||||
evolveCost: list[ItemBundle] | None
|
||||
attributesKeyFrames: List[CharacterDataAttributesKeyFrame]
|
||||
evolveCost: Union[List[ItemBundle], None]
|
||||
|
||||
|
||||
class CharacterDataMainSkillSpecializeLevelData(BaseModel):
|
||||
class CharacterDataMainSkillSpecializeLevelData(BaseStruct):
|
||||
unlockCond: CharacterDataUnlockCondition
|
||||
lvlUpTime: int
|
||||
levelUpCost: list[ItemBundle] | None
|
||||
levelUpCost: Union[List[ItemBundle], None]
|
||||
|
||||
|
||||
class CharacterDataMainSkill(BaseModel):
|
||||
skillId: str | None
|
||||
overridePrefabKey: str | None
|
||||
overrideTokenKey: str | None
|
||||
levelUpCostCond: list[CharacterDataMainSkillSpecializeLevelData]
|
||||
class CharacterDataMainSkill(BaseStruct):
|
||||
skillId: Union[str, None]
|
||||
overridePrefabKey: Union[str, None]
|
||||
overrideTokenKey: Union[str, None]
|
||||
levelUpCostCond: List[CharacterDataMainSkillSpecializeLevelData]
|
||||
unlockCond: CharacterDataUnlockCondition
|
||||
|
||||
|
||||
class TalentData(BaseModel):
|
||||
class TalentData(BaseStruct):
|
||||
unlockCondition: CharacterDataUnlockCondition
|
||||
requiredPotentialRank: int
|
||||
prefabKey: str
|
||||
name: str | None
|
||||
description: str | None
|
||||
rangeId: str | None
|
||||
blackboard: list[Blackboard]
|
||||
name: Union[str, None]
|
||||
description: Union[str, None]
|
||||
rangeId: Union[str, None]
|
||||
blackboard: List[Blackboard]
|
||||
displayRange: bool
|
||||
|
||||
|
||||
class CharacterDataTalentDataBundle(BaseModel):
|
||||
candidates: list[TalentData] | None
|
||||
class CharacterDataTalentDataBundle(BaseStruct):
|
||||
candidates: Union[List[TalentData], None]
|
||||
|
||||
|
||||
class AttributeModifierDataAttributeModifier(BaseModel):
|
||||
class AttributeModifierDataAttributeModifier(BaseStruct):
|
||||
attributeType: int
|
||||
formulaItem: int
|
||||
value: float
|
||||
@ -110,86 +113,85 @@ class AttributeModifierDataAttributeModifier(BaseModel):
|
||||
fetchBaseValueFromSourceEntity: bool
|
||||
|
||||
|
||||
class AttributeModifierData(BaseModel):
|
||||
abnormalFlags: list[str] | None
|
||||
abnormalImmunes: list[str] | None
|
||||
abnormalAntis: list[str] | None
|
||||
abnormalCombos: list[str] | None
|
||||
abnormalComboImmunes: list[str] | None
|
||||
attributeModifiers: list[AttributeModifierDataAttributeModifier]
|
||||
class AttributeModifierData(BaseStruct):
|
||||
abnormalFlags: Union[List[str], None]
|
||||
abnormalImmunes: Union[List[str], None]
|
||||
abnormalAntis: Union[List[str], None]
|
||||
abnormalCombos: Union[List[str], None]
|
||||
abnormalComboImmunes: Union[List[str], None]
|
||||
attributeModifiers: List[AttributeModifierDataAttributeModifier]
|
||||
|
||||
|
||||
class ExternalBuff(BaseModel):
|
||||
class ExternalBuff(BaseStruct):
|
||||
attributes: AttributeModifierData
|
||||
|
||||
|
||||
class CharacterDataPotentialRank(BaseModel):
|
||||
type_: int = Field(alias='type')
|
||||
class CharacterDataPotentialRank(BaseStruct):
|
||||
type_: int = field(name='type')
|
||||
description: str
|
||||
buff: ExternalBuff | None
|
||||
equivalentCost: ItemBundle | None
|
||||
buff: Union[ExternalBuff, None]
|
||||
equivalentCost: Union[ItemBundle, None]
|
||||
|
||||
|
||||
class CharacterDataSkillLevelCost(BaseModel):
|
||||
class CharacterDataSkillLevelCost(BaseStruct):
|
||||
unlockCond: CharacterDataUnlockCondition
|
||||
lvlUpCost: list[ItemBundle] | None
|
||||
lvlUpCost: Union[List[ItemBundle], None]
|
||||
|
||||
|
||||
class CharacterData(BaseModel):
|
||||
class CharacterData(BaseStruct):
|
||||
name: str
|
||||
description: str | None
|
||||
description: Union[str, None]
|
||||
canUseGeneralPotentialItem: bool
|
||||
canUseActivityPotentialItem: bool
|
||||
potentialItemId: str | None
|
||||
activityPotentialItemId: str | None
|
||||
nationId: str | None
|
||||
groupId: str | None
|
||||
teamId: str | None
|
||||
displayNumber: str | None
|
||||
tokenKey: str | None = None
|
||||
potentialItemId: Union[str, None]
|
||||
activityPotentialItemId: Union[str, None]
|
||||
nationId: Union[str, None]
|
||||
groupId: Union[str, None]
|
||||
teamId: Union[str, None]
|
||||
displayNumber: Union[str, None]
|
||||
appellation: str
|
||||
position: str
|
||||
tagList: list[str] | None
|
||||
itemUsage: str | None
|
||||
itemDesc: str | None
|
||||
itemObtainApproach: str | None
|
||||
tagList: Union[List[str], None]
|
||||
itemUsage: Union[str, None]
|
||||
itemDesc: Union[str, None]
|
||||
itemObtainApproach: Union[str, None]
|
||||
isNotObtainable: bool
|
||||
isSpChar: bool
|
||||
maxPotentialLevel: int
|
||||
rarity: int
|
||||
profession: str
|
||||
subProfessionId: str
|
||||
trait: CharacterDataTraitDataBundle | None
|
||||
phases: list[CharacterDataPhaseData]
|
||||
skills: list[CharacterDataMainSkill]
|
||||
talents: list[CharacterDataTalentDataBundle] | None
|
||||
potentialRanks: list[CharacterDataPotentialRank]
|
||||
favorKeyFrames: list[CharacterDataAttributesKeyFrame] | None
|
||||
allSkillLvlup: list[CharacterDataSkillLevelCost]
|
||||
trait: Union[CharacterDataTraitDataBundle, None]
|
||||
phases: List[CharacterDataPhaseData]
|
||||
skills: List[CharacterDataMainSkill]
|
||||
talents: Union[List[CharacterDataTalentDataBundle], None]
|
||||
potentialRanks: List[CharacterDataPotentialRank]
|
||||
favorKeyFrames: Union[List[CharacterDataAttributesKeyFrame], None]
|
||||
allSkillLvlup: List[CharacterDataSkillLevelCost]
|
||||
minPowerId: str
|
||||
maxPowerId: str
|
||||
tokenKey: Union[str, None] = None
|
||||
|
||||
|
||||
class CharPatchDataUnlockCondItem(BaseModel):
|
||||
class CharPatchDataUnlockCondItem(BaseStruct):
|
||||
stageId: str
|
||||
completeState: int
|
||||
|
||||
|
||||
class CharPatchDataUnlockCond(BaseModel):
|
||||
conds: list[CharPatchDataUnlockCondItem]
|
||||
class CharPatchDataUnlockCond(BaseStruct):
|
||||
conds: List[CharPatchDataUnlockCondItem]
|
||||
|
||||
|
||||
class CharPatchDataPatchDetailInfo(BaseModel):
|
||||
class CharPatchDataPatchDetailInfo(BaseStruct):
|
||||
patchId: str
|
||||
sortId: int
|
||||
infoParam: str
|
||||
|
||||
|
||||
class CharPatchTable(BaseModel):
|
||||
class CharPatchTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
infos: dict[str, CharPatchDataPatchInfo]
|
||||
patchChars: dict[str, CharacterData]
|
||||
unlockConds: dict[str, CharPatchDataUnlockCond]
|
||||
patchDetailInfoList: dict[str, CharPatchDataPatchDetailInfo]
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
infos: Dict[str, CharPatchDataPatchInfo]
|
||||
patchChars: Dict[str, CharacterData]
|
||||
unlockConds: Dict[str, CharPatchDataUnlockCond]
|
||||
patchDetailInfoList: Dict[str, CharPatchDataPatchDetailInfo]
|
||||
|
@ -1,34 +1,37 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class CharacterDataUnlockCondition(BaseModel):
|
||||
class CharacterDataUnlockCondition(BaseStruct):
|
||||
phase: int
|
||||
level: int
|
||||
|
||||
|
||||
class Blackboard(BaseModel):
|
||||
class Blackboard(BaseStruct):
|
||||
key: str
|
||||
value: float | None = None
|
||||
valueStr: str | None = None
|
||||
value: Union[float, None] = None
|
||||
valueStr: Union[str, None] = None
|
||||
|
||||
|
||||
class CharacterDataTraitData(BaseModel):
|
||||
class CharacterDataTraitData(BaseStruct):
|
||||
unlockCondition: CharacterDataUnlockCondition
|
||||
requiredPotentialRank: int
|
||||
blackboard: list[Blackboard]
|
||||
overrideDescripton: str | None
|
||||
prefabKey: str | None
|
||||
rangeId: str | None
|
||||
blackboard: List[Blackboard]
|
||||
overrideDescripton: Union[str, None]
|
||||
prefabKey: Union[str, None]
|
||||
rangeId: Union[str, None]
|
||||
additionalDesc: str
|
||||
|
||||
|
||||
class CharacterDataTraitDataBundle(BaseModel):
|
||||
candidates: list[CharacterDataTraitData]
|
||||
class CharacterDataTraitDataBundle(BaseStruct):
|
||||
candidates: List[CharacterDataTraitData]
|
||||
|
||||
|
||||
class AttributesData(BaseModel):
|
||||
class AttributesData(BaseStruct):
|
||||
maxHp: int
|
||||
atk: int
|
||||
def_: int = Field(alias='def')
|
||||
def_: int = field(name='def')
|
||||
magicResistance: float
|
||||
cost: int
|
||||
blockCnt: int
|
||||
@ -50,54 +53,56 @@ class AttributesData(BaseModel):
|
||||
levitateImmune: bool
|
||||
|
||||
|
||||
class CharacterDataAttributesKeyFrame(BaseModel):
|
||||
class CharacterDataAttributesKeyFrame(BaseStruct):
|
||||
level: int
|
||||
data: AttributesData
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class CharacterDataPhaseData(BaseModel):
|
||||
class CharacterDataPhaseData(BaseStruct):
|
||||
characterPrefabKey: str
|
||||
rangeId: str | None
|
||||
rangeId: Union[str, None]
|
||||
maxLevel: int
|
||||
attributesKeyFrames: list[CharacterDataAttributesKeyFrame]
|
||||
evolveCost: list[ItemBundle] | None
|
||||
attributesKeyFrames: List[CharacterDataAttributesKeyFrame]
|
||||
evolveCost: Union[List[ItemBundle], None]
|
||||
|
||||
|
||||
class CharacterDataMainSkillSpecializeLevelData(BaseModel):
|
||||
class CharacterDataMainSkillSpecializeLevelData(BaseStruct):
|
||||
unlockCond: CharacterDataUnlockCondition
|
||||
lvlUpTime: int
|
||||
levelUpCost: list[ItemBundle] | None
|
||||
levelUpCost: Union[List[ItemBundle], None]
|
||||
|
||||
|
||||
class CharacterDataMainSkill(BaseModel):
|
||||
skillId: str | None
|
||||
overridePrefabKey: str | None
|
||||
overrideTokenKey: str | None
|
||||
levelUpCostCond: list[CharacterDataMainSkillSpecializeLevelData]
|
||||
class CharacterDataMainSkill(BaseStruct):
|
||||
skillId: Union[str, None]
|
||||
overridePrefabKey: Union[str, None]
|
||||
overrideTokenKey: Union[str, None]
|
||||
levelUpCostCond: List[CharacterDataMainSkillSpecializeLevelData]
|
||||
unlockCond: CharacterDataUnlockCondition
|
||||
|
||||
|
||||
class TalentData(BaseModel):
|
||||
class TalentData(BaseStruct):
|
||||
unlockCondition: CharacterDataUnlockCondition
|
||||
requiredPotentialRank: int
|
||||
prefabKey: str
|
||||
name: str | None
|
||||
description: str | None
|
||||
rangeId: str | None
|
||||
blackboard: list[Blackboard]
|
||||
name: Union[str, None]
|
||||
description: Union[str, None]
|
||||
rangeId: Union[str, None]
|
||||
blackboard: List[Blackboard]
|
||||
displayRange: bool
|
||||
tokenKey: Union[str, None] = None
|
||||
|
||||
|
||||
class CharacterDataTalentDataBundle(BaseModel):
|
||||
candidates: list[TalentData] | None
|
||||
class CharacterDataTalentDataBundle(BaseStruct):
|
||||
candidates: Union[List[TalentData], None]
|
||||
|
||||
|
||||
class AttributeModifierDataAttributeModifier(BaseModel):
|
||||
class AttributeModifierDataAttributeModifier(BaseStruct):
|
||||
attributeType: int
|
||||
formulaItem: int
|
||||
value: float
|
||||
@ -105,74 +110,72 @@ class AttributeModifierDataAttributeModifier(BaseModel):
|
||||
fetchBaseValueFromSourceEntity: bool
|
||||
|
||||
|
||||
class AttributeModifierData(BaseModel):
|
||||
abnormalFlags: list[str] | None
|
||||
abnormalImmunes: list[str] | None
|
||||
abnormalAntis: list[str] | None
|
||||
abnormalCombos: list[str] | None
|
||||
abnormalComboImmunes: list[str] | None
|
||||
attributeModifiers: list[AttributeModifierDataAttributeModifier]
|
||||
class AttributeModifierData(BaseStruct):
|
||||
abnormalFlags: Union[List[str], None]
|
||||
abnormalImmunes: Union[List[str], None]
|
||||
abnormalAntis: Union[List[str], None]
|
||||
abnormalCombos: Union[List[str], None]
|
||||
abnormalComboImmunes: Union[List[str], None]
|
||||
attributeModifiers: List[AttributeModifierDataAttributeModifier]
|
||||
|
||||
|
||||
class ExternalBuff(BaseModel):
|
||||
class ExternalBuff(BaseStruct):
|
||||
attributes: AttributeModifierData
|
||||
|
||||
|
||||
class CharacterDataPotentialRank(BaseModel):
|
||||
type_: int = Field(alias='type')
|
||||
class CharacterDataPotentialRank(BaseStruct):
|
||||
type_: int = field(name='type')
|
||||
description: str
|
||||
buff: ExternalBuff | None
|
||||
equivalentCost: ItemBundle | None
|
||||
buff: Union[ExternalBuff, None]
|
||||
equivalentCost: Union[ItemBundle, None]
|
||||
|
||||
|
||||
class CharacterDataSkillLevelCost(BaseModel):
|
||||
class CharacterDataSkillLevelCost(BaseStruct):
|
||||
unlockCond: CharacterDataUnlockCondition
|
||||
lvlUpCost: list[ItemBundle] | None
|
||||
lvlUpCost: Union[List[ItemBundle], None]
|
||||
|
||||
|
||||
class CharacterData(BaseModel):
|
||||
class CharacterData(BaseStruct):
|
||||
name: str
|
||||
description: str | None
|
||||
description: Union[str, None]
|
||||
canUseGeneralPotentialItem: bool
|
||||
canUseActivityPotentialItem: bool
|
||||
potentialItemId: str | None
|
||||
activityPotentialItemId: str | None
|
||||
nationId: str | None
|
||||
groupId: str | None
|
||||
teamId: str | None
|
||||
displayNumber: str | None
|
||||
tokenKey: str | None = None
|
||||
potentialItemId: Union[str, None]
|
||||
activityPotentialItemId: Union[str, None]
|
||||
nationId: Union[str, None]
|
||||
groupId: Union[str, None]
|
||||
teamId: Union[str, None]
|
||||
displayNumber: Union[str, None]
|
||||
appellation: str
|
||||
position: str
|
||||
tagList: list[str] | None
|
||||
itemUsage: str | None
|
||||
itemDesc: str | None
|
||||
itemObtainApproach: str | None
|
||||
tagList: Union[List[str], None]
|
||||
itemUsage: Union[str, None]
|
||||
itemDesc: Union[str, None]
|
||||
itemObtainApproach: Union[str, None]
|
||||
isNotObtainable: bool
|
||||
isSpChar: bool
|
||||
maxPotentialLevel: int
|
||||
rarity: int
|
||||
profession: str
|
||||
subProfessionId: str
|
||||
trait: CharacterDataTraitDataBundle | None
|
||||
phases: list[CharacterDataPhaseData]
|
||||
skills: list[CharacterDataMainSkill]
|
||||
talents: list[CharacterDataTalentDataBundle] | None
|
||||
potentialRanks: list[CharacterDataPotentialRank]
|
||||
favorKeyFrames: list[CharacterDataAttributesKeyFrame] | None
|
||||
allSkillLvlup: list[CharacterDataSkillLevelCost]
|
||||
trait: Union[CharacterDataTraitDataBundle, None]
|
||||
phases: List[CharacterDataPhaseData]
|
||||
skills: List[CharacterDataMainSkill]
|
||||
talents: Union[List[CharacterDataTalentDataBundle], None]
|
||||
potentialRanks: List[CharacterDataPotentialRank]
|
||||
favorKeyFrames: Union[List[CharacterDataAttributesKeyFrame], None]
|
||||
allSkillLvlup: List[CharacterDataSkillLevelCost]
|
||||
minPowerId: str
|
||||
maxPowerId: str
|
||||
displayTokenDict: Union[Dict[str, bool], None] = None
|
||||
classicPotentialItemId: Union[str, None] = None
|
||||
tokenKey: Union[str, None] = None
|
||||
|
||||
|
||||
class CharacterTable(BaseModel):
|
||||
class CharacterTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
chars: dict[str, CharacterData]
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
|
||||
def __init__(self, data: dict) -> None:
|
||||
super().__init__(chars=data)
|
||||
chars: Dict[str, CharacterData]
|
||||
|
||||
def __getitem__(self, key: str) -> CharacterData:
|
||||
return self.chars[key]
|
||||
|
@ -1,40 +1,43 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class RuneDataSelector(BaseModel):
|
||||
professionMask: int | str
|
||||
class RuneDataSelector(BaseStruct):
|
||||
professionMask: Union[int, str]
|
||||
buildableMask: int
|
||||
charIdFilter: list[str] | None
|
||||
enemyIdFilter: list[str] | None
|
||||
enemyIdExcludeFilter: list[str] | None
|
||||
skillIdFilter: list[str] | None
|
||||
tileKeyFilter: list[str] | None
|
||||
groupTagFilter: list[str] | None
|
||||
filterTagFilter: list[str] | None
|
||||
charIdFilter: Union[List[str], None]
|
||||
enemyIdFilter: Union[List[str], None]
|
||||
enemyIdExcludeFilter: Union[List[str], None]
|
||||
skillIdFilter: Union[List[str], None]
|
||||
tileKeyFilter: Union[List[str], None]
|
||||
groupTagFilter: Union[List[str], None]
|
||||
filterTagFilter: Union[List[str], None]
|
||||
subProfessionExcludeFilter: Union[List[str], None]
|
||||
|
||||
|
||||
class Blackboard(BaseModel):
|
||||
class Blackboard(BaseStruct):
|
||||
key: str
|
||||
value: float | None = None
|
||||
valueStr: str | None = None
|
||||
value: Union[float, None] = None
|
||||
valueStr: Union[str, None] = None
|
||||
|
||||
|
||||
class RuneData(BaseModel):
|
||||
class RuneData(BaseStruct):
|
||||
key: str
|
||||
selector: RuneDataSelector
|
||||
blackboard: list[Blackboard]
|
||||
blackboard: List[Blackboard]
|
||||
|
||||
|
||||
class RuneTablePackedRuneData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class RuneTablePackedRuneData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
points: float
|
||||
mutexGroupKey: str | None
|
||||
mutexGroupKey: Union[str, None]
|
||||
description: str
|
||||
runes: list[RuneData]
|
||||
runes: List[RuneData]
|
||||
|
||||
|
||||
class CharmItemData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class CharmItemData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
sort: int
|
||||
name: str
|
||||
icon: str
|
||||
@ -44,18 +47,15 @@ class CharmItemData(BaseModel):
|
||||
rarity: int
|
||||
desc: str
|
||||
price: int
|
||||
specialObtainApproach: str | None
|
||||
specialObtainApproach: Union[str, None]
|
||||
charmType: str
|
||||
obtainInRandom: bool
|
||||
dropStages: list[str]
|
||||
dropStages: List[str]
|
||||
runeData: RuneTablePackedRuneData
|
||||
charmEffect: str
|
||||
|
||||
|
||||
class CharmTable(BaseModel):
|
||||
class CharmTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
|
||||
charmList: list[CharmItemData]
|
||||
charmList: List[CharmItemData]
|
||||
|
@ -1,12 +1,14 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class CharWordUnlockParam(BaseModel):
|
||||
valueStr: str | None
|
||||
class CharWordUnlockParam(BaseStruct):
|
||||
valueStr: Union[str, None]
|
||||
valueInt: int
|
||||
|
||||
|
||||
class CharWordData(BaseModel):
|
||||
class CharWordData(BaseStruct):
|
||||
charWordId: str
|
||||
wordKey: str
|
||||
charId: str
|
||||
@ -16,53 +18,51 @@ class CharWordData(BaseModel):
|
||||
voiceIndex: int
|
||||
voiceType: str
|
||||
unlockType: str
|
||||
unlockParam: list[CharWordUnlockParam]
|
||||
lockDescription: str | None
|
||||
unlockParam: List[CharWordUnlockParam]
|
||||
lockDescription: Union[str, None]
|
||||
placeType: str
|
||||
voiceAsset: str
|
||||
|
||||
|
||||
class VoiceLangInfoData(BaseModel):
|
||||
class VoiceLangInfoData(BaseStruct):
|
||||
wordkey: str
|
||||
voiceLangType: str
|
||||
cvName: list[str]
|
||||
cvName: List[str]
|
||||
voicePath: Union[str, None] = None
|
||||
|
||||
|
||||
class VoiceLangData(BaseModel):
|
||||
wordkeys: list[str]
|
||||
class VoiceLangData(BaseStruct):
|
||||
wordkeys: List[str]
|
||||
charId: str
|
||||
dict_: dict[str, VoiceLangInfoData] = Field(alias='dict')
|
||||
dict_: Dict[str, VoiceLangInfoData] = field(name='dict')
|
||||
|
||||
|
||||
class VoiceLangTypeData(BaseModel):
|
||||
class VoiceLangTypeData(BaseStruct):
|
||||
name: str
|
||||
groupType: str
|
||||
|
||||
|
||||
class VoiceLangGroupData(BaseModel):
|
||||
class VoiceLangGroupData(BaseStruct):
|
||||
name: str
|
||||
members: list[str]
|
||||
members: List[str]
|
||||
|
||||
|
||||
class NewVoiceTimeData(BaseModel):
|
||||
class NewVoiceTimeData(BaseStruct):
|
||||
timestamp: int
|
||||
charSet: list[str]
|
||||
charSet: List[str]
|
||||
|
||||
|
||||
class CharwordTable(BaseModel):
|
||||
class CharwordTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
charWords: dict[str, CharWordData]
|
||||
voiceLangDict: dict[str, VoiceLangData]
|
||||
charWords: Dict[str, CharWordData]
|
||||
voiceLangDict: Dict[str, VoiceLangData]
|
||||
defaultLangType: str
|
||||
newTagList: list[str]
|
||||
voiceLangTypeDict: dict[str, VoiceLangTypeData]
|
||||
voiceLangGroupTypeDict: dict[str, VoiceLangGroupData]
|
||||
charDefaultTypeDict: dict[str, str]
|
||||
startTimeWithTypeDict: dict[str, list[NewVoiceTimeData]]
|
||||
displayGroupTypeList: list[str]
|
||||
displayTypeList: list[str]
|
||||
newTagList: List[str]
|
||||
voiceLangTypeDict: Dict[str, VoiceLangTypeData]
|
||||
voiceLangGroupTypeDict: Dict[str, VoiceLangGroupData]
|
||||
charDefaultTypeDict: Dict[str, str]
|
||||
startTimeWithTypeDict: Dict[str, List[NewVoiceTimeData]]
|
||||
displayGroupTypeList: List[str]
|
||||
displayTypeList: List[str]
|
||||
playVoiceRange: str
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
|
@ -1,42 +1,41 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class MonthlySignInData(BaseModel):
|
||||
class MonthlySignInData(BaseStruct):
|
||||
itemId: str
|
||||
itemType: str
|
||||
count: int
|
||||
|
||||
|
||||
class MonthlySignInGroupData(BaseModel):
|
||||
class MonthlySignInGroupData(BaseStruct):
|
||||
groupId: str
|
||||
title: str
|
||||
description: str
|
||||
signStartTime: int
|
||||
signEndTime: int
|
||||
items: list[MonthlySignInData]
|
||||
items: List[MonthlySignInData]
|
||||
|
||||
|
||||
class MonthlyDailyBonusGroup(BaseModel):
|
||||
class MonthlyDailyBonusGroup(BaseStruct):
|
||||
groupId: str
|
||||
startTime: int
|
||||
endTime: int
|
||||
items: list[ItemBundle]
|
||||
items: List[ItemBundle]
|
||||
imgId: str
|
||||
backId: str
|
||||
|
||||
|
||||
class CheckinTable(BaseModel):
|
||||
class CheckinTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
groups: dict[str, MonthlySignInGroupData]
|
||||
monthlySubItem: dict[str, list[MonthlyDailyBonusGroup]]
|
||||
groups: Dict[str, MonthlySignInGroupData]
|
||||
monthlySubItem: Dict[str, List[MonthlyDailyBonusGroup]]
|
||||
currentMonthlySubId: str
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
|
@ -1,76 +1,78 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class ClimbTowerSingleTowerDataClimbTowerTaskRewardData(BaseModel):
|
||||
class ClimbTowerSingleTowerDataClimbTowerTaskRewardData(BaseStruct):
|
||||
levelNum: int
|
||||
rewards: list[ItemBundle]
|
||||
rewards: List[ItemBundle]
|
||||
|
||||
|
||||
class ClimbTowerSingleTowerData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ClimbTowerSingleTowerData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
sortId: int
|
||||
stageNum: int
|
||||
name: str
|
||||
subName: str
|
||||
desc: str
|
||||
towerType: str
|
||||
levels: list[str]
|
||||
hardLevels: list[str] | None
|
||||
taskInfo: list[ClimbTowerSingleTowerDataClimbTowerTaskRewardData] | None
|
||||
preTowerId: str | None
|
||||
medalId: str | None
|
||||
hiddenMedalId: str | None
|
||||
hardModeMedalId: str | None
|
||||
bossId: str | None
|
||||
cardId: str | None
|
||||
curseCardIds: list[str]
|
||||
levels: List[str]
|
||||
hardLevels: Union[List[str], None]
|
||||
taskInfo: Union[List[ClimbTowerSingleTowerDataClimbTowerTaskRewardData], None]
|
||||
preTowerId: Union[str, None]
|
||||
medalId: Union[str, None]
|
||||
hiddenMedalId: Union[str, None]
|
||||
hardModeMedalId: Union[str, None]
|
||||
bossId: Union[str, None]
|
||||
cardId: Union[str, None]
|
||||
curseCardIds: List[str]
|
||||
dangerDesc: str
|
||||
hardModeDesc: str | None
|
||||
hardModeDesc: Union[str, None]
|
||||
|
||||
|
||||
class WeightItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
type_: str = Field(alias='type')
|
||||
class WeightItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
type_: str = field(name='type')
|
||||
dropType: str
|
||||
count: int
|
||||
weight: int
|
||||
|
||||
|
||||
class StageDataDisplayRewards(BaseModel):
|
||||
type_: str = Field(alias='type')
|
||||
id_: str = Field(alias='id')
|
||||
class StageDataDisplayRewards(BaseStruct):
|
||||
type_: str = field(name='type')
|
||||
id_: str = field(name='id')
|
||||
dropType: int
|
||||
|
||||
|
||||
class StageDataDisplayDetailRewards(BaseModel):
|
||||
class StageDataDisplayDetailRewards(BaseStruct):
|
||||
occPercent: int
|
||||
type_: str = Field(alias='type')
|
||||
id_: str = Field(alias='id')
|
||||
type_: str = field(name='type')
|
||||
id_: str = field(name='id')
|
||||
dropType: int
|
||||
|
||||
|
||||
class ClimbTowerDropDisplayInfo(BaseModel):
|
||||
class ClimbTowerDropDisplayInfo(BaseStruct):
|
||||
itemId: str
|
||||
type_: int = Field(alias='type')
|
||||
type_: int = field(name='type')
|
||||
maxCount: int
|
||||
minCount: int
|
||||
|
||||
|
||||
class ClimbTowerLevelDropInfo(BaseModel):
|
||||
passRewards: list[list[WeightItemBundle]] | None = None
|
||||
displayRewards: list[StageDataDisplayRewards] | None
|
||||
displayDetailRewards: list[StageDataDisplayDetailRewards] | None
|
||||
displayDropInfo: dict[str, ClimbTowerDropDisplayInfo] | None = None
|
||||
class ClimbTowerLevelDropInfo(BaseStruct):
|
||||
displayRewards: Union[List[StageDataDisplayRewards], None]
|
||||
displayDetailRewards: Union[List[StageDataDisplayDetailRewards], None]
|
||||
passRewards: Union[List[List[WeightItemBundle]], None] = None
|
||||
displayDropInfo: Union[Dict[str, ClimbTowerDropDisplayInfo], None] = None
|
||||
|
||||
|
||||
class ClimbTowerSingleLevelData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ClimbTowerSingleLevelData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
levelId: str
|
||||
towerId: str
|
||||
layerNum: int
|
||||
@ -82,8 +84,8 @@ class ClimbTowerSingleLevelData(BaseModel):
|
||||
dropInfo: ClimbTowerLevelDropInfo
|
||||
|
||||
|
||||
class ClimbTowerTacticalBuffData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ClimbTowerTacticalBuffData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
desc: str
|
||||
profession: str
|
||||
isDefaultActive: bool
|
||||
@ -91,79 +93,80 @@ class ClimbTowerTacticalBuffData(BaseModel):
|
||||
buffType: str
|
||||
|
||||
|
||||
class RuneDataSelector(BaseModel):
|
||||
professionMask: int | str
|
||||
class RuneDataSelector(BaseStruct):
|
||||
professionMask: Union[int, str]
|
||||
buildableMask: int
|
||||
charIdFilter: list[str] | None
|
||||
enemyIdFilter: list[str] | None
|
||||
enemyIdExcludeFilter: list[str] | None
|
||||
skillIdFilter: list[str] | None
|
||||
tileKeyFilter: list[str] | None
|
||||
groupTagFilter: list[str] | None
|
||||
filterTagFilter: list[str] | None
|
||||
charIdFilter: Union[List[str], None]
|
||||
enemyIdFilter: Union[List[str], None]
|
||||
enemyIdExcludeFilter: Union[List[str], None]
|
||||
skillIdFilter: Union[List[str], None]
|
||||
tileKeyFilter: Union[List[str], None]
|
||||
groupTagFilter: Union[List[str], None]
|
||||
filterTagFilter: Union[List[str], None]
|
||||
subProfessionExcludeFilter: Union[List[str], None]
|
||||
|
||||
|
||||
class Blackboard(BaseModel):
|
||||
class Blackboard(BaseStruct):
|
||||
key: str
|
||||
value: float | None = None
|
||||
valueStr: str | None = None
|
||||
value: Union[float, None] = None
|
||||
valueStr: Union[str, None] = None
|
||||
|
||||
|
||||
class RuneData(BaseModel):
|
||||
class RuneData(BaseStruct):
|
||||
key: str
|
||||
selector: RuneDataSelector
|
||||
blackboard: list[Blackboard]
|
||||
blackboard: List[Blackboard]
|
||||
|
||||
|
||||
class RuneTablePackedRuneData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class RuneTablePackedRuneData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
points: float
|
||||
mutexGroupKey: str | None
|
||||
mutexGroupKey: Union[str, None]
|
||||
description: str
|
||||
runes: list[RuneData]
|
||||
runes: List[RuneData]
|
||||
|
||||
|
||||
class ClimbTowerMainCardData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
type_: str = Field(alias='type')
|
||||
linkedTowerId: str | None
|
||||
class ClimbTowerMainCardData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
type_: str = field(name='type')
|
||||
linkedTowerId: Union[str, None]
|
||||
sortId: int
|
||||
name: str
|
||||
desc: str
|
||||
subCardIds: list[str]
|
||||
subCardIds: List[str]
|
||||
runeData: RuneTablePackedRuneData
|
||||
trapIds: list[str]
|
||||
trapIds: List[str]
|
||||
|
||||
|
||||
class ClimbTowerSubCardData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ClimbTowerSubCardData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
mainCardId: str
|
||||
sortId: int
|
||||
name: str
|
||||
desc: str
|
||||
runeData: RuneTablePackedRuneData
|
||||
trapIds: list[str]
|
||||
trapIds: List[str]
|
||||
|
||||
|
||||
class ClimbTowerCurseCardData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
towerIdList: list[str]
|
||||
class ClimbTowerCurseCardData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
towerIdList: List[str]
|
||||
name: str
|
||||
desc: str
|
||||
trapId: str
|
||||
|
||||
|
||||
class ClimbTowerSeasonInfoData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ClimbTowerSeasonInfoData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
name: str
|
||||
startTs: int
|
||||
endTs: int
|
||||
towers: list[str]
|
||||
seasonCards: list[str]
|
||||
towers: List[str]
|
||||
seasonCards: List[str]
|
||||
seasonColor: str
|
||||
|
||||
|
||||
class ClimbTowerDetailConst(BaseModel):
|
||||
class ClimbTowerDetailConst(BaseStruct):
|
||||
unlockLevelId: str
|
||||
unlockModuleNumRequirement: int
|
||||
lowerItemId: str
|
||||
@ -171,7 +174,6 @@ class ClimbTowerDetailConst(BaseModel):
|
||||
higherItemId: str
|
||||
higherItemLimit: int
|
||||
initCharCount: int
|
||||
recruitStageSort: list[int] | None = None
|
||||
charRecruitTimes: int
|
||||
charRecruitChoiceCount: int
|
||||
subcardStageSort: int
|
||||
@ -179,72 +181,70 @@ class ClimbTowerDetailConst(BaseModel):
|
||||
firstClearTaskDesc: str
|
||||
subCardObtainDesc: str
|
||||
subGodCardUnlockDesc: str
|
||||
recruitStageSort: Union[List[int], None] = None
|
||||
|
||||
|
||||
class ClimbTowerRewardInfo(BaseModel):
|
||||
class ClimbTowerRewardInfo(BaseStruct):
|
||||
stageSort: int
|
||||
lowerItemCount: int
|
||||
higherItemCount: int
|
||||
|
||||
|
||||
class MissionDisplayRewards(BaseModel):
|
||||
type_: str = Field(alias='type')
|
||||
id_: str = Field(alias='id')
|
||||
class MissionDisplayRewards(BaseStruct):
|
||||
type_: str = field(name='type')
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
|
||||
|
||||
class MissionData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class MissionData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
sortId: int
|
||||
description: str
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
itemBgType: str
|
||||
preMissionIds: list[str] | None
|
||||
preMissionIds: Union[List[str], None]
|
||||
template: str
|
||||
templateType: str
|
||||
param: list[str]
|
||||
unlockCondition: str | None
|
||||
unlockParam: list[str] | None
|
||||
param: List[str]
|
||||
unlockCondition: Union[str, None]
|
||||
unlockParam: Union[List[str], None]
|
||||
missionGroup: str
|
||||
toPage: str | None
|
||||
toPage: Union[str, None]
|
||||
periodicalPoint: int
|
||||
rewards: list[MissionDisplayRewards] | None
|
||||
backImagePath: str | None
|
||||
foldId: str | None
|
||||
rewards: Union[List[MissionDisplayRewards], None]
|
||||
backImagePath: Union[str, None]
|
||||
foldId: Union[str, None]
|
||||
haveSubMissionToUnlock: bool
|
||||
|
||||
|
||||
class ClimbTowerMissionData(MissionData):
|
||||
bindGodCardId: str | None
|
||||
bindGodCardId: Union[str, None]
|
||||
missionBkg: str
|
||||
|
||||
|
||||
class MissionGroup(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
title: str | None
|
||||
type_: str = Field(alias='type')
|
||||
preMissionGroup: str | None
|
||||
period: list[int] | None
|
||||
rewards: list[MissionDisplayRewards]
|
||||
missionIds: list[str]
|
||||
class MissionGroup(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
title: Union[str, None]
|
||||
type_: str = field(name='type')
|
||||
preMissionGroup: Union[str, None]
|
||||
period: Union[List[int], None]
|
||||
rewards: List[MissionDisplayRewards]
|
||||
missionIds: List[str]
|
||||
startTs: int
|
||||
endTs: int
|
||||
|
||||
|
||||
class ClimbTowerTable(BaseModel):
|
||||
class ClimbTowerTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
towers: dict[str, ClimbTowerSingleTowerData]
|
||||
levels: dict[str, ClimbTowerSingleLevelData]
|
||||
tacticalBuffs: dict[str, ClimbTowerTacticalBuffData]
|
||||
mainCards: dict[str, ClimbTowerMainCardData]
|
||||
subCards: dict[str, ClimbTowerSubCardData]
|
||||
curseCards: dict[str, ClimbTowerCurseCardData]
|
||||
seasonInfos: dict[str, ClimbTowerSeasonInfoData]
|
||||
towers: Dict[str, ClimbTowerSingleTowerData]
|
||||
levels: Dict[str, ClimbTowerSingleLevelData]
|
||||
tacticalBuffs: Dict[str, ClimbTowerTacticalBuffData]
|
||||
mainCards: Dict[str, ClimbTowerMainCardData]
|
||||
subCards: Dict[str, ClimbTowerSubCardData]
|
||||
curseCards: Dict[str, ClimbTowerCurseCardData]
|
||||
seasonInfos: Dict[str, ClimbTowerSeasonInfoData]
|
||||
detailConst: ClimbTowerDetailConst
|
||||
rewardInfoList: list[ClimbTowerRewardInfo]
|
||||
missionData: dict[str, ClimbTowerMissionData]
|
||||
missionGroup: dict[str, MissionGroup]
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
rewardInfoList: List[ClimbTowerRewardInfo]
|
||||
missionData: Dict[str, ClimbTowerMissionData]
|
||||
missionGroup: Dict[str, MissionGroup]
|
||||
|
@ -1,29 +1,30 @@
|
||||
from pydantic import BaseModel
|
||||
from typing import List
|
||||
from ..common import BaseStruct
|
||||
|
||||
|
||||
class MeetingClueDataClueData(BaseModel):
|
||||
class MeetingClueDataClueData(BaseStruct):
|
||||
clueId: str
|
||||
clueName: str
|
||||
clueType: str
|
||||
number: int
|
||||
|
||||
|
||||
class MeetingClueDataClueTypeData(BaseModel):
|
||||
class MeetingClueDataClueTypeData(BaseStruct):
|
||||
clueType: str
|
||||
clueNumber: int
|
||||
|
||||
|
||||
class MeetingClueDataReceiveTimeBonus(BaseModel):
|
||||
class MeetingClueDataReceiveTimeBonus(BaseStruct):
|
||||
receiveTimes: int
|
||||
receiveBonus: int
|
||||
|
||||
|
||||
class ClueData(BaseModel):
|
||||
class ClueData(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
clues: list[MeetingClueDataClueData]
|
||||
clueTypes: list[MeetingClueDataClueTypeData]
|
||||
receiveTimeBonus: list[MeetingClueDataReceiveTimeBonus]
|
||||
clues: List[MeetingClueDataClueData]
|
||||
clueTypes: List[MeetingClueDataClueTypeData]
|
||||
receiveTimeBonus: List[MeetingClueDataReceiveTimeBonus]
|
||||
inventoryLimit: int
|
||||
outputBasicBonus: int
|
||||
outputOperatorsBonus: int
|
||||
@ -35,6 +36,3 @@ class ClueData(BaseModel):
|
||||
communicationDuration: int
|
||||
initiatorBonus: int
|
||||
participantsBonus: int
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
|
@ -1,41 +1,43 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class StringKeyFrames(BaseModel):
|
||||
class StringKeyFrames(BaseStruct):
|
||||
level: int
|
||||
data: str
|
||||
|
||||
|
||||
class CrisisClientDataSeasonInfo(BaseModel):
|
||||
class CrisisClientDataSeasonInfo(BaseStruct):
|
||||
seasonId: str
|
||||
startTs: int
|
||||
endTs: int
|
||||
name: str
|
||||
crisisRuneCoinUnlockItem: ItemBundle
|
||||
permBgm: str
|
||||
medalGroupId: str | None
|
||||
medalGroupId: Union[str, None]
|
||||
bgmHardPoint: int
|
||||
permBgmHard: str | None
|
||||
permBgmHard: Union[str, None]
|
||||
|
||||
|
||||
class CrisisMapRankInfo(BaseModel):
|
||||
rewards: list[ItemBundle]
|
||||
class CrisisMapRankInfo(BaseStruct):
|
||||
rewards: List[ItemBundle]
|
||||
unlockPoint: int
|
||||
|
||||
|
||||
class CrisisTable(BaseModel):
|
||||
class CrisisTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
seasonInfo: list[CrisisClientDataSeasonInfo]
|
||||
tempAppraise: list[StringKeyFrames]
|
||||
permAppraise: list[StringKeyFrames]
|
||||
mapRankInfo: dict[str, CrisisMapRankInfo]
|
||||
seasonInfo: List[CrisisClientDataSeasonInfo]
|
||||
tempAppraise: List[StringKeyFrames]
|
||||
permAppraise: List[StringKeyFrames]
|
||||
mapRankInfo: Dict[str, CrisisMapRankInfo]
|
||||
meta: str
|
||||
unlockCoinLv3: int
|
||||
hardPointPerm: int
|
||||
@ -43,6 +45,3 @@ class CrisisTable(BaseModel):
|
||||
voiceGrade: int
|
||||
crisisRuneCoinUnlockItemTitle: str
|
||||
crisisRuneCoinUnlockItemDesc: str
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
|
@ -1,7 +1,9 @@
|
||||
from pydantic import BaseModel
|
||||
from typing import Dict, List
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class PlayerAvatarPerData(BaseModel):
|
||||
class PlayerAvatarPerData(BaseStruct):
|
||||
avatarId: str
|
||||
avatarType: str
|
||||
avatarIdSort: int
|
||||
@ -12,19 +14,19 @@ class PlayerAvatarPerData(BaseModel):
|
||||
obtainApproach: str
|
||||
|
||||
|
||||
class PlayerAvatarGroupData(BaseModel):
|
||||
class PlayerAvatarGroupData(BaseStruct):
|
||||
avatarType: str
|
||||
typeName: str
|
||||
avatarIdList: list[str]
|
||||
avatarIdList: List[str]
|
||||
|
||||
|
||||
class PlayerAvatarData(BaseModel):
|
||||
class PlayerAvatarData(BaseStruct):
|
||||
defaultAvatarId: str
|
||||
avatarList: list[PlayerAvatarPerData]
|
||||
avatarTypeData: dict[str, PlayerAvatarGroupData]
|
||||
avatarList: List[PlayerAvatarPerData]
|
||||
avatarTypeData: Dict[str, PlayerAvatarGroupData]
|
||||
|
||||
|
||||
class HomeBackgroundSingleData(BaseModel):
|
||||
class HomeBackgroundSingleData(BaseStruct):
|
||||
bgId: str
|
||||
bgType: str
|
||||
bgSortId: int
|
||||
@ -34,20 +36,32 @@ class HomeBackgroundSingleData(BaseModel):
|
||||
bgDes: str
|
||||
bgUsage: str
|
||||
obtainApproach: str
|
||||
unlockDesList: list[str]
|
||||
unlockDesList: List[str]
|
||||
|
||||
|
||||
class HomeBackgroundData(BaseModel):
|
||||
class HomeBackgroundThemeData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
type_: str = field(name='type')
|
||||
sortId: int
|
||||
startTime: int
|
||||
tmName: str
|
||||
tmDes: str
|
||||
tmUsage: str
|
||||
obtainApproach: str
|
||||
unlockDesList: List[str]
|
||||
|
||||
|
||||
class HomeBackgroundData(BaseStruct):
|
||||
defaultBackgroundId: str
|
||||
homeBgDataList: list[HomeBackgroundSingleData]
|
||||
defaultThemeId: str
|
||||
homeBgDataList: List[HomeBackgroundSingleData]
|
||||
themeList: List[HomeBackgroundThemeData]
|
||||
defaultBgMusicId: str
|
||||
themeStartTime: int
|
||||
|
||||
|
||||
class DisplayMetaTable(BaseModel):
|
||||
class DisplayMetaTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
playerAvatarData: PlayerAvatarData
|
||||
homeBackgroundData: HomeBackgroundData
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
|
@ -1,57 +1,59 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class EnemyHandBookDataAbilty(BaseModel):
|
||||
class EnemyHandBookDataAbilty(BaseStruct):
|
||||
text: str
|
||||
textFormat: str
|
||||
|
||||
|
||||
class EnemyHandBookData(BaseModel):
|
||||
class EnemyHandBookData(BaseStruct):
|
||||
enemyId: str
|
||||
enemyIndex: str
|
||||
enemyTags: list[str] | None
|
||||
enemyTags: Union[List[str], None]
|
||||
sortId: int
|
||||
name: str
|
||||
enemyLevel: str
|
||||
description: str
|
||||
attackType: str | None
|
||||
ability: str | None
|
||||
attackType: Union[str, None]
|
||||
ability: Union[str, None]
|
||||
isInvalidKilled: bool
|
||||
overrideKillCntInfos: dict[str, int]
|
||||
overrideKillCntInfos: Dict[str, int]
|
||||
hideInHandbook: bool
|
||||
abilityList: list[EnemyHandBookDataAbilty] | None
|
||||
linkEnemies: list[str] | None
|
||||
damageType: list[str] | None
|
||||
abilityList: Union[List[EnemyHandBookDataAbilty], None]
|
||||
linkEnemies: Union[List[str], None]
|
||||
damageType: Union[List[str], None]
|
||||
invisibleDetail: bool
|
||||
hideInStage: Union[bool, None] = None
|
||||
|
||||
|
||||
class EnemyHandbookLevelInfoDataRangePair(BaseModel):
|
||||
min_: float = Field(alias='min')
|
||||
max_: float = Field(alias='max')
|
||||
class EnemyHandbookLevelInfoDataRangePair(BaseStruct):
|
||||
min_: float = field(name='min')
|
||||
max_: float = field(name='max')
|
||||
|
||||
|
||||
class EnemyHandbookLevelInfoData(BaseModel):
|
||||
class EnemyHandbookLevelInfoData(BaseStruct):
|
||||
classLevel: str
|
||||
attack: EnemyHandbookLevelInfoDataRangePair
|
||||
def_: EnemyHandbookLevelInfoDataRangePair = Field(alias='def')
|
||||
def_: EnemyHandbookLevelInfoDataRangePair = field(name='def')
|
||||
magicRes: EnemyHandbookLevelInfoDataRangePair
|
||||
maxHP: EnemyHandbookLevelInfoDataRangePair
|
||||
moveSpeed: EnemyHandbookLevelInfoDataRangePair
|
||||
attackSpeed: EnemyHandbookLevelInfoDataRangePair
|
||||
enemyDamageRes: EnemyHandbookLevelInfoDataRangePair
|
||||
enemyRes: EnemyHandbookLevelInfoDataRangePair
|
||||
|
||||
|
||||
class EnemyHandbookRaceData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class EnemyHandbookRaceData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
raceName: str
|
||||
sortId: int
|
||||
|
||||
|
||||
class EnemyHandbookTable(BaseModel):
|
||||
class EnemyHandbookTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
levelInfoList: list[EnemyHandbookLevelInfoData]
|
||||
enemyData: dict[str, EnemyHandBookData]
|
||||
raceData: dict[str, EnemyHandbookRaceData]
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
levelInfoList: List[EnemyHandbookLevelInfoData]
|
||||
enemyData: Dict[str, EnemyHandBookData]
|
||||
raceData: Dict[str, EnemyHandbookRaceData]
|
||||
|
@ -1,19 +1,20 @@
|
||||
from pydantic import BaseModel
|
||||
from typing import List
|
||||
from ..common import BaseStruct
|
||||
|
||||
|
||||
class FavorData(BaseModel):
|
||||
class FavorData(BaseStruct):
|
||||
favorPoint: int
|
||||
percent: int
|
||||
battlePhase: int
|
||||
|
||||
|
||||
class FavorDataFrames(BaseModel):
|
||||
class FavorDataFrames(BaseStruct):
|
||||
level: int
|
||||
data: FavorData
|
||||
|
||||
|
||||
class FavorTable(BaseModel):
|
||||
class FavorTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
maxFavor: int
|
||||
favorFrames: list[FavorDataFrames]
|
||||
favorFrames: List[FavorDataFrames]
|
||||
|
@ -1,25 +1,27 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class GachaDataLinkageTenGachaTkt(BaseModel):
|
||||
class GachaDataLinkageTenGachaTkt(BaseStruct):
|
||||
itemId: str
|
||||
endTime: int
|
||||
gachaPoolId: str
|
||||
|
||||
|
||||
class GachaDataLimitTenGachaTkt(BaseModel):
|
||||
class GachaDataLimitTenGachaTkt(BaseStruct):
|
||||
itemId: str
|
||||
endTime: int
|
||||
|
||||
|
||||
class GachaDataFreeLimitGachaData(BaseModel):
|
||||
class GachaDataFreeLimitGachaData(BaseStruct):
|
||||
poolId: str
|
||||
openTime: int
|
||||
endTime: int
|
||||
freeCount: int
|
||||
|
||||
|
||||
class GachaDataCarouselData(BaseModel):
|
||||
class GachaDataCarouselData(BaseStruct):
|
||||
poolId: str
|
||||
index: int
|
||||
startTime: int
|
||||
@ -27,127 +29,124 @@ class GachaDataCarouselData(BaseModel):
|
||||
spriteId: str
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class GachaDataRecruitRange(BaseModel):
|
||||
class GachaDataRecruitRange(BaseStruct):
|
||||
rarityStart: int
|
||||
rarityEnd: int
|
||||
|
||||
|
||||
class PotentialMaterialConverterConfig(BaseModel):
|
||||
items: dict[str, ItemBundle]
|
||||
class PotentialMaterialConverterConfig(BaseStruct):
|
||||
items: Dict[str, ItemBundle]
|
||||
|
||||
|
||||
class RecruitPoolRecruitTime(BaseModel):
|
||||
class RecruitPoolRecruitTime(BaseStruct):
|
||||
timeLength: int
|
||||
recruitPrice: int
|
||||
accumRate: float | None = None
|
||||
accumRate: Union[float, None] = None
|
||||
|
||||
|
||||
class RecruitConstantsData(BaseModel):
|
||||
rarityWeights: None = None
|
||||
tagPriceList: dict[str, int]
|
||||
recruitTimeFactorList: None = None
|
||||
class RecruitConstantsData(BaseStruct):
|
||||
tagPriceList: Dict[str, int]
|
||||
maxRecruitTime: int
|
||||
rarityWeights: None = None
|
||||
recruitTimeFactorList: None = None
|
||||
|
||||
|
||||
class RecruitPool(BaseModel):
|
||||
recruitTimeTable: list[RecruitPoolRecruitTime]
|
||||
recruitCharacterList: None = None
|
||||
class RecruitPool(BaseStruct):
|
||||
recruitTimeTable: List[RecruitPoolRecruitTime]
|
||||
recruitConstants: RecruitConstantsData
|
||||
recruitCharacterList: None = None
|
||||
maskTypeWeightTable: None = None
|
||||
|
||||
|
||||
class NewbeeGachaPoolClientData(BaseModel):
|
||||
class NewbeeGachaPoolClientData(BaseStruct):
|
||||
gachaPoolId: str
|
||||
gachaIndex: int
|
||||
gachaPoolName: str
|
||||
gachaPoolDetail: str
|
||||
gachaPrice: int
|
||||
gachaTimes: int
|
||||
gachaOffset: str | None = None
|
||||
firstOpenDay: int | None = None
|
||||
reOpenDay: int | None = None
|
||||
gachaOffset: Union[str, None] = None
|
||||
firstOpenDay: Union[int, None] = None
|
||||
reOpenDay: Union[int, None] = None
|
||||
gachaPoolItems: None = None
|
||||
signUpEarliestTime: int | None = None
|
||||
signUpEarliestTime: Union[int, None] = None
|
||||
|
||||
|
||||
class GachaPoolClientData(BaseModel):
|
||||
CDPrimColor: str | None
|
||||
CDSecColor: str | None
|
||||
dynMeta: dict[str, object] | None = None
|
||||
class GachaPoolClientData(BaseStruct):
|
||||
CDPrimColor: Union[str, None]
|
||||
CDSecColor: Union[str, None]
|
||||
endTime: int
|
||||
gachaIndex: int
|
||||
gachaPoolDetail: str | None
|
||||
gachaPoolDetail: Union[str, None]
|
||||
gachaPoolId: str
|
||||
gachaPoolName: str
|
||||
gachaPoolSummary: str
|
||||
gachaRuleType: str
|
||||
guarantee5Avail: int
|
||||
guarantee5Count: int
|
||||
linkageParam: dict[str, object] | None = None
|
||||
linkageRuleId: str | None = None
|
||||
LMTGSID: str | None
|
||||
LMTGSID: Union[str, None]
|
||||
openTime: int
|
||||
dynMeta: Union[Dict[str, object], None, None] = None
|
||||
linkageParam: Union[Dict[str, object], None, None] = None
|
||||
linkageRuleId: Union[str, None] = None
|
||||
|
||||
|
||||
class GachaTag(BaseModel):
|
||||
class GachaTag(BaseStruct):
|
||||
tagId: int
|
||||
tagName: str
|
||||
tagGroup: int
|
||||
|
||||
|
||||
class SpecialRecruitPoolSpecialRecruitCostData(BaseModel):
|
||||
class SpecialRecruitPoolSpecialRecruitCostData(BaseStruct):
|
||||
itemCosts: ItemBundle
|
||||
recruitPrice: int
|
||||
timeLength: int
|
||||
|
||||
|
||||
class SpecialRecruitPool(BaseModel):
|
||||
class SpecialRecruitPool(BaseStruct):
|
||||
endDateTime: int
|
||||
order: int
|
||||
recruitId: str
|
||||
recruitTimeTable: list[SpecialRecruitPoolSpecialRecruitCostData]
|
||||
recruitTimeTable: List[SpecialRecruitPoolSpecialRecruitCostData]
|
||||
startDateTime: int
|
||||
tagId: int
|
||||
tagName: str
|
||||
CDPrimColor: str | None
|
||||
CDSecColor: str | None
|
||||
LMTGSID: str | None
|
||||
CDPrimColor: Union[str, None]
|
||||
CDSecColor: Union[str, None]
|
||||
LMTGSID: Union[str, None]
|
||||
gachaRuleType: str
|
||||
|
||||
|
||||
class GachaDataFesGachaPoolRelateItem(BaseModel):
|
||||
class GachaDataFesGachaPoolRelateItem(BaseStruct):
|
||||
rarityRank5ItemId: str
|
||||
rarityRank6ItemId: str
|
||||
|
||||
|
||||
class GachaTable(BaseModel):
|
||||
class GachaTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
gachaTags: list[GachaTag]
|
||||
carousel: list[GachaDataCarouselData]
|
||||
gachaTags: List[GachaTag]
|
||||
carousel: List[GachaDataCarouselData]
|
||||
classicPotentialMaterialConverter: PotentialMaterialConverterConfig
|
||||
dicRecruit6StarHint: dict[str, str] | None
|
||||
fesGachaPoolRelateItem: dict[str, GachaDataFesGachaPoolRelateItem] | None
|
||||
freeGacha: list[GachaDataFreeLimitGachaData]
|
||||
gachaPoolClient: list[GachaPoolClientData]
|
||||
gachaTagMaxValid: int | None = None
|
||||
limitTenGachaItem: list[GachaDataLimitTenGachaTkt]
|
||||
linkageTenGachaItem: list[GachaDataLinkageTenGachaTkt]
|
||||
newbeeGachaPoolClient: list[NewbeeGachaPoolClientData]
|
||||
dicRecruit6StarHint: Union[Dict[str, str], None]
|
||||
fesGachaPoolRelateItem: Union[Dict[str, GachaDataFesGachaPoolRelateItem], None]
|
||||
freeGacha: List[GachaDataFreeLimitGachaData]
|
||||
gachaPoolClient: List[GachaPoolClientData]
|
||||
limitTenGachaItem: List[GachaDataLimitTenGachaTkt]
|
||||
linkageTenGachaItem: List[GachaDataLinkageTenGachaTkt]
|
||||
newbeeGachaPoolClient: List[NewbeeGachaPoolClientData]
|
||||
potentialMaterialConverter: PotentialMaterialConverterConfig
|
||||
recruitDetail: str
|
||||
recruitPool: RecruitPool
|
||||
recruitRarityTable: dict[str, GachaDataRecruitRange]
|
||||
specialRecruitPool: list[SpecialRecruitPool]
|
||||
specialTagRarityTable: dict[str, list[int]]
|
||||
potentialMats: dict | None = None
|
||||
classicPotentialMats: dict | None = None
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
recruitRarityTable: Dict[str, GachaDataRecruitRange]
|
||||
specialRecruitPool: List[SpecialRecruitPool]
|
||||
specialTagRarityTable: Dict[str, List[int]]
|
||||
gachaTagMaxValid: Union[int, None] = None
|
||||
potentialMats: Union[Dict, None] = None
|
||||
classicPotentialMats: Union[Dict, None] = None
|
||||
|
@ -1,24 +1,27 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
from msgspec import json as msgjson
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class GameDataConstsCharAssistRefreshTimeState(BaseModel):
|
||||
class GameDataConstsCharAssistRefreshTimeState(BaseStruct):
|
||||
Hour: int
|
||||
Minute: int
|
||||
|
||||
|
||||
class TermDescriptionData(BaseModel):
|
||||
class TermDescriptionData(BaseStruct):
|
||||
termId: str
|
||||
termName: str
|
||||
description: str
|
||||
|
||||
|
||||
class GamedataConst(BaseModel):
|
||||
class GamedataConst(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
addedRewardDisplayZone: str
|
||||
@ -26,13 +29,13 @@ class GamedataConst(BaseModel):
|
||||
announceWebBusType: str
|
||||
apBuyCost: int
|
||||
apBuyThreshold: int
|
||||
assistBeUsedSocialPt: dict[str, int]
|
||||
assistBeUsedSocialPt: Dict[str, int]
|
||||
attackMax: float
|
||||
baseMaxFriendNum: int
|
||||
buyApTimeNoLimitFlag: bool
|
||||
characterExpMap: list[list[int]]
|
||||
characterUpgradeCostMap: list[list[int]]
|
||||
charAssistRefreshTime: list[GameDataConstsCharAssistRefreshTimeState]
|
||||
characterExpMap: List[List[int]]
|
||||
characterUpgradeCostMap: List[List[int]]
|
||||
charAssistRefreshTime: List[GameDataConstsCharAssistRefreshTimeState]
|
||||
charmEquipCount: int
|
||||
commonPotentialLvlUpCount: int
|
||||
completeCrystalBonus: int
|
||||
@ -46,15 +49,15 @@ class GamedataConst(BaseModel):
|
||||
diamondMaterialToShardExchangeRatio: int
|
||||
diamondToShdRate: int
|
||||
easyCrystalBonus: int
|
||||
evolveGoldCost: list[list[int]]
|
||||
friendAssistRarityLimit: list[int]
|
||||
evolveGoldCost: List[List[int]]
|
||||
friendAssistRarityLimit: List[int]
|
||||
hardDiamondDrop: int
|
||||
hpMax: float
|
||||
initCampaignTotalFee: int
|
||||
initCharIdList: list[str]
|
||||
initCharIdList: List[str]
|
||||
initPlayerDiamondShard: int
|
||||
initPlayerGold: int
|
||||
initRecruitTagList: list[int]
|
||||
initRecruitTagList: List[int]
|
||||
instFinDmdShdCost: int
|
||||
isClassicGachaPoolFuncEnabled: bool
|
||||
isClassicPotentialItemFuncEnabled: bool
|
||||
@ -64,33 +67,31 @@ class GamedataConst(BaseModel):
|
||||
isLMGTSEnabled: bool
|
||||
isRoguelikeAvgAchieveFuncEnabled: bool
|
||||
isRoguelikeTopicFuncEnabled: bool
|
||||
isVoucherClassicItemDistinguishable: bool | None = None
|
||||
legacyItemList: list[ItemBundle]
|
||||
legacyItemList: List[ItemBundle]
|
||||
legacyTime: int
|
||||
lMTGSDescConstOne: str
|
||||
lMTGSDescConstTwo: str
|
||||
LMTGSToEPGSRatio: int
|
||||
mailBannerType: list[str]
|
||||
mailBannerType: List[str]
|
||||
mainlineCompatibleDesc: str
|
||||
mainlineEasyDesc: str
|
||||
mainlineNormalDesc: str
|
||||
mainlineToughDesc: str
|
||||
maxLevel: list[list[int]]
|
||||
maxLevel: List[List[int]]
|
||||
maxPlayerLevel: int
|
||||
maxPracticeTicket: int
|
||||
monthlySubRemainTimeLimitDays: int
|
||||
monthlySubWarningTime: int
|
||||
multiInComeByRank: list[str]
|
||||
multiInComeByRank: List[str]
|
||||
newBeeGiftEPGS: int
|
||||
normalGachaUnlockPrice: list[int]
|
||||
normalRecruitLockedString: list[str]
|
||||
operatorRecordsStartTime: int | None = None
|
||||
playerApMap: list[int]
|
||||
normalGachaUnlockPrice: List[int]
|
||||
normalRecruitLockedString: List[str]
|
||||
playerApMap: List[int]
|
||||
playerApRegenSpeed: int
|
||||
playerExpMap: list[int]
|
||||
pullForces: list[float]
|
||||
playerExpMap: List[int]
|
||||
pullForces: List[float]
|
||||
pullForceZeroIndex: int
|
||||
pushForces: list[float]
|
||||
pushForces: List[float]
|
||||
pushForceZeroIndex: int
|
||||
recruitPoolVersion: int
|
||||
rejectSpCharMission: int
|
||||
@ -98,10 +99,9 @@ class GamedataConst(BaseModel):
|
||||
replicateShopStartTime: int
|
||||
requestSameFriendCD: int
|
||||
resPrefVersion: str
|
||||
richTextStyles: dict[str, str]
|
||||
richTextStyles: Dict[str, str]
|
||||
storyReviewUnlockItemLackTip: str
|
||||
subProfessionDamageTypePairs: dict[str, int] | None = None
|
||||
termDescriptionDict: dict[str, TermDescriptionData]
|
||||
termDescriptionDict: Dict[str, TermDescriptionData]
|
||||
UnlimitSkinOutOfTime: int
|
||||
useAssistSocialPt: int
|
||||
useAssistSocialPtMaxCount: int
|
||||
@ -113,6 +113,6 @@ class GamedataConst(BaseModel):
|
||||
voucherSkinRedeem: int
|
||||
weeklyOverrideDesc: str
|
||||
TSO: int
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
isVoucherClassicItemDistinguishable: Union[bool, None] = None
|
||||
operatorRecordsStartTime: Union[int, None] = None
|
||||
subProfessionDamageTypePairs: Union[Dict[str, int], None] = None
|
||||
|
@ -1,25 +1,27 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class HandbookUnlockParam(BaseModel):
|
||||
class HandbookUnlockParam(BaseStruct):
|
||||
unlockType: int
|
||||
unlockParam1: str
|
||||
unlockParam2: str | None
|
||||
unlockParam3: str | None
|
||||
unlockParam2: Union[str, None]
|
||||
unlockParam3: Union[str, None]
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class HandbookStageTimeData(BaseModel):
|
||||
class HandbookStageTimeData(BaseStruct):
|
||||
timestamp: int
|
||||
charSet: list[str]
|
||||
charSet: List[str]
|
||||
|
||||
|
||||
class HandbookStoryStageData(BaseModel):
|
||||
class HandbookStoryStageData(BaseStruct):
|
||||
charId: str
|
||||
code: str
|
||||
description: str
|
||||
@ -27,23 +29,23 @@ class HandbookStoryStageData(BaseModel):
|
||||
loadingPicId: str
|
||||
name: str
|
||||
picId: str
|
||||
rewardItem: list[ItemBundle]
|
||||
rewardItem: List[ItemBundle]
|
||||
stageGetTime: int
|
||||
stageId: str
|
||||
stageNameForShow: str
|
||||
unlockParam: list[HandbookUnlockParam]
|
||||
unlockParam: List[HandbookUnlockParam]
|
||||
zoneId: str
|
||||
zoneNameForShow: str
|
||||
|
||||
|
||||
class HandbookDisplayCondition(BaseModel):
|
||||
class HandbookDisplayCondition(BaseStruct):
|
||||
charId: str
|
||||
conditionCharId: str
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class HandbookTeamMission(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class HandbookTeamMission(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
sort: int
|
||||
powerId: str
|
||||
powerName: str
|
||||
@ -51,19 +53,19 @@ class HandbookTeamMission(BaseModel):
|
||||
favorPoint: int
|
||||
|
||||
|
||||
class NPCUnlock(BaseModel):
|
||||
class NPCUnlock(BaseStruct):
|
||||
unLockType: int
|
||||
unLockParam: str
|
||||
unLockString: str | None = None
|
||||
unLockString: Union[str, None] = None
|
||||
|
||||
|
||||
class NPCData(BaseModel):
|
||||
class NPCData(BaseStruct):
|
||||
appellation: str
|
||||
cv: str
|
||||
designerList: list[str] | None
|
||||
designerList: Union[List[str], None]
|
||||
displayNumber: str
|
||||
groupId: str | None
|
||||
illustList: list[str]
|
||||
groupId: Union[str, None]
|
||||
illustList: List[str]
|
||||
name: str
|
||||
nationId: str
|
||||
npcId: str
|
||||
@ -71,11 +73,11 @@ class NPCData(BaseModel):
|
||||
profession: str
|
||||
resType: str
|
||||
teamId: None
|
||||
unlockDict: dict[str, NPCUnlock]
|
||||
unlockDict: Dict[str, NPCUnlock]
|
||||
minPowerId: str
|
||||
|
||||
|
||||
class HandbookAvgData(BaseModel):
|
||||
class HandbookAvgData(BaseStruct):
|
||||
storyId: str
|
||||
storySetId: str
|
||||
storySort: int
|
||||
@ -85,47 +87,44 @@ class HandbookAvgData(BaseModel):
|
||||
storyTxt: str
|
||||
|
||||
|
||||
class HandbookAvgGroupData(BaseModel):
|
||||
class HandbookAvgGroupData(BaseStruct):
|
||||
storySetId: str
|
||||
storySetName: str
|
||||
sortId: int
|
||||
storyGetTime: int
|
||||
rewardItem: list[ItemBundle]
|
||||
unlockParam: list[HandbookUnlockParam]
|
||||
avgList: list[HandbookAvgData]
|
||||
rewardItem: List[ItemBundle]
|
||||
unlockParam: List[HandbookUnlockParam]
|
||||
avgList: List[HandbookAvgData]
|
||||
charId: str
|
||||
|
||||
|
||||
class HandbookStoryData(BaseModel):
|
||||
class HandbookStoryData(BaseStruct):
|
||||
storyText: str
|
||||
unLockType: int
|
||||
unLockParam: str
|
||||
unLockString: str
|
||||
|
||||
|
||||
class HandBookStoryViewData(BaseModel):
|
||||
stories: list[HandbookStoryData]
|
||||
class HandBookStoryViewData(BaseStruct):
|
||||
stories: List[HandbookStoryData]
|
||||
storyTitle: str
|
||||
unLockorNot: bool
|
||||
|
||||
|
||||
class HandbookInfoData(BaseModel):
|
||||
class HandbookInfoData(BaseStruct):
|
||||
charID: str
|
||||
infoName: str
|
||||
storyTextAudio: list[HandBookStoryViewData]
|
||||
handbookAvgList: list[HandbookAvgGroupData]
|
||||
isLimited: bool | None = None
|
||||
storyTextAudio: List[HandBookStoryViewData]
|
||||
handbookAvgList: List[HandbookAvgGroupData]
|
||||
isLimited: Union[bool, None] = None
|
||||
|
||||
|
||||
class HandbookInfoTable(BaseModel):
|
||||
class HandbookInfoTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
handbookDict: dict[str, HandbookInfoData]
|
||||
npcDict: dict[str, NPCData]
|
||||
teamMissionList: dict[str, HandbookTeamMission]
|
||||
handbookDisplayConditionList: dict[str, HandbookDisplayCondition]
|
||||
handbookStageData: dict[str, HandbookStoryStageData]
|
||||
handbookStageTime: list[HandbookStageTimeData]
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
handbookDict: Dict[str, HandbookInfoData]
|
||||
npcDict: Dict[str, NPCData]
|
||||
teamMissionList: Dict[str, HandbookTeamMission]
|
||||
handbookDisplayConditionList: Dict[str, HandbookDisplayCondition]
|
||||
handbookStageData: Dict[str, HandbookStoryStageData]
|
||||
handbookStageTime: List[HandbookStageTimeData]
|
||||
|
@ -1,26 +1,27 @@
|
||||
from pydantic import BaseModel
|
||||
from typing import List, Union
|
||||
from ..common import BaseStruct
|
||||
|
||||
|
||||
class HandBookInfoTextViewDataInfoTextAudio(BaseModel):
|
||||
class HandBookInfoTextViewDataInfoTextAudio(BaseStruct):
|
||||
infoText: str
|
||||
audioName: str
|
||||
|
||||
|
||||
class StoryTextAudioInfoListItem(BaseModel):
|
||||
storyText: str | None
|
||||
storyTitle: str | None
|
||||
class StoryTextAudioInfoListItem(BaseStruct):
|
||||
storyText: Union[str, None]
|
||||
storyTitle: Union[str, None]
|
||||
|
||||
|
||||
class StoryTextAudioItem(BaseModel):
|
||||
stories: list[StoryTextAudioInfoListItem]
|
||||
class StoryTextAudioItem(BaseStruct):
|
||||
stories: List[StoryTextAudioInfoListItem]
|
||||
unLockorNot: bool
|
||||
unLockType: int
|
||||
unLockParam: str
|
||||
unLockString: str
|
||||
|
||||
|
||||
class HandBookInfoTextViewData(BaseModel):
|
||||
infoList: list[HandBookInfoTextViewDataInfoTextAudio]
|
||||
class HandBookInfoTextViewData(BaseStruct):
|
||||
infoList: List[HandBookInfoTextViewDataInfoTextAudio]
|
||||
unLockorNot: bool
|
||||
unLockType: int
|
||||
unLockParam: str
|
||||
@ -29,15 +30,15 @@ class HandBookInfoTextViewData(BaseModel):
|
||||
unLockString: str
|
||||
|
||||
|
||||
class CharHandbook(BaseModel):
|
||||
class CharHandbook(BaseStruct):
|
||||
charID: str
|
||||
drawName: str
|
||||
infoName: str
|
||||
infoTextAudio: list[HandBookInfoTextViewData]
|
||||
storyTextAudio: list[StoryTextAudioItem]
|
||||
infoTextAudio: List[HandBookInfoTextViewData]
|
||||
storyTextAudio: List[StoryTextAudioItem]
|
||||
|
||||
|
||||
class HandbookTable(BaseModel):
|
||||
class HandbookTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
char_102_texas: CharHandbook
|
||||
|
@ -1,7 +1,9 @@
|
||||
from pydantic import BaseModel
|
||||
from typing import Dict
|
||||
from ..common import BaseStruct
|
||||
from msgspec import json as msgjson
|
||||
|
||||
|
||||
class HandbookTeam(BaseModel):
|
||||
class HandbookTeam(BaseStruct):
|
||||
powerId: str
|
||||
orderNum: int
|
||||
powerLevel: int
|
||||
@ -12,10 +14,7 @@ class HandbookTeam(BaseModel):
|
||||
isRaw: bool
|
||||
|
||||
|
||||
class HandbookTeamTable(BaseModel):
|
||||
class HandbookTeamTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
team: dict[str, HandbookTeam]
|
||||
|
||||
def __init__(self, **data):
|
||||
super().__init__(team=data)
|
||||
team: Dict[str, HandbookTeam]
|
||||
|
@ -1,107 +1,107 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class ItemDataStageDropInfo(BaseModel):
|
||||
class ItemDataStageDropInfo(BaseStruct):
|
||||
stageId: str
|
||||
occPer: str
|
||||
|
||||
|
||||
class ItemDataBuildingProductInfo(BaseModel):
|
||||
class ItemDataBuildingProductInfo(BaseStruct):
|
||||
roomType: str
|
||||
formulaId: str
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class FavorCharacterInfo(BaseModel):
|
||||
class FavorCharacterInfo(BaseStruct):
|
||||
itemId: str
|
||||
charId: str
|
||||
favorAddAmt: int
|
||||
|
||||
|
||||
class ActivityPotentialCharacterInfo(BaseModel):
|
||||
class ActivityPotentialCharacterInfo(BaseStruct):
|
||||
charId: str
|
||||
|
||||
|
||||
class FullPotentialCharacterInfo(BaseModel):
|
||||
class FullPotentialCharacterInfo(BaseStruct):
|
||||
itemId: str
|
||||
ts: int
|
||||
|
||||
|
||||
class ItemPackInfo(BaseModel):
|
||||
class ItemPackInfo(BaseStruct):
|
||||
packId: str
|
||||
content: list[ItemBundle]
|
||||
content: List[ItemBundle]
|
||||
|
||||
|
||||
class UniCollectionInfo(BaseModel):
|
||||
class UniCollectionInfo(BaseStruct):
|
||||
uniCollectionItemId: str
|
||||
uniqueItem: list[ItemBundle]
|
||||
uniqueItem: List[ItemBundle]
|
||||
|
||||
|
||||
class ApSupplyFeature(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ApSupplyFeature(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
ap: int
|
||||
hasTs: bool
|
||||
|
||||
|
||||
class ExpItemFeature(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ExpItemFeature(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
gainExp: int
|
||||
|
||||
|
||||
class ItemData(BaseModel):
|
||||
class ItemData(BaseStruct):
|
||||
itemId: str
|
||||
name: str
|
||||
description: str | None
|
||||
description: Union[str, None]
|
||||
rarity: int
|
||||
iconId: str
|
||||
overrideBkg: None
|
||||
stackIconId: str | None
|
||||
stackIconId: Union[str, None]
|
||||
sortId: int
|
||||
usage: str | None
|
||||
obtainApproach: str | None
|
||||
usage: Union[str, None]
|
||||
obtainApproach: Union[str, None]
|
||||
classifyType: str
|
||||
itemType: str
|
||||
stageDropList: list[ItemDataStageDropInfo]
|
||||
buildingProductList: list[ItemDataBuildingProductInfo]
|
||||
stageDropList: List[ItemDataStageDropInfo]
|
||||
buildingProductList: List[ItemDataBuildingProductInfo]
|
||||
hideInItemGet: Union[bool, None] = None
|
||||
|
||||
|
||||
class CharVoucherItemFeature(BaseModel):
|
||||
class CharVoucherItemFeature(BaseStruct):
|
||||
displayType: int
|
||||
id_: str = Field(alias='id')
|
||||
id_: str = field(name='id')
|
||||
|
||||
|
||||
class ServerItemReminderMailData(BaseModel):
|
||||
class ServerItemReminderMailData(BaseStruct):
|
||||
content: str
|
||||
sender: str
|
||||
title: str
|
||||
|
||||
|
||||
class ServerItemReminderInfo(BaseModel):
|
||||
paidItemIdList: list[str]
|
||||
class ServerItemReminderInfo(BaseStruct):
|
||||
paidItemIdList: List[str]
|
||||
paidReminderMail: ServerItemReminderMailData
|
||||
|
||||
|
||||
class ItemTable(BaseModel):
|
||||
class ItemTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
activityPotentialCharacters: dict[str, ActivityPotentialCharacterInfo]
|
||||
apSupplies: dict[str, ApSupplyFeature]
|
||||
charVoucherItems: dict[str, CharVoucherItemFeature] | None = None
|
||||
expItems: dict[str, ExpItemFeature]
|
||||
favorCharacters: dict[str, FavorCharacterInfo]
|
||||
fullPotentialCharacters: dict[str, FullPotentialCharacterInfo]
|
||||
itemPackInfos: dict[str, ItemPackInfo]
|
||||
items: dict[str, ItemData]
|
||||
itemTimeLimit: dict[str, int]
|
||||
potentialItems: dict[str, dict[str, str]]
|
||||
reminderInfo: ServerItemReminderInfo | None = None
|
||||
uniCollectionInfo: dict[str, UniCollectionInfo]
|
||||
uniqueInfo: dict[str, int]
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
activityPotentialCharacters: Dict[str, ActivityPotentialCharacterInfo]
|
||||
apSupplies: Dict[str, ApSupplyFeature]
|
||||
expItems: Dict[str, ExpItemFeature]
|
||||
favorCharacters: Dict[str, FavorCharacterInfo]
|
||||
fullPotentialCharacters: Dict[str, FullPotentialCharacterInfo]
|
||||
itemPackInfos: Dict[str, ItemPackInfo]
|
||||
items: Dict[str, ItemData]
|
||||
itemTimeLimit: Dict[str, int]
|
||||
potentialItems: Dict[str, Dict[str, str]]
|
||||
uniCollectionInfo: Dict[str, UniCollectionInfo]
|
||||
uniqueInfo: Dict[str, int]
|
||||
reminderInfo: Union[ServerItemReminderInfo, None] = None
|
||||
charVoucherItems: Union[Dict[str, CharVoucherItemFeature], None] = None
|
||||
|
@ -1,65 +1,65 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class MedalExpireTime(BaseModel):
|
||||
class MedalExpireTime(BaseStruct):
|
||||
start: int
|
||||
end: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class MedalGroupData(BaseModel):
|
||||
class MedalGroupData(BaseStruct):
|
||||
groupId: str
|
||||
groupName: str
|
||||
groupDesc: str
|
||||
medalId: list[str]
|
||||
medalId: List[str]
|
||||
sortId: int
|
||||
groupBackColor: str
|
||||
groupGetTime: int
|
||||
sharedExpireTimes: list[MedalExpireTime] | None
|
||||
sharedExpireTimes: Union[List[MedalExpireTime], None]
|
||||
|
||||
|
||||
class MedalRewardGroupData(BaseModel):
|
||||
class MedalRewardGroupData(BaseStruct):
|
||||
groupId: str
|
||||
slotId: int
|
||||
itemList: list[ItemBundle]
|
||||
itemList: List[ItemBundle]
|
||||
|
||||
|
||||
class MedalTypeData(BaseModel):
|
||||
class MedalTypeData(BaseStruct):
|
||||
medalGroupId: str
|
||||
sortId: int
|
||||
medalName: str
|
||||
groupData: list[MedalGroupData]
|
||||
groupData: List[MedalGroupData]
|
||||
|
||||
|
||||
class MedalPerData(BaseModel):
|
||||
medalId: str | None
|
||||
medalName: str | None
|
||||
medalType: str | None
|
||||
slotId: int | None
|
||||
preMedalIdList: list[str] | None
|
||||
class MedalPerData(BaseStruct):
|
||||
medalId: Union[str, None]
|
||||
medalName: Union[str, None]
|
||||
medalType: Union[str, None]
|
||||
slotId: Union[int, None]
|
||||
preMedalIdList: Union[List[str], None]
|
||||
rarity: int
|
||||
template: str | None
|
||||
unlockParam: list[str]
|
||||
getMethod: str | None
|
||||
description: str | None
|
||||
advancedMedal: str | None
|
||||
originMedal: str | None
|
||||
template: Union[str, None]
|
||||
unlockParam: List[str]
|
||||
getMethod: Union[str, None]
|
||||
description: Union[str, None]
|
||||
advancedMedal: Union[str, None]
|
||||
originMedal: Union[str, None]
|
||||
displayTime: int
|
||||
expireTimes: list[MedalExpireTime]
|
||||
medalRewardGroup: list[MedalRewardGroupData]
|
||||
expireTimes: List[MedalExpireTime]
|
||||
medalRewardGroup: List[MedalRewardGroupData]
|
||||
isHidden: Union[bool, None] = None
|
||||
|
||||
|
||||
class MedalTable(BaseModel):
|
||||
class MedalTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
medalList: list[MedalPerData]
|
||||
medalTypeData: dict[str, MedalTypeData]
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
medalList: List[MedalPerData]
|
||||
medalTypeData: Dict[str, MedalTypeData]
|
||||
|
@ -1,87 +1,86 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class MissionDisplayRewards(BaseModel):
|
||||
type_: str = Field(alias='type')
|
||||
id_: str = Field(alias='id')
|
||||
class MissionDisplayRewards(BaseStruct):
|
||||
type_: str = field(name='type')
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
|
||||
|
||||
class DailyMissionGroupInfoperiodInfo(BaseModel):
|
||||
class DailyMissionGroupInfoperiodInfo(BaseStruct):
|
||||
missionGroupId: str
|
||||
period: list[int]
|
||||
period: List[int]
|
||||
rewardGroupId: str
|
||||
|
||||
|
||||
class DailyMissionGroupInfo(BaseModel):
|
||||
class DailyMissionGroupInfo(BaseStruct):
|
||||
endTime: int
|
||||
periodList: list[DailyMissionGroupInfoperiodInfo]
|
||||
periodList: List[DailyMissionGroupInfoperiodInfo]
|
||||
startTime: int
|
||||
tagState: str | None
|
||||
tagState: Union[str, None]
|
||||
|
||||
|
||||
class MissionWeeklyRewardConf(BaseModel):
|
||||
class MissionWeeklyRewardConf(BaseStruct):
|
||||
beginTime: int
|
||||
endTime: int
|
||||
groupId: str
|
||||
id_: str = Field(alias='id')
|
||||
id_: str = field(name='id')
|
||||
periodicalPointCost: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
sortIndex: int
|
||||
rewards: list[MissionDisplayRewards]
|
||||
rewards: List[MissionDisplayRewards]
|
||||
|
||||
|
||||
class MissionDailyRewardConf(BaseModel):
|
||||
class MissionDailyRewardConf(BaseStruct):
|
||||
groupId: str
|
||||
id_: str = Field(alias='id')
|
||||
id_: str = field(name='id')
|
||||
periodicalPointCost: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
sortIndex: int
|
||||
rewards: list[MissionDisplayRewards]
|
||||
rewards: List[MissionDisplayRewards]
|
||||
|
||||
|
||||
class MissionGroup(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
title: str | None
|
||||
type_: str = Field(alias='type')
|
||||
preMissionGroup: str | None
|
||||
period: list[int] | None
|
||||
rewards: list[MissionDisplayRewards] | None
|
||||
missionIds: list[str]
|
||||
class MissionGroup(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
title: Union[str, None]
|
||||
type_: str = field(name='type')
|
||||
preMissionGroup: Union[str, None]
|
||||
period: Union[List[int], None]
|
||||
rewards: Union[List[MissionDisplayRewards], None]
|
||||
missionIds: List[str]
|
||||
startTs: int
|
||||
endTs: int
|
||||
|
||||
|
||||
class MissionData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class MissionData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
sortId: int
|
||||
description: str
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
itemBgType: str
|
||||
preMissionIds: list[str] | None
|
||||
preMissionIds: Union[List[str], None]
|
||||
template: str
|
||||
templateType: str
|
||||
param: list[str]
|
||||
unlockCondition: str | None
|
||||
unlockParam: list[str] | None
|
||||
param: List[str]
|
||||
unlockCondition: Union[str, None]
|
||||
unlockParam: Union[List[str], None]
|
||||
missionGroup: str
|
||||
toPage: None
|
||||
periodicalPoint: int
|
||||
rewards: list[MissionDisplayRewards] | None
|
||||
backImagePath: str | None
|
||||
foldId: str | None
|
||||
rewards: Union[List[MissionDisplayRewards], None]
|
||||
backImagePath: Union[str, None]
|
||||
foldId: Union[str, None]
|
||||
haveSubMissionToUnlock: bool
|
||||
|
||||
|
||||
class MissionTable(BaseModel):
|
||||
class MissionTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
missions: dict[str, MissionData]
|
||||
missionGroups: dict[str, MissionGroup]
|
||||
periodicalRewards: dict[str, MissionDailyRewardConf]
|
||||
weeklyRewards: dict[str, MissionWeeklyRewardConf]
|
||||
dailyMissionGroupInfo: dict[str, DailyMissionGroupInfo]
|
||||
dailyMissionPeriodInfo: list[DailyMissionGroupInfo]
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
missions: Dict[str, MissionData]
|
||||
missionGroups: Dict[str, MissionGroup]
|
||||
periodicalRewards: Dict[str, MissionDailyRewardConf]
|
||||
weeklyRewards: Dict[str, MissionWeeklyRewardConf]
|
||||
dailyMissionGroupInfo: Dict[str, DailyMissionGroupInfo]
|
||||
dailyMissionPeriodInfo: List[DailyMissionGroupInfo]
|
||||
|
@ -1,58 +1,67 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
type_: str = Field(alias='type')
|
||||
id_: str = Field(alias='id')
|
||||
class RewardItem(BaseStruct):
|
||||
type_: str = field(name='type')
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
sortId: int
|
||||
|
||||
|
||||
class ItemBundle(BaseStruct):
|
||||
type_: str = field(name='type')
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
|
||||
|
||||
class MissionDisplayRewards(BaseModel):
|
||||
type_: str = Field(alias='type')
|
||||
id_: str = Field(alias='id')
|
||||
class MissionDisplayRewards(BaseStruct):
|
||||
type_: str = field(name='type')
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
|
||||
|
||||
class OpenServerItemData(BaseModel):
|
||||
class OpenServerItemData(BaseStruct):
|
||||
itemId: str
|
||||
itemType: str
|
||||
count: int
|
||||
|
||||
|
||||
class ReturnIntroData(BaseModel):
|
||||
class ReturnIntroData(BaseStruct):
|
||||
sort: int
|
||||
pubTime: int
|
||||
image: str
|
||||
|
||||
|
||||
class ReturnCheckinData(BaseModel):
|
||||
class ReturnCheckinData(BaseStruct):
|
||||
isImportant: bool
|
||||
checkinRewardItems: list[ItemBundle]
|
||||
checkinRewardItems: List[ItemBundle]
|
||||
|
||||
|
||||
class ReturnLongTermTaskData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ReturnLongTermTaskData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
sortId: int
|
||||
template: str
|
||||
param: list[str]
|
||||
param: List[str]
|
||||
desc: str
|
||||
rewards: list[MissionDisplayRewards]
|
||||
rewards: List[MissionDisplayRewards]
|
||||
playPoint: int
|
||||
|
||||
|
||||
class ReturnDailyTaskData(BaseModel):
|
||||
class ReturnDailyTaskData(BaseStruct):
|
||||
groupId: str
|
||||
id_: str = Field(alias='id')
|
||||
id_: str = field(name='id')
|
||||
groupSortId: int
|
||||
taskSortId: int
|
||||
template: str
|
||||
param: list[str]
|
||||
param: List[str]
|
||||
desc: str
|
||||
rewards: list[MissionDisplayRewards]
|
||||
rewards: List[MissionDisplayRewards]
|
||||
playPoint: int
|
||||
|
||||
|
||||
class ReturnConst(BaseModel):
|
||||
class ReturnConst(BaseStruct):
|
||||
startTime: int
|
||||
systemTab_time: int
|
||||
afkDays: int
|
||||
@ -66,75 +75,75 @@ class ReturnConst(BaseModel):
|
||||
pointId: str
|
||||
|
||||
|
||||
class ReturnData(BaseModel):
|
||||
class ReturnData(BaseStruct):
|
||||
constData: ReturnConst
|
||||
onceRewards: list[ItemBundle]
|
||||
intro: list[ReturnIntroData]
|
||||
returnDailyTaskDic: dict[str, list[ReturnDailyTaskData]]
|
||||
returnLongTermTaskList: list[ReturnLongTermTaskData]
|
||||
creditsList: list[ItemBundle]
|
||||
checkinRewardList: list[ReturnCheckinData]
|
||||
onceRewards: List[ItemBundle]
|
||||
intro: List[ReturnIntroData]
|
||||
returnDailyTaskDic: Dict[str, List[ReturnDailyTaskData]]
|
||||
returnLongTermTaskList: List[ReturnLongTermTaskData]
|
||||
creditsList: List[ItemBundle]
|
||||
checkinRewardList: List[ReturnCheckinData]
|
||||
|
||||
|
||||
class OpenServerConst(BaseModel):
|
||||
class OpenServerConst(BaseStruct):
|
||||
firstDiamondShardMailCount: int
|
||||
initApMailEndTs: int
|
||||
|
||||
|
||||
class TotalCheckinData(BaseModel):
|
||||
class TotalCheckinData(BaseStruct):
|
||||
order: int
|
||||
item: OpenServerItemData
|
||||
colorId: int
|
||||
|
||||
|
||||
class ChainLoginData(BaseModel):
|
||||
class ChainLoginData(BaseStruct):
|
||||
order: int
|
||||
item: OpenServerItemData
|
||||
colorId: int
|
||||
|
||||
|
||||
class MissionData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class MissionData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
sortId: int
|
||||
description: str
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
itemBgType: str
|
||||
preMissionIds: None
|
||||
template: str
|
||||
templateType: str
|
||||
param: list[str]
|
||||
param: List[str]
|
||||
unlockCondition: None
|
||||
unlockParam: None
|
||||
missionGroup: str
|
||||
toPage: None
|
||||
periodicalPoint: int
|
||||
rewards: list[ItemBundle]
|
||||
rewards: List[ItemBundle]
|
||||
backImagePath: None
|
||||
foldId: None
|
||||
haveSubMissionToUnlock: bool
|
||||
|
||||
|
||||
class MissionGroup(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class MissionGroup(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
title: None
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
preMissionGroup: None
|
||||
period: None
|
||||
rewards: None
|
||||
missionIds: list[str]
|
||||
missionIds: List[str]
|
||||
startTs: int
|
||||
endTs: int
|
||||
|
||||
|
||||
class OpenServerData(BaseModel):
|
||||
class OpenServerData(BaseStruct):
|
||||
openServerMissionGroup: MissionGroup
|
||||
openServerMissionData: list[MissionData]
|
||||
checkInData: list[TotalCheckinData]
|
||||
chainLoginData: list[ChainLoginData]
|
||||
openServerMissionData: List[MissionData]
|
||||
checkInData: List[TotalCheckinData]
|
||||
chainLoginData: List[ChainLoginData]
|
||||
|
||||
|
||||
class OpenServerScheduleItem(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class OpenServerScheduleItem(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
startTs: int
|
||||
endTs: int
|
||||
totalCheckinDescption: str
|
||||
@ -142,13 +151,127 @@ class OpenServerScheduleItem(BaseModel):
|
||||
charImg: str
|
||||
|
||||
|
||||
class OpenServerTable(BaseModel):
|
||||
class ReturnConstV2(BaseStruct):
|
||||
startTime: int
|
||||
unlockLv: int
|
||||
unlockStage: str
|
||||
permMissionTime: int
|
||||
pointId: str
|
||||
returnPriceDesc: str
|
||||
dailySupplyDesc: str
|
||||
|
||||
|
||||
class onceRewardDataV2(BaseStruct):
|
||||
groupId: str
|
||||
startTime: int
|
||||
endTime: int
|
||||
rewardList: List[RewardItem]
|
||||
|
||||
|
||||
class ReturnCheckinDataV2RewardList(BaseStruct):
|
||||
sortId: int
|
||||
isImportant: bool
|
||||
rewardList: List[ItemBundle]
|
||||
|
||||
|
||||
class CheckInRewardData(BaseStruct):
|
||||
groupId: str
|
||||
startTime: int
|
||||
endTime: int
|
||||
rewardList: List[ReturnCheckinDataV2RewardList]
|
||||
|
||||
|
||||
class PriceRewardDataV2Content(BaseStruct):
|
||||
contentId: str
|
||||
sortId: int
|
||||
pointRequire: int
|
||||
desc: str
|
||||
iconId: str
|
||||
topIconId: str
|
||||
rewardList: List[RewardItem]
|
||||
|
||||
|
||||
class PriceRewardDataV2(BaseStruct):
|
||||
groupId: str
|
||||
startTime: int
|
||||
endTime: int
|
||||
contentList: List[PriceRewardDataV2Content]
|
||||
|
||||
|
||||
class MissionGroupDataV2Mission(BaseStruct):
|
||||
missionId: str
|
||||
groupId: str
|
||||
sortId: int
|
||||
jumpType: str
|
||||
jumpParam: Union[str, None]
|
||||
desc: str
|
||||
rewardList: List[ItemBundle]
|
||||
|
||||
|
||||
class MissionGroupDataV2(BaseStruct):
|
||||
groupId: str
|
||||
sortId: int
|
||||
tabTitle: str
|
||||
title: str
|
||||
desc: str
|
||||
diffMissionCount: int
|
||||
startTime: int
|
||||
endTime: int
|
||||
imageId: str
|
||||
iconId: str
|
||||
missionList: List[MissionGroupDataV2Mission]
|
||||
|
||||
|
||||
class SailySupplyDataV2(BaseStruct):
|
||||
groupId: str
|
||||
startTime: int
|
||||
endTime: int
|
||||
rewardList: List[ItemBundle]
|
||||
|
||||
|
||||
class PackageCheckInRewardDataV2(BaseStruct):
|
||||
groupId: str
|
||||
startTime: int
|
||||
endTime: int
|
||||
getTime: int
|
||||
bindGPGoodId: str
|
||||
totalCheckInDay: int
|
||||
iconId: str
|
||||
rewardDict: Dict[str, List[RewardItem]]
|
||||
|
||||
|
||||
class ReturnDataV2(BaseStruct):
|
||||
constData: ReturnConstV2
|
||||
onceRewardData: List[onceRewardDataV2]
|
||||
checkInRewardData: List[CheckInRewardData]
|
||||
priceRewardData: List[PriceRewardDataV2]
|
||||
missionGroupData: List[MissionGroupDataV2]
|
||||
dailySupplyData: List[SailySupplyDataV2]
|
||||
packageCheckInRewardData: List[PackageCheckInRewardDataV2]
|
||||
|
||||
|
||||
class CheckInRewardItem(BaseStruct):
|
||||
orderNum: int
|
||||
itemBundle: ItemBundle
|
||||
|
||||
|
||||
class OpenServerNewbieCheckInPackage(BaseStruct):
|
||||
groupId: str
|
||||
startTime: int
|
||||
endTime: int
|
||||
bindGPGoodId: str
|
||||
checkInDuration: int
|
||||
totalCheckInDay: int
|
||||
iconId: str
|
||||
checkInRewardDict: Dict[str, List[CheckInRewardItem]]
|
||||
|
||||
|
||||
class OpenServerTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
schedule: list[OpenServerScheduleItem]
|
||||
dataMap: dict[str, OpenServerData]
|
||||
schedule: List[OpenServerScheduleItem]
|
||||
dataMap: Dict[str, OpenServerData]
|
||||
constant: OpenServerConst
|
||||
playerReturn: ReturnData
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
playerReturnV2: ReturnDataV2
|
||||
newbieCheckInPackageList: List[OpenServerNewbieCheckInPackage]
|
||||
|
@ -1,13 +1,14 @@
|
||||
from pydantic import BaseModel
|
||||
from typing import Dict, List
|
||||
from ..common import BaseStruct
|
||||
|
||||
|
||||
class PlayerAvatarGroupData(BaseModel):
|
||||
class PlayerAvatarGroupData(BaseStruct):
|
||||
avatarType: str
|
||||
typeName: str
|
||||
avatarIdList: list[str]
|
||||
avatarIdList: List[str]
|
||||
|
||||
|
||||
class PlayerAvatarPerData(BaseModel):
|
||||
class PlayerAvatarPerData(BaseStruct):
|
||||
avatarId: str
|
||||
avatarType: str
|
||||
avatarIdSort: int
|
||||
@ -18,9 +19,9 @@ class PlayerAvatarPerData(BaseModel):
|
||||
obtainApproach: str
|
||||
|
||||
|
||||
class PlayerAvatarTable(BaseModel):
|
||||
class PlayerAvatarTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
avatarList: list[PlayerAvatarPerData]
|
||||
avatarTypeData: dict[str, PlayerAvatarGroupData]
|
||||
avatarList: List[PlayerAvatarPerData]
|
||||
avatarTypeData: Dict[str, PlayerAvatarGroupData]
|
||||
defaultAvatarId: str
|
||||
|
@ -1,29 +1,29 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
from msgspec import json as msgjson
|
||||
|
||||
|
||||
class GridPosition(BaseModel):
|
||||
class GridPosition(BaseStruct):
|
||||
row: int
|
||||
col: int
|
||||
|
||||
|
||||
class ObscuredRect(BaseModel):
|
||||
class ObscuredRect(BaseStruct):
|
||||
m_xMin: float
|
||||
m_yMin: float
|
||||
m_width: float
|
||||
m_height: float
|
||||
|
||||
|
||||
class Stage(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class Stage(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
direction: int
|
||||
grids: list[GridPosition]
|
||||
boundingBoxes: list[ObscuredRect] | None = None
|
||||
grids: List[GridPosition]
|
||||
boundingBoxes: Union[List[ObscuredRect], None] = None
|
||||
|
||||
|
||||
class RangeTable(BaseModel):
|
||||
class RangeTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
range: dict[str, Stage]
|
||||
|
||||
def __init__(self, **data):
|
||||
super().__init__(range=data)
|
||||
range: Dict[str, Stage]
|
||||
|
@ -1,28 +1,25 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
from msgspec import json as msgjson
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class ReplicateData(BaseModel):
|
||||
class ReplicateData(BaseStruct):
|
||||
item: ItemBundle
|
||||
replicateTokenItem: ItemBundle
|
||||
|
||||
|
||||
class ReplicateList(BaseModel):
|
||||
replicateList: list[ReplicateData]
|
||||
class ReplicateList(BaseStruct):
|
||||
replicateList: List[ReplicateData]
|
||||
|
||||
|
||||
class ReplicateTable(BaseModel):
|
||||
class ReplicateTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
replicate: dict[str, ReplicateList]
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
|
||||
def __init__(self, **data):
|
||||
super().__init__(replicate=data)
|
||||
replicate: Dict[str, ReplicateList]
|
||||
|
@ -1,78 +1,77 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
from msgspec.inspect import NoneType
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class StageDataDisplayRewards(BaseModel):
|
||||
type_: str = Field(alias='type')
|
||||
id_: str = Field(alias='id')
|
||||
class StageDataDisplayRewards(BaseStruct):
|
||||
type_: str = field(name='type')
|
||||
id_: str = field(name='id')
|
||||
dropType: int
|
||||
|
||||
|
||||
class BlackboardStr(BaseModel):
|
||||
class Blackboard(BaseStruct):
|
||||
key: str
|
||||
valueStr: str
|
||||
value: Union[float, None] = None
|
||||
valueStr: Union[str, None] = None
|
||||
|
||||
|
||||
class BlackboardInt(BaseModel):
|
||||
key: str
|
||||
value: float
|
||||
|
||||
|
||||
class Act17sideDataChoiceNodeOptionData(BaseModel):
|
||||
class Act17sideDataChoiceNodeOptionData(BaseStruct):
|
||||
canRepeat: bool
|
||||
eventId: str
|
||||
des: str
|
||||
unlockDes: str | None
|
||||
unlockDes: Union[str, None]
|
||||
|
||||
|
||||
class StageDataDisplayDetailRewards(BaseModel):
|
||||
class StageDataDisplayDetailRewards(BaseStruct):
|
||||
occPercent: int
|
||||
type_: str = Field(alias='type')
|
||||
id_: str = Field(alias='id')
|
||||
type_: str = field(name='type')
|
||||
id_: str = field(name='id')
|
||||
dropType: int
|
||||
CannotGetPercent: float | None = None
|
||||
GetPercent: float | None = None
|
||||
CannotGetPercent: Union[float, None] = None
|
||||
GetPercent: Union[float, None] = None
|
||||
|
||||
|
||||
class StageDataConditionDesc(BaseModel):
|
||||
class StageDataConditionDesc(BaseStruct):
|
||||
stageId: str
|
||||
completeState: int
|
||||
|
||||
|
||||
class Act17sideDataConstData(BaseModel):
|
||||
class Act17sideDataConstData(BaseStruct):
|
||||
techTreeUnlockEventId: str
|
||||
|
||||
|
||||
class Act17sideDataZoneData(BaseModel):
|
||||
class Act17sideDataZoneData(BaseStruct):
|
||||
zoneId: str
|
||||
unlockPlaceId: str | None
|
||||
unlockPlaceId: Union[str, None]
|
||||
unlockText: str
|
||||
|
||||
|
||||
class Act17sideDataMainlineData(BaseModel):
|
||||
class Act17sideDataMainlineData(BaseStruct):
|
||||
mainlineId: str
|
||||
nodeId: str | None
|
||||
nodeId: Union[str, None]
|
||||
sortId: int
|
||||
missionSort: str
|
||||
zoneId: str
|
||||
mainlineDes: str
|
||||
focusNodeId: str | None
|
||||
focusNodeId: Union[str, None]
|
||||
|
||||
|
||||
class Act17sideDataMainlineChapterData(BaseModel):
|
||||
class Act17sideDataMainlineChapterData(BaseStruct):
|
||||
chapterId: str
|
||||
chapterDes: str
|
||||
chapterIcon: str
|
||||
unlockDes: str
|
||||
id_: str = Field(alias='id')
|
||||
id_: str = field(name='id')
|
||||
|
||||
|
||||
class RunesSelector(BaseModel):
|
||||
class RunesSelector(BaseStruct):
|
||||
professionMask: int
|
||||
buildableMask: int
|
||||
charIdFilter: None
|
||||
@ -82,23 +81,24 @@ class RunesSelector(BaseModel):
|
||||
tileKeyFilter: None
|
||||
groupTagFilter: None
|
||||
filterTagFilter: None
|
||||
subProfessionExcludeFilter: None
|
||||
|
||||
|
||||
class TechTreeBranchRunes(BaseModel):
|
||||
class TechTreeBranchRunes(BaseStruct):
|
||||
key: str
|
||||
selector: RunesSelector
|
||||
blackboard: list[BlackboardInt | BlackboardStr]
|
||||
blackboard: List[Blackboard]
|
||||
|
||||
|
||||
class BranchRuneData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class BranchRuneData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
points: float
|
||||
mutexGroupKey: None
|
||||
description: str
|
||||
runes: list[TechTreeBranchRunes]
|
||||
runes: List[TechTreeBranchRunes]
|
||||
|
||||
|
||||
class Act17sideDataTechTreeBranchData(BaseModel):
|
||||
class Act17sideDataTechTreeBranchData(BaseStruct):
|
||||
techTreeBranchId: str
|
||||
techTreeId: str
|
||||
techTreeBranchName: str
|
||||
@ -107,7 +107,7 @@ class Act17sideDataTechTreeBranchData(BaseModel):
|
||||
runeData: BranchRuneData
|
||||
|
||||
|
||||
class Act17sideDataTechTreeData(BaseModel):
|
||||
class Act17sideDataTechTreeData(BaseStruct):
|
||||
techTreeId: str
|
||||
sortId: int
|
||||
techTreeName: str
|
||||
@ -115,36 +115,36 @@ class Act17sideDataTechTreeData(BaseModel):
|
||||
lockDes: str
|
||||
|
||||
|
||||
class Act17sideDataArchiveItemUnlockData(BaseModel):
|
||||
class Act17sideDataArchiveItemUnlockData(BaseStruct):
|
||||
itemId: str
|
||||
itemType: str
|
||||
unlockCondition: str
|
||||
nodeId: str | None
|
||||
nodeId: Union[str, None]
|
||||
stageParam: str
|
||||
chapterId: str | None
|
||||
chapterId: Union[str, None]
|
||||
|
||||
|
||||
class Act17sideDataEventData(BaseModel):
|
||||
class Act17sideDataEventData(BaseStruct):
|
||||
eventId: str
|
||||
eventPic: str | None = None
|
||||
eventSpecialPic: str | None = None
|
||||
eventTitle: str
|
||||
eventDesList: list[str]
|
||||
eventDesList: List[str]
|
||||
eventPic: Union[str, None] = None
|
||||
eventSpecialPic: Union[str, None] = None
|
||||
|
||||
|
||||
class Act17sideDataChoiceNodeData(BaseModel):
|
||||
class Act17sideDataChoiceNodeData(BaseStruct):
|
||||
nodeId: str
|
||||
choicePic: str | None = None
|
||||
isDisposable: bool
|
||||
choiceSpecialPic: str | None = None
|
||||
choiceName: str
|
||||
choiceDesList: list[str]
|
||||
choiceDesList: List[str]
|
||||
cancelDes: str
|
||||
choiceNum: int
|
||||
optionList: list[Act17sideDataChoiceNodeOptionData]
|
||||
optionList: List[Act17sideDataChoiceNodeOptionData]
|
||||
choicePic: Union[str, None] = None
|
||||
choiceSpecialPic: Union[str, None] = None
|
||||
|
||||
|
||||
class Act17sideDataTechNodeData(BaseModel):
|
||||
class Act17sideDataTechNodeData(BaseStruct):
|
||||
nodeId: str
|
||||
techTreeId: str
|
||||
techTreeName: str
|
||||
@ -152,54 +152,55 @@ class Act17sideDataTechNodeData(BaseModel):
|
||||
techSpecialPic: str
|
||||
endEventId: str
|
||||
confirmDes: str
|
||||
techDesList: list[str]
|
||||
missionIdList: list[None]
|
||||
techDesList: List[str]
|
||||
missionIdList: List[None]
|
||||
|
||||
|
||||
class Act17sideDataEventNodeData(BaseModel):
|
||||
class Act17sideDataEventNodeData(BaseStruct):
|
||||
nodeId: str
|
||||
eventId: str
|
||||
endEventId: str
|
||||
|
||||
|
||||
class Act17sideDataTreasureNodeData(BaseModel):
|
||||
class Act17sideDataTreasureNodeData(BaseStruct):
|
||||
nodeId: str
|
||||
treasureId: str
|
||||
treasureName: str
|
||||
treasurePic: str | None
|
||||
treasurePic: Union[str, None]
|
||||
treasureSpecialPic: None
|
||||
endEventId: str
|
||||
confirmDes: str
|
||||
treasureDesList: list[str]
|
||||
missionIdList: list[str]
|
||||
rewardList: list[ItemBundle]
|
||||
treasureDesList: List[str]
|
||||
missionIdList: List[str]
|
||||
rewardList: List[ItemBundle]
|
||||
treasureType: str
|
||||
|
||||
|
||||
class Act17sideDataBattleNodeData(BaseModel):
|
||||
class Act17sideDataBattleNodeData(BaseStruct):
|
||||
nodeId: str
|
||||
stageId: str
|
||||
|
||||
|
||||
class Act17sideDataStoryNodeData(BaseModel):
|
||||
class Act17sideDataStoryNodeData(BaseStruct):
|
||||
nodeId: str
|
||||
storyId: str
|
||||
storyKey: str
|
||||
storyName: str
|
||||
storyPic: str | None
|
||||
storyPic: Union[str, None]
|
||||
confirmDes: str
|
||||
storyDesList: list[str]
|
||||
storyDesList: List[str]
|
||||
|
||||
|
||||
class Act17sideDataLandmarkNodeData(BaseModel):
|
||||
class Act17sideDataLandmarkNodeData(BaseStruct):
|
||||
nodeId: str
|
||||
landmarkId: str
|
||||
landmarkName: str
|
||||
landmarkPic: str | None
|
||||
landmarkPic: Union[str, None]
|
||||
landmarkSpecialPic: str
|
||||
landmarkDesList: list[str]
|
||||
landmarkDesList: List[str]
|
||||
|
||||
|
||||
class Act17sideDataNodeInfoData(BaseModel):
|
||||
class Act17sideDataNodeInfoData(BaseStruct):
|
||||
nodeId: str
|
||||
nodeType: str
|
||||
sortId: int
|
||||
@ -209,121 +210,122 @@ class Act17sideDataNodeInfoData(BaseModel):
|
||||
trackPointType: str
|
||||
|
||||
|
||||
class Act17sideDataPlaceData(BaseModel):
|
||||
class Act17sideDataPlaceData(BaseStruct):
|
||||
placeId: str
|
||||
placeDesc: str
|
||||
lockEventId: str | None
|
||||
lockEventId: Union[str, None]
|
||||
zoneId: str
|
||||
|
||||
|
||||
class Act17sideData(BaseModel):
|
||||
archiveItemUnlockDataMap: dict[str, Act17sideDataArchiveItemUnlockData]
|
||||
battleNodeDataMap: dict[str, Act17sideDataBattleNodeData]
|
||||
choiceNodeDataMap: dict[str, Act17sideDataChoiceNodeData]
|
||||
class Act17sideData(BaseStruct):
|
||||
archiveItemUnlockDataMap: Dict[str, Act17sideDataArchiveItemUnlockData]
|
||||
battleNodeDataMap: Dict[str, Act17sideDataBattleNodeData]
|
||||
choiceNodeDataMap: Dict[str, Act17sideDataChoiceNodeData]
|
||||
constData: Act17sideDataConstData
|
||||
eventDataMap: dict[str, Act17sideDataEventData]
|
||||
eventNodeDataMap: dict[str, Act17sideDataEventNodeData]
|
||||
landmarkNodeDataMap: dict[str, Act17sideDataLandmarkNodeData]
|
||||
mainlineChapterDataMap: dict[str, Act17sideDataMainlineChapterData]
|
||||
mainlineDataMap: dict[str, Act17sideDataMainlineData]
|
||||
nodeInfoDataMap: dict[str, Act17sideDataNodeInfoData]
|
||||
placeDataMap: dict[str, Act17sideDataPlaceData]
|
||||
storyNodeDataMap: dict[str, Act17sideDataStoryNodeData]
|
||||
techNodeDataMap: dict[str, Act17sideDataTechNodeData]
|
||||
techTreeBranchDataMap: dict[str, Act17sideDataTechTreeBranchData]
|
||||
techTreeDataMap: dict[str, Act17sideDataTechTreeData]
|
||||
treasureNodeDataMap: dict[str, Act17sideDataTreasureNodeData]
|
||||
zoneDataList: list[Act17sideDataZoneData]
|
||||
eventDataMap: Dict[str, Act17sideDataEventData]
|
||||
eventNodeDataMap: Dict[str, Act17sideDataEventNodeData]
|
||||
landmarkNodeDataMap: Dict[str, Act17sideDataLandmarkNodeData]
|
||||
mainlineChapterDataMap: Dict[str, Act17sideDataMainlineChapterData]
|
||||
mainlineDataMap: Dict[str, Act17sideDataMainlineData]
|
||||
nodeInfoDataMap: Dict[str, Act17sideDataNodeInfoData]
|
||||
placeDataMap: Dict[str, Act17sideDataPlaceData]
|
||||
storyNodeDataMap: Dict[str, Act17sideDataStoryNodeData]
|
||||
techNodeDataMap: Dict[str, Act17sideDataTechNodeData]
|
||||
techTreeBranchDataMap: Dict[str, Act17sideDataTechTreeBranchData]
|
||||
techTreeDataMap: Dict[str, Act17sideDataTechTreeData]
|
||||
treasureNodeDataMap: Dict[str, Act17sideDataTreasureNodeData]
|
||||
zoneDataList: List[Act17sideDataZoneData]
|
||||
|
||||
|
||||
class Blackboard(BaseModel):
|
||||
key: str
|
||||
value: float | None = None
|
||||
valueStr: str | None = None
|
||||
|
||||
|
||||
class RuneDataSelector(BaseModel):
|
||||
class RuneDataSelector(BaseStruct):
|
||||
buildableMask: int
|
||||
charIdFilter: list[str] | None
|
||||
enemyIdExcludeFilter: list[str] | None
|
||||
enemyIdFilter: list[str] | None
|
||||
filterTagFilter: list[str] | None
|
||||
groupTagFilter: list[str] | None
|
||||
professionMask: int
|
||||
skillIdFilter: list[str] | None
|
||||
tileKeyFilter: list[str] | None
|
||||
charIdFilter: None
|
||||
enemyIdExcludeFilter: None
|
||||
enemyIdFilter: None
|
||||
filterTagFilter: None
|
||||
groupTagFilter: None
|
||||
skillIdFilter: None
|
||||
tileKeyFilter: None
|
||||
subProfessionExcludeFilter: None
|
||||
|
||||
|
||||
class RuneData(BaseModel):
|
||||
blackboard: list[Blackboard]
|
||||
class RuneData(BaseStruct):
|
||||
blackboard: List[Blackboard]
|
||||
key: str
|
||||
m_inited: bool | None = None
|
||||
selector: RuneDataSelector
|
||||
m_inited: Union[bool, None] = None
|
||||
|
||||
|
||||
class RuneTablePackedRuneData(BaseModel):
|
||||
class RuneTablePackedRuneData(BaseStruct):
|
||||
description: str
|
||||
id_: str = Field(alias='id')
|
||||
mutexGroupKey: str | None = None
|
||||
id_: str = field(name='id')
|
||||
points: float
|
||||
runes: list[RuneData]
|
||||
runes: List[RuneData]
|
||||
mutexGroupKey: Union[str, None] = None
|
||||
|
||||
|
||||
class Act25SideDataBattlePerformanceData(BaseModel):
|
||||
class Act25SideDataBattlePerformanceData(BaseStruct):
|
||||
itemDesc: str
|
||||
itemId: str
|
||||
itemIcon: str
|
||||
ItemName: str | None = None
|
||||
itemName: str
|
||||
itemTechType: str
|
||||
runeData: RuneTablePackedRuneData
|
||||
sortId: int
|
||||
|
||||
|
||||
class ActivityCustomDataAct25sideCustomData(BaseModel):
|
||||
battlePerformanceData: dict[str, Act25SideDataBattlePerformanceData]
|
||||
class ActivityCustomDataAct25sideCustomData(BaseStruct):
|
||||
battlePerformanceData: Dict[str, Act25SideDataBattlePerformanceData]
|
||||
|
||||
|
||||
class ActivityCustomData(BaseModel):
|
||||
TYPE_ACT17SIDE: dict[str, Act17sideData]
|
||||
TYPE_ACT25SIDE: dict[str, ActivityCustomDataAct25sideCustomData]
|
||||
class ActivityCustomDataAct20sideCustomData(BaseStruct):
|
||||
zoneAdditionDataMap: Dict[str, str]
|
||||
residentCartDatas: Dict[str, Dict[str, str]]
|
||||
|
||||
|
||||
class RetroTrailRuleData(BaseModel):
|
||||
title: list[str]
|
||||
desc: list[str]
|
||||
class ActivityCustomData(BaseStruct):
|
||||
TYPE_ACT17SIDE: Dict[str, Act17sideData]
|
||||
TYPE_ACT25SIDE: Dict[str, ActivityCustomDataAct25sideCustomData]
|
||||
TYPE_ACT20SIDE: Dict[str, ActivityCustomDataAct20sideCustomData]
|
||||
|
||||
|
||||
class WeightItemBundle(BaseModel):
|
||||
class RetroTrailRuleData(BaseStruct):
|
||||
title: List[str]
|
||||
desc: List[str]
|
||||
|
||||
|
||||
class WeightItemBundle(BaseStruct):
|
||||
count: int
|
||||
dropType: str
|
||||
id_: str = Field(alias='id')
|
||||
type_: str = Field(alias='type')
|
||||
id_: str = field(name='id')
|
||||
type_: str = field(name='type')
|
||||
weight: int
|
||||
|
||||
|
||||
class StageDataStageDropInfo(BaseModel):
|
||||
firstPassRewards: list[ItemBundle] | None = None
|
||||
firstCompleteRewards: list[ItemBundle] | None = None
|
||||
passRewards: list[list[WeightItemBundle]] | None = None
|
||||
completeRewards: list[list[WeightItemBundle]] | None = None
|
||||
displayRewards: list[StageDataDisplayRewards]
|
||||
displayDetailRewards: list[StageDataDisplayDetailRewards]
|
||||
class StageDataStageDropInfo(BaseStruct):
|
||||
displayRewards: List[StageDataDisplayRewards]
|
||||
displayDetailRewards: List[StageDataDisplayDetailRewards]
|
||||
firstPassRewards: Union[List[ItemBundle], None] = None
|
||||
firstCompleteRewards: Union[List[ItemBundle], None] = None
|
||||
passRewards: Union[List[List[WeightItemBundle]], None] = None
|
||||
completeRewards: Union[List[List[WeightItemBundle]], None] = None
|
||||
|
||||
|
||||
class StageData(BaseModel):
|
||||
class StageData(BaseStruct, kw_only=False):
|
||||
stageType: str
|
||||
difficulty: str
|
||||
performanceStageFlag: str
|
||||
diffGroup: str
|
||||
unlockCondition: list[StageDataConditionDesc]
|
||||
unlockCondition: List[StageDataConditionDesc]
|
||||
stageId: str
|
||||
levelId: str | None
|
||||
levelId: Union[str, None]
|
||||
zoneId: str
|
||||
code: str
|
||||
name: str
|
||||
description: str
|
||||
hardStagedId: str | None
|
||||
dangerLevel: str | None
|
||||
hardStagedId: Union[str, None]
|
||||
dangerLevel: Union[str, None]
|
||||
dangerPoint: float
|
||||
loadingPicId: str
|
||||
canPractice: bool
|
||||
@ -357,45 +359,48 @@ class StageData(BaseModel):
|
||||
startButtonOverrideId: None
|
||||
isStagePatch: bool
|
||||
mainStageId: str
|
||||
canUseTech: Union[bool, None] = None
|
||||
canUseCharm: Union[bool, None] = None
|
||||
canUseBattlePerformance: Union[bool, None] = None
|
||||
|
||||
|
||||
class RetroTrailRewardItem(BaseModel):
|
||||
class RetroTrailRewardItem(BaseStruct):
|
||||
trailRewardId: str
|
||||
starCount: int
|
||||
rewardItem: ItemBundle
|
||||
|
||||
|
||||
class RetroTrailData(BaseModel):
|
||||
class RetroTrailData(BaseStruct):
|
||||
retroId: str
|
||||
trailStartTime: int
|
||||
trailRewardList: list[RetroTrailRewardItem]
|
||||
stageList: list[str]
|
||||
trailRewardList: List[RetroTrailRewardItem]
|
||||
stageList: List[str]
|
||||
relatedChar: str
|
||||
relatedFullPotentialItemId: None
|
||||
themeColor: str
|
||||
fullPotentialItemId: str
|
||||
|
||||
|
||||
class RetroActData(BaseModel):
|
||||
class RetroActData(BaseStruct):
|
||||
retroId: str
|
||||
type_: int = Field(alias='type')
|
||||
linkedActId: list[str]
|
||||
type_: int = field(name='type')
|
||||
linkedActId: List[str]
|
||||
startTime: int
|
||||
trailStartTime: int
|
||||
index: int
|
||||
name: str
|
||||
detail: str
|
||||
haveTrail: bool
|
||||
customActId: str | None
|
||||
customActId: Union[str, None]
|
||||
customActType: str
|
||||
|
||||
|
||||
class StageValidInfo(BaseModel):
|
||||
class StageValidInfo(BaseStruct):
|
||||
startTs: int
|
||||
endTs: int
|
||||
|
||||
|
||||
class RetroStageOverrideInfo(BaseModel):
|
||||
class RetroStageOverrideInfo(BaseStruct):
|
||||
apCost: int
|
||||
apFailReturn: int
|
||||
completeFavor: int
|
||||
@ -406,23 +411,20 @@ class RetroStageOverrideInfo(BaseModel):
|
||||
zoneId: str
|
||||
|
||||
|
||||
class RetroTable(BaseModel):
|
||||
class RetroTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
customData: ActivityCustomData
|
||||
initRetroCoin: int
|
||||
retroActList: dict[str, RetroActData]
|
||||
retroActList: Dict[str, RetroActData]
|
||||
retroCoinMax: int
|
||||
retroCoinPerWeek: int
|
||||
retroDetail: str
|
||||
retroPreShowTime: int
|
||||
retroTrailList: dict[str, RetroTrailData]
|
||||
retroTrailList: Dict[str, RetroTrailData]
|
||||
retroUnlockCost: int
|
||||
ruleData: RetroTrailRuleData
|
||||
stageList: dict[str, StageData]
|
||||
stages: dict[str, RetroStageOverrideInfo] | None = None
|
||||
stageValidInfo: dict[str, StageValidInfo]
|
||||
zoneToRetro: dict[str, str]
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
stageList: Dict[str, StageData]
|
||||
stageValidInfo: Dict[str, StageValidInfo]
|
||||
zoneToRetro: Dict[str, str]
|
||||
stages: Union[Dict[str, RetroStageOverrideInfo], None] = None
|
||||
|
@ -1,49 +1,51 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class Blackboard(BaseModel):
|
||||
class Blackboard(BaseStruct):
|
||||
key: str
|
||||
value: float | None = None
|
||||
valueStr: str | None = None
|
||||
value: Union[float, None] = None
|
||||
valueStr: Union[str, None] = None
|
||||
|
||||
|
||||
class RoguelikeBuff(BaseModel):
|
||||
class RoguelikeBuff(BaseStruct):
|
||||
key: str
|
||||
blackboard: list[Blackboard]
|
||||
blackboard: List[Blackboard]
|
||||
|
||||
|
||||
class RoguelikeOuterBuff(BaseModel):
|
||||
buffId: str | None = None
|
||||
class RoguelikeOuterBuff(BaseStruct):
|
||||
level: int
|
||||
name: str
|
||||
iconId: str
|
||||
description: str
|
||||
usage: str
|
||||
key: str
|
||||
blackboard: list[Blackboard]
|
||||
blackboard: List[Blackboard]
|
||||
buffId: Union[str, None] = None
|
||||
|
||||
|
||||
class RoguelikeOutBuffData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
buffs: dict[str, RoguelikeOuterBuff]
|
||||
class RoguelikeOutBuffData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
buffs: Dict[str, RoguelikeOuterBuff]
|
||||
|
||||
|
||||
class RoguelikeEndingData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class RoguelikeEndingData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
backgroundId: str
|
||||
name: str
|
||||
description: str
|
||||
priority: int
|
||||
unlockItemId: str | None
|
||||
unlockItemId: Union[str, None]
|
||||
changeEndingDesc: None
|
||||
|
||||
|
||||
class RoguelikeModeData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class RoguelikeModeData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
name: str
|
||||
canUnlockItem: int
|
||||
scoreFactor: float
|
||||
itemPools: list[str]
|
||||
itemPools: List[str]
|
||||
difficultyDesc: str
|
||||
ruleDesc: str
|
||||
sortId: int
|
||||
@ -51,25 +53,25 @@ class RoguelikeModeData(BaseModel):
|
||||
color: str
|
||||
|
||||
|
||||
class RoguelikeChoiceSceneData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class RoguelikeChoiceSceneData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
title: str
|
||||
description: str
|
||||
background: str
|
||||
|
||||
|
||||
class RoguelikeChoiceData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class RoguelikeChoiceData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
title: str
|
||||
description: str | None
|
||||
type_: str = Field(alias='type')
|
||||
nextSceneId: str | None
|
||||
icon: str | None
|
||||
param: dict[str, object]
|
||||
description: Union[str, None]
|
||||
type_: str = field(name='type')
|
||||
nextSceneId: Union[str, None]
|
||||
icon: Union[str, None]
|
||||
param: Dict[str, object]
|
||||
|
||||
|
||||
class RoguelikeZoneData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class RoguelikeZoneData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
name: str
|
||||
description: str
|
||||
endingDescription: str
|
||||
@ -77,106 +79,106 @@ class RoguelikeZoneData(BaseModel):
|
||||
subIconId: str
|
||||
|
||||
|
||||
class RoguelikeStageData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class RoguelikeStageData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
linkedStageId: str
|
||||
levelId: str
|
||||
code: str
|
||||
name: str
|
||||
loadingPicId: str
|
||||
description: str
|
||||
eliteDesc: str | None
|
||||
eliteDesc: Union[str, None]
|
||||
isBoss: int
|
||||
isElite: int
|
||||
difficulty: str
|
||||
|
||||
|
||||
class RoguelikeRelicFeature(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
buffs: list[RoguelikeBuff]
|
||||
class RoguelikeRelicFeature(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
buffs: List[RoguelikeBuff]
|
||||
|
||||
|
||||
class RoguelikeUpgradeTicketFeature(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class RoguelikeUpgradeTicketFeature(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
profession: int
|
||||
rarity: int
|
||||
professionList: list[str]
|
||||
rarityList: list[int]
|
||||
professionList: List[str]
|
||||
rarityList: List[int]
|
||||
|
||||
|
||||
class RoguelikeRecruitTicketFeature(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class RoguelikeRecruitTicketFeature(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
profession: int
|
||||
rarity: int
|
||||
professionList: list[str]
|
||||
rarityList: list[int]
|
||||
professionList: List[str]
|
||||
rarityList: List[int]
|
||||
extraEliteNum: int
|
||||
extraFreeRarity: list[int | None]
|
||||
extraCharIds: list[str]
|
||||
extraFreeRarity: List[Union[int, None]]
|
||||
extraCharIds: List[str]
|
||||
|
||||
|
||||
class RelicStableUnlockParam(BaseModel):
|
||||
class RelicStableUnlockParam(BaseStruct):
|
||||
unlockCondDetail: str
|
||||
unlockCnt: int
|
||||
|
||||
|
||||
class RoguelikeItemData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class RoguelikeItemData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
name: str
|
||||
description: str | None
|
||||
description: Union[str, None]
|
||||
usage: str
|
||||
obtainApproach: str
|
||||
iconId: str
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
rarity: str
|
||||
value: int
|
||||
sortId: int
|
||||
unlockCond: str | None
|
||||
unlockCondDesc: str | None
|
||||
unlockCondParams: list[str | None]
|
||||
stableUnlockCond: RelicStableUnlockParam | None
|
||||
unlockCond: Union[str, None]
|
||||
unlockCondDesc: Union[str, None]
|
||||
unlockCondParams: List[Union[str, None]]
|
||||
stableUnlockCond: Union[RelicStableUnlockParam, None]
|
||||
|
||||
|
||||
class RoguelikeItemTable(BaseModel):
|
||||
items: dict[str, RoguelikeItemData]
|
||||
recruitTickets: dict[str, RoguelikeRecruitTicketFeature]
|
||||
upgradeTickets: dict[str, RoguelikeUpgradeTicketFeature]
|
||||
relics: dict[str, RoguelikeRelicFeature]
|
||||
class RoguelikeItemTable(BaseStruct):
|
||||
items: Dict[str, RoguelikeItemData]
|
||||
recruitTickets: Dict[str, RoguelikeRecruitTicketFeature]
|
||||
upgradeTickets: Dict[str, RoguelikeUpgradeTicketFeature]
|
||||
relics: Dict[str, RoguelikeRelicFeature]
|
||||
|
||||
|
||||
class RoguelikeConstTableEventTypeData(BaseModel):
|
||||
class RoguelikeConstTableEventTypeData(BaseStruct):
|
||||
name: str
|
||||
description: str
|
||||
|
||||
|
||||
class RoguelikeConstTableCharUpgradeData(BaseModel):
|
||||
class RoguelikeConstTableCharUpgradeData(BaseStruct):
|
||||
evolvePhase: int
|
||||
skillLevel: int
|
||||
skillSpecializeLevel: int
|
||||
|
||||
|
||||
class RoguelikeConstTableRecruitData(BaseModel):
|
||||
class RoguelikeConstTableRecruitData(BaseStruct):
|
||||
recruitPopulation: int
|
||||
upgradePopulation: int
|
||||
|
||||
|
||||
class RoguelikeConstTablePlayerLevelData(BaseModel):
|
||||
class RoguelikeConstTablePlayerLevelData(BaseStruct):
|
||||
exp: int
|
||||
populationUp: int
|
||||
squadCapacityUp: int
|
||||
battleCharLimitUp: int
|
||||
|
||||
|
||||
class RoguelikeConstTable(BaseModel):
|
||||
playerLevelTable: dict[str, RoguelikeConstTablePlayerLevelData]
|
||||
recruitPopulationTable: dict[str, RoguelikeConstTableRecruitData]
|
||||
charUpgradeTable: dict[str, RoguelikeConstTableCharUpgradeData]
|
||||
eventTypeTable: dict[str, RoguelikeConstTableEventTypeData]
|
||||
shopDialogs: list[str]
|
||||
shopRelicDialogs: list[str]
|
||||
shopTicketDialogs: list[str]
|
||||
mimicEnemyIds: list[str]
|
||||
clearZoneScores: list[int]
|
||||
class RoguelikeConstTable(BaseStruct):
|
||||
playerLevelTable: Dict[str, RoguelikeConstTablePlayerLevelData]
|
||||
recruitPopulationTable: Dict[str, RoguelikeConstTableRecruitData]
|
||||
charUpgradeTable: Dict[str, RoguelikeConstTableCharUpgradeData]
|
||||
eventTypeTable: Dict[str, RoguelikeConstTableEventTypeData]
|
||||
shopDialogs: List[str]
|
||||
shopRelicDialogs: List[str]
|
||||
shopTicketDialogs: List[str]
|
||||
mimicEnemyIds: List[str]
|
||||
clearZoneScores: List[int]
|
||||
moveToNodeScore: int
|
||||
clearNormalBattleScore: int
|
||||
clearEliteBattleScore: int
|
||||
@ -185,21 +187,18 @@ class RoguelikeConstTable(BaseModel):
|
||||
gainCharacterScore: int
|
||||
unlockRelicSpecialScore: int
|
||||
squadCapacityMax: int
|
||||
bossIds: list[str]
|
||||
bossIds: List[str]
|
||||
|
||||
|
||||
class RoguelikeTable(BaseModel):
|
||||
class RoguelikeTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
constTable: RoguelikeConstTable
|
||||
itemTable: RoguelikeItemTable
|
||||
stages: dict[str, RoguelikeStageData]
|
||||
zones: dict[str, RoguelikeZoneData]
|
||||
choices: dict[str, RoguelikeChoiceData]
|
||||
choiceScenes: dict[str, RoguelikeChoiceSceneData]
|
||||
modes: dict[str, RoguelikeModeData]
|
||||
endings: dict[str, RoguelikeEndingData]
|
||||
outBuffs: dict[str, RoguelikeOutBuffData]
|
||||
|
||||
class Config:
|
||||
extra = 'allow'
|
||||
stages: Dict[str, RoguelikeStageData]
|
||||
zones: Dict[str, RoguelikeZoneData]
|
||||
choices: Dict[str, RoguelikeChoiceData]
|
||||
choiceScenes: Dict[str, RoguelikeChoiceSceneData]
|
||||
modes: Dict[str, RoguelikeModeData]
|
||||
endings: Dict[str, RoguelikeEndingData]
|
||||
outBuffs: Dict[str, RoguelikeOutBuffData]
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1,8 +1,10 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class SandboxMapConstTable(BaseModel):
|
||||
directionNames: list[str]
|
||||
class SandboxMapConstTable(BaseStruct):
|
||||
directionNames: List[str]
|
||||
homeNodeStageId: str
|
||||
homeRushStageCode: str
|
||||
homeRushStageName: str
|
||||
@ -11,11 +13,11 @@ class SandboxMapConstTable(BaseModel):
|
||||
homeBuildModeBGM: str
|
||||
|
||||
|
||||
class SandboxBaseConstTable(BaseModel):
|
||||
class SandboxBaseConstTable(BaseStruct):
|
||||
cookRegularCostItemId: str
|
||||
cookRegularCostItemIdCnt: int
|
||||
squadTabNameList: list[str]
|
||||
charRarityColorList: list[str]
|
||||
squadTabNameList: List[str]
|
||||
charRarityColorList: List[str]
|
||||
sumFoodLimitedCount: int
|
||||
sumBuildingLimitedCount: int
|
||||
sumTacticalLimitedCount: int
|
||||
@ -44,69 +46,69 @@ class SandboxBaseConstTable(BaseModel):
|
||||
settleSucDesc: str
|
||||
|
||||
|
||||
class TipData(BaseModel):
|
||||
class TipData(BaseStruct):
|
||||
tip: str
|
||||
weight: int | float
|
||||
weight: Union[int, float]
|
||||
category: str
|
||||
|
||||
|
||||
class SandboxFoodProduceData(BaseModel):
|
||||
class SandboxFoodProduceData(BaseStruct):
|
||||
itemId: str
|
||||
mainMaterialItems: list[str]
|
||||
mainMaterialItems: List[str]
|
||||
buffId: str
|
||||
unlockDesc: str
|
||||
|
||||
|
||||
class SandboxFoodmatBuffData(BaseModel):
|
||||
class SandboxFoodmatBuffData(BaseStruct):
|
||||
itemId: str
|
||||
buffId: str | None
|
||||
buffDesc: str | None
|
||||
buffId: Union[str, None]
|
||||
buffDesc: Union[str, None]
|
||||
matType: str
|
||||
sortId: int
|
||||
|
||||
|
||||
class SandboxFoodStaminaData(BaseModel):
|
||||
class SandboxFoodStaminaData(BaseStruct):
|
||||
itemId: str
|
||||
potCnt: int
|
||||
foodStaminaCnt: int
|
||||
|
||||
|
||||
class SandboxBuildProduceData(BaseModel):
|
||||
class SandboxBuildProduceData(BaseStruct):
|
||||
itemProduceId: str
|
||||
itemId: str
|
||||
itemTypeText: str
|
||||
materialItems: dict[str, int]
|
||||
materialItems: Dict[str, int]
|
||||
|
||||
|
||||
class SandboxBuildGoldRatioData(BaseModel):
|
||||
class SandboxBuildGoldRatioData(BaseStruct):
|
||||
itemId: str
|
||||
ratio: int
|
||||
effectDesc: str
|
||||
|
||||
|
||||
class SandboxBuildingItemData(BaseModel):
|
||||
class SandboxBuildingItemData(BaseStruct):
|
||||
itemId: str
|
||||
itemSubType: str
|
||||
itemRarity: int
|
||||
|
||||
|
||||
class SandboxBuildProduceUnlockData(BaseModel):
|
||||
class SandboxBuildProduceUnlockData(BaseStruct):
|
||||
itemId: str
|
||||
buildingEffectDesc: str
|
||||
buildingItemDesc: str
|
||||
buildingUnlockDesc: str
|
||||
|
||||
|
||||
class SandboxCraftItemData(BaseModel):
|
||||
class SandboxCraftItemData(BaseStruct):
|
||||
itemId: str
|
||||
sortId: int
|
||||
getFrom: str
|
||||
npcId: str | None
|
||||
npcId: Union[str, None]
|
||||
notObtainedDesc: str
|
||||
itemType: str
|
||||
|
||||
|
||||
class SandboxItemTrapData(BaseModel):
|
||||
class SandboxItemTrapData(BaseStruct):
|
||||
itemId: str
|
||||
trapId: str
|
||||
trapPhase: int
|
||||
@ -115,87 +117,87 @@ class SandboxItemTrapData(BaseModel):
|
||||
skillLevel: int
|
||||
|
||||
|
||||
class SandboxDevelopmentData(BaseModel):
|
||||
class SandboxDevelopmentData(BaseStruct):
|
||||
buffId: str
|
||||
positionX: int
|
||||
positionY: int
|
||||
frontNodeId: str | None
|
||||
nextNodeIds: list[str] | None
|
||||
frontNodeId: Union[str, None]
|
||||
nextNodeIds: Union[List[str], None]
|
||||
buffLimitedId: str
|
||||
tokenCost: int
|
||||
canBuffResearch: bool
|
||||
buffResearchDesc: str | None
|
||||
buffResearchDesc: Union[str, None]
|
||||
buffName: str
|
||||
buffIconId: str
|
||||
nodeTitle: str
|
||||
buffEffectDesc: str
|
||||
|
||||
|
||||
class SandboxDevelopmentLimitData(BaseModel):
|
||||
class SandboxDevelopmentLimitData(BaseStruct):
|
||||
buffLimitedId: str
|
||||
positionX: int
|
||||
buffCostLimitedCount: int
|
||||
|
||||
|
||||
class SandboxItemToastData(BaseModel):
|
||||
class SandboxItemToastData(BaseStruct):
|
||||
itemType: str
|
||||
toastDesc: str
|
||||
color: str
|
||||
|
||||
|
||||
class SandboxDevelopmentLineSegmentData(BaseModel):
|
||||
class SandboxDevelopmentLineSegmentData(BaseStruct):
|
||||
fromNodeId: str
|
||||
passingNodeIds: list[str]
|
||||
passingNodeIds: List[str]
|
||||
fromAxisPosX: int
|
||||
fromAxisPosY: int
|
||||
toAxisPosX: int
|
||||
toAxisPosY: int
|
||||
|
||||
|
||||
class SandboxRewardItemConfigData(BaseModel):
|
||||
class SandboxRewardItemConfigData(BaseStruct):
|
||||
rewardItem: str
|
||||
rewardType: str
|
||||
|
||||
|
||||
class SandboxRewardData(BaseModel):
|
||||
rewardList: list[SandboxRewardItemConfigData]
|
||||
class SandboxRewardData(BaseStruct):
|
||||
rewardList: List[SandboxRewardItemConfigData]
|
||||
|
||||
|
||||
class SandboxRewardCommonConfig(BaseModel):
|
||||
dropType: int | None = None
|
||||
class SandboxRewardCommonConfig(BaseStruct):
|
||||
rewardItemId: str
|
||||
rewardItemType: str
|
||||
count: int
|
||||
dropType: Union[int, None] = None
|
||||
|
||||
|
||||
class SandboxTrapRewardConfigData(SandboxRewardCommonConfig):
|
||||
dropType: int
|
||||
|
||||
|
||||
class SandboxRewardConfigGroupData(BaseModel):
|
||||
stagePreviewRewardDict: dict[str, SandboxRewardData]
|
||||
stageDefaultPreviewRewardDict: dict[str, SandboxRewardData]
|
||||
rushPreviewRewardDict: dict[str, SandboxRewardData]
|
||||
stageRewardDict: dict[str, SandboxRewardData]
|
||||
rushRewardDict: dict[str, SandboxRewardData]
|
||||
trapRewardDict: dict[str, SandboxRewardCommonConfig]
|
||||
enemyRewardDict: dict[str, SandboxRewardCommonConfig]
|
||||
keyWordData: dict[str, str]
|
||||
class SandboxRewardConfigGroupData(BaseStruct):
|
||||
stagePreviewRewardDict: Dict[str, SandboxRewardData]
|
||||
stageDefaultPreviewRewardDict: Dict[str, SandboxRewardData]
|
||||
rushPreviewRewardDict: Dict[str, SandboxRewardData]
|
||||
stageRewardDict: Dict[str, SandboxRewardData]
|
||||
rushRewardDict: Dict[str, SandboxRewardData]
|
||||
trapRewardDict: Dict[str, SandboxRewardCommonConfig]
|
||||
enemyRewardDict: Dict[str, SandboxRewardCommonConfig]
|
||||
keyWordData: Dict[str, str]
|
||||
|
||||
|
||||
class SandboxStaminaData(BaseModel):
|
||||
class SandboxStaminaData(BaseStruct):
|
||||
levelUpperLimit: int
|
||||
staminaUpperLimit: int
|
||||
|
||||
|
||||
class SandboxNodeTypeData(BaseModel):
|
||||
class SandboxNodeTypeData(BaseStruct):
|
||||
nodeType: str
|
||||
name: str
|
||||
subName: str
|
||||
iconId: str
|
||||
|
||||
|
||||
class SandboxNodeUpgradeData(BaseModel):
|
||||
class SandboxNodeUpgradeData(BaseStruct):
|
||||
nodeUpdradeId: str
|
||||
name: str
|
||||
description: str
|
||||
@ -206,7 +208,7 @@ class SandboxNodeUpgradeData(BaseModel):
|
||||
itemRarity: int
|
||||
|
||||
|
||||
class SandboxWeatherData(BaseModel):
|
||||
class SandboxWeatherData(BaseStruct):
|
||||
weatherId: str
|
||||
weatherType: str
|
||||
weatherLevel: int
|
||||
@ -218,7 +220,7 @@ class SandboxWeatherData(BaseModel):
|
||||
buffId: str
|
||||
|
||||
|
||||
class SandboxStageData(BaseModel):
|
||||
class SandboxStageData(BaseStruct):
|
||||
stageId: str
|
||||
levelId: str
|
||||
code: str
|
||||
@ -229,157 +231,158 @@ class SandboxStageData(BaseModel):
|
||||
powerCost: int
|
||||
|
||||
|
||||
class SandboxEventData(BaseModel):
|
||||
class SandboxEventData(BaseStruct):
|
||||
eventSceneId: str
|
||||
hasThumbtack: bool
|
||||
|
||||
|
||||
class SandboxEventSceneData(BaseModel):
|
||||
class SandboxEventSceneData(BaseStruct):
|
||||
choiceSceneId: str
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
title: str
|
||||
description: str
|
||||
choices: list[str]
|
||||
choices: List[str]
|
||||
|
||||
|
||||
class SandboxEventChoiceData(BaseModel):
|
||||
class SandboxEventChoiceData(BaseStruct):
|
||||
choiceId: str
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
costAction: int
|
||||
finishScene: bool
|
||||
title: str
|
||||
description: str
|
||||
|
||||
|
||||
class SandboxEventTypeData(BaseModel):
|
||||
class SandboxEventTypeData(BaseStruct):
|
||||
eventType: str
|
||||
iconId: str
|
||||
|
||||
|
||||
class SandboxMissionData(BaseModel):
|
||||
class SandboxMissionData(BaseStruct):
|
||||
missionId: str
|
||||
desc: str
|
||||
effectDesc: str | None
|
||||
effectDesc: Union[str, None]
|
||||
costAction: int
|
||||
charCnt: int
|
||||
professionIds: list[str]
|
||||
professionIds: List[str]
|
||||
profession: int
|
||||
costStamina: int
|
||||
|
||||
|
||||
class SandboxUnitData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class SandboxUnitData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
name: str
|
||||
|
||||
|
||||
class SandboxDailyDescTemplateData(BaseModel):
|
||||
type_: str = Field(alias='type')
|
||||
templateDesc: list[str]
|
||||
class SandboxDailyDescTemplateData(BaseStruct):
|
||||
type_: str = field(name='type')
|
||||
templateDesc: List[str]
|
||||
|
||||
|
||||
class RushEnemyConfig(BaseModel):
|
||||
class RushEnemyConfig(BaseStruct):
|
||||
enemyKey: str
|
||||
branchId: str
|
||||
count: int
|
||||
interval: int | float
|
||||
interval: Union[int, float]
|
||||
|
||||
|
||||
class RushEnemyGroupConfig(BaseModel):
|
||||
class RushEnemyGroupConfig(BaseStruct):
|
||||
enemyGroupKey: str
|
||||
weight: int
|
||||
enemy: list[RushEnemyConfig]
|
||||
dynamicEnemy: list[str]
|
||||
enemy: List[RushEnemyConfig]
|
||||
dynamicEnemy: List[str]
|
||||
|
||||
|
||||
class RushEnemyGroupRushEnemyDBRef(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class RushEnemyGroupRushEnemyDBRef(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
level: int
|
||||
|
||||
|
||||
class RushEnemyGroup(BaseModel):
|
||||
rushEnemyGroupConfigs: dict[str, list[RushEnemyGroupConfig]]
|
||||
rushEnemyDbRef: list[RushEnemyGroupRushEnemyDBRef]
|
||||
class RushEnemyGroup(BaseStruct):
|
||||
rushEnemyGroupConfigs: Dict[str, List[RushEnemyGroupConfig]]
|
||||
rushEnemyDbRef: List[RushEnemyGroupRushEnemyDBRef]
|
||||
|
||||
|
||||
class RuneDataSelector(BaseModel):
|
||||
class RuneDataSelector(BaseStruct):
|
||||
professionMask: int
|
||||
buildableMask: int
|
||||
charIdFilter: list[str] | None
|
||||
enemyIdFilter: list[str] | None
|
||||
enemyIdExcludeFilter: list[str] | None
|
||||
skillIdFilter: list[str] | None
|
||||
tileKeyFilter: list[str] | None
|
||||
groupTagFilter: list[str] | None
|
||||
filterTagFilter: list[str] | None
|
||||
charIdFilter: Union[List[str], None]
|
||||
enemyIdFilter: Union[List[str], None]
|
||||
enemyIdExcludeFilter: Union[List[str], None]
|
||||
skillIdFilter: Union[List[str], None]
|
||||
tileKeyFilter: Union[List[str], None]
|
||||
groupTagFilter: Union[List[str], None]
|
||||
filterTagFilter: Union[List[str], None]
|
||||
subProfessionExcludeFilter: Union[List[str], None]
|
||||
|
||||
|
||||
class Blackboard(BaseModel):
|
||||
class Blackboard(BaseStruct):
|
||||
key: str
|
||||
value: int | float | None = None
|
||||
valueStr: str | None = None
|
||||
value: Union[Union[int, float], None] = None
|
||||
valueStr: Union[str, None] = None
|
||||
|
||||
|
||||
class RuneData(BaseModel):
|
||||
class RuneData(BaseStruct):
|
||||
key: str
|
||||
selector: RuneDataSelector
|
||||
blackboard: list[Blackboard]
|
||||
blackboard: List[Blackboard]
|
||||
|
||||
|
||||
class RuneTablePackedRuneData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
points: int | float
|
||||
mutexGroupKey: str | None
|
||||
class RuneTablePackedRuneData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
points: Union[int, float]
|
||||
mutexGroupKey: Union[str, None]
|
||||
description: str
|
||||
runes: list[RuneData]
|
||||
runes: List[RuneData]
|
||||
|
||||
|
||||
class LegacyInLevelRuneData(BaseModel):
|
||||
class LegacyInLevelRuneData(BaseStruct):
|
||||
difficultyMask: int
|
||||
key: str
|
||||
professionMask: int
|
||||
buildableMask: int
|
||||
blackboard: list[Blackboard]
|
||||
blackboard: List[Blackboard]
|
||||
|
||||
|
||||
class SandboxActTable(BaseModel):
|
||||
class SandboxActTable(BaseStruct):
|
||||
mapConstTable: SandboxMapConstTable
|
||||
baseConstTable: SandboxBaseConstTable
|
||||
battleLoadingTips: list[TipData]
|
||||
foodProduceDatas: dict[str, SandboxFoodProduceData]
|
||||
foodmatDatas: dict[str, SandboxFoodmatBuffData]
|
||||
foodmatBuffDatas: dict[str, SandboxFoodmatBuffData]
|
||||
foodStaminaDatas: dict[str, SandboxFoodStaminaData]
|
||||
buildProduceDatas: dict[str, SandboxBuildProduceData]
|
||||
buildGoldRatioDatas: list[SandboxBuildGoldRatioData]
|
||||
buildingItemDatas: dict[str, SandboxBuildingItemData]
|
||||
buildProduceUnlockDatas: dict[str, SandboxBuildProduceUnlockData]
|
||||
craftItemDatas: dict[str, SandboxCraftItemData]
|
||||
itemTrapDatas: dict[str, SandboxItemTrapData]
|
||||
trapDeployLimitDatas: dict[str, int]
|
||||
developmentDatas: dict[str, SandboxDevelopmentData]
|
||||
developmentLimitDatas: dict[str, SandboxDevelopmentLimitData]
|
||||
itemToastDatas: dict[str, SandboxItemToastData]
|
||||
developmentLineSegmentDatas: list[SandboxDevelopmentLineSegmentData]
|
||||
battleLoadingTips: List[TipData]
|
||||
foodProduceDatas: Dict[str, SandboxFoodProduceData]
|
||||
foodmatDatas: Dict[str, SandboxFoodmatBuffData]
|
||||
foodmatBuffDatas: Dict[str, SandboxFoodmatBuffData]
|
||||
foodStaminaDatas: Dict[str, SandboxFoodStaminaData]
|
||||
buildProduceDatas: Dict[str, SandboxBuildProduceData]
|
||||
buildGoldRatioDatas: List[SandboxBuildGoldRatioData]
|
||||
buildingItemDatas: Dict[str, SandboxBuildingItemData]
|
||||
buildProduceUnlockDatas: Dict[str, SandboxBuildProduceUnlockData]
|
||||
craftItemDatas: Dict[str, SandboxCraftItemData]
|
||||
itemTrapDatas: Dict[str, SandboxItemTrapData]
|
||||
trapDeployLimitDatas: Dict[str, int]
|
||||
developmentDatas: Dict[str, SandboxDevelopmentData]
|
||||
developmentLimitDatas: Dict[str, SandboxDevelopmentLimitData]
|
||||
itemToastDatas: Dict[str, SandboxItemToastData]
|
||||
developmentLineSegmentDatas: List[SandboxDevelopmentLineSegmentData]
|
||||
rewardConfigDatas: SandboxRewardConfigGroupData
|
||||
charStaminaMapping: dict[str, dict[str, list[SandboxStaminaData]]]
|
||||
nodeTypeDatas: dict[str, SandboxNodeTypeData]
|
||||
nodeUpgradeDatas: dict[str, SandboxNodeUpgradeData]
|
||||
weatherDatas: dict[str, SandboxWeatherData]
|
||||
stageDatas: dict[str, SandboxStageData]
|
||||
eventDatas: dict[str, SandboxEventData]
|
||||
eventSceneDatas: dict[str, SandboxEventSceneData]
|
||||
eventChoiceDatas: dict[str, SandboxEventChoiceData]
|
||||
eventTypeDatas: dict[str, SandboxEventTypeData]
|
||||
missionDatas: dict[str, SandboxMissionData]
|
||||
unitData: dict[str, SandboxUnitData]
|
||||
dailyDescTemplateDatas: dict[str, SandboxDailyDescTemplateData]
|
||||
rushAvgDict: dict[str, str]
|
||||
charStaminaMapping: Dict[str, Dict[str, List[SandboxStaminaData]]]
|
||||
nodeTypeDatas: Dict[str, SandboxNodeTypeData]
|
||||
nodeUpgradeDatas: Dict[str, SandboxNodeUpgradeData]
|
||||
weatherDatas: Dict[str, SandboxWeatherData]
|
||||
stageDatas: Dict[str, SandboxStageData]
|
||||
eventDatas: Dict[str, SandboxEventData]
|
||||
eventSceneDatas: Dict[str, SandboxEventSceneData]
|
||||
eventChoiceDatas: Dict[str, SandboxEventChoiceData]
|
||||
eventTypeDatas: Dict[str, SandboxEventTypeData]
|
||||
missionDatas: Dict[str, SandboxMissionData]
|
||||
unitData: Dict[str, SandboxUnitData]
|
||||
dailyDescTemplateDatas: Dict[str, SandboxDailyDescTemplateData]
|
||||
rushAvgDict: Dict[str, str]
|
||||
rushEnemyGroup: RushEnemyGroup
|
||||
runeDatas: dict[str, RuneTablePackedRuneData]
|
||||
itemRuneList: dict[str, list[LegacyInLevelRuneData]]
|
||||
runeDatas: Dict[str, RuneTablePackedRuneData]
|
||||
itemRuneList: Dict[str, List[LegacyInLevelRuneData]]
|
||||
|
||||
|
||||
class SandboxItemData(BaseModel):
|
||||
class SandboxItemData(BaseStruct):
|
||||
itemId: str
|
||||
itemType: str
|
||||
itemName: str
|
||||
@ -387,13 +390,13 @@ class SandboxItemData(BaseModel):
|
||||
itemDesc: str
|
||||
itemRarity: int
|
||||
sortId: int
|
||||
recommendTypeList: list[str] | None
|
||||
recommendTypeList: Union[List[str], None]
|
||||
recommendPriority: int
|
||||
obtainApproach: str
|
||||
|
||||
|
||||
class SandboxTable(BaseModel):
|
||||
class SandboxTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
sandboxActTables: dict[str, SandboxActTable]
|
||||
itemDatas: dict[str, SandboxItemData]
|
||||
sandboxActTables: Dict[str, SandboxActTable]
|
||||
itemDatas: Dict[str, SandboxItemData]
|
||||
|
@ -1,26 +1,28 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class ShopRecommendData(BaseModel):
|
||||
class ShopRecommendData(BaseStruct):
|
||||
imgId: str
|
||||
slotIndex: int
|
||||
cmd: str
|
||||
param1: str | None
|
||||
param2: str | None
|
||||
skinId: str | None
|
||||
param1: Union[str, None]
|
||||
param2: Union[str, None]
|
||||
skinId: Union[str, None]
|
||||
|
||||
|
||||
class ShopRecommendGroup(BaseModel):
|
||||
recommendGroup: list[int]
|
||||
dataList: list[ShopRecommendData]
|
||||
class ShopRecommendGroup(BaseStruct):
|
||||
recommendGroup: List[int]
|
||||
dataList: List[ShopRecommendData]
|
||||
|
||||
|
||||
class ShopKeeperWord(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ShopKeeperWord(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
text: str
|
||||
|
||||
|
||||
class ShopRecommendItem(BaseModel):
|
||||
class ShopRecommendItem(BaseStruct):
|
||||
tagId: str
|
||||
displayType: str
|
||||
tagName: str
|
||||
@ -28,81 +30,81 @@ class ShopRecommendItem(BaseModel):
|
||||
orderNum: int
|
||||
startDatetime: int
|
||||
endDatetime: int
|
||||
groupList: list[ShopRecommendGroup]
|
||||
groupList: List[ShopRecommendGroup]
|
||||
tagWord: ShopKeeperWord
|
||||
|
||||
|
||||
class ShopCreditUnlockItem(BaseModel):
|
||||
class ShopCreditUnlockItem(BaseStruct):
|
||||
sortId: int
|
||||
unlockNum: int
|
||||
charId: str
|
||||
|
||||
|
||||
class ShopCreditUnlockGroup(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ShopCreditUnlockGroup(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
index: str
|
||||
startDateTime: int
|
||||
charDict: list[ShopCreditUnlockItem]
|
||||
charDict: List[ShopCreditUnlockItem]
|
||||
|
||||
|
||||
class ShopClientDataShopKeeperData(BaseModel):
|
||||
welcomeWords: list[ShopKeeperWord]
|
||||
clickWords: list[ShopKeeperWord]
|
||||
class ShopClientDataShopKeeperData(BaseStruct):
|
||||
welcomeWords: List[ShopKeeperWord]
|
||||
clickWords: List[ShopKeeperWord]
|
||||
|
||||
|
||||
class ShopCarouselDataItem(BaseModel):
|
||||
class ShopCarouselDataItem(BaseStruct):
|
||||
spriteId: str
|
||||
startTime: int
|
||||
endTime: int
|
||||
cmd: str
|
||||
param1: str | None
|
||||
param1: Union[str, None]
|
||||
skinId: str
|
||||
furniId: str
|
||||
|
||||
|
||||
class ShopCarouselData(BaseModel):
|
||||
items: list[ShopCarouselDataItem]
|
||||
class ShopCarouselData(BaseStruct):
|
||||
items: List[ShopCarouselDataItem]
|
||||
|
||||
|
||||
class ChooseShopRelation(BaseModel):
|
||||
class ChooseShopRelation(BaseStruct):
|
||||
goodId: str
|
||||
optionList: list[str]
|
||||
optionList: List[str]
|
||||
|
||||
|
||||
class ShopClientGPData(BaseModel):
|
||||
class ShopClientGPData(BaseStruct):
|
||||
goodId: str
|
||||
displayName: str
|
||||
condTrigPackageType: str
|
||||
|
||||
|
||||
class LMTGSShopSchedule(BaseModel):
|
||||
class LMTGSShopSchedule(BaseStruct):
|
||||
gachaPoolId: str
|
||||
LMTGSId: str
|
||||
iconColor: str
|
||||
iconBackColor: str
|
||||
storeTextColor: str | None = None
|
||||
startTime: int
|
||||
endTime: int
|
||||
storeTextColor: Union[str, None] = None
|
||||
|
||||
|
||||
class LMTGSShopOverlaySchedule(BaseModel):
|
||||
class LMTGSShopOverlaySchedule(BaseStruct):
|
||||
gachaPoolId1: str
|
||||
gachaPoolId2: str
|
||||
picId: str
|
||||
|
||||
|
||||
class ShopClientTable(BaseModel):
|
||||
class ShopClientTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
recommendList: list[ShopRecommendItem]
|
||||
creditUnlockGroup: dict[str, ShopCreditUnlockGroup]
|
||||
recommendList: List[ShopRecommendItem]
|
||||
creditUnlockGroup: Dict[str, ShopCreditUnlockGroup]
|
||||
shopKeeperData: ShopClientDataShopKeeperData
|
||||
carousels: list[ShopCarouselData]
|
||||
chooseShopRelations: list[ChooseShopRelation]
|
||||
shopUnlockDict: dict[str, str]
|
||||
extraQCShopRule: list[str]
|
||||
repQCShopRule: list[str]
|
||||
shopGPDataDict: dict[str, ShopClientGPData]
|
||||
carousels: List[ShopCarouselData]
|
||||
chooseShopRelations: List[ChooseShopRelation]
|
||||
shopUnlockDict: Dict[str, str]
|
||||
extraQCShopRule: List[str]
|
||||
repQCShopRule: List[str]
|
||||
shopGPDataDict: Dict[str, ShopClientGPData]
|
||||
shopMonthlySubGoodId: str
|
||||
ls: list[LMTGSShopSchedule]
|
||||
os: list[LMTGSShopOverlaySchedule]
|
||||
ls: List[LMTGSShopSchedule]
|
||||
os: List[LMTGSShopOverlaySchedule]
|
||||
|
@ -1,51 +1,50 @@
|
||||
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
from msgspec import json as msgjson
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class SpData(BaseModel):
|
||||
class SpData(BaseStruct):
|
||||
spType: int
|
||||
levelUpCost: list[ItemBundle] | None
|
||||
levelUpCost: Union[List[ItemBundle], None]
|
||||
maxChargeTime: int
|
||||
spCost: int
|
||||
initSp: int
|
||||
increment: int | float
|
||||
increment: Union[int, float]
|
||||
|
||||
|
||||
class Blackboard(BaseModel):
|
||||
class Blackboard(BaseStruct):
|
||||
key: str
|
||||
value: int | float | None = None
|
||||
valueStr: str | None = None
|
||||
value: Union[Union[int, float], None] = None
|
||||
valueStr: Union[str, None] = None
|
||||
|
||||
|
||||
class SkillDataBundleLevelData(BaseModel):
|
||||
class SkillDataBundleLevelData(BaseStruct):
|
||||
name: str
|
||||
rangeId: str | None
|
||||
description: str | None
|
||||
rangeId: Union[str, None]
|
||||
description: Union[str, None]
|
||||
skillType: int
|
||||
durationType: int
|
||||
spData: SpData
|
||||
prefabId: str | None
|
||||
duration: int | float
|
||||
blackboard: list[Blackboard]
|
||||
prefabId: Union[str, None]
|
||||
duration: Union[int, float]
|
||||
blackboard: List[Blackboard]
|
||||
|
||||
|
||||
class SkillDataBundle(BaseModel):
|
||||
class SkillDataBundle(BaseStruct):
|
||||
skillId: str
|
||||
iconId: str | None
|
||||
iconId: Union[str, None]
|
||||
hidden: bool
|
||||
levels: list[SkillDataBundleLevelData]
|
||||
levels: List[SkillDataBundleLevelData]
|
||||
|
||||
|
||||
class SkillTable(BaseModel):
|
||||
class SkillTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
skills: dict[str, SkillDataBundle]
|
||||
|
||||
def __init__(self, data: dict) -> None:
|
||||
super().__init__(skills=data)
|
||||
skills: Dict[str, SkillDataBundle]
|
||||
|
@ -1,89 +1,90 @@
|
||||
|
||||
from pydantic import BaseModel
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
|
||||
|
||||
class CharSkinDataTokenSkinInfo(BaseModel):
|
||||
class CharSkinDataTokenSkinInfo(BaseStruct):
|
||||
tokenId: str
|
||||
tokenSkinId: str
|
||||
|
||||
|
||||
class CharSkinDataBattleSkin(BaseModel):
|
||||
class CharSkinDataBattleSkin(BaseStruct):
|
||||
overwritePrefab: bool
|
||||
skinOrPrefabId: str | None
|
||||
skinOrPrefabId: Union[str, None]
|
||||
|
||||
|
||||
class CharSkinDataDisplaySkin(BaseModel):
|
||||
skinName: str | None
|
||||
colorList: list[str] | None
|
||||
titleList: list[str] | None
|
||||
modelName: str | None
|
||||
drawerList: list[str] | None
|
||||
designerList: list[str] | None
|
||||
skinGroupId: str | None
|
||||
skinGroupName: str | None
|
||||
class CharSkinDataDisplaySkin(BaseStruct):
|
||||
skinName: Union[str, None]
|
||||
colorList: Union[List[str], None]
|
||||
titleList: Union[List[str], None]
|
||||
modelName: Union[str, None]
|
||||
drawerList: Union[List[str], None]
|
||||
designerList: Union[List[str], None]
|
||||
skinGroupId: Union[str, None]
|
||||
skinGroupName: Union[str, None]
|
||||
skinGroupSortIndex: int
|
||||
content: str | None
|
||||
dialog: str | None
|
||||
usage: str | None
|
||||
description: str | None
|
||||
obtainApproach: str | None
|
||||
content: Union[str, None]
|
||||
dialog: Union[str, None]
|
||||
usage: Union[str, None]
|
||||
description: Union[str, None]
|
||||
obtainApproach: Union[str, None]
|
||||
sortId: int
|
||||
displayTagId: str | None
|
||||
displayTagId: Union[str, None]
|
||||
getTime: int
|
||||
onYear: int
|
||||
onPeriod: int
|
||||
|
||||
|
||||
class CharSkinData(BaseModel):
|
||||
class CharSkinData(BaseStruct):
|
||||
skinId: str
|
||||
charId: str
|
||||
tokenSkinMap: list[CharSkinDataTokenSkinInfo] | None
|
||||
illustId: str | None
|
||||
dynIllustId: str | None
|
||||
tokenSkinMap: Union[List[CharSkinDataTokenSkinInfo], None]
|
||||
illustId: Union[str, None]
|
||||
dynIllustId: Union[str, None]
|
||||
avatarId: str
|
||||
portraitId: str | None
|
||||
dynPortraitId: str | None
|
||||
dynEntranceId: str | None
|
||||
buildingId: str | None
|
||||
portraitId: Union[str, None]
|
||||
dynPortraitId: Union[str, None]
|
||||
dynEntranceId: Union[str, None]
|
||||
buildingId: Union[str, None]
|
||||
battleSkin: CharSkinDataBattleSkin
|
||||
isBuySkin: bool
|
||||
tmplId: str | None
|
||||
voiceId: str | None
|
||||
tmplId: Union[str, None]
|
||||
voiceId: Union[str, None]
|
||||
voiceType: str
|
||||
displaySkin: CharSkinDataDisplaySkin
|
||||
|
||||
|
||||
class CharSkinGroupInfo(BaseModel):
|
||||
class CharSkinGroupInfo(BaseStruct):
|
||||
skinGroupId: str
|
||||
publishTime: int
|
||||
|
||||
|
||||
class CharSkinKvImgInfo(BaseModel):
|
||||
class CharSkinKvImgInfo(BaseStruct):
|
||||
kvImgId: str
|
||||
linkedSkinGroupId: str
|
||||
|
||||
|
||||
class CharSkinBrandInfo(BaseModel):
|
||||
class CharSkinBrandInfo(BaseStruct):
|
||||
brandId: str
|
||||
groupList: list[CharSkinGroupInfo]
|
||||
kvImgIdList: list[CharSkinKvImgInfo]
|
||||
groupList: List[CharSkinGroupInfo]
|
||||
kvImgIdList: List[CharSkinKvImgInfo]
|
||||
brandName: str
|
||||
brandCapitalName: str
|
||||
description: str
|
||||
publishTime: int
|
||||
sortId: int
|
||||
|
||||
|
||||
class SpecialSkinInfo(BaseModel):
|
||||
class SpecialSkinInfo(BaseStruct):
|
||||
skinId: str
|
||||
startTime: int
|
||||
endTime: int
|
||||
|
||||
|
||||
class SkinTable(BaseModel):
|
||||
class SkinTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
charSkins: dict[str, CharSkinData]
|
||||
buildinEvolveMap: dict[str, dict[str, str]]
|
||||
buildinPatchMap: dict[str, dict[str, str]]
|
||||
brandList: dict[str, CharSkinBrandInfo]
|
||||
specialSkinInfoList: list[SpecialSkinInfo]
|
||||
charSkins: Dict[str, CharSkinData]
|
||||
buildinEvolveMap: Dict[str, Dict[str, str]]
|
||||
buildinPatchMap: Dict[str, Dict[str, str]]
|
||||
brandList: Dict[str, CharSkinBrandInfo]
|
||||
specialSkinInfoList: List[SpecialSkinInfo]
|
||||
|
@ -1,80 +1,82 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class StageDataConditionDesc(BaseModel):
|
||||
class StageDataConditionDesc(BaseStruct):
|
||||
stageId: str
|
||||
completeState: int
|
||||
|
||||
|
||||
class StageDataDisplayRewards(BaseModel):
|
||||
type_: str = Field(alias='type')
|
||||
id_: str = Field(alias='id')
|
||||
class StageDataDisplayRewards(BaseStruct):
|
||||
type_: str = field(name='type')
|
||||
id_: str = field(name='id')
|
||||
dropType: int
|
||||
|
||||
|
||||
class StageDataDisplayDetailRewards(BaseModel):
|
||||
class StageDataDisplayDetailRewards(BaseStruct):
|
||||
occPercent: int
|
||||
type_: str = Field(alias='type')
|
||||
id_: str = Field(alias='id')
|
||||
type_: str = field(name='type')
|
||||
id_: str = field(name='id')
|
||||
dropType: int
|
||||
|
||||
|
||||
class StageDataStageDropInfo(BaseModel):
|
||||
class StageDataStageDropInfo(BaseStruct):
|
||||
firstPassRewards: None
|
||||
firstCompleteRewards: None
|
||||
passRewards: None
|
||||
completeRewards: None
|
||||
displayRewards: list[StageDataDisplayRewards]
|
||||
displayDetailRewards: list[StageDataDisplayDetailRewards]
|
||||
displayRewards: List[StageDataDisplayRewards]
|
||||
displayDetailRewards: List[StageDataDisplayDetailRewards]
|
||||
|
||||
|
||||
class ExtraCondition(BaseModel):
|
||||
class ExtraCondition(BaseStruct):
|
||||
index: int
|
||||
template: str
|
||||
unlockParam: list[str]
|
||||
unlockParam: List[str]
|
||||
|
||||
|
||||
class ProgressInfo(BaseModel):
|
||||
class ProgressInfo(BaseStruct):
|
||||
progressType: str
|
||||
descList: dict[str, str] | None
|
||||
descList: Union[Dict[str, str], None]
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class ExtraInfo(BaseModel):
|
||||
class ExtraInfo(BaseStruct):
|
||||
stageId: str
|
||||
rewards: list[ItemBundle]
|
||||
rewards: List[ItemBundle]
|
||||
progressInfo: ProgressInfo
|
||||
|
||||
|
||||
class StageData(BaseModel):
|
||||
class StageData(BaseStruct):
|
||||
stageType: str
|
||||
difficulty: str
|
||||
performanceStageFlag: str
|
||||
diffGroup: str
|
||||
unlockCondition: list[StageDataConditionDesc]
|
||||
unlockCondition: List[StageDataConditionDesc]
|
||||
stageId: str
|
||||
levelId: str | None
|
||||
levelId: Union[str, None]
|
||||
zoneId: str
|
||||
code: str
|
||||
name: str | None
|
||||
description: str | None
|
||||
hardStagedId: str | None
|
||||
dangerLevel: str | None
|
||||
dangerPoint: int | float
|
||||
name: Union[str, None]
|
||||
description: Union[str, None]
|
||||
hardStagedId: Union[str, None]
|
||||
dangerLevel: Union[str, None]
|
||||
dangerPoint: Union[int, float]
|
||||
loadingPicId: str
|
||||
canPractice: bool
|
||||
canBattleReplay: bool
|
||||
apCost: int
|
||||
apFailReturn: int
|
||||
etItemId: str | None
|
||||
etItemId: Union[str, None]
|
||||
etCost: int
|
||||
etFailReturn: int
|
||||
etButtonStyle: str | None
|
||||
etButtonStyle: Union[str, None]
|
||||
apProtectTimes: int
|
||||
diamondOnceDrop: int
|
||||
practiceTicketCost: int
|
||||
@ -86,7 +88,7 @@ class StageData(BaseModel):
|
||||
passFavor: int
|
||||
completeFavor: int
|
||||
slProgress: int
|
||||
displayMainItem: str | None
|
||||
displayMainItem: Union[str, None]
|
||||
hilightMark: bool
|
||||
bossMark: bool
|
||||
isPredefined: bool
|
||||
@ -95,65 +97,65 @@ class StageData(BaseModel):
|
||||
isStoryOnly: bool
|
||||
appearanceStyle: int
|
||||
stageDropInfo: StageDataStageDropInfo
|
||||
canUseCharm: bool | None = None
|
||||
canUseTech: bool | None = None
|
||||
canUseTrapTool: bool | None = None
|
||||
canUseBattlePerformance: bool | None = None
|
||||
startButtonOverrideId: str | None
|
||||
startButtonOverrideId: Union[str, None]
|
||||
isStagePatch: bool
|
||||
mainStageId: str | None
|
||||
extraCondition: list[ExtraCondition] | None = None
|
||||
extraInfo: list[ExtraInfo] | None = None
|
||||
mainStageId: Union[str, None]
|
||||
canUseCharm: Union[bool, None] = None
|
||||
canUseTech: Union[bool, None] = None
|
||||
canUseTrapTool: Union[bool, None] = None
|
||||
canUseBattlePerformance: Union[bool, None] = None
|
||||
extraCondition: Union[List[ExtraCondition], None] = None
|
||||
extraInfo: Union[List[ExtraInfo], None] = None
|
||||
|
||||
|
||||
class RuneStageGroupDataRuneStageInst(BaseModel):
|
||||
class RuneStageGroupDataRuneStageInst(BaseStruct):
|
||||
stageId: str
|
||||
activePackedRuneIds: list[str]
|
||||
activePackedRuneIds: List[str]
|
||||
|
||||
|
||||
class RuneStageGroupData(BaseModel):
|
||||
class RuneStageGroupData(BaseStruct):
|
||||
groupId: str
|
||||
activeRuneStages: list[RuneStageGroupDataRuneStageInst]
|
||||
activeRuneStages: List[RuneStageGroupDataRuneStageInst]
|
||||
startTs: int
|
||||
endTs: int
|
||||
|
||||
|
||||
class MapThemeData(BaseModel):
|
||||
class MapThemeData(BaseStruct):
|
||||
themeId: str
|
||||
unitColor: str
|
||||
buildableColor: str | None
|
||||
themeType: str | None
|
||||
trapTintColor: str | None
|
||||
buildableColor: Union[str, None]
|
||||
themeType: Union[str, None]
|
||||
trapTintColor: Union[str, None]
|
||||
|
||||
|
||||
class TileAppendInfo(BaseModel):
|
||||
class TileAppendInfo(BaseStruct):
|
||||
tileKey: str
|
||||
name: str
|
||||
description: str
|
||||
isFunctional: bool
|
||||
|
||||
|
||||
class WeeklyForceOpenTable(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class WeeklyForceOpenTable(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
startTime: int
|
||||
endTime: int
|
||||
forceOpenList: list[str]
|
||||
forceOpenList: List[str]
|
||||
|
||||
|
||||
class TimelyDropTimeInfo(BaseModel):
|
||||
class TimelyDropTimeInfo(BaseStruct):
|
||||
startTs: int
|
||||
endTs: int
|
||||
stagePic: str | None
|
||||
dropPicId: str | None
|
||||
stagePic: Union[str, None]
|
||||
dropPicId: Union[str, None]
|
||||
stageUnlock: str
|
||||
entranceDownPicId: str | None
|
||||
entranceUpPicId: str | None
|
||||
entranceDownPicId: Union[str, None]
|
||||
entranceUpPicId: Union[str, None]
|
||||
timelyGroupId: str
|
||||
weeklyPicId: str | None
|
||||
apSupplyOutOfDateDict: dict[str, int]
|
||||
weeklyPicId: Union[str, None]
|
||||
apSupplyOutOfDateDict: Dict[str, int]
|
||||
|
||||
|
||||
class OverrideDropInfo(BaseModel):
|
||||
class OverrideDropInfo(BaseStruct):
|
||||
itemId: str
|
||||
startTs: int
|
||||
endTs: int
|
||||
@ -166,19 +168,19 @@ class OverrideDropInfo(BaseModel):
|
||||
desc3: str
|
||||
dropTag: str
|
||||
dropTypeDesc: str
|
||||
dropInfo: dict[str, StageDataStageDropInfo]
|
||||
dropInfo: Dict[str, StageDataStageDropInfo]
|
||||
|
||||
|
||||
class TimelyDropInfo(BaseModel):
|
||||
dropInfo: dict[str, StageDataStageDropInfo]
|
||||
class TimelyDropInfo(BaseStruct):
|
||||
dropInfo: Dict[str, StageDataStageDropInfo]
|
||||
|
||||
|
||||
class StageValidInfo(BaseModel):
|
||||
class StageValidInfo(BaseStruct):
|
||||
startTs: int
|
||||
endTs: int
|
||||
|
||||
|
||||
class StageFogInfo(BaseModel):
|
||||
class StageFogInfo(BaseStruct):
|
||||
lockId: str
|
||||
fogType: str
|
||||
stageId: str
|
||||
@ -188,70 +190,71 @@ class StageFogInfo(BaseModel):
|
||||
unlockItemType: str
|
||||
unlockItemNum: int
|
||||
preposedStageId: str
|
||||
preposedLockId: str | None
|
||||
preposedLockId: Union[str, None]
|
||||
|
||||
|
||||
class StageStartCondRequireChar(BaseModel):
|
||||
class StageStartCondRequireChar(BaseStruct):
|
||||
charId: str
|
||||
evolvePhase: int
|
||||
|
||||
|
||||
class StageStartCond(BaseModel):
|
||||
requireChars: list[StageStartCondRequireChar]
|
||||
excludeAssists: list[str]
|
||||
class StageStartCond(BaseStruct):
|
||||
requireChars: List[StageStartCondRequireChar]
|
||||
excludeAssists: List[str]
|
||||
isNotPass: bool
|
||||
|
||||
|
||||
class StageDiffGroupTable(BaseModel):
|
||||
class StageDiffGroupTable(BaseStruct):
|
||||
normalId: str
|
||||
toughId: str | None
|
||||
toughId: Union[str, None]
|
||||
easyId: str
|
||||
|
||||
|
||||
class StoryStageShowGroup(BaseModel):
|
||||
class StoryStageShowGroup(BaseStruct):
|
||||
displayRecordId: str
|
||||
stageId: str
|
||||
accordingStageId: str | None
|
||||
accordingStageId: Union[str, None]
|
||||
diffGroup: int
|
||||
|
||||
|
||||
class SpecialBattleFinishStageData(BaseModel):
|
||||
class SpecialBattleFinishStageData(BaseStruct):
|
||||
stageId: str
|
||||
skipAccomplishPerform: bool
|
||||
|
||||
|
||||
class RecordRewardServerData(BaseModel):
|
||||
class RecordRewardServerData(BaseStruct):
|
||||
stageId: str
|
||||
rewards: list[ItemBundle]
|
||||
rewards: List[ItemBundle]
|
||||
|
||||
|
||||
class ApProtectZoneInfoTimeRange(BaseModel):
|
||||
class ApProtectZoneInfoTimeRange(BaseStruct):
|
||||
startTs: int
|
||||
endTs: int
|
||||
|
||||
|
||||
class ApProtectZoneInfo(BaseModel):
|
||||
class ApProtectZoneInfo(BaseStruct):
|
||||
zoneId: str
|
||||
timeRanges: list[ApProtectZoneInfoTimeRange]
|
||||
timeRanges: List[ApProtectZoneInfoTimeRange]
|
||||
|
||||
|
||||
class StageTable(BaseModel):
|
||||
class StageTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
stages: dict[str, StageData]
|
||||
runeStageGroups: dict[str, RuneStageGroupData]
|
||||
mapThemes: dict[str, MapThemeData]
|
||||
tileInfo: dict[str, TileAppendInfo]
|
||||
forceOpenTable: dict[str, WeeklyForceOpenTable]
|
||||
timelyStageDropInfo: dict[str, TimelyDropTimeInfo]
|
||||
overrideDropInfo: dict[str, OverrideDropInfo]
|
||||
timelyTable: dict[str, TimelyDropInfo]
|
||||
stageValidInfo: dict[str, StageValidInfo]
|
||||
stageFogInfo: dict[str, StageFogInfo]
|
||||
stageStartConds: dict[str, StageStartCond]
|
||||
diffGroupTable: dict[str, StageDiffGroupTable]
|
||||
storyStageShowGroup: dict[str, dict[str, StoryStageShowGroup]]
|
||||
specialBattleFinishStageData: dict[str, SpecialBattleFinishStageData]
|
||||
recordRewardData: dict[str, RecordRewardServerData] | None
|
||||
apProtectZoneInfo: dict[str, ApProtectZoneInfo]
|
||||
spNormalStageIdFor4StarList: list[str]
|
||||
stages: Dict[str, StageData]
|
||||
runeStageGroups: Dict[str, RuneStageGroupData]
|
||||
mapThemes: Dict[str, MapThemeData]
|
||||
tileInfo: Dict[str, TileAppendInfo]
|
||||
forceOpenTable: Dict[str, WeeklyForceOpenTable]
|
||||
timelyStageDropInfo: Dict[str, TimelyDropTimeInfo]
|
||||
overrideDropInfo: Dict[str, OverrideDropInfo]
|
||||
timelyTable: Dict[str, TimelyDropInfo]
|
||||
stageValidInfo: Dict[str, StageValidInfo]
|
||||
stageFogInfo: Dict[str, StageFogInfo]
|
||||
stageStartConds: Dict[str, StageStartCond]
|
||||
diffGroupTable: Dict[str, StageDiffGroupTable]
|
||||
storyStageShowGroup: Dict[str, Dict[str, StoryStageShowGroup]]
|
||||
specialBattleFinishStageData: Dict[str, SpecialBattleFinishStageData]
|
||||
recordRewardData: Union[Dict[str, RecordRewardServerData], None]
|
||||
apProtectZoneInfo: Dict[str, ApProtectZoneInfo]
|
||||
actCustomStageDatas: Dict[str, Dict[str, str]]
|
||||
spNormalStageIdFor4StarList: List[str]
|
||||
|
@ -1,18 +1,20 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class MiniActTrialDataRuleData(BaseModel):
|
||||
class MiniActTrialDataRuleData(BaseStruct):
|
||||
ruleType: str
|
||||
ruleText: str
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class MiniActTrialDataMiniActTrialRewardData(BaseModel):
|
||||
class MiniActTrialDataMiniActTrialRewardData(BaseStruct):
|
||||
trialRewardId: str
|
||||
orderId: int
|
||||
actId: str
|
||||
@ -20,55 +22,55 @@ class MiniActTrialDataMiniActTrialRewardData(BaseModel):
|
||||
item: ItemBundle
|
||||
|
||||
|
||||
class MiniActTrialDataMiniActTrialSingleData(BaseModel):
|
||||
class MiniActTrialDataMiniActTrialSingleData(BaseStruct):
|
||||
actId: str
|
||||
rewardStartTime: int
|
||||
themeColor: str
|
||||
rewardList: list[MiniActTrialDataMiniActTrialRewardData]
|
||||
rewardList: List[MiniActTrialDataMiniActTrialRewardData]
|
||||
|
||||
|
||||
class MiniActTrialData(BaseModel):
|
||||
class MiniActTrialData(BaseStruct):
|
||||
preShowDays: int
|
||||
ruleDataList: list[MiniActTrialDataRuleData]
|
||||
miniActTrialDataMap: dict[str, MiniActTrialDataMiniActTrialSingleData]
|
||||
ruleDataList: List[MiniActTrialDataRuleData]
|
||||
miniActTrialDataMap: Dict[str, MiniActTrialDataMiniActTrialSingleData]
|
||||
|
||||
|
||||
class ActArchiveResDataPicArchiveResItemData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ActArchiveResDataPicArchiveResItemData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
desc: str
|
||||
assetPath: str
|
||||
type_: str = Field(alias='type')
|
||||
subType: str | None
|
||||
type_: str = field(name='type')
|
||||
subType: Union[str, None]
|
||||
picDescription: str
|
||||
kvId: str | None
|
||||
kvId: Union[str, None]
|
||||
|
||||
|
||||
class ActArchiveResDataAudioArchiveResItemData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ActArchiveResDataAudioArchiveResItemData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
desc: str
|
||||
name: str
|
||||
|
||||
|
||||
class ActArchiveResDataAvgArchiveResItemData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ActArchiveResDataAvgArchiveResItemData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
desc: str
|
||||
breifPath: str | None
|
||||
breifPath: Union[str, None]
|
||||
contentPath: str
|
||||
imagePath: str
|
||||
rawBrief: str | None
|
||||
titleIconPath: str | None
|
||||
rawBrief: Union[str, None]
|
||||
titleIconPath: Union[str, None]
|
||||
|
||||
|
||||
class ActArchiveResDataStoryArchiveResItemData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ActArchiveResDataStoryArchiveResItemData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
desc: str
|
||||
date: str | None
|
||||
date: Union[str, None]
|
||||
pic: str
|
||||
text: str
|
||||
titlePic: str | None
|
||||
titlePic: Union[str, None]
|
||||
|
||||
|
||||
class ActArchiveResDataNewsFormatData(BaseModel):
|
||||
class ActArchiveResDataNewsFormatData(BaseStruct):
|
||||
typeId: str
|
||||
typeName: str
|
||||
typeLogo: str
|
||||
@ -76,13 +78,13 @@ class ActArchiveResDataNewsFormatData(BaseModel):
|
||||
typeMainSealing: str
|
||||
|
||||
|
||||
class ActArchiveResDataActivityNewsLine(BaseModel):
|
||||
class ActArchiveResDataActivityNewsLine(BaseStruct):
|
||||
lineType: int
|
||||
content: str
|
||||
|
||||
|
||||
class ActArchiveResDataNewsArchiveResItemData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ActArchiveResDataNewsArchiveResItemData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
desc: str
|
||||
newsType: str
|
||||
newsFormat: ActArchiveResDataNewsFormatData
|
||||
@ -91,10 +93,10 @@ class ActArchiveResDataNewsArchiveResItemData(BaseModel):
|
||||
paramP0: int
|
||||
paramK: int
|
||||
paramR: float
|
||||
newsLines: list[ActArchiveResDataActivityNewsLine]
|
||||
newsLines: List[ActArchiveResDataActivityNewsLine]
|
||||
|
||||
|
||||
class ActArchiveResDataLandmarkArchiveResItemData(BaseModel):
|
||||
class ActArchiveResDataLandmarkArchiveResItemData(BaseStruct):
|
||||
landmarkId: str
|
||||
landmarkName: str
|
||||
landmarkPic: str
|
||||
@ -102,111 +104,111 @@ class ActArchiveResDataLandmarkArchiveResItemData(BaseModel):
|
||||
landmarkEngName: str
|
||||
|
||||
|
||||
class ActArchiveResDataLogArchiveResItemData(BaseModel):
|
||||
class ActArchiveResDataLogArchiveResItemData(BaseStruct):
|
||||
logId: str
|
||||
logDesc: str
|
||||
|
||||
|
||||
class ActArchiveResData(BaseModel):
|
||||
pics: dict[str, ActArchiveResDataPicArchiveResItemData]
|
||||
audios: dict[str, ActArchiveResDataAudioArchiveResItemData]
|
||||
avgs: dict[str, ActArchiveResDataAvgArchiveResItemData]
|
||||
stories: dict[str, ActArchiveResDataStoryArchiveResItemData]
|
||||
news: dict[str, ActArchiveResDataNewsArchiveResItemData]
|
||||
landmarks: dict[str, ActArchiveResDataLandmarkArchiveResItemData]
|
||||
logs: dict[str, ActArchiveResDataLogArchiveResItemData]
|
||||
class ActArchiveResData(BaseStruct):
|
||||
pics: Dict[str, ActArchiveResDataPicArchiveResItemData]
|
||||
audios: Dict[str, ActArchiveResDataAudioArchiveResItemData]
|
||||
avgs: Dict[str, ActArchiveResDataAvgArchiveResItemData]
|
||||
stories: Dict[str, ActArchiveResDataStoryArchiveResItemData]
|
||||
news: Dict[str, ActArchiveResDataNewsArchiveResItemData]
|
||||
landmarks: Dict[str, ActArchiveResDataLandmarkArchiveResItemData]
|
||||
logs: Dict[str, ActArchiveResDataLogArchiveResItemData]
|
||||
|
||||
|
||||
class ActArchiveTimelineItemData(BaseModel):
|
||||
class ActArchiveTimelineItemData(BaseStruct):
|
||||
timelineId: str
|
||||
timelineSortId: int
|
||||
timelineTitle: str
|
||||
timelineDes: str
|
||||
picIdList: list[str] | None = None
|
||||
audioIdList: list[str] | None = None
|
||||
avgIdList: list[str] | None = None
|
||||
storyIdList: list[str] | None = None
|
||||
newsIdList: list[str] | None = None
|
||||
picIdList: Union[List[str], None] = None
|
||||
audioIdList: Union[List[str], None] = None
|
||||
avgIdList: Union[List[str], None] = None
|
||||
storyIdList: Union[List[str], None] = None
|
||||
newsIdList: Union[List[str], None] = None
|
||||
|
||||
|
||||
class ActArchiveTimelineData(BaseModel):
|
||||
timelineList: list[ActArchiveTimelineItemData]
|
||||
class ActArchiveTimelineData(BaseStruct):
|
||||
timelineList: List[ActArchiveTimelineItemData]
|
||||
|
||||
|
||||
class ActArchiveMusicItemData(BaseModel):
|
||||
class ActArchiveMusicItemData(BaseStruct):
|
||||
musicId: str
|
||||
musicSortId: int
|
||||
|
||||
|
||||
class ActArchiveMusicData(BaseModel):
|
||||
musics: dict[str, ActArchiveMusicItemData]
|
||||
class ActArchiveMusicData(BaseStruct):
|
||||
musics: Dict[str, ActArchiveMusicItemData]
|
||||
|
||||
|
||||
class ActArchivePicItemData(BaseModel):
|
||||
class ActArchivePicItemData(BaseStruct):
|
||||
picId: str
|
||||
picSortId: int
|
||||
|
||||
|
||||
class ActArchivePicData(BaseModel):
|
||||
pics: dict[str, ActArchivePicItemData]
|
||||
class ActArchivePicData(BaseStruct):
|
||||
pics: Dict[str, ActArchivePicItemData]
|
||||
|
||||
|
||||
class ActArchiveStoryItemData(BaseModel):
|
||||
class ActArchiveStoryItemData(BaseStruct):
|
||||
storyId: str
|
||||
storySortId: int
|
||||
|
||||
|
||||
class ActArchiveStoryData(BaseModel):
|
||||
stories: dict[str, ActArchiveStoryItemData]
|
||||
class ActArchiveStoryData(BaseStruct):
|
||||
stories: Dict[str, ActArchiveStoryItemData]
|
||||
|
||||
|
||||
class ActArchiveAvgItemData(BaseModel):
|
||||
class ActArchiveAvgItemData(BaseStruct):
|
||||
avgId: str
|
||||
avgSortId: int
|
||||
|
||||
|
||||
class ActArchiveAvgData(BaseModel):
|
||||
avgs: dict[str, ActArchiveAvgItemData]
|
||||
class ActArchiveAvgData(BaseStruct):
|
||||
avgs: Dict[str, ActArchiveAvgItemData]
|
||||
|
||||
|
||||
class ActArchiveNewsItemData(BaseModel):
|
||||
class ActArchiveNewsItemData(BaseStruct):
|
||||
newsId: str
|
||||
newsSortId: int
|
||||
|
||||
|
||||
class ActArchiveNewsData(BaseModel):
|
||||
news: dict[str, ActArchiveNewsItemData]
|
||||
class ActArchiveNewsData(BaseStruct):
|
||||
news: Dict[str, ActArchiveNewsItemData]
|
||||
|
||||
|
||||
class ActArchiveLandmarkItemData(BaseModel):
|
||||
class ActArchiveLandmarkItemData(BaseStruct):
|
||||
landmarkId: str
|
||||
landmarkSortId: int
|
||||
|
||||
|
||||
class ActArchiveChapterLogData(BaseModel):
|
||||
class ActArchiveChapterLogData(BaseStruct):
|
||||
chapterName: str
|
||||
displayId: str
|
||||
unlockDes: str
|
||||
logs: list[str]
|
||||
logs: List[str]
|
||||
chapterIcon: str
|
||||
|
||||
|
||||
class ActArchiveComponentData(BaseModel):
|
||||
timeline: ActArchiveTimelineData | None = None
|
||||
music: ActArchiveMusicData | None = None
|
||||
class ActArchiveComponentData(BaseStruct):
|
||||
pic: ActArchivePicData
|
||||
story: ActArchiveStoryData | None = None
|
||||
avg: ActArchiveAvgData | None = None
|
||||
news: ActArchiveNewsData | None = None
|
||||
landmark: dict[str, ActArchiveLandmarkItemData] | None = None
|
||||
log: dict[str, ActArchiveChapterLogData] | None = None
|
||||
timeline: Union[ActArchiveTimelineData, None] = None
|
||||
music: Union[ActArchiveMusicData, None] = None
|
||||
story: Union[ActArchiveStoryData, None] = None
|
||||
avg: Union[ActArchiveAvgData, None] = None
|
||||
news: Union[ActArchiveNewsData, None] = None
|
||||
landmark: Union[Dict[str, ActArchiveLandmarkItemData], None] = None
|
||||
log: Union[Dict[str, ActArchiveChapterLogData], None] = None
|
||||
|
||||
|
||||
class ActArchiveComponentTable(BaseModel):
|
||||
components: dict[str, ActArchiveComponentData]
|
||||
class ActArchiveComponentTable(BaseStruct):
|
||||
components: Dict[str, ActArchiveComponentData]
|
||||
|
||||
|
||||
class StoryReviewMetaTable(BaseModel):
|
||||
class StoryReviewMetaTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
miniActTrialData: MiniActTrialData
|
||||
|
@ -1,42 +1,45 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
from msgspec import json as msgjson
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class StoryDataConditionStageCondition(BaseModel):
|
||||
class StoryDataConditionStageCondition(BaseStruct):
|
||||
stageId: str
|
||||
minState: int
|
||||
maxState: int
|
||||
|
||||
|
||||
class StoryReviewInfoClientData(BaseModel):
|
||||
class StoryReviewInfoClientData(BaseStruct):
|
||||
storyReviewType: int
|
||||
storyId: str
|
||||
storyGroup: str
|
||||
storySort: int
|
||||
storyDependence: str | None
|
||||
storyDependence: Union[str, None]
|
||||
storyCanShow: int
|
||||
storyCode: str | None
|
||||
storyCode: Union[str, None]
|
||||
storyName: str
|
||||
storyPic: str | None
|
||||
storyPic: Union[str, None]
|
||||
storyInfo: str
|
||||
storyCanEnter: int
|
||||
storyTxt: str
|
||||
avgTag: str
|
||||
unLockType: str
|
||||
costItemType: str
|
||||
costItemId: str | None
|
||||
costItemId: Union[str, None]
|
||||
costItemCount: int
|
||||
stageCount: int
|
||||
requiredStages: list[StoryDataConditionStageCondition] | None
|
||||
requiredStages: Union[List[StoryDataConditionStageCondition], None]
|
||||
|
||||
|
||||
class StoryReviewGroupClientData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class StoryReviewGroupClientData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
name: str
|
||||
entryType: str
|
||||
actType: str
|
||||
@ -46,19 +49,16 @@ class StoryReviewGroupClientData(BaseModel):
|
||||
endShowTime: int
|
||||
remakeStartTime: int
|
||||
remakeEndTime: int
|
||||
storyEntryPicId: str | None
|
||||
storyPicId: str | None
|
||||
storyMainColor: str | None
|
||||
storyEntryPicId: Union[str, None]
|
||||
storyPicId: Union[str, None]
|
||||
storyMainColor: Union[str, None]
|
||||
customType: int
|
||||
storyCompleteMedalId: str | None
|
||||
rewards: list[ItemBundle] | None
|
||||
infoUnlockDatas: list[StoryReviewInfoClientData]
|
||||
storyCompleteMedalId: Union[str, None]
|
||||
rewards: Union[List[ItemBundle], None]
|
||||
infoUnlockDatas: List[StoryReviewInfoClientData]
|
||||
|
||||
|
||||
class StoryReviewTable(BaseModel):
|
||||
class StoryReviewTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
storyreviewtable: dict[str, StoryReviewGroupClientData]
|
||||
|
||||
def __init__(self, data: dict) -> None:
|
||||
super().__init__(storyreviewtable=data)
|
||||
storyreviewtable: Dict[str, StoryReviewGroupClientData]
|
||||
|
@ -1,50 +1,50 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
from msgspec import json as msgjson
|
||||
|
||||
|
||||
class StoryDataTrigger(BaseModel):
|
||||
type_: str = Field(alias='type')
|
||||
key: str | None
|
||||
class StoryDataTrigger(BaseStruct):
|
||||
type_: str = field(name='type')
|
||||
key: Union[str, None]
|
||||
useRegex: bool
|
||||
|
||||
|
||||
class StoryDataConditionStageCondition(BaseModel):
|
||||
class StoryDataConditionStageCondition(BaseStruct):
|
||||
stageId: str
|
||||
minState: int
|
||||
maxState: int
|
||||
|
||||
|
||||
class StoryDataCondition(BaseModel):
|
||||
class StoryDataCondition(BaseStruct):
|
||||
minProgress: int
|
||||
maxProgress: int
|
||||
minPlayerLevel: int
|
||||
requiredFlags: list[str]
|
||||
excludedFlags: list[str]
|
||||
requiredStages: list[StoryDataConditionStageCondition]
|
||||
requiredFlags: List[str]
|
||||
excludedFlags: List[str]
|
||||
requiredStages: List[StoryDataConditionStageCondition]
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class StoryData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class StoryData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
needCommit: bool
|
||||
repeatable: bool
|
||||
disabled: bool
|
||||
videoResource: bool
|
||||
trigger: StoryDataTrigger
|
||||
condition: StoryDataCondition | None
|
||||
condition: Union[StoryDataCondition, None]
|
||||
setProgress: int
|
||||
setFlags: list[str] | None
|
||||
completedRewards: list[ItemBundle] | None
|
||||
setFlags: Union[List[str], None]
|
||||
completedRewards: Union[List[ItemBundle], None]
|
||||
|
||||
|
||||
class StoryTable(BaseModel):
|
||||
class StoryTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
stories: dict[str, StoryData]
|
||||
|
||||
def __init__(self, data: dict) -> None:
|
||||
super().__init__(stories=data)
|
||||
stories: Dict[str, StoryData]
|
||||
|
@ -1,36 +1,38 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class RuneDataSelector(BaseModel):
|
||||
class RuneDataSelector(BaseStruct):
|
||||
professionMask: int
|
||||
buildableMask: int
|
||||
charIdFilter: list[str] | None
|
||||
enemyIdFilter: list[str] | None
|
||||
skillIdFilter: list[str] | None
|
||||
tileKeyFilter: list[str] | None
|
||||
charIdFilter: Union[List[str], None]
|
||||
enemyIdFilter: Union[List[str], None]
|
||||
skillIdFilter: Union[List[str], None]
|
||||
tileKeyFilter: Union[List[str], None]
|
||||
|
||||
|
||||
class Blackboard(BaseModel):
|
||||
class Blackboard(BaseStruct):
|
||||
key: str
|
||||
value: float | None = None
|
||||
valueStr: str | None = None
|
||||
value: Union[float, None] = None
|
||||
valueStr: Union[str, None] = None
|
||||
|
||||
|
||||
class RuneData(BaseModel):
|
||||
class RuneData(BaseStruct):
|
||||
key: str
|
||||
selector: RuneDataSelector
|
||||
blackboard: list[Blackboard]
|
||||
blackboard: List[Blackboard]
|
||||
|
||||
|
||||
class PackedRuneData(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class PackedRuneData(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
points: float
|
||||
mutexGroupKey: str | None
|
||||
mutexGroupKey: Union[str, None]
|
||||
description: str
|
||||
runes: list[RuneData]
|
||||
runes: List[RuneData]
|
||||
|
||||
|
||||
class TechBuffTable(BaseModel):
|
||||
class TechBuffTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
runes: list[PackedRuneData]
|
||||
runes: List[PackedRuneData]
|
||||
|
@ -1,21 +1,22 @@
|
||||
from pydantic import BaseModel
|
||||
from typing import List
|
||||
from ..common import BaseStruct
|
||||
|
||||
|
||||
class TipData(BaseModel):
|
||||
class TipData(BaseStruct):
|
||||
tip: str
|
||||
weight: float
|
||||
category: str
|
||||
|
||||
|
||||
class WorldViewTip(BaseModel):
|
||||
class WorldViewTip(BaseStruct):
|
||||
title: str
|
||||
description: str
|
||||
backgroundPicId: str
|
||||
weight: float
|
||||
|
||||
|
||||
class TipTable(BaseModel):
|
||||
class TipTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
tips: list[TipData]
|
||||
worldViewTips: list[WorldViewTip]
|
||||
tips: List[TipData]
|
||||
worldViewTips: List[WorldViewTip]
|
||||
|
@ -1,36 +1,37 @@
|
||||
from pydantic import BaseModel, Field
|
||||
|
||||
# 部分数据似乎不是float类型,等之后问问dice吧awa
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
from msgspec import json as msgjson
|
||||
|
||||
|
||||
class CharacterDataUnlockCondition(BaseModel):
|
||||
class CharacterDataUnlockCondition(BaseStruct):
|
||||
phase: int
|
||||
level: int
|
||||
|
||||
|
||||
class Blackboard(BaseModel):
|
||||
class Blackboard(BaseStruct):
|
||||
key: str
|
||||
value: float | None = None
|
||||
valueStr: str | None = None
|
||||
value: Union[float, None] = None
|
||||
valueStr: Union[str, None] = None
|
||||
|
||||
|
||||
class CharacterDataTraitData(BaseModel):
|
||||
class CharacterDataTraitData(BaseStruct):
|
||||
unlockCondition: CharacterDataUnlockCondition
|
||||
requiredPotentialRank: int
|
||||
blackboard: list[Blackboard]
|
||||
overrideDescripton: str | None
|
||||
prefabKey: str | None
|
||||
rangeId: str | None
|
||||
blackboard: List[Blackboard]
|
||||
overrideDescripton: Union[str, None]
|
||||
prefabKey: Union[str, None]
|
||||
rangeId: Union[str, None]
|
||||
|
||||
|
||||
class CharacterDataTraitDataBundle(BaseModel):
|
||||
candidates: list[CharacterDataTraitData]
|
||||
class CharacterDataTraitDataBundle(BaseStruct):
|
||||
candidates: List[CharacterDataTraitData]
|
||||
|
||||
|
||||
class AttributesData(BaseModel):
|
||||
class AttributesData(BaseStruct):
|
||||
maxHp: int
|
||||
atk: int
|
||||
def_: int = Field(..., alias='def')
|
||||
def_: int = field(name='def')
|
||||
magicResistance: float
|
||||
cost: int
|
||||
blockCnt: int
|
||||
@ -52,54 +53,54 @@ class AttributesData(BaseModel):
|
||||
levitateImmune: bool
|
||||
|
||||
|
||||
class CharacterDataAttributesKeyFrame(BaseModel):
|
||||
class CharacterDataAttributesKeyFrame(BaseStruct):
|
||||
level: int
|
||||
data: AttributesData
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(..., alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(..., alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class CharacterDataPhaseData(BaseModel):
|
||||
class CharacterDataPhaseData(BaseStruct):
|
||||
characterPrefabKey: str
|
||||
rangeId: str | None
|
||||
rangeId: Union[str, None]
|
||||
maxLevel: int
|
||||
attributesKeyFrames: list[CharacterDataAttributesKeyFrame]
|
||||
evolveCost: list[ItemBundle] | None
|
||||
attributesKeyFrames: List[CharacterDataAttributesKeyFrame]
|
||||
evolveCost: Union[List[ItemBundle], None]
|
||||
|
||||
|
||||
class CharacterDataMainSkillSpecializeLevelData(BaseModel):
|
||||
class CharacterDataMainSkillSpecializeLevelData(BaseStruct):
|
||||
unlockCond: CharacterDataUnlockCondition
|
||||
lvlUpTime: int
|
||||
levelUpCost: list[ItemBundle] | None
|
||||
levelUpCost: Union[List[ItemBundle], None]
|
||||
|
||||
|
||||
class CharacterDataMainSkill(BaseModel):
|
||||
skillId: str | None
|
||||
overridePrefabKey: str | None
|
||||
overrideTokenKey: str | None
|
||||
levelUpCostCond: list[CharacterDataMainSkillSpecializeLevelData]
|
||||
class CharacterDataMainSkill(BaseStruct):
|
||||
skillId: Union[str, None]
|
||||
overridePrefabKey: Union[str, None]
|
||||
overrideTokenKey: Union[str, None]
|
||||
levelUpCostCond: List[CharacterDataMainSkillSpecializeLevelData]
|
||||
unlockCond: CharacterDataUnlockCondition
|
||||
|
||||
|
||||
class TalentData(BaseModel):
|
||||
class TalentData(BaseStruct):
|
||||
unlockCondition: CharacterDataUnlockCondition
|
||||
requiredPotentialRank: int
|
||||
prefabKey: str
|
||||
name: str | None
|
||||
description: str | None
|
||||
rangeId: str | None
|
||||
blackboard: list[Blackboard]
|
||||
name: Union[str, None]
|
||||
description: Union[str, None]
|
||||
rangeId: Union[str, None]
|
||||
blackboard: List[Blackboard]
|
||||
|
||||
|
||||
class CharacterDataTalentDataBundle(BaseModel):
|
||||
candidates: list[TalentData] | None
|
||||
class CharacterDataTalentDataBundle(BaseStruct):
|
||||
candidates: Union[List[TalentData], None]
|
||||
|
||||
|
||||
class AttributeModifierDataAttributeModifier(BaseModel):
|
||||
class AttributeModifierDataAttributeModifier(BaseStruct):
|
||||
attributeType: int
|
||||
formulaItem: int
|
||||
value: float
|
||||
@ -107,70 +108,67 @@ class AttributeModifierDataAttributeModifier(BaseModel):
|
||||
fetchBaseValueFromSourceEntity: bool
|
||||
|
||||
|
||||
class AttributeModifierData(BaseModel):
|
||||
abnormalFlags: list[str] | None
|
||||
abnormalImmunes: list[str] | None
|
||||
abnormalAntis: list[str] | None
|
||||
abnormalCombos: list[str] | None
|
||||
abnormalComboImmunes: list[str] | None
|
||||
attributeModifiers: list[AttributeModifierDataAttributeModifier]
|
||||
class AttributeModifierData(BaseStruct):
|
||||
abnormalFlags: Union[List[str], None]
|
||||
abnormalImmunes: Union[List[str], None]
|
||||
abnormalAntis: Union[List[str], None]
|
||||
abnormalCombos: Union[List[str], None]
|
||||
abnormalComboImmunes: Union[List[str], None]
|
||||
attributeModifiers: List[AttributeModifierDataAttributeModifier]
|
||||
|
||||
|
||||
class ExternalBuff(BaseModel):
|
||||
class ExternalBuff(BaseStruct):
|
||||
attributes: AttributeModifierData
|
||||
|
||||
|
||||
class CharacterDataPotentialRank(BaseModel):
|
||||
type_: int = Field(..., alias='type')
|
||||
class CharacterDataPotentialRank(BaseStruct):
|
||||
type_: int = field(name='type')
|
||||
description: str
|
||||
buff: ExternalBuff | None
|
||||
equivalentCost: ItemBundle | None
|
||||
buff: Union[ExternalBuff, None]
|
||||
equivalentCost: Union[ItemBundle, None]
|
||||
|
||||
|
||||
class CharacterDataSkillLevelCost(BaseModel):
|
||||
class CharacterDataSkillLevelCost(BaseStruct):
|
||||
unlockCond: CharacterDataUnlockCondition
|
||||
lvlUpCost: list[ItemBundle] | None
|
||||
lvlUpCost: Union[List[ItemBundle], None]
|
||||
|
||||
|
||||
class CharacterData(BaseModel):
|
||||
class TokenCharacterData(BaseStruct):
|
||||
name: str
|
||||
description: str | None
|
||||
description: Union[str, None]
|
||||
canUseGeneralPotentialItem: bool
|
||||
canUseActivityPotentialItem: bool
|
||||
potentialItemId: str | None
|
||||
activityPotentialItemId: str | None
|
||||
nationId: str | None
|
||||
groupId: str | None
|
||||
teamId: str | None
|
||||
displayNumber: str | None
|
||||
tokenKey: str | None = None
|
||||
potentialItemId: Union[str, None]
|
||||
activityPotentialItemId: Union[str, None]
|
||||
nationId: Union[str, None]
|
||||
groupId: Union[str, None]
|
||||
teamId: Union[str, None]
|
||||
displayNumber: Union[str, None]
|
||||
appellation: str
|
||||
position: str
|
||||
tagList: list[str] | None
|
||||
itemUsage: str | None
|
||||
itemDesc: str | None
|
||||
itemObtainApproach: str | None
|
||||
tagList: Union[List[str], None]
|
||||
itemUsage: Union[str, None]
|
||||
itemDesc: Union[str, None]
|
||||
itemObtainApproach: Union[str, None]
|
||||
isNotObtainable: bool
|
||||
isSpChar: bool
|
||||
maxPotentialLevel: int
|
||||
rarity: int
|
||||
profession: str
|
||||
subProfessionId: str
|
||||
trait: CharacterDataTraitDataBundle | None
|
||||
phases: list[CharacterDataPhaseData]
|
||||
skills: list[CharacterDataMainSkill] | None
|
||||
talents: list[CharacterDataTalentDataBundle] | None
|
||||
potentialRanks: list[CharacterDataPotentialRank] | None
|
||||
favorKeyFrames: list[CharacterDataAttributesKeyFrame] | None
|
||||
allSkillLvlup: list[CharacterDataSkillLevelCost] | None
|
||||
trait: Union[CharacterDataTraitDataBundle, None]
|
||||
phases: List[CharacterDataPhaseData]
|
||||
skills: Union[List[CharacterDataMainSkill], None]
|
||||
talents: Union[List[CharacterDataTalentDataBundle], None]
|
||||
potentialRanks: Union[List[CharacterDataPotentialRank], None]
|
||||
favorKeyFrames: Union[List[CharacterDataAttributesKeyFrame], None]
|
||||
allSkillLvlup: Union[List[CharacterDataSkillLevelCost], None]
|
||||
minPowerId: str
|
||||
maxPowerId: str
|
||||
tokenKey: Union[str, None] = None
|
||||
|
||||
|
||||
class TokenTable(BaseModel):
|
||||
class TokenTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
tokens: dict[str, CharacterData]
|
||||
|
||||
def __init__(self, data: dict) -> None:
|
||||
super().__init__(tokens=data)
|
||||
tokens: Dict[str, TokenCharacterData]
|
||||
|
@ -1,25 +1,27 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class UnlockCondition(BaseModel):
|
||||
class UnlockCondition(BaseStruct):
|
||||
phase: int
|
||||
level: int
|
||||
|
||||
|
||||
class TraitDescBundle(BaseModel):
|
||||
class TraitDescBundle(BaseStruct):
|
||||
unlockCondition: UnlockCondition
|
||||
requiredPotentialRank: int
|
||||
overrideDescription: None
|
||||
additiveDescription: str
|
||||
|
||||
|
||||
class UniEquipData(BaseModel):
|
||||
class UniEquipData(BaseStruct):
|
||||
uniEquipId: str
|
||||
uniEquipName: str
|
||||
uniEquipIcon: str
|
||||
@ -33,31 +35,31 @@ class UniEquipData(BaseModel):
|
||||
showLevel: int
|
||||
unlockLevel: int
|
||||
unlockFavorPercent: int
|
||||
missionList: list[str]
|
||||
itemCost: list[ItemBundle] | None
|
||||
type_: str = Field(..., alias='type')
|
||||
traitDescBundle: list[TraitDescBundle]
|
||||
missionList: List[str]
|
||||
itemCost: Union[List[ItemBundle], None]
|
||||
type_: str = field(name='type')
|
||||
traitDescBundle: List[TraitDescBundle]
|
||||
|
||||
|
||||
class UniEquipMissionData(BaseModel):
|
||||
template: str | None
|
||||
desc: str | None
|
||||
paramList: list[str]
|
||||
class UniEquipMissionData(BaseStruct):
|
||||
template: Union[str, None]
|
||||
desc: Union[str, None]
|
||||
paramList: List[str]
|
||||
uniEquipMissionId: str
|
||||
uniEquipMissionSort: int
|
||||
uniEquipId: str
|
||||
|
||||
|
||||
class SubProfessionData(BaseModel):
|
||||
class SubProfessionData(BaseStruct):
|
||||
subProfessionId: str
|
||||
subProfessionName: str
|
||||
subProfessionCatagory: int
|
||||
|
||||
|
||||
class UniequipData(BaseModel):
|
||||
class UniequipData(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
equipDict: dict[str, UniEquipData]
|
||||
missionList: dict[str, UniEquipMissionData]
|
||||
subProfDict: dict[str, SubProfessionData]
|
||||
charEquip: dict[str, list[str]]
|
||||
equipDict: Dict[str, UniEquipData]
|
||||
missionList: Dict[str, UniEquipMissionData]
|
||||
subProfDict: Dict[str, SubProfessionData]
|
||||
charEquip: Dict[str, List[str]]
|
||||
|
@ -1,66 +1,68 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, List, Union
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class UniEquipData(BaseModel):
|
||||
class UniEquipData(BaseStruct):
|
||||
uniEquipId: str
|
||||
uniEquipName: str
|
||||
uniEquipIcon: str
|
||||
uniEquipDesc: str
|
||||
typeIcon: str
|
||||
typeName1: str
|
||||
typeName2: str | None
|
||||
typeName2: Union[str, None]
|
||||
equipShiningColor: str
|
||||
showEvolvePhase: int
|
||||
unlockEvolvePhase: int
|
||||
charId: str
|
||||
tmplId: str | None
|
||||
tmplId: Union[str, None]
|
||||
showLevel: int
|
||||
unlockLevel: int
|
||||
unlockFavorPoint: int
|
||||
missionList: list[str]
|
||||
itemCost: dict[str, list[ItemBundle]] | None
|
||||
type_: str = Field(..., alias='type')
|
||||
missionList: List[str]
|
||||
itemCost: Union[Dict[str, List[ItemBundle]], None]
|
||||
type_: str = field(name='type')
|
||||
uniEquipGetTime: int
|
||||
charEquipOrder: int
|
||||
|
||||
|
||||
class UniEquipMissionData(BaseModel):
|
||||
class UniEquipMissionData(BaseStruct):
|
||||
template: str
|
||||
desc: str
|
||||
paramList: list[str]
|
||||
paramList: List[str]
|
||||
uniEquipMissionId: str
|
||||
uniEquipMissionSort: int
|
||||
uniEquipId: str
|
||||
jumpStageId: str | None
|
||||
jumpStageId: Union[str, None]
|
||||
|
||||
|
||||
class SubProfessionData(BaseModel):
|
||||
class SubProfessionData(BaseStruct):
|
||||
subProfessionId: str
|
||||
subProfessionName: str
|
||||
subProfessionCatagory: int
|
||||
|
||||
|
||||
class UniEquipTrack(BaseModel):
|
||||
class UniEquipTrack(BaseStruct):
|
||||
charId: str
|
||||
equipId: str
|
||||
|
||||
|
||||
class UniEquipTimeInfo(BaseModel):
|
||||
class UniEquipTimeInfo(BaseStruct):
|
||||
timeStamp: int
|
||||
trackList: list[UniEquipTrack]
|
||||
trackList: List[UniEquipTrack]
|
||||
|
||||
|
||||
class UniEquipTable(BaseModel):
|
||||
class UniEquipTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
equipDict: dict[str, UniEquipData]
|
||||
missionList: dict[str, UniEquipMissionData]
|
||||
subProfDict: dict[str, SubProfessionData]
|
||||
charEquip: dict[str, list[str]]
|
||||
equipTrackDict: list[UniEquipTimeInfo]
|
||||
equipDict: Dict[str, UniEquipData]
|
||||
missionList: Dict[str, UniEquipMissionData]
|
||||
subProfDict: Dict[str, SubProfessionData]
|
||||
charEquip: Dict[str, List[str]]
|
||||
equipTrackDict: List[UniEquipTimeInfo]
|
||||
|
@ -1,34 +1,36 @@
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Dict, Union, List
|
||||
from ..common import BaseStruct
|
||||
from msgspec import field
|
||||
|
||||
|
||||
class ZoneData(BaseModel):
|
||||
class ZoneData(BaseStruct):
|
||||
zoneID: str
|
||||
zoneIndex: int
|
||||
type: str
|
||||
zoneNameFirst: str | None
|
||||
zoneNameSecond: str | None
|
||||
zoneNameTitleCurrent: str | None
|
||||
zoneNameTitleUnCurrent: str | None
|
||||
zoneNameTitleEx: str | None
|
||||
zoneNameThird: str | None
|
||||
lockedText: str | None
|
||||
zoneNameFirst: Union[str, None]
|
||||
zoneNameSecond: Union[str, None]
|
||||
zoneNameTitleCurrent: Union[str, None]
|
||||
zoneNameTitleUnCurrent: Union[str, None]
|
||||
zoneNameTitleEx: Union[str, None]
|
||||
zoneNameThird: Union[str, None]
|
||||
lockedText: Union[str, None]
|
||||
canPreview: bool
|
||||
|
||||
|
||||
class WeeklyZoneData(BaseModel):
|
||||
daysOfWeek: list[int]
|
||||
type_: str = Field(..., alias='type')
|
||||
class WeeklyZoneData(BaseStruct):
|
||||
daysOfWeek: List[int]
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class ZoneValidInfo(BaseModel):
|
||||
class ZoneValidInfo(BaseStruct):
|
||||
startTs: int
|
||||
endTs: int
|
||||
|
||||
|
||||
class MainlineZoneData(BaseModel):
|
||||
class MainlineZoneData(BaseStruct):
|
||||
zoneId: str
|
||||
chapterId: str
|
||||
preposedZoneId: str | None
|
||||
preposedZoneId: Union[str, None]
|
||||
zoneIndex: int
|
||||
startStageId: str
|
||||
endStageId: str
|
||||
@ -39,70 +41,70 @@ class MainlineZoneData(BaseModel):
|
||||
buttonStyle: str
|
||||
spoilAlert: bool
|
||||
zoneOpenTime: int
|
||||
diffGroup: list[int]
|
||||
diffGroup: List[int]
|
||||
|
||||
|
||||
class ItemBundle(BaseModel):
|
||||
id_: str = Field(alias='id')
|
||||
class ItemBundle(BaseStruct):
|
||||
id_: str = field(name='id')
|
||||
count: int
|
||||
type_: str = Field(alias='type')
|
||||
type_: str = field(name='type')
|
||||
|
||||
|
||||
class RecordRewardInfo(BaseModel):
|
||||
class RecordRewardInfo(BaseStruct):
|
||||
bindStageId: str
|
||||
stageDiff1: int
|
||||
stageDiff: int
|
||||
picRes: str | None
|
||||
textPath: str | None
|
||||
textDesc: str | None
|
||||
recordReward: list[ItemBundle] | None
|
||||
picRes: Union[str, None]
|
||||
textPath: Union[str, None]
|
||||
textDesc: Union[str, None]
|
||||
recordReward: Union[List[ItemBundle], None]
|
||||
|
||||
|
||||
class ZoneRecordData(BaseModel):
|
||||
class ZoneRecordData(BaseStruct):
|
||||
recordId: str
|
||||
zoneId: str
|
||||
recordTitleName: str
|
||||
preRecordId: str | None
|
||||
nodeTitle1: str | None
|
||||
nodeTitle2: str | None
|
||||
rewards: list[RecordRewardInfo]
|
||||
preRecordId: Union[str, None]
|
||||
nodeTitle1: Union[str, None]
|
||||
nodeTitle2: Union[str, None]
|
||||
rewards: List[RecordRewardInfo]
|
||||
|
||||
|
||||
class ZoneRecordUnlockData(BaseModel):
|
||||
class ZoneRecordUnlockData(BaseStruct):
|
||||
noteId: str
|
||||
zoneId: str
|
||||
initialName: str
|
||||
finalName: str | None
|
||||
accordingExposeId: str | None
|
||||
finalName: Union[str, None]
|
||||
accordingExposeId: Union[str, None]
|
||||
initialDes: str
|
||||
finalDes: str | None
|
||||
remindDes: str | None
|
||||
finalDes: Union[str, None]
|
||||
remindDes: Union[str, None]
|
||||
|
||||
|
||||
class ZoneRecordGroupData(BaseModel):
|
||||
class ZoneRecordGroupData(BaseStruct):
|
||||
zoneId: str
|
||||
records: list[ZoneRecordData]
|
||||
records: List[ZoneRecordData]
|
||||
unlockData: ZoneRecordUnlockData
|
||||
|
||||
|
||||
class ZoneRecordMissionData(BaseModel):
|
||||
class ZoneRecordMissionData(BaseStruct):
|
||||
missionId: str
|
||||
recordStageId: str
|
||||
templateDesc: str
|
||||
desc: str
|
||||
|
||||
|
||||
class ZoneMetaData(BaseModel):
|
||||
ZoneRecordMissionData: dict[str, ZoneRecordMissionData]
|
||||
class ZoneMetaData(BaseStruct):
|
||||
ZoneRecordMissionData: Dict[str, ZoneRecordMissionData]
|
||||
|
||||
|
||||
class ZoneTable(BaseModel):
|
||||
class ZoneTable(BaseStruct):
|
||||
__version__ = '23-07-27-18-50-06-aeb568'
|
||||
|
||||
zones: dict[str, ZoneData]
|
||||
weeklyAdditionInfo: dict[str, WeeklyZoneData]
|
||||
zoneValidInfo: dict[str, ZoneValidInfo]
|
||||
mainlineAdditionInfo: dict[str, MainlineZoneData]
|
||||
zoneRecordGroupedData: dict[str, ZoneRecordGroupData]
|
||||
zoneRecordRewardData: dict[str, list[str]]
|
||||
zones: Dict[str, ZoneData]
|
||||
weeklyAdditionInfo: Dict[str, WeeklyZoneData]
|
||||
zoneValidInfo: Dict[str, ZoneValidInfo]
|
||||
mainlineAdditionInfo: Dict[str, MainlineZoneData]
|
||||
zoneRecordGroupedData: Dict[str, ZoneRecordGroupData]
|
||||
zoneRecordRewardData: Dict[str, List[str]]
|
||||
zoneMetaData: ZoneMetaData
|
||||
|
@ -1,3 +1,4 @@
|
||||
from typing import Dict, List, Union
|
||||
from msgspec import Struct, field
|
||||
|
||||
|
||||
@ -28,9 +29,9 @@ class ArknightsAttendanceCalendar(Struct):
|
||||
|
||||
class ArknightsAttendanceCalendarModel(Struct):
|
||||
currentTs: str
|
||||
calendar: list[ArknightsAttendanceCalendar]
|
||||
records: list[ArknightsAttendanceRecord | None]
|
||||
resourceInfoMap: dict[str, ArknightsAttendanceAwardResource]
|
||||
calendar: List[ArknightsAttendanceCalendar]
|
||||
records: List[Union[ArknightsAttendanceRecord, None]]
|
||||
resourceInfoMap: Dict[str, ArknightsAttendanceAwardResource]
|
||||
|
||||
|
||||
################
|
||||
@ -43,7 +44,7 @@ class ArknightsAttendanceAward(Struct):
|
||||
|
||||
class ArknightsAttendanceModel(Struct):
|
||||
ts: str
|
||||
awards: list[ArknightsAttendanceAward]
|
||||
awards: List[ArknightsAttendanceAward]
|
||||
################
|
||||
# ArknightsAttendance End
|
||||
################
|
||||
@ -95,7 +96,7 @@ class UserGameStatus(Struct):
|
||||
charCnt: int
|
||||
furnitureCnt: int
|
||||
skinCnt: int
|
||||
avatar: UserGameStatusAvatar | None = None
|
||||
avatar: Union[UserGameStatusAvatar, None] = None
|
||||
|
||||
|
||||
class UserMeInfoRts(Struct):
|
||||
@ -116,7 +117,7 @@ class UserMeInfo(Struct):
|
||||
avatar: str
|
||||
backgroundCode: int
|
||||
isCreator: bool
|
||||
creatorIdentifiers: list[str]
|
||||
creatorIdentifiers: List[str]
|
||||
status: int
|
||||
operationStatus: int
|
||||
identity: int
|
||||
@ -131,7 +132,7 @@ class UserMeInfo(Struct):
|
||||
class ArknightsUserMeModel(Struct, omit_defaults=True):
|
||||
user: UserMeInfo
|
||||
userRts: UserMeInfoRts
|
||||
userSanctionList: list[str]
|
||||
userSanctionList: List[str]
|
||||
gameStatus: UserGameStatus
|
||||
moderator: UserMeModerator
|
||||
userInfoApply: UserMeInfoApply
|
||||
@ -152,7 +153,7 @@ class PlayerManufactureFormulaInfo(Struct):
|
||||
count: int
|
||||
weight: int
|
||||
costPoint: int
|
||||
costs: list[str] | None = None
|
||||
costs: Union[List[str], None] = None
|
||||
|
||||
|
||||
class PlayerEquipmentInfo(Struct):
|
||||
@ -160,8 +161,8 @@ class PlayerEquipmentInfo(Struct):
|
||||
name: str
|
||||
typeIcon: str
|
||||
shiningColor: str
|
||||
desc: str | None = None
|
||||
typeName1: str | None = None
|
||||
desc: Union[str, None] = None
|
||||
typeName1: Union[str, None] = None
|
||||
|
||||
|
||||
class PlayerCampaignZoneInfo(Struct):
|
||||
@ -189,8 +190,8 @@ class PlayerTowerInfo(Struct):
|
||||
id_: str = field(name='id')
|
||||
name: str
|
||||
subName: str
|
||||
hasHard: bool | None = None
|
||||
stageNum: int | None = None
|
||||
hasHard: Union[bool, None] = None
|
||||
stageNum: Union[int, None] = None
|
||||
|
||||
|
||||
class PlayerZoneInfo(Struct):
|
||||
@ -219,14 +220,14 @@ class PlayerSkinInfo(Struct):
|
||||
brandId: str
|
||||
sortId: int
|
||||
displayTagId: str
|
||||
name: str | None = None
|
||||
brandName: str | None = None
|
||||
brandCapitalName: str | None = None
|
||||
illustId: str | None = None
|
||||
dynIllustId: str | None = None
|
||||
avatarId: str | None = None
|
||||
portraitId: str | None = None
|
||||
skinGroupId: str | None = None
|
||||
name: Union[str, None] = None
|
||||
brandName: Union[str, None] = None
|
||||
brandCapitalName: Union[str, None] = None
|
||||
illustId: Union[str, None] = None
|
||||
dynIllustId: Union[str, None] = None
|
||||
avatarId: Union[str, None] = None
|
||||
portraitId: Union[str, None] = None
|
||||
skinGroupId: Union[str, None] = None
|
||||
|
||||
|
||||
class PlayerCharInfo(Struct):
|
||||
@ -250,14 +251,14 @@ class ActivityZone(Struct):
|
||||
zoneReplicaId: str
|
||||
clearedStage: int
|
||||
totalStage: int
|
||||
stageStatus: list[ActivityZoneStageStatus] | None = None
|
||||
stageStatus: Union[List[ActivityZoneStageStatus], None] = None
|
||||
|
||||
|
||||
class PlayerActivity(Struct):
|
||||
actId: str
|
||||
actReplicaId: str
|
||||
zones: list[ActivityZone]
|
||||
type_: str | None = field(name='type', default=None)
|
||||
zones: List[ActivityZone]
|
||||
type_: Union[str, None] = field(name='type', default=None)
|
||||
|
||||
|
||||
class RewoardItem(Struct):
|
||||
@ -279,12 +280,12 @@ class RogueRecord(Struct):
|
||||
rogueId: str
|
||||
relicCnt: int
|
||||
bank: BankItem
|
||||
mission: RewoardItem | None = None
|
||||
clearTime: int | None = None
|
||||
mission: Union[RewoardItem, None] = None
|
||||
clearTime: Union[int, None] = None
|
||||
|
||||
|
||||
class PlayerRogue(Struct):
|
||||
records: list[RogueRecord]
|
||||
records: List[RogueRecord]
|
||||
|
||||
|
||||
class TowerReward(Struct):
|
||||
@ -296,14 +297,14 @@ class TowerReward(Struct):
|
||||
class TowerRecord(Struct):
|
||||
towerId: str
|
||||
best: int
|
||||
hasHard: bool | None = None
|
||||
stageNum: int | None = None
|
||||
unlockHard: bool | None = None
|
||||
hardBest: int | None = None
|
||||
hasHard: Union[bool, None] = None
|
||||
stageNum: Union[int, None] = None
|
||||
unlockHard: Union[bool, None] = None
|
||||
hardBest: Union[int, None] = None
|
||||
|
||||
|
||||
class PlayerTower(Struct):
|
||||
records: list[TowerRecord]
|
||||
records: List[TowerRecord]
|
||||
reward: TowerReward
|
||||
|
||||
|
||||
@ -318,7 +319,7 @@ class CampaignRecord(Struct):
|
||||
|
||||
|
||||
class PlayerCampaign(Struct):
|
||||
records: list[CampaignRecord]
|
||||
records: List[CampaignRecord]
|
||||
reward: CampaignReward
|
||||
|
||||
|
||||
@ -331,8 +332,8 @@ class PlayerRecruit(Struct):
|
||||
startTs: int
|
||||
finishTs: int
|
||||
state: int
|
||||
duration: int | None = None
|
||||
selectTags: list[RecruitTag] | None = None
|
||||
duration: Union[int, None] = None
|
||||
selectTags: Union[List[RecruitTag], None] = None
|
||||
|
||||
|
||||
class BuildingTrainingTrainee(Struct):
|
||||
@ -353,7 +354,7 @@ class BuildingClue(Struct):
|
||||
received: int
|
||||
dailyReward: bool
|
||||
needReceive: int
|
||||
board: list[str]
|
||||
board: List[str]
|
||||
sharing: bool
|
||||
shareCompleteTime: int
|
||||
|
||||
@ -381,7 +382,7 @@ class BuildingControl(Struct):
|
||||
slotId: str
|
||||
slotState: int
|
||||
level: int
|
||||
chars: list[BuildingChar]
|
||||
chars: List[BuildingChar]
|
||||
|
||||
|
||||
class BuildingCorridor(Struct):
|
||||
@ -415,14 +416,14 @@ class BuildingTraining(Struct):
|
||||
lastUpdateTime: int
|
||||
remainSecs: int
|
||||
slotState: int
|
||||
trainee: BuildingTrainingTrainee | None
|
||||
trainer: BuildingTrainingTrainer | None
|
||||
trainee: Union[BuildingTrainingTrainee, None]
|
||||
trainer: Union[BuildingTrainingTrainer, None]
|
||||
|
||||
|
||||
class BuildingHire(Struct):
|
||||
slotId: str
|
||||
level: int
|
||||
chars: list[BuildingChar]
|
||||
chars: List[BuildingChar]
|
||||
state: int
|
||||
refreshCount: int
|
||||
completeWorkTime: int
|
||||
@ -432,7 +433,7 @@ class BuildingHire(Struct):
|
||||
class BuildingMeeting(Struct):
|
||||
slotId: str
|
||||
level: int
|
||||
chars: list[BuildingChar]
|
||||
chars: List[BuildingChar]
|
||||
clue: BuildingClue
|
||||
lastUpdateTime: int
|
||||
completeWorkTime: int
|
||||
@ -441,7 +442,7 @@ class BuildingMeeting(Struct):
|
||||
class BuildingDormitories(Struct):
|
||||
slotId: str
|
||||
level: int
|
||||
chars: list[BuildingChar]
|
||||
chars: List[BuildingChar]
|
||||
comfort: int
|
||||
|
||||
|
||||
@ -454,7 +455,7 @@ class BuildingStockDelivery(Struct):
|
||||
class BuildingStock(Struct):
|
||||
instId: int
|
||||
type_: str = field(name='type')
|
||||
delivery: list[BuildingStockDelivery]
|
||||
delivery: List[BuildingStockDelivery]
|
||||
gain: BuildingStockDelivery
|
||||
isViolated: bool
|
||||
|
||||
@ -462,18 +463,18 @@ class BuildingStock(Struct):
|
||||
class BuildingTradings(Struct):
|
||||
slotId: str
|
||||
level: int
|
||||
chars: list[BuildingChar]
|
||||
chars: List[BuildingChar]
|
||||
completeWorkTime: int
|
||||
lastUpdateTime: int
|
||||
strategy: str
|
||||
stock: list[BuildingStock]
|
||||
stock: List[BuildingStock]
|
||||
stockLimit: int
|
||||
|
||||
|
||||
class BuildingManufactures(Struct):
|
||||
slotId: str
|
||||
level: int
|
||||
chars: list[BuildingChar]
|
||||
chars: List[BuildingChar]
|
||||
completeWorkTime: int
|
||||
lastUpdateTime: int
|
||||
formulaId: str
|
||||
@ -487,7 +488,7 @@ class BuildingManufactures(Struct):
|
||||
class BuildingPower(Struct):
|
||||
slotId: str
|
||||
level: int
|
||||
chars: list[BuildingChar]
|
||||
chars: List[BuildingChar]
|
||||
|
||||
|
||||
class BuildingTiredChar(Struct):
|
||||
@ -501,19 +502,19 @@ class BuildingTiredChar(Struct):
|
||||
|
||||
|
||||
class PlayerBuilding(Struct):
|
||||
tiredChars: list[BuildingTiredChar] | None
|
||||
powers: list[BuildingPower] | None
|
||||
manufactures: list[BuildingManufactures] | None
|
||||
tradings: list[BuildingTradings] | None
|
||||
dormitories: list[BuildingDormitories] | None
|
||||
meeting: BuildingMeeting | None
|
||||
hire: BuildingHire | None
|
||||
tiredChars: Union[List[BuildingTiredChar], None]
|
||||
powers: Union[List[BuildingPower], None]
|
||||
manufactures: Union[List[BuildingManufactures], None]
|
||||
tradings: Union[List[BuildingTradings], None]
|
||||
dormitories: Union[List[BuildingDormitories], None]
|
||||
meeting: Union[BuildingMeeting, None]
|
||||
hire: Union[BuildingHire, None]
|
||||
labor: BuildingLabor
|
||||
furniture: BuildingFurniture
|
||||
elevators: list[BuildingElevator]
|
||||
corridors: list[BuildingCorridor] | None
|
||||
elevators: List[BuildingElevator]
|
||||
corridors: Union[List[BuildingCorridor], None]
|
||||
control: BuildingControl
|
||||
training: BuildingTraining | None = None
|
||||
training: Union[BuildingTraining, None] = None
|
||||
|
||||
|
||||
class PlayerInfoSkin(Struct):
|
||||
@ -538,8 +539,8 @@ class PlayerInfoChar(Struct):
|
||||
evolvePhase: int
|
||||
potentialRank: int
|
||||
mainSkillLvl: int
|
||||
skills: list[PlayerInfoCharSkill] | None
|
||||
equip: list[PlayerInfoCharEquip] | None
|
||||
skills: Union[List[PlayerInfoCharSkill] , None]
|
||||
equip: Union[List[PlayerInfoCharEquip] , None]
|
||||
favorPercent: int
|
||||
defaultSkillId: str
|
||||
gainTime: int
|
||||
@ -560,14 +561,14 @@ class PlayerAssistChar(Struct):
|
||||
skillId: str
|
||||
mainSkillLvl: int
|
||||
specializeLevel: int
|
||||
equip: PlayerAssistCharEquip | None
|
||||
equip: Union[PlayerAssistCharEquip, None]
|
||||
|
||||
|
||||
class PlayerMedal(Struct):
|
||||
type_: str = field(name='type')
|
||||
template: str
|
||||
templateMedalList: list[str]
|
||||
customMedalLayout: list[str | None]
|
||||
templateMedalList: List[str]
|
||||
customMedalLayout: List[Union[str, None]]
|
||||
total: int
|
||||
|
||||
|
||||
@ -603,7 +604,7 @@ class PlayerStatus(Struct):
|
||||
charCnt: int
|
||||
furnitureCnt: int
|
||||
skinCnt: int
|
||||
avatar: PlayerStatusAvatar | None = None
|
||||
avatar: Union[PlayerStatusAvatar, None] = None
|
||||
|
||||
|
||||
class DisplayShowConfig(Struct):
|
||||
@ -624,32 +625,32 @@ class ArknightsPlayerInfoModel(Struct, omit_defaults=True, gc=False):
|
||||
currentTs: int
|
||||
showConfig: DisplayShowConfig
|
||||
status: PlayerStatus
|
||||
assistChars: list[PlayerAssistChar]
|
||||
chars: list[PlayerInfoChar]
|
||||
skins: list[PlayerInfoSkin]
|
||||
assistChars: List[PlayerAssistChar]
|
||||
chars: List[PlayerInfoChar]
|
||||
skins: List[PlayerInfoSkin]
|
||||
building: PlayerBuilding
|
||||
recruit: list[PlayerRecruit]
|
||||
recruit: List[PlayerRecruit]
|
||||
campaign: PlayerCampaign
|
||||
tower: PlayerTower
|
||||
rogue: PlayerRogue
|
||||
routine: PlayerRoutine
|
||||
activity: list[PlayerActivity]
|
||||
charInfoMap: dict[str, PlayerCharInfo]
|
||||
skinInfoMap: dict[str, PlayerSkinInfo]
|
||||
stageInfoMap: dict[str, PlayerStageInfo]
|
||||
activityInfoMap: dict[str, PlayerActivityInfo]
|
||||
towerInfoMap: dict[str, PlayerTowerInfo]
|
||||
rogueInfoMap: dict[str, PlayerRogueInfo]
|
||||
campaignInfoMap: dict[str, PlayerCampaignInfo]
|
||||
campaignZoneInfoMap: dict[str, PlayerCampaignZoneInfo]
|
||||
equipmentInfoMap: dict[str, PlayerEquipmentInfo]
|
||||
manufactureFormulaInfoMap: dict[str, PlayerManufactureFormulaInfo]
|
||||
charAssets: list[str | None]
|
||||
skinAssets: list[str | None]
|
||||
activityBannerList: dict[str, list[PlayerActivityBannerList]]
|
||||
medal: PlayerMedal | None = None
|
||||
zoneInfoMap: dict[str, PlayerZoneInfo] | None = None
|
||||
medalInfoMap: dict[str, PlayerMedalInfo] | None = None
|
||||
activity: List[PlayerActivity]
|
||||
charInfoMap: Dict[str, PlayerCharInfo]
|
||||
skinInfoMap: Dict[str, PlayerSkinInfo]
|
||||
stageInfoMap: Dict[str, PlayerStageInfo]
|
||||
activityInfoMap: Dict[str, PlayerActivityInfo]
|
||||
towerInfoMap: Dict[str, PlayerTowerInfo]
|
||||
rogueInfoMap: Dict[str, PlayerRogueInfo]
|
||||
campaignInfoMap: Dict[str, PlayerCampaignInfo]
|
||||
campaignZoneInfoMap: Dict[str, PlayerCampaignZoneInfo]
|
||||
equipmentInfoMap: Dict[str, PlayerEquipmentInfo]
|
||||
manufactureFormulaInfoMap: Dict[str, PlayerManufactureFormulaInfo]
|
||||
charAssets: List[Union[str, None]]
|
||||
skinAssets: List[Union[str, None]]
|
||||
activityBannerList: Dict[str, List[PlayerActivityBannerList]]
|
||||
medal: Union[PlayerMedal, None] = None
|
||||
zoneInfoMap: Union[Dict[str, PlayerZoneInfo], None] = None
|
||||
medalInfoMap: Union[Dict[str, PlayerMedalInfo], None] = None
|
||||
|
||||
|
||||
################
|
||||
|
@ -1,5 +1,6 @@
|
||||
import asyncio
|
||||
from pathlib import Path
|
||||
from typing import Dict, List, Tuple, Union
|
||||
|
||||
from aiohttp.client import ClientSession
|
||||
from gsuid_core.logger import logger
|
||||
@ -15,19 +16,19 @@ with Path.open(
|
||||
) as f:
|
||||
resource_map = msgjson.decode(
|
||||
f.read(),
|
||||
type=dict[str, dict[str, dict[str, dict[str, int | str]]]],
|
||||
type=Dict[str, Dict[str, Dict[str, Dict[str, Union[int, str]]]]],
|
||||
)
|
||||
|
||||
|
||||
async def download_all_file_from_cos():
|
||||
async def _download(tasks: list[asyncio.Task]):
|
||||
async def _download(tasks: List[asyncio.Task]):
|
||||
failed_list.extend(
|
||||
list(filter(lambda x: x is not None, await asyncio.gather(*tasks)))
|
||||
)
|
||||
tasks.clear()
|
||||
logger.info('[cos]下载完成!')
|
||||
|
||||
failed_list: list[tuple[str, str, str, str]] = []
|
||||
failed_list: List[Tuple[str, str, str, str]] = []
|
||||
TASKS = []
|
||||
async with ClientSession() as sess:
|
||||
for res_type in ['resource']:
|
||||
|
@ -1,4 +1,5 @@
|
||||
|
||||
from typing import Union, Tuple
|
||||
import aiofiles
|
||||
from aiohttp.client import ClientSession
|
||||
from aiohttp.client_exceptions import ClientConnectorError
|
||||
@ -16,7 +17,7 @@ async def download(
|
||||
res_type: str,
|
||||
resource_type: str,
|
||||
name: str,
|
||||
) -> tuple[str, str, str] | None:
|
||||
) -> Union[Tuple[str, str, str], None]:
|
||||
"""
|
||||
:说明:
|
||||
下载URL保存入目录
|
||||
@ -43,8 +44,8 @@ async def download_file(
|
||||
res_type: str,
|
||||
resource_type: str,
|
||||
name: str,
|
||||
sess: ClientSession | None = None,
|
||||
) -> tuple[str, str, str] | None:
|
||||
sess: Union[ClientSession, None] = None,
|
||||
) -> Union[Tuple[str, str, str], None]:
|
||||
if sess is None:
|
||||
sess = ClientSession()
|
||||
try:
|
||||
|
Loading…
x
Reference in New Issue
Block a user