new:添加黑武技能排列导入

This commit is contained in:
2026-08-10 16:26:04 +08:00
parent 0f648a94e8
commit 8239d69033
@@ -16,6 +16,22 @@ export default defineComponent({
const res = await api.getSkillFromCode(skillCode.value)
// console.log(res)
configStore.config.skills = res.skills
const shortcuts: { skill_id: number; slot_index: number }[] = res.shortcuts
const combos: { slot_index: number; skills: { skill_id: number }[] }[] = res.combos
console.log('shortcuts', res)
const alter = res.job.name
if (alter == 'dark_knight') {
configStore.config.skillShortcuts = {
// 黑暗武士前7个快捷键是组合技能,后面才是快捷栏
shortcuts: shortcuts.slice(6).map((a) => a.skill_id?.toString() ?? ''),
combos: combos.map((a) => a.skills.map((b) => b.skill_id.toString() ?? '')),
}
} else {
configStore.config.skillShortcuts = {
shortcuts: shortcuts.map((a) => a.skill_id?.toString() ?? ''),
combos: [],
}
}
const { alert } = useDialog()
visible.value = false
await alert({
@@ -53,12 +69,12 @@ export default defineComponent({
<p class="text-#e9c556/80">
* 点击导入后会根据规则解析出技能加点、技能进化、技能强化
</p>
<p class="text-#e9c556/80">
* 部分技能可能存在无法识别的情况,需要手动调整
</p>
<p class="text-#e9c556/80">* 部分技能可能存在无法识别的情况,需要手动调整</p>
</div>
<div class="flex justify-around items-center">
<calc-button onClick={execute} disabled={!skillCode.value || isLoading.value}>导入</calc-button>
<calc-button onClick={execute} disabled={!skillCode.value || isLoading.value}>
导入
</calc-button>
<calc-button onClick={() => (visible.value = false)}>取消</calc-button>
</div>
</div>