2024-09-17 16:28:39 +00:00
|
|
|
from starrail_damage_cal.cal_damage import cal_char_info, get_char_data
|
2024-09-10 07:24:22 +00:00
|
|
|
from starrail_damage_cal.damage.Avatar import AvatarInstance
|
2023-10-30 10:01:42 +00:00
|
|
|
|
|
|
|
|
2023-10-31 02:17:24 +00:00
|
|
|
async def test_get_damage_data_by_uid() -> None:
|
2024-08-02 09:59:15 +00:00
|
|
|
# print(await api_to_dict("108069476"))
|
2024-09-17 15:19:48 +00:00
|
|
|
char_data = await get_char_data(uid="100086290", avatar_name="希儿")
|
2024-09-17 16:28:39 +00:00
|
|
|
print(char_data)
|
2024-09-10 07:24:22 +00:00
|
|
|
|
|
|
|
char = await cal_char_info(char_data)
|
|
|
|
avatar = AvatarInstance(char)
|
|
|
|
print(avatar.base_attr)
|
|
|
|
print(avatar.attribute_bonus)
|
2023-10-30 10:01:42 +00:00
|
|
|
|
|
|
|
|
|
|
|
if __name__ == "__main__":
|
|
|
|
import asyncio
|
|
|
|
|
|
|
|
asyncio.run(test_get_damage_data_by_uid())
|