die_audio添加播放本体任意武将阵亡配音的机制

This commit is contained in:
mengxinzxz 2023-10-11 16:19:49 +08:00 committed by GitHub
parent d299123229
commit 15c065bf3d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 2 deletions

View File

@ -19926,8 +19926,10 @@
game.playAudio(path);
}
}
else if(lib.character[player.name]&&lib.character[player.name][4].contains('die_audio')){
game.playAudio('die',player.name);
else if(lib.character[player.name]&&lib.character[player.name][4].some(tag=>tag.startsWith('die_audio'))){
var tag=lib.character[player.name][4].find(tag=>tag.startsWith('die_audio'));
var list=tag.split(':').slice(1);
game.playAudio('die',list.length?list[0]:player.name);
}
else{
game.playAudio('die',player.name,function(){