增加部分Q版角色头像资源
@ -45,9 +45,11 @@ const ProfileStat = {
|
|||||||
}
|
}
|
||||||
|
|
||||||
let faceChar = Character.get(player.face || avatarRet[0]?.id)
|
let faceChar = Character.get(player.face || avatarRet[0]?.id)
|
||||||
|
let imgs = faceChar.imgs
|
||||||
let face = {
|
let face = {
|
||||||
banner: faceChar.imgs?.banner,
|
banner: imgs?.banner,
|
||||||
face: faceChar.imgs?.face,
|
face: imgs?.face,
|
||||||
|
qFace: imgs?.qFace,
|
||||||
name: player.name || `#${uid}`,
|
name: player.name || `#${uid}`,
|
||||||
sign: player.sign,
|
sign: player.sign,
|
||||||
level: player.level
|
level: player.level
|
||||||
|
@ -82,8 +82,16 @@ export default class Player extends Base {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 保存json文件
|
* 保存json文件
|
||||||
|
* @param flag false时暂时禁用保存,true时启用保存,并保存数据
|
||||||
|
* @returns {boolean}
|
||||||
*/
|
*/
|
||||||
save () {
|
save (flag = null) {
|
||||||
|
if (flag === true) {
|
||||||
|
this._save = true
|
||||||
|
} else if (flag === false || this._save === false) {
|
||||||
|
this._save = false
|
||||||
|
return false
|
||||||
|
}
|
||||||
let ret = Data.getData(this, 'uid,name,level,word,face,card,sign,info,_info,_mys,_profile')
|
let ret = Data.getData(this, 'uid,name,level,word,face,card,sign,info,_info,_mys,_profile')
|
||||||
ret.avatars = {}
|
ret.avatars = {}
|
||||||
this.forEachAvatar((avatar) => {
|
this.forEachAvatar((avatar) => {
|
||||||
@ -257,18 +265,25 @@ export default class Player extends Base {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async refresh (cfg) {
|
async refresh (cfg) {
|
||||||
if (cfg.index || cfg.index === 0) {
|
this.save(false)
|
||||||
await this.refreshMysInfo(cfg.index)
|
try {
|
||||||
}
|
if (cfg.index || cfg.index === 0) {
|
||||||
if (cfg.detail || cfg.detail === 0) {
|
await this.refreshMysInfo(cfg.index)
|
||||||
await this.refreshMysDetail(cfg.detail)
|
}
|
||||||
}
|
if (cfg.detail || cfg.detail === 0) {
|
||||||
if (cfg.talent || cfg.talent === 0) {
|
await this.refreshMysDetail(cfg.detail)
|
||||||
await this.refreshTalent(cfg.ids, cfg.talent)
|
}
|
||||||
}
|
if (cfg.talent || cfg.talent === 0) {
|
||||||
if (cfg.profile || cfg.profile === 0) {
|
await this.refreshTalent(cfg.ids, cfg.talent)
|
||||||
await this.refreshProfile(cfg.profile)
|
}
|
||||||
|
if (cfg.profile || cfg.profile === 0) {
|
||||||
|
await this.refreshProfile(cfg.profile)
|
||||||
|
}
|
||||||
|
} catch (e) {
|
||||||
|
Bot.logger.mark(`刷新uid${this.uid}数据遇到错误...`)
|
||||||
|
console.log(e)
|
||||||
}
|
}
|
||||||
|
this.save(true)
|
||||||
}
|
}
|
||||||
|
|
||||||
async refreshAndGetAvatarData (cfg) {
|
async refreshAndGetAvatarData (cfg) {
|
||||||
|
@ -101,10 +101,10 @@ const CharImg = {
|
|||||||
imgs[key] = `${travelerElem ? tPath : nPath}${path}.${fileType}`
|
imgs[key] = `${travelerElem ? tPath : nPath}${path}.${fileType}`
|
||||||
}
|
}
|
||||||
add('face', 'imgs/face', `imgs/face${costumeIdx}`)
|
add('face', 'imgs/face', `imgs/face${costumeIdx}`)
|
||||||
|
add('qFace', 'imgs/face', 'imgs/face-q')
|
||||||
add('side', 'imgs/side', `imgs/side${costumeIdx}`)
|
add('side', 'imgs/side', `imgs/side${costumeIdx}`)
|
||||||
add('gacha', 'imgs/gacha')
|
add('gacha', 'imgs/gacha')
|
||||||
add('splash', 'imgs/splash', `imgs/splash${costumeIdx}`)
|
add('splash', 'imgs/splash', `imgs/splash${costumeIdx}`)
|
||||||
// 检查彩蛋自定义
|
|
||||||
tAdd('card', 'imgs/card')
|
tAdd('card', 'imgs/card')
|
||||||
tAdd('banner', 'imgs/banner')
|
tAdd('banner', 'imgs/banner')
|
||||||
for (let i = 1; i <= 6; i++) {
|
for (let i = 1; i <= 6; i++) {
|
||||||
|
@ -18,7 +18,7 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
updatePlayer (player, data) {
|
updatePlayer (player, data) {
|
||||||
player.setBasicData(Data.getData(data, 'name:nickname,face:profilePicture.avatarID,card:nameCardID,level,word:worldLevel,sign:signature'))
|
player.setBasicData(Data.getData(data, 'name:nickname,face:profilePicture.avatarId,card:nameCardID,level,word:worldLevel,sign:signature'))
|
||||||
lodash.forEach(data.showAvatarInfoList, (ds) => {
|
lodash.forEach(data.showAvatarInfoList, (ds) => {
|
||||||
let ret = MiaoData.setAvatar(player, ds)
|
let ret = MiaoData.setAvatar(player, ds)
|
||||||
if (ret) {
|
if (ret) {
|
||||||
|
@ -9,13 +9,12 @@
|
|||||||
{{block 'main'}}
|
{{block 'main'}}
|
||||||
<div class="user-banner" style="background-image:url({{_res_path}}{{face?.banner}})">
|
<div class="user-banner" style="background-image:url({{_res_path}}{{face?.banner}})">
|
||||||
<div class="face">
|
<div class="face">
|
||||||
<span style="background-image:url({{_res_path}}{{face?.face}})"></span>
|
<span style="background-image:url({{_res_path}}{{face?.qFace||face?.face}})"></span>
|
||||||
</div>
|
</div>
|
||||||
<div class="user-info">
|
<div class="user-info">
|
||||||
<div class="name">
|
<div class="name">
|
||||||
<strong>{{face.name}}</strong>
|
<strong>{{face.name}}</strong>
|
||||||
{{if face.level && face.level > 1}} Lv.{{face.level}}{{/if}}
|
{{if face.level && face.level > 1}} Lv.{{face.level}}{{/if}}
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div class="uid">
|
<div class="uid">
|
||||||
{{if uid}}<span> #{{uid}}</span>{{/if}}
|
{{if uid}}<span> #{{uid}}</span>{{/if}}
|
||||||
@ -36,7 +35,6 @@
|
|||||||
{{/if}}
|
{{/if}}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
{{if !isSelfCookie}}
|
{{if !isSelfCookie}}
|
||||||
<div class="ck-notice">未绑定CK或CK失效,信息可能不完全。发送<strong>#体力帮助</strong>查看CK绑定方法,发送<strong>#更新面板</strong>更新游戏内角色展柜信息</div>
|
<div class="ck-notice">未绑定CK或CK失效,信息可能不完全。发送<strong>#体力帮助</strong>查看CK绑定方法,发送<strong>#更新面板</strong>更新游戏内角色展柜信息</div>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
@ -419,6 +419,9 @@ ul.cont-msg li strong,
|
|||||||
.item-icon.opacity-bg.star5 {
|
.item-icon.opacity-bg.star5 {
|
||||||
background-image: url("../common/item/bg5-o.png");
|
background-image: url("../common/item/bg5-o.png");
|
||||||
}
|
}
|
||||||
|
.item-icon.star-w {
|
||||||
|
background: #fff;
|
||||||
|
}
|
||||||
.item-list {
|
.item-list {
|
||||||
display: flex;
|
display: flex;
|
||||||
}
|
}
|
||||||
|
@ -348,6 +348,10 @@ ul.cont-msg, .cont-footer ul {
|
|||||||
background-image: url("../common/item/bg@{value}-o.png");
|
background-image: url("../common/item/bg@{value}-o.png");
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
&.star-w {
|
||||||
|
background: #fff;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.item-list {
|
.item-list {
|
||||||
|
BIN
resources/meta/character/七七/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 65 KiB |
BIN
resources/meta/character/云堇/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 89 KiB |
BIN
resources/meta/character/优菈/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 109 KiB |
BIN
resources/meta/character/八重神子/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 86 KiB |
BIN
resources/meta/character/刻晴/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 74 KiB |
BIN
resources/meta/character/可莉/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 92 KiB |
BIN
resources/meta/character/妮露/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 133 KiB |
BIN
resources/meta/character/宵宫/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 125 KiB |
BIN
resources/meta/character/早柚/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 36 KiB |
BIN
resources/meta/character/枫原万叶/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 72 KiB |
BIN
resources/meta/character/流浪者/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 125 KiB |
BIN
resources/meta/character/温迪/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 68 KiB |
BIN
resources/meta/character/烟绯/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 113 KiB |
BIN
resources/meta/character/珊瑚宫心海/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 60 KiB |
BIN
resources/meta/character/琴/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 84 KiB |
BIN
resources/meta/character/瑶瑶/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 119 KiB |
BIN
resources/meta/character/甘雨/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 98 KiB |
BIN
resources/meta/character/申鹤/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 78 KiB |
BIN
resources/meta/character/神里绫人/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 78 KiB |
BIN
resources/meta/character/神里绫华/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 78 KiB |
BIN
resources/meta/character/空/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 68 KiB |
BIN
resources/meta/character/纳西妲/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 125 KiB |
BIN
resources/meta/character/胡桃/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 69 KiB |
BIN
resources/meta/character/艾尔海森/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 87 KiB |
BIN
resources/meta/character/芭芭拉/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 77 KiB |
BIN
resources/meta/character/荧/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 73 KiB |
BIN
resources/meta/character/莫娜/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 75 KiB |
BIN
resources/meta/character/菲谢尔/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 77 KiB |
BIN
resources/meta/character/诺艾尔/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 70 KiB |
BIN
resources/meta/character/赛诺/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 61 KiB |
BIN
resources/meta/character/达达利亚/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 74 KiB |
BIN
resources/meta/character/迪卢克/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 72 KiB |
BIN
resources/meta/character/迪奥娜/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 45 KiB |
BIN
resources/meta/character/钟离/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 104 KiB |
BIN
resources/meta/character/阿贝多/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 67 KiB |
BIN
resources/meta/character/雷电将军/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 60 KiB |
BIN
resources/meta/character/香菱/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 65 KiB |
BIN
resources/meta/character/魈/imgs/face-q.webp
Normal file
After Width: | Height: | Size: 76 KiB |
@ -7,7 +7,7 @@
|
|||||||
{{block 'main'}}
|
{{block 'main'}}
|
||||||
<div class="head-box" style="background-image:url('{{_res_path}}{{imgs.card}}')">
|
<div class="head-box" style="background-image:url('{{_res_path}}{{imgs.card}}')">
|
||||||
<div class="head">
|
<div class="head">
|
||||||
<img src="{{_res_path}}{{imgs.face}}"/>
|
<img src="{{_res_path}}{{imgs.qFace||imgs.face}}"/>
|
||||||
</div>
|
</div>
|
||||||
<!-- <div class="head-astro">{{astro}}</div>
|
<!-- <div class="head-astro">{{astro}}</div>
|
||||||
<div class="head-icon">
|
<div class="head-icon">
|
||||||
|