v1.9.113
This commit is contained in:
parent
aae7f6834d
commit
f8b4a621a2
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -14,17 +14,14 @@ game.import('card',function(lib,game,ui,get,ai,_status){
|
|||
content:function(){
|
||||
cards=cards.filterInD();
|
||||
if(cards.length&&target.isAlive()){
|
||||
game.cardsGotoSpecial(cards);
|
||||
game.log(cards,'被移出了游戏');
|
||||
player.$gain2(cards,false);
|
||||
target.markAuto('zhaoshu_skill',cards);
|
||||
target.addToExpansion(cards,'gain2').gaintag.add('zhaoshu_skill');
|
||||
target.addSkill('zhaoshu_skill');
|
||||
game.addGlobalSkill('zhaoshu_global');
|
||||
}
|
||||
},
|
||||
onEquip:function(){
|
||||
if(player.isAlive()){
|
||||
player.lose(card)._triggered=null;
|
||||
player.addToExpansion(card,'giveAuto').gaintag.add('zhaoshu_skill');
|
||||
player.markAuto('zhaoshu_skill',[card]);
|
||||
player.addSkill('zhaoshu_skill');
|
||||
game.addGlobalSkill('zhaoshu_global');
|
||||
|
@ -1112,7 +1109,7 @@ game.import('card',function(lib,game,ui,get,ai,_status){
|
|||
enable:'phaseUse',
|
||||
usable:1,
|
||||
filter:function(event,player){
|
||||
var cards=player.getStorage('zhaoshu_cards');
|
||||
var cards=player.getExpansions('zhaoshu_cards');
|
||||
if(cards.length<4) return false;
|
||||
var list=[];
|
||||
for(var i of cards){
|
||||
|
@ -1124,12 +1121,8 @@ game.import('card',function(lib,game,ui,get,ai,_status){
|
|||
delay:false,
|
||||
content:function(){
|
||||
'step 0'
|
||||
var cards=player.getStorage('zhaoshu_cards');
|
||||
game.cardsDiscard(cards);
|
||||
player.$throw(cards);
|
||||
game.log(player,'移去了',cards);
|
||||
cards.length=0;
|
||||
player.markSkill('zhaoshu_cards');
|
||||
var cards=player.getExpansions('zhaoshu_cards');
|
||||
player.loseToDiscardpile(cards);
|
||||
game.delayx();
|
||||
'step 1'
|
||||
var list=[
|
||||
|
@ -1158,25 +1151,19 @@ game.import('card',function(lib,game,ui,get,ai,_status){
|
|||
mark:function(dialog,content,player){
|
||||
dialog.add(content);
|
||||
dialog.addText('<br><li>与你势力相同的角色的出牌阶段限一次,其可以将一张手牌(小势力角色改为至多两张)置于【诏书】上,称为“应”。<br><li>出牌阶段限一次,若你的“应”中包含至少四种花色,则你可以发动“锦囊召唤”,将所有“应”置入弃牌堆,然后随机获得一张未加入游戏的势力锦囊牌。',false);
|
||||
if(player.storage.zhaoshu_cards&&player.storage.zhaoshu_cards.length){
|
||||
dialog.addAuto(player.storage.zhaoshu_cards)
|
||||
}
|
||||
},
|
||||
content:'cards',
|
||||
markcount:function(content,player){
|
||||
return player.getStorage('zhaoshu_cards').length;
|
||||
},
|
||||
onunmark:function(storage,player){
|
||||
var cards=player.getStorage('zhaoshu_skill').concat(player.getStorage('zhaoshu_cards'));
|
||||
var cards=player.getExpansions('zhaoshu_cards');
|
||||
if(cards.length){
|
||||
game.log(cards,'进入了弃牌堆');
|
||||
game.cardsDiscard(cards);
|
||||
player.$throw(cards,1000);
|
||||
dialog.addAuto(cards)
|
||||
}
|
||||
delete player.storage.zhaoshu_skill;
|
||||
delete player.storage.zhaoshu_cards;
|
||||
player.removeSkill('zhaoshu_skill');
|
||||
},
|
||||
content:'expansion',
|
||||
markcount:function(content,player){
|
||||
return player.getExpansions('zhaoshu_cards').length;
|
||||
},
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill).concat(player.getExpansions('zhaoshu_cards'));
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
},
|
||||
zhaoshu_global:{
|
||||
|
@ -1195,11 +1182,12 @@ game.import('card',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
position:'h',
|
||||
discard:false,
|
||||
toStorage:true,
|
||||
lose:false,
|
||||
delay:false,
|
||||
check:function(card){
|
||||
var player=_status.event.player,cards=ui.selected.cards.concat(game.findPlayer(function(current){
|
||||
return current.hasSkill('zhaoshu_skill')&¤t.isFriendOf(player);
|
||||
}).getStorage('zhaoshu_cards')),suit=get.suit(card,false);
|
||||
}).getExpansions('zhaoshu_cards')),suit=get.suit(card,false);
|
||||
for(var i of cards){
|
||||
if(get.suit(i)==suit) return 0;
|
||||
}
|
||||
|
@ -1220,14 +1208,9 @@ game.import('card',function(lib,game,ui,get,ai,_status){
|
|||
return current.hasSkill('zhaoshu_skill')&¤t.isFriendOf(player);
|
||||
}))+'的【诏书】上';
|
||||
},
|
||||
prepare:function(cards,player,targets){
|
||||
var target=targets[0]
|
||||
player.$give(cards,target,false);
|
||||
game.log(player,'将',cards,'放在了',target,'的',target.getStorage('zhaoshu_skill'),'上');
|
||||
target.markAuto('zhaoshu_cards',cards);
|
||||
target.markSkill('zhaoshu_skill');
|
||||
content:function(){
|
||||
target.addToExpansion(cards,player,'give').gaintag.add('zhaoshu_cards');
|
||||
},
|
||||
content:function(){},
|
||||
ai:{
|
||||
order:1,
|
||||
result:{
|
||||
|
@ -1509,7 +1492,7 @@ game.import('card',function(lib,game,ui,get,ai,_status){
|
|||
maxHandcard:function(player,num){
|
||||
if(get.mode()=='guozhan'){
|
||||
if(player.hasSkill('huangjintianbingfu')){
|
||||
num+=player.storage.huangjintianbingfu.length;
|
||||
num+=player.getExpansions('huangjintianbingfu').length;
|
||||
}
|
||||
return num+game.countPlayer(function(current){
|
||||
return current.isFriendOf(player);
|
||||
|
|
|
@ -443,7 +443,7 @@ game.import('card',function(lib,game,ui,get,ai,_status){
|
|||
g_du:{
|
||||
trigger:{
|
||||
player:['loseAfter','compare'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
target:'compare',
|
||||
},
|
||||
cardSkill:true,
|
||||
|
|
220
character/diy.js
220
character/diy.js
|
@ -1126,27 +1126,30 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 2'
|
||||
if(result.bool){
|
||||
var cards=result.cards;
|
||||
player.lose(cards,ui.special,'toStorage');
|
||||
player.markAuto('tenzen_yixing',cards);
|
||||
game.log(player,'将',cards,'放在了武将牌上');
|
||||
player.addToExpansion(cards,player,'give').gaintag.add('tenzen_yixing');
|
||||
}
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
content:'expansion',
|
||||
onunmark:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
group:'tenzen_yixing_counter',
|
||||
subSkill:{
|
||||
counter:{
|
||||
trigger:{target:'useCardToTargeted'},
|
||||
filter:function(event,player){
|
||||
if(player==event.player||!player.getStorage('tenzen_yixing').length) return false;
|
||||
if(player==event.player||!player.getExpansions('tenzen_yixing').length) return false;
|
||||
return event.targets.length==1&&(event.card.name=='sha'||get.type(event.card)=='trick');
|
||||
},
|
||||
prompt2:function(event){
|
||||
return '获得一张“兴”,且'+get.translation(event.card)+'结算完成后可以弃置两张牌,视为对'+get.translation(event.player)+'使用一张同名牌';
|
||||
},
|
||||
check:function(event,player){
|
||||
if(!player.storage.tenzen_lingyu&&player.getStorage('tenzen_yixing').length<3) return false;
|
||||
if(!player.storage.tenzen_lingyu&&player.getExpansions('tenzen_yixing').length<3) return false;
|
||||
var card={
|
||||
name:event.card.name,
|
||||
nature:event.card.nature,
|
||||
|
@ -1156,11 +1159,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.chooseButton(['选择获得一张“兴”',player.storage.tenzen_yixing],true);
|
||||
player.chooseButton(['选择获得一张“兴”',player.getExpansions('tenzen_yixing')],true);
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
player.gain(result.links,'gain2','fromStorage');
|
||||
player.unmarkAuto('tenzen_yixing',result.links);
|
||||
player.gain(result.links,'gain2');;
|
||||
}
|
||||
var next=game.createEvent('tenzen_yixing_insert');
|
||||
event.next.remove(next);
|
||||
|
@ -1196,7 +1198,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
skillAnimation:true,
|
||||
animationColor:'water',
|
||||
filter:function(event,player){
|
||||
return player.getStorage('tenzen_yixing').length>=player.hp;
|
||||
return player.getExpansions('tenzen_yixing').length>=player.hp;
|
||||
},
|
||||
content:function(){
|
||||
player.awakenSkill('tenzen_lingyu');
|
||||
|
@ -1209,7 +1211,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
tenzen_tianquan:{
|
||||
trigger:{player:'useCardToPlayered'},
|
||||
filter:function(event,player){
|
||||
return (event.card.name=='sha'||event.card.name=='juedou')&&event.targets.length==1&&player.getStorage('tenzen_yixing').length>1;
|
||||
return (event.card.name=='sha'||event.card.name=='juedou')&&event.targets.length==1&&player.getExpansions('tenzen_yixing').length>1;
|
||||
},
|
||||
logTarget:'target',
|
||||
usable:1,
|
||||
|
@ -1219,17 +1221,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
content:function(){
|
||||
'step 0'
|
||||
//player.viewHandcards(trigger.target);
|
||||
player.chooseButton(['选择移去两张“兴”',player.storage.tenzen_yixing],true,2);
|
||||
player.chooseButton(['选择移去两张“兴”',player.getExpansions('tenzen_yixing')],true,2);
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
player.unmarkAuto('tenzen_yixing',result.links);
|
||||
player.loseToDiscardpile(result.links);
|
||||
var cards=get.cards(5);
|
||||
player.showCards(cards,get.translation(player)+'发动了【天全】');
|
||||
game.cardsGotoOrdering(cards).relatedEvent=trigger.getParent();
|
||||
game.log(player,'移去了',result.links);
|
||||
player.$throw(result.links,1500);
|
||||
game.cardsDiscard(result.links);
|
||||
//ui.cardPile.insertBefore(result.links[0],ui.cardPile.firstChild);
|
||||
var num=cards.filter(function(card){
|
||||
return get.type(card,false)=='basic';
|
||||
}).length;
|
||||
|
@ -3104,19 +3102,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
return (event.name!='phase'||game.phaseNumber==0);
|
||||
},
|
||||
content:function(){
|
||||
player.markAuto('shiroha_yuzhao',game.cardsGotoSpecial(get.cards(game.countGroup())).cards);
|
||||
player.addToExpansion(get.cards(game.countGroup()),'draw').gaintag.add('shiroha_yuzhao');
|
||||
},
|
||||
marktext:'兆',
|
||||
intro:{
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
},
|
||||
markcount:'expansion',
|
||||
mark:function(dialog,content,player){
|
||||
var content=player.getExpansions('shiroha_yuzhao');
|
||||
if(content&&content.length){
|
||||
if(player==game.me||player.isUnderControl()){
|
||||
dialog.addAuto(content);
|
||||
|
@ -3127,6 +3119,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
},
|
||||
content:function(content,player){
|
||||
var content=player.getExpansions('shiroha_yuzhao');
|
||||
if(content&&content.length){
|
||||
if(player==game.me||player.isUnderControl()){
|
||||
return get.translation(content);
|
||||
|
@ -3141,12 +3134,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{global:'phaseBegin'},
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
return player.getStorage('shiroha_yuzhao').length>0&&get.distance(event.player,player)<=1;
|
||||
return player.getExpansions('shiroha_yuzhao').length>0&&get.distance(event.player,player)<=1;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
event.num=game.countGroup();
|
||||
player.markAuto('shiroha_yuzhao',game.cardsGotoSpecial(get.cards(event.num)).cards);
|
||||
player.addToExpansion(get.cards(event.num)).gaintag.add('shiroha_yuzhao');
|
||||
'step 1'
|
||||
var next=player.chooseToMove(),num=game.countGroup();
|
||||
next.set('prompt','预兆:将'+get.cnNumber(num)+'张牌置于牌堆顶');
|
||||
|
@ -3160,7 +3153,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
return moved[1].length<_status.event.num;
|
||||
});
|
||||
next.set('list',[
|
||||
[get.translation(player)+'(你)的“兆”',player.storage.shiroha_yuzhao],
|
||||
[get.translation(player)+'(你)的“兆”',player.getExpansions('shiroha_yuzhao')],
|
||||
['牌堆顶'],
|
||||
]);
|
||||
next.set('processAI',function(list){
|
||||
|
@ -3170,10 +3163,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 2'
|
||||
if(result&&result.bool){
|
||||
var cards=result.moved[1];
|
||||
player.unmarkAuto('shiroha_yuzhao',cards);
|
||||
while(cards.length){
|
||||
ui.cardPile.insertBefore(cards.pop().fix(),ui.cardPile.firstChild);
|
||||
}
|
||||
player.lose(cards,ui.cardPile,'insert');
|
||||
}
|
||||
game.updateRoundNumber();
|
||||
},
|
||||
|
@ -3222,11 +3212,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{global:'judge'},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
return player.getStorage('shiroha_yuzhao').length&&event.player.isAlive();
|
||||
return player.getExpansions('shiroha_yuzhao').length&&event.player.isAlive();
|
||||
},
|
||||
content:function(){
|
||||
"step 0"
|
||||
var list=player.storage.shiroha_yuzhao;
|
||||
var list=player.getExpansions('shiroha_yuzhao');
|
||||
player.chooseButton([get.translation(trigger.player)+'的'+(trigger.judgestr||'')+'判定为'+get.translation(trigger.player.judging[0])+
|
||||
','+get.prompt('shiroha_jiezhao'),list,'hidden'],function(button){
|
||||
var card=button.link;
|
||||
|
@ -3250,16 +3240,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
event.forceDie=true;
|
||||
player.respond(result.links,'shiroha_jiezhao','highlight','noOrdering');
|
||||
result.cards=result.links;
|
||||
player.unmarkAuto('shiroha_yuzhao',result.cards);
|
||||
if(!player.storage.shiroha_yuzhao.length){
|
||||
player.storage.shiroha_jiezhao=true;
|
||||
player.gainMaxHp();
|
||||
player.recover();
|
||||
var list=['umi_chaofan','ao_xishi','tsumugi_mugyu','kamome_jieban'];
|
||||
var skill=list.randomGet();
|
||||
player.addSkillLog(skill);
|
||||
player.flashAvatar('shiroha_jiezhao','key_'+skill.split('_')[0])
|
||||
}
|
||||
}
|
||||
else{
|
||||
event.finish();
|
||||
|
@ -3281,6 +3261,16 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
game.log(trigger.player,'的判定牌改为',result.cards[0]);
|
||||
game.delay(2);
|
||||
}
|
||||
"step 3"
|
||||
if(!player.getExpansions('shiroha_yuzhao').length){
|
||||
player.storage.shiroha_jiezhao=true;
|
||||
player.gainMaxHp();
|
||||
player.recover();
|
||||
var list=['umi_chaofan','ao_xishi','tsumugi_mugyu','kamome_jieban'];
|
||||
var skill=list.randomGet();
|
||||
player.addSkillLog(skill);
|
||||
player.flashAvatar('shiroha_jiezhao','key_'+skill.split('_')[0]);
|
||||
}
|
||||
},
|
||||
ai:{
|
||||
rejudge:true,
|
||||
|
@ -3715,7 +3705,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
ryoichi_baoyi:{
|
||||
trigger:{
|
||||
player:'loseAfter',
|
||||
global:['gainAfter','equipAfter','addJudgeAfter','loseAsyncAfter'],
|
||||
global:['gainAfter','equipAfter','addJudgeAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
filterTarget:function(card,player,target){
|
||||
return target!=player&&(target.hasSex('female')||target.countCards('hej')>0);
|
||||
|
@ -4261,7 +4251,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
enable:'phaseUse',
|
||||
usable:1,
|
||||
filter:function(event,player){
|
||||
return !player.getStorage('kud_qiaoshou_equip').length&&player.countCards('h')>0;
|
||||
return !player.getExpansions('kud_qiaoshou_equip').length&&player.countCards('h')>0;
|
||||
},
|
||||
chooseButton:{
|
||||
dialog:function(){
|
||||
|
@ -4312,6 +4302,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
group:'kud_qiaoshou_end',
|
||||
ai:{
|
||||
notemp:true,
|
||||
order:5,
|
||||
result:{
|
||||
player:1,
|
||||
|
@ -4321,16 +4312,19 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
kud_qiaoshou_backupx:{
|
||||
filterCard:true,
|
||||
discard:false,
|
||||
toStorage:true,
|
||||
lose:false,
|
||||
delay:false,
|
||||
check:function(event,player){
|
||||
return 6-get.value(card);
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.addToExpansion(cards,player,'give').gaintag.add('kud_qiaoshou_equip');
|
||||
'step 1'
|
||||
if(!player.getExpansions('kud_qiaoshou_equip').length) return;
|
||||
player.addTempSkill('kud_qiaoshou_equip',{player:['phaseUseEnd','phaseZhunbeiBegin']});
|
||||
var name=lib.skill.kud_qiaoshou_backup.cardname;
|
||||
player.storage.kud_qiaoshou_equip2=name;
|
||||
player.markAuto('kud_qiaoshou_equip',cards);
|
||||
var info=lib.card[name].skills;
|
||||
if(info&&info.length) player.addAdditionalSkill('kud_qiaoshou_equip',info);
|
||||
player.draw();
|
||||
|
@ -4362,9 +4356,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
if(info&&info.distance&&info.distance.attackTo) return distance+info.distance.attackTo;
|
||||
},
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
intro:{
|
||||
markcount:'expansion',
|
||||
mark:function(dialog,storage,player){
|
||||
dialog.add(storage);
|
||||
dialog.add(player.getExpansions('kud_qiaoshou_equip'));
|
||||
dialog.addText('当前装备:'+get.translation(player.storage.kud_qiaoshou_equip2));
|
||||
var str2=lib.translate[player.storage.kud_qiaoshou_equip2+'_info'];
|
||||
if(str2){
|
||||
|
@ -4373,12 +4372,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
},
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
player.removeAdditionalSkill('kud_qiaoshou_equip');
|
||||
delete player.storage.kud_qiaoshou_equip2;
|
||||
player.addEquipTrigger();
|
||||
|
@ -4389,7 +4382,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{player:'phaseJieshuBegin'},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
return player.countCards('h')>0&&!player.getStorage('kud_qiaoshou_equip').length;
|
||||
return player.countCards('h')>0&&!player.getExpansions('kud_qiaoshou_equip').length;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
|
@ -4427,11 +4420,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
else event.finish();
|
||||
'step 2'
|
||||
var cards=result.cards;
|
||||
player.addToExpansion(cards,player,'give').gaintag.add('kud_qiaoshou_equip');
|
||||
'step 3'
|
||||
if(!player.getExpansions('kud_qiaoshou_equip').length) return;
|
||||
player.addTempSkill('kud_qiaoshou_equip',{player:['phaseUseEnd','phaseZhunbeiBegin']});
|
||||
var name=event.cardname;
|
||||
player.storage.kud_qiaoshou_equip2=name;
|
||||
var cards=result.cards;
|
||||
player.lose(cards,ui.special,'toStorage');
|
||||
player.markAuto('kud_qiaoshou_equip',cards);
|
||||
var info=lib.card[name].skills;
|
||||
if(info&&info.length) player.addAdditionalSkill('kud_qiaoshou_equip',info);
|
||||
|
@ -4442,7 +4437,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
kud_buhui:{
|
||||
enable:'chooseToUse',
|
||||
filter:function(event,player){
|
||||
return event.type=='dying'&&player==event.dying&&(player.getStorage('kud_qiaoshou_equip').length+player.countCards('e'))>0;
|
||||
return event.type=='dying'&&player==event.dying&&(player.getExpansions('kud_qiaoshou_equip').length+player.countCards('e'))>0;
|
||||
},
|
||||
skillAnimation:true,
|
||||
limited:true,
|
||||
|
@ -4450,11 +4445,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
content:function(){
|
||||
'step 0'
|
||||
player.awakenSkill('kud_buhui');
|
||||
var cards=player.getCards('e');
|
||||
var length=player.getStorage('kud_qiaoshou_equip').length;
|
||||
var cards=player.getCards('e').concat(player.getExpansions('kud_qiaoshou_equip'));
|
||||
if(cards.length) player.discard(cards);
|
||||
player.removeSkill('kud_qiaoshou_equip');
|
||||
player.draw(cards.length+length);
|
||||
player.draw(cards.length);
|
||||
player.addSkill('kud_chongzhen');
|
||||
'step 1'
|
||||
var num=2-player.hp;
|
||||
|
@ -4546,7 +4540,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
misuzu_zhongxing:{
|
||||
trigger:{
|
||||
player:'loseAfter',
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
|
@ -4580,7 +4574,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
kamome_yangfan:{
|
||||
trigger:{
|
||||
player:['loseAfter','enterGame'],
|
||||
global:['equipAfter','addJudgeAfter','phaseBefore','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','phaseBefore','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
|
@ -5878,31 +5872,26 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
});
|
||||
'step 2'
|
||||
if(result.bool){
|
||||
trigger.player.lose(result.links,ui.special,'visible','toStorage');
|
||||
trigger.player.$give(result.links,player,false);
|
||||
player.markAuto('ao_diegui',result.links);
|
||||
player.addToExpansion(result.links,trigger.player,'give').set('log',false).gaintag.add('ao_diegui');
|
||||
game.log(result.links,'飞向了',player);
|
||||
}
|
||||
else event.finish();
|
||||
'step 3'
|
||||
game.delayx();
|
||||
},
|
||||
locked:false,
|
||||
mod:{
|
||||
targetInRange:function(card,player){
|
||||
var list=player.getStorage('ao_diegui');
|
||||
var list=player.getExpansions('ao_diegui');
|
||||
for(var i=0;i<list.length;i++){
|
||||
if(get.suit(list[i],false)==get.suit(card,false)) return true;
|
||||
}
|
||||
},
|
||||
cardUsable:function(card,player){
|
||||
var list=player.getStorage('ao_diegui');
|
||||
var list=player.getExpansions('ao_diegui');
|
||||
for(var i=0;i<list.length;i++){
|
||||
if(get.suit(list[i],false)==get.suit(card,false)) return Infinity;
|
||||
}
|
||||
},
|
||||
maxHandcard:function(player,num){
|
||||
return num+player.getStorage('ao_diegui').length;
|
||||
return num+player.getExpansions('ao_diegui').length;
|
||||
},
|
||||
},
|
||||
},
|
||||
|
@ -5915,7 +5904,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
animationColor:'key',
|
||||
unique:true,
|
||||
filter:function(event,player){
|
||||
var list=player.getStorage('ao_diegui');
|
||||
var list=player.getExpansions('ao_diegui');
|
||||
var list2=[];
|
||||
for(var i=0;i<list.length;i++){
|
||||
list2.add(get.suit(list[i],false));
|
||||
|
@ -5934,11 +5923,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
enable:'phaseUse',
|
||||
usable:1,
|
||||
filter:function(event,player){
|
||||
return player.getStorage('ao_diegui').length>0;
|
||||
return player.getExpansions('ao_diegui').length>0;
|
||||
},
|
||||
chooseButton:{
|
||||
dialog:function(event,player){
|
||||
return ui.create.dialog('蝶归',player.storage.ao_diegui,'hidden');
|
||||
return ui.create.dialog('蝶归',player.getExpansions('ao_diegui'),'hidden');
|
||||
},
|
||||
backup:function(links,player){
|
||||
return {
|
||||
|
@ -5968,15 +5957,22 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
contentx:function(){
|
||||
'step 0'
|
||||
target.gain(lib.skill.ao_diegui_backup.card,player,'give','fromStorage');
|
||||
player.unmarkAuto('ao_diegui',lib.skill.ao_diegui_backup.card);
|
||||
target.gain(lib.skill.ao_diegui_backup.card,player,'give',player);
|
||||
target.draw(2);
|
||||
'step 1'
|
||||
target.link(false);
|
||||
'step 2'
|
||||
target.turnOver(false);
|
||||
},
|
||||
intro:{name:'七影蝶',content:'cards',onunmark:'throw'},
|
||||
intro:{
|
||||
name:'七影蝶',
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
ai:{order:1,result:{player:1}},
|
||||
},
|
||||
ayato_jianshen:{
|
||||
|
@ -7019,21 +7015,19 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 2'
|
||||
if(result.bool&&result.cards.length){
|
||||
var cards=result.cards;
|
||||
player.lose(cards,ui.special,'toStorage');
|
||||
player.markAuto('shiina_qingshen',cards);
|
||||
game.log(player,'将',cards,'置于武将牌上');
|
||||
player.addToExpansion(cards,player,'give').gaintag.add('shiina_qingshen');
|
||||
}
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:'throw',
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
mod:{
|
||||
attackFrom:function(from,to,num){
|
||||
return num-from.getStorage('shiina_qingshen').length;
|
||||
return num-from.getExpansions('shiina_qingshen').length;
|
||||
},
|
||||
maxHandcard:function(from,num){
|
||||
return num+from.getStorage('shiina_qingshen').length;
|
||||
return num+from.getExpansions('shiina_qingshen').length;
|
||||
},
|
||||
},
|
||||
ai:{
|
||||
|
@ -7046,17 +7040,15 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
direct:true,
|
||||
filter:function(event,player){
|
||||
if(lib.skill.shiina_feiyan.animalList.contains(event.player.name)) return false;
|
||||
return player.getStorage('shiina_qingshen').length>0&&player.inRange(event.player);
|
||||
return player.getExpansions('shiina_qingshen').length>0&&player.inRange(event.player);
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.chooseButton([get.prompt('shiina_feiyan',trigger.player),player.getStorage('shiina_qingshen')]).set('goon',get.attitude(player,trigger.player)<0?1:-1).set('ai',function(){return _status.event.goon});
|
||||
player.chooseButton([get.prompt('shiina_feiyan',trigger.player),player.getExpansions('shiina_qingshen')]).set('goon',get.attitude(player,trigger.player)<0?1:-1).set('ai',function(){return _status.event.goon});
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
var cards=result.links;
|
||||
player.unmarkAuto('shiina_qingshen',cards);
|
||||
game.cardsDiscard(cards);
|
||||
player.$throw(cards);
|
||||
player.loseToDiscardpile(cards);
|
||||
event.card={name:'sha',isCard:true};
|
||||
if(lib.filter.targetEnabled(event.card,player,trigger.player)){
|
||||
event.card=player.useCard(event.card,trigger.player,'shiina_feiyan').card;
|
||||
|
@ -7506,27 +7498,28 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
var cards=result.cards;
|
||||
player.logSkill('tsumugi_huilang');
|
||||
player.addSkill('tsumugi_huilang2');
|
||||
player.markAuto('tsumugi_huilang2',cards);
|
||||
player.lose(cards,ui.special);
|
||||
player.addToExpansion('giveAuto',cards,player).gaintag.add('tsumugi_huilang2');
|
||||
}
|
||||
},
|
||||
},
|
||||
tsumugi_huilang2:{
|
||||
charlotte:true,
|
||||
marktext:'隐',
|
||||
intro:{content:'cardCount',onunmark:'throw'},
|
||||
intro:{content:'隐藏于回廊之牌',markcount:'expansion'},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
trigger:{player:'phaseBegin'},
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
return player.getStorage('tsumugi_huilang2').length>0;
|
||||
return player.getExpansions('tsumugi_huilang2').length>0;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
var cards=player.getStorage('tsumugi_huilang2');
|
||||
var cards=player.getExpansions('tsumugi_huilang2');
|
||||
event.num=cards.length;
|
||||
player.gain(cards,'draw');
|
||||
game.log(player,'获得了'+get.cnNumber(cards.length)+'张牌');
|
||||
player.unmarkAuto('tsumugi_huilang2',cards);
|
||||
'step 1'
|
||||
player.chooseTarget([1,num],'是否令至多'+get.cnNumber(num)+'名角色各摸一张牌?').set('ai',function(target){
|
||||
return get.attitude(_status.event.player,target);
|
||||
|
@ -9867,9 +9860,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 1'
|
||||
if(result.bool){
|
||||
player.logSkill('nsjiquan',target);
|
||||
target.lose(result.cards,ui.special,'toStorage');
|
||||
player.markAuto('nsjiquan_mark',result.cards);
|
||||
target.$give(result.cards,player,false);
|
||||
player.addToExpansion(result.cards,target,'give').gaintag.add('nsjiquan_mark');
|
||||
}
|
||||
else event.finish();
|
||||
'step 2'
|
||||
|
@ -9877,14 +9868,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
mod:{
|
||||
cardUsable:function(card,player,num){
|
||||
if(card.name=='sha') return num+player.getStorage('nsjiquan_mark').length;
|
||||
if(card.name=='sha') return num+player.getExpansions('nsjiquan_mark').length;
|
||||
},
|
||||
},
|
||||
},
|
||||
nsjiquan_mark:{
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:'throw',
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
marktext:'威',
|
||||
},
|
||||
|
@ -9896,7 +9887,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
skillAnimation:true,
|
||||
animationColor:'thunder',
|
||||
filter:function(event,player){
|
||||
return player.getStorage('nsjiquan_mark').length>4;
|
||||
return player.getExpansions('nsjiquan_mark').length>4;
|
||||
},
|
||||
content:function(){
|
||||
player.awakenSkill('nsfuwei');
|
||||
|
@ -9911,14 +9902,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{player:'phaseUseBegin'},
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
return player.getStorage('nsjiquan_mark').length>game.players.length;
|
||||
return player.getExpansions('nsjiquan_mark').length>game.players.length;
|
||||
},
|
||||
content:function(){
|
||||
var num=player.getStorage('nsjiquan_mark').length;
|
||||
player.draw(num);
|
||||
var cards=player.getExpansions('nsjiquan_mark');
|
||||
player.draw(cards.length);
|
||||
player.loseMaxHp();
|
||||
player.unmarkSkill('nsjiquan_mark');
|
||||
if(num>4) player.turnOver();
|
||||
player.loseToDiscardpile(cards);
|
||||
if(cards.length>4) player.turnOver();
|
||||
},
|
||||
},
|
||||
nszhihuang:{
|
||||
|
@ -9926,7 +9917,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{global:'useCard'},
|
||||
usable:1,
|
||||
filter:function(event,player){
|
||||
return event.player==get.zhu(player)&&player.getStorage('nsjiquan_mark').length>0&&event.cards&&event.cards.filterInD().length>0;
|
||||
return event.player==get.zhu(player)&&player.getExpansions('nsjiquan_mark').length>0&&event.cards&&event.cards.filterInD().length>0;
|
||||
},
|
||||
prompt2:function(event){
|
||||
return '移去一张“威”并获得'+get.translation(event.cards.filterInD());
|
||||
|
@ -9945,8 +9936,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
else player.chooseButton(['选择移去一张“威”',cards],true);
|
||||
'step 1'
|
||||
player.unmarkAuto('nsjiquan_mark',result.links);
|
||||
game.cardsDiscard(result.links);
|
||||
player.loseToDiscardpile(result.links);
|
||||
player.gain(trigger.cards.filterInD(),'gain2','log');
|
||||
},
|
||||
},
|
||||
|
@ -10263,7 +10253,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
nsfengli_draw:{
|
||||
trigger:{
|
||||
player:['loseAfter','nsfengliClear'],
|
||||
global:['gainAfter','equipAfter','addJudgeAfter','loseAsyncAfter'],
|
||||
global:['gainAfter','equipAfter','addJudgeAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
target:'nsfengliUse',
|
||||
},
|
||||
direct:true,
|
||||
|
|
|
@ -307,7 +307,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
player.loseMaxHp();
|
||||
},
|
||||
locked:false,
|
||||
global:'yingba_mark',
|
||||
//global:'yingba_mark',
|
||||
mod:{
|
||||
targetInRange:function(card,player,target){
|
||||
if(target.hasMark('yingba_mark')) return true;
|
||||
|
@ -1229,7 +1229,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
boss_juejing2:{
|
||||
trigger:{
|
||||
player:'loseAfter',
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
|
@ -1720,7 +1720,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:2,
|
||||
trigger:{global:'damageEnd'},
|
||||
filter:function(event,player){
|
||||
return event.player.isAlive()&&player.getStorage('chuyuan').length<player.maxHp;
|
||||
return event.player.isAlive()&&player.getExpansions('chuyuan').length<player.maxHp;
|
||||
},
|
||||
logTarget:'player',
|
||||
locked:false,
|
||||
|
@ -1731,20 +1731,17 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
if(!trigger.player.countCards('h')) event.finish();
|
||||
else trigger.player.chooseCard('h',true,'选择一张牌置于'+get.translation(player)+'的武将牌上作为「储」');
|
||||
'step 2'
|
||||
trigger.player.lose(result.cards,ui.special,'visible','toStorage');
|
||||
trigger.player.$give(result.cards,player,false);
|
||||
game.log(trigger.player,'选择了',result.cards);
|
||||
player.markAuto('chuyuan',result.cards);
|
||||
player.addToExpansion(result.cards,trigger.player,'give').gaintag.add('chuyuan');
|
||||
},
|
||||
//mod:{
|
||||
// maxHandcard:function(player,num){
|
||||
// return num+player.getStorage('chuyuan').length;
|
||||
// },
|
||||
//},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:'throw',
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
ai:{combo:'dengji'},
|
||||
},
|
||||
dengji:{
|
||||
audio:2,
|
||||
|
@ -1756,15 +1753,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
skillAnimation:true,
|
||||
animationColor:'water',
|
||||
filter:function(event,player){
|
||||
return player.getStorage('chuyuan').length>=3;
|
||||
return player.getExpansions('chuyuan').length>=3;
|
||||
},
|
||||
content:function(){
|
||||
player.awakenSkill(event.name);
|
||||
player.addSkill('tianxing');
|
||||
player.addSkill('new_rejianxiong');
|
||||
player.loseMaxHp();
|
||||
player.gain(player.storage.chuyuan,'gain2','fromStorage');
|
||||
player.unmarkAuto('chuyuan',player.storage.chuyuan);
|
||||
player.gain(player.getExpansions('chuyuan'),'gain2','fromStorage');
|
||||
},
|
||||
},
|
||||
tianxing:{
|
||||
|
@ -1776,14 +1772,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
skillAnimation:true,
|
||||
animationColor:'thunder',
|
||||
filter:function(event,player){
|
||||
return player.getStorage('chuyuan').length>=3;
|
||||
return player.getExpansions('chuyuan').length>=3;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.awakenSkill(event.name);
|
||||
player.loseMaxHp();
|
||||
player.gain(player.storage.chuyuan,'gain2','fromStorage');
|
||||
player.unmarkAuto('chuyuan',player.storage.chuyuan);
|
||||
player.gain(player.getExpansions('chuyuan'),'gain2','fromStorage');
|
||||
"step 1"
|
||||
player.removeSkill('chuyuan');
|
||||
player.chooseControl('rerende','rezhiheng','olluanji','caopi_xingdong').set('prompt','选择获得一个技能').set('ai',function(){
|
||||
var player=_status.event.player;
|
||||
|
@ -1792,7 +1788,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
if(!player.hasSkill('caopi_xingdong')) return 'caopi_xingdong';
|
||||
return 'rerende';
|
||||
});
|
||||
'step 1'
|
||||
'step 2'
|
||||
player.addSkillLog(result.control);
|
||||
},
|
||||
},
|
||||
|
@ -3069,9 +3065,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
content:function(){
|
||||
"step 0"
|
||||
player.markAuto('qixing',game.cardsGotoSpecial(get.cards(7)).cards);
|
||||
player.addToExpansion(get.cards(7),'gain2').gaintag.add('qixing');
|
||||
"step 1"
|
||||
var cards=player.getStorage('qixing');
|
||||
var cards=player.getExpansions('qixing');
|
||||
if(!cards.length||!player.countCards('h')){
|
||||
event.finish();
|
||||
return;
|
||||
|
@ -3087,34 +3083,24 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
next.set('processAI',function(list){
|
||||
var player=_status.event.player,cards=list[0][1].concat(list[1][1]).sort(function(a,b){
|
||||
return get.useful(a)-get.useful(b);
|
||||
}),cards2=cards.splice(0,player.storage.qixing.length);
|
||||
}),cards2=cards.splice(0,player.getExpansions('qixing').length);
|
||||
return [cards2,cards];
|
||||
});
|
||||
"step 2"
|
||||
if(result.bool){
|
||||
var pushs=result.moved[0],gains=result.moved[1];
|
||||
pushs.removeArray(player.storage.qixing);
|
||||
pushs.removeArray(player.getExpansions('qixing'));
|
||||
gains.removeArray(player.getCards('h'));
|
||||
if(!pushs.length||pushs.length!=gains.length) return;
|
||||
player.lose(pushs,ui.special,'toStorage');
|
||||
player.addToExpansion(pushs,player,'giveAuto').gaintag.add('qixing');
|
||||
game.log(player,'将',pushs,'作为“星”置于武将牌上');
|
||||
player.gain(gains,'gain2','log','fromStorage');
|
||||
player.storage.qixing.addArray(pushs);
|
||||
player.storage.qixing.removeArray(gains);
|
||||
player.markSkill('qixing');
|
||||
player.gain(gains,'gain2');
|
||||
}
|
||||
},
|
||||
mark:true,
|
||||
intro:{
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
},
|
||||
markcount:'expansion',
|
||||
mark:function(dialog,content,player){
|
||||
var content=player.getExpansions('qixing');
|
||||
if(content&&content.length){
|
||||
if(player==game.me||player.isUnderControl()){
|
||||
dialog.addAuto(content);
|
||||
|
@ -3125,6 +3111,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
},
|
||||
content:function(content,player){
|
||||
var content=player.getExpansions('qixing');
|
||||
if(content&&content.length){
|
||||
if(player==game.me||player.isUnderControl()){
|
||||
return get.translation(content);
|
||||
|
@ -3134,16 +3121,17 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
},
|
||||
group:['qixing2'],
|
||||
ai:{combo:'dawu'},
|
||||
},
|
||||
qixing2:{
|
||||
trigger:{player:'phaseDrawAfter'},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
return player.storage.qixing&&player.storage.qixing.length;
|
||||
return player.getExpansions('qixing').length>0&&player.countCards('h')>0;
|
||||
},
|
||||
content:function(){
|
||||
"step 0"
|
||||
var cards=player.getStorage('qixing');
|
||||
var cards=player.getExpansions('qixing');
|
||||
if(!cards.length||!player.countCards('h')){
|
||||
event.finish();
|
||||
return;
|
||||
|
@ -3159,38 +3147,34 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
next.set('processAI',function(list){
|
||||
var player=_status.event.player,cards=list[0][1].concat(list[1][1]).sort(function(a,b){
|
||||
return get.value(a)-get.value(b);
|
||||
}),cards2=cards.splice(0,player.storage.qixing.length);
|
||||
}),cards2=cards.splice(0,player.getExpansions('qixing').length);
|
||||
return [cards2,cards];
|
||||
});
|
||||
"step 1"
|
||||
if(result.bool){
|
||||
var pushs=result.moved[0],gains=result.moved[1];
|
||||
pushs.removeArray(player.storage.qixing);
|
||||
pushs.removeArray(player.getExpansions('qixing'));
|
||||
gains.removeArray(player.getCards('h'));
|
||||
if(!pushs.length||pushs.length!=gains.length) return;
|
||||
player.logSkill('qixing2');
|
||||
player.lose(pushs,ui.special,'toStorage');
|
||||
player.addToExpansion(pushs,player,'giveAuto').gaintag.add('qixing');
|
||||
game.log(player,'将',pushs,'作为“星”置于武将牌上');
|
||||
player.gain(gains,'gain2','log','fromStorage');
|
||||
player.storage.qixing.addArray(pushs);
|
||||
player.storage.qixing.removeArray(gains);
|
||||
player.markSkill('qixing');
|
||||
player.gain(gains,'gain2');
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
dawu:{
|
||||
unique:true,
|
||||
trigger:{player:'phaseJieshuBegin'},
|
||||
//priority:1,
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
return player.storage.qixing&&player.storage.qixing.length;
|
||||
return player.getExpansions('qixing').length;
|
||||
},
|
||||
audio:2,
|
||||
content:function(){
|
||||
"step 0"
|
||||
player.chooseTarget(get.prompt('dawu'),'选择角色获得大雾标记',
|
||||
[1,Math.min(game.countPlayer(),player.storage.qixing.length)]).set('ai',function(target){
|
||||
var num=Math.min(game.countPlayer(),player.getExpansions('qixing').length);
|
||||
player.chooseTarget(get.prompt('dawu'),'令至多'+get.cnNumber(num)+'名角色获得“大雾”标记',
|
||||
[1,num]).set('ai',function(target){
|
||||
if(target.isMin()) return 0;
|
||||
if(target.hasSkill('biantian2')) return 0;
|
||||
var att=get.attitude(player,target);
|
||||
|
@ -3201,34 +3185,26 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
return 0;
|
||||
}
|
||||
return -1;
|
||||
}).set('allUse',player.storage.qixing.length>=game.countPlayer(function(current){
|
||||
}).set('allUse',player.getExpansions('qixing').length>=game.countPlayer(function(current){
|
||||
return get.attitude(player,current)>4;
|
||||
})*2);
|
||||
"step 1"
|
||||
if(result.bool){
|
||||
player.logSkill('dawu',result.targets,'thunder');
|
||||
var length=result.targets.length;
|
||||
for(var i=0;i<length;i++){
|
||||
result.targets[i].addSkill('dawu2');
|
||||
}
|
||||
player.logSkill('dawu',result.targets,'thunder');
|
||||
player.chooseCardButton('弃置'+get.cnNumber(length)+'枚星',length,player.storage.qixing,true);
|
||||
player.chooseCardButton('选择弃置'+get.cnNumber(length)+'张“星”',length,player.getExpansions('qixing'),true);
|
||||
player.addSkill('dawu3');
|
||||
}
|
||||
else{
|
||||
event.finish();
|
||||
}
|
||||
"step 2"
|
||||
for(var i=0;i<result.links.length;i++){
|
||||
player.storage.qixing.remove(result.links[i]);
|
||||
}
|
||||
if(player.storage.qixing.length==0){
|
||||
player.unmarkSkill('qixing');
|
||||
}
|
||||
player.$throw(result.links,1000);
|
||||
game.delayx();
|
||||
game.addVideo('storage',player,['qixing',get.cardsInfo(player.storage.qixing),'cards']);
|
||||
game.cardsDiscard(result.links);
|
||||
player.loseToDiscardpile(result.links);
|
||||
},
|
||||
ai:{combo:'qixing'},
|
||||
},
|
||||
dawu2:{
|
||||
trigger:{player:'damageBegin4'},
|
||||
|
@ -3253,7 +3229,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
intro:{
|
||||
markcount:()=>1,
|
||||
content:'共有1个标记'
|
||||
content:'共有1个标记',
|
||||
}
|
||||
},
|
||||
dawu3:{
|
||||
|
@ -3278,11 +3254,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{player:'phaseJieshuBegin'},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
return player.storage.qixing&&player.storage.qixing.length;
|
||||
return player.getExpansions('qixing').length;
|
||||
},
|
||||
content:function(){
|
||||
"step 0"
|
||||
player.chooseTarget(get.prompt('kuangfeng'),'选择一名角色获得“狂风”标记').ai=function(target){
|
||||
player.chooseTarget(get.prompt('kuangfeng'),'令一名角色获得“狂风”标记').ai=function(target){
|
||||
return -1;
|
||||
}
|
||||
"step 1"
|
||||
|
@ -3292,25 +3268,16 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
result.targets[i].addSkill('kuangfeng2');
|
||||
}
|
||||
player.logSkill('kuangfeng',result.targets,'fire');
|
||||
player.chooseCardButton('弃置'+get.cnNumber(length)+'枚星',length,player.storage.qixing,true);
|
||||
player.chooseCardButton('弃置'+get.cnNumber(length)+'枚星',length,player.getExpansions('qixing'),true);
|
||||
player.addSkill('dawu3');
|
||||
}
|
||||
else{
|
||||
event.finish();
|
||||
}
|
||||
"step 2"
|
||||
for(var i=0;i<result.links.length;i++){
|
||||
player.storage.qixing.remove(result.links[i]);
|
||||
}
|
||||
if(player.storage.qixing.length==0){
|
||||
player.unmarkSkill('qixing');
|
||||
}
|
||||
player.$throw(result.links,1000);
|
||||
game.delayx();
|
||||
game.addVideo('storage',player,['qixing',get.cardsInfo(player.storage.qixing),'cards']);
|
||||
game.cardsDiscard(result.links);
|
||||
game.log(player,'将',result.links,'置入了弃牌堆')
|
||||
player.loseToDiscardpile(result.links);
|
||||
},
|
||||
ai:{combo:'qixing'},
|
||||
},
|
||||
kuangfeng2:{
|
||||
trigger:{player:'damageBegin3'},
|
||||
|
@ -4945,7 +4912,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
dinghan_info:'①当你成为未记录过的锦囊牌的目标时,你记录此牌名并取消之。②准备阶段,你可在〖定汉①〗的记录中添加或减少一种锦囊牌的牌名。',
|
||||
shen_sunce:'神孙策',
|
||||
yingba:'英霸',
|
||||
yingba_info:'①出牌阶段限一次,你可令一名体力上限大于1的其他角色减少1点体力上限并获得“平定”标记,然后你减少1点体力上限。②你对拥有“平定”标记的角色使用牌没有距离限制。③拥有“平定”标记的角色的手牌上限+X(X为其“平定”数)。',
|
||||
yingba_info:'①出牌阶段限一次,你可令一名体力上限大于1的其他角色减少1点体力上限并获得“平定”标记,然后你减少1点体力上限。②你对拥有“平定”标记的角色使用牌没有距离限制。',
|
||||
scfuhai:'覆海',
|
||||
scfuhai_info:'锁定技。①当你使用牌指定目标后,若目标角色有“平定”标记,则其不可响应此牌。若你本回合内以此法获得的牌数小于2,则你摸一张牌。②拥有“平定”标记的角色死亡时,你增加X点体力上限并摸X张牌。(X为其拥有的“平定”标记数)。',
|
||||
pinghe:'冯河',
|
||||
|
|
|
@ -843,7 +843,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
player.logSkill('yingfeng',target);
|
||||
target.addAdditionalSkill('yingfeng_'+player.playerid,'yingfeng_mark');
|
||||
game.countPlayer(function(current){
|
||||
if(current!=target&¤t.hasSkill('yingfeng_mark')) current.removeSkill('yingfeng_mark');
|
||||
if(current!=target&¤t.hasSkill('yingfeng_mark')){
|
||||
current.removeSkill('yingfeng_mark');
|
||||
current.removeAdditionalSkill('yingfeng_'+player.playerid);
|
||||
}
|
||||
});
|
||||
}
|
||||
},
|
||||
|
@ -919,7 +922,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
content:function(){
|
||||
var num=player.getDamagedHp();
|
||||
game.log(player,'的拼点牌点数-',num);
|
||||
trigger.num1=Math.min(1,trigger.num1-num);
|
||||
trigger.num1=Math.max(1,trigger.num1-num);
|
||||
}
|
||||
},
|
||||
},
|
||||
|
@ -1249,7 +1252,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 0'
|
||||
var evt=trigger.getParent();
|
||||
if(evt.name=='phaseJudge') evt.excluded=true;
|
||||
else evt.finish();
|
||||
else{
|
||||
evt.finish();
|
||||
evt._triggered=null;
|
||||
}
|
||||
var list=[];
|
||||
if(get.position(trigger.result.card)=='d') list.push(0);
|
||||
if(trigger.player.isIn()&&player.canUse({name:'sha',nature:'fire',isCard:true},trigger.player,false)) list.push(1);
|
||||
|
@ -1766,7 +1772,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
return player!=event.player&&game.getGlobalHistory('cardMove',function(evt){
|
||||
if(evt.name!='lose'||evt.type!='discard') return false;
|
||||
for(var i of evt.cards){
|
||||
if(get.subtype(i,false)=='equip2') return true;
|
||||
if(get.subtype(i,false)=='equip2'&&get.position(i,true)=='d') return true;
|
||||
}
|
||||
return false;
|
||||
}).length>0;
|
||||
|
@ -1777,7 +1783,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
game.getGlobalHistory('cardMove',function(evt){
|
||||
if(evt.name!='lose'||evt.type!='discard') return false;
|
||||
for(var i of evt.cards){
|
||||
if(get.subtype(i,false)=='equip2') cards.push(i);
|
||||
if(get.subtype(i,false)=='equip2'&&get.position(i,true)=='d') cards.push(i);
|
||||
}
|
||||
});
|
||||
player.chooseButton(['俭衣:获得一张防具牌',cards],true).set('ai',function(button){
|
||||
|
@ -2977,10 +2983,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
if(player.storage.jutu&&player.storage.jutu.length>0){
|
||||
player.gain(player.storage.jutu,'gain2');
|
||||
delete player.storage.jutu;
|
||||
player.unmarkSkill('jutu');
|
||||
var cards=player.getExpansions('jutu');
|
||||
if(cards.length>0){
|
||||
player.gain(cards,'gain2');
|
||||
}
|
||||
'step 1'
|
||||
event.num=game.countPlayer(function(current){
|
||||
|
@ -2996,18 +3001,20 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 3'
|
||||
if(result.bool){
|
||||
var cards=result.cards;
|
||||
player.markAuto('jutu',cards);
|
||||
game.log(player,'将',cards,'放在了武将牌上');
|
||||
player.lose(cards,ui.special,'toStorage');
|
||||
player.addToExpansion(player,'give',cards).gaintag.add('jutu');
|
||||
}
|
||||
'step 4'
|
||||
game.delayx();
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:'throw',
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
ai:{combo:'jutu'},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
ai:{combo:'yaohu'},
|
||||
},
|
||||
yaohu:{
|
||||
audio:'yinlang',
|
||||
|
@ -3065,20 +3072,19 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
forced:true,
|
||||
locked:false,
|
||||
filter:function(event,player){
|
||||
return event.player!=player&&event.player.group==player.storage.yaohu&&event.player.isIn()&&player.getStorage('jutu').length>0;
|
||||
return event.player!=player&&event.player.group==player.storage.yaohu&&event.player.isIn()&&player.getExpansions('jutu').length>0;
|
||||
},
|
||||
logTarget:'player',
|
||||
content:function(){
|
||||
'step 0'
|
||||
var target=trigger.player;
|
||||
event.target=target;
|
||||
target.chooseButton(['选择获得一张“生”',player.storage.jutu],true).set('ai',function(button){
|
||||
target.chooseButton(['选择获得一张“生”',player.getExpansions('jutu')],true).set('ai',function(button){
|
||||
return get.value(button.link,player);
|
||||
});
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
player.unmarkAuto('jutu',result.links);
|
||||
target.gain(result.links,'gain2','fromStorage');
|
||||
target.gain(result.links,'give',player);
|
||||
}
|
||||
'step 2'
|
||||
if(game.hasPlayer(function(current){
|
||||
|
@ -3147,14 +3153,15 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger.getParent().triggeredTargets2.remove(player);
|
||||
trigger.untrigger();
|
||||
var card=trigger.cards[0];
|
||||
game.cardsGotoSpecial(card);
|
||||
player.$gain2(card,false);
|
||||
game.log(player,'将',card,'作为“绝”置于了武将牌上');
|
||||
player.addToExpansion(card,'gain2').gaintag.add('jueyong');
|
||||
if(!player.storage.jueyong) player.storage.jueyong=[[],[]];
|
||||
player.storage.jueyong[0].push(card);
|
||||
player.storage.jueyong[1].push(trigger.player);
|
||||
player.markSkill('jueyong');
|
||||
game.delayx();
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
delete player.storage[skill];
|
||||
},
|
||||
intro:{
|
||||
markcount:function(storage){
|
||||
|
@ -3165,12 +3172,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
dialog.addText(get.translation(storage[1]));
|
||||
},
|
||||
onunmark:function(storage,player){
|
||||
if(storage[0]&&storage[0].length){
|
||||
player.$throw(storage[0],1000);
|
||||
game.cardsDiscard(storage[0]);
|
||||
game.log(storage[0],'进入了弃牌堆');
|
||||
}
|
||||
delete player.storage.jueyong;
|
||||
player.storage.jueyong=[[],[]];
|
||||
},
|
||||
},
|
||||
ai:{
|
||||
|
@ -3197,10 +3199,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
content:function(){
|
||||
var list=player.storage.jueyong,card=list[0].shift(),source=list[1].shift();
|
||||
if(source&&source.isIn()&&source.canUse(card,player,false)) source.useCard(card,player,false);
|
||||
else game.cardsDiscard(card);
|
||||
if(player.getExpansions('jueyong').contains(card)){
|
||||
if(source&&source.isIn()&&source.canUse(card,player,false)) source.useCard(card,player,false);
|
||||
else player.loseToDiscardpile(card);
|
||||
}
|
||||
if(list[0].length) event.redo();
|
||||
else player.unmarkSkill('jueyong');
|
||||
},
|
||||
},
|
||||
},
|
||||
|
@ -4407,9 +4410,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
frequent:true,
|
||||
locked:false,
|
||||
notemp:true,
|
||||
init:function(player){
|
||||
if(!player.storage.quanji) player.storage.quanji=[];
|
||||
},
|
||||
filter:function(event,player){
|
||||
if(event.name=='phaseUse') return player.countCards('h')>player.hp;
|
||||
return event.num>0;
|
||||
|
@ -4429,11 +4429,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
"step 3"
|
||||
if(result.cards&&result.cards.length){
|
||||
player.lose(result.cards,ui.special,'toStorage');
|
||||
player.storage.quanji=player.storage.quanji.concat(result.cards);
|
||||
player.syncStorage('quanji');
|
||||
player.markSkill('quanji');
|
||||
game.log(player,'将',result.cards,'置于武将牌上作为“权”');
|
||||
player.addToExpansion(result.cards,player,'give').gaintag.add('quanji');
|
||||
}
|
||||
"step 4"
|
||||
if(event.count>0){
|
||||
|
@ -4448,9 +4444,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
mod:{
|
||||
maxHandcard:function(player,num){
|
||||
return num+player.storage.quanji.length;
|
||||
return num+player.getExpansions('quanji').length;
|
||||
}
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions('quanji');
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
ai:{
|
||||
maixie:true,
|
||||
maixie_hp:true,
|
||||
|
@ -10885,10 +10885,16 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
if(card){
|
||||
cards.push(card);
|
||||
names.push(card.name);
|
||||
if(cards.length==3&&!get.isLuckyStar(player)&&Math.random()<0.33) break;
|
||||
if(cards.length==4&&!get.isLuckyStar(player)&&Math.random()<0.5) break;
|
||||
if(cards.length==5) break;
|
||||
if(cards.length>=6) break;
|
||||
if(get.mode()=='doudizhu'){
|
||||
if(cards.length==1&&!get.isLuckyStar(player)&&Math.random()<0.33) break;
|
||||
if(cards.length==2&&!get.isLuckyStar(player)&&Math.random()<0.5) break;
|
||||
if(cards.length>=3) break;
|
||||
}
|
||||
else{
|
||||
if(cards.length==3&&!get.isLuckyStar(player)&&Math.random()<0.33) break;
|
||||
if(cards.length==4&&!get.isLuckyStar(player)&&Math.random()<0.5) break;
|
||||
if(cards.length>=5) break;
|
||||
}
|
||||
}
|
||||
else break;
|
||||
};
|
||||
|
@ -11128,12 +11134,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
if(result.bool){
|
||||
var cards=result.moved[0],gains=result.moved[1];
|
||||
target.addSkill('zhengjing2');
|
||||
target.markAuto('zhengjing2',cards);
|
||||
target.$gain2(cards,false);
|
||||
game.cardsGotoSpecial(cards);
|
||||
target.addToExpansion(cards,'gain2').gaintag.add('zhengjing2');
|
||||
if(gains.length) player.gain(gains,'gain2');
|
||||
else game.delayx();
|
||||
game.log(player,'将',cards,'置于了',target,'的武将牌上');
|
||||
}
|
||||
},
|
||||
ai:{
|
||||
|
@ -11146,14 +11148,19 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
zhengjing2:{
|
||||
trigger:{player:'phaseZhunbeiBegin'},
|
||||
forced:true,
|
||||
intro:{content:'cards'},
|
||||
charlotte:true,
|
||||
intro:{content:'expansion',markcount:'expansion'},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
content:function(){
|
||||
player.gain(player.storage.zhengjing2,'gain2','log','fromStorage');
|
||||
delete player.storage.zhengjing2;
|
||||
player.removeSkill('zhengjing2');
|
||||
//player.addTempSkill('zhengjing3');
|
||||
'step 0'
|
||||
player.gain(player.getExpansions('zhengjing2'),'gain2');
|
||||
player.skip('phaseJudge');
|
||||
player.skip('phaseDraw');
|
||||
'step 1'
|
||||
player.removeSkill('zhengjing2');
|
||||
},
|
||||
},
|
||||
zhengjing3:{},
|
||||
|
@ -11561,19 +11568,17 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
event.target=result.targets[0];
|
||||
player.logSkill('rezhengrong',target);
|
||||
var card=target.getCards('he').randomGet();
|
||||
game.log(player,'选择了',card);
|
||||
target.$give(card,player,false);
|
||||
target.lose(card,ui.special,'toStorage');
|
||||
if(!player.storage.rezhengrong) player.storage.rezhengrong=[];
|
||||
player.storage.rezhengrong.push(card);
|
||||
player.markSkill('rezhengrong');
|
||||
game.delayx();
|
||||
player.addToExpansion(card,target,'give').gaintag.add('rezhengrong');
|
||||
}
|
||||
},
|
||||
marktext:'荣',
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:'throw',
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
},
|
||||
rehongju:{
|
||||
|
@ -11586,19 +11591,19 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
animationColor:'thunder',
|
||||
derivation:'reqingce',
|
||||
filter:function(event,player){
|
||||
return player.storage.rezhengrong&&player.storage.rezhengrong.length>=3&&game.dead.length>0;
|
||||
return player.getExpansions('rezhengrong').length>=3&&game.dead.length>0;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.awakenSkill('rehongju');
|
||||
player.draw(player.storage.rezhengrong.length);
|
||||
player.draw(player.getExpansions('rezhengrong').length);
|
||||
'step 1'
|
||||
if(player.countCards('h')==0) event.goto(3);
|
||||
else{
|
||||
var dialog=['请选择要交换的手牌和「荣」,或点「取消」','<div class="text center">「征荣」牌</div>',player.storage.rezhengrong,'<div class="text center">手牌区</div>',player.getCards('h')];
|
||||
var dialog=['请选择要交换的手牌和「荣」,或点「取消」','<div class="text center">「征荣」牌</div>',player.getExpansions('rezhengrong'),'<div class="text center">手牌区</div>',player.getCards('h')];
|
||||
var next=player.chooseButton(dialog);
|
||||
next.set('filterButton',function(button){
|
||||
var ss=_status.event.player.storage.rezhengrong;
|
||||
var ss=_status.event.player.getExpansions('rezhengrong');
|
||||
var hs=_status.event.player.getCards('h');
|
||||
var sn=0;
|
||||
var hn=0;
|
||||
|
@ -11611,7 +11616,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
});
|
||||
next.set('selectButton',function(){
|
||||
if(ui.selected.buttons.length==0) return 2;
|
||||
var ss=_status.event.player.storage.rezhengrong;
|
||||
var ss=_status.event.player.getExpansions('rezhengrong');
|
||||
var hs=_status.event.player.getCards('h');
|
||||
var sn=0;
|
||||
var hn=0;
|
||||
|
@ -11632,17 +11637,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
if(result.bool){
|
||||
var gains=[];
|
||||
var pushs=[];
|
||||
var expansions=player.getExpansions('rezhengrong');
|
||||
for(var i=0;i<result.links.length;i++){
|
||||
var card=result.links[i];
|
||||
if(player.storage.rezhengrong.contains(card)) gains.push(card);
|
||||
if(expansions.contains(card)) gains.push(card);
|
||||
else pushs.push(card);
|
||||
}
|
||||
player.lose(pushs,ui.special,'toStorage');
|
||||
game.log(player,'将',pushs,'放在了武将牌上');
|
||||
player.gain(gains,'gain2','log','fromStorage');
|
||||
player.storage.rezhengrong.addArray(pushs);
|
||||
player.storage.rezhengrong.removeArray(gains);
|
||||
player.markSkill('rezhengrong');
|
||||
player.addToExpansion(pushs,player,'give').gaintag.add('rezhengrong');
|
||||
player.gain(gains,'gain2');
|
||||
}
|
||||
'step 3'
|
||||
player.addSkill('reqingce');
|
||||
|
@ -11654,11 +11656,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
enable:'phaseUse',
|
||||
audio:'drlt_qingce',
|
||||
filter:function(event,player){
|
||||
return player.storage.rezhengrong&&player.storage.rezhengrong.length>0;
|
||||
return player.getExpansions('rezhengrong').length>0;
|
||||
},
|
||||
chooseButton:{
|
||||
dialog:function(event,player){
|
||||
return ui.create.dialog('请选择要移去的「荣」',player.storage.rezhengrong,'hidden');
|
||||
return ui.create.dialog('请选择要移去的「荣」',player.getExpansions('rezhengrong'),'hidden');
|
||||
},
|
||||
backup:function(links,player){
|
||||
return {
|
||||
|
@ -11692,10 +11694,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
contentx:function(){
|
||||
'step 0'
|
||||
var card=lib.skill.reqingce_backup.card;
|
||||
player.$throw(card);
|
||||
game.cardsDiscard(card);
|
||||
player.storage.rezhengrong.remove(card);
|
||||
player[player.storage.rezhengrong.length>0?'markSkill':'unmarkSkill']('rezhengrong');
|
||||
player.loseToDiscardpile(card);
|
||||
'step 1'
|
||||
if(target.countDiscardableCards(player,'ej')>0){
|
||||
player.discardPlayerCard('ej',true,target);
|
||||
|
@ -11926,31 +11925,32 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
else event.finish();
|
||||
'step 3'
|
||||
target.addSkill('reshanxi2');
|
||||
target.storage.reshanxi2.addArray(result.cards);
|
||||
target.lose(result.cards,ui.special,'toStorage');
|
||||
game.log(target,'失去了'+get.cnNumber(result.cards.length)+'张牌');
|
||||
target.markSkill('reshanxi2');
|
||||
target.addToExpansion(result.cards,'giveAuto',target).gaintag.add('reshanxi2');
|
||||
},
|
||||
},
|
||||
reshanxi2:{
|
||||
init:function(player,skill){
|
||||
if(!player.storage[skill]) player.storage[skill]=[];
|
||||
},
|
||||
trigger:{global:'phaseEnd'},
|
||||
forced:true,
|
||||
popup:false,
|
||||
charlotte:true,
|
||||
filter:function(event,player){
|
||||
return player.storage.reshanxi2&&player.storage.reshanxi2.length>0;
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
content:function(){
|
||||
game.log(player,'收回了'+get.cnNumber(player.gain(player.storage.reshanxi2,'draw','fromStorage').cards.length)+'张〖闪袭〗牌');
|
||||
player.storage.reshanxi2.length=0;
|
||||
'step 0'
|
||||
var cards=player.getExpansions('reshanxi2');
|
||||
if(cards.length) player.gain(cards,'draw');
|
||||
'step 1'
|
||||
player.removeSkill('reshanxi2');
|
||||
},
|
||||
intro:{
|
||||
onunmark:'throw',
|
||||
content:'cardCount',
|
||||
markcount:'expansion',
|
||||
mark:function(dialog,storage,player){
|
||||
var cards=player.getExpansions('reshanxi2');
|
||||
if(player.isUnderControl(true)) dialog.addAuto(cards);
|
||||
else return '共有'+get.cnNumber(cards.length)+'张牌';
|
||||
},
|
||||
},
|
||||
},
|
||||
reqizhou:{
|
||||
|
@ -12175,9 +12175,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
if(result.bool){
|
||||
player.logSkill('xinqingjian');
|
||||
player.addSkill('xinqingjian2');
|
||||
player.storage.xinqingjian2.addArray(result.cards);
|
||||
game.log(player,'将'+get.cnNumber(player.lose(result.cards,ui.special,'toStorage').cards.length)+'张牌置于其武将牌上');
|
||||
player.markSkill('xinqingjian2');
|
||||
player.addToExpansion(result.cards,'giveAuto',player).gaintag.add('xinqingjian2');
|
||||
}
|
||||
else player.storage.counttrigger.xinqingjian--;
|
||||
},
|
||||
|
@ -12188,42 +12186,32 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{global:'phaseEnd'},
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
return player.storage.xinqingjian2&&player.storage.xinqingjian2.length>0;
|
||||
return player.getExpansions('xinqingjian2').length>0;
|
||||
},
|
||||
init:function(player){
|
||||
if(!player.storage.xinqingjian2) player.storage.xinqingjian2=[];
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.chooseTarget(true,lib.filter.notMe).set('createDialog',['清俭:选择一名角色获得这些牌'+(player.storage.xinqingjian2.length>1?',然后摸一张牌':''),player.storage.xinqingjian2]);
|
||||
var cards=player.getExpansions('xinqingjian2');
|
||||
player.chooseTarget(true,lib.filter.notMe).set('createDialog',['清俭:选择一名角色获得这些牌'+(cards.length>1?',然后摸一张牌':''),cards]);
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
var target=result.targets[0];
|
||||
player.line(target,'thunder');
|
||||
if(target.gain(player.storage.xinqingjian2,player,'giveAuto','fromStorage').cards.length>1) player.draw();
|
||||
player.storage.xinqingjian2.length=0;
|
||||
player.removeSkill('xinqingjian2');
|
||||
if(target.gain(player.getExpansions('xinqingjian2'),player,'giveAuto').cards.length>1) player.draw();
|
||||
}
|
||||
'step 2'
|
||||
player.removeSkill('xinqingjian2');
|
||||
},
|
||||
intro:{
|
||||
onunmark:'throw',mark:function(dialog,content,player){
|
||||
if(content&&content.length){
|
||||
if(player==game.me||player.isUnderControl()){
|
||||
dialog.addAuto(content);
|
||||
}
|
||||
else{
|
||||
return '共有'+get.cnNumber(content.length)+'张牌';
|
||||
}
|
||||
}
|
||||
markcount:'expansion',
|
||||
mark:function(dialog,storage,player){
|
||||
var cards=player.getExpansions('xinqingjian2');
|
||||
if(player.isUnderControl(true)) dialog.addAuto(cards);
|
||||
else return '共有'+get.cnNumber(cards.length)+'张牌';
|
||||
},
|
||||
content:function(content,player){
|
||||
if(content&&content.length){
|
||||
if(player==game.me||player.isUnderControl()){
|
||||
return get.translation(content);
|
||||
}
|
||||
return '共有'+get.cnNumber(content.length)+'张牌';
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
zhongzuo:{
|
||||
|
@ -12681,60 +12669,56 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
rebiaozhao:{
|
||||
audio:'biaozhao',
|
||||
intro:{
|
||||
content:"cards",
|
||||
content:"expansion",
|
||||
markcount:'expansion',
|
||||
},
|
||||
trigger:{
|
||||
player:"phaseJieshuBegin",
|
||||
},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
return player.countCards('he')>0&&!player.storage.rebiaozhao;
|
||||
return player.countCards('he')>0&&!player.getExpansions('rebiaozhao').length;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.chooseCard('he',get.prompt2('rebiaozhao')).ai=function(card){
|
||||
player.chooseCard('he',get.prompt('rebiaozhao'),'将一张牌置于武将牌上作为“表”').ai=function(card){
|
||||
return 6-get.value(card);
|
||||
}
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
player.addSkill('rebiaozhao2');
|
||||
player.addSkill('rebiaozhao3');
|
||||
player.logSkill('rebiaozhao');
|
||||
player.$give(result.cards,player,false);
|
||||
player.lose(result.cards,ui.special,'toStorage','visible');
|
||||
player.storage.rebiaozhao=result.cards;
|
||||
player.markSkill('rebiaozhao');
|
||||
player.addToExpansion(player,'give',result.cards).gaintag.add('rebiaozhao');
|
||||
}
|
||||
},
|
||||
ai:{notemp:true},
|
||||
},
|
||||
"rebiaozhao2":{
|
||||
trigger:{
|
||||
global:["loseEnd","cardsDiscardEnd"],
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
ai:{notemp:true},
|
||||
group:['rebiaozhao2','rebiaozhao3'],
|
||||
},
|
||||
rebiaozhao2:{
|
||||
trigger:{
|
||||
global:["loseAfter","cardsDiscardAfter"],
|
||||
},
|
||||
charlotte:true,
|
||||
forced:true,
|
||||
audio:"biaozhao",
|
||||
filter:function(event,player){
|
||||
if(!player.storage.rebiaozhao) return false;
|
||||
var num=get.number(player.storage.rebiaozhao[0]);
|
||||
if(event.name=='lose'&&(event.position!=ui.discardPile||event.getParent(2).name=='rebiaozhao3')) return false;
|
||||
var cards=player.getExpansions('rebiaozhao');
|
||||
if(!cards.length) return false;
|
||||
var num=get.number(cards[0]);
|
||||
for(var i=0;i<event.cards.length;i++){
|
||||
if(get.position(event.cards[i],true)=='d'&&get.number(event.cards[i])==num) return true;
|
||||
if(get.number(event.cards[i])==num) return true;
|
||||
}
|
||||
return false;
|
||||
},
|
||||
content:function(){
|
||||
"step 0"
|
||||
var card=player.storage.rebiaozhao[0];
|
||||
delete player.storage.rebiaozhao;
|
||||
player.$throw(card);
|
||||
game.cardsDiscard(card);
|
||||
"step 1"
|
||||
player.unmarkSkill('rebiaozhao');
|
||||
player.loseToDiscardpile(player.getExpansions('rebiaozhao'));
|
||||
player.loseHp();
|
||||
},
|
||||
},
|
||||
"rebiaozhao3":{
|
||||
rebiaozhao3:{
|
||||
trigger:{
|
||||
player:"phaseZhunbeiBegin",
|
||||
},
|
||||
|
@ -12742,14 +12726,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
charlotte:true,
|
||||
audio:"biaozhao",
|
||||
filter:function(event,player){
|
||||
return player.storage.rebiaozhao!=undefined;
|
||||
return player.getExpansions('rebiaozhao').length>0;
|
||||
},
|
||||
content:function(){
|
||||
"step 0"
|
||||
var card=player.storage.rebiaozhao[0];
|
||||
delete player.storage.rebiaozhao;
|
||||
player.unmarkSkill('rebiaozhao');
|
||||
game.cardsDiscard(card);
|
||||
player.loseToDiscardpile(player.getExpansions('rebiaozhao'));
|
||||
"step 1"
|
||||
player.chooseTarget('令一名角色摸三张牌并回复1点体力',true).ai=function(target){
|
||||
var num=2;
|
||||
if(target.isDamaged()) num++;
|
||||
|
@ -13488,50 +13470,37 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
else trigger.cancel();
|
||||
},
|
||||
},
|
||||
"xinfu_zhaoxin":{
|
||||
xinfu_zhaoxin:{
|
||||
group:["zhaoxin_give"],
|
||||
intro:{
|
||||
content:"cards",
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
},
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
enable:"phaseUse",
|
||||
usable:1,
|
||||
audio:2,
|
||||
init:function(player,skill){
|
||||
if(!player.storage[skill]) player.storage[skill]=[];
|
||||
},
|
||||
filter:function(event,player){
|
||||
return player.storage.xinfu_zhaoxin.length<3&&player.countCards('h')>0;
|
||||
return player.countCards('h')>0&&player.getExpansions('xinfu_zhaoxin').length<3;
|
||||
},
|
||||
visible:true,
|
||||
filterCard:true,
|
||||
selectCard:function(){
|
||||
var player=_status.event.player;
|
||||
return [1,3-player.storage.xinfu_zhaoxin.length];
|
||||
return [1,3-player.getExpansions('xinfu_zhaoxin').length];
|
||||
},
|
||||
discard:false,
|
||||
toStorage:true,
|
||||
//lose:false,
|
||||
lose:false,
|
||||
delay:false,
|
||||
content:function(){
|
||||
'step 0'
|
||||
//player.lose(cards,ui.special,'toStorage')
|
||||
player.$give(cards,player,false);
|
||||
player.storage.xinfu_zhaoxin=player.storage.xinfu_zhaoxin.concat(cards);
|
||||
player.markSkill('xinfu_zhaoxin');
|
||||
'step 1'
|
||||
player.addToExpansion(player,'give',cards).gaintag.add('xinfu_zhaoxin');
|
||||
player.draw(cards.length);
|
||||
},
|
||||
check:function(card){
|
||||
return 6-get.value(card);
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
ai:{
|
||||
order:1,
|
||||
result:{
|
||||
|
@ -13539,18 +13508,18 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
},
|
||||
},
|
||||
"zhaoxin_give":{
|
||||
zhaoxin_give:{
|
||||
trigger:{
|
||||
global:"phaseDrawAfter",
|
||||
},
|
||||
filter:function(event,player){
|
||||
if(!player.storage.xinfu_zhaoxin||!player.storage.xinfu_zhaoxin.length) return false;
|
||||
if(!player.getExpansions('xinfu_zhaoxin').length) return false;
|
||||
return player==event.player||player.inRange(event.player);
|
||||
},
|
||||
direct:true,
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.chooseCardButton(get.prompt('xinfu_zhaoxin',trigger.player),player.storage.xinfu_zhaoxin,function(button){
|
||||
player.chooseCardButton(get.prompt('xinfu_zhaoxin',trigger.player),player.getExpansions('xinfu_zhaoxin'),function(button){
|
||||
return true;
|
||||
}).set('ai',function(button){
|
||||
return 1+Math.random();
|
||||
|
@ -13569,11 +13538,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
};
|
||||
'step 3'
|
||||
if(result.bool){
|
||||
player.storage.xinfu_zhaoxin.remove(event.card);
|
||||
player.$give(event.card,trigger.player);
|
||||
trigger.player.gain(event.card,'fromStorage');
|
||||
if(player.storage.xinfu_zhaoxin.length) player.markSkill('xinfu_zhaoxin');
|
||||
else player.unmarkSkill('xinfu_zhaoxin');
|
||||
trigger.player.gain(event.card,'give',player);
|
||||
player.chooseBool('是否对'+get.translation(trigger.player)+'造成一点伤害?').ai=function(){
|
||||
return get.damageEffect(trigger.player,player,player)>0
|
||||
};
|
||||
|
@ -14746,34 +14711,36 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{player:'phaseDrawBegin2'},
|
||||
frequent:true,
|
||||
preHidden:true,
|
||||
locked:false,
|
||||
filter:function(event,player){
|
||||
if(event.numFixed||player.storage.tunchu&&player.storage.tunchu.length) return false;
|
||||
if(event.numFixed||player.getExpansions('tunchu').length) return false;
|
||||
return true;
|
||||
},
|
||||
content:function(){
|
||||
trigger.num+=2;
|
||||
player.addTempSkill('tunchu_choose','phaseDrawAfter');
|
||||
},
|
||||
init:function(player){
|
||||
if(!player.storage.tunchu) player.storage.tunchu=[];
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
mod:{
|
||||
cardEnabled:function(card,player){
|
||||
if(player.getExpansions('tunchu').length&&card.name=='sha'){
|
||||
return false;
|
||||
}
|
||||
},
|
||||
},
|
||||
group:'tunchu_disable',
|
||||
subSkill:{
|
||||
choose:{
|
||||
trigger:{player:'phaseDrawEnd'},
|
||||
forced:true,
|
||||
popup:false,
|
||||
charlotte:true,
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.removeSkill('tunchu_choose');
|
||||
|
@ -14793,27 +14760,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
player.lose(result.cards,ui.special,'toStorage');
|
||||
player.storage.tunchu.addArray(result.cards);
|
||||
player.markSkill('tunchu');
|
||||
player.syncStorage('tunchu');
|
||||
player.addToExpansion(result.cards,player,'giveAuto').gaintag.add('tunchu');
|
||||
}
|
||||
}
|
||||
},
|
||||
disable:{
|
||||
mod:{
|
||||
cardEnabled:function(card,player){
|
||||
if(player.storage.tunchu&&player.storage.tunchu.length&&card.name=='sha'){
|
||||
return false;
|
||||
}
|
||||
},
|
||||
cardUsable:function(card,player){
|
||||
if(player.storage.tunchu&&player.storage.tunchu.length&&card.name=='sha'){
|
||||
return false;
|
||||
}
|
||||
},
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
shuliang:{
|
||||
|
@ -14821,28 +14771,23 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{global:'phaseJieshuBegin'},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
return player.storage.tunchu&&player.storage.tunchu.length>0&&event.player.countCards('h')<event.player.hp&&event.player.isAlive();
|
||||
return player.getExpansions('tunchu').length>0&&event.player.countCards('h')<event.player.hp&&event.player.isAlive();
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
var goon=(get.attitude(player,trigger.player)>0);
|
||||
player.chooseCardButton(get.prompt('shuliang',trigger.player),player.storage.tunchu).set('ai',function(){
|
||||
player.chooseCardButton(get.prompt('shuliang',trigger.player),player.getExpansions('tunchu')).set('ai',function(){
|
||||
if(_status.event.goon) return 1;
|
||||
return 0;
|
||||
}).set('goon',goon);
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
player.logSkill('shuliang',trigger.player);
|
||||
player.storage.tunchu.remove(result.links[0]);
|
||||
player.$throw(result.links);
|
||||
game.cardsDiscard(result.links);
|
||||
player.syncStorage('tunchu');
|
||||
if(player.storage.tunchu.length==0){
|
||||
player.unmarkSkill('tunchu');
|
||||
}
|
||||
player.loseToDiscardpile(result.links);
|
||||
trigger.player.draw(2);
|
||||
}
|
||||
}
|
||||
},
|
||||
ai:{combo:'tunchu'},
|
||||
},
|
||||
choulve:{
|
||||
audio:2,
|
||||
|
@ -16358,7 +16303,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
bingqing:'秉清',
|
||||
bingqing_info:'当你于出牌阶段内使用的牌结算结束后,若你于本阶段内使用的所有其他牌与此牌花色均不相同,则你可根据X的值执行对应效果:为2,你令一名角色摸两张牌;为3,你弃置一名角色区域内的一张牌;为4,你对一名其他角色造成1点伤害。(X为你本阶段内使用过的牌中包含的花色数)',
|
||||
yingfeng:'迎奉',
|
||||
yingfeng_info:'准备阶段,你可以令一名角色获得“奉”标记并移除场上所有其他的“奉”标记。有“奉”标记的角色使用牌没有次数限制。',
|
||||
yingfeng_info:'准备阶段,你可以令一名角色获得“奉”标记并移除场上所有其他的“奉”标记。有“奉”标记的角色使用牌没有距离限制。',
|
||||
xin_sunxiu:'手杀孙休',
|
||||
mobileyanzhu:'宴诛',
|
||||
mobileyanzhu_info:'出牌阶段限一次,你可以令一名有牌的其他角色选择一项:①你获得其装备区里所有的牌,然后你失去技能〖宴诛〗。②你获得其一张牌。',
|
||||
|
|
|
@ -82,7 +82,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
"old_guhuo":{
|
||||
group:["old_guhuo_guess","old_guhuo_respond","old_guhuo_wuxie"],
|
||||
enable:"chooseToUse",
|
||||
filter:function (event,player){
|
||||
filter:function(event,player){
|
||||
if(!player.countCards('hs')) return false;
|
||||
var list=['sha','tao','shan','jiu','taoyuan','wugu','juedou','huogong','jiedao','tiesuo','guohe','shunshou','wuzhong','wanjian','nanman'];
|
||||
if(get.mode()=='guozhan'){
|
||||
|
@ -94,7 +94,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
return false;
|
||||
},
|
||||
chooseButton:{
|
||||
dialog:function (){
|
||||
dialog:function(){
|
||||
var list=[];
|
||||
for(var i=0;i<lib.inpile.length;i++){
|
||||
var name=lib.inpile[i];
|
||||
|
@ -110,14 +110,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
return ui.create.dialog('蛊惑',[list,'vcard']);
|
||||
},
|
||||
filter:function (button,player){
|
||||
filter:function(button,player){
|
||||
var evt=_status.event.getParent();
|
||||
if(evt&&evt.filterCard){
|
||||
return evt.filterCard({name:button.link[2]},player,evt);
|
||||
}
|
||||
return true;
|
||||
},
|
||||
backup:function (links,player){
|
||||
backup:function(links,player){
|
||||
return {
|
||||
filterCard:true,
|
||||
selectCard:1,
|
||||
|
@ -125,7 +125,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
viewAs:{name:links[0][2],nature:links[0][3]},
|
||||
}
|
||||
},
|
||||
prompt:function (links,player){
|
||||
prompt:function(links,player){
|
||||
return '将一张手牌当'+get.translation(links[0][2])+'使用';
|
||||
},
|
||||
},
|
||||
|
@ -136,13 +136,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{
|
||||
player:"useCardBefore",
|
||||
},
|
||||
filter:function (event,player){
|
||||
filter:function(event,player){
|
||||
return event.skill=="old_guhuo_backup"||event.skill=="old_guhuo_wuxie";
|
||||
},
|
||||
forced:true,
|
||||
direct:true,
|
||||
priority:15,
|
||||
content:function (){
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.logSkill('old_guhuo_guess');
|
||||
player.popup(trigger.card.name,'metal');
|
||||
|
@ -206,14 +206,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{
|
||||
player:"chooseToRespondBegin",
|
||||
},
|
||||
filter:function (event,player){
|
||||
filter:function(event,player){
|
||||
if(event.responded) return false;
|
||||
if(!event.filterCard({name:'shan'})&&!event.filterCard({name:'sha'})) return false;
|
||||
if(!player.countCards('h')) return false;
|
||||
return true;
|
||||
},
|
||||
direct:true,
|
||||
content:function (){
|
||||
content:function(){
|
||||
'step 0'
|
||||
if(trigger.filterCard({name:'shan'})&&lib.filter.cardRespondable({name:'shan'},player,trigger)) event.name='shan';
|
||||
else event.name='sha';
|
||||
|
@ -294,7 +294,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
popup:false,
|
||||
enable:"chooseToUse",
|
||||
filterCard:true,
|
||||
viewAsFilter:function (player){
|
||||
viewAsFilter:function(player){
|
||||
return player.countCards('hs')>0;
|
||||
},
|
||||
viewAs:{
|
||||
|
@ -315,14 +315,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
enable:"phaseUse",
|
||||
usable:2,
|
||||
filterTarget:function (card,player,target){
|
||||
filterTarget:function(card,player,target){
|
||||
if(player==target) return false;
|
||||
var pos='he';
|
||||
if(player.hasSkill('old_zuilun_h')) pos='e';
|
||||
if(player.hasSkill('old_zuilun_e')) pos='h';
|
||||
return target.countGainableCards(player,pos)>0;
|
||||
},
|
||||
content:function (){
|
||||
content:function(){
|
||||
'step 0'
|
||||
var pos='he';
|
||||
if(player.hasSkill('old_zuilun_h')) pos='e';
|
||||
|
@ -349,35 +349,36 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
},
|
||||
},
|
||||
"old_jijun":{
|
||||
old_jijun:{
|
||||
marktext:"方",
|
||||
audio:"xinfu_jijun",
|
||||
intro:{
|
||||
content:"cards",
|
||||
content:"expansion",
|
||||
markcount:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
enable:"phaseUse",
|
||||
filterCard:true,
|
||||
selectCard:[1,Infinity],
|
||||
filter:function (event,player){
|
||||
filter:function(event,player){
|
||||
return player.countCards('h')>0;
|
||||
},
|
||||
check:function (card){
|
||||
check:function(card){
|
||||
var player=_status.event.player;
|
||||
if(player.storage.old_jijun&&(36-player.storage.old_jijun.length)<=player.countCards('h')) return 1;
|
||||
if((36-player.getExpansions('old_jijun').length)<=player.countCards('h')) return 1;
|
||||
return 5-get.value(card);
|
||||
},
|
||||
discard:false,
|
||||
lose:false,
|
||||
content:function (){
|
||||
player.lose(cards,ui.special,'toStorage');
|
||||
player.$give(cards,player);
|
||||
if(!player.storage.old_jijun) player.storage.old_jijun=[];
|
||||
player.storage.old_jijun.addArray(cards);
|
||||
player.markSkill('old_jijun');
|
||||
content:function(){
|
||||
player.addToExpansion(cards,player,'give').gaintag.add('old_jijun');
|
||||
},
|
||||
ai:{order:1,result:{player:1}},
|
||||
ai:{order:1,result:{player:1}},
|
||||
},
|
||||
"old_fangtong":{
|
||||
old_fangtong:{
|
||||
trigger:{
|
||||
player:"phaseJieshuBegin",
|
||||
},
|
||||
|
@ -385,12 +386,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
forced:true,
|
||||
skillAnimation:true,
|
||||
animationColor:'metal',
|
||||
filter:function (event,player){
|
||||
return (player.storage.old_jijun&&player.storage.old_jijun.length>35);
|
||||
filter:function(event,player){
|
||||
return (player.getExpansions('old_jijun').length>35);
|
||||
},
|
||||
content:function (){
|
||||
content:function(){
|
||||
var bool=false;
|
||||
if(player==game.me) bool=true;
|
||||
if(player==game.me||player.isFriendOf(game.me)) bool=true;
|
||||
else switch(get.mode()){
|
||||
case 'identity':{
|
||||
game.showIdentity();
|
||||
|
@ -400,25 +401,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
if(['zhu','zhong','mingzhong'].contains(id2)) bool=true;
|
||||
break;
|
||||
}
|
||||
else if(id1=='fan'){
|
||||
else if(id1=='fan'){
|
||||
if(id2=='fan') bool=true;
|
||||
break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 'guozhan':{
|
||||
if(game.me.isFriendOf(player)) bool=true;
|
||||
break;
|
||||
}
|
||||
case 'versus':{
|
||||
if(player.side==game.me.side) bool=true;
|
||||
break;
|
||||
}
|
||||
case 'boss':{
|
||||
if(player.side==game.me.side) bool=true;
|
||||
break;
|
||||
}
|
||||
default:{}
|
||||
}
|
||||
game.over(bool);
|
||||
},
|
||||
|
|
|
@ -1115,10 +1115,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
else event.goto(4);
|
||||
'step 3'
|
||||
if(result.bool&&result.cards&&result.cards.length){
|
||||
var card=result.cards[0];
|
||||
player.lose(card,ui.special,'toStorage');
|
||||
player.markAuto('xinquanji',result.cards);
|
||||
game.log(player,'将',card,'置于了武将牌上');
|
||||
player.addToExpansion(result.cards,'giveAuto',player).gaintag.add('xinquanji');
|
||||
}
|
||||
'step 4'
|
||||
if(event.count>0){
|
||||
|
@ -1132,13 +1129,17 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
},
|
||||
locked:false,
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:'throw',
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
mod:{
|
||||
maxHandcard:function(player,num){
|
||||
return num+player.getStorage('xinquanji').length;
|
||||
return num+player.getExpansions('xinquanji').length;
|
||||
},
|
||||
},
|
||||
ai:{
|
||||
|
@ -1168,7 +1169,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
skillAnimation:true,
|
||||
animationColor:'thunder',
|
||||
filter:function(event,player){
|
||||
return player.getStorage('xinquanji').length>2;
|
||||
return player.getExpansions('xinquanji').length>2;
|
||||
},
|
||||
content:function(){
|
||||
player.awakenSkill('xinzili');
|
||||
|
@ -1182,7 +1183,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:2,
|
||||
enable:'phaseUse',
|
||||
filter:function(event,player){
|
||||
return player.getStorage('xinquanji').length>0&&(!player.hasSkill('xinpaiyi_0')||!player.hasSkill('xinpaiyi_1'))
|
||||
return player.getExpansions('xinquanji').length>0&&(!player.hasSkill('xinpaiyi_0')||!player.hasSkill('xinpaiyi_1'))
|
||||
},
|
||||
chooseButton:{
|
||||
check:function(button){
|
||||
|
@ -1218,7 +1219,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
dialog.buttons.add(td);
|
||||
}
|
||||
dialog.content.appendChild(table);
|
||||
dialog.add(player.storage.xinquanji);
|
||||
dialog.add(player.getExpansions('xinquanji'));
|
||||
return dialog;
|
||||
},
|
||||
select:2,
|
||||
|
@ -1234,7 +1235,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
prompt:function(links,player){
|
||||
if(typeof links[0]=='object') links.reverse();
|
||||
var num=get.cnNumber(Math.max(1,player.storage.xinquanji.length-1)),card=get.translation(links[1]);
|
||||
var num=get.cnNumber(Math.max(1,player.getExpansions('xinquanji').length-1)),card=get.translation(links[1]);
|
||||
if(links[0]==0) return '移去'+card+'并令一名角色摸'+num+'张牌';
|
||||
return '移去'+card+'并对至多'+num+'名角色造成1点伤害';
|
||||
},
|
||||
|
@ -1256,13 +1257,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 0'
|
||||
player.addTempSkill('xinpaiyi_0','phaseUseEnd');
|
||||
var card=lib.skill.xinpaiyi_backup.card;
|
||||
player.unmarkAuto('xinquanji',[card]);
|
||||
game.log(card,'进入了弃牌堆');
|
||||
player.$throw(card,1000);
|
||||
game.delayx();
|
||||
game.cardsDiscard(card);
|
||||
player.loseToDiscardpile(card);
|
||||
'step 1'
|
||||
target.draw(Math.max(1,player.getStorage('xinquanji').length));
|
||||
target.draw(Math.max(1,player.getExpansions('xinquanji').length));
|
||||
},
|
||||
ai:{
|
||||
result:{
|
||||
|
@ -1283,18 +1280,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
multitarget:true,
|
||||
multiline:true,
|
||||
selectTarget:function(){
|
||||
return [1,Math.max(1,_status.event.player.storage.xinquanji.length-1)];
|
||||
return [1,Math.max(1,_status.event.player.getExpansions('xinquanji').length-1)];
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
targets.sortBySeat();
|
||||
player.addTempSkill('xinpaiyi_1','phaseUseEnd');
|
||||
var card=lib.skill.xinpaiyi_backup.card;
|
||||
player.unmarkAuto('xinquanji',[card]);
|
||||
game.log(card,'进入了弃牌堆');
|
||||
player.$throw(card,1000);
|
||||
game.delayx();
|
||||
game.cardsDiscard(card);
|
||||
player.loseToDiscardpile(card);
|
||||
'step 1'
|
||||
for(var i of targets) i.damage();
|
||||
},
|
||||
|
@ -1911,7 +1904,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
audioname:['re_chengpu'],
|
||||
check:function(event,player){
|
||||
return (event.baseDamage>1||player.getHistory('useCard').indexOf(event)==0)&&(player.hp>1||player.getStorage('rechunlao').length)&&game.hasPlayer(function(current){
|
||||
return (event.baseDamage>1||player.getHistory('useCard').indexOf(event)==0)&&(player.hp>1||player.getExpansions('rechunlao').length)&&game.hasPlayer(function(current){
|
||||
return !event.targets.contains(current)&&player.canUse(event.card,current)
|
||||
&&get.attitude(player,current)<0&&!current.hasShan()
|
||||
&&get.effect(current,{name:'sha',nature:'fire'},player,player)>0;
|
||||
|
@ -1980,11 +1973,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
content:function(){
|
||||
var cards=trigger.cards.filterInD();
|
||||
player.markAuto('rechunlao',cards);
|
||||
player.$gain2(cards,false);
|
||||
game.log(player,'将',cards,'放在了武将牌上');
|
||||
game.cardsGotoSpecial(cards);
|
||||
game.delay();
|
||||
player.addToExpansion('gain2',cards).gaintag.add('rechunlao');
|
||||
},
|
||||
},
|
||||
rezhongyong:{
|
||||
|
@ -2127,19 +2116,21 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 2'
|
||||
if(result.bool){
|
||||
var cs=result.cards;
|
||||
player.lose(cs,ui.special,'toStorage');
|
||||
player.markAuto('gzquanji',cs);
|
||||
game.log(player,'将',cs,'放在了武将牌上');
|
||||
player.addToExpansion(cs,player,'give').gaintag.add('gzquanji');
|
||||
}
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:'throw',
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
locked:false,
|
||||
mod:{
|
||||
maxHandcard:function(player,num){
|
||||
return num+player.getStorage('gzquanji').length;
|
||||
return num+player.getExpansions('gzquanji').length;
|
||||
},
|
||||
},
|
||||
},
|
||||
|
@ -2148,11 +2139,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
enable:'phaseUse',
|
||||
usable:1,
|
||||
filter:function(event,player){
|
||||
return player.getStorage('gzquanji').length>0&&!player.hasSkill('gzquanji2');
|
||||
return player.getExpansions('gzquanji').length>0&&!player.hasSkill('gzquanji2');
|
||||
},
|
||||
chooseButton:{
|
||||
dialog:function(event,player){
|
||||
return ui.create.dialog('排异',player.storage.gzquanji,'hidden')
|
||||
return ui.create.dialog('排异',player.getExpansions('gzquanji'),'hidden')
|
||||
},
|
||||
backup:function(links,player){
|
||||
return {
|
||||
|
@ -2167,7 +2158,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
order:10,
|
||||
result:{
|
||||
target:function(player,target){
|
||||
var num=player.getStorage('gzquanji').length-1;
|
||||
var num=player.getExpansions('gzquanji').length-1;
|
||||
if(num==0){
|
||||
if(target.countCards('h')>player.countCards('h')) return get.damageEffect(target,player,target);
|
||||
return 0;
|
||||
|
@ -2185,25 +2176,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
contentx:function(){
|
||||
"step 0"
|
||||
var card=lib.skill.gzpaiyi_backup.card;
|
||||
game.cardsDiscard(card);
|
||||
player.$throw(card);
|
||||
player.storage.gzquanji.remove(card);
|
||||
game.log(card,'进入了弃牌堆');
|
||||
if(!player.storage.gzquanji.length){
|
||||
player.unmarkSkill('gzquanji');
|
||||
}
|
||||
else{
|
||||
player.markSkill('gzquanji');
|
||||
}
|
||||
player.syncStorage('gzquanji');
|
||||
game.delayx();
|
||||
player.loseToDiscardpile(card);
|
||||
player.addTempSkill('gzquanji2');
|
||||
"step 1"
|
||||
var num=player.getStorage('gzquanji').length;
|
||||
var num=player.getExpansions('gzquanji').length;
|
||||
if(num) target.draw(Math.min(7,num));
|
||||
"step 2"
|
||||
if(target.countCards('h')>player.countCards('h')){
|
||||
target.damage();
|
||||
player.addTempSkill('gzquanji2');
|
||||
}
|
||||
},
|
||||
ai:{
|
||||
|
@ -2401,15 +2381,16 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 1'
|
||||
if(result.bool){
|
||||
player.logSkill('residi');
|
||||
var cards=result.cards;
|
||||
player.markAuto('residi',cards);
|
||||
game.log(player,'将',cards[0],'放在了武将牌上');
|
||||
player.lose(cards,ui.special,'toStorage');
|
||||
player.addToExpansion(result.cards,'give',player).gaintag.add('residi');
|
||||
}
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:true,
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
group:'residi_push',
|
||||
ai:{notemp:true},
|
||||
|
@ -2418,11 +2399,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{global:'phaseUseBegin'},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
return event.player!=player&&player.getStorage('residi').length>0;
|
||||
return event.player!=player&&player.getExpansions('residi').length>0;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.chooseButton([get.prompt('residi',trigger.player),player.getStorage('residi')]).set('ai',function(button){
|
||||
player.chooseButton([get.prompt('residi',trigger.player),player.getExpansions('residi')]).set('ai',function(button){
|
||||
var player=_status.event.player;
|
||||
var target=_status.event.getTrigger().player;
|
||||
if(get.attitude(player,target)>-1) return 0;
|
||||
|
@ -2446,10 +2427,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
var card=result.links[0];
|
||||
var target=trigger.player;
|
||||
player.logSkill('residi',target);
|
||||
player.unmarkAuto('residi',result.links);
|
||||
player.$throw(card,1000);
|
||||
game.log(player,'将',card,'置入了弃牌堆');
|
||||
game.cardsDiscard(card);
|
||||
player.loseToDiscardpile(card);
|
||||
var color=get.color(card,false);
|
||||
if(!target.storage.residi2) target.storage.residi2=[];
|
||||
target.storage.residi2.add(color);
|
||||
|
@ -3159,7 +3137,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audioname:['boss_lvbu3','re_heqi','xin_lingtong'],
|
||||
trigger:{
|
||||
player:['loseAfter','phaseDiscardEnd'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
|
@ -3263,10 +3241,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
olzaoxian:{
|
||||
inherit:'zaoxian',
|
||||
content:function(){
|
||||
player.awakenSkill('olzaoxian');
|
||||
player.loseMaxHp();
|
||||
player.addSkill('jixi');
|
||||
player.storage.olzaoxian=true;
|
||||
player.awakenSkill('olzaoxian');
|
||||
player.insertPhase();
|
||||
}
|
||||
},
|
||||
|
@ -3927,9 +3904,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
var target=trigger.target;
|
||||
player.logSkill('decadepojun',trigger.target);
|
||||
target.addSkill('decadepojun2');
|
||||
target.markAuto('decadepojun2',result.cards);
|
||||
target.lose(result.cards,ui.special,'toStorage');
|
||||
game.log(target,'失去了'+get.cnNumber(result.cards.length)+'张牌');;
|
||||
target.addToExpansion(result.cards,'giveAuto',target).gaintag.add('decadepojun2');
|
||||
}
|
||||
else event.finish();
|
||||
'step 2'
|
||||
|
@ -3950,11 +3925,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
if(draw) event.draw=true;
|
||||
'step 3'
|
||||
if(event.equip&&result.links&&result.links.length){
|
||||
trigger.target.unmarkAuto('decadepojun2',result.links);
|
||||
trigger.target.$throw(result.links,1000);
|
||||
game.log(player,'将',result.links,'置入了弃牌堆');
|
||||
game.cardsDiscard(result.links);
|
||||
if(!event.draw) game.delayx();
|
||||
trigger.target.loseToDiscardpile(result.links);
|
||||
}
|
||||
if(event.draw) player.draw();
|
||||
},
|
||||
|
@ -3970,24 +3941,28 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
},
|
||||
decadepojun2:{
|
||||
init:function(player,skill){
|
||||
if(!player.storage[skill]) player.storage[skill]=[];
|
||||
},
|
||||
trigger:{global:'phaseEnd'},
|
||||
forced:true,
|
||||
popup:false,
|
||||
charlotte:true,
|
||||
filter:function(event,player){
|
||||
return player.storage.decadepojun2&&player.storage.decadepojun2.length>0;
|
||||
return player.getExpansions('decadepojun2').length>0;
|
||||
},
|
||||
content:function(){
|
||||
game.log(player,'收回了'+get.cnNumber(player.gain(player.storage.decadepojun2,'draw','fromStorage').cards.length)+'张〖破军〗牌');
|
||||
player.storage.decadepojun2.length=0;
|
||||
'step 0'
|
||||
var cards=player.getExpansions('decadepojun2');
|
||||
player.gain(cards,'draw');
|
||||
game.log(player,'收回了'+get.cnNumber(cards.length)+'张“破军”牌');
|
||||
'step 1'
|
||||
player.removeSkill('decadepojun2');
|
||||
},
|
||||
intro:{
|
||||
onunmark:'throw',
|
||||
content:'cardCount',
|
||||
markcount:'expansion',
|
||||
mark:function(dialog,storage,player){
|
||||
var cards=player.getExpansions('decadepojun2');
|
||||
if(player.isUnderControl(true)) dialog.addAuto(cards);
|
||||
else return '共有'+get.cnNumber(cards.length)+'张牌';
|
||||
},
|
||||
},
|
||||
},
|
||||
hanzhan:{
|
||||
|
@ -4511,7 +4486,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audioname:['boss_lvbu3','re_heqi','re_lingtong'],
|
||||
trigger:{
|
||||
player:['loseAfter','phaseDiscardEnd'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
|
@ -4699,18 +4674,15 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
direct:true,
|
||||
audio:2,
|
||||
filter:function(event,player){
|
||||
return player.countCards('h')>0&&(_status.connectMode||player.countCards('h','sha')>0)&&!player.getStorage('rechunlao').length;
|
||||
return player.countCards('h')>0&&(_status.connectMode||player.countCards('h','sha')>0)&&!player.getExpansions('rechunlao').length;
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
},
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
|
@ -4720,9 +4692,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 1'
|
||||
if(result.bool){
|
||||
player.logSkill('rechunlao');
|
||||
player.markAuto('rechunlao',result.cards);
|
||||
player.lose(result.cards,ui.special,'toStorage');
|
||||
player.$give(result.cards,player,false);
|
||||
player.addToExpansion('gain2',result.cards).gaintag.add('rechunlao');
|
||||
}
|
||||
},
|
||||
ai:{
|
||||
|
@ -4733,7 +4703,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
rechunlao2:{
|
||||
enable:'chooseToUse',
|
||||
filter:function(event,player){
|
||||
return event.type=='dying'&&event.dying&&event.dying.hp<=0&&player.getStorage('rechunlao').length>0;
|
||||
return event.type=='dying'&&event.dying&&event.dying.hp<=0&&player.getExpansions('rechunlao').length>0;
|
||||
},
|
||||
filterTarget:function(card,player,target){
|
||||
return target==_status.event.dying;
|
||||
|
@ -4743,22 +4713,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
selectTarget:-1,
|
||||
content:function(){
|
||||
"step 0"
|
||||
player.chooseCardButton(get.translation('rechunlao'),player.storage.rechunlao,true);
|
||||
player.chooseCardButton(get.translation('rechunlao'),player.getExpansions('rechunlao'),true);
|
||||
"step 1"
|
||||
if(result.bool){
|
||||
player.logSkill('rechunlao');
|
||||
player.$throw(result.links);
|
||||
player.storage.rechunlao.remove(result.links[0]);
|
||||
game.cardsDiscard(result.links[0]);
|
||||
player.syncStorage('rechunlao')
|
||||
event.type='dying';
|
||||
player.loseToDiscardpile(result.links);
|
||||
target.useCard({name:'jiu',isCard:true},target);
|
||||
if(!player.storage.rechunlao.length){
|
||||
player.unmarkSkill('rechunlao');
|
||||
}
|
||||
else{
|
||||
player.markSkill('rechunlao');
|
||||
}
|
||||
var nature=get.nature(result.links[0]);
|
||||
if(nature=='fire') player.recover();
|
||||
if(nature=='thunder') player.draw(2);
|
||||
|
@ -4767,7 +4728,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
ai:{
|
||||
order:6,
|
||||
skillTagFilter:function(player){
|
||||
return player.getStorage('rechunlao').length>0;
|
||||
return player.getExpansions('rechunlao').length>0;
|
||||
},
|
||||
save:true,
|
||||
result:{
|
||||
|
@ -5546,12 +5507,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 1'
|
||||
if(result.bool){
|
||||
var target=trigger.target;
|
||||
player.logSkill('repojun',trigger.target);
|
||||
player.logSkill('repojun',target);
|
||||
target.addSkill('repojun2');
|
||||
target.storage.repojun2.addArray(result.cards);
|
||||
target.lose(result.cards,ui.special,'toStorage');
|
||||
game.log(target,'失去了'+get.cnNumber(result.cards.length)+'张牌');
|
||||
target.markSkill('repojun2');
|
||||
target.addToExpansion('giveAuto',result.cards,target).gaintag.add('repojun2');
|
||||
}
|
||||
},
|
||||
ai:{
|
||||
|
@ -5581,24 +5539,28 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
},
|
||||
repojun2:{
|
||||
init:function(player,skill){
|
||||
if(!player.storage[skill]) player.storage[skill]=[];
|
||||
},
|
||||
trigger:{global:'phaseEnd'},
|
||||
forced:true,
|
||||
popup:false,
|
||||
charlotte:true,
|
||||
filter:function(event,player){
|
||||
return player.storage.repojun2&&player.storage.repojun2.length>0;
|
||||
return player.getExpansions('repojun2').length>0;
|
||||
},
|
||||
content:function(){
|
||||
game.log(player,'收回了'+get.cnNumber(player.gain(player.storage.repojun2,'draw','fromStorage').cards.length)+'张〖破军〗牌');
|
||||
player.storage.repojun2.length=0;
|
||||
'step 0'
|
||||
var cards=player.getExpansions('repojun2');
|
||||
player.gain(cards,'draw');
|
||||
game.log(player,'收回了'+get.cnNumber(cards.length)+'张“破军”牌');
|
||||
'step 1'
|
||||
player.removeSkill('repojun2');
|
||||
},
|
||||
intro:{
|
||||
onunmark:'throw',
|
||||
content:'cardCount',
|
||||
markcount:'expansion',
|
||||
mark:function(dialog,storage,player){
|
||||
var cards=player.getExpansions('repojun2');
|
||||
if(player.isUnderControl(true)) dialog.addAuto(cards);
|
||||
else return '共有'+get.cnNumber(cards.length)+'张牌';
|
||||
},
|
||||
},
|
||||
},
|
||||
reganlu:{
|
||||
|
@ -8845,27 +8807,23 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
},
|
||||
reqianxun:{
|
||||
init:function(player){
|
||||
if(!player.storage.reqianxun2) player.storage.reqianxun2=[];
|
||||
},
|
||||
audio:2,
|
||||
trigger:{target:'useCardToBegin',player:'judgeBefore'},
|
||||
trigger:{
|
||||
target:'useCardToBegin',
|
||||
player:'judgeBefore',
|
||||
},
|
||||
filter:function(event,player){
|
||||
if(player.countCards('h')==0) return false;
|
||||
if(event.parent.name=='phaseJudge'){
|
||||
if(lib.skill.reqianxun.trigger.player=='judgeBefore'){
|
||||
return true;
|
||||
}
|
||||
return event.result&&event.result.judge!=0;
|
||||
if(event.getParent().name=='phaseJudge'){
|
||||
return true;
|
||||
}
|
||||
if(event.name=='judge') return false;
|
||||
if(event.targets&&event.targets.length>1) return false;
|
||||
if(event.card&&get.type(event.card)=='trick'&&event.player!=player) return true;
|
||||
},
|
||||
content:function(){
|
||||
player.storage.reqianxun2=player.storage.reqianxun2.concat(player.getCards('h'));
|
||||
game.addVideo('storage',player,['reqianxun2',get.cardsInfo(player.storage.reqianxun2),'cards']);
|
||||
player.lose(player.getCards('h'),ui.special,'toStorage');
|
||||
var cards=player.getCards('h');
|
||||
player.addToExpansion(cards,'giveAuto',player).gaintag.add('reqianxun2');
|
||||
player.addSkill('reqianxun2');
|
||||
},
|
||||
ai:{
|
||||
|
@ -8893,29 +8851,24 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
forced:true,
|
||||
audio:false,
|
||||
content:function(){
|
||||
player.gain(player.storage.reqianxun2,'fromStorage','draw');
|
||||
player.storage.reqianxun2.length=0;
|
||||
var cards=player.getExpansions('reqianxun2');
|
||||
if(cards.length) player.gain(cards,'draw');
|
||||
player.removeSkill('reqianxun2');
|
||||
game.addVideo('storage',player,['reqianxun2',get.cardsInfo(player.storage.reqianxun2),'cards']);
|
||||
},
|
||||
mark:true,
|
||||
intro:{
|
||||
content:'cardCount',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
player.storage.reqianxun2.length=0;
|
||||
}
|
||||
mark:function(dialog,storage,player){
|
||||
var cards=player.getExpansions('reqianxun2');
|
||||
if(player.isUnderControl(true)) dialog.addAuto(cards);
|
||||
else return '共有'+get.cnNumber(cards.length)+'张牌';
|
||||
},
|
||||
markcount:'expansion',
|
||||
}
|
||||
},
|
||||
relianying:{
|
||||
audio:2,
|
||||
trigger:{
|
||||
player:'loseAfter',
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
|
@ -9924,7 +9877,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:2,
|
||||
trigger:{
|
||||
player:'loseAfter',
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
frequent:true,
|
||||
filter:function(event,player){
|
||||
|
@ -9940,40 +9893,22 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
callback:function(){
|
||||
'step 0'
|
||||
if(event.judgeResult.suit=='heart'){
|
||||
player.gain(card,'gain2');
|
||||
event.finish();
|
||||
}
|
||||
else if(get.mode()=='guozhan'){
|
||||
player.chooseBool('是否将'+get.translation(card)+'作为【田】置于武将牌上?').set('frequentSkill','retuntian').ai=function(){
|
||||
return true;
|
||||
};
|
||||
}
|
||||
else event.directbool=true;
|
||||
'step 1'
|
||||
if(!result.bool&&!event.directbool){
|
||||
//game.cardsDiscard(card);
|
||||
return;
|
||||
if(event.judgeResult.suit=='heart'){
|
||||
player.gain(card,'gain2');
|
||||
event.finish();
|
||||
}
|
||||
else if(get.mode()=='guozhan'){
|
||||
player.chooseBool('是否将'+get.translation(card)+'作为【田】置于武将牌上?').set('frequentSkill','retuntian').ai=function(){
|
||||
return true;
|
||||
};
|
||||
event.node=event.judgeResult.node;
|
||||
//event.trigger("addCardToStorage");
|
||||
//event.card.fix();
|
||||
player.storage.tuntian.push(event.card);
|
||||
//event.card.goto(ui.special);
|
||||
game.cardsGotoSpecial(card);
|
||||
event.node.moveDelete(player);
|
||||
game.broadcast(function(cardid,player){
|
||||
var node=lib.cardOL[cardid];
|
||||
if(node){
|
||||
node.moveDelete(player);
|
||||
}
|
||||
},event.node.cardid,player);
|
||||
game.addVideo('gain2',player,get.cardsInfo([event.node]));
|
||||
player.markSkill('tuntian');
|
||||
game.addVideo('storage',player,['tuntian',get.cardsInfo(player.storage.tuntian),'cards']);
|
||||
},
|
||||
init:function(player){
|
||||
if(!player.storage.tuntian) player.storage.tuntian=[];
|
||||
}
|
||||
else event.directbool=true;
|
||||
'step 1'
|
||||
if(!result.bool&&!event.directbool){
|
||||
//game.cardsDiscard(card);
|
||||
return;
|
||||
};
|
||||
player.addToExpansion(card,'gain2').gaintag.add('tuntian');
|
||||
},
|
||||
group:'tuntian_dist',
|
||||
locked:false,
|
||||
|
|
|
@ -172,20 +172,17 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 2'
|
||||
if(result.bool){
|
||||
var card=result.links[0];
|
||||
game.log(player,'选择了',card);
|
||||
target.$give(card,player,false);
|
||||
target.lose(card,ui.special,'toStorage');
|
||||
if(!player.storage.zhengrong) player.storage.zhengrong=[];
|
||||
player.storage.zhengrong.push(card);
|
||||
player.markSkill('zhengrong');
|
||||
player.addToExpansion(card,'give','log',target).gaintag.add('zhengrong');
|
||||
}
|
||||
'step 3'
|
||||
game.delayx();
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
marktext:'荣',
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:'throw',
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
},
|
||||
hongju:{
|
||||
|
@ -198,12 +195,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
animationColor:'thunder',
|
||||
derivation:'qingce',
|
||||
filter:function(event,player){
|
||||
return player.storage.zhengrong&&player.storage.zhengrong.length>=3;
|
||||
return player.getExpansions('zhengrong').length>=3;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.awakenSkill('hongju');
|
||||
var cards=player.getStorage('zhengrong');
|
||||
var cards=player.getExpansions('zhengrong');
|
||||
if(!cards.length||!player.countCards('h')){
|
||||
event.goto(2);
|
||||
return;
|
||||
|
@ -219,21 +216,17 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
next.set('processAI',function(list){
|
||||
var player=_status.event.player,cards=list[0][1].concat(list[1][1]).sort(function(a,b){
|
||||
return get.value(a)-get.value(b);
|
||||
}),cards2=cards.splice(0,player.storage.zhengrong.length);
|
||||
}),cards2=cards.splice(0,player.getExpansions('zhengrong').length);
|
||||
return [cards2,cards];
|
||||
});
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
var pushs=result.moved[0],gains=result.moved[1];
|
||||
pushs.removeArray(player.storage.zhengrong);
|
||||
pushs.removeArray(player.getExpansions('zhengrong'));
|
||||
gains.removeArray(player.getCards('h'));
|
||||
if(!pushs.length||pushs.length!=gains.length) return;
|
||||
player.lose(pushs,ui.special,'toStorage');
|
||||
game.log(player,'将',pushs,'作为“荣”置于武将牌上');
|
||||
player.gain(gains,'gain2','log','fromStorage');
|
||||
player.storage.zhengrong.addArray(pushs);
|
||||
player.storage.zhengrong.removeArray(gains);
|
||||
player.markSkill('zhengrong');
|
||||
player.addToExpansion(pushs).gaintag.add('zhengrong');
|
||||
player.gain(gains,'gain2','log');
|
||||
}
|
||||
'step 2'
|
||||
player.addSkill('qingce');
|
||||
|
@ -245,11 +238,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
enable:'phaseUse',
|
||||
audio:'drlt_qingce',
|
||||
filter:function(event,player){
|
||||
return player.storage.zhengrong&&player.storage.zhengrong.length>0&&player.countCards('h')>0;
|
||||
return player.getExpansions('zhengrong').length>0&&player.countCards('h')>0;
|
||||
},
|
||||
chooseButton:{
|
||||
dialog:function(event,player){
|
||||
return ui.create.dialog('请选择要获得的「荣」',player.storage.zhengrong,'hidden');
|
||||
return ui.create.dialog('请选择要获得的「荣」',player.getExpansions('zhengrong'),'hidden');
|
||||
},
|
||||
backup:function(links,player){
|
||||
return {
|
||||
|
@ -283,9 +276,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
contentx:function(){
|
||||
'step 0'
|
||||
var card=lib.skill.qingce_backup.card;
|
||||
player.gain(card,'gain2','log','fromStorage');
|
||||
player.storage.zhengrong.remove(card);
|
||||
player[player.storage.zhengrong.length>0?'markSkill':'unmarkSkill']('zhengrong');
|
||||
player.gain(card,'gain2','log');
|
||||
'step 1'
|
||||
if(target.countDiscardableCards(player,'ej')>0){
|
||||
player.discardPlayerCard('ej',true,target);
|
||||
|
@ -307,22 +298,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
//阴雷
|
||||
"drlt_zhenrong":{
|
||||
init:function(player,skill){
|
||||
if(!player.storage[skill]) player.storage.drlt_zhenrong=[];
|
||||
},
|
||||
marktext:"荣",
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
},
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
mark:true,
|
||||
audio:2,
|
||||
trigger:{
|
||||
source:'damageSource',
|
||||
|
@ -340,11 +320,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
if(result&&result.links&&result.links.length){
|
||||
player.line(player,trigger.player);
|
||||
player.logSkill('drlt_zhenrong');
|
||||
player.storage.drlt_zhenrong.push(result.links[0]);
|
||||
player.syncStorage('drlt_zhenrong');
|
||||
trigger.player.lose(result.links[0],ui.special,'toStorage');
|
||||
trigger.player.$give(result.links,player);
|
||||
game.log(player,'将',result.links[0],'置于其武将牌上');
|
||||
player.addToExpansion(result.links,trigger.player,'give','log').gaintag.add('drlt_zhengrong');
|
||||
};
|
||||
},
|
||||
},
|
||||
|
@ -359,48 +335,42 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
unique:true,
|
||||
juexingji:true,
|
||||
derivation:['drlt_qingce'],
|
||||
init:function(player){
|
||||
player.storage.drlt_hongju=false;
|
||||
},
|
||||
filter:function(event,player){
|
||||
return !player.storage.drlt_hongju&&player.storage.drlt_zhenrong&&player.storage.drlt_zhenrong.length>=3&&game.dead.length>0;
|
||||
return player.getExpansions('drlt_zhengrong').length>=3&&game.dead.length>0;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.awakenSkill('drlt_hongju'),
|
||||
player.storage.drlt_hongju=true;
|
||||
var num=player.storage.drlt_zhenrong.length;
|
||||
if(num>player.countCards('h')) num=player.countCards('h');
|
||||
player.chooseCard('h',[1,num],'请选择需要替换“荣”的手牌').set('ai',function(card){
|
||||
return 5-get.value(card);
|
||||
}).set('promptx',[player.storage.drlt_zhengrong]);
|
||||
player.awakenSkill('drlt_hongju');
|
||||
var cards=player.getExpansions('drlt_zhengrong');
|
||||
if(!cards.length||!player.countCards('h')){
|
||||
event.goto(2);
|
||||
return;
|
||||
}
|
||||
var next=player.chooseToMove('征荣:是否交换“荣”和手牌?');
|
||||
next.set('list',[
|
||||
[get.translation(player)+'(你)的“荣”',cards],
|
||||
['手牌区',player.getCards('h')],
|
||||
]);
|
||||
next.set('filterMove',function(from,to){
|
||||
return typeof to!='number';
|
||||
});
|
||||
next.set('processAI',function(list){
|
||||
var player=_status.event.player,cards=list[0][1].concat(list[1][1]).sort(function(a,b){
|
||||
return get.value(a)-get.value(b);
|
||||
}),cards2=cards.splice(0,player.getExpansions('drlt_zhengrong').length);
|
||||
return [cards2,cards];
|
||||
});
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
event.cards=result.cards;
|
||||
player.chooseCardButton(player.storage.drlt_zhenrong,result.cards.length,'请选择需要替换的“荣”',true).ai=function(button){
|
||||
return 6-get.value(button.link);
|
||||
};
|
||||
}else{
|
||||
player.addSkill('drlt_qingce');
|
||||
player.loseMaxHp();
|
||||
event.finish();
|
||||
};
|
||||
var pushs=result.moved[0],gains=result.moved[1];
|
||||
pushs.removeArray(player.getExpansions('drlt_zhengrong'));
|
||||
gains.removeArray(player.getCards('h'));
|
||||
if(!pushs.length||pushs.length!=gains.length) return;
|
||||
player.addToExpansion(pushs).gaintag.add('drlt_zhengrong');
|
||||
player.gain(gains,'gain2','log');
|
||||
}
|
||||
'step 2'
|
||||
if(result.bool){
|
||||
var cards=result.links;
|
||||
for(var i=0;i<event.cards.length;i++){
|
||||
player.storage.drlt_zhenrong.push(event.cards[i]);
|
||||
};
|
||||
player.syncStorage('drlt_zhenrong');
|
||||
player.lose(event.cards,ui.special,'toStorage');
|
||||
game.log(player,'将',event.cards,'置于其武将牌上');
|
||||
for(var i=0;i<cards.length;i++){
|
||||
player.storage.drlt_zhenrong.remove(cards[i]);
|
||||
};
|
||||
player.syncStorage('drlt_zhenrong');
|
||||
player.gain(cards,'gain2','fromStorage');
|
||||
};
|
||||
player.addSkill('drlt_qingce');
|
||||
player.addSkillLog('drlt_qingce');
|
||||
player.loseMaxHp();
|
||||
},
|
||||
},
|
||||
|
@ -1147,10 +1117,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
subSkill:{
|
||||
"1":{
|
||||
trigger:{
|
||||
global:["loseAfter","addCardToStorage","loseAsyncAfter"],
|
||||
global:["loseAfter","addToExpansionAfter","cardsGotoSpecialAfter",'loseAsyncAfter'],
|
||||
},
|
||||
filter:function(event,player,name){
|
||||
if(name!='addCardToStorage') return event.toStorage==true;
|
||||
if(event.name=='lose'||event.name=='loseAsync') return event.getlx!==false&&event.toStorage==true;
|
||||
if(event.name=='cardGotoSpecial') return !event.notrigger;
|
||||
return true;
|
||||
},
|
||||
direct:true,
|
||||
|
@ -1174,7 +1145,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
global:"gainAfter",
|
||||
},
|
||||
filter:function(event,player){
|
||||
return event.fromStorage==true;
|
||||
return event.fromStorage==true||game.hasPlayer2(function(current){
|
||||
var evt=event.getl(current);
|
||||
return evt&&evt.xs&&evt.xs.length>0;
|
||||
});
|
||||
},
|
||||
direct:true,
|
||||
content:function(){
|
||||
|
@ -1205,7 +1179,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.chooseCard(get.prompt2('kongsheng'),'he',[1,player.countCards('he')]).set('ai',function(card){
|
||||
player.chooseCard(get.prompt('kongsheng'),'将任意张牌置于武将牌上','he',[1,player.countCards('he')]).set('ai',function(card){
|
||||
if(get.position(card)=='e') return 1-get.value(card);
|
||||
if(card.name=='shan'||card.name=='du'||!player.hasValueTarget(card)) return 1;
|
||||
return 4-get.value(card);
|
||||
|
@ -1213,66 +1187,49 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 1'
|
||||
if(result.bool){
|
||||
player.logSkill('kongsheng');
|
||||
if(player.storage.kongsheng2==undefined) player.storage.kongsheng2=[];
|
||||
player.storage.kongsheng2.addArray(result.cards);
|
||||
player.lose(result.cards,ui.special,'toStorage');
|
||||
game.log(player,'将',result.cards,'置于其武将牌上');
|
||||
player.addSkill('kongsheng2');
|
||||
player.addToExpansion(result.cards,'log','give',player).gaintag.add('kongsheng2');
|
||||
}
|
||||
},
|
||||
},
|
||||
kongsheng_ai:{ai:{reverseOrder:true}},
|
||||
"kongsheng2":{
|
||||
kongsheng2:{
|
||||
audio:'kongsheng',
|
||||
marktext:"箜",
|
||||
intro:{
|
||||
content:"cards",
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
player.storage.kongsheng2.length=0;
|
||||
}
|
||||
},
|
||||
content:"expansion",
|
||||
markcount:'expansion',
|
||||
},
|
||||
mark:true,
|
||||
trigger:{
|
||||
player:"phaseJieshuBegin",
|
||||
},
|
||||
filter:function(event,player){
|
||||
return player.storage.kongsheng2!=undefined&&player.storage.kongsheng2.length>0;
|
||||
return player.getExpansions('kongsheng2').length>0;
|
||||
},
|
||||
forced:true,
|
||||
charlotte:true,
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.addTempSkill('kongsheng_ai','kongsheng2After');
|
||||
event.list=[];
|
||||
for(var i=0;i<player.storage.kongsheng2.length;i++){
|
||||
var card=player.storage.kongsheng2[i];
|
||||
if(get.type(card)=='equip'&&player.hasUseTarget(card)){
|
||||
event.list.push(card);
|
||||
player.storage.kongsheng2.splice(i--,1);
|
||||
}
|
||||
};
|
||||
if(!event.list.length) event.goto(3);
|
||||
'step 1'
|
||||
if(event.list.length==1){
|
||||
event._result={bool:true,links:event.list.slice(0)}
|
||||
var cards=player.getExpansions('kongsheng2').filter(function(i){
|
||||
return get.type(i,false)=='equip'&&player.hasUseTarget(i);
|
||||
});
|
||||
if(cards.length==1){
|
||||
event._result={bool:true,links:cards}
|
||||
}
|
||||
else player.chooseButton(true,['选择要使用的装备牌',event.list]).set('ai',function(button){
|
||||
else if(cards.length) player.chooseButton(true,['选择要使用的装备牌',cards]).set('ai',function(button){
|
||||
return get.order(button.link);
|
||||
});
|
||||
else event.goto(3);
|
||||
'step 2'
|
||||
if(result.bool){
|
||||
player.chooseUseTarget(result.links[0],true);
|
||||
event.list.remove(result.links[0]);
|
||||
if(event.list.length) event.goto(1);
|
||||
event.goto(1);
|
||||
}
|
||||
'step 3'
|
||||
if(player.storage.kongsheng2.length) player.gain(player.storage.kongsheng2,'gain2','fromStorage','log');
|
||||
player.storage.kongsheng2.length=0;
|
||||
player.removeSkill('kongsheng2');
|
||||
var cards=player.getExpansions('kongsheng2');
|
||||
if(cards.length) player.gain(cards,'gain2');
|
||||
},
|
||||
},
|
||||
|
||||
|
@ -1921,8 +1878,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:"nzry_mingren_1",
|
||||
marktext:"任",
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:'throw',
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
group:["nzry_mingren_1","nzry_mingren_2"],
|
||||
subSkill:{
|
||||
|
@ -1935,7 +1896,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
forced:true,
|
||||
locked:false,
|
||||
filter:function(event,player){
|
||||
return !player.getStorage('nzry_mingren').length&&(event.name!='phase'||game.phaseNumber==0);
|
||||
return (event.name!='phase'||game.phaseNumber==0)&&!player.getExpansions('nzry_mingren').length;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
|
@ -1947,9 +1908,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
});
|
||||
'step 2'
|
||||
if(result.bool){
|
||||
player.markAuto('nzry_mingren',result.cards);
|
||||
game.log(player,'将',result.cards[0],'置于其武将牌上');
|
||||
player.lose(result.cards[0],ui.special,'toStorage');
|
||||
player.addToExpansion(result.cards[0],player,'give','log').gaintag.add('nzry_mingren');
|
||||
};
|
||||
},
|
||||
},
|
||||
|
@ -1959,15 +1918,15 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
player:'phaseJieshuBegin',
|
||||
},
|
||||
filter:function(event,player){
|
||||
return player.countCards('h')>0&&player.getStorage('nzry_mingren').length>0;
|
||||
return player.countCards('h')>0&&player.getExpansions('nzry_mingren').length>0;
|
||||
},
|
||||
direct:true,
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.chooseCard('h','是否用一张手牌替换“任”('+get.translation(player.getStorage('nzry_mingren')[0])+')?').set('ai',function(card){
|
||||
player.chooseCard('h','是否用一张手牌替换“任”('+get.translation(player.getExpansions('nzry_mingren')[0])+')?').set('ai',function(card){
|
||||
var player=_status.event.player;
|
||||
var color=get.color(card);
|
||||
if(color==get.color(player.getStorage('nzry_mingren')[0])) return false;
|
||||
if(color==get.color(player.getExpansions('nzry_mingren')[0])) return false;
|
||||
var num=0;
|
||||
var list=[];
|
||||
player.countCards('h',function(cardx){
|
||||
|
@ -1985,15 +1944,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 1'
|
||||
if(result.bool){
|
||||
player.logSkill('nzry_mingren');
|
||||
game.log(player,'将',result.cards[0],'置于其武将牌上');
|
||||
player.lose(result.cards[0],ui.special,'toStorage');
|
||||
var card=player.getStorage('nzry_mingren')[0];
|
||||
if(card){
|
||||
player.gain(card,'gain2','fromStorage');
|
||||
player.storage.nzry_mingren.remove(card);
|
||||
player.storage.nzry_mingren.push(result.cards[0]);
|
||||
player.syncStorage('nzry_mingren');
|
||||
}
|
||||
player.addToExpansion(result.cards[0],'log','give',player).gaintag.add('nzry_mingren');
|
||||
var card=player.getExpansions('nzry_mingren')[0];
|
||||
if(card) player.gain(card,'gain2');
|
||||
};
|
||||
},
|
||||
},
|
||||
|
@ -2021,7 +1974,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
enable:'phaseUse',
|
||||
filter:function(event,player){
|
||||
if(player.storage.nzry_zhenliang==true) return false;
|
||||
var storage=player.getStorage('nzry_mingren');
|
||||
var storage=player.getExpansions('nzry_mingren');
|
||||
if(!storage.length) return false;
|
||||
var color=get.color(storage[0]);
|
||||
if(player.countCards('he',function(card){
|
||||
|
@ -2033,7 +1986,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
position:'he',
|
||||
filterCard:function(card,player){
|
||||
return get.color(card)==get.color(player.getStorage('nzry_mingren')[0]);
|
||||
return get.color(card)==get.color(player.getExpansions('nzry_mingren')[0]);
|
||||
},
|
||||
filterTarget:function(card,player,target){
|
||||
return player.inRange(target);
|
||||
|
@ -2061,7 +2014,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
filter:function(event,player){
|
||||
if(_status.currentPhase==player||player.storage.nzry_zhenliang!=true) return false;
|
||||
var card=player.getStorage('nzry_mingren')[0];
|
||||
var card=player.getExpansions('nzry_mingren')[0];
|
||||
return card&&get.color(event.card)==get.color(card);
|
||||
},
|
||||
direct:true,
|
||||
|
@ -3285,7 +3238,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audioname:['gz_dengai'],
|
||||
trigger:{
|
||||
player:'loseAfter',
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
frequent:true,
|
||||
preHidden:true,
|
||||
|
@ -3315,7 +3268,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
return;
|
||||
}
|
||||
event.card=result.card;
|
||||
event.node=result.node;
|
||||
player.chooseBool('是否将'+get.translation(event.card)+'作为【田】置于武将牌上?').ai=function(){
|
||||
return true;
|
||||
};
|
||||
|
@ -3323,51 +3275,23 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
if(!result.bool&&!event.directbool){
|
||||
return;
|
||||
};
|
||||
player.storage.tuntian.push(event.card);
|
||||
game.cardsGotoSpecial(card);
|
||||
event.node.moveDelete(player);
|
||||
game.broadcast(function(cardid,player){
|
||||
var node=lib.cardOL[cardid];
|
||||
if(node){
|
||||
node.moveDelete(player);
|
||||
}
|
||||
},event.node.cardid,player);
|
||||
game.addVideo('gain2',player,get.cardsInfo([event.node]));
|
||||
player.markSkill('tuntian');
|
||||
game.addVideo('storage',player,['tuntian',get.cardsInfo(player.storage.tuntian),'cards']);
|
||||
player.addToExpansion(event.card,'gain2').gaintag.add('tuntian');
|
||||
},
|
||||
callback:function(){
|
||||
if(!event.judgeResult.bool){
|
||||
event.finish();
|
||||
return;
|
||||
}
|
||||
player.storage.tuntian.push(event.card);
|
||||
game.cardsGotoSpecial(card);
|
||||
event.node=event.judgeResult.node;
|
||||
event.node.moveDelete(player);
|
||||
game.broadcast(function(cardid,player){
|
||||
var node=lib.cardOL[cardid];
|
||||
if(node){
|
||||
node.moveDelete(player);
|
||||
}
|
||||
},event.node.cardid,player);
|
||||
game.addVideo('gain2',player,get.cardsInfo([event.node]));
|
||||
player.markSkill('tuntian');
|
||||
game.addVideo('storage',player,['tuntian',get.cardsInfo(player.storage.tuntian),'cards']);
|
||||
},
|
||||
init:function(player){
|
||||
if(!player.storage.tuntian) player.storage.tuntian=[];
|
||||
player.addToExpansion(event.judgeResult.card,'gain2').gaintag.add('tuntian');
|
||||
},
|
||||
marktext:'田',
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
player.storage.tuntian.length=0;
|
||||
}
|
||||
},
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
group:'tuntian_dist',
|
||||
locked:false,
|
||||
|
@ -3377,7 +3301,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
mod:{
|
||||
globalFrom:function(from,to,distance){
|
||||
if(from.storage.tuntian){
|
||||
var num=distance-from.storage.tuntian.length;
|
||||
var num=distance-from.getExpansions('tuntian').length;
|
||||
if(_status.event.skill=='jixi_backup'||_status.event.skill=='gzjixi_backup') num++;
|
||||
return num;
|
||||
}
|
||||
|
@ -3430,14 +3354,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{player:'phaseZhunbeiBegin'},
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
if(player.storage.tuntian) return player.storage.tuntian.length>=3&&!player.storage.zaoxian;
|
||||
return player.getExpansions('tuntian').length>=3;
|
||||
},
|
||||
derivation:'jixi',
|
||||
content:function(){
|
||||
player.awakenSkill('zaoxian');
|
||||
player.loseMaxHp();
|
||||
player.addSkill('jixi');
|
||||
player.storage.zaoxian=true;
|
||||
player.awakenSkill('zaoxian');
|
||||
}
|
||||
},
|
||||
jixi:{
|
||||
|
@ -3445,42 +3368,34 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audioname:['re_dengai','gz_dengai','ol_dengai'],
|
||||
enable:'phaseUse',
|
||||
filter:function(event,player){
|
||||
return player.storage.tuntian.length>0&&event.filterCard({name:'shunshou'},player,event);
|
||||
return player.getExpansions('tuntian').length>0&&event.filterCard({name:'shunshou'},player,event);
|
||||
},
|
||||
chooseButton:{
|
||||
dialog:function(event,player){
|
||||
return ui.create.dialog('急袭',player.storage.tuntian,'hidden');
|
||||
return ui.create.dialog('急袭',player.getExpansions('tuntian'),'hidden');
|
||||
},
|
||||
backup:function(links,player){
|
||||
return {
|
||||
filterCard:function(){return false},
|
||||
audio:'jixi',
|
||||
audioname:['re_dengai','gz_dengai','ol_dengai'],
|
||||
selectCard:-1,
|
||||
viewAs:{name:'shunshou',cards:links},
|
||||
cards:links,
|
||||
onuse:function(result,player){
|
||||
result.cards=lib.skill[result.skill].cards;
|
||||
var card=result.cards[0];
|
||||
player.storage.tuntian.remove(card);
|
||||
player.syncStorage('tuntian');
|
||||
if(!player.storage.tuntian.length){
|
||||
player.unmarkSkill('tuntian');
|
||||
}
|
||||
else{
|
||||
player.markSkill('tuntian');
|
||||
}
|
||||
player.logSkill('jixi',result.targets);
|
||||
}
|
||||
position:'x',
|
||||
filterCard:function(card){
|
||||
return card==lib.skill.jixi_backup.card;
|
||||
},
|
||||
viewAs:{name:'shunshou'},
|
||||
card:links[0],
|
||||
}
|
||||
},
|
||||
prompt:function(links,player){
|
||||
return '请选择【顺手牵羊】的目标';
|
||||
return '选择 顺手牵羊('+get.translation(links[0])+')的目标';
|
||||
}
|
||||
},
|
||||
ai:{
|
||||
order:10,
|
||||
result:{
|
||||
player:function(player){
|
||||
return player.storage.tuntian.length-1;
|
||||
return player.getExpansions('tuntian').length-1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -5707,15 +5622,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
preHidden:true,
|
||||
content:function(){
|
||||
"step 0"
|
||||
player.judge(ui.special);
|
||||
"step 1"
|
||||
player.gain(result.card);
|
||||
player.$gain2(result.card);
|
||||
player.addTempSkill('shuangxiong2');
|
||||
player.storage.shuangxiong=get.color(result.card);
|
||||
player.judge().set('callback',lib.skill.shuangxiong.callback);
|
||||
trigger.changeToZero();
|
||||
}
|
||||
},
|
||||
callback:function(){
|
||||
player.gain(card,'gain2');
|
||||
player.addTempSkill('shuangxiong2');
|
||||
player.storage.shuangxiong=event.judgeResult.color;
|
||||
},
|
||||
},
|
||||
shuangxiong2:{
|
||||
audio:true,
|
||||
|
@ -6698,24 +6612,21 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{player:'chooseToUseBefore'},
|
||||
forced:true,
|
||||
preHidden:true,
|
||||
filter:function(event,player){return event.type=='dying'&&player.isDying()&&event.dying==player},
|
||||
filter:function(event,player){
|
||||
return event.type=='dying'&&player.isDying()&&event.dying==player&&!event.getParent()._buqu;
|
||||
},
|
||||
content:function(){
|
||||
"step 0"
|
||||
event.card=get.cards()[0];
|
||||
if(player.storage.buqu==undefined) player.storage.buqu=[];
|
||||
player.storage.buqu.push(event.card);
|
||||
player.syncStorage('buqu');
|
||||
//event.trigger("addCardToStorage");
|
||||
game.cardsGotoSpecial(event.card);
|
||||
player.showCards(player.storage.buqu,'不屈')
|
||||
player.markSkill('buqu');
|
||||
trigger.getParent()._buqu=true;
|
||||
var card=get.cards()[0];
|
||||
event.card=card;
|
||||
player.addToExpansion(card,'gain2').gaintag.add('buqu');
|
||||
"step 1"
|
||||
for(var i=0;i<player.storage.buqu.length-1;i++){
|
||||
if(get.number(event.card)&&get.number(event.card)==get.number(player.storage.buqu[i])){
|
||||
player.storage.buqu.remove(event.card);
|
||||
player.syncStorage('buqu');
|
||||
player.markSkill('buqu');
|
||||
game.cardsDiscard(event.card);
|
||||
var cards=player.getExpansions('buqu'),num=get.number(card);
|
||||
player.showCards(cards,'不屈')
|
||||
for(var i=0;i<cards.length;i++){
|
||||
if(cards[i]!=card&&get.number(cards[i])==num){
|
||||
player.loseToDiscardpile(card);
|
||||
return;
|
||||
};
|
||||
}
|
||||
|
@ -6738,14 +6649,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
delete player.storage.buqu;
|
||||
}
|
||||
}
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
}
|
||||
},
|
||||
fenji:{
|
||||
|
|
648
character/sp.js
648
character/sp.js
File diff suppressed because it is too large
Load Diff
176
character/sp2.js
176
character/sp2.js
|
@ -4,6 +4,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
name:'sp2',
|
||||
connect:true,
|
||||
character:{
|
||||
re_sunyi:['male','wu',4,['syjiqiao','syxiongyi'],['unseen']],
|
||||
re_pangdegong:['male','qun',3,['heqia','yinyi']],
|
||||
wangtao:['female','shu',3,['huguan','yaopei']],
|
||||
wangyue:['female','shu',3,['huguan','mingluan']],
|
||||
|
@ -124,10 +125,100 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
sp_zhilan:['liuyong','wanniangongzhu','zhanghu'],
|
||||
sp_fenghuo:['re_nanhualaoxian','tongyuan','zhangning'],
|
||||
sp_guixin:['re_kanze','re_chendeng'],
|
||||
sp_decade:['wulan','leitong','huaman','wangshuang','wenyang','re_liuzan','caobuxing','re_maliang','xin_baosanniang','re_xinxianying','dongxie','guozhao','fanyufeng','ruanyu','liangxing','re_dongzhao','yangwan','re_panshu','dufuren','zhouyi','lvlingqi','caojinyu','wangtao','wangyue','re_pangdegong'],
|
||||
sp_decade:['wulan','leitong','huaman','wangshuang','wenyang','re_liuzan','caobuxing','re_maliang','xin_baosanniang','re_xinxianying','dongxie','guozhao','fanyufeng','ruanyu','liangxing','re_dongzhao','yangwan','re_panshu','dufuren','zhouyi','lvlingqi','caojinyu','wangtao','wangyue','re_pangdegong','re_sunyi'],
|
||||
}
|
||||
},
|
||||
skill:{
|
||||
//孙翊
|
||||
syjiqiao:{
|
||||
audio:2,
|
||||
trigger:{player:'phaseUseBegin'},
|
||||
content:function(){
|
||||
var cards=get.cards(player.maxHp);
|
||||
player.addToExpansion(cards,'gain2').gaintag.add('syjiqiao');
|
||||
player.addTempSkill('syjiqiao_gain','phaseUseAfter');
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
intro:{
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
subSkill:{
|
||||
gain:{
|
||||
audio:'syjiqiao',
|
||||
trigger:{player:'useCardAfter'},
|
||||
charlotte:true,
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
return player.hasCard((card)=>card.hasGaintag('syjiqiao'),'x');
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
var cards=player.getExpansions('syjiqiao')
|
||||
player.chooseButton(['激峭:选择获得一张牌',cards],true);
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
player.gain(result.links,'gain2');
|
||||
}
|
||||
else event.finish();
|
||||
'step 2'
|
||||
var map={red:0,black:0},cards=player.getExpansions('syjiqiao')
|
||||
for(var i of cards){
|
||||
var color=get.color(i,false);
|
||||
if(map[color]!=undefined) map[color]++;
|
||||
}
|
||||
if(map.red==map.black) player.recover();
|
||||
else player.loseHp();
|
||||
},
|
||||
onremove:function(player){
|
||||
var cards=player.getExpansions('syjiqiao')
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
syxiongyi:{
|
||||
audio:2,
|
||||
skillAnimation:true,
|
||||
animationColor:'wood',
|
||||
limited:true,
|
||||
enable:'chooseToUse',
|
||||
filter:function(event,player){
|
||||
if(event.type!='dying') return false;
|
||||
if(player!=event.dying) return false;
|
||||
return true;
|
||||
},
|
||||
content:function(){
|
||||
player.awakenSkill('syxiongyi');
|
||||
if(!_status.characterlist){
|
||||
lib.skill.pingjian.initList();
|
||||
}
|
||||
var hp=1-player.hp;
|
||||
if((player.name1=='re_sunyi'||player.name2=='re_sunyi')&&_status.characterlist.contains('xushi')){
|
||||
hp+=2;
|
||||
_status.characterlist.remove('xushi');
|
||||
_status.characterlist.add('re_sunyi');
|
||||
player.reinit('re_sunyi','xushi',false);
|
||||
}
|
||||
else{
|
||||
player.addSkillLog('olhunzi');
|
||||
}
|
||||
if(hp>0) player.recover(hp);
|
||||
},
|
||||
ai:{
|
||||
save:true,
|
||||
skillTagFilter:function(player,arg,target){
|
||||
return player==target;
|
||||
},
|
||||
result:{
|
||||
player:10
|
||||
},
|
||||
},
|
||||
derivation:['olhunzi','reyingzi','gzyinghun'],
|
||||
},
|
||||
//庞德公
|
||||
heqia:{
|
||||
audio:2,
|
||||
|
@ -285,8 +376,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:2,
|
||||
trigger:{player:'damageBegin1'},
|
||||
forced:true,
|
||||
usable:1,
|
||||
filter:function(event,player){
|
||||
return event.source&&event.source.hp!=player.hp&&event.source.countCards('h')!=player.countCards('h');
|
||||
return event.source&&event.source.hp!=player.hp&&!lib.linked.contains(event.nature)&&event.source.countCards('h')!=player.countCards('h');
|
||||
},
|
||||
content:function(){
|
||||
trigger.cancel();
|
||||
|
@ -506,9 +598,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 0'
|
||||
target.gain(cards,player,'giveAuto');
|
||||
'step 1'
|
||||
var next=target.chooseCard('he',2,'交给'+get.translation(player)+'两张装备牌,否则受到1点伤害',{type:'equip'});
|
||||
var next=target.chooseCard('he',[2,Infinity],'交给'+get.translation(player)+'至少两张装备牌,否则受到1点伤害',{type:'equip'});
|
||||
if(get.damageEffect(target,player,target)>=0) next.set('ai',()=>-1);
|
||||
else next.set('ai',(card)=>6-get.value(card));
|
||||
else next.set('ai',(card)=>ui.selected.cards.length<2?(6-get.value(card)):0);
|
||||
'step 2'
|
||||
if(result.bool) player.gain(result.cards,target,'giveAuto');
|
||||
else target.damage('nocard');
|
||||
|
@ -1235,7 +1327,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
subSkill:{
|
||||
draw:{
|
||||
trigger:{
|
||||
global:['equipAfter','addJudgeAfter','loseAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','loseAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
|
@ -2628,7 +2720,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
yaner:{
|
||||
audio:2,
|
||||
trigger:{
|
||||
global:['equipAfter','addJudgeAfter','loseAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','loseAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
filter:function(event,player){
|
||||
var current=_status.currentPhase;
|
||||
|
@ -3942,7 +4034,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
liangjue:{
|
||||
trigger:{
|
||||
player:'loseAfter',
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
|
@ -4767,7 +4859,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
filterTarget:function(card,player,target){
|
||||
if(player==target) return false;
|
||||
if(player.storage.bazhan) return target.countGainableCards(player,'he')>0;
|
||||
if(player.storage.bazhan) return target.countGainableCards(player,'h')>0;
|
||||
return true;
|
||||
},
|
||||
prompt:function(){
|
||||
|
@ -5148,7 +5240,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:'pianchong',
|
||||
trigger:{
|
||||
player:'loseAfter',
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
forced:true,
|
||||
charlotte:true,
|
||||
|
@ -6587,7 +6679,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:2,
|
||||
trigger:{
|
||||
player:'loseAfter',
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
|
@ -9048,70 +9140,67 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
biaozhao:{
|
||||
audio:2,
|
||||
intro:{
|
||||
content:"cards",
|
||||
content:"expansion",
|
||||
markcount:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
trigger:{
|
||||
player:"phaseJieshuBegin",
|
||||
},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
return player.countCards('he')>0&&!player.storage.biaozhao;
|
||||
return player.countCards('he')>0&&!player.getExpansions('biaozhao').length;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.chooseCard('he',get.prompt2('biaozhao')).ai=function(card){
|
||||
player.chooseCard('he',get.prompt('biaozhao'),'将一张牌置于武将牌上作为“表”').ai=function(card){
|
||||
return 6-get.value(card);
|
||||
}
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
player.addSkill('biaozhao2');
|
||||
player.addSkill('biaozhao3');
|
||||
player.logSkill('biaozhao');
|
||||
player.lose(result.cards,ui.special,'toStorage','visible');
|
||||
player.$give(result.cards,player,false);
|
||||
player.storage.biaozhao=result.cards;
|
||||
player.markSkill('biaozhao');
|
||||
player.addToExpansion(result.cards,player,'give').gaintag.add('biaozhao');
|
||||
}
|
||||
},
|
||||
ai:{
|
||||
notemp:true,
|
||||
},
|
||||
group:['biaozhao2','biaozhao3'],
|
||||
},
|
||||
"biaozhao2":{
|
||||
biaozhao2:{
|
||||
trigger:{
|
||||
global:["loseAfter","cardsDiscardAfter"],
|
||||
},
|
||||
charlotte:true,
|
||||
forced:true,
|
||||
audio:"biaozhao",
|
||||
filter:function(event,player){
|
||||
if(!player.storage.biaozhao) return false;
|
||||
var suit=get.suit(player.storage.biaozhao[0]);
|
||||
var num=get.number(player.storage.biaozhao[0]);
|
||||
if(event.name=='lose'&&event.position!=ui.discardPile) return false;
|
||||
var cards=player.getExpansions('biaozhao');
|
||||
if(!cards.length) return false;
|
||||
var suit=get.suit(cards[0]);
|
||||
var num=get.number(cards[0]);
|
||||
for(var i=0;i<event.cards.length;i++){
|
||||
if(get.position(event.cards[i],true)=='d'&&get.suit(event.cards[i])==suit
|
||||
&&get.number(event.cards[i])==num) return true;
|
||||
if(get.suit(event.cards[i])==suit&&get.number(event.cards[i])==num) return true;
|
||||
}
|
||||
return false;
|
||||
},
|
||||
content:function(){
|
||||
"step 0"
|
||||
var card=player.storage.biaozhao[0];
|
||||
delete player.storage.biaozhao;
|
||||
var card=player.getExpansions('biaozhao')[0];
|
||||
if(trigger.getParent().name=='discard'){
|
||||
trigger.player.gain(card,'fromStorage');
|
||||
player.$give(card,trigger.player);
|
||||
trigger.player.gain(card,'player','give');
|
||||
}
|
||||
else{
|
||||
player.$throw(card);
|
||||
game.cardsDiscard(card);
|
||||
player.loseToDiscardpile(card);
|
||||
}
|
||||
"step 1"
|
||||
player.unmarkSkill('biaozhao');
|
||||
player.loseHp();
|
||||
},
|
||||
},
|
||||
"biaozhao3":{
|
||||
biaozhao3:{
|
||||
trigger:{
|
||||
player:"phaseZhunbeiBegin",
|
||||
},
|
||||
|
@ -9119,14 +9208,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
charlotte:true,
|
||||
audio:"biaozhao",
|
||||
filter:function(event,player){
|
||||
return player.storage.biaozhao!=undefined;
|
||||
return player.getExpansions('biaozhao').length>0;
|
||||
},
|
||||
content:function(){
|
||||
"step 0"
|
||||
var card=player.storage.biaozhao[0];
|
||||
delete player.storage.biaozhao;
|
||||
player.unmarkSkill('biaozhao');
|
||||
game.cardsDiscard(card);
|
||||
var card=player.getExpansions('biaozhao')[0];
|
||||
player.loseToDiscardpile(card);
|
||||
"step 1"
|
||||
event.num=0;
|
||||
game.countPlayer(function(current){
|
||||
if(current.countCards('h')>event.num) event.num=current.countCards('h');
|
||||
|
@ -9136,7 +9224,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
if(target.isDamaged()) num++;
|
||||
return num*get.attitude(_status.event.player,target);
|
||||
};
|
||||
"step 1"
|
||||
"step 2"
|
||||
if(result.bool){
|
||||
var target=result.targets[0];
|
||||
player.line(target,'green');
|
||||
|
@ -12023,6 +12111,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
kanze:['re_kanze','kanze'],
|
||||
yangwan:['yangwan','sp_yangwan'],
|
||||
chendeng:['re_chendeng','chendeng'],
|
||||
pangdegong:['re_pangdegong','pangdegong'],
|
||||
zhujun:['sp_zhujun','zhujun'],
|
||||
sunyi:['re_sunyi','sunyi'],
|
||||
},
|
||||
translate:{
|
||||
lijue:"李傕",
|
||||
|
@ -12653,6 +12744,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
heqia_info:'出牌阶段开始时,你可选择一项:①将任意张牌交给一名其他角色。②令一名有手牌的其他角色交给你任意张牌。然后以此法获得牌的角色可以视为使用一张基本牌,且当其声明使用此牌时,可以为此牌增加至至多X个目标(X为以此法移动的牌数)。',
|
||||
yinyi:'隐逸',
|
||||
yinyi_info:'锁定技。每回合限一次,当你受到非属性伤害时,若你的手牌数和体力值与伤害来源均不相同,则你防止此伤害。',
|
||||
re_sunyi:'孙翊',
|
||||
syjiqiao:'激峭',
|
||||
syjiqiao_info:'出牌阶段开始时,你可将牌堆顶的X张牌置于你的武将牌上(X为你的体力上限)。当你于此出牌阶段内使用的牌结算结束后,你可以获得其中的一张牌,然后若剩余牌中红色牌和黑色牌的数量:不相等,你失去1点体力;相等,你摸一张牌。出牌阶段结束时,你将这些牌置入弃牌堆。',
|
||||
syxiongyi:'凶疑',
|
||||
syxiongyi_info:'限定技。当你处于濒死状态时,若剩余武将牌堆中:有“徐氏”,则你将体力值回复至3点,并将此武将牌替换为“徐氏”;没有“徐氏”,则你将体力值回复至1点并获得〖魂姿〗。',
|
||||
|
||||
sp_whlw:"文和乱武",
|
||||
sp_zlzy:"逐鹿中原",
|
||||
|
|
|
@ -1016,12 +1016,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
filter:function(event,player){
|
||||
return player.countCards('he')>0;
|
||||
},
|
||||
toStorage:true,
|
||||
discard:false,
|
||||
lose:false,
|
||||
content:function(){
|
||||
player.awakenSkill('zhongyi');
|
||||
player.addTempSkill('zhongyi2','roundStart');
|
||||
player.markAuto('zhongyi2',cards);
|
||||
player.addToExpansion(player,'give',cards).gaintag.add('zhongyi2');
|
||||
},
|
||||
},
|
||||
zhongyi2:{
|
||||
|
@ -1033,7 +1033,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
return event.getParent().name=='sha'&&event.source&&event.source.isFriendOf(player);
|
||||
},
|
||||
content:function(){trigger.num++},
|
||||
intro:{content:'cards',onunmark:'throw'},
|
||||
intro:{content:'expansion',markcount:'expansion'},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
},
|
||||
paoxiao:{
|
||||
audio:2,
|
||||
|
@ -1789,7 +1793,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:2,
|
||||
trigger:{
|
||||
player:'loseAfter',
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
frequent:true,
|
||||
filter:function(event,player){
|
||||
|
@ -1820,7 +1824,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audioname:['sp_sunshangxiang','re_sunshangxiang'],
|
||||
trigger:{
|
||||
player:'loseAfter',
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
frequent:true,
|
||||
filter:function(event,player){
|
||||
|
|
|
@ -790,7 +790,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
equipSkill:true,
|
||||
trigger:{
|
||||
player:['loseAfter','gainAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
filter:function(event,player){
|
||||
if(player==_status.currentPhase) return false;
|
||||
|
@ -1550,7 +1550,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
cards:cards,
|
||||
});
|
||||
'step 2'
|
||||
target.removeSkill('twrangyi');
|
||||
target.removeSkill('twrangyi2');
|
||||
if(!result.bool) target.damage('nocard');
|
||||
},
|
||||
ai:{
|
||||
|
@ -1573,6 +1573,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{player:'useCard'},
|
||||
forced:true,
|
||||
popup:false,
|
||||
charlotte:true,
|
||||
filter:function(event,player){
|
||||
var evt=event.getParent(2);
|
||||
return evt.name=='twrangyi'&&evt.player.isAlive()&&player.countCards('h',function(card){
|
||||
|
@ -1583,6 +1584,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
var cards=player.getCards('h',function(card){
|
||||
return card.hasGaintag('twrangyi');
|
||||
});
|
||||
game.delayx();
|
||||
trigger.getParent(2).player.gain(cards,player,'giveAuto');
|
||||
},
|
||||
onremove:function(player){
|
||||
|
|
|
@ -48,7 +48,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
direct:true,
|
||||
filter:function(event,player){
|
||||
return player.countCards('he')>0&&!game.hasPlayer(function(current){
|
||||
return current.storage.xinyingshi_cards&¤t.storage.xinyingshi_cards.length>0;
|
||||
return current.getExpansions('xinyingshi_cards').length>0;
|
||||
});
|
||||
},
|
||||
content:function(){
|
||||
|
@ -74,16 +74,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
if(result.bool){
|
||||
var target=result.targets[0],cards=result.cards;
|
||||
player.logSkill('xinyingshi',target);
|
||||
player.lose(cards,ui.special,'toStorage');
|
||||
player.$give(cards,target,false);
|
||||
target.addSkill('xinyingshi_cards');
|
||||
target.markAuto('xinyingshi_cards',cards);
|
||||
target.addToExpansion(player,'give',cards).gaintag.add('xinyingshi_cards');
|
||||
target.storage.xinyingshi_source=player;
|
||||
game.log(player,'将',cards,'置于了',target,'的武将牌上');
|
||||
}
|
||||
else event.finish();
|
||||
'step 2'
|
||||
game.delay(0,get.delayx(650,650));
|
||||
},
|
||||
subSkill:{
|
||||
cards:{
|
||||
|
@ -92,17 +86,16 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
charlotte:true,
|
||||
filter:function(event,player){
|
||||
return event.source&&event.source.isIn()&&event.card&&event.getParent().type=='card'&&
|
||||
player.storage.xinyingshi_cards&&player.storage.xinyingshi_cards.length;
|
||||
player.getExpansions('xinyingshi_cards').length;
|
||||
},
|
||||
logTarget:'source',
|
||||
content:function(){
|
||||
'step 0'
|
||||
event.target=trigger.source;
|
||||
event.target.chooseButton(['应势:请选择你的赏金',player.storage.xinyingshi_cards]);
|
||||
event.target.chooseButton(['应势:请选择你的赏金',player.getExpansions('xinyingshi_cards')]);
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
var cards=[result.links[0]];
|
||||
player.unmarkAuto('xinyingshi_cards',cards);
|
||||
for(var i=0;i<ui.cardPile.childNodes.length;i++){
|
||||
var card=ui.cardPile.childNodes[i];
|
||||
if(card.number==cards[0].number&&card.suit==cards[0].suit) cards.push(card);
|
||||
|
@ -116,34 +109,34 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
game.delay(0,get.delayx(500,500));
|
||||
target.gain(cards);
|
||||
if(!player.storage.xinyingshi_cards||!player.storage.xinyingshi_cards.length) player.removeSkill('xinyingshi_cards');
|
||||
}
|
||||
else event.finish();
|
||||
'step 2'
|
||||
game.delay(0,get.delayx(150,150));
|
||||
if(!player.getExpansions('xinyingshi_cards').length) player.removeSkill('xinyingshi_cards');
|
||||
},
|
||||
marktext:'酬',
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
var source=player.storage.xinyingshi_source;
|
||||
if(source&&source.isIn()){
|
||||
source.logSkill('xinyingshi',player);
|
||||
player.$give(storage,source);
|
||||
game.delayx(0,get.delayx(500,500));
|
||||
source.gain(storage);
|
||||
}
|
||||
else{
|
||||
game.cardsDiscard(storage);
|
||||
player.$throw(storage,1000);
|
||||
}
|
||||
}
|
||||
delete player.storage.xinyingshi_source;
|
||||
delete player.storage.xinyingshi_cards;
|
||||
},
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
ai:{threaten:3},
|
||||
group:'xinyingshi_regain',
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
delete player.storage.xinyingshi_source;
|
||||
},
|
||||
},
|
||||
regain:{
|
||||
trigger:{player:'die'},
|
||||
forced:true,
|
||||
charlotte:true,
|
||||
forceDie:true,
|
||||
filter:function(event,player){
|
||||
return player.storage.xinyingshi_source&&player.storage.xinyingshi_source.isIn()&&player.getExpansions('xinyingshi_cards').length>0;
|
||||
},
|
||||
content:function(){
|
||||
player.storage.xinyingshi_source.gain(player.getExpansions('xinyingshi_cards'),player,'give');
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
|
@ -546,7 +539,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:'qinguo_use',
|
||||
trigger:{
|
||||
player:'loseAfter',
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
prompt:'是否发动【勤国】回复1点体力?',
|
||||
filter:function (event,player){
|
||||
|
@ -562,7 +555,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
},
|
||||
},
|
||||
"xinfu_jijun":{
|
||||
xinfu_jijun:{
|
||||
ai:{
|
||||
reverseEquip:true,
|
||||
effect:{
|
||||
|
@ -584,46 +577,28 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
return false;
|
||||
},
|
||||
callback:function(){
|
||||
game.cardsGotoSpecial(card);
|
||||
player.storage.xinfu_jijun.push(card);
|
||||
var node=event.judgeResult.node;
|
||||
node.moveDelete(player);
|
||||
game.broadcast(function(cardid,player){
|
||||
var node=lib.cardOL[cardid];
|
||||
if(node){
|
||||
node.moveDelete(player);
|
||||
}
|
||||
},node.cardid,player);
|
||||
game.addVideo('gain2',player,get.cardsInfo([node]));
|
||||
player.markSkill('xinfu_jijun');
|
||||
game.addVideo('storage',player,['xinfu_jijun',get.cardsInfo(player.storage.xinfu_jijun),'cards']);
|
||||
//event.trigger("addCardToStorage");
|
||||
player.addToExpansion(card,'gain2').gaintag.add('xinfu_jijun');
|
||||
},
|
||||
content:function (){
|
||||
player.judge(function(card){
|
||||
return 1;
|
||||
}).callback=lib.skill.xinfu_jijun.callback;
|
||||
},
|
||||
init:function (player){
|
||||
if(!player.storage.xinfu_jijun) player.storage.xinfu_jijun=[];
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
},
|
||||
mark:function (dialog,content,player){
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
mark:function(dialog,content,player){
|
||||
var content=player.getExpansions('xinfu_jijun');
|
||||
if(content&&content.length){
|
||||
dialog.addAuto(content);
|
||||
if(player==game.me||player.isUnderControl()){
|
||||
var list=lib.skill.xinfu_fangtong.getAuto(player);
|
||||
if(list.length>0){
|
||||
dialog.addText('<li>推荐方案:'+get.translation(list));
|
||||
dialog.addText('<li>推荐方案:'+get.translation(list[0])+'+ '+get.translation(list.slice(1)));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -631,53 +606,32 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
marktext:"方",
|
||||
},
|
||||
"xinfu_fangtong":{
|
||||
getAuto:function (player){
|
||||
xinfu_fangtong:{
|
||||
getAuto:function(player){
|
||||
var hs=player.getCards('he');
|
||||
var ss=player.storage.xinfu_jijun;
|
||||
var bool=false;
|
||||
for(var i=0;i<hs.length;i++){
|
||||
var num=36-hs[i].number;
|
||||
for(var j=0;j<ss.length;j++){
|
||||
if(ss[j]==num){var k=-1;bool=true;break}
|
||||
for(var k=j+1;k<ss.length;k++){
|
||||
if(ss[j].number+ss[k].number==num){var l=-1;bool=true;break}
|
||||
for(var l=k+1;l<ss.length;l++){
|
||||
if(ss[j].number+ss[k].number+ss[l].number==num){var m=-1;bool=true;break}
|
||||
for(var m=l+1;m<ss.length;m++){
|
||||
if(ss[j].number+ss[k].number+ss[l].number+ss[m].number==num){var n=-1;bool=true;break}
|
||||
for(var n=m+1;n<ss.length;n++){
|
||||
if(ss[j].number+ss[k].number+ss[l].number+ss[m].number+ss[n].number==num){var o=-1;bool=true;break}
|
||||
for(var o=n+1;o<ss.length;o++){
|
||||
if(ss[j].number+ss[k].number+ss[l].number+ss[m].number+ss[n].number+ss[o].number==num){var p=-1;bool=true;break}
|
||||
for(var p=o+1;p<ss.length;p++){
|
||||
if(ss[j].number+ss[k].number+ss[l].number+ss[m].number+ss[n].number+ss[o].number+ss[p].number==num){bool=true;break}
|
||||
}
|
||||
if(bool) break;
|
||||
}
|
||||
if(bool) break;
|
||||
}
|
||||
if(bool) break;
|
||||
}
|
||||
if(bool) break;
|
||||
}
|
||||
if(bool) break;
|
||||
var ss=player.getExpansions('xinfu_jijun');
|
||||
var bool=false,max=Math.pow(2,ss.length),index,i;
|
||||
for(i=0;i<hs.length;i++){
|
||||
for(var j=1;j<max;j++){
|
||||
var num=get.number(hs[i]);
|
||||
index=j.toString(2);
|
||||
while(index.length<ss.length){
|
||||
index=('0'+index);
|
||||
}
|
||||
for(var k=0;k<ss.length;k++){
|
||||
if(index[k]=='1') num+=get.number(ss[k]);
|
||||
}
|
||||
if(num==36){
|
||||
bool=true;
|
||||
break;
|
||||
}
|
||||
if(bool) break;
|
||||
}
|
||||
if(bool) break;
|
||||
}
|
||||
if(!bool) return [];
|
||||
var list=[i,j,k,l,m,n,o,p];
|
||||
for(var q=0;q<list.length;q++){
|
||||
if(list[q]==-1){
|
||||
list=list.slice(0,q);
|
||||
break;
|
||||
}
|
||||
else if(q==0){
|
||||
list[q]=hs[i];
|
||||
}
|
||||
else list[q]=ss[list[q]];
|
||||
var list=[hs[i]];
|
||||
for(var k=0;k<ss.length;k++){
|
||||
if(index[k]=='1') list.push(ss[k]);
|
||||
}
|
||||
return list;
|
||||
},
|
||||
|
@ -686,7 +640,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
player:"phaseJieshuBegin",
|
||||
},
|
||||
filter:function (event,player){
|
||||
return player.storage.xinfu_jijun&&player.storage.xinfu_jijun.length&&player.countCards('he');
|
||||
return player.countCards('he')>0&&player.getExpansions('xinfu_jijun').length>0;
|
||||
},
|
||||
direct:true,
|
||||
skillAnimation:true,
|
||||
|
@ -694,10 +648,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
content:function (){
|
||||
'step 0'
|
||||
var info=['是否发动【方统】?'];
|
||||
if(player.storage.xinfu_jijun){
|
||||
info.push('<div class="text center">'+get.translation(player)+'的“方”</div>');
|
||||
info.push(player.storage.xinfu_jijun);
|
||||
}
|
||||
info.push('<div class="text center">'+get.translation(player)+'的“方”</div>');
|
||||
info.push(player.getExpansions('xinfu_jijun'));
|
||||
if(player.countCards('h')){
|
||||
info.push('<div class="text center">'+get.translation(player)+'的手牌区</div>');
|
||||
info.push(player.getCards('h'));
|
||||
|
@ -708,7 +660,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
var next=player.chooseButton();
|
||||
next.set('createDialog',info);
|
||||
next.set('selectButton',function (){
|
||||
next.set('selectButton',function(){
|
||||
var num=0;
|
||||
for(var i=0;i<ui.selected.buttons.length;i++){
|
||||
num+=get.number(ui.selected.buttons[i]);
|
||||
|
@ -717,11 +669,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
return ui.selected.buttons.length+2;
|
||||
});
|
||||
next.set('filterButton',function(button){
|
||||
var player=_status.event.player;
|
||||
var player=_status.event.player,cards=player.getExpansions('xinfu_jijun');
|
||||
if(ui.selected.buttons.length){
|
||||
if(!player.storage.xinfu_jijun.contains(button.link)) return false;
|
||||
if(!cards.contains(button.link)) return false;
|
||||
}
|
||||
else if(player.storage.xinfu_jijun.contains(button.link)) return false;
|
||||
else if(cards.contains(button.link)) return false;
|
||||
var num=0;
|
||||
for(var i=0;i<ui.selected.buttons.length;i++){
|
||||
num+=get.number(ui.selected.buttons[i]);
|
||||
|
@ -736,6 +688,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
links:_status.event.autolist,
|
||||
}
|
||||
}
|
||||
return {bool:false};
|
||||
});
|
||||
next.set('complexSelect',true);
|
||||
'step 1'
|
||||
|
@ -744,14 +697,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
var tothrow=[];
|
||||
var cards=result.links.slice(0);
|
||||
for(var i=0;i<cards.length;i++){
|
||||
if(player.storage.xinfu_jijun.contains(cards[i])){
|
||||
player.storage.xinfu_jijun.remove(cards[i]);
|
||||
if(get.position(cards[i])=='x'){
|
||||
tothrow.push(cards[i]);
|
||||
}else{
|
||||
player.discard(cards[i]);
|
||||
}
|
||||
else{
|
||||
player.discard(cards[i]).delay=false;
|
||||
}
|
||||
}
|
||||
player.$throw(tothrow);
|
||||
player.loseToDiscardpile(tothrow);
|
||||
player.chooseTarget('选择一个目标并对其造成3点雷电伤害',true,function(card,player,target){
|
||||
return target!=player;
|
||||
}).set('ai',function(target){
|
||||
|
|
|
@ -74,7 +74,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
|
||||
xin_liru:['male','qun',3,['xinjuece','xinmieji','xinfencheng']],
|
||||
|
||||
guohuanghou:['female','wei',3,['jiaozhao','xindanxin']],
|
||||
guohuanghou:['female','wei',3,['jiaozhao','danxin']],
|
||||
liuyu:['male','qun',2,['xinzhige','xinzongzuo']],
|
||||
liyan:['male','shu',3,['duliang','fulin']],
|
||||
sundeng:['male','wu',4,['xinkuangbi']],
|
||||
|
@ -408,7 +408,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:2,
|
||||
trigger:{
|
||||
player:['loseAfter','changeHp','gainMaxHpAfter','loseMaxHpAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
frequent:true,
|
||||
prompt:function(event,player){
|
||||
|
@ -2764,37 +2764,26 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
bizhuan:{
|
||||
audio:2,
|
||||
trigger:{player:'useCard',target:'useCardToTargeted'},
|
||||
trigger:{
|
||||
player:'useCard',
|
||||
target:'useCardToTargeted',
|
||||
},
|
||||
filter:function(event,player){
|
||||
if(event.name!='useCard'&&event.player==event.target) return false;
|
||||
if(player.storage.bizhuan.length>=4) return false;
|
||||
if(player.getExpansions('bizhuan').length>=4) return false;
|
||||
return get.suit(event.card)=='spade';
|
||||
},
|
||||
init:function(player){
|
||||
if(!player.storage.bizhuan) player.storage.bizhuan=[];
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
},
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
frequent:true,
|
||||
content:function(){
|
||||
var card=game.cardsGotoSpecial(get.cards()).cards[0];
|
||||
player.$draw(card);
|
||||
game.delay();
|
||||
player.storage.bizhuan.push(card);
|
||||
player.markSkill('bizhuan');
|
||||
player.addToExpansion(get.cards(),'gain2').gaintag.add('bizhuan');
|
||||
},
|
||||
mod:{
|
||||
maxHandcard:function(player,num){
|
||||
if(player.storage.bizhuan&&player.storage.bizhuan.length) return num+player.storage.bizhuan.length;
|
||||
return num+player.getExpansions('bizhuan').length;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@ -2802,15 +2791,16 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{player:'phaseDrawAfter'},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
return player.storage.bizhuan&&player.storage.bizhuan.length&&player.countCards('he')>0;
|
||||
return player.getExpansions('bizhuan').length>0&&player.countCards('he')>0;
|
||||
},
|
||||
content:function(){
|
||||
"step 0"
|
||||
var four=false;
|
||||
var nofour=!player.hasFriend();
|
||||
if(player.storage.bizhuan.length==4){
|
||||
var expansions=player.getExpansions('bizhuan');
|
||||
if(expansions.length==4){
|
||||
var suits=['club','spade','heart','diamond'];
|
||||
var list=player.getCards('he').concat(player.storage.bizhuan);
|
||||
var list=player.getCards('he').concat(expansions);
|
||||
for(var i=0;i<list.length;i++){
|
||||
suits.remove(get.suit(list[i]));
|
||||
if(suits.length==0){
|
||||
|
@ -2821,7 +2811,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
var next=player.chooseToMove('通博:是否交换“书”和手牌?').set('four',four).set('suits2',suits2).set('nofour',nofour);
|
||||
next.set('list',[
|
||||
[get.translation(player)+'(你)的“书”',player.storage.bizhuan],
|
||||
[get.translation(player)+'(你)的“书”',expansions],
|
||||
['你的牌',player.getCards('he')],
|
||||
]);
|
||||
next.set('filterMove',function(from,to){
|
||||
|
@ -2864,33 +2854,27 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
"step 1"
|
||||
if(result.bool){
|
||||
var pushs=result.moved[0],gains=result.moved[1];
|
||||
pushs.removeArray(player.storage.bizhuan);
|
||||
pushs.removeArray(player.getExpansions('bizhuan'));
|
||||
gains.removeArray(player.getCards('he'));
|
||||
if(!pushs.length||pushs.length!=gains.length){
|
||||
event.finish();
|
||||
return;
|
||||
}
|
||||
player.logSkill('tongbo');
|
||||
player.lose(pushs,ui.special,'toStorage');
|
||||
game.log(player,'将',pushs,'作为“星”置于武将牌上');
|
||||
player.gain(gains,'gain2','log','fromStorage');
|
||||
player.storage.bizhuan.addArray(pushs);
|
||||
player.storage.bizhuan.removeArray(gains);
|
||||
player.markSkill('bizhuan');
|
||||
player.addToExpansion(pushs,'give',player).gaintag.add('bizhuan');
|
||||
player.gain(gains,'gain2');
|
||||
}
|
||||
"step 2"
|
||||
var suits2=['club','spade','heart','diamond'];
|
||||
for(var i=0;i<player.storage.bizhuan.length;i++){
|
||||
suits2.remove(get.suit(player.storage.bizhuan[i]));
|
||||
var expansions=player.getExpansions('bizhuan');
|
||||
for(var i=0;i<expansions.length;i++){
|
||||
suits2.remove(get.suit(expansions[i]));
|
||||
}
|
||||
if(suits2.length>0){
|
||||
event.finish();
|
||||
}
|
||||
"step 3"
|
||||
event.cards=player.storage.bizhuan.slice(0);
|
||||
player.storage.bizhuan.length=0;
|
||||
player.unmarkSkill('bizhuan');
|
||||
"step 4"
|
||||
event.cards=player.getExpansions('bizhuan').slice(0);
|
||||
if(event.cards.length>1){
|
||||
player.chooseCardButton('将所有“书”交给任意名其他角色',true,event.cards,[1,event.cards.length]).set('ai',function(button){
|
||||
if(ui.selected.buttons.length==0) return 1;
|
||||
|
@ -2903,7 +2887,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
else{
|
||||
event.finish();
|
||||
}
|
||||
"step 5"
|
||||
"step 4"
|
||||
if(result.bool){
|
||||
for(var i=0;i<result.links.length;i++){
|
||||
event.cards.remove(result.links[i]);
|
||||
|
@ -2927,16 +2911,16 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
else{
|
||||
event.finish();
|
||||
}
|
||||
"step 6"
|
||||
"step 5"
|
||||
if(result.targets.length){
|
||||
result.targets[0].gain(event.togive,'draw');
|
||||
player.line(result.targets[0],'green');
|
||||
game.log(result.targets[0],'获得了'+get.cnNumber(event.togive.length)+'张','#g“书”');
|
||||
if(event.cards.length) event.goto(4);
|
||||
if(event.cards.length) event.goto(3);
|
||||
}
|
||||
},
|
||||
ai:{
|
||||
combo:'bizhuan'
|
||||
combo:'bizhuan',
|
||||
}
|
||||
},
|
||||
shouxi:{
|
||||
|
@ -3052,7 +3036,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
player.chooseCard('h','选择要分配的手牌',event.list.length,true);
|
||||
'step 3'
|
||||
var cards=result.cards;
|
||||
player.lose(cards,ui.special);
|
||||
player.lose(cards,ui.ordering);
|
||||
event.togain=cards;
|
||||
if(result.bool&&cards.length){
|
||||
var dialog=ui.create.dialog('惠民',cards,true);
|
||||
|
@ -3108,14 +3092,30 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
event.finish();
|
||||
}
|
||||
'step 6'
|
||||
var card=result.links[0];
|
||||
var card=result.links[0],target=event.current;
|
||||
if(card){
|
||||
event.current.gain(card);
|
||||
event.current.$gain2(card);
|
||||
target.gain(card,'gain2');
|
||||
event.togain.remove(card);
|
||||
}
|
||||
game.log(event.current,'选择了',card);
|
||||
game.delay();
|
||||
var capt=get.translation(target)+'选择了'+get.translation(card);
|
||||
game.broadcastAll(function(card,id,name,capt){
|
||||
var dialog=get.idDialog(id);
|
||||
if(dialog){
|
||||
dialog.content.firstChild.innerHTML=capt;
|
||||
for(var i=0;i<dialog.buttons.length;i++){
|
||||
if(dialog.buttons[i].link==card){
|
||||
dialog.buttons[i].querySelector('.info').innerHTML=name;
|
||||
break;
|
||||
}
|
||||
}
|
||||
game.addVideo('dialogCapt',null,[dialog.videoId,dialog.content.firstChild.innerHTML]);
|
||||
}
|
||||
},card,event.dialogID,function(target){
|
||||
if(target._tempTranslate) return target._tempTranslate;
|
||||
var name=target.name;
|
||||
if(lib.translate[name+'_ab']) return lib.translate[name+'_ab'];
|
||||
return get.translation(name);
|
||||
}(target),capt);
|
||||
if(event.togain.length) event.goto(5);
|
||||
}
|
||||
},
|
||||
|
@ -4559,14 +4559,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:2,
|
||||
content:function(){
|
||||
'step 0'
|
||||
if(player.storage.jiaozhao1&&player.storage.jiaozhao2){
|
||||
if(player.countMark('xindanxin')>=2){
|
||||
player.draw();
|
||||
event.finish();
|
||||
}
|
||||
else{
|
||||
var list=['draw_card','更改描述'];
|
||||
var prompt;
|
||||
if(player.storage.jiaozhao1){
|
||||
if(player.countMark('xindanxin')==0){
|
||||
prompt='摸一张牌或更改矫诏的描述<br><br><div class="text">更改描述:将“选择距离最近的一名其他角色,该角色”改为“你”';
|
||||
}
|
||||
else{
|
||||
|
@ -4584,13 +4584,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
else{
|
||||
game.log(player,'更改了','【矫诏】','的描述');
|
||||
player.popup('更改描述');
|
||||
player.markSkill('jiaozhao');
|
||||
if(player.storage.jiaozhao1){
|
||||
player.storage.jiaozhao2=true;
|
||||
}
|
||||
else{
|
||||
player.storage.jiaozhao1=true;
|
||||
}
|
||||
player.addMark('xindanxin',1,false);
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@ -5203,6 +5197,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:2,
|
||||
trigger:{player:'phaseJieshuBegin'},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
return !player.getExpansions('jieyue2').length;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.chooseCardTarget({
|
||||
|
@ -5245,10 +5242,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
'step 2'
|
||||
if(result.bool&&result.cards&&result.cards.length){
|
||||
event.target.$give(result.cards,player,false);
|
||||
player.storage.jieyue2=result.cards[0];
|
||||
event.target.lose(result.cards[0],ui.special,'toStorage');
|
||||
player.syncStorage('jieyue2');
|
||||
player.addToExpansion(result.cards,'give',target).gaintag.add('jieyue2');
|
||||
player.addSkill('jieyue2');
|
||||
}
|
||||
else if(event.target.countCards('he')){
|
||||
|
@ -5257,13 +5251,18 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
ai:{
|
||||
expose:0.1
|
||||
}
|
||||
},
|
||||
},
|
||||
jieyue2:{
|
||||
mark:'card',
|
||||
intro:{
|
||||
content:'card'
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
marktext:'钺',
|
||||
audio:true,
|
||||
enable:'chooseToUse',
|
||||
filterCard:function(card){
|
||||
|
@ -5277,6 +5276,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
prompt:'将一张黑色手牌当无懈可击使用',
|
||||
check:function(card){return 8-get.value(card)},
|
||||
threaten:1.2,
|
||||
charlotte:true,
|
||||
group:['jieyue3','jieyue4']
|
||||
},
|
||||
jieyue3:{
|
||||
|
@ -5308,8 +5308,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{player:'phaseZhunbeiBegin'},
|
||||
forced:true,
|
||||
content:function(){
|
||||
player.gain(player.storage.jieyue2,'gain2','fromStorage');
|
||||
player.storage.jieyue2=null;
|
||||
'step 0'
|
||||
var cards=player.getExpansions('jieyue2');
|
||||
if(cards.length) player.gain(cards,'gain2');
|
||||
'step 1'
|
||||
player.removeSkill('jieyue2');
|
||||
}
|
||||
},
|
||||
|
@ -5556,21 +5558,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:2,
|
||||
audioname:['xin_chengpu'],
|
||||
filter:function(event,player){
|
||||
return player.countCards('h')>0&&(_status.connectMode||player.countCards('h','sha')>0)&&!player.storage.chunlao.length;
|
||||
},
|
||||
init:function(player){
|
||||
if(!player.storage.chunlao) player.storage.chunlao=[];
|
||||
return player.countCards('h')>0&&(_status.connectMode||player.countCards('h','sha')>0)&&!player.getExpansion('chunlao').length;
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
},
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
|
@ -5580,11 +5572,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 1'
|
||||
if(result.bool){
|
||||
player.logSkill('chunlao');
|
||||
player.storage.chunlao=player.storage.chunlao.concat(result.cards);
|
||||
player.syncStorage('chunlao');
|
||||
player.markSkill('chunlao');
|
||||
player.lose(result.cards,ui.special,'toStorage');
|
||||
player.$give(result.cards,player,false);
|
||||
player.addToExpansion(result.cards,player,'giveAuto').gaintag.add('chunlao');
|
||||
}
|
||||
},
|
||||
ai:{
|
||||
|
@ -5592,7 +5580,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
player:function(card,player,target){
|
||||
if(_status.currentPhase!=player) return;
|
||||
if(card.name=='sha'&&!player.needsToDiscard()&&
|
||||
!player.storage.chunlao.length&&target.hp>1){
|
||||
!player.getExpansions('chunlao').length&&target.hp>1){
|
||||
return 'zeroplayertarget';
|
||||
}
|
||||
}
|
||||
|
@ -5604,7 +5592,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
chunlao2:{
|
||||
enable:'chooseToUse',
|
||||
filter:function(event,player){
|
||||
return event.type=='dying'&&event.dying&&event.dying.hp<=0&&player.storage.chunlao.length>0;
|
||||
return event.type=='dying'&&event.dying&&event.dying.hp<=0&&player.getExpansions('chunlao').length>0;
|
||||
},
|
||||
filterTarget:function(card,player,target){
|
||||
return target==_status.event.dying;
|
||||
|
@ -5615,28 +5603,19 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
selectTarget:-1,
|
||||
content:function(){
|
||||
"step 0"
|
||||
player.chooseCardButton(get.translation('chunlao'),player.storage.chunlao,true);
|
||||
player.chooseCardButton(get.translation('chunlao'),player.getExpansions('chunlao'),true);
|
||||
"step 1"
|
||||
if(result.bool){
|
||||
player.logSkill('chunlao',target);
|
||||
player.$throw(result.links);
|
||||
player.storage.chunlao.remove(result.links[0]);
|
||||
game.cardsDiscard(result.links[0]);
|
||||
player.syncStorage('chunlao')
|
||||
player.loseToDiscardpile(result.links);
|
||||
event.type='dying';
|
||||
target.useCard({name:'jiu',isCard:true},target);
|
||||
if(!player.storage.chunlao.length){
|
||||
player.unmarkSkill('chunlao');
|
||||
}
|
||||
else{
|
||||
player.markSkill('chunlao');
|
||||
}
|
||||
}
|
||||
},
|
||||
ai:{
|
||||
order:6,
|
||||
skillTagFilter:function(player){
|
||||
return player.storage.chunlao.length>0;
|
||||
return player.getExpansions('chunlao').length>0;
|
||||
},
|
||||
save:true,
|
||||
result:{
|
||||
|
@ -5975,20 +5954,16 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
return _status.currentPhase==player;
|
||||
},
|
||||
frequent:true,
|
||||
init:function(player){
|
||||
if(!player.storage.sidi) player.storage.sidi=[];
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:'throw',
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
content:function(){
|
||||
var card=game.cardsGotoSpecial(get.cards()).cards[0];
|
||||
game.log(player,'将',card,'置于武将牌上');
|
||||
player.$gain2(card);
|
||||
player.storage.sidi.add(card);
|
||||
player.markSkill('sidi');
|
||||
player.syncStorage('sidi');
|
||||
player.addToExpansion(get.cards(),'gain2').gaintag.add('sidi');
|
||||
},
|
||||
group:'sidi2'
|
||||
},
|
||||
|
@ -5996,7 +5971,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{global:'phaseUseBegin'},
|
||||
filter:function(event,player){
|
||||
if(event.player==player||event.player.isDead()) return false;
|
||||
if(!player.storage.sidi||!player.storage.sidi.length) return false;
|
||||
if(!player.getExpansions('sidi').length) return false;
|
||||
return true;
|
||||
},
|
||||
check:function(event,player){
|
||||
|
@ -6029,11 +6004,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
logTarget:'player',
|
||||
content:function(){
|
||||
'step 0'
|
||||
if(player.storage.sidi.length==1){
|
||||
event.directbutton=player.storage.sidi[0];
|
||||
var cards=player.getExpansions('sidi');
|
||||
if(cards.length==1){
|
||||
event.directbutton=cards[0];
|
||||
}
|
||||
else{
|
||||
player.chooseCardButton('弃置一张“司敌”牌',player.storage.sidi,true);
|
||||
player.chooseCardButton('弃置一张“司敌”牌',cards,true);
|
||||
}
|
||||
'step 1'
|
||||
var button;
|
||||
|
@ -6044,20 +6020,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
button=result.links[0];
|
||||
}
|
||||
if(button){
|
||||
player.$throw([button]);
|
||||
game.log(player,'将',button,'置于弃牌堆');
|
||||
game.cardsDiscard(button);
|
||||
player.loseToDiscardpile('sidi');
|
||||
trigger.player.addTempSkill('sidi3');
|
||||
trigger.player.addMark('sidi3',1,false);
|
||||
player.storage.sidi.remove(button);
|
||||
player.syncStorage('sidi');
|
||||
if(player.storage.sidi.length==0){
|
||||
player.unmarkSkill('sidi');
|
||||
}
|
||||
else{
|
||||
player.markSkill('sidi');
|
||||
}
|
||||
game.delayx();
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@ -7807,19 +7772,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
content:function(){
|
||||
'step 0'
|
||||
player.choosePlayerCard(trigger.target,'he',
|
||||
[1,Math.min(trigger.target.countCards('he'),trigger.target.hp)],get.prompt('xinpojun',trigger.target));
|
||||
[1,Math.min(trigger.target.countCards('he'),trigger.target.hp)],get.prompt('xinpojun',trigger.target)).set('forceAuto',true);
|
||||
'step 1'
|
||||
if(result.bool&&result.links.length){
|
||||
player.logSkill('xinpojun',trigger.target);
|
||||
if(trigger.target.storage.xinpojun2){
|
||||
trigger.target.storage.xinpojun2=trigger.target.storage.xinpojun2.concat(result.links);
|
||||
}
|
||||
else{
|
||||
trigger.target.storage.xinpojun2=result.links.slice(0);
|
||||
}
|
||||
game.addVideo('storage',trigger.target,['xinpojun2',get.cardsInfo(trigger.target.storage.xinpojun2),'cards']);
|
||||
trigger.target.addSkill('xinpojun2');
|
||||
trigger.target.lose(result.links,ui.special,'toStorage');
|
||||
var target=trigger.target;
|
||||
player.logSkill('xinpojun',target);
|
||||
target.addToExpansion(result.cards,'giveAuto',target).gaintag.add('xinpojun2');
|
||||
target.addSkill('xinpojun2');
|
||||
}
|
||||
},
|
||||
ai:{
|
||||
|
@ -7836,41 +7795,27 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
xinpojun2:{
|
||||
trigger:{global:'phaseEnd'},
|
||||
forced:true,
|
||||
audio:false,
|
||||
mark:true,
|
||||
popup:false,
|
||||
charlotte:true,
|
||||
filter:function(event,player){
|
||||
return player.getExpansions('xinpojun2').length>0;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
var cards=player.getExpansions('xinpojun2');
|
||||
player.gain(cards,'draw');
|
||||
game.log(player,'收回了'+get.cnNumber(cards.length)+'张“破军”牌');
|
||||
'step 1'
|
||||
player.removeSkill('xinpojun2');
|
||||
},
|
||||
intro:{
|
||||
content:'cardCount',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
markcount:'expansion',
|
||||
mark:function(dialog,storage,player){
|
||||
var cards=player.getExpansions('xinpojun2');
|
||||
if(player.isUnderControl(true)) dialog.addAuto(cards);
|
||||
else return '共有'+get.cnNumber(cards.length)+'张牌';
|
||||
},
|
||||
},
|
||||
content:function(){
|
||||
if(player.storage.xinpojun2){
|
||||
player.gain(player.storage.xinpojun2,'fromStorage');
|
||||
delete player.storage.xinpojun2;
|
||||
}
|
||||
player.removeSkill('xinpojun2');
|
||||
},
|
||||
//group:'xinpojun3'
|
||||
},
|
||||
xinpojun3:{
|
||||
trigger:{player:'dieBegin'},
|
||||
forced:true,
|
||||
popup:false,
|
||||
content:function(){
|
||||
player.$throw(player.storage.xinpojun2,1000);
|
||||
for(var i=0;i<player.storage.xinpojun2.length;i++){
|
||||
game.cardsDiscard(player.storage.xinpojun2);
|
||||
}
|
||||
game.log(player,'弃置了',player.storage.xinpojun2);
|
||||
delete player.storage.xinpojun2;
|
||||
player.removeSkill('xinpojun2');
|
||||
}
|
||||
},
|
||||
qiaoshi:{
|
||||
audio:2,
|
||||
|
@ -9240,9 +9185,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
frequent:true,
|
||||
locked:false,
|
||||
notemp:true,
|
||||
init:function(player){
|
||||
if(!player.storage.quanji) player.storage.quanji=[];
|
||||
},
|
||||
filter:function(event){
|
||||
return event.num>0;
|
||||
},
|
||||
|
@ -9261,11 +9203,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
"step 3"
|
||||
if(result.cards&&result.cards.length){
|
||||
player.lose(result.cards,ui.special,'toStorage');
|
||||
player.storage.quanji=player.storage.quanji.concat(result.cards);
|
||||
player.syncStorage('quanji');
|
||||
player.markSkill('quanji');
|
||||
game.log(player,'将',result.cards,'置于武将牌上作为“权”');
|
||||
player.addToExpansion(result.cards,player,'giveAuto').gaintag.add('quanji');
|
||||
}
|
||||
"step 4"
|
||||
if(event.count>0){
|
||||
|
@ -9279,19 +9217,16 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
},
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
mod:{
|
||||
maxHandcard:function(player,num){
|
||||
return num+player.storage.quanji.length;
|
||||
return num+player.getExpansions('quanji').length;
|
||||
}
|
||||
},
|
||||
ai:{
|
||||
|
@ -9322,7 +9257,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{player:'phaseZhunbeiBegin'},
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
return !player.hasSkill('paiyi')&&player.storage.quanji&&player.storage.quanji.length>=3;
|
||||
return !player.hasSkill('paiyi')&&player.getExpansions('quanji').length>=3;
|
||||
},
|
||||
content:function(){
|
||||
"step 0"
|
||||
|
@ -9342,11 +9277,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:2,
|
||||
audioname:['re_zhonghui'],
|
||||
filter:function(event,player){
|
||||
return player.storage.quanji&&player.storage.quanji.length>0;
|
||||
return player.getExpansions('quanji').length>0;
|
||||
},
|
||||
chooseButton:{
|
||||
dialog:function(event,player){
|
||||
return ui.create.dialog('排异',player.storage.quanji,'hidden')
|
||||
return ui.create.dialog('排异',player.getExpansions('quanji'),'hidden')
|
||||
},
|
||||
backup:function(links,player){
|
||||
return {
|
||||
|
@ -9375,18 +9310,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
contentx:function(){
|
||||
"step 0"
|
||||
var card=lib.skill.paiyi_backup.card;
|
||||
game.cardsDiscard(card);
|
||||
player.$throw(card);
|
||||
player.storage.quanji.remove(card);
|
||||
game.log(card,'进入了弃牌堆');
|
||||
if(!player.storage.quanji.length){
|
||||
player.unmarkSkill('quanji');
|
||||
}
|
||||
else{
|
||||
player.markSkill('quanji');
|
||||
}
|
||||
player.syncStorage('quanji');
|
||||
game.delayx();
|
||||
player.loseToDiscardpile(card);
|
||||
"step 1"
|
||||
target.draw(2);
|
||||
"step 2"
|
||||
|
@ -10966,7 +10890,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audioname:['boss_lvbu3','re_heqi'],
|
||||
trigger:{
|
||||
player:['loseAfter','phaseDiscardEnd'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
|
@ -11645,9 +11569,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:2,
|
||||
trigger:{player:'phaseZhunbeiBegin'},
|
||||
direct:true,
|
||||
init:function(player){
|
||||
if(!player.storage.xiansi) player.storage.xiansi=[];
|
||||
},
|
||||
content:function(){
|
||||
"step 0"
|
||||
player.chooseTarget(get.prompt2('xiansi'),[1,2],function(card,player,target){
|
||||
|
@ -11675,24 +11596,17 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
"step 3"
|
||||
if(result.bool){
|
||||
player.storage.xiansi=player.storage.xiansi.concat(result.links);
|
||||
player.markSkill('xiansi');
|
||||
player.syncStorage('xiansi');
|
||||
event.current.lose(result.links,ui.special,'toStorage');
|
||||
event.current.$give(result.links,player,false);
|
||||
player.addToExpansion(result.cards,event.current,'give').gaintag.add('xiansi');
|
||||
event.goto(2);
|
||||
}
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
},
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
ai:{
|
||||
threaten:2
|
||||
|
@ -11705,16 +11619,16 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
viewAs:{name:'sha',isCard:true},
|
||||
filter:function(event,player){
|
||||
return game.hasPlayer(function(current){
|
||||
return current.hasSkill('xiansi')&¤t.storage.xiansi.length>1&&event.filterTarget({name:'sha'},player,current);
|
||||
return current.hasSkill('xiansi')&¤t.getExpansions('xiansi').length>1&&event.filterTarget({name:'sha'},player,current);
|
||||
});
|
||||
},
|
||||
filterTarget:function(card,player,target){
|
||||
var bool=false;
|
||||
var players=ui.selected.targets.slice(0);
|
||||
for(var i=0;i<players.length;i++){
|
||||
if(players[i].hasSkill('xiansi')&&players[i].storage.xiansi.length>1) bool=true;break;
|
||||
if(players[i].hasSkill('xiansi')&&players[i].getExpansions('xiansi').length>1) bool=true;break;
|
||||
}
|
||||
if(!bool&&(!target.hasSkill('xiansi')||target.storage.xiansi.length<=1)) return false;
|
||||
if(!bool&&(!target.hasSkill('xiansi')||target.getExpansions('xiansi').length<=1)) return false;
|
||||
return _status.event._backup.filterTarget.apply(this,arguments);
|
||||
},
|
||||
complexSelect:true,
|
||||
|
@ -11730,8 +11644,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
precontent:function(){
|
||||
"step 0"
|
||||
var targets=game.filterPlayer(function(current){
|
||||
if(event.result.targets.contains(current)&¤t.storage.xiansi){
|
||||
return current.storage.xiansi.length>1;
|
||||
if(event.result.targets.contains(current)&¤t.getExpansions('xiansi')){
|
||||
return current.getExpansions('xiansi').length>1;
|
||||
}
|
||||
return false;
|
||||
});
|
||||
|
@ -11740,7 +11654,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
event.goto(2);
|
||||
}
|
||||
else if(targets.length>0){
|
||||
player.chooseTarget(true,'选择【陷嗣】的目标',function(card,player,target){
|
||||
player.chooseTarget(true,'选择弃置【陷嗣】牌的目标',function(card,player,target){
|
||||
return _status.event.list.contains(target);
|
||||
}).set('list',targets).set('ai',function(target){
|
||||
var player=_status.event.player;
|
||||
|
@ -11759,11 +11673,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
"step 2"
|
||||
if(event.target){
|
||||
if(event.target.storage.xiansi.length==2){
|
||||
event.directresult=event.target.storage.xiansi.slice(0);
|
||||
if(event.target.getExpansions('xiansi').length==2){
|
||||
event.directresult=event.target.getExpansions('xiansi').slice(0);
|
||||
}
|
||||
else{
|
||||
player.chooseCardButton('移去两张“逆”',2,event.target.storage.xiansi,true);
|
||||
player.chooseCardButton('移去两张“逆”',2,event.target.getExpansions('xiansi'),true);
|
||||
}
|
||||
}
|
||||
else{
|
||||
|
@ -11773,19 +11687,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
if(event.directresult||result.bool){
|
||||
player.logSkill('xiansi2',event.target);
|
||||
var links=event.directresult||result.links;
|
||||
for(var i=0;i<links.length;i++){
|
||||
event.target.storage.xiansi.remove(links[i]);
|
||||
}
|
||||
event.target.syncStorage('xiansi');
|
||||
if(!event.target.storage.xiansi.length){
|
||||
event.target.unmarkSkill('xiansi');
|
||||
}
|
||||
else{
|
||||
event.target.markSkill('xiansi');
|
||||
}
|
||||
event.target.$throw(links);
|
||||
game.log(event.target,'被移去了',links);
|
||||
game.cardsDiscard(links);
|
||||
target.loseToDiscardpile(links);
|
||||
}
|
||||
},
|
||||
ai:{
|
||||
|
@ -11990,9 +11892,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
init:function(player){
|
||||
player.storage.zbaijiang=false;
|
||||
},
|
||||
// intro:{
|
||||
// content:'limited'
|
||||
// },
|
||||
filter:function(event,player){
|
||||
return !player.storage.zbaijiang&&player.countCards('e')>=2;
|
||||
},
|
||||
|
@ -12009,56 +11908,40 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
zyexin:{
|
||||
trigger:{player:'damageEnd',source:'damageSource'},
|
||||
frequent:true,
|
||||
init:function(player){
|
||||
if(!player.storage.zyexin) player.storage.zyexin=[];
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
},
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
content:function(){
|
||||
var card=game.cardsGotoSpecial(get.cards()).cards[0];
|
||||
player.storage.zyexin.push(card);
|
||||
player.$draw(card);
|
||||
player.markSkill('zyexin');
|
||||
game.addVideo('storage',player,['zyexin',get.cardsInfo(player.storage.zyexin),'cards']);
|
||||
player.addToExpansion('zyexin',get.cards()).gaintag.add('zyexin');
|
||||
},
|
||||
group:'zyexin2'
|
||||
group:'zyexin2',
|
||||
},
|
||||
zyexin2:{
|
||||
enable:'phaseUse',
|
||||
usable:1,
|
||||
lose:false,
|
||||
discard:false,
|
||||
delay:false,
|
||||
selectCard:[1,Infinity],
|
||||
filterCard:true,
|
||||
filter:function(event,player){
|
||||
return player.storage.zyexin.length>0;
|
||||
return player.getExpansions('zyexin').length>0;
|
||||
},
|
||||
prompt:'用任意数量的手牌与等量的“权”交换',
|
||||
content:function(){
|
||||
"step 0"
|
||||
player.lose(cards,ui.special,'toStorage');
|
||||
player.storage.zyexin=player.storage.zyexin.concat(cards);
|
||||
player.chooseCardButton(player.storage.zyexin,'选择'+cards.length+'张牌作为手牌',cards.length,true).ai=function(button){
|
||||
'step 0'
|
||||
player.addToExpansion(cards,'give',player).gaintag.add('zyexin');
|
||||
'step 1'
|
||||
player.chooseCardButton(player.getExpansions('zyexin'),'选择'+cards.length+'张牌作为手牌',cards.length,true).ai=function(button){
|
||||
return get.value(button.link);
|
||||
}
|
||||
if(player==game.me&&_status.auto){
|
||||
game.delay();
|
||||
}
|
||||
"step 1"
|
||||
player.gain(result.links,'toStorage');
|
||||
for(var i=0;i<result.links.length;i++){
|
||||
player.storage.zyexin.remove(result.links[i]);
|
||||
}
|
||||
game.addVideo('storage',player,['zyexin',get.cardsInfo(player.storage.zyexin),'cards']);
|
||||
'step 2'
|
||||
player.gain(result.links,'gain2');
|
||||
},
|
||||
ai:{
|
||||
order:5,
|
||||
|
@ -12076,7 +11959,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
derivation:'zpaiyi',
|
||||
trigger:{player:'phaseZhunbeiBegin'},
|
||||
filter:function(event,player){
|
||||
return player.storage.zyexin.length>=4&&!player.storage.zzili;
|
||||
return player.getExpansions('zyexin').length>=4&&!player.storage.zzili;
|
||||
},
|
||||
forced:true,
|
||||
content:function(){
|
||||
|
@ -12092,8 +11975,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
zpaiyi:{
|
||||
trigger:{player:'phaseJieshuBegin'},
|
||||
filter:function(event,player){
|
||||
for(var i=0;i<player.storage.zyexin.length;i++){
|
||||
var type=get.type(player.storage.zyexin[i]);
|
||||
var cards=player.getExpansions('zyexin');
|
||||
for(var i=0;i<cards.length;i++){
|
||||
var type=get.type(cards[i]);
|
||||
if(type=='delay'||type=='equip') return true;
|
||||
}
|
||||
return false;
|
||||
|
@ -12101,7 +11985,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
direct:true,
|
||||
content:function(){
|
||||
"step 0"
|
||||
var next=player.chooseCardButton(get.prompt('zpaiyi'),player.storage.zyexin);
|
||||
var next=player.chooseCardButton(get.prompt('zpaiyi'),player.getExpansions('zyexin'));
|
||||
next.set('filterButton',function(button){
|
||||
var type=get.type(button.link);
|
||||
if(type=='delay'||type=='equip') return true;
|
||||
|
@ -12131,9 +12015,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
"step 2"
|
||||
if(result.bool){
|
||||
player.storage.zyexin.remove(event.card);
|
||||
game.addVideo('storage',player,['zyexin',get.cardsInfo(player.storage.zyexin),'cards']);
|
||||
game.delay();
|
||||
if(get.type(event.card)=='equip'){
|
||||
player.$give(event.card,result.targets[0],false);
|
||||
result.targets[0].equip(event.card);
|
||||
|
@ -12414,9 +12295,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
jiaozhao2:'矫诏',
|
||||
jiaozhao_info:'出牌阶段限一次,你可以展示一张手牌,然后选择距离最近的一名其他角色,该角色声明一张基本牌的牌名。在此出牌阶段内,你可以将此手牌当声明的牌使用(你不能对自己使用此牌)。',
|
||||
danxin:'殚心',
|
||||
danxin_info:'当你受到伤害后,你可以摸一张牌,或对“矫诏”的描述依次执行下列一项修改:1.将“基本牌”改为“基本牌或普通锦囊牌”;2.将“选择距离最近的一名其他角色,该角色”改为“你”。3.将“出牌阶段限一次”改为“出牌阶段限两次”',
|
||||
danxin_info:'当你受到伤害后,你可以摸一张牌,或对“矫诏”的描述依次执行下列一项修改:1.将“基本牌”改为“基本牌或普通锦囊牌”;2.将“选择距离最近的一名其他角色,该角色”改为“你”。',
|
||||
xindanxin:'殚心',
|
||||
xindanxin_info:'当你受到伤害后,你可以摸一张牌,并对“矫诏”的描述依次执行下列一项修改:1.将“基本牌”改为“基本牌或普通锦囊牌”;2.将“选择距离最近的一名其他角色,该角色”改为“你”。',
|
||||
xindanxin_info:'当你受到伤害后,你可以摸一张牌,并对“矫诏”的描述依次执行下列一项修改:1.将“基本牌”改为“基本牌或普通锦囊牌”;2.将“选择距离最近的一名其他角色,该角色”改为“你”。3.将“出牌阶段限一次”改为“出牌阶段限两次”',
|
||||
duliang:'督粮',
|
||||
duliang2:'督粮',
|
||||
duliang_info:'出牌阶段限一次,你可以获得一名其他角色的一张手牌,然后选择一项:1.令其观看牌堆顶的两张牌,然后获得其中的基本牌;2.令其于下个摸牌阶段额外摸一张牌。',
|
||||
|
|
|
@ -85,7 +85,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:'qimei',
|
||||
charlotte:true,
|
||||
forced:true,
|
||||
trigger:{global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','loseAfter','gainAfter']},
|
||||
trigger:{global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','loseAfter','gainAfter','addToExpansionAfter']},
|
||||
logTarget:function(event,player){
|
||||
return player.storage.qimei_draw;
|
||||
},
|
||||
|
@ -300,7 +300,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
filter:function(event,player){
|
||||
return event.card.name=='sha'&&event.card.isCard&&event.getParent(2).name!='maihuo_effect'&&
|
||||
event.cards.filterInD().length>0&&event.targets.length==1&&
|
||||
event.player.isIn()&&(!event.player.storage.maihuo_effect||!event.player.storage.maihuo_effect.length);
|
||||
event.player.isIn()&&(!event.player.getExpansions('maihuo_effect').length);
|
||||
},
|
||||
prompt2:function(event){
|
||||
return '令'+get.translation(event.card)+'暂时对你无效';
|
||||
|
@ -311,8 +311,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
content:function(){
|
||||
trigger.excluded.add(player);
|
||||
var target=trigger.player,cards=trigger.cards.filterInD();
|
||||
game.cardsGotoSpecial(cards);
|
||||
target.markAuto('maihuo_effect',cards);
|
||||
target.addToExpansion('gain2',cards).gaintag.add('maihuo_effect');
|
||||
target.storage.maihuo_target=player;
|
||||
target.addSkill('maihuo_effect')
|
||||
},
|
||||
|
@ -323,24 +322,30 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
forced:true,
|
||||
charlotte:true,
|
||||
filter:function(event,player){
|
||||
return player.storage.maihuo_effect&&player.storage.maihuo_effect.length>0;
|
||||
return player.getExpansions('maihuo_effect').length>0;
|
||||
},
|
||||
content:function(){
|
||||
var card=player.storage.maihuo_effect[0];
|
||||
'step 0'
|
||||
var cards=player.getExpansions('maihuo_effect'),card=cards[0];
|
||||
if(card.name!='sha') card=get.autoViewAs({
|
||||
name:'sha',
|
||||
isCard:true,
|
||||
},player.storage.maihuo_effect);
|
||||
},cards);
|
||||
var target=player.storage.maihuo_target;
|
||||
if(target.isIn()&&player.canUse(card,target,null,true)){
|
||||
player.useCard(card,target,player.storage.maihuo_effect);
|
||||
delete player.storage.maihuo_effect;
|
||||
player.useCard(card,target,cards);
|
||||
}
|
||||
else event.finish();
|
||||
'step 1'
|
||||
player.removeSkill('maihuo_effect');
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:'throw',
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
ai:{threaten:1.05},
|
||||
},
|
||||
|
@ -1024,7 +1029,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:'zhongyun',
|
||||
trigger:{
|
||||
player:['loseAfter','gainAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
|
@ -1169,7 +1174,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
audio:'chexuan',
|
||||
trigger:{
|
||||
player:'loseAfter',
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
frequent:true,
|
||||
filter:function(event,player){
|
||||
|
@ -1333,13 +1338,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
logTarget:'source',
|
||||
content:function(){
|
||||
'step 0'
|
||||
var cards=player.getStorage('qiaoyan');
|
||||
var cards=player.getExpansions('qiaoyan');
|
||||
if(cards.length){
|
||||
var source=trigger.source;
|
||||
player.$give(cards,source,false);
|
||||
source.gain(cards,'log');
|
||||
player.unmarkAuto('qiaoyan',cards);
|
||||
event.goto(3);
|
||||
source.gain(cards,player,'give');
|
||||
event.finish();
|
||||
}
|
||||
else{
|
||||
trigger.cancel();
|
||||
|
@ -1353,17 +1356,16 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
'step 2'
|
||||
if(result.bool&&result.cards&&result.cards.length){
|
||||
var cards=result.cards;
|
||||
player.lose(cards,ui.special,'visible','toStorage');
|
||||
player.$give(cards,player,false);
|
||||
player.markAuto('qiaoyan',cards);
|
||||
game.log(player,'将',cards,'放在了武将牌上');
|
||||
player.addToExpansion(cards,player,'give').gaintag.add('qiaoyan');
|
||||
}
|
||||
event.finish();
|
||||
'step 3'
|
||||
game.delayx();
|
||||
},
|
||||
marktext:'珠',
|
||||
intro:{content:'cards',onunmark:'throw'},
|
||||
intro:{content:'expansion',markcount:'expansion'},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
ai:{
|
||||
filterDamage:true,
|
||||
skillTagFilter:function(player,tag,arg){
|
||||
|
@ -1380,11 +1382,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
direct:true,
|
||||
locked:true,
|
||||
filter:function(event,player){
|
||||
return player.storage.qiaoyan&&player.storage.qiaoyan.length>0;
|
||||
return player.getExpansions('qiaoyan').length>0;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
event.cards=player.storage.qiaoyan;
|
||||
event.cards=player.getExpansions('qiaoyan');
|
||||
player.chooseTarget(true,'请选择【献珠】的目标','令一名角色获得'+get.translation(event.cards)+'。若该角色不为你自己,则你令其视为对其攻击范围内的另一名角色使用【杀】').set('ai',function(target){
|
||||
var player=_status.event.player;
|
||||
var eff=get.sgn(get.attitude(player,target))*get.value(_status.event.getParent().cards[0],target);
|
||||
|
@ -1400,13 +1402,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
var target=result.targets[0];
|
||||
event.target=target;
|
||||
player.logSkill('xianzhu',target);
|
||||
player.$give(cards,target,false);
|
||||
target.gain(cards,'log');
|
||||
player.unmarkAuto('qiaoyan',cards);
|
||||
target.gain(cards,player,'give');
|
||||
}
|
||||
else event.finish();
|
||||
'step 2'
|
||||
game.delayx();
|
||||
if(player!=target&&target.isIn()&&player.isIn()&&game.hasPlayer(function(current){
|
||||
return current!=target&&target.inRange(current)&&target.canUse('sha',current);
|
||||
})){
|
||||
|
@ -2175,7 +2174,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
global:'zhaoran3',
|
||||
trigger:{
|
||||
player:'loseAfter',
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
forced:true,
|
||||
charlotte:true,
|
||||
|
|
|
@ -424,6 +424,7 @@ window.noname_asset_list=[
|
|||
'audio/effect/tie.mp3',
|
||||
'audio/effect/win.mp3',
|
||||
'audio/effect/tori_no_uta.mp3',
|
||||
'audio/effect/taketori_hishou.mp3',
|
||||
|
||||
'audio/die/beimihu.mp3',
|
||||
'audio/die/boss_lvbu1.mp3',
|
||||
|
@ -840,6 +841,12 @@ window.noname_asset_list=[
|
|||
'audio/die/sp_yangwan.mp3',
|
||||
'audio/die/xin_jushou.mp3',
|
||||
'audio/die/yj_huangzhong.mp3',
|
||||
'audio/die/sp_maojie.mp3',
|
||||
'audio/die/sp_zhujun.mp3',
|
||||
'audio/die/wangtao.mp3',
|
||||
'audio/die/wangyue.mp3',
|
||||
'audio/die/wuyan.mp3',
|
||||
'audio/die/xin_sunxiu.mp3',
|
||||
|
||||
'audio/skill/decadezishou1.mp3',
|
||||
'audio/skill/decadezishou2.mp3',
|
||||
|
@ -3824,6 +3831,33 @@ window.noname_asset_list=[
|
|||
'audio/skill/spyishi2.mp3',
|
||||
'audio/skill/xinjianying1.mp3',
|
||||
'audio/skill/xinjianying2.mp3',
|
||||
'audio/skill/bingqing1.mp3',
|
||||
'audio/skill/bingqing2.mp3',
|
||||
'audio/skill/houfeng1.mp3',
|
||||
'audio/skill/houfeng2.mp3',
|
||||
'audio/skill/houfeng3.mp3',
|
||||
'audio/skill/huguan_wangyue1.mp3',
|
||||
'audio/skill/huguan_wangyue2.mp3',
|
||||
'audio/skill/huguan1.mp3',
|
||||
'audio/skill/huguan2.mp3',
|
||||
'audio/skill/lanjiang1.mp3',
|
||||
'audio/skill/lanjiang2.mp3',
|
||||
'audio/skill/liubing1.mp3',
|
||||
'audio/skill/liubing2.mp3',
|
||||
'audio/skill/mingluan1.mp3',
|
||||
'audio/skill/mingluan2.mp3',
|
||||
'audio/skill/mobilexingxue1.mp3',
|
||||
'audio/skill/mobilexingxue2.mp3',
|
||||
'audio/skill/mobileyanzhu1.mp3',
|
||||
'audio/skill/mobileyanzhu2.mp3',
|
||||
'audio/skill/yangjie1.mp3',
|
||||
'audio/skill/yangjie2.mp3',
|
||||
'audio/skill/yaopei1.mp3',
|
||||
'audio/skill/yaopei2.mp3',
|
||||
'audio/skill/yingfeng1.mp3',
|
||||
'audio/skill/yingfeng2.mp3',
|
||||
'audio/skill/zjjuxiang1.mp3',
|
||||
'audio/skill/zjjuxiang2.mp3',
|
||||
|
||||
'audio/voice/male/0.mp3',
|
||||
'audio/voice/male/1.mp3',
|
||||
|
|
366
game/game.js
366
game/game.js
|
@ -11067,7 +11067,6 @@
|
|||
}
|
||||
game.updateRenku();
|
||||
}
|
||||
if(event.notrigger!==true) event.trigger('addCardToStorage');
|
||||
},
|
||||
chooseToEnable:function(){
|
||||
'step 0'
|
||||
|
@ -14731,14 +14730,17 @@
|
|||
return;
|
||||
}
|
||||
if(!get.info(card,false).noForceDie) event.forceDie=true;
|
||||
var next=player.lose(cards,'visible',ui.ordering).set('type','use');
|
||||
var directDiscard=[];
|
||||
for(var i=0;i<cards.length;i++){
|
||||
if(!next.cards.contains(cards[i])){
|
||||
directDiscard.push(cards[i]);
|
||||
if(cards.length){
|
||||
var owner=get.owner(cards[0]);
|
||||
var next=owner.lose(cards,'visible',ui.ordering).set('type','use');
|
||||
var directDiscard=[];
|
||||
for(var i=0;i<cards.length;i++){
|
||||
if(!next.cards.contains(cards[i])){
|
||||
directDiscard.push(cards[i]);
|
||||
}
|
||||
}
|
||||
if(directDiscard.length) game.cardsGotoOrdering(directDiscard);
|
||||
}
|
||||
if(directDiscard.length) game.cardsGotoOrdering(directDiscard);
|
||||
//player.using=cards;
|
||||
var cardaudio=true;
|
||||
if(event.skill){
|
||||
|
@ -15446,6 +15448,14 @@
|
|||
"step 1"
|
||||
event.trigger('discard');
|
||||
},
|
||||
loseToDiscardpile:function(){
|
||||
"step 0"
|
||||
game.log(player,'将',cards,'置入了弃牌堆');
|
||||
event.done=player.lose(cards,event.position,'visible');
|
||||
event.done.type='loseToDiscardpile';
|
||||
"step 1"
|
||||
event.trigger('loseToDiscardpile');
|
||||
},
|
||||
respond:function(){
|
||||
'step 0'
|
||||
var cardaudio=true;
|
||||
|
@ -15486,15 +15496,16 @@
|
|||
game.log(player,'打出了',card);
|
||||
}
|
||||
player.actionHistory[player.actionHistory.length-1].respond.push(event);
|
||||
var cards2=cards.slice(0);
|
||||
if(cards2.length){
|
||||
var next=player.lose(cards2,ui.ordering,'visible');
|
||||
if(event.noOrdering) next.noOrdering=true;
|
||||
cards2.removeArray(next.cards);
|
||||
if(cards2.length){
|
||||
var next2=game.cardsGotoOrdering(cards2);
|
||||
if(event.noOrdering) next2.noOrdering=true;
|
||||
if(cards.length){
|
||||
var owner=get.owner(cards[0]);
|
||||
var next=owner.lose(cards,'visible',ui.ordering).set('type','use');
|
||||
var directDiscard=[];
|
||||
for(var i=0;i<cards.length;i++){
|
||||
if(!next.cards.contains(cards[i])){
|
||||
directDiscard.push(cards[i]);
|
||||
}
|
||||
}
|
||||
if(directDiscard.length) game.cardsGotoOrdering(directDiscard);
|
||||
}
|
||||
if(event.animate!=false&&event.throw!==false){
|
||||
for(var i=0;i<cards.length;i++){
|
||||
|
@ -15745,10 +15756,130 @@
|
|||
"step 4"
|
||||
game.delayx();
|
||||
},
|
||||
addToExpansion:function(){
|
||||
"step 0"
|
||||
if(event.animate=='give') event.visible=true;
|
||||
if(cards){
|
||||
var map={};
|
||||
for(var i of cards){
|
||||
var owner=get.owner(i,'judge');
|
||||
if(owner&&get.position(i)!='x'){
|
||||
var id=owner.playerid;
|
||||
if(!map[id]) map[id]=[];
|
||||
map[id].push(i);
|
||||
}
|
||||
}
|
||||
for(var i in map){
|
||||
var owner=(_status.connectMode?lib.playerOL:game.playerMap)[i];
|
||||
var next=owner.lose(map[i],ui.special).set('type','loseToExpansion').set('forceDie',true).set('getlx',false);
|
||||
if(event.visible==true) next.visible=true;
|
||||
event.relatedLose=next;
|
||||
}
|
||||
}
|
||||
else{
|
||||
event.finish();
|
||||
}
|
||||
"step 1"
|
||||
for(var i=0;i<cards.length;i++){
|
||||
if(cards[i].destroyed){
|
||||
if(player.hasSkill(cards[i].destroyed)){
|
||||
delete cards[i].destroyed;
|
||||
}
|
||||
else{
|
||||
cards.splice(i--,1);
|
||||
}
|
||||
}
|
||||
}
|
||||
if(cards.length==0){
|
||||
event.finish();
|
||||
return;
|
||||
}
|
||||
"step 2"
|
||||
var hs=player.getCards('x');
|
||||
for(var i=0;i<cards.length;i++){
|
||||
if(hs.contains(cards[i])){
|
||||
cards.splice(i--,1);
|
||||
}
|
||||
}
|
||||
for(var num=0;num<cards.length;num++){
|
||||
if(_status.discarded){
|
||||
_status.discarded.remove(cards[num]);
|
||||
}
|
||||
for(var num2=0;num2<cards[num].vanishtag.length;num2++){
|
||||
if(cards[num].vanishtag[num2][0]!='_'){
|
||||
cards[num].vanishtag.splice(num2--,1);
|
||||
}
|
||||
}
|
||||
}
|
||||
if(event.animate=='draw'){
|
||||
player.$draw(cards.length);
|
||||
game.log(player,'将',get.cnNumber(cards.length),'张牌置于了武将牌上');
|
||||
game.pause();
|
||||
setTimeout(function(){
|
||||
player.$addToExpansion(cards,null,event.gaintag);
|
||||
for(var i of event.gaintag) player.markSkill(i);
|
||||
game.resume();
|
||||
},get.delayx(500,500));
|
||||
}
|
||||
else if(event.animate=='gain'){
|
||||
player.$gain(cards,false);
|
||||
game.pause();
|
||||
setTimeout(function(){
|
||||
player.$addToExpansion(cards,null,event.gaintag);
|
||||
for(var i of event.gaintag) player.markSkill(i);
|
||||
game.resume();
|
||||
},get.delayx(700,700));
|
||||
}
|
||||
else if(event.animate=='gain2'||event.animate=='draw2'){
|
||||
var gain2t=300;
|
||||
if(player.$gain2(cards)&&player==game.me){
|
||||
gain2t=500;
|
||||
}
|
||||
game.pause();
|
||||
setTimeout(function(){
|
||||
player.$addToExpansion(cards,null,event.gaintag);
|
||||
for(var i of event.gaintag) player.markSkill(i);
|
||||
game.resume();
|
||||
},get.delayx(gain2t,gain2t));
|
||||
}
|
||||
else if(event.source&&(event.animate=='give'||event.animate=='giveAuto')){
|
||||
if(event.animate=='give') event.source['$'+event.animate](cards,player,false);
|
||||
else{
|
||||
var givemap={hs:[],ots:[]};
|
||||
for(var i=0;i<cards.length;i++){
|
||||
givemap[event.relatedLose&&event.relatedLose.hs&&event.relatedLose.hs.contains(cards[i])?'hs':'ots'].push(cards[i]);
|
||||
}
|
||||
if(givemap.hs.length){
|
||||
event.source.$giveAuto(givemap.hs,player,false);
|
||||
game.log(player,'将',get.cnNumber(givemap.hs.length),'张牌置于了武将牌上');
|
||||
}
|
||||
if(givemap.ots.length){
|
||||
event.source.$give(givemap.ots,player,false);
|
||||
game.log(player,'将',givemap.ots,'置于了武将牌上');
|
||||
}
|
||||
}
|
||||
game.pause();
|
||||
setTimeout(function(){
|
||||
player.$addToExpansion(cards,null,event.gaintag);
|
||||
for(var i of event.gaintag) player.markSkill(i);
|
||||
game.resume();
|
||||
},get.delayx(500,500));
|
||||
}
|
||||
else{
|
||||
player.$addToExpansion(cards,null,event.gaintag);
|
||||
for(var i of event.gaintag) player.markSkill(i);
|
||||
event.finish();
|
||||
}
|
||||
if(event.log){
|
||||
game.log(player,'将',cards,'置于了武将牌上');
|
||||
}
|
||||
"step 4"
|
||||
game.delayx();
|
||||
},
|
||||
lose:function(){
|
||||
"step 0"
|
||||
var evt=event.getParent();
|
||||
if(evt.name!='discard'&&event.type!='discard'){
|
||||
if((evt.name!='discard'&&event.type!='discard')&&(evt.name!='loseToDiscardpile'&&event.type!='loseToDiscardpile')){
|
||||
event.delay=false;
|
||||
return;
|
||||
}
|
||||
|
@ -15792,15 +15923,12 @@
|
|||
}
|
||||
"step 1"
|
||||
event.gaintag_map={};
|
||||
var hs=[],es=[],js=[],ss=[];
|
||||
var hs=[],es=[],js=[],ss=[],xs=[];
|
||||
var unmarks=[];
|
||||
if(event.insert_card&&event.position==ui.cardPile) event.cards.reverse();
|
||||
var hej=player.getCards('hejs');
|
||||
var hej=player.getCards('hejsx');
|
||||
event.stockcards=cards.slice(0);
|
||||
for(var i=0;i<cards.length;i++){
|
||||
if(cards[i].gaintag&&cards[i].gaintag.length){
|
||||
event.gaintag_map[cards[i].cardid]=cards[i].gaintag.slice(0);
|
||||
cards[i].removeGaintag(true);
|
||||
}
|
||||
if(!hej.contains(cards[i])){
|
||||
cards.splice(i--,1);
|
||||
continue;
|
||||
|
@ -15814,6 +15942,11 @@
|
|||
cards[i].original='j';
|
||||
js.push(cards[i]);
|
||||
}
|
||||
else if(cards[i].parentNode.classList.contains('expansions')){
|
||||
cards[i].original='x';
|
||||
xs.push(cards[i]);
|
||||
if(cards[i].gaintag&&cards[i].gaintag.length) unmarks.addArray(cards[i].gaintag);
|
||||
}
|
||||
else if(cards[i].parentNode.classList.contains('handcards')){
|
||||
if(cards[i].classList.contains('glows')){
|
||||
cards[i].original='s';
|
||||
|
@ -15828,6 +15961,10 @@
|
|||
cards[i].original=null;
|
||||
}
|
||||
}
|
||||
if(cards[i].gaintag&&cards[i].gaintag.length){
|
||||
event.gaintag_map[cards[i].cardid]=cards[i].gaintag.slice(0);
|
||||
cards[i].removeGaintag(true);
|
||||
}
|
||||
|
||||
cards[i].style.transform+=' scale(0.2)';
|
||||
cards[i].classList.remove('glow');
|
||||
|
@ -15906,10 +16043,16 @@
|
|||
else if(event.position==ui.cardPile){
|
||||
game.updateRoundNumber();
|
||||
}
|
||||
if(unmarks.length){
|
||||
for(var i of unmarks){
|
||||
player[(lib.skill[i]&&lib.skill[i].mark||player.hasCard((card)=>card.hasGaintag(i),'x'))?'markSkill':'unmarkSkill'](i);
|
||||
}
|
||||
}
|
||||
event.hs=hs;
|
||||
event.es=es;
|
||||
event.js=js;
|
||||
event.ss=ss;
|
||||
event.xs=xs;
|
||||
"step 2"
|
||||
if(num<cards.length){
|
||||
if(event.es.contains(cards[num])){
|
||||
|
@ -15968,7 +16111,7 @@
|
|||
}
|
||||
"step 5"
|
||||
var evt=event.getParent();
|
||||
if(evt.name!='discard'&&event.type!='discard') return;
|
||||
if((evt.name!='discard'&&event.type!='discard')&&(evt.name!='loseToDiscardpile'&&event.type!='loseToDiscardpile')) return;
|
||||
if(evt.delay!=false){
|
||||
if(evt.waitingForTransition){
|
||||
_status.waitingForTransition=evt.waitingForTransition;
|
||||
|
@ -16373,7 +16516,7 @@
|
|||
if(lib.character[player.name1]) _status.characterlist.add(player.name1);
|
||||
if(lib.character[player.name2]) _status.characterlist.add(player.name2);
|
||||
}
|
||||
event.cards=player.getCards('hejs');
|
||||
event.cards=player.getCards('hejsx');
|
||||
if(event.cards.length){
|
||||
player.discard(event.cards).forceDie=true;
|
||||
//player.$throw(event.cards,1000);
|
||||
|
@ -18252,6 +18395,9 @@
|
|||
if(typeof lib.skill[i].intro.markcount=='function'){
|
||||
num=lib.skill[i].intro.markcount(this.storage[i],this);
|
||||
}
|
||||
else if(lib.skill[i].intro.markcount=='expansion'){
|
||||
num=this.countCards('x',(card)=>card.hasGaintag(i));
|
||||
}
|
||||
else if(typeof this.storage[i+'_markcount']=='number'){
|
||||
num=this.storage[i+'_markcount'];
|
||||
}
|
||||
|
@ -18473,6 +18619,13 @@
|
|||
}
|
||||
}
|
||||
}
|
||||
else if(arg1[i]=='x'){
|
||||
for(j=0;j<this.node.expansions.childElementCount;j++){
|
||||
if(!this.node.expansions.childNodes[j].classList.contains('removing')){
|
||||
cards.push(this.node.expansions.childNodes[j]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if(arguments.length==1){
|
||||
return cards;
|
||||
|
@ -20156,6 +20309,34 @@
|
|||
next.setContent('discard');
|
||||
return next;
|
||||
},
|
||||
loseToDiscardpile:function(){
|
||||
var next=game.createEvent('loseToDiscardpile');
|
||||
next.player=this;
|
||||
next.num=0;
|
||||
for(var i=0;i<arguments.length;i++){
|
||||
if(get.itemtype(arguments[i])=='player'){
|
||||
next.source=arguments[i];
|
||||
}
|
||||
else if(get.itemtype(arguments[i])=='cards'){
|
||||
next.cards=arguments[i].slice(0);
|
||||
}
|
||||
else if(get.itemtype(arguments[i])=='card'){
|
||||
next.cards=[arguments[i]];
|
||||
}
|
||||
else if(typeof arguments[i]=='boolean'){
|
||||
next.animate=arguments[i];
|
||||
}
|
||||
else if(get.objtype(arguments[i])=='div'){
|
||||
next.position=arguments[i];
|
||||
}
|
||||
else if(arguments[i]=='notBySelf'){
|
||||
next.notBySelf=true;
|
||||
}
|
||||
}
|
||||
if(next.cards==undefined) _status.event.next.remove(next);
|
||||
next.setContent('loseToDiscardpile');
|
||||
return next;
|
||||
},
|
||||
respond:function(){
|
||||
var next=game.createEvent('respond');
|
||||
next.player=this;
|
||||
|
@ -20213,6 +20394,24 @@
|
|||
game.addVideo('directequip',this,get.cardsInfo(cards));
|
||||
}
|
||||
},
|
||||
$addToExpansion:function(cards,broadcast,gaintag){
|
||||
var hs=this.getCards('x');
|
||||
for(var i=0;i<cards.length;i++){
|
||||
if(hs.contains(cards[i])){
|
||||
cards.splice(i--,1);
|
||||
}
|
||||
}
|
||||
for(var i=0;i<cards.length;i++){
|
||||
cards[i].fix();
|
||||
if(gaintag) cards[i].addGaintag(gaintag);
|
||||
var sort=lib.config.sort_card(cards[i]);
|
||||
this.node.expansions.insertBefore(cards[i],this.node.expansions.firstChild);
|
||||
}
|
||||
if(broadcast!==false) game.broadcast(function(player,cards){
|
||||
player.$addToExpansion(cards);
|
||||
},this,cards);
|
||||
return this;
|
||||
},
|
||||
directgain:function(cards,broadcast,gaintag){
|
||||
var hs=this.getCards('hs');
|
||||
for(var i=0;i<cards.length;i++){
|
||||
|
@ -20344,6 +20543,7 @@
|
|||
es:[],
|
||||
js:[],
|
||||
ss:[],
|
||||
xs:[],
|
||||
cards:[],
|
||||
cards2:[],
|
||||
};
|
||||
|
@ -20353,11 +20553,79 @@
|
|||
map.es.addArray(evt.es);
|
||||
map.js.addArray(evt.js);
|
||||
map.ss.addArray(evt.ss);
|
||||
map.xs.addArray(evt.xs);
|
||||
map.cards.addArray(evt.cards);
|
||||
map.cards2.addArray(evt.cards2);
|
||||
}
|
||||
});
|
||||
if(map.cards.length>0||map.ss.length>0) return map;
|
||||
if(map.cards.length>0||map.ss.length>0||map.xs.length>0) return map;
|
||||
};
|
||||
next.gaintag=[];
|
||||
return next;
|
||||
},
|
||||
addToExpansion:function(){
|
||||
var next=game.createEvent('addToExpansion');
|
||||
next.player=this;
|
||||
for(var i=0;i<arguments.length;i++){
|
||||
if(get.itemtype(arguments[i])=='player'){
|
||||
next.source=arguments[i];
|
||||
}
|
||||
else if(get.itemtype(arguments[i])=='cards'){
|
||||
next.cards=arguments[i].slice(0);
|
||||
}
|
||||
else if(get.itemtype(arguments[i])=='card'){
|
||||
next.cards=[arguments[i]];
|
||||
}
|
||||
else if(arguments[i]==='log'){
|
||||
next.log=true;
|
||||
}
|
||||
else if(arguments[i]=='fromStorage'){
|
||||
next.fromStorage=true;
|
||||
}
|
||||
else if(arguments[i]=='fromRenku'){
|
||||
next.fromStorage=true;
|
||||
next.fromRenku=true;
|
||||
}
|
||||
else if(arguments[i]=='bySelf'){
|
||||
next.bySelf=true;
|
||||
}
|
||||
else if(typeof arguments[i]=='string'){
|
||||
next.animate=arguments[i];
|
||||
}
|
||||
else if(typeof arguments[i]=='boolean'){
|
||||
next.delay=arguments[i];
|
||||
}
|
||||
}
|
||||
if(next.animate=='gain2'||next.animate=='draw2'||next.animate=='give'){
|
||||
if(!next.hasOwnProperty('log')){
|
||||
next.log=true;
|
||||
}
|
||||
}
|
||||
next.setContent('addToExpansion');
|
||||
next.getl=function(player){
|
||||
var that=this;
|
||||
var map={
|
||||
player:player,
|
||||
hs:[],
|
||||
es:[],
|
||||
js:[],
|
||||
ss:[],
|
||||
xs:[],
|
||||
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.ss.addArray(evt.ss);
|
||||
map.xs.addArray(evt.xs);
|
||||
map.cards.addArray(evt.cards);
|
||||
map.cards2.addArray(evt.cards2);
|
||||
}
|
||||
});
|
||||
if(map.cards.length>0||map.ss.length>0||map.xs.length>0) return map;
|
||||
};
|
||||
next.gaintag=[];
|
||||
return next;
|
||||
|
@ -20398,7 +20666,7 @@
|
|||
}
|
||||
}
|
||||
if(next.cards){
|
||||
var hej=this.getCards('hejs');
|
||||
var hej=this.getCards('hejsx');
|
||||
for(var i=0;i<next.cards.length;i++){
|
||||
if(!hej.contains(next.cards[i])){
|
||||
next.cards.splice(i--,1);
|
||||
|
@ -20785,6 +21053,7 @@
|
|||
es:[],
|
||||
js:[],
|
||||
ss:[],
|
||||
xs:[],
|
||||
cards:[],
|
||||
cards2:[],
|
||||
};
|
||||
|
@ -20794,11 +21063,12 @@
|
|||
map.es.addArray(evt.es);
|
||||
map.js.addArray(evt.js);
|
||||
map.ss.addArray(evt.ss);
|
||||
map.xs.addArray(evt.xs);
|
||||
map.cards.addArray(evt.cards);
|
||||
map.cards2.addArray(evt.cards2);
|
||||
}
|
||||
});
|
||||
if(map.cards.length>0||map.ss.length>0) return map;
|
||||
if(map.cards.length>0||map.ss.length>0||map.xs.length>0) return map;
|
||||
};
|
||||
return next;
|
||||
},
|
||||
|
@ -20818,6 +21088,7 @@
|
|||
es:[],
|
||||
js:[],
|
||||
ss:[],
|
||||
xs:[],
|
||||
cards:[],
|
||||
cards2:[],
|
||||
};
|
||||
|
@ -20827,11 +21098,12 @@
|
|||
map.es.addArray(evt.es);
|
||||
map.js.addArray(evt.js);
|
||||
map.ss.addArray(evt.ss);
|
||||
map.xs.addArray(evt.xs);
|
||||
map.cards.addArray(evt.cards);
|
||||
map.cards2.addArray(evt.cards2);
|
||||
}
|
||||
});
|
||||
if(map.cards.length>0||map.ss.length>0) return map;
|
||||
if(map.cards.length>0||map.ss.length>0||map.xs.length>0) return map;
|
||||
};
|
||||
return next;
|
||||
},
|
||||
|
@ -21272,6 +21544,9 @@
|
|||
this.markAuto(name);
|
||||
}
|
||||
},
|
||||
getExpansions:function(tag){
|
||||
return this.getCards('x',(card)=>card.hasGaintag(tag));
|
||||
},
|
||||
getStorage:function(name){
|
||||
return this.storage[name]||[];
|
||||
},
|
||||
|
@ -25050,7 +25325,7 @@
|
|||
return false;
|
||||
},
|
||||
hasPosition:function(){
|
||||
return ['h','e','j'].contains(get.position(this));
|
||||
return ['h','e','j','s','x'].contains(get.position(this));
|
||||
},
|
||||
isInPile:function(){
|
||||
return ['c','d'].contains(get.position(this));
|
||||
|
@ -27185,7 +27460,7 @@
|
|||
}
|
||||
},
|
||||
_discard:{
|
||||
trigger:{global:'discardAfter'},
|
||||
trigger:{global:['discardAfter','loseToDiscardpileAfter']},
|
||||
forced:true,
|
||||
popup:false,
|
||||
priority:-100,
|
||||
|
@ -28535,6 +28810,7 @@
|
|||
es:[],
|
||||
js:[],
|
||||
ss:[],
|
||||
xs:[],
|
||||
cards:[],
|
||||
cards2:[],
|
||||
};
|
||||
|
@ -28544,11 +28820,12 @@
|
|||
map.es.addArray(evt.es);
|
||||
map.js.addArray(evt.js);
|
||||
map.ss.addArray(evt.ss);
|
||||
map.xs.addArray(evt.xs);
|
||||
map.cards.addArray(evt.cards);
|
||||
map.cards2.addArray(evt.cards2);
|
||||
}
|
||||
});
|
||||
if(map.cards.length>0||map.ss.length>0) return map;
|
||||
if(map.cards.length>0||map.ss.length>0||map.xs.length>0) return map;
|
||||
};
|
||||
if(arg&&get.is.object(arg)){
|
||||
for(var i in arg) next[i]=arg[i];
|
||||
|
@ -33546,7 +33823,7 @@
|
|||
args[i]=arguments[i];
|
||||
}
|
||||
if((args.length==0||args.contains('card'))&&_status.event.player){
|
||||
var cards=_status.event.player.getCards('hejs');
|
||||
var cards=_status.event.player.getCards('hejsx');
|
||||
for(j=0;j<cards.length;j++){
|
||||
cards[j].classList.remove('selected');
|
||||
cards[j].classList.remove('selectable');
|
||||
|
@ -45353,7 +45630,9 @@
|
|||
chain:ui.create.div('.chain','<div></div>',node),
|
||||
handcards1:ui.create.div('.handcards'),
|
||||
handcards2:ui.create.div('.handcards'),
|
||||
expansions:ui.create.div('.expansions'),
|
||||
};
|
||||
node.node.expansions.display='none';
|
||||
var chainlength=game.layout=='default'?64:40;
|
||||
for(var i=0;i<chainlength;i++){
|
||||
ui.create.div(node.node.chain.firstChild,'.cardbg').style.transform='translateX('+(i*5-5)+'px)';
|
||||
|
@ -50153,7 +50432,6 @@
|
|||
_status.maxShuffle--;
|
||||
}
|
||||
game.shuffleNumber++;
|
||||
if(_status.event.trigger) _status.event.trigger('washCard');
|
||||
var cards=[],i;
|
||||
for(var i=0;i<lib.onwash.length;i++){
|
||||
if(lib.onwash[i]()=='remove'){
|
||||
|
@ -50176,6 +50454,7 @@
|
|||
for(var i=0;i<cards.length;i++){
|
||||
ui.cardPile.appendChild(cards[i]);
|
||||
}
|
||||
if(_status.event.trigger) _status.event.trigger('washCard');
|
||||
}
|
||||
if(ui.cardPile.hasChildNodes()==false){
|
||||
game.over('平局');
|
||||
|
@ -51397,10 +51676,10 @@
|
|||
itemtype:function(obj){
|
||||
var i,j;
|
||||
if(typeof obj=='string'){
|
||||
if(obj.length<=4){
|
||||
if(obj.length<=5){
|
||||
var bool=true;
|
||||
for(i=0;i<obj.length;i++){
|
||||
if(/h|e|j|s/.test(obj[i])==false){
|
||||
if(/h|e|j|s|x/.test(obj[i])==false){
|
||||
bool=false;break;
|
||||
}
|
||||
}
|
||||
|
@ -51592,6 +51871,7 @@
|
|||
for(var i=0;i<cards.length;i++){
|
||||
ui.cardPile.appendChild(cards[i]);
|
||||
}
|
||||
if(_status.event.trigger) _status.event.trigger('washCard');
|
||||
}
|
||||
if(ui.cardPile.hasChildNodes()==false){
|
||||
game.over('平局');
|
||||
|
@ -51752,6 +52032,7 @@
|
|||
if(card.timeout&&card.destiny){
|
||||
if(card.destiny.classList.contains('equips')) return 'e';
|
||||
if(card.destiny.classList.contains('judges')) return 'j';
|
||||
if(card.destiny.classList.contains('expansions')) return 'x';
|
||||
if(card.destiny.classList.contains('handcards')) return card.classList.contains('glows')?'s':'h';
|
||||
if(card.destiny.id=='cardPile') return 'c';
|
||||
if(card.destiny.id=='discardPile') return 'd';
|
||||
|
@ -51762,6 +52043,7 @@
|
|||
if(!card.parentNode) return;
|
||||
if(card.parentNode.classList.contains('equips')) return 'e';
|
||||
if(card.parentNode.classList.contains('judges')) return 'j';
|
||||
if(card.parentNode.classList.contains('expansions')) return 'x';
|
||||
if(card.parentNode.classList.contains('handcards')) return card.classList.contains('glows')?'s':'h';
|
||||
if(card.parentNode.id=='cardPile') return 'c';
|
||||
if(card.parentNode.id=='discardPile') return 'd';
|
||||
|
@ -52155,7 +52437,7 @@
|
|||
owner:function(card,method){
|
||||
var list=game.players.concat(game.dead);
|
||||
for(var i=0;i<list.length;i++){
|
||||
if(list[i].getCards('hej').contains(card)) return list[i];
|
||||
if(list[i].getCards('hejsx').contains(card)) return list[i];
|
||||
if(list[i].judging[0]==card&&method!='judge') return list[i];
|
||||
}
|
||||
//for(var i=0;i<game.players.length;i++){
|
||||
|
@ -52388,6 +52670,18 @@
|
|||
}
|
||||
return false;
|
||||
}
|
||||
case 'expansion':{
|
||||
content=player.getCards('x',function(card){
|
||||
return card.hasGaintag(skill);
|
||||
});
|
||||
if(dialog&&content.length){
|
||||
dialog.addAuto(content);
|
||||
}
|
||||
else{
|
||||
return '没有卡牌';
|
||||
}
|
||||
return false;
|
||||
}
|
||||
case 'card':case 'cards':{
|
||||
if(get.itemtype(content)=='card'){
|
||||
content=[content];
|
||||
|
|
|
@ -1,16 +1,14 @@
|
|||
window.noname_update={
|
||||
version:'1.9.112.3',
|
||||
update:'1.9.112.2',
|
||||
version:'1.9.113',
|
||||
update:'1.9.112.3',
|
||||
changeLog:[
|
||||
'李映夏',
|
||||
'吾彦、庞德公、王桃、王悦',
|
||||
'手杀毛玠、孙休、朱儁、武将技能调整',
|
||||
'功能性更新:E(x)pansion区域独立化(武将牌上的牌所在区域)',
|
||||
'bug修复',
|
||||
],
|
||||
files:[
|
||||
//'card/extra.js',
|
||||
//'card/gujian.js',
|
||||
//'card/guozhan.js',
|
||||
'card/guozhan.js',
|
||||
//'card/gwent.js',
|
||||
//'card/huanlekapai.js',
|
||||
//'card/mtg.js',
|
||||
|
@ -19,7 +17,7 @@ window.noname_update={
|
|||
//'card/swd.js',
|
||||
//'card/yunchou.js',
|
||||
//'card/yingbian.js',
|
||||
//'card/yongjian.js',
|
||||
'card/yongjian.js',
|
||||
//'card/zhenfa.js',
|
||||
//'card/zhulu.js',
|
||||
'character/diy.js',
|
||||
|
@ -33,16 +31,16 @@ window.noname_update={
|
|||
//'character/offline.js',
|
||||
'character/old.js',
|
||||
//'character/ow.js',
|
||||
'character/rank.js',
|
||||
//'character/refresh.js',
|
||||
//'character/rank.js',
|
||||
'character/refresh.js',
|
||||
'character/shenhua.js',
|
||||
'character/sp.js',
|
||||
'character/sp2.js',
|
||||
//'character/tw.js',
|
||||
//'character/standard.js',
|
||||
'character/tw.js',
|
||||
'character/standard.js',
|
||||
//'character/swd.js',
|
||||
'character/xianjian.js',
|
||||
//'character/xinghuoliaoyuan.js',
|
||||
//'character/xianjian.js',
|
||||
'character/xinghuoliaoyuan.js',
|
||||
'character/yingbian.js',
|
||||
'character/yijiang.js',
|
||||
//'character/yxs.js',
|
||||
|
@ -62,7 +60,7 @@ window.noname_update={
|
|||
//'mode/single.js',
|
||||
//'mode/stone.js',
|
||||
//'mode/tafang.js',
|
||||
'mode/versus.js',
|
||||
//'mode/versus.js',
|
||||
'game/game.js',
|
||||
//'game/keyWords.js',
|
||||
//'game/NoSleep.js',
|
||||
|
|
344
mode/guozhan.js
344
mode/guozhan.js
|
@ -571,11 +571,11 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
usable:1,
|
||||
filter:function(event,player){
|
||||
return !player.hasSkill('wushuang')&&player.hasCard(function(card){
|
||||
return get.type(card,player)=='trick';
|
||||
return get.type2(card,player)=='trick';
|
||||
},'h');
|
||||
},
|
||||
filterCard:function(card,player){
|
||||
return get.type(card,player)=='trick';
|
||||
return get.type2(card,player)=='trick';
|
||||
},
|
||||
content:function(){
|
||||
player.addTempSkill('wushuang','phaseUseEnd');
|
||||
|
@ -2161,7 +2161,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
if(!player.countCards('h',{color:'red'})) event._result={control:'黑色'};
|
||||
else if(!player.countCards('h',{color:'black'})) event._result={control:'红色'};
|
||||
else player.chooseControl('红色','黑色').set('ai',function(){
|
||||
var player=_status.event.player,num=player.maxHp-player.getStorage('gzhuaiyi').length;
|
||||
var player=_status.event.player,num=player.maxHp-player.getExpansions('gzhuaiyi').length;
|
||||
if(player.countCards('h',{color:'red'})<=num&&
|
||||
player.countCards('h',{color:'black'})>num) return '红色';
|
||||
return '黑色';
|
||||
|
@ -2207,19 +2207,14 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
return get.type(card)=='equip'&&hs.contains(card);
|
||||
});
|
||||
if(cards.length){
|
||||
player.lose(cards,ui.special,'toStorage');
|
||||
game.log(player,'将',cards,'作为“异”置于武将牌上');
|
||||
player.markAuto('gzhuaiyi',cards);
|
||||
player.addToExpansion(cards,player,'give').gaintag.add('gzhuaiyi');
|
||||
}
|
||||
else event.finish();
|
||||
'step 8'
|
||||
game.delayx();
|
||||
},
|
||||
ai:{
|
||||
order:10,
|
||||
result:{
|
||||
player:function(player,target){
|
||||
var num=player.maxHp-player.getStorage('gzhuaiyi').length;
|
||||
var num=player.maxHp-player.getExpansions('gzhuaiyi').length;
|
||||
if(player.countCards('h',{color:'red'})<=num) return 1;
|
||||
if(player.countCards('h',{color:'black'})<=num) return 1;
|
||||
return 0;
|
||||
|
@ -2227,17 +2222,21 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
},
|
||||
marktext:'异',
|
||||
intro:{content:'cards',onunmark:'throw'},
|
||||
intro:{content:'expansion',markcount:'expansion'},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
},
|
||||
gzzisui:{
|
||||
audio:2,
|
||||
trigger:{player:'phaseDrawBegin2'},
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
return !event.numFixed&&player.getStorage('gzhuaiyi').length>0;
|
||||
return !event.numFixed&&player.getExpansions('gzhuaiyi').length>0;
|
||||
},
|
||||
content:function(){
|
||||
trigger.num+=player.getStorage('gzhuaiyi').length;
|
||||
trigger.num+=player.getExpansions('gzhuaiyi').length;
|
||||
},
|
||||
group:'gzzisui_die',
|
||||
subSkill:{
|
||||
|
@ -2246,7 +2245,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{player:'phaseJieshuBegin'},
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
return player.getStorage('gzhuaiyi').length>player.maxHp;
|
||||
return player.getExpansions('gzhuaiyi').length>player.maxHp;
|
||||
},
|
||||
content:function(){
|
||||
player.die();
|
||||
|
@ -3436,7 +3435,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
audio:'gzxingzhao',
|
||||
trigger:{
|
||||
player:'loseAfter',
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
filter:function(event,player){
|
||||
var evt=event.getl(player);
|
||||
|
@ -3463,7 +3462,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
audio:2,
|
||||
trigger:{player:'damageBegin2'},
|
||||
filter:function(event,player){
|
||||
return event.cards&&event.cards.filterInD().length>0&&!player.getStorage('qiuan').length;
|
||||
return event.cards&&event.cards.filterInD().length>0&&!player.getExpansions('qiuan').length;
|
||||
},
|
||||
check:function(event,player){
|
||||
if(get.damageEffect(player,event.source||player,player,event.nature)>=0) return false;
|
||||
|
@ -3472,15 +3471,12 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
preHidden:true,
|
||||
content:function(){
|
||||
var cards=trigger.cards.filterInD();
|
||||
game.cardsGotoSpecial(cards);
|
||||
player.$gain2(cards,false);
|
||||
player.markAuto('qiuan',cards);
|
||||
game.log(player,'将',cards,'置于了武将牌上');
|
||||
player.addToExpansion('gain2',cards).gaintag.add('qiuan');
|
||||
trigger.cancel();
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:'throw',
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
marktext:'函',
|
||||
},
|
||||
|
@ -3489,13 +3485,12 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{player:'phaseZhunbeiBegin'},
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
return player.getStorage('qiuan').length>0;
|
||||
return player.getExpansions('qiuan').length>0;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
var cards=player.getStorage('qiuan');
|
||||
player.gain(cards,'gain2','fromStorage').gaintag.add('liangfan');
|
||||
player.unmarkAuto('qiuan',cards);
|
||||
var cards=player.getExpansions('qiuan');
|
||||
player.gain(cards,'gain2').gaintag.add('liangfan');
|
||||
player.addTempSkill('liangfan2');
|
||||
'step 1'
|
||||
player.loseHp();
|
||||
|
@ -5039,7 +5034,6 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
var owner=get.owner(card);
|
||||
if(owner){
|
||||
player.line(owner,'green');
|
||||
owner.lose(card,ui.special);
|
||||
owner.$give(card,player);
|
||||
}
|
||||
else player.$gain(card,'log');
|
||||
|
@ -6007,78 +6001,23 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
},
|
||||
},
|
||||
"new_kongcheng":{
|
||||
init:function(player){
|
||||
if(player.storage.new_kongcheng==undefined) player.storage.new_kongcheng=[];
|
||||
},
|
||||
fixedGain:function(){
|
||||
'step 0'
|
||||
if(cards){
|
||||
var owner=event.source||get.owner(cards[0]);
|
||||
if(owner){
|
||||
var next=owner.lose(cards,ui.special,'toStorage').set('type','gain').set('forceDie',true);
|
||||
if(event.animate=='give'||event.visible==true) next.visible=true;
|
||||
event.relatedLose=next;
|
||||
}
|
||||
player.storage.new_kongcheng.addArray(cards);
|
||||
player.markSkill('new_kongcheng');
|
||||
}
|
||||
else{
|
||||
event.finish();
|
||||
}
|
||||
'step 1'
|
||||
if(event.animate=='draw'){
|
||||
player.$draw(cards.length);
|
||||
game.pause();
|
||||
setTimeout(function(){
|
||||
game.resume();
|
||||
},get.delayx(500,500));
|
||||
}
|
||||
else if(event.animate=='gain'){
|
||||
player.$gain(cards);
|
||||
game.pause();
|
||||
setTimeout(function(){
|
||||
game.resume();
|
||||
},get.delayx(700,700));
|
||||
}
|
||||
else if(event.animate=='gain2'||event.animate=='draw2'){
|
||||
var gain2t=300;
|
||||
if(player.$gain2(cards)&&player==game.me){
|
||||
gain2t=500;
|
||||
}
|
||||
game.pause();
|
||||
setTimeout(function(){
|
||||
game.resume();
|
||||
},get.delayx(gain2t,gain2t));
|
||||
}
|
||||
else if(event.source&&(event.animate=='give'||event.animate=='giveAuto')){
|
||||
if(event.animate=='give') event.source['$'+event.animate](cards,player);
|
||||
else{
|
||||
var givemap={hs:[],ots:[]};
|
||||
for(var i=0;i<cards.length;i++){
|
||||
givemap[cards[i].original=='h'?'hs':'ots'].push(cards[i]);
|
||||
}
|
||||
if(givemap.hs.length) event.source.$giveAuto(givemap.hs,player);
|
||||
if(givemap.ots.length) event.source.$give(givemap.ots,player);
|
||||
}
|
||||
game.pause();
|
||||
setTimeout(function(){
|
||||
game.resume();
|
||||
},get.delayx(500,500));
|
||||
}
|
||||
},
|
||||
new_kongcheng:{
|
||||
group:["new_kongcheng_gain","new_kongcheng_got"],
|
||||
subSkill:{
|
||||
gain:{
|
||||
audio:"kongcheng",
|
||||
trigger:{
|
||||
player:"gainBegin",
|
||||
player:"gainBefore",
|
||||
},
|
||||
filter:function(event,player){
|
||||
return event.source&&event.source!=player&&player!=_status.currentPhase&&!event.bySelf&&player.countCards('h')==0;
|
||||
},
|
||||
content:function(){
|
||||
trigger.setContent(lib.skill.new_kongcheng.fixedGain);
|
||||
trigger.name='addToExpansion';
|
||||
trigger.setContent('addToExpansion');
|
||||
trigger.gaintag=['new_kongcheng'];
|
||||
trigger.untrigger();
|
||||
trigger.trigger('addToExpansionBefore');
|
||||
},
|
||||
sub:true,
|
||||
forced:true,
|
||||
|
@ -6088,13 +6027,10 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
player:"phaseDrawBegin1",
|
||||
},
|
||||
filter:function(event,player){
|
||||
return player.storage.new_kongcheng.length>0;
|
||||
return player.getExpansions('new_kongcheng').length>0;
|
||||
},
|
||||
content:function(){
|
||||
player.gain(player.storage.new_kongcheng,'draw','fromStorage');
|
||||
player.storage.new_kongcheng=[];
|
||||
game.addVideo('storage',player,['new_kongcheng',get.cardsInfo(player.storage.new_kongcheng),'cards']);
|
||||
player.unmarkSkill('new_kongcheng');
|
||||
player.gain(player.getExpansions('new_kongcheng'),'draw');
|
||||
},
|
||||
sub:true,
|
||||
forced:true,
|
||||
|
@ -6122,15 +6058,9 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
},
|
||||
intro:{
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
},
|
||||
markcount:'expansion',
|
||||
mark:function(dialog,content,player){
|
||||
var content=player.getExpansions('new_kongcheng');
|
||||
if(content&&content.length){
|
||||
if(player==game.me||player.isUnderControl()){
|
||||
dialog.addAuto(content);
|
||||
|
@ -6141,6 +6071,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
},
|
||||
content:function(content,player){
|
||||
var content=player.getExpansions('new_kongcheng');
|
||||
if(content&&content.length){
|
||||
if(player==game.me||player.isUnderControl()){
|
||||
return get.translation(content);
|
||||
|
@ -6149,6 +6080,10 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
},
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
},
|
||||
"new_keji":{
|
||||
audio:"keji",
|
||||
|
@ -7375,19 +7310,13 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
qianhuan:{
|
||||
group:['qianhuan_add','qianhuan_use'],
|
||||
init:function(player){
|
||||
if(!player.storage.qianhuan) player.storage.qianhuan=[];
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
},
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
},
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
ai:{
|
||||
threaten:1.8
|
||||
|
@ -7398,20 +7327,22 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
add:{
|
||||
trigger:{global:'damageEnd'},
|
||||
filter:function(event,player){
|
||||
var suits=[];
|
||||
for(var i=0;i<player.storage.qianhuan.length;i++){
|
||||
suits.add(get.suit(player.storage.qianhuan[i]));
|
||||
var suits=[],cards=player.getExpansions('qianhuan');
|
||||
for(var i=0;i<cards.length;i++){
|
||||
suits.add(get.suit(cards[i]));
|
||||
}
|
||||
return player.isFriendOf(event.player)&&player.countCards('he',function(card){
|
||||
if(suits.length>=lib.suit.length) return false;
|
||||
return player.isFriendOf(event.player)&&player.hasCard(function(card){
|
||||
if(_status.connectMode&&get.position(card)=='h') return true;
|
||||
return !suits.contains(get.suit(card));
|
||||
});
|
||||
},'he');
|
||||
},
|
||||
direct:true,
|
||||
content:function(){
|
||||
'step 0'
|
||||
var suits=[];
|
||||
for(var i=0;i<player.storage.qianhuan.length;i++){
|
||||
suits.add(get.suit(player.storage.qianhuan[i]));
|
||||
var suits=[],cards=player.getExpansions('qianhuan');
|
||||
for(var i=0;i<cards.length;i++){
|
||||
suits.add(get.suit(cards[i]));
|
||||
}
|
||||
player.chooseCard('he',get.prompt2('qianhuan'),function(card){
|
||||
return !_status.event.suits.contains(get.suit(card));
|
||||
|
@ -7420,12 +7351,9 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
}).set('suits',suits).setHiddenSkill('qianhuan');
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
var card=result.cards[0]
|
||||
player.storage.qianhuan.add(card);
|
||||
player.lose(card,ui.special,'toStorage');
|
||||
player.$give(card,player,false);
|
||||
player.markSkill('qianhuan',true);
|
||||
player.logSkill('qianhuan');
|
||||
var card=result.cards[0];
|
||||
player.addToExpansion(card,player,'give').gaintag.add('qianhuan');
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@ -7433,7 +7361,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{global:'useCardToTarget'},
|
||||
filter:function(event,player){
|
||||
if(!['basic','trick'].contains(get.type(event.card,'trick'))) return false;
|
||||
return event.target&&player.sameIdentityAs(event.target)&&event.targets.length==1&&player.storage.qianhuan.length;
|
||||
return event.target&&player.sameIdentityAs(event.target)&&event.targets.length==1&&player.getExpansions('qianhuan').length;
|
||||
},
|
||||
direct:true,
|
||||
content:function(){
|
||||
|
@ -7466,21 +7394,13 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
if(_status.event.goon) return 1;
|
||||
return 0;
|
||||
}).set('createDialog',[get.prompt('qianhuan'),'<div class="text center">移去一张“千幻”牌令'+
|
||||
get.translation(trigger.player)+'对'+get.translation(trigger.target)+'的'+get.translation(trigger.card)+'失效</div>',player.storage.qianhuan]);
|
||||
get.translation(trigger.player)+'对'+get.translation(trigger.target)+'的'+get.translation(trigger.card)+'失效</div>',player.getExpansions('qianhuan')]);
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
var card=result.links[0];
|
||||
player.storage.qianhuan.remove(card);
|
||||
if(player.storage.qianhuan.length){
|
||||
player.updateMarks('qianhuan');
|
||||
}
|
||||
else{
|
||||
player.unmarkSkill('qianhuan');
|
||||
}
|
||||
game.cardsDiscard(card);
|
||||
player.$throw(card);
|
||||
player.logSkill('qianhuan',trigger.player);
|
||||
trigger.getParent().targets.remove(trigger.target);
|
||||
var card=result.links[0];
|
||||
player.loseToDiscardpile(card);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -7527,8 +7447,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
xuanlve:{
|
||||
trigger:{
|
||||
player:'loseAfter',
|
||||
source:'gainAfter',
|
||||
global:['equipAfter','addJudgeAfter'],
|
||||
global:['equipAfter','addJudgeAfter','gainAfter','loseAsyncAfter','addToExpansionAfter'],
|
||||
},
|
||||
direct:true,
|
||||
preHidden:true,
|
||||
|
@ -7572,7 +7491,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
if(current.identity=='wu'){
|
||||
return current.countCards('e');
|
||||
}
|
||||
})+player.storage.yuanjiangfenghuotu.length;
|
||||
})+player.getExpansions('yuanjiangfenghuotu').length;
|
||||
if(num>=5){
|
||||
return 8-get.value(card);
|
||||
}
|
||||
|
@ -7590,7 +7509,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
if(current.identity=='wu'){
|
||||
return current.countCards('e');
|
||||
}
|
||||
})+player.storage.yuanjiangfenghuotu.length;
|
||||
})+player.getExpansions('yuanjiangfenghuotu').length;
|
||||
if(num){
|
||||
event.shown=get.cards(num);
|
||||
player.showCards(event.shown,get.translation('lianzi'));
|
||||
|
@ -7675,29 +7594,21 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
derivation:'yuanjiangfenghuotu',
|
||||
mark:true,
|
||||
global:['jiahe_put','jiahe_skill'],
|
||||
init:function(player){
|
||||
if(!player.storage.yuanjiangfenghuotu) player.storage.yuanjiangfenghuotu=[];
|
||||
},
|
||||
ai:{
|
||||
threaten:2
|
||||
},
|
||||
trigger:{player:'damageEnd'},
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
return event.card&&(event.card.name=='sha'||get.type(event.card,'trick')=='trick')&&player.storage.yuanjiangfenghuotu.length>0;
|
||||
return event.card&&(event.card.name=='sha'||get.type(event.card,'trick')=='trick')&&player.getExpansions('yuanjiangfenghuotu').length>0;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.chooseCardButton('将一张“烽火”置入弃牌堆',player.storage.yuanjiangfenghuotu,true);
|
||||
player.chooseCardButton('将一张“烽火”置入弃牌堆',player.getExpansions('yuanjiangfenghuotu'),true);
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
var card=result.links[0];
|
||||
player.$throw(card);
|
||||
game.cardsDiscard(card);
|
||||
player.storage.yuanjiangfenghuotu.remove(card);
|
||||
player.syncStorage('yuanjiangfenghuotu');
|
||||
player.updateMarks('yuanjiangfenghuotu');
|
||||
game.log(player,'将',card,'置入了弃牌堆');
|
||||
player.loseToDiscardpile(card);
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@ -7707,7 +7618,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
forceaudio:true,
|
||||
filter:function(event,player){
|
||||
var zhu=get.zhu(player,'jiahe');
|
||||
if(zhu&&zhu.storage.yuanjiangfenghuotu){
|
||||
if(zhu){
|
||||
return player.countCards('he',{type:'equip'})>0;
|
||||
}
|
||||
return false;
|
||||
|
@ -7720,7 +7631,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
if(!zhu) return 0;
|
||||
var num=7-get.value(card);
|
||||
if(get.position(card)=='h'){
|
||||
if(zhu.storage.yuanjiangfenghuotu.length>=5){
|
||||
if(zhu.getExpansions('huangjintianbingfu').length>=5){
|
||||
return num-3;
|
||||
}
|
||||
return num+3;
|
||||
|
@ -7732,27 +7643,22 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
if(player.countCards('h',function(card){
|
||||
return get.type(card)=='equip'&&get.subtype(card)=='sub'&&player.hasValueTarget(card);
|
||||
})) return num+4;
|
||||
if(zhu.storage.yuanjiangfenghuotu.length>=5&&!player.hasSkillTag('noe')){
|
||||
if(zhu.getExpansions('yuanjiangfenghuotu').length>=5&&!player.hasSkillTag('noe')){
|
||||
return num-5;
|
||||
}
|
||||
}
|
||||
return num;
|
||||
},
|
||||
discard:false,
|
||||
lose:true,
|
||||
toStorage:true,
|
||||
lose:false,
|
||||
delay:false,
|
||||
prepare:function(cards,player){
|
||||
var zhu=get.zhu(player,'jiahe');
|
||||
player.$give(cards,zhu,false);
|
||||
player.line(zhu);
|
||||
game.log(player,'放置了',cards[0]);
|
||||
},
|
||||
content:function(){
|
||||
var zhu=get.zhu(player,'jiahe');
|
||||
zhu.storage.yuanjiangfenghuotu.add(cards[0]);
|
||||
zhu.syncStorage('yuanjiangfenghuotu');
|
||||
zhu.updateMarks('yuanjiangfenghuotu');
|
||||
//event.trigger('addCardToStorage');
|
||||
zhu.addToExpansion(cards,player,'give').gaintag.add('yuanjiangfenghuotu');
|
||||
},
|
||||
ai:{
|
||||
order:function(item,player){
|
||||
|
@ -7773,7 +7679,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
forceaudio:true,
|
||||
filter:function(event,player){
|
||||
var zhu=get.zhu(player,'jiahe');
|
||||
if(zhu&&zhu.storage.yuanjiangfenghuotu&&zhu.storage.yuanjiangfenghuotu.length){
|
||||
if(zhu&&zhu.getExpansions('yuanjiangfenghuotu').length){
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
@ -7781,7 +7687,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
content:function(){
|
||||
'step 0'
|
||||
var zhu=get.zhu(player,'jiahe');
|
||||
event.num=zhu.storage.yuanjiangfenghuotu.length;
|
||||
event.num=zhu.getExpansions('yuanjiangfenghuotu').length;
|
||||
'step 1'
|
||||
var list=[];
|
||||
if(event.num>=1&&!player.hasSkill('reyingzi')) list.push('reyingzi');
|
||||
|
@ -7842,17 +7748,15 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
forceunique:true,
|
||||
nopop:true,
|
||||
mark:true,
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
},
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
mark:function(dialog,content,player){
|
||||
var content=player.getExpansions('yuanjiangfenghuotu');
|
||||
if(content&&content.length){
|
||||
dialog.addSmall(content);
|
||||
}
|
||||
|
@ -8402,7 +8306,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
if(event.responded) return false;
|
||||
if(!event.filterCard({name:'sha'})) return false;
|
||||
var zhu=get.zhu(player,'hongfa');
|
||||
if(zhu&&zhu.storage.huangjintianbingfu&&zhu.storage.huangjintianbingfu.length>0){
|
||||
if(zhu&&zhu.getExpansions('huangjintianbingfu').length>0){
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
@ -8410,7 +8314,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
content:function(){
|
||||
"step 0"
|
||||
var zhu=get.zhu(player,'hongfa');
|
||||
player.chooseCardButton(get.prompt('huangjintianbingfu'),zhu.storage.huangjintianbingfu).set('ai',function(){
|
||||
player.chooseCardButton(get.prompt('huangjintianbingfu'),zhu.getExpansions('huangjintianbingfu')).set('ai',function(){
|
||||
if(_status.event.goon) return 1;
|
||||
return 0;
|
||||
}).set('goon',player.countCards('h','sha')==0);
|
||||
|
@ -8421,10 +8325,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
trigger.responded=true;
|
||||
trigger.result={bool:true,card:{name:'sha'},cards:[card]};
|
||||
var zhu=get.zhu(player,'hongfa');
|
||||
zhu.storage.huangjintianbingfu.remove(card);
|
||||
zhu.syncStorage('huangjintianbingfu');
|
||||
zhu.updateMarks('huangjintianbingfu');
|
||||
player.logSkill('hongfa_respond');
|
||||
player.logSkill('hongfa_respond',zhu);
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@ -8435,7 +8336,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
filter:function(event,player){
|
||||
if(!event.filterCard({name:'sha'},player)) return false;
|
||||
var zhu=get.zhu(player,'hongfa');
|
||||
if(zhu&&zhu.storage.huangjintianbingfu&&zhu.storage.huangjintianbingfu.length>0){
|
||||
if(zhu&&zhu.getExpansions('huangjintianbingfu').length>0){
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
@ -8443,7 +8344,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
chooseButton:{
|
||||
dialog:function(event,player){
|
||||
var zhu=get.zhu(player,'hongfa');
|
||||
return ui.create.dialog('黄巾天兵符',zhu.storage.huangjintianbingfu,'hidden');
|
||||
return ui.create.dialog('黄巾天兵符',zhu.getExpansions('huangjintianbingfu'),'hidden');
|
||||
},
|
||||
backup:function(links,player){
|
||||
return {
|
||||
|
@ -8451,13 +8352,9 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
selectCard:-1,
|
||||
viewAs:{name:'sha',cards:links},
|
||||
cards:links,
|
||||
onuse:function(result,player){
|
||||
result.cards=lib.skill[result.skill].cards;
|
||||
var card=result.cards[0];
|
||||
var zhu=get.zhu(player,'hongfa');
|
||||
zhu.storage.huangjintianbingfu.remove(card);
|
||||
zhu.syncStorage('huangjintianbingfu');
|
||||
zhu.updateMarks('huangjintianbingfu');
|
||||
precontent:function(){
|
||||
var cards=lib.skill.hongfa_use_backup.cards;
|
||||
event.result.cards=cards;
|
||||
player.logSkill('hongfa_use',result.targets);
|
||||
}
|
||||
}
|
||||
|
@ -8470,7 +8367,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
respondSha:true,
|
||||
skillTagFilter:function(player){
|
||||
var zhu=get.zhu(player,'hongfa');
|
||||
if(zhu&&zhu.storage.huangjintianbingfu&&zhu.storage.huangjintianbingfu.length>0){
|
||||
if(zhu&&zhu.getExpansions('huangjintianbingfu').length>0){
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
@ -8488,24 +8385,17 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
hongfa:{
|
||||
audio:2,
|
||||
init:function(player){
|
||||
player.storage.huangjintianbingfu=[];
|
||||
},
|
||||
derivation:'huangjintianbingfu',
|
||||
unique:true,
|
||||
forceunique:true,
|
||||
trigger:{player:'phaseZhunbeiBegin'},
|
||||
forced:true,
|
||||
filter:function(event,player){
|
||||
return player.storage.huangjintianbingfu.length==0&&get.population('qun')>0;
|
||||
return player.getExpansions('huangjintianbingfu').length==0&&get.population('qun')>0;
|
||||
},
|
||||
content:function(){
|
||||
var cards=get.cards(get.population('qun'));
|
||||
player.storage.huangjintianbingfu.addArray(cards);
|
||||
game.cardsGotoSpecial(cards);
|
||||
player.syncStorage('huangjintianbingfu');
|
||||
player.updateMarks('huangjintianbingfu');
|
||||
//event.trigger('addCardToStorage');
|
||||
player.addToExpansion(cards,'gain2').gaintag.add('huangjintianbingfu');
|
||||
},
|
||||
ai:{
|
||||
threaten:2,
|
||||
|
@ -8517,25 +8407,19 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
audio:true,
|
||||
trigger:{player:'loseHpBefore'},
|
||||
filter:function(event,player){
|
||||
return player.storage.huangjintianbingfu.length>0;
|
||||
return player.getExpansions('huangjintianbingfu').length>0;
|
||||
},
|
||||
direct:true,
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.chooseCardButton(get.prompt('hongfa'),player.storage.huangjintianbingfu).set('ai',function(){
|
||||
player.chooseCardButton(get.prompt('hongfa'),player.getExpansions('huangjintianbingfu')).set('ai',function(){
|
||||
return 1;
|
||||
});
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
var card=result.links[0];
|
||||
game.cardsDiscard(card);
|
||||
player.storage.huangjintianbingfu.remove(card);
|
||||
player.$throw(card,1000);
|
||||
player.updateMarks('huangjintianbingfu');
|
||||
player.syncStorage('huangjintianbingfu');
|
||||
player.logSkill('huangjintianbingfu');
|
||||
player.loseToDiscardpile(result.links);
|
||||
trigger.cancel();
|
||||
player.logSkill('hongfa_hp');
|
||||
game.delay();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -8607,17 +8491,15 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
forceunique:true,
|
||||
nopop:true,
|
||||
mark:true,
|
||||
onremove:function(player,skill){
|
||||
var cards=player.getExpansions(skill);
|
||||
if(cards.length) player.loseToDiscardpile(cards);
|
||||
},
|
||||
intro:{
|
||||
content:'cards',
|
||||
onunmark:function(storage,player){
|
||||
if(storage&&storage.length){
|
||||
player.$throw(storage,1000);
|
||||
game.cardsDiscard(storage);
|
||||
game.log(storage,'被置入了弃牌堆');
|
||||
storage.length=0;
|
||||
}
|
||||
},
|
||||
content:'expansion',
|
||||
markcount:'expansion',
|
||||
mark:function(dialog,content,player){
|
||||
var content=player.getExpansions('huangjintianbingfu');
|
||||
if(content&&content.length){
|
||||
dialog.addSmall(content);
|
||||
}
|
||||
|
@ -8635,7 +8517,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
'step 0'
|
||||
var num=get.population('qun');
|
||||
if(player.hasSkill('huangjintianbingfu')){
|
||||
num+=player.storage.huangjintianbingfu.length;
|
||||
num+=player.getExpansions('huangjintianbingfu').length;
|
||||
}
|
||||
var cards=get.cards(num);
|
||||
game.cardsGotoOrdering(cards);
|
||||
|
@ -9014,7 +8896,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
audio:2,
|
||||
trigger:{global:'damageEnd'},
|
||||
filter:function(event,player){
|
||||
return event.player.isIn()&&event.player.isFriendOf(player)&&player.storage.tuntian&&player.storage.tuntian.length;
|
||||
return event.player.isIn()&&event.player.isFriendOf(player)&&player.getExpansions('tuntian').length;
|
||||
},
|
||||
init:function(player){
|
||||
player.checkViceSkill('ziliang');
|
||||
|
@ -9023,28 +8905,14 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
direct:true,
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.chooseCardButton(get.prompt('ziliang',trigger.player),player.storage.tuntian).set('ai',function(button){
|
||||
player.chooseCardButton(get.prompt('ziliang',trigger.player),player.getExpansions('tuntian')).set('ai',function(button){
|
||||
return get.value(button.link);
|
||||
});
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
var card=result.links[0];
|
||||
player.logSkill('ziliang',trigger.player);
|
||||
player.storage.tuntian.remove(card);
|
||||
player.syncStorage('tuntian');
|
||||
if(!player.storage.tuntian.length){
|
||||
player.unmarkSkill('tuntian');
|
||||
}
|
||||
else{
|
||||
player.updateMarks('tuntian');
|
||||
}
|
||||
trigger.player.gain(card);
|
||||
if(trigger.player==player){
|
||||
player.$draw(card,true);
|
||||
}
|
||||
else{
|
||||
player.$give(card,trigger.player);
|
||||
}
|
||||
trigger.player.gain(card,player,'give');
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue