修复临时获得的许劭【评鉴】获得的技能在失去【评鉴】后发动不立即失去的bug,添加【评鉴】的lib.skill.rehuashen.createAudio

This commit is contained in:
mengxinzxz 2023-11-29 22:18:26 +08:00
parent ac7adea4b5
commit 88ed58bb89
1 changed files with 14 additions and 6 deletions

View File

@ -8297,9 +8297,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
player.addSkill('pingjian_check'); player.addSkill('pingjian_check');
if(!player.storage.pingjian_check) player.storage.pingjian_check={}; if(!player.storage.pingjian_check) player.storage.pingjian_check={};
}, },
onremove:function(player){
player.removeSkill('pingjian_check');
},
audio:2, audio:2,
trigger:{player:['damageEnd','phaseJieshuBegin']}, trigger:{player:['damageEnd','phaseJieshuBegin']},
frequent:true, frequent:true,
@ -8359,12 +8356,17 @@ game.import('character',function(lib,game,ui,get,ai,_status){
} }
if(list.length>2) break; if(list.length>2) break;
} }
if(skills.length) player.chooseControl(skills).set('dialog',['评鉴:请选择尝试发动的技能',[list,'character']]); if(skills.length){
event.list=list;
player.chooseControl(skills).set('dialog',['评鉴:请选择尝试发动的技能',[list,'character']]);
}
else event.finish(); else event.finish();
'step 1' 'step 1'
player.markAuto('pingjian',[result.control]); player.markAuto('pingjian',[result.control]);
player.addTempSkill(result.control); player.addTempSkill(result.control);
player.storage.pingjian_check[result.control]=(trigger.name=='damage'?trigger:'phaseJieshu'); player.storage.pingjian_check[result.control]=(trigger.name=='damage'?trigger:'phaseJieshu');
var name=event.list.find(name=>lib.character[name][3].includes(result.control));
if(name) lib.skill.rehuashen.createAudio(name,result.control,'xushao');
}, },
group:'pingjian_use', group:'pingjian_use',
phaseUse_special:[], phaseUse_special:[],
@ -8442,12 +8444,17 @@ game.import('character',function(lib,game,ui,get,ai,_status){
} }
if(list.length>2) break; if(list.length>2) break;
} }
if(skills.length) player.chooseControl(skills).set('dialog',['评鉴:请选择尝试发动的技能',[list,'character']]); if(skills.length){
event.list=list;
player.chooseControl(skills).set('dialog',['评鉴:请选择尝试发动的技能',[list,'character']]);
}
else event.finish(); else event.finish();
'step 1' 'step 1'
player.markAuto('pingjian',[result.control]); player.markAuto('pingjian',[result.control]);
player.addTempSkill(result.control); player.addTempSkill(result.control);
player.storage.pingjian_check[result.control]='phaseUse'; player.storage.pingjian_check[result.control]='phaseUse';
var name=event.list.find(name=>lib.character[name][3].includes(result.control));
if(name) lib.skill.rehuashen.createAudio(name,result.control,'xushao');
}, },
ai:{order:12,result:{player:1}}, ai:{order:12,result:{player:1}},
}, },
@ -8455,7 +8462,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
charlotte:true, charlotte:true,
trigger:{player:['useSkill','logSkillBegin']}, trigger:{player:['useSkill','logSkillBegin']},
filter:function(event,player){ filter:function(event,player){
if(get.info(event.skill).charlotte) return false; var info=get.info(event.skill);
if(info&&info.charlotte) return false;
var skill=event.sourceSkill||event.skill; var skill=event.sourceSkill||event.skill;
return player.storage.pingjian_check[skill]; return player.storage.pingjian_check[skill];
}, },