This commit is contained in:
Spmario233 2020-10-15 13:41:31 +08:00
parent 9421219f15
commit 843bfcf453
20 changed files with 412 additions and 227 deletions

View File

@ -408,12 +408,14 @@ game.import('card',function(lib,game,ui,get,ai,_status){
subtype:'equip2', subtype:'equip2',
loseDelay:false, loseDelay:false,
onLose:function(){ onLose:function(){
if(player.isDamaged()) player.logSkill('baiyin_skill');
var next=game.createEvent('baiyin_recover'); var next=game.createEvent('baiyin_recover');
event.next.remove(next); event.next.remove(next);
event.getParent().after.push(next); var evt=event.getParent();
if(evt.getlx===false) evt=evt.getParent();
evt.after.push(next);
next.player=player; next.player=player;
next.setContent(function(){ next.setContent(function(){
if(player.isDamaged()) player.logSkill('baiyin_skill');
player.recover(); player.recover();
}); });
}, },

View File

@ -129,11 +129,22 @@ game.import('card',function(lib,game,ui,get,ai,_status){
} }
}, },
filterLose:function(card,player){ filterLose:function(card,player){
if(player.hasSkillTag('unequip2')) return false; if(player.hasSkillTag('unequip2')) return false;
return true; return true;
}, },
loseDelay:false,
onLose:function(){ onLose:function(){
var next=game.createEvent('taipingyaoshu');
event.next.remove(next);
var evt=event.getParent();
if(evt.getlx===false) evt=evt.getParent();
evt.after.push(next);
next.player=player;
next.setContent(lib.card.taipingyaoshu.onLosex);
},
onLosex:function(){
'step 0' 'step 0'
player.logSkill('taipingyaoshu');
player.draw(2); player.draw(2);
'step 1' 'step 1'
if(player.hp>1) player.loseHp(); if(player.hp>1) player.loseHp();

View File

@ -1663,7 +1663,8 @@ game.import('card',function(lib,game,ui,get,ai,_status){
onremove:true, onremove:true,
trigger:{ trigger:{
player:['damage','damageCancelled','damageZero'], player:['damage','damageCancelled','damageZero'],
target:['shaMiss','useCardToExcluded'], target:['shaMiss','useCardToExcluded','shaEnd'],
global:['useCardEnd'],
}, },
charlotte:true, charlotte:true,
filter:function(event,player){ filter:function(event,player){

View File

@ -319,11 +319,9 @@ game.import('card',function(lib,game,ui,get,ai,_status){
filterTarget:lib.filter.notMe, filterTarget:lib.filter.notMe,
selectTarget:1, selectTarget:1,
toself:false, toself:false,
onEquip:function(){ loseThrow:true,
var cards=player.getCards('e',function(cardz){ customSwap:function(){
return cardz!=card; return true;
});
if(cards.length) player.discard(cards);
}, },
ai:{ ai:{
order:9, order:9,
@ -467,9 +465,10 @@ game.import('card',function(lib,game,ui,get,ai,_status){
if(player.sex!='male') return; if(player.sex!='male') return;
var next=game.createEvent('nvzhuang_lose'); var next=game.createEvent('nvzhuang_lose');
event.next.remove(next); event.next.remove(next);
event.getParent().after.push(next); var evt=event.getParent();
if(evt.getlx===false) evt=evt.getParent();
evt.after.push(next);
next.player=player; next.player=player;
next.card=card;
next.setContent(function(){ next.setContent(function(){
if(player.countCards('he')){ if(player.countCards('he')){
player.popup('nvzhuang'); player.popup('nvzhuang');

View File

@ -444,6 +444,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
return ['equip','delay'].contains(get.type(card,false)); return ['equip','delay'].contains(get.type(card,false));
}, },
filterTarget:function(card,player,target){ filterTarget:function(card,player,target){
if(player==target) return false;
var card=ui.selected.cards[0]; var card=ui.selected.cards[0];
if(get.type(card,false)=='delay') return target.canAddJudge({name:card.name}); if(get.type(card,false)=='delay') return target.canAddJudge({name:card.name});
return target.isEmpty(get.subtype(card,false)); return target.isEmpty(get.subtype(card,false));
@ -948,10 +949,15 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}, },
}, },
misuzu_zhongxing:{ misuzu_zhongxing:{
trigger:{player:'loseAfter'}, trigger:{
player:'loseAfter',
source:'gainAfter',
global:['equipAfter','addJudgeAfter'],
},
direct:true, direct:true,
filter:function(event,player){ filter:function(event,player){
return event.js&&event.js.length>0&&!player.hasSkill('misuzu_zhongxing_haruko'); var evt=event.getl(player);
return evt&&evt.js&&evt.js.length>0&&!player.hasSkill('misuzu_zhongxing_haruko');
}, },
content:function(){ content:function(){
'step 0' 'step 0'
@ -979,16 +985,18 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}, },
kamome_yangfan:{ kamome_yangfan:{
trigger:{ trigger:{
global:'gameDrawAfter', player:['loseAfter','enterGame'],
player:['enterGame','loseAfter'], source:'gainAfter',
global:['equipAfter','addJudgeAfter','gameDrawAfter'],
}, },
forced:true, forced:true,
filter:function(event,player){ filter:function(event,player){
if(event.name!='lose') return true; if(typeof event.getl!='function') return true;
return event.es&&event.es.length; var evt=event.getl(player);
return evt&&evt.player==player&&evt.es&&evt.es.length;
}, },
content:function(){ content:function(){
if(trigger.name=='lose') player.draw(2*trigger.es.length); if(trigger.getl) player.draw(2*trigger.getl(player).es.length);
else player.equip(game.createCard2('kamome_suitcase','spade',1)); else player.equip(game.createCard2('kamome_suitcase','spade',1));
}, },
ai:{ ai:{
@ -1469,6 +1477,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}); });
'step 1' 'step 1'
if(result.control=='cancel2'){event.finish();return;} if(result.control=='cancel2'){event.finish();return;}
player.logSkill('shiorimiyuki_tingxian');
var num=1+result.index; var num=1+result.index;
player.draw(num); player.draw(num);
'step 2' 'step 2'

View File

@ -20,6 +20,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
key_shiki:['female','shen','3/5',['shiki_omusubi'],['key']], key_shiki:['female','shen','3/5',['shiki_omusubi'],['key']],
//key_hina:['female','shen',3,[],['key']], //key_hina:['female','shen',3,[],['key']],
//shen_diaochan:['female','shen',3,[],['qun']],
shen_guanyu:['male','shen',5,['new_wuhun','wushen'],['shu']], shen_guanyu:['male','shen',5,['new_wuhun','wushen'],['shu']],
shen_zhaoyun:['male','shen',2,['xinjuejing','relonghun'],['shu']], shen_zhaoyun:['male','shen',2,['xinjuejing','relonghun'],['shu']],
shen_zhugeliang:['male','shen',3,['qixing','kuangfeng','dawu'],['shu']], shen_zhugeliang:['male','shen',3,['qixing','kuangfeng','dawu'],['shu']],
@ -3422,6 +3423,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
qixian_info:'锁定技你的手牌上限视为7。', qixian_info:'锁定技你的手牌上限视为7。',
caopi_xingdong:'行动', caopi_xingdong:'行动',
caopi_xingdong_info:'出牌阶段限一次,你可以将一张【杀】或普通锦囊牌交给一名其他角色,然后该角色选择一项:对除你以外的角色使用此牌并在此牌结算完成后和你各摸一张牌;或跳过下回合的判定阶段和摸牌阶段。', caopi_xingdong_info:'出牌阶段限一次,你可以将一张【杀】或普通锦囊牌交给一名其他角色,然后该角色选择一项:对除你以外的角色使用此牌并在此牌结算完成后和你各摸一张牌;或跳过下回合的判定阶段和摸牌阶段。',
//shen_diaochan:'神貂蝉',
key_kagari:'篝', key_kagari:'篝',
kagari_zongsi:'纵丝', kagari_zongsi:'纵丝',
@ -3429,7 +3431,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
key_shiki:'神山识', key_shiki:'神山识',
shiki_omusubi:'御结', shiki_omusubi:'御结',
shiki_omusubi_info:'一轮游戏开始时你可以减1点体力上限然后将一名其他角色武将牌上的技能加入到你的武将牌上。', shiki_omusubi_info:'一轮游戏开始时你可以减1点体力上限然后将一名其他角色武将牌上的技能加入到你的武将牌上。',
//key_hina:'雏', shiki_omusubi_append:'<span style="font-family: yuanli">来吧,羽依里。用你的手,让我变成那只真正的鬼吧!</span>',
//key_hina:'佐藤雏',
extra_feng:'神话再临·风', extra_feng:'神话再临·风',
extra_huo:'神话再临·火', extra_huo:'神话再临·火',

View File

@ -12,7 +12,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
mobile_standard:["xin_xiahoudun"], mobile_standard:["xin_xiahoudun"],
mobile_shenhua:["re_pangtong","re_guanqiujian","xin_yuanshao","re_liushan","re_dongzhuo","re_sp_zhugeliang","re_sunjian"], mobile_shenhua:["re_pangtong","re_guanqiujian","xin_yuanshao","re_liushan","re_dongzhuo","re_sp_zhugeliang","re_sunjian"],
mobile_yijiang1:["re_jikang","old_bulianshi","xin_liaohua","xin_caozhang","re_xusheng","xin_chengpu"], mobile_yijiang1:["re_jikang","old_bulianshi","xin_liaohua","xin_caozhang","re_xusheng","xin_chengpu"],
mobile_sp:["old_yuanshu","re_wangyun","re_baosanniang","re_weiwenzhugezhi","re_zhanggong","re_xugong","re_heqi","old_liuzan"], mobile_sp:["old_yuanshu","re_wangyun","re_baosanniang","re_weiwenzhugezhi","re_zhanggong","re_xugong","re_heqi","liuzan"],
mobile_trashbin:['old_jiakui'], mobile_trashbin:['old_jiakui'],
}, },
}, },
@ -47,7 +47,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
old_bulianshi:['female','wu',3,['anxu','zhuiyi']], old_bulianshi:['female','wu',3,['anxu','zhuiyi']],
miheng:['male','qun',3,['kuangcai','shejian']], miheng:['male','qun',3,['kuangcai','shejian']],
taoqian:['male','qun',3,['zhaohuo','yixiang','yirang']], taoqian:['male','qun',3,['zhaohuo','yixiang','yirang']],
old_liuzan:['male','wu',4,['fenyin']],lingcao:['male','wu',4,['dujin']], liuzan:['male','wu',4,['fenyin']],lingcao:['male','wu',4,['dujin']],
sunru:['female','wu',3,['yingjian','shixin']], sunru:['female','wu',3,['yingjian','shixin']],
lifeng:['male','shu',3,['tunchu','shuliang']], lifeng:['male','shu',3,['tunchu','shuliang']],
zhuling:['male','wei',4,['xinzhanyi']], zhuling:['male','wei',4,['xinzhanyi']],
@ -178,12 +178,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}, },
loseDelay:false, loseDelay:false,
onLose:function(){ onLose:function(){
player.logSkill('rw_baiyin_skill'); var next=game.createEvent('rewrite_baiyin_recover');
var next=game.createEvent('rw_baiyin_recover');
event.next.remove(next); event.next.remove(next);
event.getParent().after.push(next); var evt=event.getParent();
if(evt.getlx===false) evt=evt.getParent();
evt.after.push(next);
next.player=player; next.player=player;
next.setContent(function(){ next.setContent(function(){
player.logSkill('rw_baiyin_skill');
player.draw(2); player.draw(2);
player.recover(); player.recover();
}); });
@ -5594,7 +5596,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}, },
}, },
translate:{ translate:{
old_liuzan:'手杀留赞', liuzan:'手杀留赞',
re_sp_zhugeliang:"手杀卧龙", re_sp_zhugeliang:"手杀卧龙",
ly_piliche:'霹雳车', ly_piliche:'霹雳车',
ly_piliche_info:'当你对其他角色造成伤害后,若造成伤害的牌不为延时锦囊牌,你可以弃置其装备区里的防具牌与+1坐骑牌当你失去此装备时销毁之。', ly_piliche_info:'当你对其他角色造成伤害后,若造成伤害的牌不为延时锦囊牌,你可以弃置其装备区里的防具牌与+1坐骑牌当你失去此装备时销毁之。',

View File

@ -1107,7 +1107,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
rexuanfeng:{ rexuanfeng:{
audio:'xuanfeng', audio:'xuanfeng',
audioname:['boss_lvbu3','re_heqi','re_lingtong'], audioname:['boss_lvbu3','re_heqi','re_lingtong'],
trigger:{player:['loseAfter','phaseDiscardEnd']}, trigger:{
player:'loseAfter',
source:'gainAfter',
global:['equipAfter','addJudgeAfter'],
},
direct:true, direct:true,
filter:function(event,player){ filter:function(event,player){
if(!game.hasPlayer(function(current){ if(!game.hasPlayer(function(current){
@ -1120,7 +1124,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}); });
return cards.length>1; return cards.length>1;
} }
else return event.es&&event.es.length>0; var evt=event.getl(player);
return evt&&evt.es&&evt.es.length>0;
}, },
content:function(){ content:function(){
'step 0' 'step 0'
@ -5727,16 +5732,21 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}, },
relianying:{ relianying:{
audio:2, audio:2,
trigger:{player:'loseAfter'}, trigger:{
player:'loseAfter',
source:'gainAfter',
global:['equipAfter','addJudgeAfter'],
},
direct:true, direct:true,
filter:function(event,player){ filter:function(event,player){
if(player.countCards('h')) return false; if(player.countCards('h')) return false;
return event.hs&&event.hs.length; var evt=event.getl(player);
return evt&&evt.hs&&evt.hs.length;
}, },
content:function(){ content:function(){
"step 0" "step 0"
var num=trigger.hs.length; var num=trigger.getl(player).hs.length;
player.chooseTarget('选择发动连营的目标',[1,num]).ai=function(target){ player.chooseTarget(get.prompt('relianying'),'令至多'+get.cnNumber(num)+'名角色各摸一张牌',[1,num]).ai=function(target){
var player=_status.event.player; var player=_status.event.player;
if(player==target) return get.attitude(player,target)+10; if(player==target) return get.attitude(player,target)+10;
return get.attitude(player,target); return get.attitude(player,target);

View File

@ -3148,11 +3148,16 @@ game.import('character',function(lib,game,ui,get,ai,_status){
tuntian:{ tuntian:{
audio:2, audio:2,
audioname:['gz_dengai'], audioname:['gz_dengai'],
trigger:{player:'loseAfter'}, trigger:{
player:'loseAfter',
source:'gainAfter',
global:['equipAfter','addJudgeAfter'],
},
frequent:true, frequent:true,
filter:function(event,player){ filter:function(event,player){
if(player==_status.currentPhase) return false; if(player==_status.currentPhase) return false;
return event.cards2&&event.cards2.length>0; var evt=event.getl(player);
return evt&&evt.cards2&&evt.cards2.length>0;
}, },
content:function(){ content:function(){
'step 0' 'step 0'
@ -4912,9 +4917,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
} }
}, },
weimu:{ weimu:{
trigger:{global:'useCard'}, trigger:{global:'useCard1'},
audio:2, audio:2,
forced:true, forced:true,
firstDo:true,
filter:function (event,player,card){ filter:function (event,player,card){
if(get.color(event.card)!='black') return false; if(get.color(event.card)!='black') return false;
return event.card.name=='nanman'&&player!=event.player||event.card.name=='wanjian'&&player!=event.player||event.card.name=='taoyuan'&&player.hp<player.maxHp||event.card.name=='wugu'; return event.card.name=='nanman'&&player!=event.player||event.card.name=='wanjian'&&player!=event.player||event.card.name=='taoyuan'&&player.hp<player.maxHp||event.card.name=='wugu';

View File

@ -5089,7 +5089,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}, },
refuhan:{ refuhan:{
audio:'fuhan', audio:'fuhan',
trigger:{player:'phaseBegin'}, trigger:{player:'phaseZhunbeiBegin'},
unique:true, unique:true,
limited:true, limited:true,
skillAnimation:true, skillAnimation:true,
@ -5128,6 +5128,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
list.remove(players[i].name1); list.remove(players[i].name1);
list.remove(players[i].name2); list.remove(players[i].name2);
} }
list.remove('zhaoyun');
list.remove('re_zhaoyun');
list.remove('ol_zhaoyun');
list=list.randomGets(Math.max(4,game.countPlayer())); list=list.randomGets(Math.max(4,game.countPlayer()));
var skills=[]; var skills=[];
for(var i of list){ for(var i of list){
@ -6111,12 +6114,16 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}, },
hongde:{ hongde:{
audio:2, audio:2,
trigger:{player:['gainAfter','loseAfter']}, trigger:{
player:['loseAfter','gainAfter'],
source:'gainAfter',
global:['equipAfter','addJudgeAfter'],
},
direct:true, direct:true,
filter:function(event,player){ filter:function(event,player){
if(event.name=='lose'&&event.type=='gain'&&event.getParent().player==player) return false; if(event.name=='gain'&&event.player==player) return event.cards&&event.cards.length>1;
if(event.name=='gain') return event.cards&&event.cards.length>1; var evt=event.getl(player);
return event.cards2&&event.cards2.length>1; return evt&&evt.cards2&&evt.cards2.length>1;
}, },
content:function(){ content:function(){
'step 0' 'step 0'
@ -11314,19 +11321,41 @@ game.import('character',function(lib,game,ui,get,ai,_status){
audioname:['liushan'] audioname:['liushan']
}, },
shoucheng:{ shoucheng:{
trigger:{global:'loseAfter'}, trigger:{
global:['equipAfter','addJudgeAfter','loseAfter','gainAfter'],
},
audio:2, audio:2,
check:function(event,player){ direct:true,
return get.attitude(player,event.player)>0;
},
filter:function(event,player){ filter:function(event,player){
if(event.player==player||event.player.isDead()||event.player.countCards('h')) return false; return game.hasPlayer(function(current){
if(_status.currentPhase==event.player) return false; if(current==_status.currentPhase) return false;
return event.hs&&event.hs.length>0; var evt=event.getl(current);
return evt&&evt.hs&&evt.hs.length&&current.countCards('h')==0;
});
}, },
logTarget:'player',
content:function(){ content:function(){
trigger.player.draw(); "step 0"
event.list=game.filterPlayer(function(current){
if(current==_status.currentPhase) return false;
var evt=trigger.getl(current);
return evt&&evt.hs&&evt.hs.length;
}).sortBySeat(_status.currentPhase);
"step 1"
var target=event.list.shift();
event.target=target;
if(target.isAlive()&&target.countCards('h')==0){
player.chooseBool(get.prompt2('shoucheng',target)).set('ai',function(){
return get.attitude(_status.event.player,_status.event.getParent().target)>0;
});
}
else event.goto(3);
"step 2"
if(result.bool){
player.logSkill(event.name,target);
target.draw();
}
"step 3"
if(event.list.length) event.goto(1);
}, },
ai:{ ai:{
threaten:1.3, threaten:1.3,

View File

@ -11,7 +11,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
caobuxing:['male','wu',3,['moying','juanhui'],[]], caobuxing:['male','wu',3,['moying','juanhui'],[]],
//sp_zhangliao:['male','qun',4,['mubing','diaoling']], //sp_zhangliao:['male','qun',4,['mubing','diaoling']],
re_sunluyu:['female','wu',3,['remeibu','remumu']], re_sunluyu:['female','wu',3,['remeibu','remumu']],
liuzan:['male','wu',4,['refenyin','liji']], re_liuzan:['male','wu',4,['refenyin','liji']],
wenyang:['male','wei',5,['xinlvli','choujue']], wenyang:['male','wei',5,['xinlvli','choujue']],
wangshuang:['male','wei',8,['spzhuilie']], wangshuang:['male','wei',8,['spzhuilie']],
huaman:['female','shu',3,['hmmanyi','mansi','souying','zhanyuan']], huaman:['female','shu',3,['hmmanyi','mansi','souying','zhanyuan']],
@ -61,7 +61,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
sp_shengun:["puyuan","guanlu","gexuan","xushao"], sp_shengun:["puyuan","guanlu","gexuan","xushao"],
sp_baigei:['re_panfeng','xingdaorong','caoxing'], sp_baigei:['re_panfeng','xingdaorong','caoxing'],
sp_guandu:["sp_zhanghe","xunchen","sp_shenpei","gaolan","lvkuanglvxiang","chunyuqiong","sp_xuyou"], sp_guandu:["sp_zhanghe","xunchen","sp_shenpei","gaolan","lvkuanglvxiang","chunyuqiong","sp_xuyou"],
sp_decade:['wulan','leitong','huaman','wangshuang','wenyang','liuzan','re_sunluyu','caobuxing','ol_xinxianying','ol_yujin','re_maliang'], sp_decade:['wulan','leitong','huaman','wangshuang','wenyang','re_liuzan','re_sunluyu','caobuxing','ol_xinxianying','ol_yujin','re_maliang'],
} }
}, },
skill:{ skill:{
@ -231,14 +231,22 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}, },
moying:{ moying:{
audio:2, audio:2,
trigger:{player:'loseAfter'}, trigger:{
player:'loseAfter',
source:'gainAfter',
global:['equipAfter','addJudgeAfter'],
},
direct:true, direct:true,
filter:function(event,player){ filter:function(event,player){
return player!=_status.currentPhase&&event.getParent().name!='useCard'&&event.cards2&&event.cards2.length==1&&!player.hasSkill('moying2')&&['equip','trick'].contains(get.type2(event.cards2[0],event.hs.contains(event.cards2[0])?player:false)); if(player==_status.currentPhase||event.getParent().name=='useCard') return false;
var evt=event.getl(player);
return evt&&evt.cards2&&evt.cards2.length==1&&
['equip','trick'].contains(get.type2(evt.cards2[0],(evt.type=='discard'&&evt.hs.contains(evt.cards2[0]))?player:false))&&
!player.hasSkill('moying2');
}, },
content:function(){ content:function(){
"step 0" "step 0"
var number=trigger.cards2[0].number; var number=trigger.getl(player).cards2[0].number;
var numbers=[number-2,number-1,number,number+1,number+2].filter(function(number){ var numbers=[number-2,number-1,number,number+1,number+2].filter(function(number){
return number>=1&&number<=13; return number>=1&&number<=13;
}); });
@ -2594,8 +2602,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
audio:"biaozhao", audio:"biaozhao",
filter:function (event,player){ filter:function (event,player){
if(!player.storage.biaozhao) return false; if(!player.storage.biaozhao) return false;
var evt=event.getParent();
if(evt&&(evt.name=='useCard'||evt.name=='respond'||evt.name=='biaozhao2')) return false;
var suit=get.suit(player.storage.biaozhao[0]); var suit=get.suit(player.storage.biaozhao[0]);
var num=get.number(player.storage.biaozhao[0]); var num=get.number(player.storage.biaozhao[0]);
for(var i=0;i<event.cards.length;i++){ for(var i=0;i<event.cards.length;i++){
@ -4011,11 +4017,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}); });
player.chooseControl(list).set('prompt','秉诏:请选择一个势力').set('ai',function(){ player.chooseControl(list).set('prompt','秉诏:请选择一个势力').set('ai',function(){
var listx=list.slice(0); var listx=list.slice(0);
list.sort(function(a,b){ listx.sort(function(a,b){
return game.countPlayer(function(current){ return game.countPlayer(function(current){
return current.group==b; return current!=player&&current.group==b;
})-game.countPlayer(function(current){ })-game.countPlayer(function(current){
return current.group==a; return current!=player&&current.group==a;
}); });
}) })
return listx[0]; return listx[0];
@ -5523,7 +5529,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
beishui_info:'觉醒技准备阶段若你的手牌数或体力值小于2你减1点体力上限并获得技能〖清剿〗然后将〖膂力〗改为受到伤害后也可以发动。', beishui_info:'觉醒技准备阶段若你的手牌数或体力值小于2你减1点体力上限并获得技能〖清剿〗然后将〖膂力〗改为受到伤害后也可以发动。',
qingjiao:'清剿', qingjiao:'清剿',
qingjiao_info:'出牌阶段开始时,你可以弃置所有手牌,然后从牌堆或弃牌堆中随机获得八张牌名各不相同且副类别不同的牌。若如此做,结束阶段,你弃置所有牌。', qingjiao_info:'出牌阶段开始时,你可以弃置所有手牌,然后从牌堆或弃牌堆中随机获得八张牌名各不相同且副类别不同的牌。若如此做,结束阶段,你弃置所有牌。',
liuzan:'留赞', re_liuzan:'留赞',
refenyin:'奋音', refenyin:'奋音',
refenyin_info:'锁定技,你的回合内,当一张牌进入弃牌堆后,若本回合内没有过与此牌花色相同的卡牌进入过弃牌堆,则你摸一张牌。', refenyin_info:'锁定技,你的回合内,当一张牌进入弃牌堆后,若本回合内没有过与此牌花色相同的卡牌进入过弃牌堆,则你摸一张牌。',
liji:'力激', liji:'力激',

View File

@ -2063,11 +2063,16 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}, },
lianying:{ lianying:{
audio:2, audio:2,
trigger:{player:'loseAfter'}, trigger:{
player:'loseAfter',
source:'gainAfter',
global:['equipAfter','addJudgeAfter'],
},
frequent:true, frequent:true,
filter:function(event,player){ filter:function(event,player){
if(player.countCards('h')) return false; if(player.countCards('h')) return false;
return event.hs&&event.hs.length>0; var evt=event.getl(player);
return evt&&evt.player==player&&evt.hs&&evt.hs.length>0;
}, },
content:function(){ content:function(){
player.draw(); player.draw();
@ -2090,14 +2095,19 @@ game.import('character',function(lib,game,ui,get,ai,_status){
xiaoji:{ xiaoji:{
audio:2, audio:2,
audioname:['sp_sunshangxiang','re_sunshangxiang'], audioname:['sp_sunshangxiang','re_sunshangxiang'],
trigger:{player:'loseAfter'}, trigger:{
player:'loseAfter',
source:'gainAfter',
global:['equipAfter','addJudgeAfter'],
},
frequent:true, frequent:true,
filter:function(event,player){ filter:function(event,player){
return event.es&&event.es.length>0; var evt=event.getl(player);
return evt&&evt.player==player&&evt.es&&evt.es.length>0;
}, },
content:function(){ content:function(){
"step 0" "step 0"
event.count=trigger.es.length; event.count=trigger.getl(player).es.length;
"step 1" "step 1"
event.count--; event.count--;
player.draw(2); player.draw(2);

View File

@ -52,11 +52,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
target.chooseToUse({ target.chooseToUse({
prompt:'请使用得到的一张牌,或者受到来自'+get.translation(player)+'的一点伤害', prompt:'请使用得到的一张牌,或者受到来自'+get.translation(player)+'的一点伤害',
filterCard:function(card,player,event){ filterCard:function(card,player,event){
var cards=_status.event.cards; if(get.itemtype(card)!='card'||!cards.contains(card)) return false;
if(!cards||get.itemtype(card)!='card'||!cards.contains(card)) return false;
return lib.filter.filterCard(card,player,event); return lib.filter.filterCard(card,player,event);
}, },
cards:event.cards,
}); });
'step 2' 'step 2'
if(result.bool){ if(result.bool){
@ -521,10 +519,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}, },
content:function(){ content:function(){
'step 0' 'step 0'
var list=[]; var list=lib.group.filter(function(group){
game.countPlayer(function(current){ return group!=player.group&&game.hasPlayer(function(current){
if(current.group!=player.group&&current.group!='shen') list.add(current.group); return current.group==group;
}); });
})
if(!event.renshe) list.push('cancel2'); if(!event.renshe) list.push('cancel2');
player.chooseControl(list).set('prompt',event.renshe?'请选择一个势力':get.prompt('chijie')).set('prompt2',event.renshe?'':'将自己的势力变更为场上存在的一个势力').set('',function(){ player.chooseControl(list).set('prompt',event.renshe?'请选择一个势力':get.prompt('chijie')).set('prompt2',event.renshe?'':'将自己的势力变更为场上存在的一个势力').set('',function(){
return list.randomGet(); return list.randomGet();

View File

@ -215,28 +215,28 @@ game.import('character',function(lib,game,ui,get,ai,_status){
result:{ result:{
target:function (player,target){ target:function (player,target){
var raweffect=function(player,target){ var raweffect=function(player,target){
if(player.countCards('h','sha')){ if(player.countCards('h','sha')){
return get.effect(target,{name:'sha'},player,target); return get.effect(target,{name:'sha'},player,target);
} }
else{ else{
var att=get.attitude(player,target); var att=get.attitude(player,target);
var nh=target.countCards('h'); var nh=target.countCards('h');
if(att>0){ if(att>0){
if(target.getEquip('baiyin')&&target.isDamaged()&& if(target.getEquip('baiyin')&&target.isDamaged()&&
get.recoverEffect(target,player,player)>0){ get.recoverEffect(target,player,player)>0){
if(target.hp==1&&!target.hujia) return 1.6; if(target.hp==1&&!target.hujia) return 1.6;
if(target.hp==2) return 0.01; if(target.hp==2) return 0.01;
return 0; return 0;
} }
} }
var es=target.getCards('e'); var es=target.getCards('e');
var noe=(es.length==0||target.hasSkillTag('noe')); var noe=(es.length==0||target.hasSkillTag('noe'));
var noe2=(es.length==1&&es[0].name=='baiyin'&&target.isDamaged()); var noe2=(es.length==1&&es[0].name=='baiyin'&&target.isDamaged());
var noh=(nh==0||target.hasSkillTag('noh')); var noh=(nh==0||target.hasSkillTag('noh'));
if(noh&&(noe||noe2)) return 0; if(noh&&(noe||noe2)) return 0;
if(att<=0&&!target.countCards('he')) return 1.5; if(att<=0&&!target.countCards('he')) return 1.5;
return -1.5; return -1.5;
} }
} }
var num=game.countPlayer(function(current){ var num=game.countPlayer(function(current){
return current!=player&&current.hp==target.hp&&(raweffect(player,current)*get.attitude(player,current))>0 return current!=player&&current.hp==target.hp&&(raweffect(player,current)*get.attitude(player,current))>0
@ -421,33 +421,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
} }
}, },
}, },
"qinguo_use":{
audio:2,
trigger:{
player:"equipEnd",
},
filter:function (event,player){
if(!event.swapped&&player.countCards('e')==player.hp&&player.isDamaged()){
return true;
};
return false;
},
frequent:true,
content:function (){
player.recover();
},
ai:{
reverseEquip:true,
effect:{
target:function (card,player,target,current){
if(get.type(card)=='equip'&&player==target&&player==_status.currentPhase) return [1,3];
},
},
},
},
"xinfu_qinguo":{ "xinfu_qinguo":{
group:["qinguo_use","qinguo_lose"], group:"xinfu_qinguo_recover",
audio:2, audio:2,
subfrequent:['recover'],
trigger:{ trigger:{
player:"useCardEnd", player:"useCardEnd",
}, },
@ -455,23 +432,29 @@ game.import('character',function(lib,game,ui,get,ai,_status){
return get.type(event.card)=='equip'; return get.type(event.card)=='equip';
}, },
direct:true, direct:true,
content:function (){ content:function(){
player.chooseUseTarget({name:'sha'},get.prompt('xinfu_qinguo'),'视为使用一张【杀】',false).logSkill='qinguo_use'; player.chooseUseTarget({name:'sha'},get.prompt('xinfu_qinguo'),'视为使用一张【杀】',false).logSkill='qinguo_use';
}, },
}, subSkill:{
"qinguo_lose":{ recover:{
audio:2, audio:'xinfu_qinguo',
trigger:{ trigger:{
player:"loseAfter", player:'loseAfter',
}, source:'gainAfter',
filter:function (event,player){ global:['equipAfter','addJudgeAfter'],
if(event.getParent().name=='equip') return false; },
if(player.hp!=player.countCards('e')||!player.isDamaged()) return false; prompt:'是否发动【勤国】回复1点体力',
return event.es&&event.es.length>0; filter:function (event,player){
}, if(player.isHealthy()||player.countCards('e')!=player.hp) return false;
frequent:true, var evt=event.getl(player);
content:function (){ if(event.name=='equip') return !evt||evt.cards.length!=1;
player.recover(); return evt&&evt.es.length;
},
frequent:true,
content:function(){
player.recover();
},
},
}, },
}, },
"xinfu_jijun":{ "xinfu_jijun":{
@ -930,13 +913,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
sub:true, sub:true,
mod:{ mod:{
ignoredHandcard:function (card,player){ ignoredHandcard:function (card,player){
if(get.suit(card)=='heart'){ if(get.suit(card)=='heart'){
return true; return true;
} }
}, },
cardDiscardable:function (card,player,name){ cardDiscardable:function (card,player,name){
if(name=='phaseDiscard'&&get.suit(card)=='heart') return false; if(name=='phaseDiscard'&&get.suit(card)=='heart') return false;
}, },
}, },
}, },
}, },
@ -1174,17 +1157,17 @@ game.import('character',function(lib,game,ui,get,ai,_status){
aiOrder:function(player,card,num){ aiOrder:function(player,card,num){
if(typeof card.number!='number') return; if(typeof card.number!='number') return;
var history=player.getHistory('useCard',function(evt){ var history=player.getHistory('useCard',function(evt){
return evt.isPhaseUsing(); return evt.isPhaseUsing();
}); });
if(history.length==0) return num+10*(14-card.number); if(history.length==0) return num+10*(14-card.number);
var num=get.number(history[0].card); var num=get.number(history[0].card);
if(!num) return; if(!num) return;
for(var i=1;i<history.length;i++){ for(var i=1;i<history.length;i++){
var num2=get.number(history[i].card); var num2=get.number(history[i].card);
if(!num2||num2<=num) return; if(!num2||num2<=num) return;
num=num2; num=num2;
} }
if(card.number>num) return num+10*(14-card.number); if(card.number>num) return num+10*(14-card.number);
}, },
}, },
filter:function (event,player){ filter:function (event,player){
@ -1227,17 +1210,17 @@ game.import('character',function(lib,game,ui,get,ai,_status){
aiOrder:function(player,card,num){ aiOrder:function(player,card,num){
if(typeof card.number!='number') return; if(typeof card.number!='number') return;
var history=player.getHistory('useCard',function(evt){ var history=player.getHistory('useCard',function(evt){
return evt.isPhaseUsing(); return evt.isPhaseUsing();
}); });
if(history.length==0) return num+10*card.number; if(history.length==0) return num+10*card.number;
var num=get.number(history[0].card); var num=get.number(history[0].card);
if(!num) return; if(!num) return;
for(var i=1;i<history.length;i++){ for(var i=1;i<history.length;i++){
var num2=get.number(history[i].card); var num2=get.number(history[i].card);
if(!num2||num2>=num) return; if(!num2||num2>=num) return;
num=num2; num=num2;
} }
if(card.number<num) return num+10*card.number; if(card.number<num) return num+10*card.number;
}, },
}, },
filter:function (event,player){ filter:function (event,player){
@ -1493,14 +1476,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
check:function(card){ check:function(card){
var player=_status.event.player; var player=_status.event.player;
if(!player.getEquip('zhangba')&&player.countCards('h','sha')<2){ if(!player.getEquip('zhangba')&&player.countCards('h','sha')<2){
if(player.countCards('h',function(cardx){ if(player.countCards('h',function(cardx){
return cardx!=card&&cardx.name=='shan'; return cardx!=card&&cardx.name=='shan';
})>0) return 0; })>0) return 0;
var damaged=player.maxHp-player.hp-1; var damaged=player.maxHp-player.hp-1;
var ts=player.countCards('h',function(cardx){ var ts=player.countCards('h',function(cardx){
return cardx!=card&&cardx.name=='tao'; return cardx!=card&&cardx.name=='tao';
}); });
if(ts>0&&ts>damaged) return 0; if(ts>0&&ts>damaged) return 0;
} }
if(card.name=='shan') return 15; if(card.name=='shan') return 15;
if(card.name=='tao') return 10; if(card.name=='tao') return 10;

View File

@ -239,13 +239,18 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}, },
reshangshi:{ reshangshi:{
audio:'shangshi', audio:'shangshi',
trigger:{player:['loseAfter','changeHp']}, trigger:{
player:['loseAfter','changeHp','gainMaxHpAfter','loseMaxHpAfter'],
source:'gainAfter',
global:['equipAfter','addJudgeAfter'],
},
frequent:true, frequent:true,
prompt:function(event,player){ prompt:function(event,player){
return '是否发动【伤逝】将手牌摸至'+get.cnNumber(player.getDamagedHp())+'张?' return '是否发动【伤逝】将手牌摸至'+get.cnNumber(player.getDamagedHp())+'张?'
}, },
prompt2:false, prompt2:false,
filter:function(event,player){ filter:function(event,player){
if(event.getl&&!event.getl(player)) return false;
return player.countCards('h')<player.getDamagedHp(); return player.countCards('h')<player.getDamagedHp();
}, },
content:function(){ content:function(){
@ -8433,6 +8438,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
audio:'zhiman', audio:'zhiman',
audioname:['guansuo','re_masu'], audioname:['guansuo','re_masu'],
trigger:{source:'damageBegin2'}, trigger:{source:'damageBegin2'},
filter:function(event,player){
return player!=event.player;
},
check:function(event,player){ check:function(event,player){
if(get.damageEffect(event.player,player,player)<0) return true; if(get.damageEffect(event.player,player,player)<0) return true;
var att=get.attitude(player,event.player); var att=get.attitude(player,event.player);
@ -10837,7 +10845,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
xuanfeng:{ xuanfeng:{
audio:2, audio:2,
audioname:['boss_lvbu3','re_heqi'], audioname:['boss_lvbu3','re_heqi'],
trigger:{player:['loseAfter','phaseDiscardEnd']}, trigger:{
player:['loseAfter','phaseDiscardEnd'],
source:'gainAfter',
global:['equipAfter','addJudgeAfter'],
},
direct:true, direct:true,
filter:function(event,player){ filter:function(event,player){
if(event.name=='phaseDiscard'){ if(event.name=='phaseDiscard'){
@ -10847,7 +10859,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}); });
return cards.length>1; return cards.length>1;
} }
else return event.es&&event.es.length>0; else{
var evt=event.getl(player);
return evt&&evt.es&&evt.es.length>0;
}
}, },
content:function(){ content:function(){
"step 0" "step 0"

View File

@ -1,5 +1,5 @@
window.noname_asset_list=[ window.noname_asset_list=[
'v1.9.105.2', 'v1.9.105.3',
'audio/background/aozhan_chaoming.mp3', 'audio/background/aozhan_chaoming.mp3',
'audio/background/aozhan_online.mp3', 'audio/background/aozhan_online.mp3',
'audio/background/aozhan_rewrite.mp3', 'audio/background/aozhan_rewrite.mp3',
@ -3292,7 +3292,7 @@ window.noname_asset_list=[
'image/character/key_doruji.jpg', 'image/character/key_doruji.jpg',
'image/character/key_riki.jpg', 'image/character/key_riki.jpg',
'image/character/key_yuiko.jpg', 'image/character/key_yuiko.jpg',
'image/character/old_liuzan.jpg', 'image/character/re_liuzan.jpg',
'image/character/re_caozhang.jpg', 'image/character/re_caozhang.jpg',
'image/character/re_chengpu.jpg', 'image/character/re_chengpu.jpg',
'image/character/re_guohuai.jpg', 'image/character/re_guohuai.jpg',

View File

@ -11974,12 +11974,12 @@
event.result.num2[event.iwhile]=event.num2; event.result.num2[event.iwhile]=event.num2;
var str; var str;
if(event.num1>event.num2){ if(event.num1>event.num2){
str=get.translation(player.name)+'拼点成功'; str=get.translation(player)+'拼点成功';
player.popup('胜'); player.popup('胜');
target.popup('负'); target.popup('负');
} }
else{ else{
str=get.translation(player.name)+'拼点失败'; str=get.translation(player)+'拼点失败';
if(event.num1==event.num2){ if(event.num1==event.num2){
player.popup('平'); player.popup('平');
target.popup('平'); target.popup('平');
@ -12139,13 +12139,13 @@
if(event.num1>event.num2){ if(event.num1>event.num2){
event.result.bool=true; event.result.bool=true;
event.result.winner=player; event.result.winner=player;
str=get.translation(player.name)+'拼点成功'; str=get.translation(player)+'拼点成功';
player.popup('胜'); player.popup('胜');
target.popup('负'); target.popup('负');
} }
else{ else{
event.result.bool=false; event.result.bool=false;
str=get.translation(player.name)+'拼点失败'; str=get.translation(player)+'拼点失败';
if(event.num1==event.num2){ if(event.num1==event.num2){
event.result.tie=true; event.result.tie=true;
player.popup('平'); player.popup('平');
@ -14447,7 +14447,7 @@
if(cards){ if(cards){
var owner=event.source||get.owner(cards[0]); var owner=event.source||get.owner(cards[0]);
if(owner){ if(owner){
var next=owner.lose(cards,ui.special).set('type','gain').set('forceDie',true); var next=owner.lose(cards,ui.special).set('type','gain').set('forceDie',true).set('getlx',false);
if(event.animate=='give'||event.visible==true) next.visible=true; if(event.animate=='give'||event.visible==true) next.visible=true;
event.relatedLose=next; event.relatedLose=next;
} }
@ -15226,7 +15226,7 @@
equip:function(){ equip:function(){
"step 0" "step 0"
var owner=get.owner(card) var owner=get.owner(card)
if(owner) owner.lose(card,ui.special,'visible').set('type','equip'); if(owner) owner.lose(card,ui.special,'visible').set('type','equip').set('getlx',false);
"step 1" "step 1"
if(event.cancelled){ if(event.cancelled){
event.finish(); event.finish();
@ -15257,9 +15257,16 @@
} }
player.equiping=true; player.equiping=true;
"step 3" "step 3"
var current=player.getCards('e',{subtype:get.subtype(card)}); var info=get.info(card,false);
var current=player.getCards('e',function(card){
if(info.customSwap) return info.customSwap(card);
return get.subtype(card,false)==info.subtype;
});
if(current.length){ if(current.length){
player.lose(current,false,'visible'); player.lose(current,false,'visible').set('type','equip').set('getlx',false);
if(info.loseThrow){
player.$throw(current);
}
event.swapped=true; event.swapped=true;
event.redo(); event.redo();
} }
@ -15310,7 +15317,7 @@
if(cards){ if(cards){
var owner=get.owner(cards[0]); var owner=get.owner(cards[0]);
if(owner){ if(owner){
owner.lose(cards,'visible'); event.relatedLose=owner.lose(cards,'visible').set('getlx',false);
} }
} }
"step 1" "step 1"
@ -18728,6 +18735,27 @@
} }
} }
next.setContent('gain'); next.setContent('gain');
next.getl=function(player){
var that=this;
var map={
player:player,
hs:[],
es:[],
js:[],
cards:[],
cards2:[],
};
player.getHistory('lose',function(evt){
if(evt.parent==that){
map.hs.addArray(evt.hs);
map.es.addArray(evt.es);
map.js.addArray(evt.js);
map.cards.addArray(evt.cards);
map.cards2.addArray(evt.cards2);
}
});
if(map.cards.length>0) return map;
};
return next; return next;
}, },
give:function(cards,target,visible){ give:function(cards,target,visible){
@ -18774,6 +18802,9 @@
next.cards=next.cards.slice(0); next.cards=next.cards.slice(0);
} }
next.setContent('lose'); next.setContent('lose');
next.getl=function(player){
if(this.getlx!==false&&this.player==player) return this;
};
return next; return next;
}, },
damage:function(){ damage:function(){
@ -19130,6 +19161,28 @@
} }
next.setContent(lib.element.content.equip); next.setContent(lib.element.content.equip);
if(get.is.object(next.card)&&next.card.cards) next.card=next.card.cards[0]; if(get.is.object(next.card)&&next.card.cards) next.card=next.card.cards[0];
next.cards=[next.card];
next.getl=function(player){
var that=this;
var map={
player:player,
hs:[],
es:[],
js:[],
cards:[],
cards2:[],
};
player.getHistory('lose',function(evt){
if(evt.parent==that){
map.hs.addArray(evt.hs);
map.es.addArray(evt.es);
map.js.addArray(evt.js);
map.cards.addArray(evt.cards);
map.cards2.addArray(evt.cards2);
}
});
if(map.cards.length>0) return map;
};
return next; return next;
}, },
addJudge:function(card,cards){ addJudge:function(card,cards){
@ -19140,6 +19193,27 @@
if(get.itemtype(next.cards)=='card') next.cards=[next.cards]; if(get.itemtype(next.cards)=='card') next.cards=[next.cards];
next.player=this; next.player=this;
next.setContent('addJudge'); next.setContent('addJudge');
next.getl=function(player){
var that=this;
var map={
player:player,
hs:[],
es:[],
js:[],
cards:[],
cards2:[],
};
player.getHistory('lose',function(evt){
if(evt.parent==that){
map.hs.addArray(evt.hs);
map.es.addArray(evt.es);
map.js.addArray(evt.js);
map.cards.addArray(evt.cards);
map.cards2.addArray(evt.cards2);
}
});
if(map.cards.length>0) return map;
};
return next; return next;
}, },
canAddJudge:function(card){ canAddJudge:function(card){

View File

@ -1,50 +1,51 @@
window.noname_update={ window.noname_update={
version:'1.9.105.2', version:'1.9.105.3',
update:'1.9.105.1', update:'1.9.105.2',
changeLog:[ changeLog:[
'庆祝《成神之日》开播!联机服务器全新升级!', '新留赞插画',
'getl机制',
'bug修复', 'bug修复',
], ],
files:[ files:[
//'card/extra.js', 'card/extra.js',
//'card/huanlekapai.js', //'card/huanlekapai.js',
//'card/sp.js', //'card/sp.js',
//'card/standard.js', 'card/standard.js',
//'card/swd.js', //'card/swd.js',
//'card/mtg.js', //'card/mtg.js',
//'card/gujian.js', //'card/gujian.js',
//'card/guozhan.js', 'card/guozhan.js',
//'card/gwent.js', //'card/gwent.js',
//'card/yunchou.js', //'card/yunchou.js',
//'card/zhenfa.js', //'card/zhenfa.js',
//'card/zhulu.js', 'card/zhulu.js',
//'character/diy.js', 'character/diy.js',
//'character/extra.js', 'character/extra.js',
//'character/hearth.js', //'character/hearth.js',
//'character/gujian.js', //'character/gujian.js',
//'character/gwent.js', //'character/gwent.js',
//'character/hearth.js', //'character/hearth.js',
//'character/mobile.js', 'character/mobile.js',
//'character/mtg.js', //'character/mtg.js',
//'character/old.js', //'character/old.js',
//'character/refresh.js', 'character/refresh.js',
//'character/shenhua.js', 'character/shenhua.js',
'character/sp.js', 'character/sp.js',
'character/sp2.js', 'character/sp2.js',
//'character/tw.js', 'character/tw.js',
//'character/standard.js', 'character/standard.js',
//'character/swd.js', //'character/swd.js',
//'character/xianjian.js', //'character/xianjian.js',
//'character/xinghuoliaoyuan.js', 'character/xinghuoliaoyuan.js',
///'character/yijiang.js', 'character/yijiang.js',
//'character/yxs.js', //'character/yxs.js',
//'extension/boss/extension.js', //'extension/boss/extension.js',
//'layout/default/layout.css', //'layout/default/layout.css',
//'layout/nova/layout.css', //'layout/nova/layout.css',
//'mode/identity.js', //'mode/identity.js',
//'mode/doudizhu.js', //'mode/doudizhu.js',
//'mode/guozhan.js', 'mode/guozhan.js',
//'mode/chess.js', //'mode/chess.js',
//'mode/tafang.js', //'mode/tafang.js',
//'mode/single.js', //'mode/single.js',
@ -53,8 +54,8 @@ window.noname_update={
//'mode/versus.js', //'mode/versus.js',
//'mode/boss.js', //'mode/boss.js',
'game/game.js', 'game/game.js',
'game/keyWords.js', //'game/keyWords.js',
'game/server.js', //'game/server.js',
//'game/NoSleep.js', //'game/NoSleep.js',
//'game/config.js', //'game/config.js',
//'game/package.js', //'game/package.js',

Binary file not shown.

After

Width:  |  Height:  |  Size: 54 KiB

View File

@ -829,28 +829,26 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
}, },
xindiaodu:{ xindiaodu:{
audio:"diaodu", audio:"diaodu",
global:"xindiaodu_use", group:'xindiaodu_use',
subfrequent:['use'],
subSkill:{ subSkill:{
use:{ use:{
trigger:{ trigger:{
player:"useCard", player:"useCard",
}, },
popup:false,
frequent:true,
prompt:'是否发动【调度】摸一张牌?',
filter:function (event,player){ filter:function (event,player){
return get.type(event.card)=='equip'&&game.hasPlayer(function(current){ return get.type(event.card)=='equip'&&event.player.isAlive()&&
return current.hasSkill('xindiaodu')&&current.isFriendOf(player); event.player.isFriendOf(player)&&(player==event.player||player.hasSkill('xindiaodu'));
});
}, },
content:function (){ direct:true,
var logger=game.findPlayer(function(current){ content:function(){
return current.isFriendOf(player)&&current.hasSkill('xindiaodu'); 'step 0'
}); var next=trigger.player.chooseBool('是否发动【调度】摸一张牌?');
logger.line(player,'green'); if(player.hasSkill('xindiaodu')) next.set('frequentSkill','xindiaodu');
logger.logSkill('xindiaodu'); 'step 1'
player.draw('nodelay'); if(result.bool){
player.logSkill('xindiaodu',trigger.player);
trigger.player.draw('nodelay');
}
}, },
ai:{ ai:{
reverseEquip:true, reverseEquip:true,
@ -900,7 +898,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
} }
else event.finish(); else event.finish();
'step 2' 'step 2'
if(result.bool){ if(result.bool&&player.getCards('h').contains(result.cards[0])){
event.card=result.cards[0]; event.card=result.cards[0];
player.chooseTarget('是否将'+get.translation(event.card)+'交给一名其他角色?',function(card,player,current){ player.chooseTarget('是否将'+get.translation(event.card)+'交给一名其他角色?',function(card,player,current){
return current!=player&&current!=_status.event.target1&&current.isFriendOf(player); return current!=player&&current!=_status.event.target1&&current.isFriendOf(player);
@ -4090,10 +4088,15 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
} }
}, },
xuanlve:{ xuanlve:{
trigger:{player:'loseAfter'}, trigger:{
player:'loseAfter',
source:'gainAfter',
global:['equipAfter','addJudgeAfter'],
},
direct:true, direct:true,
filter:function(event,player){ filter:function(event,player){
return event.es&&event.es.length>0; var evt=event.getl(player);
return evt&&evt.es&&evt.es.length>0;
}, },
content:function(){ content:function(){
'step 0' 'step 0'
@ -5495,13 +5498,35 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
inherit:'shoucheng', inherit:'shoucheng',
audio:'shoucheng', audio:'shoucheng',
filter:function(event,player){ filter:function(event,player){
if(event.player.isDead()||event.player.countCards('h')) return false; return game.hasPlayer(function(current){
if(!event.player.isFriendOf(player)) return false; if(current==_status.currentPhase||!current.isFriendOf(player)) return false;
if(_status.currentPhase==event.player) return false; var evt=event.getl(current);
for(var i=0;i<event.cards.length;i++){ return evt&&evt.hs&&evt.hs.length&&current.countCards('h')==0;
if(event.cards[i].original=='h') return true; });
},
content:function(){
"step 0"
event.list=game.filterPlayer(function(current){
if(current==_status.currentPhase||!current.isFriendOf(player)) return false;
var evt=trigger.getl(current);
return evt&&evt.hs&&evt.hs.length;
}).sortBySeat(_status.currentPhase);
"step 1"
var target=event.list.shift();
event.target=target;
if(target.isAlive()&&target.countCards('h')==0){
player.chooseBool(get.prompt2('gzshoucheng',target)).set('ai',function(){
return get.attitude(_status.event.player,_status.event.getParent().target)>0;
});
} }
return false; else event.goto(3);
"step 2"
if(result.bool){
player.logSkill(event.name,target);
target.draw();
}
"step 3"
if(event.list.length) event.goto(1);
}, },
}, },
yicheng:{ yicheng:{