Merge pull request #208 from copcap/dev

新增OL文钦、族王浑;解禁新杀杜预、郤正
This commit is contained in:
Spmario233 2023-08-13 20:16:39 +08:00 committed by GitHub
commit b0f52ef40c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
17 changed files with 391 additions and 31 deletions

BIN
audio/die/xizheng.mp3 Normal file

Binary file not shown.

BIN
audio/skill/dcdanyi1.mp3 Normal file

Binary file not shown.

BIN
audio/skill/dcdanyi2.mp3 Normal file

Binary file not shown.

BIN
audio/skill/dcwencan1.mp3 Normal file

Binary file not shown.

BIN
audio/skill/dcwencan2.mp3 Normal file

Binary file not shown.

View File

@ -706,7 +706,7 @@ game.import('card',function(lib,game,ui,get,ai,_status){
yonglv_info:'锁定技。其他角色至你的距离视为1。',
yonglv_append:'<span class="text" style="font-family: yuanli">它旁边的就是王仲宣。</span>',
zhanxiang:'战象',
zhanxiang_info:'锁定技。当你成为〖赠予〗的目标后,你将此次赠予的效果改为“将赠予牌移动至弃牌堆”。',
zhanxiang_info:'锁定技。①其他角色至你的距离+1。②当你成为〖赠予〗的目标后,你将此次赠予的效果改为“将赠予牌移动至弃牌堆”。',
xinge:'信鸽',
xinge_info:'出牌阶段限一次。你可以将一张手牌交给一名其他角色。',
xinge_append:'<span class="text" style="font-family: yuanli">咕咕咕。</span>',

View File

@ -17,17 +17,153 @@ game.import('character',function(lib,game,ui,get,ai,_status){
clan_wangling:['male','wei',4,['clanbolong','clanzhongliu'],['clan:太原王氏']],
clan_zhongyan:['female','jin',3,['clanguangu','clanxiaoyong','clanbaozu'],['clan:颍川钟氏']],
clan_wangyun:['male','qun',3,['clanjiexuan','clanmingjie','clanzhongliu'],['clan:太原王氏']],
clan_wanghun:['male','jin',3,['clanfuxun','clanchenya','clanzhongliu'],['clan:太原王氏']],
},
characterSort:{
clan:{
clan_wu:['clan_wuxian','clan_wuban','clan_wukuang'],
clan_xun:['clan_xunshu','clan_xunchen','clan_xuncai','clan_xuncan'],
clan_han:['clan_hanshao','clan_hanrong'],
clan_wang:['clan_wangling','clan_wangyun'],
clan_wang:['clan_wangling','clan_wangyun','clan_wanghun'],
clan_zhong:['clan_zhongyan'],
},
},
skill:{
//族王浑
clanfuxun:{
audio:2,
enable:'phaseUse',
usable:1,
filterCard:true,
position:'h',
discard:false,
lose:false,
delay:false,
selectCard:function(){
var player=_status.event.player;
if(ui.selected.targets.length&&!ui.selected.targets[0].countGainableCards(player,'h')) return 1;
return [0,1];
},
filterTarget:function(card,player,target){
if(player==target) return false;
if(!ui.selected.cards.length) return target.countGainableCards(player,'h')>0;
return true;
},
content:function(){
'step 0'
if(cards.length){
player.give(cards,target);
}
else{
player.gainPlayerCard(target,'h',true);
}
'step 1'
var evtx=event.getParent('phaseUse');
if(player.countCards('h')==target.countCards('h')&&evtx&&!target.hasHistory('lose',evt=>{
return evt.getParent(3).name!='clanfuxun'&&evt.getParent('phaseUse')==evtx&&evt.cards2.length;
})&&!target.hasHistory('gain',evt=>{
return evt.getParent().name!='clanfuxun'&&evt.getParent('phaseUse')==evtx&&evt.cards.length;
})&&player.countCards('he')){
var list=[];
for(var name of lib.inpile){
if(get.type(name)!='basic') continue;
if(player.hasUseTarget({name:name})) list.push(['基本','',name]);
if(name=='sha'){
for(var nature of lib.inpile_nature){
if(player.hasUseTarget({name:name,nature:nature})) list.push(['基本','',name,nature]);
}
}
}
if(list.length){
player.chooseButton(['是否将一张牌当做一种基本牌使用?',[list,'vcard']]).set('ai',button=>{
return _status.event.player.getUseValue({name:button.link[2],nature:button.link[3]});
});
}
else event.finish();
}
else event.finish();
'step 2'
if(result.bool){
var card={
name:result.links[0][2],
nature:result.links[0][3]
};
game.broadcastAll(function(card){
lib.skill.clanfuxun_backup.viewAs=card;
},card);
var next=player.chooseToUse();
next.set('openskilldialog','将一张牌当做'+get.translation(card)+'使用');
next.set('norestore',true);
next.set('addCount',false);
next.set('_backupevent','clanfuxun_backup');
next.set('custom',{
add:{},
replace:{window:function(){}}
});
next.backup('clanfuxun_backup');
}
},
ai:{
order:2,
result:{
target:-1,
},
},
subSkill:{
backup:{
filterCard:function(card){
return get.itemtype(card)=='card';
},
position:'hes',
filterTarget:lib.filter.targetEnabled,
selectCard:1,
check:(card)=>6-get.value(card),
log:false,
precontent:function(){
delete event.result.skill;
},
},
}
},
clanchenya:{
audio:2,
trigger:{
global:['useSkillAfter','logSkill'],
},
filter:function(event,player){
if(event.type!='player') return false;
var skill=event.sourceSkill||event.skill;
var info=get.info(skill);
if(info.charlotte) return false;
var translation=lib.translate[skill+'_info'];
if(translation&&!(/(?<!“)出牌阶段限一次/.test(translation))) return false;
return event.player.countCards('h')>0;
},
check:function(event,player){
return get.attitude(player,event.player)>0;
},
logTarget:'player',
content:function(){
'step 0'
var num=trigger.player.countCards('h');
trigger.player.chooseCard('是否重铸任意张牌名字数为'+num+'的牌?',[1,Infinity],'he',(card,player,target)=>{
if(!_status.event.cards.contains(card)) return false;
var mod=game.checkMod(card,player,'unchanged','cardChongzhuable',player);
return mod=='unchanged';
}).set('ai',card=>{
var val=get.value(card);
return 6-val;
}).set('cards',trigger.player.getCards('he',card=>{
return lib.skill.dcweidang.getLength(card)==num;
}));
'step 1'
if(result.bool){
var cards=result.cards;
trigger.player.loseToDiscardpile(cards);
trigger.player.draw(cards.length);
}
}
},
//族王允
clanjiexuan:{
audio:2,
@ -435,7 +571,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
},
prompt:function(result){
if(result.index) return '点击“确定”以观看牌堆顶牌';
if(result.index>0) return '点击“确定”以观看牌堆顶牌';
return '观骨:选择观看牌的目标';
},
},
@ -600,7 +736,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},
clanzhongliu:{
audio:2,
audioname:['clan_wangling','clan_wangyun'],
audioname:['clan_wangling','clan_wangyun','clan_wanghun'],
trigger:{player:'useCard'},
forced:true,
clanSkill:true,
@ -2058,6 +2194,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
hanshao:'韩韶生卒年不详字仲黄颍川舞阳今河南省漯河市东汉桓帝时出仕。任郡吏有政绩继而被征入司徒府。他公正廉明尽心民事视民苦如在己身政绩卓著。汉永寿二年公元156年泰山贼公孙举率流寇数千骚扰嬴县守令因不能拒敌安民多受制裁朝廷命尚书府从三府司徒、司马、司空属员中选择能治理民事又能拒寇入侵的官员前往镇守。韩韶被封为“嬴长”到嬴县上任他是莱芜历史上唯一的一位“嬴长”。',
hanrong:'韩融127年196年字元长颍川舞阳今属河南省漯河市人。赢长韩韶子献帝时大臣。中平五年188年融与荀爽、陈纪等十四人并博士征不至。董卓废立融等复俱公车征。初平元年190年六月融为大鸿胪奉命与执金吾胡母班等出使关东。献帝东迁为李傕、郭汜等所败融为太仆奉命至弘农与傕、汜连和使其放遣公卿百官及宫女妇人。',
wukuang:'吴匡生卒年不详兖州陈留今河南开封市人。东汉末年大臣大将军何进部将。光熹元年公元189年汉灵帝死后十常侍干预朝政大将军何进谋诛宦官但失败被杀吴匡联合曹操、袁绍等杀尽宦官攻杀车骑将军何苗。兴平二年公元195年十月李傕、郭汜后悔放汉献帝东归洛阳于是联合起来追击曹操遂起兵平乱但在回朝后曹操挟天子以令诸侯实行专权但遭到吴匡反对。',
wanghun:'王浑223年297年字玄冲太原郡晋阳县今山西省太原市人。魏晋时期名臣曹魏司空王昶的儿子。王浑早年为大将军曹爽的掾吏高平陵政变后循例免官出任怀县县令、散骑侍郎等职袭封京陵县侯。西晋王朝建立后加号扬烈将军历任征虏将军、东中郎将、豫州刺史等职积极筹划伐吴方略。咸宁五年279年配合镇南将军杜预灭亡吴国迁征东大将军、左仆射、司徒公晋爵京陵县公。晋惠帝司马衷即位加任侍中衔。楚王司马玮发动政变有意寻求支持遭到严词拒绝。楚王司马玮死后复任司徒、录尚书事。元康七年297年王浑去世享年七十五岁谥号为元。《唐会要》尊为“魏晋八君子”之一。',
},
dynamicTranslate:{
clanlianzhu:function(player){
@ -2139,6 +2276,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
clanjiexuan_info:'限定技,转换技。阴:你可以将一张红色牌当【顺手牵羊】使用;阳:你可以将一张黑色牌当【过河拆桥】使用。',
clanmingjie:'铭戒',
clanmingjie_info:'限定技。出牌阶段,你可以选择一名角色,然后直到其下回合结束时,当你使用牌时你可以指定其为额外目标。然后其下回合结束时,你可以使用本回合使用过的黑桃牌和被抵消过的牌。',
clan_wanghun:'族王浑',
clanfuxun:'抚循',
clanfuxun_info:'出牌阶段限一次。你可以获得或交给一名其他角色一张手牌,然后若其手牌数与你相等且于此阶段仅以此法获得或失去过牌,你可以将一张牌当任意基本牌使用。',
clanchenya:'沉雅',
clanchenya_info:'当一名角色发动“出牌阶段限一次”的技能后你可以令其重铸任意张牌名字数为X的牌X为其手牌数。',
clan_wu:'陈留·吴氏',
clan_xun:'颍川·荀氏',

View File

@ -11,7 +11,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
zhangkai:['male','qun',4,['dcxiangshu']],
gaoxiang:['male','shu',4,['dcchiying'],['unseen']],
yuanyin:['male','qun',3,['dcmoshou','dcyunjiu'],['unseen']],
dongwan:['female','qun',3,['dcshengdu','dcxianjiao'],['unseen']],
dongwan:['female','qun',3,['dcshengdu','dcjieling'],['unseen']],
zhangchu:['female','qun',3,['dcjizhong','dcrihui','dcguangshi']],
peiyuanshao:['male','qun',4,['dcmoyu'],['unseen']],
mengjie:['male','qun',3,['dcyinlu','dcyouqi']],
@ -1051,7 +1051,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
var att=get.attitude(player,target);
var eff=get.effect(target,{
name:'sha',
storage:{dcxianjiao:true},
storage:{dcjieling:true},
},player,player);
var value=att/5;
if(value<0) value=-value/1.3;
@ -1102,14 +1102,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
}
},
dcxianjiao:{
dcjieling:{
audio:2,
enable:'phaseUse',
usable:1,
position:'hs',
viewAs:{
name:'sha',
storage:{dcxianjiao:true}
storage:{dcjieling:true}
},
filterCard:function(card,player){
if(ui.selected.cards.length){
@ -1123,7 +1123,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
return 6-get.value(card);
},
precontent:function(){
player.addTempSkill('dcxianjiao_after');
player.addTempSkill('dcjieling_after');
event.getParent().addCount=false;
},
ai:{
@ -1134,7 +1134,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
locked:false,
mod:{
targetInRange:function(card){
if(card.storage&&card.storage.dcxianjiao) return true;
if(card.storage&&card.storage.dcjieling) return true;
},
},
subSkill:{
@ -1144,7 +1144,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
direct:true,
charlotte:true,
filter:function(event,player){
return event.card.name=='sha'&&event.card.storage&&event.card.storage.dcxianjiao;
return event.card.name=='sha'&&event.card.storage&&event.card.storage.dcjieling;
},
content:function(){
'step 0'
@ -1152,7 +1152,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
return current.hasHistory('damage',evt=>evt.card==trigger.card);
});
var targets=trigger.targets.filter(i=>i.isIn());
player.logSkill('dcxianjiao_after',targets);
player.logSkill('dcjieling_after',targets);
if(damaged){
for(var target of targets){
target.loseHp();
@ -10208,8 +10208,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
dongwan:'董绾',
dcshengdu:'生妒',
dcshengdu_info:'回合开始时,你可以选择一名其他角色。当其于其的下个摸牌阶段获得牌后,你摸等量的牌。',
dcxianjiao:'献绞',
dcxianjiao_info:'出牌阶段限一次。你可以将两张颜色不同的手牌当无距离限制且无任何次数限制的【杀】使用。然后若此【杀】造成了伤害所有目标角色失去1点体力未造成伤害你对所有目标角色依次发动一次〖生妒〗。',
dcjieling:'介绫',
dcjieling_info:'出牌阶段限一次。你可以将两张颜色不同的手牌当无距离限制且无任何次数限制的【杀】使用。然后若此【杀】造成了伤害所有目标角色失去1点体力未造成伤害你对所有目标角色依次发动一次〖生妒〗。',
yuanyin:'袁胤',
dcmoshou:'墨守',
dcmoshou_info:'当你成为其他角色使用的黑色牌的目标后你可以摸X张牌X为你本局游戏此前发动过此技能的次数÷3的余数+1。',

View File

@ -2256,8 +2256,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
return event.isFirstTarget&&event.card.name=='sha'&&player.hasEmptySlot(1);
},
content:function(){
trigger.getParent().targets=trigger.getParent().targets.concat(trigger.targets);
trigger.getParent().triggeredTargets4=trigger.getParent().triggeredTargets4.concat(trigger.targets);
// trigger.getParent().targets=trigger.getParent().targets.concat(trigger.targets);
// trigger.getParent().triggeredTargets4=trigger.getParent().triggeredTargets4.concat(trigger.targets);
trigger.getParent().effectCount++;
},
ai:{
effect:{

View File

@ -10,7 +10,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
sp_tianzhu:["wutugu","yanbaihu","shamoke","panfeng","zhugedan",'huangzu','gaogan',"tadun","fanjiangzhangda","ahuinan","dongtuna"],
sp_nvshi:["lingju","guanyinping","zhangxingcai","mayunlu","dongbai","zhaoxiang",'ol_zhangchangpu','ol_xinxianying',"daxiaoqiao","jin_guohuai"],
sp_shaowei:["simahui","zhangbao","zhanglu","zhugeguo","xujing","zhangling",'huangchengyan','ol_puyuan','zhangzhi','lushi'],
sp_huben:["caohong","xiahouba","zhugeke","zumao","wenpin","litong","mazhong","heqi","quyi","luzhi","zangba","yuejin","dingfeng","wuyan","ol_zhuling","tianyu","huojun",'zhaoyǎn','dengzhong','ol_furong','macheng','ol_zhangyì','ol_zhujun','maxiumatie','luoxian'],
sp_huben:["caohong","xiahouba","zhugeke","zumao","wenpin","litong","mazhong","heqi","quyi","luzhi","zangba","yuejin","dingfeng","wuyan","ol_zhuling","tianyu","huojun",'zhaoyǎn','dengzhong','ol_furong','macheng','ol_zhangyì','ol_zhujun','maxiumatie','luoxian','ol_wenqin'],
sp_liesi:['mizhu','weizi','ol_liuba','zhangshiping'],
sp_default:["sp_diaochan","sp_zhaoyun","sp_sunshangxiang","sp_caoren","sp_jiangwei","sp_machao","sp_caiwenji","jsp_guanyu","jsp_huangyueying","sp_pangde","sp_jiaxu","yuanshu",'sp_zhangliao','sp_ol_zhanghe','sp_menghuo'],
sp_waitforsort:['ol_huban','ol_mengda','haopu'],
@ -28,6 +28,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},
},
character:{
ol_wenqin:['male','wei',4,['olguangao','olhuiqi']],
haopu:['male','shu',4,['olzhenying']],
ol_mengda:['male','shu',4,['olgoude']],
ol_wanglang:['male','wei',3,['gushe','oljici']],
@ -686,6 +687,149 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},
},
skill:{
//OL文钦
olguangao:{
audio:2,
trigger:{
global:'useCard2',
},
filter:function(event,player){
var card=event.card;
if(card.name!='sha') return false;
if(event.player==player){
if(game.hasPlayer(current=>{
return current.isIn()&&!event.targets.contains(current)&&player.canUse(event.card,current,false);
})){
return true;
}
return false;
}
return event.player.isIn()&&!event.targets.contains(player)&&event.player.canUse(card,player);
},
direct:true,
content:function(){
'step 0'
if(trigger.player==player){
player.chooseTarget(get.prompt('olguangao'),'为'+get.translation(trigger.card)+'额外指定一个目标。然后若你手牌数为偶数,你摸一张牌并令此牌对任意目标无效。',(card,player,target)=>{
return !_status.event.sourcex.contains(target)&&player.canUse(_status.event.card,target,false);
}).set('sourcex',trigger.targets).set('ai',function(target){
var player=_status.event.player;
var eff=get.effect(target,_status.event.card,player,player);
if(player.countCards('h')%2==0&&player.hasSkill('olxieju')&&player.isPhaseUsing()&&!player.getStat().skill.olxieju) return 1-eff;
return eff;
}).set('card',trigger.card);
}
else{
trigger.player.chooseBool('是否发动'+get.translation(player)+'的【犷骜】?','令其成为'+get.translation(trigger.card)+'的额外目标。然后若其手牌数为偶数,其摸一张牌并令此牌对任意目标无效。').set('ai',()=>{
return _status.event.bool;
}).set('bool',function(){
var att=get.attitude(trigger.player,player);
var eff=get.effect(player,trigger.card,trigger.player,trigger.player);
if(player.countCards('h')%2==0&&att>0) return true;
if(eff>0) return true;
return false;
}());
}
'step 1'
if(result.bool){
var target=result.targets&&result.targets[0];
if(!target){
target=player;
trigger.player.logSkill('olguangao',player);
}
else{
player.logSkill('olguangao',target);
}
trigger.targets.add(target);
game.delayex();
}
else event.finish();
'step 2'
if(player.countCards('h')%2==0){
player.draw();
player.chooseTarget('犷骜:令此杀对其任意个目标无效',[1,Infinity],true,(card,player,target)=>{
return _status.event.targetsx.contains(target);
}).set('ai',target=>{
return 1-get.effect(target,_status.event.getTrigger().card,_status.event.player,_status.event.player);
}).set('targetsx',trigger.targets);
}
else event.finish();
'step 3'
if(result.bool){
player.line(result.targets);
trigger.excluded.addArray(result.targets);
}
}
},
olhuiqi:{
audio:2,
trigger:{
global:'phaseEnd',
},
juexingji:true,
forced:true,
skillAnimation:true,
animationColor:'thunder',
derivation:'olxieju',
filter:function(event,player){
var targets=[];
game.getGlobalHistory('useCard',evt=>{
if(evt.targets&&evt.targets.length){
targets.addArray(evt.targets);
}
});
return targets.length==3;
},
content:function(){
'step 0'
player.awakenSkill('olhuiqi');
player.addSkillLog('olxieju');
player.insertPhase();
}
},
olxieju:{
audio:2,
enable:'phaseUse',
usable:1,
filter:function(event,player){
return event.olxieju&&event.olxieju.length;
},
onChooseToUse:function(event){
if(!event.olxieju&&!game.online){
var targets=[];
game.getGlobalHistory('useCard',evt=>{
if(evt.targets&&evt.targets.length){
targets.addArray(evt.targets);
}
})
event.set('olxieju',targets);
}
},
filterTarget:function(card,player,target){
var event=_status.event;
if(event.olxieju.contains(target)) return true;
return false;
},
selectTarget:[1,Infinity],
content:function(){
var card={
name:'sha',
isCard:true,
};
if(target.hasUseTarget(card,true)){
target.chooseUseTarget(card,true);
}
},
ai:{
order:1,
result:{
target:function(player,target){
var val=target.getUseValue({name:'sha'},true);
return Math.sign(val);
}
}
}
},
//郝普
olzhenying:{
audio:2,
@ -22503,6 +22647,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
ruiji:['dc_ruiji','ruiji'],
jsp_huangyueying:['jsp_huangyueying','re_jsp_huangyueying'],
ganfuren:['dc_ganfuren','ganfuren'],
wenqin:['wenqin','pe_wenqin'],
},
translate:{
"xinfu_lingren":"凌人",
@ -23587,6 +23732,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
haopu:'郝普',
olzhenying:'镇荧',
olzhenying_info:'出牌阶段限两次。你可以选择一名手牌数不大于你的其他角色,你与其同时将手牌摸或弃置至至多两张。然后你与其中手牌数较少的角色视为对另一名角色使用一张【决斗】。',
ol_wenqin:'文钦',
olguangao:'犷骜',
olguangao_info:'当你/其他角色使用【杀】时,你/该角色可以额外指定一个目标/你为目标(使用者不为你则有距离限制)。然后若你的手牌数为偶数,你摸一张牌并令此牌对任意目标无效。',
olhuiqi:'彗企',
olhuiqi_info:'觉醒技。一名角色回合结束后,若仅有三名角色于此回合成为过牌的目标,你获得〖偕举〗并获得一个额外的回合。',
olxieju:'偕举',
olxieju_info:'出牌阶段限一次。你可以令任意名本回合成为过牌的目标的角色依次视为使用一张【杀】。',
sp_tianji:'天极·皇室宗亲',
sp_sibi:'四弼·辅国文曲',

View File

@ -4,7 +4,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
name:'xianding',
connect:true,
character:{
dc_duyu:['male','wei',3,['dcjianguo','dcdyqingshi'],['unseen']],
dc_duyu:['male','wei',4,['dcjianguo','dcdyqingshi']],
ganfurenmifuren:['female','shu',3,['dcchanjuan','dcxunbie']],
dc_ganfuren:['female','shu',3,['dcshushen','dcshenzhi']],
dc_mifuren:['female','shu',3,['dcguixiu','dccunsi']],
@ -16,7 +16,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
huanfan:['male','wei',3,['dcjianzheng','dcfumou']],
chentai:['male','wei',4,['dcctjiuxian','dcchenyong']],
sunyu:['male','wu',3,['dcquanshou','dcshexue'],['unseen']],
xizheng:['male','shu',3,['dcdanyi','dcwencan'],['unseen']],
xizheng:['male','shu',3,['dcdanyi','dcwencan']],
dc_ruiji:['female','wu',4,['dcwangyuan','dclingyin','dcliying']],
zerong:['male','qun',4,['dccansi','dcfozong']],
xielingyu:['female','wu',3,['dcyuandi','dcxinyou']],
@ -1556,6 +1556,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
storage:{dcctjiuxian:true}
},true);
},
ai:{
order:5.5,
result:{player:1},
},
subSkill:{
help:{
trigger:{global:'damageSource'},
@ -1827,12 +1831,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
if(!event.targets||!event.targets.length) return false;
var evt=lib.skill.dcjianying.getLastUsed(player,event.getParent());
if(!evt||!evt.targets||!evt.targets.length||evt.targets.length!=event.targets.length) return false;
var targetsx=event.targets.slice().sort((a,b)=>a.seatNum-b.seatNum);
var targetsy=evt.targets.slice().sort((a,b)=>a.seatNum-b.seatNum);
for(var i=0;i<targetsx.length;i++){
if(targetsx[i]!=targetsy[i]) return false;
}
return true;
var targetsx=event.targets.slice();
var targetsy=evt.targets.slice();
return targetsx.slice().removeArray(targetsy).length==0&&targetsy.slice().removeArray(targetsx).length==0;
},
frequent:true,
locked:false,

View File

@ -13329,6 +13329,8 @@
var dialog=info.chooseButton.dialog(event,player);
if(info.chooseButton.chooseControl){
var next=player.chooseControl(info.chooseButton.chooseControl(event,player));
if(dialog.direct) next.direct=true;
if(dialog.forceDirect) next.forceDirect=true;
next.dialog=dialog;
next.set('ai',info.chooseButton.check||function(){return 0;});
if(event.id) next._parent_id=event.id;
@ -13336,6 +13338,8 @@
}
else{
var next=player.chooseButton(dialog);
if(dialog.direct) next.direct=true;
if(dialog.forceDirect) next.forceDirect=true;
next.set('ai',info.chooseButton.check||function(){return 1;});
next.set('filterButton',info.chooseButton.filter||function(){return true;});
next.set('selectButton',info.chooseButton.select||1);
@ -13510,11 +13514,15 @@
var dialog=info.chooseButton.dialog(event,player);
if(info.chooseButton.chooseControl){
var next=player.chooseControl(info.chooseButton.chooseControl(event,player));
if(dialog.direct) next.direct=true;
if(dialog.forceDirect) next.forceDirect=true;
next.dialog=dialog;
next.set('ai',info.chooseButton.check||function(){return 0;});
}
else{
var next=player.chooseButton(dialog);
if(dialog.direct) next.direct=true;
if(dialog.forceDirect) next.forceDirect=true;
next.set('ai',info.chooseButton.check||function(){return 1;});
next.set('filterButton',info.chooseButton.filter||function(){return true;});
next.set('selectButton',info.chooseButton.select||1);
@ -14404,16 +14412,50 @@
event.dialog.style.display='';
event.dialog.open();
}
var filterButton=event.filterButton||function(){return true};
var selectButton=get.select(event.selectButton);
var buttons=event.dialog.buttons;
var buttonsx=[];
var num=0;
for(var i=0;i<buttons.length;i++){
var button=buttons[i];
if(filterButton(button,player)){
num++;
buttonsx.add(button);
}
}
if(event.isMine()){
game.check();
if(event.direct&&num==selectButton[0]||event.forceDirect){
var buttons=buttonsx.slice(0,num);
event.result={
bool:true,
button:[buttons],
links:get.links(buttons),
};
event.dialog.close();
}
else{
game.check();
game.pause();
}
if(event.hsskill&&!event.forced&&_status.prehidden_skills.contains(event.hsskill)){
ui.click.cancel();
return;
}
game.pause();
}
else if(event.isOnline()){
event.send();
if(event.direct&&num==1||event.forceDirect){
var buttons=buttonsx.slice(0,num);
event.result={
bool:true,
button:[buttons],
links:get.links(buttons),
};
event.dialog.close();
}
else{
event.send();
}
delete event.callback;
}
else{
@ -14895,12 +14937,34 @@
}
else{
if(event.seperate||lib.config.seperate_control){
event.controlbars=[];
for(var i=0;i<event.controls.length;i++){
event.controlbars.push(ui.create.control([event.controls[i]]));
var controls=event.controls.slice(0);
var num=0;
controls.remove('cancel2');
if(event.direct&&controls.length==1||event.forceDirect){
event.result={
control:event.controls[0].link,
links:get.links([event.controls[0]]),
};
return;
}
else{
event.controlbars=[];
for(var i=0;i<event.controls.length;i++){
event.controlbars.push(ui.create.control([event.controls[i]]));
}
}
}
else{
var controls=event.controls.slice(0);
var num=0;
controls.remove('cancel2');
if(event.direct&&controls.length==1||event.forceDirect){
event.result={
control:event.controls[0].link,
links:get.links([event.controls[0]]),
};
return;
}
event.controlbar=ui.create.control(event.controls);
}
if(event.dialog){

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

BIN
image/character/dc_duyu.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

BIN
image/character/xizheng.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 25 KiB