mirror of
https://github.com/baiqwerdvd/StarRailUID.git
synced 2025-05-06 11:43:44 +08:00
再加一点
This commit is contained in:
parent
8878252291
commit
9fac923fb9
@ -1,4 +1,4 @@
|
||||
from typing import Dict
|
||||
from typing import Dict, List, Union
|
||||
|
||||
from .effect.Role import RoleInstance
|
||||
from .mono.Character import Character
|
||||
@ -15,7 +15,7 @@ async def cal_char_info(char_data: Dict):
|
||||
async def cal(char_data: Dict):
|
||||
char = await cal_char_info(char_data)
|
||||
|
||||
skill_info_list = []
|
||||
skill_info_list: List[List[Union[str, float]]] = []
|
||||
if char.char_id in [
|
||||
1102,
|
||||
1204,
|
||||
|
@ -1,3 +1,5 @@
|
||||
from typing import List, Union
|
||||
|
||||
from gsuid_core.logger import logger
|
||||
|
||||
from ..mono.Character import Character
|
||||
@ -428,11 +430,11 @@ class RoleInstance:
|
||||
# 期望伤害
|
||||
qiwang_damage = (critical_chance_base * critical_damage_base) + 1
|
||||
logger.info(f'暴击期望: {qiwang_damage}')
|
||||
damage_cd_z = 0
|
||||
damage_qw_z = 0
|
||||
damage_tz_z = 0
|
||||
attack_tz = 0
|
||||
injury_add = 0
|
||||
damage_cd_z = 0.0
|
||||
damage_qw_z = 0.0
|
||||
damage_tz_z = 0.0
|
||||
attack_tz = 0.0
|
||||
injury_add = 0.0
|
||||
critical_damage_add = 0
|
||||
for i in range(1, skill_info[2] + 1):
|
||||
injury_add = 0
|
||||
@ -542,7 +544,7 @@ class RoleInstance:
|
||||
* 10
|
||||
)
|
||||
damage_tz_z += damage_tz_fj
|
||||
skill_info_list = []
|
||||
skill_info_list: List[Union[str, float]] = []
|
||||
skill_info_list.append(skill_info[1])
|
||||
skill_info_list.append(damage_cd_z)
|
||||
skill_info_list.append(damage_qw_z)
|
||||
@ -576,7 +578,7 @@ class RoleInstance:
|
||||
defence * skill_multiplier + defence_multiplier
|
||||
) * shield_added
|
||||
|
||||
skill_info_list = []
|
||||
skill_info_list: List[Union[str, float]] = []
|
||||
skill_info_list.append(skill_info[1])
|
||||
skill_info_list.append(defence_num)
|
||||
skill_info_list.append(defence_num)
|
||||
|
@ -89,6 +89,8 @@ for item in AvatarConfig:
|
||||
avatar_id = avatar_item['AvatarID']
|
||||
avatar_name_hash = avatar_item['AvatarName']['Hash']
|
||||
avatar_damage_type = avatar_item['DamageType']
|
||||
avatar_en_name = ''
|
||||
avatar_name = ''
|
||||
for item in TextMapCN:
|
||||
if str(item) == str(avatar_name_hash):
|
||||
avatar_name = TextMapCN[item]
|
||||
@ -108,6 +110,7 @@ for item in EquipmentConfig:
|
||||
equipment_item = EquipmentConfig[item]
|
||||
equipment_id = equipment_item['EquipmentID']
|
||||
equipment_name_hash = equipment_item['EquipmentName']['Hash']
|
||||
equipment_name = ''
|
||||
for item in TextMapCN:
|
||||
if str(item) == str(equipment_name_hash):
|
||||
equipment_name = TextMapCN[item]
|
||||
@ -127,6 +130,7 @@ for item in EquipmentConfig:
|
||||
equipment_item = EquipmentConfig[item]
|
||||
equipment_id = equipment_item['EquipmentID']
|
||||
equipment_name_hash = equipment_item['EquipmentName']['Hash']
|
||||
equipment_name = ''
|
||||
for item in TextMapEN:
|
||||
if str(item) == str(equipment_name_hash):
|
||||
equipment_name = TextMapEN[item].replace(' ', '')
|
||||
@ -140,6 +144,8 @@ for skill in AvatarSkillConfig:
|
||||
skill_name_hash = skill_item['1']['SkillName']['Hash']
|
||||
skill_type_hash = skill_item['1']['SkillTag']['Hash']
|
||||
skill_attack_type = skill_item['1'].get('AttackType', '')
|
||||
skill_name = ''
|
||||
skill_type = ''
|
||||
for item in TextMapCN:
|
||||
if str(item) == str(skill_name_hash):
|
||||
skill_name = TextMapCN[item]
|
||||
@ -159,6 +165,7 @@ for avatar_property in AvatarPropertyConfig:
|
||||
PropertyNameHash = AvatarPropertyConfig[avatar_property][
|
||||
'PropertyNameFilter'
|
||||
]['Hash']
|
||||
Property_Name = ''
|
||||
for item in TextMapCN:
|
||||
if str(item) == str(PropertyNameHash):
|
||||
Property_Name = TextMapCN[item]
|
||||
@ -173,6 +180,7 @@ for relic in RelicConfig:
|
||||
|
||||
for set_group in RelicSetConfig:
|
||||
set_name_hash = RelicSetConfig[set_group]['SetName']['Hash']
|
||||
set_name = ''
|
||||
for item in TextMapCN:
|
||||
if str(item) == str(set_name_hash):
|
||||
set_name = TextMapCN[item]
|
||||
@ -226,6 +234,7 @@ for item in relics_new:
|
||||
for item in ItemConfigRelic:
|
||||
item_id = ItemConfigRelic[item]['ID']
|
||||
item_name_hash = ItemConfigRelic[item]['ItemName']['Hash']
|
||||
item_name = ''
|
||||
for item in TextMapCN:
|
||||
if str(item) == str(item_name_hash):
|
||||
item_name = TextMapCN[item]
|
||||
|
Loading…
x
Reference in New Issue
Block a user