优化怪物手册,状态栏初步

This commit is contained in:
AncTe committed 2022-12-28 12:13:52 +08:00
1 parent ed4b0fe730
commit 0ecdcbdf34
22 files changed
+153 -30

No files matched your search

-2
View File
@@ -75,7 +75,6 @@ export function getDefDamage(
if (!has(dam)) continue;
if (dam.damage === origin) continue;
if (dam.damage === res.at(-1)?.[1]) continue;
if (last === dam.damage) break;
last = dam.damage;
res.push([ratio * i + addDef, dam.damage]);
}
@@ -121,7 +120,6 @@ export function getCriticalDamage(
if (!has(dam)) continue;
if (dam.damage === origin) continue;
if (dam.damage === res.at(-1)?.[1]) continue;
if (last === dam.damage) break;
last = dam.damage;
res.push([ratio * i + addAtk, dam.damage]);
}
+9
View File
@@ -0,0 +1,9 @@
import { ref } from 'vue';
const status = ref(false);
export default function init() {
return { statusBarStatus: status };
}
export { status };
+5 -2
View File
@@ -9,6 +9,7 @@ export const toolOpened = ref(false);
export const equipOpened = ref(false);
export const transition = ref(true);
export const noClosePanel = ref(false);
let app: HTMLDivElement;
@@ -61,12 +62,14 @@ async function hideApp(index: number) {
await sleep(600);
uiStack.value.splice(index, 1);
app.style.display = 'none';
core.closePanel();
if (!noClosePanel.value) core.closePanel();
noClosePanel.value = false;
} else {
app.style.transition = '';
app.style.opacity = '0';
uiStack.value.splice(index, 1);
app.style.display = 'none';
core.closePanel();
if (!noClosePanel.value) core.closePanel();
noClosePanel.value = false;
}
}