78 lines
2.5 KiB
Python
78 lines
2.5 KiB
Python
#!/usr/bin/env python3
|
|
"""
|
|
궁극기 정보 추출 스크립트
|
|
|
|
모든 스토커의 궁극기 정보를 DT_Skill에서 추출합니다.
|
|
"""
|
|
|
|
import json
|
|
import sys
|
|
from pathlib import Path
|
|
|
|
STALKERS = ['hilda', 'urud', 'nave', 'baran', 'rio', 'clad', 'rene', 'sinobu', 'lian', 'cazimord']
|
|
|
|
def load_json(file_path):
|
|
"""JSON 파일 로드"""
|
|
with open(file_path, 'r', encoding='utf-8') as f:
|
|
data = json.load(f)
|
|
return data.get('Assets', [])
|
|
|
|
def find_table(datatables, table_name):
|
|
"""특정 테이블 찾기"""
|
|
for dt in datatables:
|
|
if dt.get('AssetName') == table_name:
|
|
return dt
|
|
return None
|
|
|
|
def main():
|
|
if len(sys.argv) < 2:
|
|
print("사용법: python extract_ultimate_skills.py <DataTable.json 경로>")
|
|
sys.exit(1)
|
|
|
|
json_path = Path(sys.argv[1])
|
|
datatables = load_json(json_path)
|
|
|
|
# DT_CharacterStat에서 궁극기 ID 추출
|
|
char_stat_table = find_table(datatables, 'DT_CharacterStat')
|
|
stalker_ultimates = {}
|
|
for row in char_stat_table.get('Rows', []):
|
|
row_name = row['RowName']
|
|
if row_name in STALKERS:
|
|
stalker_ultimates[row_name] = row['Data'].get('ultimateSkill', '')
|
|
|
|
# DT_Skill에서 궁극기 상세 정보 추출
|
|
skill_table = find_table(datatables, 'DT_Skill')
|
|
|
|
print("=" * 100)
|
|
print("스토커별 궁극기 정보")
|
|
print("=" * 100)
|
|
|
|
for stalker in STALKERS:
|
|
ult_id = stalker_ultimates.get(stalker, '')
|
|
if not ult_id:
|
|
continue
|
|
|
|
# 스킬 정보 찾기
|
|
skill_row = next((row for row in skill_table['Rows'] if row['RowName'] == ult_id), None)
|
|
if not skill_row:
|
|
print(f"\n{stalker}: 궁극기 {ult_id} 정보를 찾을 수 없습니다")
|
|
continue
|
|
|
|
data = skill_row['Data']
|
|
|
|
print(f"\n【{stalker.upper()}】")
|
|
print(f" ID: {ult_id}")
|
|
print(f" 이름: {data.get('name', 'N/A')}")
|
|
print(f" 간단 설명: {data.get('simpleDesc', 'N/A')}")
|
|
print(f" bIsUltimate: {data.get('bIsUltimate', False)}")
|
|
print(f" skillDamageRate: {data.get('skillDamageRate', 0)}")
|
|
print(f" skillAttackType: {data.get('skillAttackType', 'N/A')}")
|
|
print(f" skillElementType: {data.get('skillElementType', 'N/A')}")
|
|
print(f" castingTime: {data.get('castingTime', 0)}초")
|
|
print(f" activeDuration: {data.get('activeDuration', 0)}초")
|
|
print(f" manaCost: {data.get('manaCost', 0)}")
|
|
print(f" coolTime: {data.get('coolTime', 0)}")
|
|
|
|
if __name__ == "__main__":
|
|
main()
|