[BUGFIX]修复上个属性配音相关PR报错问题。

This commit is contained in:
kuangthree 2023-10-10 22:22:18 +08:00
parent 6c91928ad5
commit 2debb92e61
1 changed files with 6 additions and 5 deletions

View File

@ -35458,13 +35458,14 @@
if(!lib.config.background_audio||get.type(card)=='equip'&&!lib.config.equip_audio) return;
var nature=get.natureList(card)[0];
if(lib.natureAudio[card.name]){
let shaAudio = lib.natureAudio.sha[nature];
if(shaAudio === 'default'){
let useAudio = lib.natureAudio[card.name][nature];
if(useAudio === 'default'){
game.playAudio('card',sex,`${card.name}_${nature}`);
}else if(shaAudio[sex]){
game.playAudio(shaAudio[sex]);
return;
}else if(useAudio && useAudio[sex]){
game.playAudio(useAudio[sex]);
return;
}
return;
}
const audio=lib.card[card.name].audio;
if(typeof audio=='string'){