显示头像相框

This commit is contained in:
kron
2025-07-07 19:01:14 +08:00
parent 31973a1142
commit 06d8244e83
12 changed files with 71 additions and 32 deletions

View File

@@ -33,6 +33,21 @@ export default defineStore("store", {
// 方法
actions: {
getLvlImage(score) {
let lvlImage = "";
const rankInfos = this.config.randInfos || [];
rankInfos.some((r, index) => {
lvlImage = rankInfos[index].icoin;
if (r.upgrade_scores > score) {
if (rankInfos[index - 1]) {
lvlImage = rankInfos[index - 1].icoin;
}
return true;
}
return false;
});
return lvlImage;
},
getLvlName(score) {
let lvlName = "";
const rankInfos = this.config.randInfos || [];