Merge pull request #671 from MDYY1/PR-Branch

bugfix
This commit is contained in:
Spmario233 2023-11-24 22:40:46 +08:00 committed by GitHub
commit eb5dbf3d3a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 9 additions and 2 deletions

View File

@ -27397,7 +27397,14 @@ new Promise(resolve=>{
subplayer:true subplayer:true
} }
} }
lib.character[skill]=[cfg.sex,cfg.group,cfg.maxHp,cfg.skills,['character:'+cfg.name]]; lib.character[skill]=[cfg.sex,cfg.group,cfg.maxHp,cfg.skills,[]];
if(Array.isArray(cfg.image)){
cfg.image.forEach(image=>lib.character[skill][4].push(image));
}else if(typeof cfg.image=='string'){
lib.character[skill][4].push(cfg.image);
}else{
lib.character[skill][4].push('character:'+cfg.name);
}
lib.translate[skill]=cfg.caption||get.rawName(cfg.name); lib.translate[skill]=cfg.caption||get.rawName(cfg.name);
player.storage[skill]=cfg; player.storage[skill]=cfg;
},this,skill,cfg); },this,skill,cfg);
@ -61443,7 +61450,7 @@ new Promise(resolve=>{
||(item.cardtags&&item.cardtags.contains(tag)), ||(item.cardtags&&item.cardtags.contains(tag)),
tag:(item,tag,item2,bool)=>{ tag:(item,tag,item2,bool)=>{
var result; var result;
if(get.info(item)&&get.info(item).ai&&get.info(item).ai.tag){ if(get.info(item,bool)&&get.info(item,bool).ai&&get.info(item,bool).ai.tag){
result=get.info(item,bool).ai.tag[tag]; result=get.info(item,bool).ai.tag[tag];
} }
if(typeof result=='function') return result(item,item2); if(typeof result=='function') return result(item,item2);