自动用OL默认武将剪影代替无原画武将原画
This commit is contained in:
parent
8e23927898
commit
468d29b298
|
@ -4,16 +4,16 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
name:'huicui',
|
||||
connect:true,
|
||||
character:{
|
||||
dc_sunchen:['male','wu',4,['dczigu','dczuowei'],['unseen']],
|
||||
dc_sunchen:['male','wu',4,['dczigu','dczuowei']],
|
||||
dc_zhangmancheng:['male','qun',4,['dclvecheng','dczhongji']],
|
||||
yue_zhoufei:['female','wu',3,['dclingkong','dcxianshu']],
|
||||
dc_wuban:['male','shu',4,['dcyouzhan'],['clan:陈留吴氏','unseen']],
|
||||
dc_wuban:['male','shu',4,['dcyouzhan'],['clan:陈留吴氏']],
|
||||
yue_caiwenji:['female','qun',3,['dcshuangjia','dcbeifen']],
|
||||
liuchongluojun:['male','qun',3,['dcminze','dcjini']],
|
||||
yuechen:['male','wei',4,['dcporui','dcgonghu']],
|
||||
zhangkai:['male','qun',4,['dcxiangshu']],
|
||||
gaoxiang:['male','shu',4,['dcchiying']],
|
||||
yuanyin:['male','qun',3,['dcmoshou','dcyunjiu'],['unseen']],
|
||||
yuanyin:['male','qun',3,['dcmoshou','dcyunjiu']],
|
||||
dongwan:['female','qun',3,['dcshengdu','dcjieling']],
|
||||
zhangchu:['female','qun',3,['dcjizhong','dcrihui','dcguangshi']],
|
||||
peiyuanshao:['male','qun',4,['dcmoyu']],
|
||||
|
|
|
@ -32,7 +32,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
baoxin:['male','qun',4,['mutao','yimou'],['character:tw_baoxin','die_audio:tw_baoxin']],
|
||||
jiangji:['male','wei',3,['twjichou','jilun'],['character:tw_jiangji','die_audio:tw_jiangji']],
|
||||
liwei:['male','shu',4,['jiaohua'],['character:tw_liwei','die:tw_liwei']],
|
||||
laimin:['male','shu',3,['laishou','luanqun'],['unseen']],
|
||||
laimin:['male','shu',3,['laishou','luanqun']],
|
||||
yj_zhoubuyi:['male','wei',3,['mbhuiyao','mbquesong']],
|
||||
xin_guozhao:['female','wei',3,['yichong','wufei']],
|
||||
xin_zhangyi:['male','shu',4,['xinwurong','shizhi']],
|
||||
|
|
|
@ -23,10 +23,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
re_xushu:['male','shu',4,['zhuhai','qianxin']],
|
||||
re_lidian:['male','wei',3,['xunxun','xinwangxi']],
|
||||
re_zhongyao:['male','wei',3,['rehuomo','zuoding'],['clan:颍川钟氏']],
|
||||
xin_zhangliang:['male','qun',4,['rejijun','refangtong'],['unseen']],
|
||||
re_simalang:['male','wei',3,['requji','rejunbing'],['unseen']],
|
||||
re_zhugedan:['male','wei',4,['regongao','rejuyi'],['unseen']],
|
||||
re_caorui:['male','wei',3,['huituo','mingjian','rexingshuai'],['unseen','zhu']],
|
||||
xin_zhangliang:['male','qun',4,['rejijun','refangtong']],
|
||||
re_simalang:['male','wei',3,['requji','rejunbing']],
|
||||
re_zhugedan:['male','wei',4,['regongao','rejuyi']],
|
||||
re_caorui:['male','wei',3,['huituo','mingjian','rexingshuai'],['zhu']],
|
||||
re_caochong:['male','wei',3,['rechengxiang','renxin']],
|
||||
ol_zhangzhang:['male','wu',3,['olzhijian','olguzheng']],
|
||||
re_jsp_huangyueying:['female','qun',3,['rejiqiao','relinglong']],
|
||||
|
|
|
@ -38,8 +38,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
sb_liubiao:['male','qun',3,['sbzishou','sbzongshi']],
|
||||
sb_zhurong:['female','shu',4,['sblieren','sbjuxiang']],
|
||||
sb_menghuo:['male','shu',4,['sbhuoshou','sbzaiqi']],
|
||||
sb_yl_luzhi:['male','qun',3,['nzry_mingren','sbzhenliang'],['unseen']],
|
||||
sb_xiaoqiao:['female','wu',3,['sbtianxiang','xinhongyan'],['unseen']],
|
||||
sb_yl_luzhi:['male','qun',3,['nzry_mingren','sbzhenliang']],
|
||||
sb_xiaoqiao:['female','wu',3,['sbtianxiang','xinhongyan']],
|
||||
},
|
||||
characterSort:{
|
||||
sb:{
|
||||
|
|
|
@ -49,7 +49,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
haopu:['male','shu',4,['olzhenying']],
|
||||
ol_mengda:['male','shu',4,['olgoude']],
|
||||
ol_wanglang:['male','wei',3,['gushe','oljici']],
|
||||
ol_liuyan:['male','qun','4/6',['olpianan','olyinji','olkuisi'],['unseen']],
|
||||
ol_liuyan:['male','qun','4/6',['olpianan','olyinji','olkuisi']],
|
||||
lushi:['female','qun',3,['olzhuyan','olleijie']],
|
||||
zhangshiping:['male','shu',3,['olhongji','olxinggu']],
|
||||
sunhong:['male','wu',3,['olxianbi','olzenrun']],
|
||||
|
|
|
@ -12,7 +12,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
dc_mengda:['male','wei',4,['dclibang','dcwujie']],
|
||||
//dc_fuwan:['male','qun',4,['dcmoukui']],
|
||||
guānning:['male','shu',3,['dcxiuwen','dclongsong']],
|
||||
sunhuan:['male','wu',4,['dcniji'],['unseen']],
|
||||
sunhuan:['male','wu',4,['dcniji']],
|
||||
sunlang:['male','shu',4,['dctingxian','dcbenshi']],
|
||||
shiyi:['male','wu',3,['dccuichuan','dczhengxu']],
|
||||
dc_hujinding:['female','shu','3/6',['dcdeshi','dcwuyuan','huaizi']],
|
||||
|
|
|
@ -14,7 +14,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
old_huangfusong:['male','qun',4,['xinfenyue']],
|
||||
dc_xiahouba:['male','shu',4,['rebaobian']],
|
||||
dc_daxiaoqiao:['female','wu',3,['dcxingwu','dcluoyan']],
|
||||
tianshangyi:['female','wei',3,['dcposuo','dcxiaoren'],['unseen']],
|
||||
tianshangyi:['female','wei',3,['dcposuo','dcxiaoren']],
|
||||
sunlingluan:['female','wu',3,['dclingyue','dcpandi']],
|
||||
dc_wangjun:['male','qun',4,['dctongye','dcchangqu']],
|
||||
zhoubuyi:['male','wei',3,['dcshiji','dcsilun']],
|
||||
|
|
38
game/game.js
38
game/game.js
|
@ -8571,14 +8571,42 @@
|
|||
}
|
||||
else if(modeimage) src=`image/mode/${modeimage}/character/${name}${ext}`;
|
||||
else if(type=='character'&&lib.config.skin[name]&&arguments[2]!='noskin') src=`image/skin/${name}/${lib.config.skin[name]}${ext}`;
|
||||
else if(type=='character') src=`image/character/${gzbool?'gz_':''}${name}${ext}`;
|
||||
else if(type=='character'){
|
||||
src=`image/character/${gzbool?'gz_':''}${name}${ext}`;
|
||||
}
|
||||
else src=`image/${type}/${subfolder}/${name}${ext}`;
|
||||
}
|
||||
else src=`image/${name}${ext}`;
|
||||
this.setBackgroundImage(src);
|
||||
this.style.backgroundPositionX='center';
|
||||
this.style.backgroundSize='cover';
|
||||
return this;
|
||||
return new Promise((resolve,reject)=>{
|
||||
const image=new Image();
|
||||
image.src=`${lib.assetURL}${src}`;
|
||||
image.onload=resolve;
|
||||
if(type=='character') image.onerror=reject;
|
||||
}).then(()=>{
|
||||
this.setBackgroundImage(src);
|
||||
this.style.backgroundPositionX='center';
|
||||
this.style.backgroundSize='cover';
|
||||
}).catch(()=>new Promise((resolve,reject)=>{
|
||||
const nameinfo=get.character(name);
|
||||
const sex=nameinfo[0];
|
||||
src=`image/character/default_silhouette_${sex}${ext}`;
|
||||
const image=new Image();
|
||||
image.src=`${lib.assetURL}${src}`;
|
||||
image.onload=()=>resolve(src);
|
||||
image.onerror=reject;
|
||||
}).catch(()=>new Promise((resolve,reject)=>{
|
||||
const nameinfo=get.character(name);
|
||||
const sex=nameinfo[0];
|
||||
src=`image/character/default_silhouette_${sex=='female'?'female':'male'}${ext}`;
|
||||
const image=new Image();
|
||||
image.src=`${lib.assetURL}${src}`;
|
||||
image.onload=()=>resolve(src);
|
||||
image.onerror=reject;
|
||||
})).then((src)=>{
|
||||
this.setBackgroundImage(src);
|
||||
this.style.backgroundPositionX='center';
|
||||
this.style.backgroundSize='cover';
|
||||
}));
|
||||
}
|
||||
});
|
||||
HTMLDivElement.prototype.setBackgroundDB=function(img){
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 67 KiB |
Binary file not shown.
After Width: | Height: | Size: 70 KiB |
Loading…
Reference in New Issue