添加怪物手册的按键操作,增加提示,修复bug

This commit is contained in:
unanmed 2023-04-22 10:04:03 +08:00
parent 2d8f4ebe7c
commit 9806c0bce9
5 changed files with 18 additions and 7 deletions

1
components.d.ts vendored
View File

@ -11,6 +11,7 @@ declare module '@vue/runtime-core' {
AProgress: typeof import('ant-design-vue/es')['Progress']
ASelect: typeof import('ant-design-vue/es')['Select']
ASelectOption: typeof import('ant-design-vue/es')['SelectOption']
ASlider: typeof import('ant-design-vue/es')['Slider']
ASwitch: typeof import('ant-design-vue/es')['Switch']
Box: typeof import('./src/components/box.vue')['default']
BoxAnimate: typeof import('./src/components/boxAnimate.vue')['default']

View File

@ -1222,7 +1222,11 @@ var functions_d6ad677b_427a_4623_b50f_a445a3b0ef8a = {
core.actions._clickGameInfo_openComments();
break;
case 49: // 1: 断灭之刃
if (!flags.bladeOn || flags.autoSkill) break;
if (!flags.bladeOn) break;
if (!flags.autoSkill) {
core.tip('error', '已开启自动切换技能!');
break;
}
core.status.route.push('key:49'); // 将按键记在录像中
core.playSound('光标移动');
if (flags.blade) flags.blade = false;
@ -1245,8 +1249,11 @@ var functions_d6ad677b_427a_4623_b50f_a445a3b0ef8a = {
}
break;
case 51: // 3: 铸剑为盾
if (!flags.shieldOn || flags.autoSkill) break;
console.log(1);
if (!flags.shieldOn) break;
if (!flags.autoSkill) {
core.tip('error', '已开启自动切换技能!');
break;
}
core.status.route.push('key:51'); // 将按键记在录像中
core.playSound('光标移动');
if (flags.shield) flags.shield = false;

View File

@ -33,7 +33,7 @@ const marked = ref(hasMarkedEnemy(enemy.id));
function mark() {
if (marked.value) unmarkEnemy(enemy.id);
if (!marked.value) markEnemy(enemy.id);
marked.value = !marked.value;
marked.value = hasMarkedEnemy(enemy.id);
}
</script>

View File

@ -161,7 +161,10 @@ function keyup(e: KeyboardEvent) {
if (c === KeyCode.KeyX || c === KeyCode.Escape) {
exit();
}
if (c === KeyCode.Enter && !detail.value) {
if (
(c === KeyCode.Enter || c === KeyCode.KeyC || c === KeyCode.Space) &&
!detail.value
) {
select(enemy[selected.value], selected.value);
}
}

View File

@ -41,8 +41,8 @@ onMounted(async () => {
can.style.width = `${window.innerWidth}px`;
can.style.height = `${window.innerHeight}px`;
text.style.left = `${w + 10}px`;
text.style.top = `${window.innerHeight / 2 - h * 0.025}px`;
text.style.height = `${h * 0.05}px`;
text.style.top = `47.5vh`;
text.style.height = `5vh`;
text.style.width = `${textWidth}px`;
let soundPlayed = false;