diff --git a/card/extra.js b/card/extra.js index 76109d27b..bb705eeb6 100644 --- a/card/extra.js +++ b/card/extra.js @@ -855,8 +855,8 @@ game.import('card',function(lib,game,ui,get,ai,_status){ }, ai:{ effect:{ - player:function(card,player,target,current){ - if(card.name=='sha'&&target.countCards('h')==0&&!target.hasSkillTag('filterDamage',null,{ + player:function(card,player,target,current,isLink){ + if(card.name=='sha'&&!isLink&&target.countCards('h')==0&&!target.hasSkillTag('filterDamage',null,{ player:player, card:card, })) return [1,0,1,-3]; @@ -891,11 +891,11 @@ game.import('card',function(lib,game,ui,get,ai,_status){ if(target.hasSkillTag('unequip2')) return; if(player.hasSkillTag('unequip',false,{ name:card?card.name:null, - target:player, + target:target, card:card })||player.hasSkillTag('unequip_ai',false,{ name:card?card.name:null, - target:player, + target:target, card:card })) return; if(card.name=='nanman'||card.name=='wanjian'||card.name=='chuqibuyi') return 'zerotarget'; @@ -984,12 +984,12 @@ game.import('card',function(lib,game,ui,get,ai,_status){ if(arg&&arg.player){ if(arg.player.hasSkillTag('unequip',false,{ name:arg.card?arg.card.name:null, - target:player, + target:target, card:arg.card, })) return false; if(arg.player.hasSkillTag('unequip_ai',false,{ name:arg.card?arg.card.name:null, - target:player, + target:target, card:arg.card, })) return false; if(arg.player.hasSkillTag('jueqing',false,player)) return false; diff --git a/card/standard.js b/card/standard.js index 9983185c6..ad09ded83 100644 --- a/card/standard.js +++ b/card/standard.js @@ -173,33 +173,56 @@ game.import('card',function(lib,game,ui,get,ai,_status){ } }, ai:{ + canLink:function(player,target,card){ + if(!target.isLinked()&&!player.hasSkill('wutiesuolian_skill')) return false; + if(target.mayHaveShan()&&!player.hasSkillTag('directHit_ai',true,{ + target:target, + card:card, + },true)) return false; + if(player.hasSkill('jueqing')||target.hasSkill('gangzhi')||target.hasSkill('gangzhi')) return false; + return true; + }, basic:{ useful:[5,1], value:[5,1], }, order:function(item,player){ if(player.hasSkillTag('presha',true,null,true)) return 10; - if(lib.linked.contains(get.nature(item))) return (player.getCardUsable('sha')>1?3:3.1); + if(lib.linked.contains(get.nature(item))){ + if(game.hasPlayer(function(current){ + return current!=player&¤t.isLinked()&&player.canUse(item,current,null,true)&&get.effect(current,item,player,player)>0&&lib.card.sha.ai.canLink(player,current,item); + })&&game.countPlayer(function(current){ + return current.isLinked()&&get.damageEffect(current,player,player,get.nature(item))>0; + })>1) return 3.1; + return 3; + } return 3.05; }, result:{ target:function(player,target,card,isLink){ - if(!isLink&&player.hasSkill('jiu')){ - if(!target.hasSkillTag('filterDamage',null,{ - player:player, - card:card, - jiu:true, - })){ - if(get.attitude(player,target)>0){ - return -7; - } - else{ - return -4; - } + var eff=function(){ + if(!isLink&&player.hasSkill('jiu')){ + if(!target.hasSkillTag('filterDamage',null,{ + player:player, + card:card, + jiu:true, + })){ + if(get.attitude(player,target)>0){ + return -7; + } + else{ + return -4; + } + } + return -0.5; } - return -0.5; - } - return -1.5; + return -1.5; + }(); + if(!isLink&&target.mayHaveShan()&&!player.hasSkillTag('directHit_ai',true,{ + target:target, + card:card, + },true)) return eff/1.2; + return eff; }, }, tag:{ @@ -1070,13 +1093,11 @@ game.import('card',function(lib,game,ui,get,ai,_status){ result:{ target:-1.5, player:function(player,target,card){ - if(get.cardtag(card,'yingbian_fujia')){ - var num=player.countCards('h',function(cardx){ - return cardx!=card&&(!card.cards||!card.cards.contains(cardx)); - }); - if(!game.hasPlayer(function(current){ - return current.countCards('h')>num; - })) return 0; + if(player.hasSkillTag('directHit_ai',true,{ + target:target, + card:card, + },true)){ + return 0; } if(get.damageEffect(target,player,target)>0&&get.attitude(player,target)>0&&get.attitude(target,player)>0){ return 0; @@ -1654,11 +1675,11 @@ game.import('card',function(lib,game,ui,get,ai,_status){ if(target.hasSkillTag('unequip2')) return; if(player.hasSkillTag('unequip',false,{ name:card?card.name:null, - target:player, + target:target, card:card })||player.hasSkillTag('unequip_ai',false,{ name:card?card.name:null, - target:player, + target:target, card:card })) return; if(card.name=='sha'&&get.color(card)=='black') return 'zerotarget'; @@ -1847,7 +1868,16 @@ game.import('card',function(lib,game,ui,get,ai,_status){ trigger._result.bool=false; trigger._result.result=null; } - } + }, + ai:{ + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + if(get.attitude(player,arg.target)<0&&arg.card.name=='sha'&&player.countCards('he',function(card){ + return card!=player.getEquip('guanshi')&&card!=arg.card&&(!arg.card.cards||!arg.card.cards.contains(card))&&get.value(card)<5; + })>1) return true; + return false; + }, + }, }, fangtian_skill:{ equipSkill:true, @@ -1979,7 +2009,7 @@ game.import('card',function(lib,game,ui,get,ai,_status){ filter:function(event,player){ if(event.responded) return false; if(event.bagua_skill) return false; - if(!event.filterCard({name:'shan'},player,event)) return false; + if(!event.filterCard||!event.filterCard({name:'shan'},player,event)) return false; if(event.name=='chooseToRespond'&&!lib.filter.cardRespondable({name:'shan'},player,event)) return false; if(player.hasSkillTag('unequip2')) return false; var evt=event.getParent(); @@ -2020,11 +2050,11 @@ game.import('card',function(lib,game,ui,get,ai,_status){ if(target.hasSkillTag('unequip2')) return; if(player.hasSkillTag('unequip',false,{ name:card?card.name:null, - target:player, + target:target, card:card })||player.hasSkillTag('unequip_ai',false,{ name:card?card.name:null, - target:player, + target:target, card:card })) return; if(get.tag(card,'respondShan')) return 0.5; diff --git a/card/yingbian.js b/card/yingbian.js index 17be1f09d..62d2ea117 100644 --- a/card/yingbian.js +++ b/card/yingbian.js @@ -230,12 +230,14 @@ game.import('card',function(lib,game,ui,get,ai,_status){ subtype:'equip5', loseDelay:false, onEquip:function(){ - player.logSkill('tianjitu'); if(player.countCards('he',function(cardx){ return cardx!=card; - })) player.chooseToDiscard(true,function(card){ - return card!=_status.event.card; - },'he').set('card',card); + })>0){ + player.logSkill('tianjitu'); + player.chooseToDiscard(true,function(card){ + return card!=_status.event.card; + },'he').set('card',card); + } }, onLose:function(){ var next=game.createEvent('tianjitu_lose'); @@ -252,6 +254,14 @@ game.import('card',function(lib,game,ui,get,ai,_status){ }); }, ai:{ + value:function(card,player){ + if(player.countCards('h')>3||get.position(card)!='e') return 0.5; + return (player.countCards('h')-5)/3; + }, + equipValue:function(card,player){ + if(player.countCards('h')>3||get.position(card)!='e') return 0.5; + return (player.countCards('h')-5)/3; + }, basic:{ equipValue:0.5 } diff --git a/character/diy.js b/character/diy.js index 5d5bf7d5e..820eaabf6 100755 --- a/character/diy.js +++ b/character/diy.js @@ -383,6 +383,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ content:function(){ player.removeSkill('hiroto_huyu2'); player.removeSkill('hiroto_zonglve'); + player.removeGaintag('hiroto_huyu2'); var target=player.storage.hiroto_huyu2; if(target&&target.isAlive()){ var cards=[]; @@ -398,6 +399,15 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, mark:'character', intro:{content:'已成为$的工具人'}, + group:'hiroto_huyu_gain', + }, + hiroto_huyu_gain:{ + trigger:{player:'gainBegin'}, + silent:true, + filter:function(event,player){ + if(player==_status.currentPhase) event.gaintag.add('hiroto_huyu2'); + return false; + }, }, hiroto_zonglve:{ enable:'phaseUse', @@ -515,13 +525,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, position:'he', content:function(){ - 'step 0' - player.draw(cards.length*2); - 'step 1' - if(get.itemtype(result)=='cards'){ - player.addTempSkill('shizuku_sizhi2'); - player.markAuto('shizuku_sizhi2',result); - } + player.draw(cards.length*2).gaintag=['shizuku_sizhi2']; + player.addTempSkill('shizuku_sizhi2'); }, ai:{ order:5, @@ -529,49 +534,36 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, }, shizuku_sizhi2:{ - intro:{ - mark:function(dialog,content,player){ - if(content&&content.length){ - if(player==game.me||player.isUnderControl()){ - dialog.addAuto(content); - } - else{ - return '本回合以此法获得了'+get.cnNumber(content.length)+'张牌'; - } - } - }, - content:'cards', + onremove:function(player){ + player.removeGaintag('shizuku_sizhi2'); }, - onremove:true, mod:{ targetInRange:function(card,player,target){ if(!card.cards) return; - var storage=player.getStorage('shizuku_sizhi2'); for(var i of card.cards){ - if(!storage.contains(i)||get.color(i)!='black') return; + if(!i.hasGaintag('shizuku_sizhi2')||get.color(i)!='black') return; } return true; }, cardUsable:function(card,player,target){ if(!card.cards) return; - var storage=player.getStorage('shizuku_sizhi2'); for(var i of card.cards){ - if(!storage.contains(i)||get.color(i)!='black') return; + if(!i.hasGaintag('shizuku_sizhi2')||get.color(i)!='black') return; } return Infinity; }, ignoredHandcard:function(card,player){ - if(player.getStorage('shizuku_sizhi2').contains(card)&&get.color(card)=='red'){ + if(card.hasGaintag('shizuku_sizhi2')&&get.color(card)=='red'){ return true; } }, cardDiscardable:function(card,player,name){ - if(name=='phaseDiscard'&&player.getStorage('shizuku_sizhi2').contains(card)&&get.color(card)=='red'){ + if(name=='phaseDiscard'&&card.hasGaintag('shizuku_sizhi2')&&get.color(card)=='red'){ return false; } }, aiOrder:function(player,card,num){ - if(player.getStorage('shizuku_sizhi2').contains(card)&&get.color(card)=='black') return num-0.1; + if(get.itemtype(card)=='card'&&card.hasGaintag('shizuku_sizhi2')&&get.color(card)=='black') return num-0.1; }, }, }, @@ -2608,18 +2600,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){ return 3; }); 'step 1' - if(result.control=='cancel2'){event.finish();return;} + if(result.control=='cancel2') return; player.logSkill('shiorimiyuki_tingxian'); var num=1+result.index; - player.draw(num); - 'step 2' - event.cards=result; + player.draw(num).gaintag=['shiorimiyuki_tingxian']; player.recover(); - 'step 3' - if(get.itemtype(cards)=='cards'){ - trigger.shiorimiyuki_tingxian=cards; - player.addTempSkill('shiorimiyuki_tingxian2'); - } + player.addTempSkill('shiorimiyuki_tingxian2'); }, }, shiorimiyuki_tingxian2:{ @@ -2628,25 +2614,22 @@ game.import('character',function(lib,game,ui,get,ai,_status){ charlotte:true, mod:{ aiOrder:function(player,card,num){ - var cards=_status.event.getParent('phaseUse').shiorimiyuki_tingxian; - if(cards&&cards.contains(card)) return num+2; + if(get.itemtype(card)=='card'&&card.hasGaintag('shiorimiyuki_tingxian')) return num+2; }, - aiValuetarget:function(player,card,num){ - var cards=_status.event.getParent('phaseUse').shiorimiyuki_tingxian; - if(cards&&cards.contains(card)) return 0; + aiValue:function(player,card,num){ + if(get.itemtype(card)=='card'&&card.hasGaintag('shiorimiyuki_tingxian')) return 0; }, }, filter:function(event,player){ - var hs=player.getCards('h'); - return Array.isArray(event.shiorimiyuki_tingxian)&&event.shiorimiyuki_tingxian.filter(function(card){ - return hs.contains(card); - }).length>0 + return player.countCards('h',function(card){ + return card.hasGaintag('shiorimiyuki_tingxian'); + })>0; }, content:function(){ - var hs=player.getCards('h'); - player.loseHp(trigger.shiorimiyuki_tingxian.filter(function(card){ - return hs.contains(card); - }).length); + player.loseHp(player.countCards('h',function(card){ + return card.hasGaintag('shiorimiyuki_tingxian'); + })); + player.removeGaintag('shiorimiyuki_tingxian'); }, }, shizuru_nianli:{ @@ -3965,6 +3948,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){ content:function(){ trigger.directHit.addArray(game.players); }, + ai:{ + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + return arg.card.name==player.storage.riki_spwenji_respond; + }, + }, } } }, @@ -4113,6 +4102,21 @@ game.import('character',function(lib,game,ui,get,ai,_status){ if(trigger.name=='useCard') trigger.directHit.addArray(game.players); else trigger.directHit.add(player); }, + ai:{ + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + return arg.card.name=='sha'; + }, + }, + global:'doruji_feiqu_ai', + }, + doruji_feiqu_ai:{ + ai:{ + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + return arg.card.name=='sha'&&(arg.target.hasSkill('doruji_feiqu')||arg.target.hasSkill('godan_feiqu')); + }, + }, }, akane_jugu:{ audio:2, @@ -4306,30 +4310,22 @@ game.import('character',function(lib,game,ui,get,ai,_status){ if(get.itemtype(trigger.respondTo[1])=='card') cards.push(trigger.respondTo[1]); else if(trigger.respondTo[1].cards) cards.addArray(trigger.respondTo[1].cards); cards=cards.filterInD('od'); - trigger.player.gain(cards,'gain2','log'); + trigger.player.gain(cards,'gain2','log').gaintag.add('sasami_funan'); trigger.player.addTempSkill('sasami_funan_use'); - if(!trigger.player.storage.sasami_funan_use){ - trigger.player.storage.sasami_funan_use=[]; - } - trigger.player.storage.sasami_funan_use.addArray(cards); } 'step 1' var cards=trigger.cards.filterInD('od'); player.gain(cards,'log','gain2'); }, subSkill:{ - jiexun:{ - charlotte:true, - mark:true, - intro:{ - content:'你发动“复难”时,无须令其他角色获得你使用的牌' - }, - }, use:{ - onremove:true, + onremove:function(player){ + player.removeGaintag('sasami_funan'); + }, + charlotte:true, mod:{ cardEnabled2:function(card,player){ - if(player.storage.sasami_funan_use&&player.storage.sasami_funan_use.contains(card)){ + if(get.itemtype(card)=='card'&&card.hasGaintag('sasami_funan')){ return false; } } @@ -5690,6 +5686,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){ init:function(player,skill){ if(!player.storage[skill]) player.storage[skill]=[]; }, + ai:{ + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + return player.storage.yukine_magic&&player.storage.yukine_magic.contains(arg.card.name); + }, + }, }, komari_tiankou:{ trigger:{ @@ -6504,6 +6506,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){ var next=player.chooseToUse(); next.set('norestore',true); next.set('_backupevent','nsdaizhanx'); + next.set('custom',{ + add:{}, + replace:{window:function(){}} + }); next.backup('nsdaizhanx'); }, }, @@ -11854,8 +11860,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){ rin_baoqiu_info:'锁定技,你的攻击范围+2。当你使用【杀】指定目标后,你进行判定。若结果:为红色,此【杀】对其的伤害值基数+1;为黑色,其无法闪避此【杀】;为♠/♥,此【杀】不计入使用次数限制且你摸一张牌;为♦/♣,目标角色的所有非锁定技失效直到回合结束,且你弃置其一张牌。', sasami_miaobian:'喵变', sasami_miaobian_info:'当你的体力值变为:3以下时,你获得技能〖公清〗,2以下时,你获得技能〖复难〗,1以下时,你获得技能〖暴球〗', - "sasami_gongqing":"公清", - "sasami_gongqing_info":"锁定技。当你受到伤害时,若伤害来源的攻击范围:<3,则你令此伤害的数值减为1。>3,你令此伤害+1。", + sasami_gongqing:"公清", + sasami_gongqing_info:"锁定技。当你受到伤害时,若伤害来源的攻击范围:<3,则你令此伤害的数值减为1。>3,你令此伤害+1。", sasami_funan:'复难', sasami_funan_info:'其他角色使用或打出牌响应你使用的牌时,你可令其获得你使用的牌(其本回合不能使用或打出这些牌),然后你获得其使用或打出的牌。', sasami_baoqiu:'暴球', diff --git a/character/extra.js b/character/extra.js index 87af34851..57f8b8264 100755 --- a/character/extra.js +++ b/character/extra.js @@ -1946,10 +1946,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){ if(get.tag(card,'respondSha')&¤t<0) return 0.6 } }, - respondSha:true, - order:4, - useful:-1, - value:-1 + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + return arg.card.name=='sha'&&get.suit(arg.card)=='heart'; + }, } }, wuhun:{ diff --git a/character/mobile.js b/character/mobile.js index 8436a56e7..9d818ef78 100644 --- a/character/mobile.js +++ b/character/mobile.js @@ -9,13 +9,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){ mobile_default:["miheng","taoqian","lingcao","sunru","lifeng","zhuling","liuye","zhaotongzhaoguang","majun","simazhao","wangyuanji","pangdegong","shenpei","hujinding","zhangyì","jiakui","yangbiao","chendeng","dongcheng","yangyi","dengzhi","zhengxuan","sp_sufei","furong","dingyuan","simashi","yanghuiyu","hucheer"], mobile_yijiang:["yj_zhanghe","yj_zhangliao","yj_xuhuang","yj_ganning"], mobile_sunben:["re_sunben"], - mobile_standard:["xin_xiahoudun"], + mobile_standard:["xin_xiahoudun","xin_zhangfei"], mobile_shenhua:["re_pangtong","re_guanqiujian","xin_yuanshao","re_liushan","re_dongzhuo","re_sp_zhugeliang","re_sunjian"], mobile_yijiang1:["re_jikang","old_bulianshi","xin_liaohua","xin_caozhang","re_xusheng","xin_chengpu","xin_jianyong","xin_gongsunzan","xin_zhuran","re_lingtong","re_liubiao"], mobile_sp:["old_yuanshu","re_wangyun","re_baosanniang","re_weiwenzhugezhi","re_zhanggong","re_xugong","re_heqi","liuzan","xin_hansui"], }, }, character:{ + xin_zhangfei:['male','shu',4,['new_repaoxiao','liyong']], xin_hansui:['male','qun',4,['xinniluan','xiaoxi_hansui']], hucheer:['male','qun',4,['daoji']], re_lingtong:['male','wu',4,['rexuanfeng']], @@ -313,6 +314,80 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, }, skill:{ + //铁骑飞 + liyong:{ + audio:'retishen', + trigger:{player:'shaMiss'}, + forced:true, + filter:function(event,player){ + return player.isPhaseUsing(); + }, + content:function(){ + trigger.getParent().liyong=true; + player.addTempSkill('liyong2','phaseUseEnd'); + }, + }, + liyong2:{ + audio:'retishen', + mark:true, + intro:{ + content:'铁骑!强命!加伤!然后掉血嘞…', + }, + trigger:{player:'useCardToPlayered'}, + forced:true, + filter:function(event,player){ + if(!event.card||event.card.name!='sha') return false; + var evt=event.getParent(); + if(evt.liyong) return false; + var history=player.getHistory('useCard',function(evt){ + return evt.card.name=='sha'; + }); + var evt2=history[history.indexOf(evt)-1]; + return evt2&&evt2.liyong; + }, + logTarget:'target', + content:function(){ + var target=trigger.target; + target.addTempSkill('fengyin'); + trigger.directHit.add(target); + var id=target.playerid; + var map=trigger.customArgs; + if(!map[id]) map[id]={}; + if(!map[id].extraDamage) map[id].extraDamage=0; + map[id].extraDamage++; + trigger.getParent().liyong2=true; + }, + group:['liyong3','liyong4'], + }, + liyong3:{ + trigger:{source:'damageSource'}, + forced:true, + popup:false, + filter:function(event,player){ + return event.card&&event.card.name=='sha'&& + event.player.isAlive()&&event.getParent(2).liyong2==true; + }, + content:function(){ + player.loseHp(); + }, + }, + liyong4:{ + trigger:{player:'useCardAfter'}, + forced:true, + silent:true, + filter:function(evt,player){ + if(!evt.card||evt.card.name!='sha') return false; + if(evt.liyong) return false; + var history=player.getHistory('useCard',function(evt){ + return evt.card.name=='sha'; + }); + var evt2=history[history.indexOf(evt)-1]; + return evt2&&evt2.liyong; + }, + content:function(){ + player.removeSkill('liyong2'); + }, + }, //韩遂 xinniluan:{ trigger:{global:'phaseJieshuBegin'}, @@ -687,7 +762,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ filter:function(event,player){ return event.player.getStockSkills('仲村由理','天下第一').filter(function(skill){ var info=get.info(skill); - return info&&!info.juexingji&&!info.zhuSkill&&!info.charlotte&&!info.limited; + return info&&!info.juexingji&&!info.hiddenSkill&&!info.zhuSkill&&!info.charlotte&&!info.limited; }).length>0; }, logTarget:'player', @@ -700,7 +775,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ player.awakenSkill('quanfeng'); var list=trigger.player.getStockSkills('仲村由理','天下第一').filter(function(skill){ var info=get.info(skill); - return info&&!info.juexingji&&!info.zhuSkill&&!info.charlotte&&!info.limited; + return info&&!info.juexingji&&!info.hiddenSkill&&!info.zhuSkill&&!info.charlotte&&!info.limited; }); if(list.length==1) event._result={control:list[0]}; else player.chooseControl(list).set('prompt','选择获得'+get.translation(trigger.player)+'的一个技能').set('forceDie',true).set('ai',function(){ @@ -6479,7 +6554,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ chengzhao_info:'一名角色的结束阶段,若你于本回合内获得了两张以上的牌,则你可以与一名其他角色拼点。若你赢,你视为对其使用一张无视防具的【杀】。', yangyi:'杨仪', duoduan:'度断', - duoduan_info:'每回合限一次,当你成为【杀】的目标后,你可以重铸一张牌。若如此做,此【杀】的使用者选择一项:摸两张牌令此【杀】无效,或弃置一张牌并令你不能闪避此【杀】。', + duoduan_info:'每回合限一次,当你成为【杀】的目标后,你可以重铸一张牌。若如此做,你选择一项:①令使用者摸两张牌,且此【杀】无效。②令使用弃置一张牌,且你不能响应此【杀】。', gongsun:'共损', gongsun_info:'出牌阶段开始时,你可以弃置两张牌并指定一名其他角色。你选择一个基本牌或普通锦囊牌的牌名。直到你的下回合开始或你死亡,你与其不能使用或打出或弃置此名称的牌。', gongsun_shadow:'共损', @@ -6575,7 +6650,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ hongyi2:'弘仪', hongyi_info:'出牌阶段限一次,你可以弃置X张牌并选择一名其他角色(X为场上已阵亡的角色数且至多为2)。你的下回合开始前,该角色造成伤害时进行判定,若结果为:黑色,此伤害-1。红色,受到伤害的角色摸一张牌。', quanfeng:'劝封', - quanfeng_info:'锁定技,限定技,一名角色死亡时,你选择获得其的一个技能(主公技,限定技,觉醒技,带有Charlotte标签的技能除外),然后加1点体力上限并回复1点体力。', + quanfeng_info:'锁定技,限定技,一名角色死亡时,你选择获得其的一个技能(主公技,限定技,觉醒技,隐匿技,带有Charlotte标签的技能除外),然后加1点体力上限并回复1点体力。', simashi:'司马师', baiyi:'败移', baiyi_info:'限定技,出牌阶段,若你已受伤,你可以交换两名其他角色的座次。', @@ -6595,6 +6670,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){ xinniluan_info:'其他角色的结束阶段,若其本回合对除其以外的角色使用过牌,则你可以对其使用一张【杀】。若以此法使用的【杀】造成伤害,则你弃置其一张牌。', xiaoxi_hansui:'骁袭', xiaoxi_hansui_info:'你可以将一张黑色牌当做【杀】使用或打出。', + xin_zhangfei:'手杀张飞', + liyong:'厉勇', + liyong2:'厉勇', + liyong3:'厉勇', + liyong_info:'锁定技,若你于出牌阶段使用的【杀】被【闪】抵消,本阶段你下一张【杀】不可被响应且伤害+1,指定的目标本回合非锁定技失效,当此【杀】造成伤害后,若目标角色未死亡,你失去1点体力。', mobile_standard:'手杀异构·标准包', mobile_shenhua:'手杀异构·神话再临', mobile_yijiang1:'手杀异构·一将成名', diff --git a/character/old.js b/character/old.js index fc7e67cc4..b8ff1c0ab 100755 --- a/character/old.js +++ b/character/old.js @@ -34,7 +34,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ old_caochong:['male','wei',3,['oldrenxin','oldchengxiang']], yuji:['male','qun',3,['old_guhuo'],['forbidai']], zhangjiao:['male','qun',3,['leiji','guidao','huangtian'],['zhu']], - old_zhangfei:['male','shu',4,['paoxiao','new_tishen']], + old_zhangfei:['male','shu',4,['new_repaoxiao','new_tishen']], old_zhaoyun:['male','shu',4,['longdan','new_yajiao']], old_huatuo:['male','qun',3,['jijiu','chulao']], jsp_caoren:['male','wei',4,['kuiwei','yanzheng']], diff --git a/character/ow.js b/character/ow.js index 036731499..1de07d1f5 100644 --- a/character/ow.js +++ b/character/ow.js @@ -1,3663 +1,3663 @@ -'use strict'; -game.import('character',function(lib,game,ui,get,ai,_status){ - return { - name:'ow', - character:{ - ow_liekong:['female','shu',3,['shanxian','shanhui']], - ow_sishen:['male','shu',4,['xiandan','yihun','shouge']], - ow_tianshi:['female','qun',3,['shouhu','ziyu','feiying']], - ow_falaozhiying:['female','shu',3,['feidan','huoyu','feiying']], - ow_zhixuzhiguang:['female','qun',3,['guangshu']], - ow_luxiao:['male','wu',3,['yuedong','kuoyin','huhuan']], - ow_shibing:['male','shu',4,['tuji','mujing','lichang']], - ow_yuanshi:['male','qun',3,['feiren','lianpo','zhanlong']], - ow_chanyata:['male','qun',3,['xie','luan','sheng']], - ow_dva:['female','shu',2,['jijia','tuijin','zihui','chongzhuang']], - ow_mei:['female','wei',3,['bingqiang','jidong','baoxue']], - ow_ana:['female','wei',3,['zhiyuan','mianzhen','aqianghua']], - ow_heibaihe:['female','qun',3,['juji','duwen','dulei']], - ow_maikelei:['male','shu',4,['shanguang','tiandan','shenqiang']], - ow_kuangshu:['male','shu',3,['liudan','shoujia','shihuo']], - - ow_tuobiang:['male','shu',3,['paotai','maoding']], - ow_baolei:['male','qun',4,['bshaowei','zhencha']], - ow_banzang:['male','qun',4,['bfengshi','yinbo']], - ow_laiyinhate:['male','qun',4,['zhongdun','mengji']], - ow_luba:['male','shu',4,['liangou','xiyang']], - ow_wensidun:['male','shu',4,['feitiao','dianji']], - ow_zhaliya:['female','wei',4,['pingzhang','liyong']], - - ow_heiying:['female','wei',3,['qinru','yinshen','maichong']], - ow_orisa:['female','wu',4,['qianggu','woliu']], - }, - characterIntro:{ - ow_orisa:'奥丽莎是用在努巴尼昙花一现的OR15防御机器人的零件组装而成的,她是这座城市的新一代守护者,但依然有很大的成长空间', - ow_liekong:'莉娜·奥克斯顿(代号:“猎空”)是守望先锋原型机试飞计划的最年轻成员。但在第一次试飞过程中,原型机的传送阵列出现故障,包括飞行员在内完全失踪。莉娜在几个月后再次出现,不过她身上的分子却无法和时间流同步。这种被称为“时间解离”的症状使她彻底变成了一个“活生生”的幽灵,时隐时现。直到一位名叫温斯顿的科学家设计出了“时间加速器”,一台可以让“猎空”维持在当前时间的装置。不仅如此,这一装置还让“猎空”有能力控制她自己的时间流,使她可以任意加速或减慢时间。有了这一全新的能力,她成了守望先锋最强大的特工之一。守望先锋解散后,“猎空”依旧选择为了正义而战,守护无辜。', - ow_sishen:'关于这个黑袍恐怖分子的传闻并不多,只知道大家都称他为“死神”。虽然没人知道他的真实身份和动机,但有一点是可以肯定的,他的出现意味着死亡。“死神”是一名极其不稳定、残暴、冷酷的雇佣兵,在世界各地犯下多起恐怖袭击案件。在过去的数十年间,他参与了许多武装冲突,但其本人却不属于任何组织。在多年的追踪后,“死神”神秘的面纱终于被慢慢揭开。据信,“死神”正在追杀前守望先锋特工并系统地逐一消灭。', - ow_tianshi:'齐格勒是瑞士一家顶尖医院的手术部门负责人。正是她在医学领域的成就,引起了守望先锋的注意。由于齐格勒的双亲都被战争夺走了生命,因此她从一开始就极其反对该组织通过军事手段进行维和。但最终,她意识到守望先锋给她提供了一个可以拯救更多人生命的机会。作为守望先锋医学研究部门的负责人,安吉拉致力于更好地在前线治疗受到致命伤的病员。尽管她对守望先锋做出了巨大的贡献,但齐格勒博士经常质疑她的上司以及守望先锋的长远目标。而当守望先锋解散之后,齐格勒博士便致力于帮助那些受战争波及的受难者。', - ow_falaozhiying:'本名法芮尔,来自一个军功卓越的军人世家,贡献与荣耀就是她最高的追求。在加入埃及军队后,她的坚韧和在战术上的天赋使她很快就晋升为了一名军官。作为一名果敢的领袖,任何在她手下服役的士兵都对她抱有绝对的忠诚。有了所有这些卓越的表现,法芮尔自然成了守望先锋最青睐的一名候选人。但在她正式加入之前,守望先锋就解散了。当她带着所有的荣誉退役后,法芮尔加入了一家名为“海力士国际安保”的私人安保公司,该公司的最重要的一笔订单就是负责保护吉萨高原地下的人工智能研究设施。尽管她对守望先锋的解散感到无比的遗憾,但她依旧梦想着能为正义而战并改变这个残破的世界。', - ow_zhixuzhiguang:'当被认为是为数不多可以成为光子建筑师的人才之后,年轻的塞特娅·法斯瓦尼离开了贫穷的家乡,成为了费斯卡光子建筑师学院的一员。她很快就成为了乌托邦最顶尖的光子建筑师。但费斯卡集团在塞特娅身上还是看到了更广阔的发展潜力。费斯卡集团称其为“秩序之光”,为了集团的利益和扩大在其他国家的影响力,将其派遣到全球执行秘密任务。虽然“秩序之光”相信她的所作所为是为了实现人性之“大善”,但有时候她也会怀疑她所希望实现的控制和秩序,是否真的是人类最需要的。', - ow_luxiao:'卢西奥•科雷亚•多斯桑托斯在里约热内卢长大。“智能危机”结束后,由于经济的一蹶不振导致这里变成了一个贫穷拥挤的贫民区。他想找到一个办法激发周围人的信心与活力:音乐。他开始在街边、社区派对进行表演,随着年龄的增长便开始了一系列传奇的地下演出。但当多国集团费斯卡集团计划重建城市的大部分地区时,卢西奥所在的社区陷入了混乱,人们失去了自由。卢西奥绝对不会容忍这一切。他偷走了费斯卡用来压迫人民的音波技术,反过来将人们团结在一起。最终,在一场暴动中,他们将费斯卡集团赶出了家园。卢西奥的领导能力让他在一夜之间成为了明星和社会正能量的象征。他的音乐在人们心中的地位如火箭般蹿升。随着影响力的不断扩大,卢西奥意识到他有机会可以改变这个世界,让这个世界变得更美好。', - ow_shibing:'被全球通缉的独行侠“士兵:76”独自一人发动了一场旨在查出守望先锋解散真相的战争。“士兵:76”在全球一系列针对金融机构、秘密集团和守望先锋基地的袭击活动中被曝光。尽管外界至今不清楚他的动机是什么,但有人认为他曾是一位守望先锋特工,决心查出守望先锋垮台的幕后黑手。', - ow_yuanshi:'岛田忍者家族大名最年轻的儿子,但对家族的非法生意毫无兴趣,被视为一个危险的累赘。在家族大名意外死亡后,他与哥哥半藏的矛盾激化,最终导致了一场生死对决,源氏也因此差点送命。后来被守望先锋救下,并被改造成机械忍者以摧毁他父亲的邪恶帝国。在完成任务后,源氏因无法接受自己的机械身躯,离开了守户先锋,并游历世界希望能找到自己存在的意义。数年之后,他遇到了智械僧侣禅雅塔,并且在这位僧侣的引导下,源氏体内的人类和机械体验终于融合在了一起。他开始明白,尽管他有一副机械身躯,但他的人类灵魂是完整的,他渐渐意识到自己的新形态是给予自己的恩赐和力量。', - ow_chanyata:'在“智能危机”结束之后,一群被放逐的智能机器人感受到了被其称为“灵魂觉醒”的升华之道,他们渐渐相信他们和人类一样,同样拥有灵魂。由神秘僧侣泰哈撒·孟达塔带领的这些僧侣开始寻找让人类和机器人重回曾经的和谐相处之道。他们最终被世人所接纳,并得到了全球数百万人的支持。但其中一位僧侣,禅雅塔并不赞同这一新道路。他认为要解决人类和机器人之间根深蒂固的问题,不能依靠循循善诱,而必须通过个体联系和互动。最终,他选择离开寺庙,游走世界,帮助那些他所遇到的人摆脱凡尘。但如果有必要,他也会为了保护无辜而拿起武器,无论人类还是机器人。', - ow_dva:'D.Va曾是一名职业玩家,而现在则利用自己的技巧驾驶一台尖端机甲保卫国家。随着智能机械不断进化,它最终干扰了MEKA的无人机控制网络,迫使军方派驾驶员驾驶这些机甲。由于难以找到合适的候选人,政府开始向那些拥有足以操控机甲尖端武器系统的必要反应和本能的国内职业玩家寻求帮助,其中就包括顶尖玩家之一的“D.Va”宋哈娜。作为一名为了获胜不惜一切代价的精英玩家,D.Va从来都不会对对手表现出丝毫的仁慈。D.Va将这次新任务视为一款全新的游戏,无所畏惧地和其他MEKA机甲冲向战场,随时准备保卫自己的国家。最近,她开始向她的粉丝直播战斗行动,而这也让她成为了世界巨星。', - ow_mei:'守望先锋为了查明全球不断升级的怪异气候现象的真正原因,在世界各个位置建立了一系列生态监测站。周美灵就是这一长久项目的成员之一。当她来到该项目的南极洲监控站时,一场突如其来的极地风暴摧毁了大部分设施并将这里与外界隔绝了开来。随着补给物资的不断消耗,科学家们进入了急冻状态希望能够撑到救援队抵达的那一天。但救援并没有抵达。几年后,当这些科学家的急冻舱最终被发现时,美是唯一的幸存者。此时,守望先锋已经解散,所有的生态监测站也都已经被废弃,他们之前收集的研究数据全部丢失。美最终决定独自继续她的工作。她带上了一台可穿戴式气候控制装置,游历世界,希望能够重新建立起生态监测网络,查出威胁着这个星球生态系统的真正原因。', - ow_ana:'守望先锋的创始成员之一,世界公认的顶级狙击手。智械危机结束后,安娜被晋升为了上尉。尽管身居要职,但已年过半百的安娜拒绝离开战场,依然亲临前线。直至在一次人质解救行动中,遭遇了一个叫做“黑百合”的黑爪特工,所有人都认为安娜死在了那场战斗中。但事实上,安娜活了下来,身受重伤并且失去了自己的右眼。在恢复期间,她感受到了战斗中生命的不可承受之重,因此决定就此隐居。然而随着时间一天天过去,看着自己家乡遭到的威胁愈演愈烈,她突然意识到自己依然有责任保护身边的亲人。在“征用”了守望先锋军械库中的装备后,安娜重新回到了这个世界,为了一个更安全、稳定的和平世界而战。', - ow_heibaihe:'“黑百合”在成为如今的杀手之前,曾与对抗恐怖组织“黑爪”的守望先锋探员杰哈·拉克瓦结婚。在多次刺杀杰哈无果之后,黑爪决定将目标转向他的妻子,艾米丽。黑爪特工绑架了艾米丽并对其进行了一项高强度神经重构计划。他们击垮了她的意志,抑制了其本身的人性,将其变成了一个潜伏特工。她最终被守望先锋探员找到并在确认无致命伤之后重新过上了以前的生活。两周之后,她杀死了睡梦中的杰哈,并回归了黑爪。', - ow_maikelei:'曾是美国西南部因非法军火交易而臭名昭著的“死局”帮中,最令人胆寒的一员,后被守望先锋逮捕。由于其枪法精湛且足智多谋,守望先锋给了他两个选择:在最高安全级别的监狱中度过余生,或加入守望先锋的秘密行动部队“暗影守望”。他选择了后者。尽管一开始他对守望先锋的理念嗤之以鼻,但他逐渐相信可以通过扫除世上的不公,来弥补自己过去犯下的罪行。后来,暗影守望内部出现了异样的气氛:废除守望先锋,独掌大权。麦克雷由于不想参与其中,于是便独自离开,销声匿迹。多年之后,他以雇佣兵的身份再次出现。尽管许多大小团体都想拉拢他,但他只为自己眼中的正义而战。', - ow_kuangshu:'由于澳大利亚智能中枢核心在遭到攻击后发生爆炸,这片地区现在变成了寸草不生的辐射荒地。但即便如此,还是有一群自称为“拾荒者”的人类生存了下来。他们在残骸中寻找一切还可利用的东西,渐渐形成了一个野蛮、危险的团体。“狂鼠”就是其中的一员。和其他人一样,他也受到了辐射,因此变成了一个痴迷于危险炸弹的疯子。当他在中枢废墟中发掘出一个极其珍贵的宝藏后,全世界都知道了这个疯子的名号。尽管几乎没人知道他到底发现了什么,但他身后总有数不清的赏金猎人、黑帮和投机分子想要杀掉他,直到他与“拾荒者”打手“路霸”达到了一个协议:只要今后找到的宝贝五五分成,“路霸”就会是“狂鼠”的私人保镖。', - ow_tuobiang:'托比昂是一个极其不信任智械的天才工程师,但他的同行都认为这只是他杞人忧天而已。但托比昂最担心的事情最终还是发生了,一场机器人对抗其人类发明者的“智能危机”在全球范围内爆发。由于其在工程学方面的天才造诣,守望先锋向他伸出了橄榄枝,并将其纳入了最早的守望先锋攻击部队,而他也证明了自己在终结这场危机中的关键价值。但在守望先锋解散后,托比昂设计出的许多武器被偷走并被藏在世界各地。出于对自己作品的责任心,托比昂便发誓不能让这些武器落入敌手,危害无辜的世人。', - ow_baolei:'“堡垒”系列在设计之初是被用于维和目的的,这一系列的机器单位拥有能够快速在突击和攻城模式之间转换的独特能力。但在“智能危机”期间,该系列却被用来对抗其人类发明者,成为了机器人叛军的中坚力量。随着后来危机的解除,几乎所有的“堡垒”系列机器人都被销毁或拆解。直到今天,“堡垒”依旧是当年那场可怕战争的代名词。但是有一台独特的“堡垒”机器人,在那场战争的决战中严重受损,因此被遗忘了数十年。直到有一天,它被意外地重新激活,它的战斗程序几乎全部受损,取而代之的是对自然世界及其住民的强烈好奇。好奇的“堡垒”于是在这个被战火蹂躏过的世界上,开始了探索和寻找自我价值的旅途。', - ow_banzang:'岛田家据传已有数百年的历史。以忍者为主要成员的岛田家,经过多年的发展,已经建立起一个以军火和非法物资交易为主的庞大黑道帝国。作为大名的长子,半藏注定要继承他的父亲统治岛田帝国。父亲过世后,家族长老就建议半藏帮助他那刚愎自用的弟弟源氏,以便两人携手管理岛田帝国。在遭到源氏拒绝后,半藏被迫亲手了结了自己的弟弟。半藏因此深受打击,他拒绝继承父亲的遗产并最终抛弃了自己的家族和所有辛苦换来的成果。现在,半藏四海为家,不断磨练着自己作为一名武士的技巧,希望终有一天能挽回自己的名誉并真正放下自己的过去。', - ow_laiyinhate:'莱因哈特•威尔海姆的行事作风就像一个属于过去的勇士,时刻铭记着骑士的信条:无畏、公正、勇敢。莱因哈特独特的道德观和舍小为大的信念,深得其上级的喜爱。他有话直说,因此成为了守望先锋最坚定的拥护者,同时在有必要时,也是守望先锋最刻薄的批评者,时刻提醒着其他人,守望先锋是一支正义之师。莱因哈特一直服役到将近六十岁,因此不得不面临强制退役。而守望先锋又深陷腐败和煽动叛乱之嫌的泥沼,莱因哈特只能眼睁睁地看着自己守护了一生的信念被吞噬。尽管守望先锋最终解散,但莱因哈特绝不会在世界陷入混乱之时袖手旁观。他再一次穿上了十字军战甲,立誓为正义而战,像曾经的白银骑士那样守护欧罗巴大陆无辜的人民,坚信光明的未来必将到来。', - ow_luba:'“路霸”马可曾是众多居住在澳洲内陆的居民之一。在智能危机爆发后,政府作出了一个极具争议的决定,将这里送给了差点摧毁整个国家的智能机器人,以求达成永久的和平协定。这一决定直接导致马可和大批居民被迫离开,因失去家园而怒不可遏的马可和其他人开始了一场暴力起义,最终,引发了一场大爆炸,导致周围数公里地区全部遭到辐射,只留下了变形的金属和残骸。为了在这种环境下生存下来,他戴上了面具、骑着破烂摩托开上了通往澳洲内陆的残破高速公路。一路上,他的人性一点一点地被消磨,马可最终消失了,而“路霸”就此诞生。', - ow_wensidun:'在“地平线”月球殖民地的居民中,有一群经过基因改造的大猩猩。其中一只大猩猩在接受了哈罗德·温斯顿博士团队的基因改造后,显示出了极快的脑部发育迹象,博士本人也将人类科学和创造力教给了这只猩猩。但当其他大猩猩发动叛乱,杀死了所有科学家并占领殖民地后,他的生活便再也回不到过去了。出于对哈罗德博士的爱戴,这只大猩猩决定继承他的姓氏:温斯顿,并设计出了一枚临时火箭逃往了地球。他找到了新家:守望先锋 —— 这是一个代表着他所憧憬的所有人性的组织。温斯顿终于有机会实现哈罗德博士生前不断教导他的英雄理念。但随着后来守望先锋的解散,温斯顿也隐居了起来,再一次与他报以厚望的世界失去联系,但他却从未放弃对英雄最终回归的期望。', - ow_zhaliya:'亚历山德拉·查莉娅诺娃是世界上最强壮的女运动员之一。然而就在世锦赛前夕,一直处于休眠状态的西伯利亚机器人控制中枢再度发动攻击,战火再次蔓延到了她的家乡。早已名利双收的亚历山德拉,毅然抛弃了一切,立即回到家乡加入了当地的防御部队。', - ow_heiying:'作为全世界最臭名昭著的黑客,“黑影”利用信息与情报操控权贵。早在她称自己为“黑影”之前,░░░░░░是千千万万在智械危机后变成孤儿的儿童之一。在家乡大部分基础设施都被摧毁的情况下,她依靠自己在黑客以及计算机方面的天赋活了下来。在黑客领域的一连串的胜利让░░░░░░对自己的实力过度自信,最终她在毫无防备的情况下,陷入了一张覆盖全球的阴谋网——并且也因此被人盯上了。由于自己的安全面临严重威胁,░░░░░░不得不删除关于自己的全部信息,从此销声匿迹。后来,她以“黑影”的身份再度出现,经过改造的她决心查出那张阴谋网背后的真相。', - }, - skill:{ - woliu:{ - trigger:{player:'phaseEnd'}, - direct:true, - unique:true, - forceunique:true, - content:function(){ - 'step 0' - player.chooseTarget(get.prompt('woliu'),lib.filter.notMe,[1,2]).ai=function(target){ - if(get.attitude(player,target)<0){ - return get.effect(target,{name:'sha'},player,player); - } - return 0; - } - 'step 1' - if(result.bool){ - player.logSkill('woliu',result.targets); - var list=[player].concat(result.targets); - for(var i=0;i0){ - return [0,num]; - } - if(target.hp==1&&!target.hasShan()) return; - return [1,num]; - } - } - } - } - }, - qianggu:{ - enable:'phaseUse', - usable:1, - filterCard:true, - selectCard:2, - position:'he', - check:function(card){ - return 8-get.value(card); - }, - filter:function(event,player){ - return player.countCards('he')>=2; - }, - content:function(){ - player.changeHujia(2); - player.addTempSkill('qianggu2',{player:'phaseBegin'}); - }, - ai:{ - result:{ - player:1 - }, - order:2.5 - } - }, - qianggu2:{ - trigger:{target:'useCardToBefore'}, - forced:true, - filter:function(event,player){ - return event.card.name=='sha'; - }, - mark:true, - intro:{ - content:'其他角色对你使用杀时需要弃置一张基本牌,否则杀对你无效' - }, - content:function(){ - "step 0" - var eff; - if(player.hasSkill('woliu2')){ - eff=-get.attitude(trigger.player,player); - } - else{ - eff=get.effect(player,trigger.card,trigger.player,trigger.player); - } - trigger.player.chooseToDiscard('强固:弃置一张基本牌,否则杀对'+get.translation(player)+'无效',function(card){ - return get.type(card)=='basic'; - }).set('ai',function(card){ - if(_status.event.eff>0){ - return 10-get.value(card); - } - return 0; - }).set('eff',eff); - "step 1" - if(result.bool==false){ - trigger.cancel(); - } - }, - ai:{ - effect:{ - target:function(card,player,target,current){ - if(card.name=='sha'){ - if(_status.event.name=='qianggu2') return; - if(get.attitude(player,target)>0) return; - var bs=player.getCards('h',{type:'basic'}); - if(bs.length<2) return 0; - if(player.hasSkill('jiu')||player.hasSkill('tianxianjiu')) return; - if(bs.length<=3&&player.countCards('h','sha')<=1){ - for(var i=0;i0; - }, - filterCard:true, - usable:1, - viewAs:{name:'jingleishan',nature:'thunder'}, - check:function(card){ - return 8-get.value(card) - }, - ai:{ - order:8, - expose:0.2, - threaten:1.2 - }, - mod:{ - playerEnabled:function(card,player,target){ - if(_status.event.skill=='dianji'&&get.distance(player,target)>2) return false; - } - } - }, - feitiao:{ - trigger:{player:'phaseUseBegin'}, - direct:true, - filter:function(event,player){ - return player.countCards('he')>0; - }, - content:function(){ - 'step 0' - var next=player.chooseCardTarget({ - prompt:get.prompt('feitiao'), - position:'he', - filterCard:true, - ai1:function(card){ - return 7-get.value(card); - }, - ai2:function(target){ - var att=get.attitude(player,target); - if(att>=0) return 0; - if(!target.countCards('he')) return -0.01; - var dist=get.distance(player,target); - if(dist>2){ - att-=2; - } - else if(dist==2){ - att--; - } - return -att; - }, - filterTarget:function(card,player,target){ - return player!=target; - } - }); - 'step 1' - if(result.bool){ - player.discard(result.cards); - var target=result.targets[0]; - player.logSkill('feitiao',target); - player.storage.feitiao2=target; - player.addTempSkill('feitiao2'); - target.randomDiscard(); - } - - } - }, - feitiao2:{ - mod:{ - globalFrom:function(from,to){ - if(to==from.storage.feitiao2) return -Infinity; - } - }, - mark:'character', - intro:{ - content:'与$的距离视为1直到回合结束' - }, - onremove:true - }, - zhencha:{ - init:function(player){ - player.storage.zhencha=true; - }, - mark:true, - intro:{ - content:function(storage,player){ - if(storage){ - return '每当你使用一张杀,你摸一张牌或回复一点体力'; - } - else if(player.hasSkill('bshaowei')&&player.storage.bshaowei){ - return '你的杀无视距离和防具、无数量限制且不可闪避;你不能闪避杀'; - } - else{ - return '无额外技能'; - } - } - }, - trigger:{player:'phaseEnd'}, - filter:function(event,player){ - if(player.hasSkill('zhencha2')) return false; - return !player.storage.zhencha; - }, - content:function(){ - player.storage.bshaowei=false; - player.storage.zhencha=true; - if(player.marks.zhencha){ - player.marks.zhencha.firstChild.innerHTML='侦'; - } - player.addTempSkill('zhencha2'); - }, - subSkill:{ - sha:{ - trigger:{player:'shaBegin'}, - direct:true, - filter:function(event,player){ - return player.storage.zhencha&&event.card&&event.card.name=='sha'; - }, - content:function(){ - player.chooseDrawRecover(get.prompt('zhencha')).logSkill='zhencha'; - } - } - }, - group:'zhencha_sha' - }, - bshaowei:{ - init:function(player){ - player.storage.bshaowei=false; - }, - trigger:{player:'phaseEnd'}, - filter:function(event,player){ - if(player.hasSkill('zhencha2')) return false; - return !player.storage.bshaowei; - }, - check:function(event,player){ - if(!player.hasShan()) return true; - if(!player.hasSha()) return false; - return Math.random()<0.5; - }, - content:function(){ - player.storage.bshaowei=true; - player.storage.zhencha=false; - if(player.marks.zhencha){ - player.marks.zhencha.firstChild.innerHTML='哨'; - } - player.addTempSkill('zhencha2'); - }, - subSkill:{ - sha:{ - mod:{ - targetInRange:function(card,player,target,now){ - if(card.name=='sha'&&player.storage.bshaowei) return true; - }, - cardUsable:function(card,player,num){ - if(card.name=='sha'&&player.storage.bshaowei) return Infinity; - } - }, - trigger:{target:'shaBegin',player:'shaBegin'}, - forced:true, - filter:function(event,player){ - return player.storage.bshaowei; - }, - check:function(){ - return false; - }, - content:function(){ - trigger.directHit=true; - }, - ai:{ - unequip:true, - skillTagFilter:function(player,tag,arg){ - if(!player.storage.bshaowei) return false; - if(arg&&arg.name=='sha') return true; - return false; - } - } - } - }, - group:'bshaowei_sha', - ai:{ - threaten:function(player,target){ - if(target.storage.bshaowei) return 1.7; - return 1; - } - } - }, - zhencha2:{}, - pingzhang:{ - trigger:{global:'damageBegin'}, - // alter:true, - intro:{ - content:function(storage,player){ - if(player.hasSkill('pingzhang2')){ - if(player.hasSkill('pingzhang3')){ - return '已对自已和其他角色发动屏障'; - } - else{ - return '已对自已发动屏障'; - } - } - else{ - return '已对其他角色发动屏障'; - } - }, - markcount:function(storage,player){ - if(player.hasSkill('pingzhang2')&&player.hasSkill('pingzhang3')){ - return 2; - } - return 1; - } - }, - filter:function(event,player){ - if(event.num<=0) return false; - var position=get.is.altered('pingzhang')?'h':'he'; - if(event.player==player){ - if(player.hasSkill('pingzhang2')) return false; - return player.countCards(position,{suit:'heart'}); - } - else{ - if(player.hasSkill('pingzhang3')) return false; - return player.countCards(position,{suit:'spade'}); - } - }, - direct:true, - content:function(){ - 'step 0' - var position=get.is.altered('pingzhang')?'h':'he'; - var suit=(player==trigger.player)?'heart':'spade'; - var next=player.chooseToDiscard(position,{suit:suit},get.prompt('pingzhang',trigger.player)); - next.ai=function(card){ - if(get.damageEffect(trigger.player,trigger.source,player)<0){ - return 8-get.value(card); - } - return 0; - } - next.logSkill=['pingzhang',trigger.player]; - 'step 1' - if(result.bool){ - trigger.num--; - if(player==trigger.player){ - player.addSkill('pingzhang2'); - } - else{ - player.addSkill('pingzhang3'); - } - player.markSkill('pingzhang'); - } - }, - group:['pingzhang_count'], - subSkill:{ - count:{ - trigger:{player:'phaseBegin'}, - silent:true, - content:function(){ - player.storage.pingzhang=0; - if(player.hasSkill('pingzhang2')){ - player.storage.pingzhang++; - player.removeSkill('pingzhang2'); - } - if(player.hasSkill('pingzhang3')){ - player.storage.pingzhang++; - player.removeSkill('pingzhang3'); - } - player.unmarkSkill('pingzhang'); - } - } - }, - ai:{ - expose:0.2, - threaten:1.5 - } - }, - pingzhang2:{}, - pingzhang3:{}, - liyong:{ - trigger:{player:'phaseDrawBegin'}, - forced:true, - filter:function(event,player){ - return player.storage.pingzhang>0; - }, - content:function(){ - trigger.num+=player.storage.pingzhang; - } - }, - liangou:{ - enable:'phaseUse', - usable:1, - filterTarget:function(card,player,target){ - return target!=player; - }, - filterCard:true, - position:'he', - check:function(card){ - return 5-get.value(card); - }, - content:function(){ - 'step 0' - player.judge(function(card){ - return get.suit(card)!='heart'?1:-1; - }); - 'step 1' - if(result.bool){ - target.addTempSkill('liangou2'); - target.storage.liangou2=player; - } - }, - ai:{ - order:10, - expose:0.2, - result:{ - target:function(player,target){ - if(get.damageEffect(target,player,target)<0&&player.hasCard(function(card){ - return get.tag(card,'damage')?true:false; - })){ - return -1; - } - return 0; - } - } - } - }, - liangou2:{ - mod:{ - // cardEnabled:function(card,player){ - // return false; - // }, - // cardUsable:function(card,player){ - // return false; - // }, - // cardRespondable:function(card,player){ - // return false; - // }, - // cardSavable:function(card,player){ - // return false; - // }, - globalTo:function(from,to){ - if(from==to.storage.liangou2) return -Infinity; - } - }, - onremove:true, - trigger:{player:'damageBegin'}, - usable:1, - forced:true, - popup:false, - content:function(){ - trigger.num++; - }, - // ai:{ - // effect:{ - // target:function(card,player,target){ - // if(get.tag(card,'damage')) return [1,-2]; - // if(get.tag(card,'respond')) return [1,-1]; - // } - // } - // } - }, - xiyang:{ - trigger:{player:'phaseEnd'}, - filter:function(event,player){ - return !player.isTurnedOver()&&player.isDamaged(); - }, - check:function(event,player){ - return player.hp<=1; - }, - content:function(){ - 'step 0' - player.turnOver(); - 'step 1' - player.recover(2); - } - }, - qinru:{ - trigger:{player:'useCardToBegin'}, - filter:function(event,player){ - return event.card.name=='sha'&&event.target!=player&&event.target&&!event.target.hasSkill('fengyin'); - }, - logTarget:'target', - check:function(event,player){ - return get.attitude(player,event.target)<0; - }, - intro:{ - content:'players', - mark:function(dialog,storage,player){ - var one=[],two=[],three=[]; - for(var i=0;i1){ - player.storage.qinru_turn[i]--; - } - else{ - player.storage.qinru.splice(i,1); - player.storage.qinru_turn.splice(i,1); - i--; - } - } - if(!player.storage.qinru.length){ - player.unmarkSkill('qinru'); - } - else{ - player.updateMarks(); - } - } - } - }, - group:['qinru_count','qinru_die'] - }, - yinshen:{ - trigger:{player:'loseEnd'}, - forced:true, - filter:function(event,player){ - if(player.countCards('h',{type:'basic'})) return false; - for(var i=0;i0; - }, - content:function(){ - "step 0" - var next=player.chooseToDiscard(get.prompt('yinshen'),'he',{type:'equip'}); - next.logSkill='yinshen'; - next.ai=function(card){ - if(player.hp==1) return 8-get.value(card); - if(player.isZhu) return 7-get.value(card); - if(player.hp==2) return 6-get.value(card); - return 5-get.value(card); - }; - "step 1" - if(result.bool){ - player.tempHide(); - } - }, - }, - maichong:{ - trigger:{player:'useCard'}, - forced:true, - filter:function(event,player){ - if(!player.hasSkill('qinru')||!player.storage.qinru||!player.storage.qinru.length) return false; - if(get.type(event.card)=='trick'&&event.cards[0]&&event.cards[0]==event.card){ - for(var i=0;i0; - }, - filterTarget:function(card,player,target){ - return !target.hujia; - }, - filterCard:true, - position:'he', - check:function(card){ - var player=_status.event.player; - if(game.hasPlayer(function(current){ - return current.hp==1&&get.attitude(player,current)>2; - })){ - return 7-get.value(card); - } - return 5-get.value(card); - }, - content:function(){ - player.changeHujia(-1); - target.changeHujia(); - }, - ai:{ - order:5, - expose:0.2, - result:{ - target:function(player,target){ - return 1/Math.max(1,target.hp); - } - } - } - }, - maoding:{ - trigger:{player:'damageEnd',source:'damageEnd'}, - frequent:true, - filter:function(event,player){ - if(get.is.altered('maoding')&&event.source!=player) return false; - return true; - }, - // alter:true, - content:function(){ - var list=get.typeCard('hslingjian'); - if(!list.length){ - return; - } - player.gain(game.createCard(list.randomGet()),'gain2'); - }, - group:'maoding2', - ai:{ - threaten:1.5, - maixie_defend:true - } - }, - maoding2:{ - enable:'phaseUse', - filter:function(event,player){ - return player.countCards('h',{type:'hslingjian'})>1; - }, - filterCard:{type:'hslingjian'}, - filterTarget:function(card,player,target){ - return !target.hujia; - }, - selectCard:2, - // usable:1, - content:function(){ - target.changeHujia(); - }, - ai:{ - order:9, - result:{ - target:function(player,target){ - return 2/Math.max(1,Math.sqrt(target.hp)); - }, - }, - } - }, - paotai:{ - enable:'phaseUse', - intro:{ - content:function(storage){ - var num; - switch(storage){ - case 1:num=30;break; - case 2:num=60;break; - case 3:num=100;break; - } - return '结束阶段,有'+num+'%机率对一名随机敌人造成一点火焰伤害'; - } - }, - init:function(player){ - player.storage.paotai=0; - }, - filter:function(event,player){ - return player.countCards('h','sha')>0&&player.storage.paotai<3; - }, - filterCard:{name:'sha'}, - content:function(){ - player.storage.paotai++; - player.markSkill('paotai'); - }, - ai:{ - order:5, - threaten:1.5, - result:{ - player:1 - } - }, - group:['paotai2','paotai3'] - }, - paotai2:{ - trigger:{player:'phaseEnd'}, - forced:true, - filter:function(event,player){ - var num=0; - switch(player.storage.paotai){ - case 1:num=30;break; - case 2:num=60;break; - case 3:num=100;break; - } - return 100*Math.random()0&&event.num>0; - }, - content:function(){ - player.storage.paotai-=trigger.num; - if(player.storage.paotai<=0){ - player.storage.paotai=0; - player.unmarkSkill('paotai'); - } - else{ - player.updateMarks(); - } - } - }, - bfengshi:{ - trigger:{player:'shaBegin'}, - forced:true, - // alter:true, - check:function(event,player){ - return get.attitude(player,event.target)<=0; - }, - filter:function(event,player){ - if(player.hasSkill('bfengshi4')) return false; - var num=0.2; - if(get.is.altered('bfengshi')) num=0.15; - return Math.random()0; - }, - check:function(card){ - return 7-get.value(card); - }, - content:function(){ - 'step 0' - var targets=player.getEnemies(function(target){ - return target.countCards('he')>0; - }); - if(targets.length){ - event.targets=targets.randomGets(3); - event.targets.sort(lib.sort.seat); - player.line(event.targets,'green'); - } - 'step 1' - if(event.targets.length){ - var target=event.targets.shift(); - var he=target.getCards('he'); - if(he.length){ - target.addExpose(0.1); - target.discard(he.randomGet()); - } - event.redo(); - } - }, - ai:{ - order:10, - expose:0.3, - result:{ - player:1 - } - } - }, - aqianghua:{ - enable:'phaseUse', - usable:1, - // alter:true, - filter:function(event,player){ - return player.countCards('h')>=1; - }, - filterTarget:function(card,player,target){ - return target!=player; - }, - filterCard:true, - selectCard:-1, - discard:false, - prepare:'give', - content:function(){ - target.gain(cards); - if(!get.is.altered('aqianghua')) target.changeHujia(); - target.addSkill('aqianghua2'); - }, - ai:{ - threaten:1.5, - order:2.1, - result:{ - target:function(player,target){ - if(target.hasSkillTag('nogain')) return 0; - if(get.attitude(player,target)<3) return 0; - if(target.hasJudge('lebu')) return 0; - if(target.hasSkill('aqianghua2')) return 0.1; - return 1; - } - } - } - }, - aqianghua2:{ - trigger:{source:'damageBegin'}, - forced:true, - content:function(){ - trigger.num++; - player.unmarkSkill('aqianghua2'); - player.removeSkill('aqianghua2'); - }, - mark:true, - intro:{ - content:'下一次造成的伤害+1' - } - }, - shihuo:{ - trigger:{global:'damageEnd'}, - forced:true, - filter:function(event){ - return event.nature=='fire'; - }, - content:function(){ - player.draw(); - } - }, - shoujia:{ - enable:'phaseUse', - usable:1, - filter:function(event,player){ - return player.countCards('h')>0; - }, - filterCard:true, - check:function(card){ - return 6-get.value(card); - }, - discard:false, - prepare:'give2', - filterTarget:function(card,player,target){ - return target!=player&&!target.hasSkill('shoujia2'); - }, - content:function(){ - target.storage.shoujia=cards[0]; - target.storage.shoujia2=player; - target.addSkill('shoujia2'); - target.syncStorage('shoujia'); - }, - ai:{ - order:1, - expose:0.2, - threaten:1.4, - result:{ - target:-1 - } - } - }, - shoujia2:{ - mark:true, - trigger:{player:'useCardToBegin'}, - forced:true, - filter:function(event,player){ - return get.suit(event.card)==get.suit(player.storage.shoujia)&&event.target&&event.target!=player; - }, - content:function(){ - 'step 0' - player.showCards([player.storage.shoujia],get.translation(player)+'发动了【兽夹】'); - 'step 1' - player.storage.shoujia.discard(); - delete player.storage.shoujia; - delete player.storage.shoujia2; - player.removeSkill('shoujia2'); - game.addVideo('storage',player,['shoujia',null]); - game.addVideo('storage',player,['shoujia2',null]); - player.turnOver(true); - }, - intro:{ - mark:function(dialog,content,player){ - if(player.storage.shoujia2&&player.storage.shoujia2.isUnderControl(true)){ - dialog.add([player.storage.shoujia]); - } - else{ - return '已成为'+get.translation(player.storage.shoujia2)+'的兽夹目标'; - } - }, - content:function(content,player){ - if(player.storage.shoujia2&&player.storage.shoujia2.isUnderControl(true)){ - return get.translation(player.storage.shoujia); - } - return '已成为'+get.translation(player.storage.shoujia2)+'的兽夹目标'; - } - }, - group:'shoujia3' - }, - shoujia3:{ - trigger:{global:'damageEnd'}, - forced:true, - filter:function(event,player){ - return event.player==player.storage.shoujia2; - }, - content:function(){ - player.storage.shoujia.discard(); - player.$throw(player.storage.shoujia); - game.log(player.storage.shoujia,'被置入弃牌堆') - delete player.storage.shoujia; - delete player.storage.shoujia2; - player.removeSkill('shoujia2'); - game.addVideo('storage',player,['shoujia',null]); - game.addVideo('storage',player,['shoujia2',null]); - } - }, - liudan:{ - trigger:{player:'useCard'}, - check:function(event,player){ - return game.countPlayer(function(current){ - if(event.targets.contains(current)==false&¤t!=player&& - lib.filter.targetEnabled(event.card,player,current)){ - return get.effect(current,event.card,player,player); - } - })>=0; - }, - filter:function(event,player){ - if(event.card.name!='sha') return false; - return game.hasPlayer(function(current){ - return (event.targets.contains(current)==false&¤t!=player&& - lib.filter.targetEnabled(event.card,player,current)); - }); - }, - content:function(){ - var list=game.filterPlayer(function(current){ - return (trigger.targets.contains(current)==false&¤t!=player&& - lib.filter.targetEnabled(trigger.card,player,current)); - }); - if(list.length){ - var list2=[]; - for(var i=0;iplayer.countCards('h')&&!player.skipList.contains('phaseUse')&&!player.skipList.contains('phaseDiscard'); - }, - check:function(event,player){ - var nh=player.countCards('h'); - if(Math.min(5,player.hp)-nh>=2) return true; - return false; - }, - content:function(){ - var num=Math.min(5,player.hp)-player.countCards('h'); - var cards=[]; - while(num--){ - cards.push(game.createCard('sha')); - } - player.gain(cards,'gain2'); - player.skip('phaseUse'); - player.skip('phaseDiscard'); - } - }, - shanguang:{ - enable:'phaseUse', - usable:1, - filterCard:{suit:'diamond'}, - position:'he', - filter:function(event,player){ - return player.countCards('he',{suit:'diamond'})>0; - }, - filterTarget:function(card,player,target){ - return target!=player&&get.distance(player,target,'attack')<=1; - }, - check:function(card){ - if(card.name=='sha'&&_status.event.player.countCards('h','sha')<3) return 0; - return 6-get.value(card); - }, - content:function(){ - target.addTempSkill('shanguang2'); - }, - ai:{ - order:7.9, - result:{ - target:function(player,target){ - var nh=target.countCards('h'); - if(get.attitude(player,target)<0&&nh>=3&& - player.canUse('sha',target)&&player.countCards('h','sha')&& - get.effect(target,{name:'sha'},player,player)>0){ - return -nh-5; - } - return -nh; - } - } - } - }, - shanguang2:{ - mod:{ - cardEnabled:function(){ - return false; - }, - cardUsable:function(){ - return false; - }, - cardRespondable:function(){ - return false; - }, - cardSavable:function(){ - return false; - } - }, - ai:{ - effect:{ - target:function(card,player,target,current){ - if(get.tag(card,'respondShan')||get.tag(card,'respondSha')){ - if(current<0) return 1.5; - } - } - } - } - }, - baoxue:{ - enable:'phaseUse', - init:function(player){ - player.storage.baoxue=false; - }, - intro:{ - content:'limited' - }, - mark:true, - unique:true, - skillAnimation:true, - animationColor:'water', - line:'thunder', - filter:function(event,player){ - return !player.storage.baoxue&&player.countCards('he',{color:'black'})>0; - }, - filterTarget:function(card,player,target){ - return target!=player; - }, - selectTarget:function(){ - return [1,_status.event.player.countCards('he',{color:'black'})]; - }, - // alter:true, - delay:false, - contentBefore:function(){ - 'step 0' - game.delayx(); - 'step 1' - player.storage.baoxue=true; - player.awakenSkill('baoxue'); - player.showHandcards(); - player.discard(player.getCards('he',{color:'black'})); - }, - content:function(){ - 'step 0' - if(!get.is.altered('baoxue')){ - var he=target.getCards('he'); - if(he.length){ - target.discard(he.randomGet()); - } - } - 'step 1' - target.turnOver(true); - }, - contentAfter:function(){ - player.turnOver(true); - }, - ai:{ - order:function(skill,player){ - var num=game.countPlayer(function(current){ - return get.attitude(player,current)<0; - }); - var nh=player.countCards('he',{color:'black'}); - if(nh==1&&num>1) return 0; - if(nh>num) return 1; - return 11; - }, - result:{ - target:function(player,target){ - if(target.hasSkillTag('noturn')) return 0; - if(player.hasUnknown()) return 0; - return -1; - } - } - } - }, - mianzhen:{ - enable:'phaseUse', - usable:1, - filter:function(event,player){ - return player.countCards('he')>0; - }, - filterTarget:function(card,player,target){ - return target!=player&&!target.hasSkill('mianzhen2'); - }, - filterCard:true, - position:'he', - check:function(card){ - return 8-get.value(card); - }, - content:function(){ - 'step 0' - target.chooseToRespond({name:'shan'}); - 'step 1' - if(!result.bool) target.addSkill('mianzhen2'); - }, - ai:{ - order:2.2, - result:{ - target:function(player,target){ - return Math.min(-0.1,-1-target.countCards('h')+Math.sqrt(target.hp)/2); - } - } - } - }, - mianzhen2:{ - mark:true, - intro:{ - content:'不能使用或打出手牌直到受到伤害或下一回合结束' - }, - trigger:{player:['damageEnd','phaseEnd']}, - forced:true, - popup:false, - content:function(){ - player.removeSkill('mianzhen2'); - }, - mod:{ - cardEnabled:function(){ - return false; - }, - cardUsable:function(){ - return false; - }, - cardRespondable:function(){ - return false; - }, - cardSavable:function(){ - return false; - } - }, - ai:{ - threaten:0.6 - } - }, - zhiyuan:{ - trigger:{source:'damageBefore'}, - check:function(event,player){ - player.disableSkill('tmp','zhiyuan'); - var eff=get.damageEffect(event.player,player,player); - var att=get.attitude(player,event.player); - var bool=false; - if(att>0){ - if(eff<=0||event.player.hp0; - }, - content:function(){ - trigger.cancel(); - trigger.player.recover(trigger.num); - }, - ai:{ - effect:{ - player:function(card,player,target){ - if(get.tag(card,'damage')&&get.attitude(player,target)>0){ - if(target.hp==target.maxHp||get.recoverEffect(target,player,player)<=0) return 'zeroplayertarget'; - return [0,0,0,1]; - } - } - } - } - }, - duwen:{ - trigger:{source:'damageBegin'}, - check:function(event,player){ - return get.attitude(player,event.player)<=0; - }, - forced:true, - filter:function(event,player){ - return player.countCards('h')==event.player.countCards('h')&&event.notLink(); - }, - content:function(){ - trigger.num++; - }, - ai:{ - threaten:1.5 - }, - }, - duwen2:{ - trigger:{source:'damageEnd'}, - forced:true, - filter:function(event,player){ - return event.card&&event.card.name=='sha'&&player.hp==event.player.hp&&event.notLink(); - }, - content:function(){ - player.draw(2); - } - }, - juji:{ - enable:'phaseUse', - usable:1, - position:'he', - filter:function(event,player){ - return player.countCards('he')>0; - }, - filterCard:function(card){ - var suit=get.suit(card); - for(var i=0;i0; - }, - check:function(card){ - if(ui.selected.cards.length>1) return 0; - return 5-get.value(card); - }, - selectCard:[1,4], - content:function(){ - var suits=[]; - for(var i=0;inum){ - min.length=0; - min.push(players[i]); - num=eff; - } - } - } - for(var i=0;i0) return 0; - if(min[i].countCards('h')<=1&&get.distance(player,min[i],'attack')<=1) return 0; - } - if(min.contains(target)) return -1; - return 0; - } - } - }, - }, - juji2:{ - ai:{ - effect:{ - player:function(card,player,target){ - if(card.name=='sha'&&target==player.storage.juji2) return [1,0,1,-1]; - } - } - }, - trigger:{player:'phaseAfter'}, - forced:true, - popup:false, - content:function(){ - player.unmarkSkill('juji2'); - player.removeSkill('juji2'); - delete player.storage.juji2; - }, - group:'juji3' - }, - juji3:{ - trigger:{player:'shaBegin'}, - forced:true, - filter:function(event,player){ - return event.target==player.storage.juji2; - }, - content:function(){ - trigger.directHit=true; - }, - mod:{ - globalFrom:function(from,to){ - if(to==from.storage.juji2) return -Infinity; - } - } - }, - dulei:{ - enable:'phaseUse', - filter:function(event,player){ - return !player.hasSkill('dulei2'); - }, - filterCard:true, - check:function(card){ - return 6-get.value(card); - }, - discard:false, - prepare:function(cards,player){ - player.$give(1,player,false); - }, - content:function(){ - player.storage.dulei=cards[0]; - player.addSkill('dulei2'); - player.syncStorage('dulei'); - }, - ai:{ - order:1, - result:{ - player:1 - } - } - }, - dulei2:{ - mark:true, - trigger:{target:'useCardToBegin'}, - forced:true, - filter:function(event,player){ - return event.player!=player&&get.suit(event.card)==get.suit(player.storage.dulei); - }, - content:function(){ - 'step 0' - player.showCards([player.storage.dulei],get.translation(player)+'发动了【诡雷】'); - 'step 1' - player.storage.dulei.discard(); - delete player.storage.dulei; - player.removeSkill('dulei2'); - game.addVideo('storage',player,['dulei',null]); - trigger.player.loseHp(); - 'step 2' - var he=trigger.player.getCards('he'); - if(he.length){ - trigger.player.discard(he.randomGet()); - } - }, - intro:{ - mark:function(dialog,content,player){ - if(player==game.me||player.isUnderControl()){ - dialog.add([player.storage.dulei]); - } - else{ - return '已发动诡雷'; - } - }, - content:function(content,player){ - if(player==game.me||player.isUnderControl()){ - return get.translation(player.storage.dulei); - } - return '已发动诡雷'; - } - } - }, - juji_old:{ - trigger:{player:'shaBegin'}, - forced:true, - filter:function(event,player){ - return get.distance(event.target,player,'attack')>1; - }, - content:function(){ - trigger.directHit=true; - }, - group:'juji2' - }, - juji2_old:{ - enable:'phaseUse', - usable:1, - filterTarget:function(card,player,target){ - return target!=player; - }, - content:function(){ - target.addTempSkill('juji3',{player:'phaseEnd'}); - if(!target.storage.juji3){ - target.storage.juji3=[]; - } - target.storage.juji3.push(player); - }, - mod:{ - targetInRange:function(card,player,target){ - if(target.hasSkill('juji3')&&Array.isArray(target.storage.juji3)&&target.storage.juji3.contains(player)){ - return true; - } - } - } - }, - juji3_old:{ - mark:true, - intro:{ - nocount:true, - content:function(storage){ - return '对'+get.translation(storage)+'使用卡牌无视距离'; - } - }, - mod:{ - targetInRange:function(card,player,target){ - if(Array.isArray(player.storage.juji3)&&player.storage.juji3.contains(target)){ - return true; - } - } - } - }, - zhuagou:{ - enable:'phaseUse', - usable:1, - changeSeat:true, - filterTarget:function(card,player,target){ - return player!=target&&player.next!=target; - }, - filterCard:true, - check:function(card){ - return 4-get.value(card); - }, - content:function(){ - while(player.next!=target){ - game.swapSeat(player,player.next); - } - }, - ai:{ - order:5, - result:{ - player:function(player,target){ - var att=get.attitude(player,target); - if(target==player.previous&&att>0) return 1; - if(target==player.next.next&&get.attitude(player,player.next)<0) return 1; - return 0; - } - } - } - }, - bingqiang:{ - enable:'phaseUse', - position:'he', - filterCard:function(card){ - var color=get.color(card); - for(var i=0;imax){ - max=num; - } - if(num-min){ - if(get.color(card)=='red') return 5-get.value(card); - } - else{ - if(get.color(card)=='black') return 5-get.value(card); - } - return 0; - }, - changeTarget:function(player,targets){ - var target=targets[0]; - var add=game.filterPlayer(function(player){ - return get.distance(target,player,'pure')==1; - }); - for(var i=0;i0; - }, - content:function(){ - for(var i=0;i0; - }, - content:function(){ - 'step 0' - var goon=false; - var goon2=false; - var att=get.attitude(player,trigger.player); - if(att>0){ - if(trigger.player.hp==1) goon=true; - } - else{ - if(Math.random()<0.5) goon=true; - } - if(Math.random()<0.3) goon2=true; - player.chooseToDiscard([1,player.countCards('h')],'he',get.prompt('bingqiang',trigger.player)).set('logSkill',['bingqiang',trigger.player]).ai=function(card){ - if(ui.selected.cards.length) return 0; - if(goon) return 6-get.value(card); - if(goon2) return 4-get.value(card); - return 0; - } - 'step 1' - if(result.bool){ - var num=result.cards.length; - event.num=num; - player.chooseControl('选项一','选项二','选项三','选项四',function(){ - if(get.attitude(player,trigger.player)>0){ - if(Math.random()<0.7) return '选项一'; - return '选项三'; - } - else{ - if(Math.random()<0.7) return '选项四'; - return '选项二'; - } - }).set('prompt','冰墙

选项一:防御距离+'+num+ - '

选项二:防御距离-'+num+ - '

选项三:进攻距离+'+num+ - '

选项四:进攻距离-'+num+'
'); - } - else{ - event.finish(); - } - 'step 2' - switch(result.control){ - case '选项一':{ - trigger.player.storage.bingqiang2=event.num; - trigger.player.addTempSkill('bingqiang2',{player:'phaseBegin'}); - break; - } - case '选项二':{ - trigger.player.storage.bingqiang3=event.num; - trigger.player.addTempSkill('bingqiang3',{player:'phaseBegin'}); - break; - } - case '选项三':{ - trigger.player.storage.bingqiang4=event.num; - trigger.player.addTempSkill('bingqiang4',{player:'phaseBegin'}); - break; - } - case '选项四':{ - trigger.player.storage.bingqiang5=event.num; - trigger.player.addTempSkill('bingqiang5',{player:'phaseBegin'}); - break; - } - } - }, - ai:{ - expose:0.1 - } - }, - bingqiang2:{ - mark:true, - intro:{ - content:'防御距离+#' - }, - mod:{ - globalTo:function(from,to,distance){ - if(typeof to.storage.bingqiang2=='number') return distance+to.storage.bingqiang2; - }, - } - }, - bingqiang3:{ - mark:true, - intro:{ - content:'防御距离-#' - }, - mod:{ - globalTo:function(from,to,distance){ - if(typeof to.storage.bingqiang3=='number') return distance-to.storage.bingqiang3; - }, - } - }, - bingqiang4:{ - mark:true, - intro:{ - content:'进攻距离+#' - }, - mod:{ - globalFrom:function(from,to,distance){ - if(typeof from.storage.bingqiang4=='number') return distance-from.storage.bingqiang4; - } - } - }, - bingqiang5:{ - mark:true, - intro:{ - content:'进攻距离-#' - }, - mod:{ - globalFrom:function(from,to,distance){ - if(typeof from.storage.bingqiang5=='number') return distance+from.storage.bingqiang5; - } - } - }, - shuangqiang:{ - trigger:{source:'damageBegin'}, - check:function(event,player){ - var att=get.attitude(player,event.player); - if(event.player.hp==1) return att>0; - return att<=0; - }, - logTarget:'player', - filter:function(event,player){ - return !event.player.isTurnedOver()&&event.num>0; - }, - content:function(){ - trigger.num--; - trigger.player.draw(); - trigger.player.turnOver(); - } - }, - jidong:{ - trigger:{global:'phaseEnd'}, - filter:function(event,player){ - return player.hp==1&&!player.isTurnedOver(); - }, - // alter:true, - content:function(){ - 'step 0' - player.turnOver(); - player.recover(2); - 'step 1' - if(player.isTurnedOver()&&!get.is.altered('jidong')){ - player.addTempSkill('jidong2',{player:'turnOverAfter'}); - } - }, - ai:{ - threaten:function(player,target){ - if(target.hp==1) return 2; - return 1; - } - } - }, - jidong2:{ - trigger:{player:'damageBefore'}, - forced:true, - content:function(){ - trigger.cancel(); - }, - ai:{ - nofire:true, - nothunder:true, - nodamage:true, - effect:{ - target:function(card,player,target,current){ - if(get.tag(card,'damage')) return [0,0]; - } - }, - }, - mod:{ - targetEnabled:function(card,player,target){ - if(player!=target) return false; - } - } - }, - chongzhuang:{ - trigger:{source:'damageEnd'}, - forced:true, - filter:function(event,player){ - return player.storage.jijia<=0&&event.num>0; - }, - popup:false, - unique:true, - content:function(){ - player.storage.jijia2+=trigger.num; - if(player.storage.jijia2>=4){ - player.storage.jijia=4; - player.storage.jijia2=0; - player.markSkill('jijia'); - if(lib.config.skill_animation_type!='off'){ - player.logSkill('chongzhuang'); - player.$skill('重装') - } - } - } - }, - tuijin:{ - enable:'phaseUse', - usable:1, - unique:true, - filter:function(event,player){ - if(player.storage.jijia>0){ - return game.hasPlayer(function(current){ - return get.distance(player,current)>1 - }); - } - return false; - }, - filterTarget:function(card,player,target){ - return target!=player&&get.distance(player,target)>1; - }, - content:function(){ - player.storage.tuijin2=target; - player.addTempSkill('tuijin2'); - }, - ai:{ - order:11, - result:{ - target:function(player,target){ - if(get.attitude(player,target)<0){ - if(get.distance(player,target)>2) return -1.5; - return -1; - } - return 0.3; - } - } - } - }, - tuijin2:{ - mod:{ - globalFrom:function(from,to){ - if(to==from.storage.tuijin2) return -Infinity; - } - }, - mark:'character', - intro:{ - content:'与$的距离视为1直到回合结束' - }, - onremove:true - }, - jijia:{ - mark:true, - unique:true, - init:function(player){ - player.storage.jijia=4; - player.storage.jijia2=0; - }, - intro:{ - content:'机甲体力值:#' - }, - mod:{ - maxHandcard:function(player,num){ - if(player.storage.jijia>0){ - return num+player.storage.jijia; - } - } - }, - trigger:{player:'changeHp'}, - forced:true, - popup:false, - filter:function(event,player){ - return player.storage.jijia>0&&event.parent.name=='damage'&&event.num<0; - }, - content:function(){ - player.hp-=trigger.num; - player.update(); - player.storage.jijia+=trigger.num; - if(player.storage.jijia<=0){ - player.unmarkSkill('jijia'); - } - else{ - player.updateMarks(); - } - }, - ai:{ - threaten:function(player,target){ - if(target.storage.jijia<=0) return 2; - return 1; - } - } - }, - zihui:{ - enable:'phaseUse', - filter:function(event,player){ - return player.storage.jijia>0; - }, - filterTarget:function(card,player,target){ - return target!=player&&get.distance(player,target)<=2; - }, - unique:true, - selectTarget:-1, - skillAnimation:true, - animationColor:'fire', - line:'fire', - // alter:true, - content:function(){ - 'step 0' - var num=player.storage.jijia; - if(get.is.altered('zihui')){ - num=Math.max(1,Math.min(num,target.countCards('he'))); - } - target.chooseToDiscard(num,'he','弃置'+get.cnNumber(num)+'张牌,或受到2点火焰伤害').ai=function(card){ - if(target.hasSkillTag('nofire')) return 0; - if(get.type(card)!='basic') return 11-get.value(card); - if(target.hp>4) return 7-get.value(card); - if(target.hp==4&&num>=3) return 7-get.value(card); - if(target.hp==3&&num>=4) return 7-get.value(card); - if(num>1) return 8-get.value(card); - return 10-get.value(card); - }; - 'step 1' - if(!result.bool){ - target.damage(2,'fire'); - } - if(target==targets[targets.length-1]){ - player.storage.jijia=0; - player.unmarkSkill('jijia'); - } - }, - ai:{ - order:2, - result:{ - player:function(player){ - var num=0; - var players=game.filterPlayer(); - for(var i=0;i2) continue; - var nh=players[i].countCards('h'); - var att=get.attitude(player,players[i]); - if(nh0){ - if(players[i].hp<=2){ - num-=2; - } - else{ - num-=1.5; - } - } - } - else if(nh==player.storage.jijia){ - if(att<0){ - num+=0.5; - } - else if(att>0){ - num-=0.5; - } - } - } - if(num>=2) return 1; - return 0; - } - } - } - }, - xiandan:{ - trigger:{player:'shaBegin'}, - direct:true, - content:function(){ - "step 0" - var dis=trigger.target.countCards('h','shan')||trigger.target.getEquip('bagua')||trigger.target.countCards('h')>2; - var att=get.attitude(player,trigger.target); - var next=player.chooseToDiscard(get.prompt('xiandan')); - next.ai=function(card){ - if(att) return 0; - if(dis) return 7-get.value(card); - return 0; - } - next.logSkill='xiandan'; - "step 1" - if(result.bool){ - if(get.color(result.cards[0])=='red'){ - trigger.directHit=true; - } - else{ - player.addTempSkill('xiandan2','shaAfter'); - } - } - } - }, - xiandan2:{ - trigger:{source:'damageBegin'}, - filter:function(event){ - return event.card&&event.card.name=='sha'&&event.notLink(); - }, - forced:true, - popup:false, - content:function(){ - trigger.num++; - } - }, - shouge:{ - trigger:{source:'dieAfter'}, - frequent:true, - content:function(){ - player.gain(game.createCard('zhiliaobo'),'gain2'); - } - }, - tuji:{ - mod:{ - globalFrom:function(from,to,distance){ - if(_status.currentPhase==from){ - return distance-from.countUsed(); - } - }, - }, - }, - mujing:{ - enable:['chooseToRespond','chooseToUse'], - filterCard:function(card){ - return get.color(card)=='black'; - }, - position:'he', - viewAs:{name:'sha'}, - viewAsFilter:function(player){ - if(!player.countCards('he',{color:'black'})) return false; - }, - prompt:'将一张黑色牌当杀使用或打出', - check:function(card){return 4-get.value(card)}, - ai:{ - skillTagFilter:function(player){ - if(!player.countCards('he',{color:'black'})) return false; - }, - respondSha:true, - }, - group:'mujing2' - }, - mujing2:{ - trigger:{player:'shaMiss'}, - forced:true, - popup:false, - filter:function(event){ - return !event.parent._mujinged; - }, - content:function(){ - trigger.parent._mujinged=true; - player.getStat().card.sha--; - } - }, - lichang:{ - trigger:{player:'phaseEnd'}, - direct:true, - filter:function(event,player){ - return player.countCards('he',{color:'red'})>0; - }, - content:function(){ - "step 0" - var next=player.chooseToDiscard(get.prompt('lichang'),'he',{color:'red'}); - next.logSkill='lichang'; - next.ai=function(card){ - return 6-get.value(card); - }; - "step 1" - if(result.bool){ - player.addSkill('lichang2'); - } - }, - }, - lichang2:{ - trigger:{player:'phaseBegin'}, - direct:true, - mark:true, - intro:{ - content:'下个准备阶段令一名距离1以内的角色回复一点体力或摸两张牌' - }, - content:function(){ - 'step 0' - player.chooseTarget(get.prompt('lichang'),function(card,player,target){ - return get.distance(player,target)<=1; - }).ai=function(target){ - var att=get.attitude(player,target); - if(att>0){ - if(target.hp==1&&target.maxHp>1) return att*2; - } - return att; - }; - player.removeSkill('lichang2'); - 'step 1' - if(result.bool){ - player.logSkill('lichang',result.targets); - result.targets[0].chooseDrawRecover(2,true); - } - } - }, - mujing_old:{ - trigger:{player:'useCardToBegin'}, - filter:function(event,player){ - return event.target&&event.target!=player&&get.distance(event.target,player,'attack')>1; - }, - direct:true, - content:function(){ - 'step 0' - player.discardPlayerCard(get.prompt('mujing'),trigger.target).logSkill=['mujing']; - 'step 1' - if(result.bool&&player.countCards('h')<=trigger.target.countCards('h')){ - player.draw(); - } - } - }, - zhanlong:{ - trigger:{player:'phaseBegin'}, - unique:true, - mark:true, - skillAnimation:true, - init:function(player){ - player.storage.zhanlong=false; - }, - check:function(event,player){ - if(player.hasJudge('lebu')) return false; - return true; - }, - filter:function(event,player){ - if(player.storage.zhanlong) return false; - if(player.countCards('he')==0) return false; - if(player.hp!=1) return false; - return true; - }, - content:function(){ - 'step 0' - player.discard(player.getCards('he')); - 'step 1' - player.addTempSkill('zhanlong2'); - player.awakenSkill('zhanlong'); - player.storage.zhanlong=true; - var cards=[]; - for(var i=0;i<3;i++){ - cards.push(game.createCard('sha')); - } - player.gain(cards,'gain2'); - }, - ai:{ - threaten:function(player,target){ - if(target.hp==1) return 3; - return 1; - }, - effect:{ - target:function(card,player,target){ - if(!target.hasFriend()) return; - if(get.tag(card,'damage')==1&&target.hp==2&&target.countCards('he')&& - !target.isTurnedOver()&&_status.currentPhase!=target){ - if(get.distance(_status.currentPhase,target,'absolute')<=2) return [0.5,1]; - return 0.8; - } - } - } - }, - intro:{ - content:'limited' - } - }, - zhanlong2:{ - mod:{ - cardUsable:function(card){ - if(card.name=='sha') return Infinity; - } - } - }, - feiren:{ - trigger:{source:'damageBegin'}, - forced:true, - // alter:true, - filter:function(event,player){ - return !get.is.altered('feiren')&&event.card&&event.card.name=='sha'&&get.suit(event.card)=='spade'&&event.notLink(); - }, - content:function(){ - trigger.num++; - }, - mod:{ - targetInRange:function(card){ - if(card.name=='sha') return true; - }, - selectTarget:function(card,player,range){ - if(card.name=='sha'&&range[1]!=-1&&get.suit(card)=='club'){ - range[1]++; - } - }, - }, - ai:{ - threaten:1.4 - } - }, - feiren3:{ - trigger:{player:'useCardAfter'}, - filter:function(event,player){ - if(event.parent.name=='feiren2') return false; - if(event.card.name!='sha') return false; - if(get.suit(event.card)!='spade') return false; - var card=game.createCard(event.card.name,event.card.suit,event.card.number,event.card.nature); - for(var i=0;i0){ - return 0; - } - return get.recoverEffect(target,player,target); - } - } - } - }, - xie2:{ - mark:true, - trigger:{global:'phaseEnd'}, - forced:true, - filter:function(event,player){ - if(player.storage.xie=='now'){ - return event.player==player; - } - var num=game.phaseNumber-player.storage.xie; - return num&&num%6==0; - }, - content:function(){ - if(player.storage.xie=='now'){ - player.storage.xie=game.phaseNumber; - } - player.recover(); - }, - intro:{ - content:function(storage,player){ - var str='每隔六回合回复一点体力,直到'+get.translation(storage)+'死亡'; - if(typeof player.storage.xie=='number'){ - var num=game.phaseNumber-player.storage.xie; - num=num%6; - if(num==0){ - str+='(下次生效于本回合)' - } - else{ - str+='(下次生效于'+(6-num)+'回合后)' - } - } - return str; - }, - onunmark:function(storage,player){ - delete player.storage.xie; - delete player.storage.xie2; - } - }, - group:['xie3','xie4'] - }, - xie3:{ - trigger:{global:'phaseBegin'}, - forced:true, - popup:false, - content:function(){ - var num=game.phaseNumber-player.storage.xie; - num=num%6; - if(num){ - num=6-num; - } - player.storage.xie2_markcount=num; - player.updateMarks(); - } - }, - xie4:{ - trigger:{global:'dieAfter'}, - forced:true, - popup:false, - filter:function(event,player){ - return event.player==player.storage.xie2; - }, - content:function(){ - game.log(player,'解除了','【谐】'); - player.removeSkill('xie2'); - } - }, - luan:{ - enable:'phaseUse', - unique:true, - filterTarget:function(card,player,target){ - return target!=player&&!target.hasSkill('luan2'); - }, - filter:function(event,player){ - return player.countCards('h',{suit:'spade'}); - }, - filterCard:{suit:'spade'}, - check:function(card){ - return 7-get.value(card); - }, - content:function(){ - var current=game.findPlayer(function(player){ - return player.hasSkill('luan2'); - }); - if(current){ - current.removeSkill('luan2'); - } - target.addSkill('luan2'); - // target.storage.luan='now'; - target.storage.luan2=player; - }, - ai:{ - expose:0.2, - order:9.1, - threaten:2, - result:{ - target:function(player,target){ - var current=game.findPlayer(function(player){ - return player.hasSkill('luan2'); - }); - if(current&&get.attitude(player,current)<0){ - return 0; - } - if(target.hp==1) return 0.5; - return -1; - } - } - } - }, - luan2:{ - mark:true, - intro:{ - content:'受到的伤害后流失一点体力,直到首次进入濒死状态' - }, - trigger:{player:'damageEnd'}, - forced:true, - content:function(){ - player.loseHp(); - }, - ai:{ - threaten:1.2 - }, - group:['luan3','luan4'] - }, - luan3:{ - trigger:{player:'dyingAfter'}, - forced:true, - popup:false, - content:function(){ - game.log(player,'解除了','【乱】'); - player.removeSkill('luan2'); - } - }, - luan2_old:{ - mark:true, - trigger:{global:'phaseEnd'}, - forced:true, - filter:function(event,player){ - if(player.storage.luan=='now'){ - return event.player==player; - } - var num=game.phaseNumber-player.storage.luan; - return num&&num%6==0; - }, - content:function(){ - if(player.storage.luan=='now'){ - player.storage.luan=game.phaseNumber; - } - player.loseHp(); - }, - intro:{ - content:function(storage,player){ - var str='每隔六回合失去一点体力,直到'+get.translation(storage)+'死亡'; - if(typeof player.storage.luan=='number'){ - var num=game.phaseNumber-player.storage.luan; - num=num%6; - if(num==0){ - str+='(下次生效于本回合)' - } - else{ - str+='(下次生效于'+(6-num)+'回合后)' - } - } - return str; - }, - onunmark:function(storage,player){ - delete player.storage.luan; - delete player.storage.luan2; - } - }, - group:['luan3','luan4'] - }, - luan3_old:{ - trigger:{global:'phaseBegin'}, - forced:true, - popup:false, - content:function(){ - var num=game.phaseNumber-player.storage.luan; - num=num%6; - if(num){ - num=6-num; - } - player.storage.luan2_markcount=num; - player.updateMarks(); - } - }, - luan4:{ - trigger:{global:'dieAfter'}, - forced:true, - popup:false, - filter:function(event,player){ - return event.player==player.storage.luan2; - }, - content:function(){ - game.log(player,'解除了','【乱】'); - player.removeSkill('luan2'); - } - }, - sheng:{ - enable:'phaseUse', - unique:true, - mark:true, - skillAnimation:true, - animationColor:'metal', - init:function(player){ - player.storage.sheng=false; - }, - filter:function(event,player){ - if(player.storage.sheng) return false; - return true; - }, - filterTarget:function(card,player,target){ - return target.isDamaged(); - }, - selectTarget:[1,Infinity], - contentBefore:function(){ - player.turnOver(); - player.addSkill('sheng2'); - player.awakenSkill('sheng'); - player.storage.sheng=true; - }, - content:function(){ - target.recover(); - }, - ai:{ - order:1, - result:{ - target:function(player,target){ - var eff=get.recoverEffect(target,player,target); - if(player.hp==1) return eff; - if(player.hasUnknown()) return 0; - var num1=0,num2=0,num3=0,players=game.filterPlayer(); - for(var i=0;i0){ - num1++; - if(players[i].isDamaged()){ - num2++; - if(players[i].hp<=1){ - num3++; - } - } - } - } - if(num1==num2) return eff; - if(num2==num1-1&&num3) return eff; - if(num3>=2) return eff; - return 0; - } - }, - }, - intro:{ - content:'limited' - } - }, - sheng2:{ - trigger:{player:'phaseBegin'}, - forced:true, - popup:false, - content:function(){ - player.removeSkill('sheng2'); - }, - mod:{ - targetEnabled:function(card,player,target){ - if(player!=target) return false; - } - } - }, - yihun:{ - trigger:{player:'phaseEnd'}, - direct:true, - filter:function(event,player){ - return player.countCards('he',{color:'black'})>0&&!player.hasSkill('yihun2'); - }, - content:function(){ - 'step 0' - var next=player.chooseCardTarget({ - prompt:get.prompt('yihun'), - position:'he', - filterCard:function(card,player){ - return get.color(card)=='black'&&lib.filter.cardDiscardable(card,player); - }, - ai1:function(card){ - return 7-get.value(card); - }, - ai2:function(target){ - var att=-get.attitude(player,target); - if(target==player.next){ - att/=10; - } - if(target==player.next.next){ - att/=2; - } - return att; - }, - filterTarget:function(card,player,target){ - return player!=target; - }, - }); - 'step 1' - if(result.bool){ - player.discard(result.cards); - player.logSkill('yihun',result.targets); - player.addSkill('yihun2'); - var target=result.targets[0] - player.storage.yihun2=target; - if(target&&(get.mode()!='guozhan')||!target.isUnseen()){ - player.markSkillCharacter('yihun2',target,'移魂','在'+get.translation(target)+'的下一准备阶段视为对其使用一张杀'); - } - } - }, - }, - yihun2:{ - trigger:{global:['phaseBegin','dieAfter']}, - forced:true, - filter:function(event,player){ - return event.player==player.storage.yihun2; - }, - content:function(){ - if(player.storage.yihun2.isIn()){ - player.useCard({name:'sha'},player.storage.yihun2); - } - player.removeSkill('yihun2'); - delete player.storage.yihun2; - }, - mod:{ - targetEnabled:function(){ - return false; - }, - cardEnabled:function(card,player){ - return false; - }, - } - }, - huoyu:{ - enable:'phaseUse', - unique:true, - mark:true, - skillAnimation:true, - animationColor:'fire', - init:function(player){ - player.storage.huoyu=false; - }, - filter:function(event,player){ - if(player.storage.huoyu) return false; - if(player.countCards('he',{color:'red'})<2) return false; - return true; - }, - filterTarget:function(card,player,target){ - return player.canUse('chiyuxi',target); - }, - filterCard:{color:'red'}, - selectCard:2, - position:'he', - check:function(card){ - return 7-get.value(card); - }, - selectTarget:-1, - multitarget:true, - multiline:true, - line:'fire', - content:function(){ - 'step 0' - targets.sort(lib.sort.seat); - player.awakenSkill('huoyu'); - player.storage.huoyu=true; - player.useCard({name:'chiyuxi'},targets).animate=false; - 'step 1' - player.useCard({name:'chiyuxi'},targets).animate=false; - }, - ai:{ - order:5, - result:{ - target:function(player,target){ - if(player.hasUnknown()) return 0; - return get.effect(target,{name:'chiyuxi'},player,target); - } - }, - }, - intro:{ - content:'limited' - } - }, - feidan:{ - trigger:{source:'damageAfter'}, - direct:true, - filter:function(event,player){ - if(player.countCards('he')==0) return false; - if(!event.card) return false; - if(event.card.name!='sha') return false; - return game.hasPlayer(function(current){ - return current!=event.player&&get.distance(event.player,current)<=1 - }); - }, - content:function(){ - "step 0" - var eff=0; - var targets=game.filterPlayer(function(current){ - if(current!=trigger.player&&get.distance(trigger.player,current)<=1){ - eff+=get.damageEffect(current,player,player); - return true; - } - }); - event.targets=targets; - player.chooseToDiscard(get.prompt('feidan',targets)).set('ai',function(card){ - if(eff>0) return 7-get.value(card); - return 0; - }).set('logSkill',['feidan',targets]); - "step 1" - if(result.bool){ - event.targets.sort(lib.sort.seat); - } - else{ - event.finish(); - } - "step 2" - if(event.targets.length){ - event.targets.shift().damage(); - event.redo(); - } - }, - mod:{ - targetInRange:function(card,player,target){ - if(card.name=='sha'){ - if(get.distance(player,target)<=1) return false; - return true; - } - } - } - }, - yuedong:{ - trigger:{player:'phaseUseEnd'}, - direct:true, - content:function(){ - 'step 0' - var num=1+player.storage.yuedong_num; - player.chooseTarget(get.prompt('yuedong'),[1,num],function(card,player,target){ - if(player.storage.yuedong_recover){ - return target.hp1) return att/5; - if(num2==1){ - if(num>1) return att/3; - return att/4; - } - return att*1.1; - } - return att; - }); - 'step 1' - if(result.bool){ - player.logSkill('yuedong',result.targets); - var eff=1+player.storage.yuedong_eff; - if(player.storage.yuedong_recover){ - result.targets.sort(lib.sort.seat); - for(var i=0;i1&&!player.storage.yuedong_recover; - }, - check:function(card){ - return 6-get.value(card); - }, - content:function(){ - player.storage.yuedong_recover=true; - }, - ai:{ - order:10.2, - result:{ - player:function(player){ - var num1=0,num2=0,players=game.filterPlayer(); - for(var i=0;i0){ - num2++; - if(players[i].hp<=2&&players[i].maxHp>2){ - num1++; - if(players[i].hp==1){ - num1++; - } - } - } - } - if(num1>=3){ - return 1; - } - return 0; - } - } - } - }, - kuoyin:{ - enable:'phaseUse', - filterCard:true, - selectCard:function(){ - if(get.is.altered('kuoyin')) return 1; - if(_status.event.player.storage.yuedong_eff) return 1; - if(_status.event.player.storage.yuedong_num) return 2; - return [1,2]; - }, - position:'he', - // alter:true, - filter:function(event,player){ - if(get.is.altered('kuoyin')&&player.storage.yuedong_num) return false; - if(player.storage.yuedong_eff&&player.storage.yuedong_num) return false; - return player.countCards('he')>0; - }, - check:function(card){ - var player=_status.event.player; - var num1=0,num2=0,players=game.filterPlayer(); - for(var i=0;i0){ - num2++; - if(players[i].hp<=2&&players[i].maxHp>2){ - num1++; - } - } - } - if(player.storage.yuedong_recover){ - if(num1>1&&!player.storage.yuedong_num){ - if(ui.selected.cards.length) return 0; - return 7-get.value(card); - } - return 0; - } - else{ - if(num2>1&&!player.storage.yuedong_num){ - if(ui.selected.cards.length) return 0; - return 7-get.value(card); - } - if(num2>2){ - return 6-get.value(card); - } - return 5-get.value(card); - } - }, - content:function(){ - if(cards.length==1){ - player.storage.yuedong_num+=2; - } - else{ - player.storage.yuedong_eff++; - } - }, - ai:{ - threaten:1.6, - order:10.1, - result:{ - player:1 - } - }, - group:'kuoyin2' - }, - kuoyin2:{ - trigger:{player:'phaseBegin'}, - silent:true, - content:function(){ - player.storage.yuedong_recover=false; - player.storage.yuedong_num=0; - player.storage.yuedong_eff=0; - } - }, - guangshu:{ - enable:'phaseUse', - check:function(card){ - var player=_status.event.player; - var suit=get.suit(card); - if(suit=='heart'){ - if(game.hasPlayer(function(current){ - return current.hp==1&&get.attitude(player,current)>0 - })); - } - else if(suit=='spade'){ - return 7-get.value(card); - } - return 6-get.value(card); - }, - filter:function(event,player){ - return player.countCards('he')>0; - }, - filterTarget:function(card,player,target){ - return !target.hasSkill('guangshu_heart')&& - !target.hasSkill('guangshu_spade')&& - !target.hasSkill('guangshu_club')&& - !target.hasSkill('guangshu_diamond'); - }, - filterCard:true, - position:'he', - content:function(){ - target.addSkill('guangshu_'+get.suit(cards[0])); - }, - ai:{ - expose:0.2, - threaten:1.6, - order:5, - result:{ - target:function(player,target){ - if(!ui.selected.cards.length) return 0; - switch(get.suit(ui.selected.cards[0])){ - case 'heart':if(target.hp==1) return 1;return 0.1; - case 'diamond':return 1+Math.sqrt(target.countCards('h')); - case 'club':return -target.countCards('h')-Math.sqrt(target.countCards('h','sha')); - case 'spade':return get.damageEffect(target,player,target,'thunder'); - default:return 0; - } - } - } - } - }, - guangshu_diamond:{ - mark:true, - intro:{ - content:'下次造成伤害时摸两张牌' - }, - trigger:{source:'damageEnd'}, - forced:true, - content:function(){ - player.draw(2); - player.removeSkill('guangshu_diamond'); - } - }, - guangshu_heart:{ - mark:true, - intro:{ - content:'下次受到伤害时回复一点体力' - }, - trigger:{player:'damageEnd'}, - priority:6, - forced:true, - content:function(){ - player.recover(); - player.removeSkill('guangshu_heart'); - } - }, - guangshu_club:{ - mark:true, - intro:{ - content:'无法使用杀直到下一回合结束' - }, - trigger:{player:'phaseEnd'}, - forced:true, - popup:false, - content:function(){ - player.removeSkill('guangshu_club'); - }, - mod:{ - cardEnabled:function(card){ - if(card.name=='sha') return false; - } - } - }, - guangshu_spade:{ - mark:true, - intro:{ - content:'下个结束阶段受到一点无来源的雷电伤害' - }, - trigger:{player:'phaseEnd'}, - forced:true, - content:function(){ - player.damage('thunder','nosource'); - player.removeSkill('guangshu_spade'); - } - }, - ziyu:{ - trigger:{global:'phaseEnd'}, - direct:true, - filter:function(event,player){ - if(get.is.altered('ziyu')) return game.phaseNumber%6==0; - return game.phaseNumber%4==0; - }, - // alter:true, - content:function(){ - player.chooseDrawRecover(get.prompt('ziyu')).logSkill='ziyu'; - } - }, - shouhu:{ - mod:{ - cardEnabled:function(card){ - if(card.name=='sha') return false; - }, - }, - enable:'phaseUse', - filter:function(event,player){ - return player.countCards('h','sha')>0; - }, - filterTarget:function(card,player,target){ - return target.hpplayer.hp&&player.countCards('h','lebu')==0)||get.distance(player,event.player)>1); - }, - // alter:true, - intro:{ - content:function(storage,player){ - var str=''; - if(player.storage.shanxian_h.length){ - if(player.isUnderControl(true)){ - str+='手牌区:'+get.translation(player.storage.shanxian_h); - } - else{ - str+='手牌区:'+(player.storage.shanxian_h.length)+'张牌'; - } - } - if(player.storage.shanxian_e.length){ - if(str.length) str+='、'; - if(player.isUnderControl(true)){ - str+='装备区:'+get.translation(player.storage.shanxian_e); - } - else{ - str+='装备区:'+(player.storage.shanxian_e.length)+'张牌'; - } - } - return str; - }, - mark:function(dialog,content,player){ - if(player.storage.shanxian_h.length){ - if(player.isUnderControl(true)){ - dialog.add('
手牌区
'); - dialog.addSmall(player.storage.shanxian_h); - } - else{ - dialog.add('
手牌区:'+player.storage.shanxian_h.length+'张牌
'); - } - } - if(player.storage.shanxian_e.length){ - if(player.isUnderControl(true)){ - dialog.add('
装备区
'); - dialog.addSmall(player.storage.shanxian_e); - } - else{ - dialog.add('
装备区:'+player.storage.shanxian_e.length+'张牌
'); - } - } - }, - }, - logTarget:'player', - content:function(){ - "step 0" - if(!get.is.altered('shanxian')){ - player.draw(false); - player.$draw(); - } - "step 1" - player.storage.shanxian_h=player.getCards('h'); - player.storage.shanxian_e=player.getCards('e'); - player.storage.shanxian_n=1; - player.syncStorage('shanxian_e'); - player.phase('shanxian'); - player.storage.shanxian=trigger.player; - player.removeSkill('shanxian2'); - player.markSkill('shanxian'); - "step 2" - player.turnOver(true); - delete player.storage.shanxian; - }, - mod:{ - targetInRange:function(card,player,target,now){ - if(target==player.storage.shanxian) return true; - }, - }, - ai:{ - expose:0.1, - effect:{ - target:function(card){ - if(card.name=='guiyoujie') return [0,0]; - } - } - } - }, - shanxian2:{ - trigger:{player:['gainBegin','loseBegin']}, - forced:true, - popup:false, - content:function(){ - player.removeSkill('shanxian2'); - } - }, - shanhui:{ - unique:true, - trigger:{player:'damageEnd',source:'damageEnd'}, - filter:function(event,player){ - return player.storage.shanxian_h&&player.storage.shanxian_e&& - player.storage.shanxian_n>0&&!player.hasSkill('shanxian2'); - }, - check:function(event,player){ - var n1=player.countCards('he'); - var n2=player.storage.shanxian_h.length+player.storage.shanxian_e.length; - if(n1player.storage.shanxian_h.length+player.storage.shanxian_e.length){ - player.recover(); - } - player.storage.shanxian_n--; - if(player.storage.shanxian_n<=0){ - delete player.storage.shanxian_h; - delete player.storage.shanxian_e; - delete player.storage.shanxian_n; - player.unmarkSkill('shanxian'); - } - else{ - player.addSkill('shanxian2'); - } - } - } - }, - translate:{ - woliu:'涡流', - woliu2:'涡流', - woliu_info:'结束阶段,你可以选择至多两名角色,当你或目标中的任意一名角色成为杀的目标时,其余角色也将被追加为目标,直到你死亡或下一回合开始', - qianggu:'强固', - qianggu_info:'出牌阶段限一次,你可以弃置两张牌并获得两点护甲,若如此做,直到你的下个回合开始,其他角色对你使用杀时需要弃置一张基本牌,否则杀对你无效', - qianggu2:'强固', - qianggu2_bg:'固', - qianggu2_info:'其他角色对你使用杀时需要弃置一张基本牌,否则杀对你无效', - pingzhang:'屏障', - pingzhang_info:'每轮各限一次,当你受到伤害时,你可以弃置一张红桃牌令伤害-1;当一名其他角色受到伤害时,你可以弃置一张黑桃牌令伤害-1', - pingzhang_info_alter:'每轮各限一次,当你受到伤害时,你可以弃置一张红桃手牌令伤害-1;当一名其他角色受到伤害时,你可以弃置一张黑桃手牌令伤害-1', - liyong:'力涌', - liyong_info:'锁定技,你摸牌阶段摸牌数+X,X为你上一轮发动屏障的次数', - dianji:'电击', - dianji_info:'出牌阶段限一次,你可以将一张手牌当作惊雷闪对距离2以内的角色使用', - feitiao:'飞跳', - feitiao2:'飞跳', - feitiao_info:'出牌阶段开始时,你可以弃置一张牌并指定一名角色,你与该角色的距离视为1直到回合结束,然后该角色随机弃置一张牌', - bshaowei:'哨卫', - bshaowei_info:'结束阶段,你可以切换至哨卫模式。当处于此模式时,你的杀无视距离和防具、无数量限制且不可闪避;你不能闪避杀', - zhencha:'侦查', - zhencha_info:'结束阶段,你可以切换至侦查模式。当处于此模式时,每当你使用一张杀,你摸一张牌或回复一点体力', - liangou:'链钩', - liangou_info:'出牌阶段限一次,你可以弃置一张牌,指定一名其他角色并进行一次判定,若结果不为红桃,该角色与你距离为1且受到的首次伤害+1直到回合结束', - xiyang:'吸氧', - xiyang_info:'结束阶段,若你武将牌正面朝上,你可以翻面并回复两点体力', - qinru:'侵入', - qinru_info:'每当你使用杀指定目标时,你可以令其进行一次判定,若结果不为红桃,该角色的非锁定技失效直到其下一回合结束', - yinshen:'隐身', - yinshen_info:'锁定技,每当你失去最后一张基本牌,你获得潜行直到下一回合开始', - yinshen_info_old:'结束阶段,你可以弃置一张装备牌并获得潜行直到下一回合开始', - maichong:'脉冲', - maichong_info:'锁定技,每当你使用一张普通锦囊牌,你令最近三回合内被你侵入过的角色各随机弃置一张牌', - maichong_info_alter:'准备阶段,你可以令最近两名被你侵入的角色各随机弃置一张牌', - lichang:'力场', - lichang2:'力场', - lichang_info:'结束阶段,你可以弃置一张红色牌,若如此做,你可以在下个准备阶段令一名距离1以内的角色回复一点体力或摸两张牌', - mengji:'猛击', - mengji_info:'锁定技,若你已发动重盾,当你没有护甲时,你的杀造成的伤害+1', - zhongdun:'重盾', - zhongdun_info:'游戏开始时,你获得8点护甲;出牌阶段限一次,你可以弃置一张牌并将一点护甲分给一名没有护甲的其他角色', - zhongdun_info_alter:'游戏开始时,你获得6点护甲;出牌阶段限一次,你可以弃置一张牌并将一点护甲分给一名没有护甲的其他角色', - paotai:'炮台', - paotai2:'炮台', - paotai_info:'出牌阶段,你可以弃置一张杀布置或升级一个炮台(最高3级);结束阶段,炮台有一定机率对一名随机敌人造成一点火焰伤害;每当你受到一点伤害,炮台降低一级', - maoding:'铆钉', - maoding2:'铆钉', - maoding_info:'每当你造成或受到一次伤害,你可以获得一个零件;出牌阶段,你可以弃置两张零件牌令一名没有护甲的角色获得一点护甲', - maoding_info_alter:'每当你造成一次伤害,你可以获得一个零件;出牌阶段,你可以弃置两张零件牌令一名没有护甲的角色获得一点护甲', - bfengshi:'风矢', - bfengshi2:'风矢', - bfengshi_info:'锁定技,在一合内每当你使用一张牌,你的攻击范围+1;你的首张杀增加20%的概率强制命中;你的首张杀造成伤害后增加20%的概率令伤害+1', - bfengshi_info_alter:'锁定技,在一合内每当你使用一张牌,你的攻击范围+1;你的首张杀增加15%的概率强制命中;你的首张杀造成伤害后增加15%的概率令伤害+1', - yinbo:'音波', - yinbo_info:'出牌阶段限一次,你可以弃置一张黑桃牌,然后随机弃置三名敌人各一张牌', - liudan:'榴弹', - liudan_info:'每当你使用一张杀,你可以令所有不是此杀目标的其他角色有50%概率成为此杀的额外目标', - shoujia:'兽夹', - shoujia2:'兽夹', - shoujia3:'兽夹', - shoujia_info:'出牌阶段限一次,你可以将一张牌背面朝上置于一名其他角色的武将牌上,当该角色使用一张与此牌花色相同的牌指定其他角色为目标时,移去此牌,该角色将武将牌翻至背面;当你受到伤害时,移去此牌', - shihuo:'嗜火', - shihuo_info:'锁定技,每当一名角色受到火焰伤害,你摸一张牌', - shanguang:'闪光', - shanguang_info:'出牌阶段限一次,你可以弃置一张方片牌令攻击范围内的一名其他角色本回合内不能使用或打出卡牌', - tiandan:'填弹', - tiandan_info:'摸牌阶段开始时,你可以跳过出牌和弃牌阶段,然后获得若干张杀直到你的手牌数等于你的体值(最多为5)', - shenqiang:'神枪', - shenqiang_info:'锁定技,每当你在出牌阶段使用杀造成伤害,本阶段内出杀次数上限+1', - mianzhen:'眠针', - mianzhen2:'眠针', - mianzhen_info:'出牌阶段限一次,你可以弃置一张牌并令一名其他角色打出一张闪,否则该角色不能使用或打出卡牌直到其受到伤害或下一回合结束', - aqianghua:'强化', - aqianghua2:'强化', - aqianghua_info:'出牌阶段限一次,你可以将你的全部手牌(至少一张)交给一名其他角色,该角色获得一点护甲且下一次造成的伤害+1', - aqianghua_info_alter:'出牌阶段限一次,你可以将你的全部手牌(至少一张)交给一名其他角色,该角色下一次造成的伤害+1', - zhiyuan:'支援', - zhiyuan_info:'每当你即将造成伤害,你可以防止此伤害,改为令目标回复等量的体力', - juji:'狙击', - juji2:'狙击', - juji3:'狙击', - juji_info:'出牌阶段限一次,你可以弃置任意张花色不同的牌并指定一名有手牌的其他角色,若该角色的手牌中含有与你弃置的牌花色相同的牌,则本回合内你与其距离为1且该角色不能闪避你的杀', - duwen:'毒吻', - duwen2:'毒吻', - duwen_info:'锁定技,当你造成伤害时,若你的手牌数与受伤害角色相等,此伤害+1', - zhuagou:'抓钩', - zhuagou_info:'出牌阶段限一次,你可以弃置一张手牌并将你的座位移到任意位置', - dulei:'诡雷', - dulei2:'诡雷', - dulei_info:'出牌阶段,若你武将牌上没有牌,你可以将一张牌背面朝上置于你的武将牌上,当一名角色使用与该牌花色相同的牌指定你为目标时,你展示并移去此牌,然后该角色失去一点体力并随机弃置一张牌', - shuangqiang:'霜枪', - shuangqiang_info:'每当你对一名未翻面的角色造成伤害,你可以令伤害-1,然后令受伤害角色翻面', - baoxue:'暴雪', - baoxue_info:'限定技,出牌阶段,若你未翻面,你可以展示并弃置你的所有黑色牌,然后令至多X名其他角色随机弃置一张牌并将武将牌翻至背面,X为你的弃牌数;结算后你将武将牌翻至背面', - baoxue_info_alter:'限定技,出牌阶段,你可以展示并弃置你的所有黑色牌,并选择等量其他角色将武将牌翻至背面,结算后你将武将牌翻至背面', - bingqiang:'冰墙', - bingqiang2:'冰墙', - bingqiang2_bg:'墙', - bingqiang3:'冰墙', - bingqiang3_bg:'墙', - bingqiang4:'冰墙', - bingqiang4_bg:'墙', - bingqiang5:'冰墙', - bingqiang5_bg:'障', - bingqiang_info:'出牌阶段,你可以弃置X张红色牌令一名角色和其相邻角色的防御离+X,或弃置X张黑色牌令一名角色和其相邻角色的进攻离-X,效果持续到你的下个回合开始', - jidong:'急冻', - jidong_info:'在一名角色的结束阶段,若你的体力值为1且未翻面,你可以翻面并回复两点体力,在你的武将牌翻至正面前,你防止所有伤害,也不能成为其他角色卡牌的目标', - jidong_info_alter:'在一名角色的结束阶段,若你的体力值为1,你可以翻面并回复两点体力', - jijia:'机甲', - jijia_info:'锁定技,游戏开始时,你获得一个体力为4的机甲;你的手牌上限为你和机甲的体力之和;你受到的伤害由机甲承担', - zihui:'自毁', - zihui_info:'出牌阶段,你可以令距离2以内的所有其他角色选择一项:弃置数量等同你机甲体力值的牌,或受到2点火焰伤害,并在结算完毕后摧毁你的机甲', - zihui_info_alter:'出牌阶段,你可以令距离2以内的所有其他角色选择一项:1. 弃置数量等同你机甲体力值的牌(不足则全弃,至少弃1张);2. 或受到2点火焰伤害,并在结算完毕后摧毁你的机甲', - tuijin:'推进', - tuijin2:'推进', - tuijin_info:'出牌阶段限一次,若你有机甲,你可以指定一名角色,本回合内视为与其距离为1', - chongzhuang:'重装', - chongzhuang_info:'在你失去机甲后,当你累计造成了4点伤害时,你重新获得机甲', - shouge:'收割', - shouge_info:'每当你杀死一名角色,你可以获得一张治疗波', - tuji:'突击', - tuji_info:'锁定技,在你的回合内,每当你使用一张牌,你的进攻距离+1', - mujing:'目镜', - mujing2:'目镜', - mujing_info:'你可以将一张黑色牌当作杀使用或打出;当你的杀被闪避后,此杀不计入出杀次数', - mujing_old_info:'每当你对攻击范围不含你的角色使用一张牌,你可以弃置目标一张牌;若你的手牌数不多于目标,你摸一张牌', - feiren:'飞刃', - feiren2:'飞刃', - feiren_info:'你的杀无视距离;你的黑桃杀造成的伤害+1,梅花杀可以额外指定一个目标', - feiren_info_alter:'你的杀无视距离;你的梅花杀可以额外指定一个目标', - zhanlong:'斩龙', - zhanlong_info:'限定技,准备阶段,若你体力值为1,你可以弃置所有牌(至少一张),然后将三张杀置入你的手牌,若如此做,你本回合使用杀无次数限制', - xie:'谐', - xie2:'谐', - xie_info:'出牌阶段,你可以弃置一张红桃手牌并指定一名角色,该角色自其下一回合开始每隔六回合回复一点体力,直到你死亡。同一时间只能对一人发动', - luan:'乱', - luan2:'乱', - luan_old_info:'出牌阶段,你可以弃置一张黑桃手牌并指定一名角色,该角色自其下一回合开始每隔六回合失去一点体力,直到你死亡。同一时间只能对一人发动', - luan_info:'出牌阶段,你可以弃置一张黑桃手牌并指定一名角色,该角色受到伤害后流失一点体力,直到你死亡或其首次进入濒死状态。同一时间只能对一人发动', - sheng:'圣', - sheng_info:'限定技,出牌阶段,你可以将你的武将牌翻面,然后令任意名角色回复一点体力,若如此做,你不能成为其他角色的卡牌目标直到下一回合开始', - xiandan:'霰弹', - xiandan_info:'每当你使用一张杀,你可以弃置一张红色牌令此杀不可闪避,或弃置一张黑色牌令此杀伤害+1', - yihun:'移魂', - yihun_info:'结束阶段,你可以弃置一张黑色牌并指定一名其他角色,你在该角色下一准备阶段视为对其使用一张杀;在此之前,你不能使用卡牌,也不能成为卡牌的目标', - feidan:'飞弹', - feidan_info:'你的杀只能对距离1以外的角色使用;每当你使用杀造成伤害后,你可以弃置一张牌对距离目标1以内的其他角色各造成一点伤害', - huoyu:'火雨', - huoyu_info:'限定技,出牌阶段,你可以弃置两张红色牌,视为使用两张炽羽袭', - yuedong:'乐动', - yuedong_info:'出牌阶段结束时,你可以令一名角色摸一张牌', - kuoyin:'扩音', - kuoyin_info:'出牌阶段,你可以弃置一张牌令本回合乐动的目标数改为3,或弃置两张牌令本回合乐动的摸牌量改为2', - kuoyin_info_alter:'出牌阶段,你可以弃置一张牌令本回合乐动的目标数改为3', - huhuan:'互换', - huhuan_info:'出牌阶段,你可以弃置两张牌令本回合乐动的摸牌效果改为回复等量体力', - guangshu:'光枢', - guangshu_heart:'光盾', - guangshu_spade:'光塔', - guangshu_club:'光井', - guangshu_diamond:'光流', - guangshu_info:'出牌阶段,你可以弃置一张牌,并指定一名角色,根据弃置牌的花色执行如下效果:♥该角色下次受到伤害时回复一点体力;♦︎该角色下次造成伤害时摸两张牌;♣该角色无法使用杀直到下一回合结束;♠该角色于下个结束阶段受到一点无来源的雷电伤害', - ziyu:'自愈', - ziyu_info:'在一名角色的结束阶段,你可以回复一点体力或摸一张牌,每隔四回合发动一次', - ziyu_info_alter:'在一名角色的结束阶段,你可以回复一点体力或摸一张牌,每隔六回合发动一次', - shouhu:'守护', - shouhu_info:'你不能使用杀;出牌阶段,你可以弃置一张杀令一名其他角色回复一点体力', - shanxian:'闪现', - shanxian_info:'在一名其他角色的回合开始前,若你的武将牌正面朝上,你可以摸一张牌并进行一个额外回合,并在回合结束后将武将牌翻至背面。若如此做,你对其使用卡牌无视距离直到回合结束。', - shanxian_info_alter:'在一名其他角色的回合开始前,若你的武将牌正面朝上,你可以进行一个额外回合,并在回合结束后将武将牌翻至背面。若如此做,你对其使用卡牌无视距离直到回合结束。', - shanhui:'闪回', - shanhui_info:'当你造成或受到伤害后,你可以将你的牌重置为上次发动闪现时的状态,若你的牌数因此而减少,你回复一点体力', - ow_liekong:'猎空', - ow_sishen:'死神', - ow_tianshi:'天使', - ow_falaozhiying:'法老之鹰', - ow_zhixuzhiguang:'秩序之光', - ow_luxiao:'卢西奥', - ow_shibing:'士兵76', - ow_yuanshi:'源氏', - ow_chanyata:'禅雅塔', - ow_dva:'DVA', - ow_mei:'小美', - ow_heibaihe:'黑百合', - ow_ana:'安娜', - ow_baolei:'堡垒', - ow_maikelei:'麦克雷', - ow_banzang:'半藏', - ow_kuangshu:'狂鼠', - ow_tuobiang:'托比昂', - ow_laiyinhate:'莱因哈特', - ow_luba:'路霸', - ow_wensidun:'温斯顿', - ow_zhaliya:'查莉娅', - ow_heiying:'黑影', - ow_orisa:'奥丽莎', - } - }; -}); +'use strict'; +game.import('character',function(lib,game,ui,get,ai,_status){ + return { + name:'ow', + character:{ + ow_liekong:['female','shu',3,['shanxian','shanhui']], + ow_sishen:['male','shu',4,['xiandan','yihun','shouge']], + ow_tianshi:['female','qun',3,['shouhu','ziyu','feiying']], + ow_falaozhiying:['female','shu',3,['feidan','huoyu','feiying']], + ow_zhixuzhiguang:['female','qun',3,['guangshu']], + ow_luxiao:['male','wu',3,['yuedong','kuoyin','huhuan']], + ow_shibing:['male','shu',4,['tuji','mujing','lichang']], + ow_yuanshi:['male','qun',3,['feiren','lianpo','zhanlong']], + ow_chanyata:['male','qun',3,['xie','luan','sheng']], + ow_dva:['female','shu',2,['jijia','tuijin','zihui','chongzhuang']], + ow_mei:['female','wei',3,['bingqiang','jidong','baoxue']], + ow_ana:['female','wei',3,['zhiyuan','mianzhen','aqianghua']], + ow_heibaihe:['female','qun',3,['juji','duwen','dulei']], + ow_maikelei:['male','shu',4,['shanguang','tiandan','shenqiang']], + ow_kuangshu:['male','shu',3,['liudan','shoujia','shihuo']], + + ow_tuobiang:['male','shu',3,['paotai','maoding']], + ow_baolei:['male','qun',4,['bshaowei','zhencha']], + ow_banzang:['male','qun',4,['bfengshi','yinbo']], + ow_laiyinhate:['male','qun',4,['zhongdun','mengji']], + ow_luba:['male','shu',4,['liangou','xiyang']], + ow_wensidun:['male','shu',4,['feitiao','dianji']], + ow_zhaliya:['female','wei',4,['pingzhang','owliyong']], + + ow_heiying:['female','wei',3,['qinru','yinshen','maichong']], + ow_orisa:['female','wu',4,['qianggu','woliu']], + }, + characterIntro:{ + ow_orisa:'奥丽莎是用在努巴尼昙花一现的OR15防御机器人的零件组装而成的,她是这座城市的新一代守护者,但依然有很大的成长空间', + ow_liekong:'莉娜·奥克斯顿(代号:“猎空”)是守望先锋原型机试飞计划的最年轻成员。但在第一次试飞过程中,原型机的传送阵列出现故障,包括飞行员在内完全失踪。莉娜在几个月后再次出现,不过她身上的分子却无法和时间流同步。这种被称为“时间解离”的症状使她彻底变成了一个“活生生”的幽灵,时隐时现。直到一位名叫温斯顿的科学家设计出了“时间加速器”,一台可以让“猎空”维持在当前时间的装置。不仅如此,这一装置还让“猎空”有能力控制她自己的时间流,使她可以任意加速或减慢时间。有了这一全新的能力,她成了守望先锋最强大的特工之一。守望先锋解散后,“猎空”依旧选择为了正义而战,守护无辜。', + ow_sishen:'关于这个黑袍恐怖分子的传闻并不多,只知道大家都称他为“死神”。虽然没人知道他的真实身份和动机,但有一点是可以肯定的,他的出现意味着死亡。“死神”是一名极其不稳定、残暴、冷酷的雇佣兵,在世界各地犯下多起恐怖袭击案件。在过去的数十年间,他参与了许多武装冲突,但其本人却不属于任何组织。在多年的追踪后,“死神”神秘的面纱终于被慢慢揭开。据信,“死神”正在追杀前守望先锋特工并系统地逐一消灭。', + ow_tianshi:'齐格勒是瑞士一家顶尖医院的手术部门负责人。正是她在医学领域的成就,引起了守望先锋的注意。由于齐格勒的双亲都被战争夺走了生命,因此她从一开始就极其反对该组织通过军事手段进行维和。但最终,她意识到守望先锋给她提供了一个可以拯救更多人生命的机会。作为守望先锋医学研究部门的负责人,安吉拉致力于更好地在前线治疗受到致命伤的病员。尽管她对守望先锋做出了巨大的贡献,但齐格勒博士经常质疑她的上司以及守望先锋的长远目标。而当守望先锋解散之后,齐格勒博士便致力于帮助那些受战争波及的受难者。', + ow_falaozhiying:'本名法芮尔,来自一个军功卓越的军人世家,贡献与荣耀就是她最高的追求。在加入埃及军队后,她的坚韧和在战术上的天赋使她很快就晋升为了一名军官。作为一名果敢的领袖,任何在她手下服役的士兵都对她抱有绝对的忠诚。有了所有这些卓越的表现,法芮尔自然成了守望先锋最青睐的一名候选人。但在她正式加入之前,守望先锋就解散了。当她带着所有的荣誉退役后,法芮尔加入了一家名为“海力士国际安保”的私人安保公司,该公司的最重要的一笔订单就是负责保护吉萨高原地下的人工智能研究设施。尽管她对守望先锋的解散感到无比的遗憾,但她依旧梦想着能为正义而战并改变这个残破的世界。', + ow_zhixuzhiguang:'当被认为是为数不多可以成为光子建筑师的人才之后,年轻的塞特娅·法斯瓦尼离开了贫穷的家乡,成为了费斯卡光子建筑师学院的一员。她很快就成为了乌托邦最顶尖的光子建筑师。但费斯卡集团在塞特娅身上还是看到了更广阔的发展潜力。费斯卡集团称其为“秩序之光”,为了集团的利益和扩大在其他国家的影响力,将其派遣到全球执行秘密任务。虽然“秩序之光”相信她的所作所为是为了实现人性之“大善”,但有时候她也会怀疑她所希望实现的控制和秩序,是否真的是人类最需要的。', + ow_luxiao:'卢西奥•科雷亚•多斯桑托斯在里约热内卢长大。“智能危机”结束后,由于经济的一蹶不振导致这里变成了一个贫穷拥挤的贫民区。他想找到一个办法激发周围人的信心与活力:音乐。他开始在街边、社区派对进行表演,随着年龄的增长便开始了一系列传奇的地下演出。但当多国集团费斯卡集团计划重建城市的大部分地区时,卢西奥所在的社区陷入了混乱,人们失去了自由。卢西奥绝对不会容忍这一切。他偷走了费斯卡用来压迫人民的音波技术,反过来将人们团结在一起。最终,在一场暴动中,他们将费斯卡集团赶出了家园。卢西奥的领导能力让他在一夜之间成为了明星和社会正能量的象征。他的音乐在人们心中的地位如火箭般蹿升。随着影响力的不断扩大,卢西奥意识到他有机会可以改变这个世界,让这个世界变得更美好。', + ow_shibing:'被全球通缉的独行侠“士兵:76”独自一人发动了一场旨在查出守望先锋解散真相的战争。“士兵:76”在全球一系列针对金融机构、秘密集团和守望先锋基地的袭击活动中被曝光。尽管外界至今不清楚他的动机是什么,但有人认为他曾是一位守望先锋特工,决心查出守望先锋垮台的幕后黑手。', + ow_yuanshi:'岛田忍者家族大名最年轻的儿子,但对家族的非法生意毫无兴趣,被视为一个危险的累赘。在家族大名意外死亡后,他与哥哥半藏的矛盾激化,最终导致了一场生死对决,源氏也因此差点送命。后来被守望先锋救下,并被改造成机械忍者以摧毁他父亲的邪恶帝国。在完成任务后,源氏因无法接受自己的机械身躯,离开了守户先锋,并游历世界希望能找到自己存在的意义。数年之后,他遇到了智械僧侣禅雅塔,并且在这位僧侣的引导下,源氏体内的人类和机械体验终于融合在了一起。他开始明白,尽管他有一副机械身躯,但他的人类灵魂是完整的,他渐渐意识到自己的新形态是给予自己的恩赐和力量。', + ow_chanyata:'在“智能危机”结束之后,一群被放逐的智能机器人感受到了被其称为“灵魂觉醒”的升华之道,他们渐渐相信他们和人类一样,同样拥有灵魂。由神秘僧侣泰哈撒·孟达塔带领的这些僧侣开始寻找让人类和机器人重回曾经的和谐相处之道。他们最终被世人所接纳,并得到了全球数百万人的支持。但其中一位僧侣,禅雅塔并不赞同这一新道路。他认为要解决人类和机器人之间根深蒂固的问题,不能依靠循循善诱,而必须通过个体联系和互动。最终,他选择离开寺庙,游走世界,帮助那些他所遇到的人摆脱凡尘。但如果有必要,他也会为了保护无辜而拿起武器,无论人类还是机器人。', + ow_dva:'D.Va曾是一名职业玩家,而现在则利用自己的技巧驾驶一台尖端机甲保卫国家。随着智能机械不断进化,它最终干扰了MEKA的无人机控制网络,迫使军方派驾驶员驾驶这些机甲。由于难以找到合适的候选人,政府开始向那些拥有足以操控机甲尖端武器系统的必要反应和本能的国内职业玩家寻求帮助,其中就包括顶尖玩家之一的“D.Va”宋哈娜。作为一名为了获胜不惜一切代价的精英玩家,D.Va从来都不会对对手表现出丝毫的仁慈。D.Va将这次新任务视为一款全新的游戏,无所畏惧地和其他MEKA机甲冲向战场,随时准备保卫自己的国家。最近,她开始向她的粉丝直播战斗行动,而这也让她成为了世界巨星。', + ow_mei:'守望先锋为了查明全球不断升级的怪异气候现象的真正原因,在世界各个位置建立了一系列生态监测站。周美灵就是这一长久项目的成员之一。当她来到该项目的南极洲监控站时,一场突如其来的极地风暴摧毁了大部分设施并将这里与外界隔绝了开来。随着补给物资的不断消耗,科学家们进入了急冻状态希望能够撑到救援队抵达的那一天。但救援并没有抵达。几年后,当这些科学家的急冻舱最终被发现时,美是唯一的幸存者。此时,守望先锋已经解散,所有的生态监测站也都已经被废弃,他们之前收集的研究数据全部丢失。美最终决定独自继续她的工作。她带上了一台可穿戴式气候控制装置,游历世界,希望能够重新建立起生态监测网络,查出威胁着这个星球生态系统的真正原因。', + ow_ana:'守望先锋的创始成员之一,世界公认的顶级狙击手。智械危机结束后,安娜被晋升为了上尉。尽管身居要职,但已年过半百的安娜拒绝离开战场,依然亲临前线。直至在一次人质解救行动中,遭遇了一个叫做“黑百合”的黑爪特工,所有人都认为安娜死在了那场战斗中。但事实上,安娜活了下来,身受重伤并且失去了自己的右眼。在恢复期间,她感受到了战斗中生命的不可承受之重,因此决定就此隐居。然而随着时间一天天过去,看着自己家乡遭到的威胁愈演愈烈,她突然意识到自己依然有责任保护身边的亲人。在“征用”了守望先锋军械库中的装备后,安娜重新回到了这个世界,为了一个更安全、稳定的和平世界而战。', + ow_heibaihe:'“黑百合”在成为如今的杀手之前,曾与对抗恐怖组织“黑爪”的守望先锋探员杰哈·拉克瓦结婚。在多次刺杀杰哈无果之后,黑爪决定将目标转向他的妻子,艾米丽。黑爪特工绑架了艾米丽并对其进行了一项高强度神经重构计划。他们击垮了她的意志,抑制了其本身的人性,将其变成了一个潜伏特工。她最终被守望先锋探员找到并在确认无致命伤之后重新过上了以前的生活。两周之后,她杀死了睡梦中的杰哈,并回归了黑爪。', + ow_maikelei:'曾是美国西南部因非法军火交易而臭名昭著的“死局”帮中,最令人胆寒的一员,后被守望先锋逮捕。由于其枪法精湛且足智多谋,守望先锋给了他两个选择:在最高安全级别的监狱中度过余生,或加入守望先锋的秘密行动部队“暗影守望”。他选择了后者。尽管一开始他对守望先锋的理念嗤之以鼻,但他逐渐相信可以通过扫除世上的不公,来弥补自己过去犯下的罪行。后来,暗影守望内部出现了异样的气氛:废除守望先锋,独掌大权。麦克雷由于不想参与其中,于是便独自离开,销声匿迹。多年之后,他以雇佣兵的身份再次出现。尽管许多大小团体都想拉拢他,但他只为自己眼中的正义而战。', + ow_kuangshu:'由于澳大利亚智能中枢核心在遭到攻击后发生爆炸,这片地区现在变成了寸草不生的辐射荒地。但即便如此,还是有一群自称为“拾荒者”的人类生存了下来。他们在残骸中寻找一切还可利用的东西,渐渐形成了一个野蛮、危险的团体。“狂鼠”就是其中的一员。和其他人一样,他也受到了辐射,因此变成了一个痴迷于危险炸弹的疯子。当他在中枢废墟中发掘出一个极其珍贵的宝藏后,全世界都知道了这个疯子的名号。尽管几乎没人知道他到底发现了什么,但他身后总有数不清的赏金猎人、黑帮和投机分子想要杀掉他,直到他与“拾荒者”打手“路霸”达到了一个协议:只要今后找到的宝贝五五分成,“路霸”就会是“狂鼠”的私人保镖。', + ow_tuobiang:'托比昂是一个极其不信任智械的天才工程师,但他的同行都认为这只是他杞人忧天而已。但托比昂最担心的事情最终还是发生了,一场机器人对抗其人类发明者的“智能危机”在全球范围内爆发。由于其在工程学方面的天才造诣,守望先锋向他伸出了橄榄枝,并将其纳入了最早的守望先锋攻击部队,而他也证明了自己在终结这场危机中的关键价值。但在守望先锋解散后,托比昂设计出的许多武器被偷走并被藏在世界各地。出于对自己作品的责任心,托比昂便发誓不能让这些武器落入敌手,危害无辜的世人。', + ow_baolei:'“堡垒”系列在设计之初是被用于维和目的的,这一系列的机器单位拥有能够快速在突击和攻城模式之间转换的独特能力。但在“智能危机”期间,该系列却被用来对抗其人类发明者,成为了机器人叛军的中坚力量。随着后来危机的解除,几乎所有的“堡垒”系列机器人都被销毁或拆解。直到今天,“堡垒”依旧是当年那场可怕战争的代名词。但是有一台独特的“堡垒”机器人,在那场战争的决战中严重受损,因此被遗忘了数十年。直到有一天,它被意外地重新激活,它的战斗程序几乎全部受损,取而代之的是对自然世界及其住民的强烈好奇。好奇的“堡垒”于是在这个被战火蹂躏过的世界上,开始了探索和寻找自我价值的旅途。', + ow_banzang:'岛田家据传已有数百年的历史。以忍者为主要成员的岛田家,经过多年的发展,已经建立起一个以军火和非法物资交易为主的庞大黑道帝国。作为大名的长子,半藏注定要继承他的父亲统治岛田帝国。父亲过世后,家族长老就建议半藏帮助他那刚愎自用的弟弟源氏,以便两人携手管理岛田帝国。在遭到源氏拒绝后,半藏被迫亲手了结了自己的弟弟。半藏因此深受打击,他拒绝继承父亲的遗产并最终抛弃了自己的家族和所有辛苦换来的成果。现在,半藏四海为家,不断磨练着自己作为一名武士的技巧,希望终有一天能挽回自己的名誉并真正放下自己的过去。', + ow_laiyinhate:'莱因哈特•威尔海姆的行事作风就像一个属于过去的勇士,时刻铭记着骑士的信条:无畏、公正、勇敢。莱因哈特独特的道德观和舍小为大的信念,深得其上级的喜爱。他有话直说,因此成为了守望先锋最坚定的拥护者,同时在有必要时,也是守望先锋最刻薄的批评者,时刻提醒着其他人,守望先锋是一支正义之师。莱因哈特一直服役到将近六十岁,因此不得不面临强制退役。而守望先锋又深陷腐败和煽动叛乱之嫌的泥沼,莱因哈特只能眼睁睁地看着自己守护了一生的信念被吞噬。尽管守望先锋最终解散,但莱因哈特绝不会在世界陷入混乱之时袖手旁观。他再一次穿上了十字军战甲,立誓为正义而战,像曾经的白银骑士那样守护欧罗巴大陆无辜的人民,坚信光明的未来必将到来。', + ow_luba:'“路霸”马可曾是众多居住在澳洲内陆的居民之一。在智能危机爆发后,政府作出了一个极具争议的决定,将这里送给了差点摧毁整个国家的智能机器人,以求达成永久的和平协定。这一决定直接导致马可和大批居民被迫离开,因失去家园而怒不可遏的马可和其他人开始了一场暴力起义,最终,引发了一场大爆炸,导致周围数公里地区全部遭到辐射,只留下了变形的金属和残骸。为了在这种环境下生存下来,他戴上了面具、骑着破烂摩托开上了通往澳洲内陆的残破高速公路。一路上,他的人性一点一点地被消磨,马可最终消失了,而“路霸”就此诞生。', + ow_wensidun:'在“地平线”月球殖民地的居民中,有一群经过基因改造的大猩猩。其中一只大猩猩在接受了哈罗德·温斯顿博士团队的基因改造后,显示出了极快的脑部发育迹象,博士本人也将人类科学和创造力教给了这只猩猩。但当其他大猩猩发动叛乱,杀死了所有科学家并占领殖民地后,他的生活便再也回不到过去了。出于对哈罗德博士的爱戴,这只大猩猩决定继承他的姓氏:温斯顿,并设计出了一枚临时火箭逃往了地球。他找到了新家:守望先锋 —— 这是一个代表着他所憧憬的所有人性的组织。温斯顿终于有机会实现哈罗德博士生前不断教导他的英雄理念。但随着后来守望先锋的解散,温斯顿也隐居了起来,再一次与他报以厚望的世界失去联系,但他却从未放弃对英雄最终回归的期望。', + ow_zhaliya:'亚历山德拉·查莉娅诺娃是世界上最强壮的女运动员之一。然而就在世锦赛前夕,一直处于休眠状态的西伯利亚机器人控制中枢再度发动攻击,战火再次蔓延到了她的家乡。早已名利双收的亚历山德拉,毅然抛弃了一切,立即回到家乡加入了当地的防御部队。', + ow_heiying:'作为全世界最臭名昭著的黑客,“黑影”利用信息与情报操控权贵。早在她称自己为“黑影”之前,░░░░░░是千千万万在智械危机后变成孤儿的儿童之一。在家乡大部分基础设施都被摧毁的情况下,她依靠自己在黑客以及计算机方面的天赋活了下来。在黑客领域的一连串的胜利让░░░░░░对自己的实力过度自信,最终她在毫无防备的情况下,陷入了一张覆盖全球的阴谋网——并且也因此被人盯上了。由于自己的安全面临严重威胁,░░░░░░不得不删除关于自己的全部信息,从此销声匿迹。后来,她以“黑影”的身份再度出现,经过改造的她决心查出那张阴谋网背后的真相。', + }, + skill:{ + woliu:{ + trigger:{player:'phaseEnd'}, + direct:true, + unique:true, + forceunique:true, + content:function(){ + 'step 0' + player.chooseTarget(get.prompt('woliu'),lib.filter.notMe,[1,2]).ai=function(target){ + if(get.attitude(player,target)<0){ + return get.effect(target,{name:'sha'},player,player); + } + return 0; + } + 'step 1' + if(result.bool){ + player.logSkill('woliu',result.targets); + var list=[player].concat(result.targets); + for(var i=0;i0){ + return [0,num]; + } + if(target.hp==1&&!target.hasShan()) return; + return [1,num]; + } + } + } + } + }, + qianggu:{ + enable:'phaseUse', + usable:1, + filterCard:true, + selectCard:2, + position:'he', + check:function(card){ + return 8-get.value(card); + }, + filter:function(event,player){ + return player.countCards('he')>=2; + }, + content:function(){ + player.changeHujia(2); + player.addTempSkill('qianggu2',{player:'phaseBegin'}); + }, + ai:{ + result:{ + player:1 + }, + order:2.5 + } + }, + qianggu2:{ + trigger:{target:'useCardToBefore'}, + forced:true, + filter:function(event,player){ + return event.card.name=='sha'; + }, + mark:true, + intro:{ + content:'其他角色对你使用杀时需要弃置一张基本牌,否则杀对你无效' + }, + content:function(){ + "step 0" + var eff; + if(player.hasSkill('woliu2')){ + eff=-get.attitude(trigger.player,player); + } + else{ + eff=get.effect(player,trigger.card,trigger.player,trigger.player); + } + trigger.player.chooseToDiscard('强固:弃置一张基本牌,否则杀对'+get.translation(player)+'无效',function(card){ + return get.type(card)=='basic'; + }).set('ai',function(card){ + if(_status.event.eff>0){ + return 10-get.value(card); + } + return 0; + }).set('eff',eff); + "step 1" + if(result.bool==false){ + trigger.cancel(); + } + }, + ai:{ + effect:{ + target:function(card,player,target,current){ + if(card.name=='sha'){ + if(_status.event.name=='qianggu2') return; + if(get.attitude(player,target)>0) return; + var bs=player.getCards('h',{type:'basic'}); + if(bs.length<2) return 0; + if(player.hasSkill('jiu')||player.hasSkill('tianxianjiu')) return; + if(bs.length<=3&&player.countCards('h','sha')<=1){ + for(var i=0;i0; + }, + filterCard:true, + usable:1, + viewAs:{name:'jingleishan',nature:'thunder'}, + check:function(card){ + return 8-get.value(card) + }, + ai:{ + order:8, + expose:0.2, + threaten:1.2 + }, + mod:{ + playerEnabled:function(card,player,target){ + if(_status.event.skill=='dianji'&&get.distance(player,target)>2) return false; + } + } + }, + feitiao:{ + trigger:{player:'phaseUseBegin'}, + direct:true, + filter:function(event,player){ + return player.countCards('he')>0; + }, + content:function(){ + 'step 0' + var next=player.chooseCardTarget({ + prompt:get.prompt('feitiao'), + position:'he', + filterCard:true, + ai1:function(card){ + return 7-get.value(card); + }, + ai2:function(target){ + var att=get.attitude(player,target); + if(att>=0) return 0; + if(!target.countCards('he')) return -0.01; + var dist=get.distance(player,target); + if(dist>2){ + att-=2; + } + else if(dist==2){ + att--; + } + return -att; + }, + filterTarget:function(card,player,target){ + return player!=target; + } + }); + 'step 1' + if(result.bool){ + player.discard(result.cards); + var target=result.targets[0]; + player.logSkill('feitiao',target); + player.storage.feitiao2=target; + player.addTempSkill('feitiao2'); + target.randomDiscard(); + } + + } + }, + feitiao2:{ + mod:{ + globalFrom:function(from,to){ + if(to==from.storage.feitiao2) return -Infinity; + } + }, + mark:'character', + intro:{ + content:'与$的距离视为1直到回合结束' + }, + onremove:true + }, + zhencha:{ + init:function(player){ + player.storage.zhencha=true; + }, + mark:true, + intro:{ + content:function(storage,player){ + if(storage){ + return '每当你使用一张杀,你摸一张牌或回复一点体力'; + } + else if(player.hasSkill('bshaowei')&&player.storage.bshaowei){ + return '你的杀无视距离和防具、无数量限制且不可闪避;你不能闪避杀'; + } + else{ + return '无额外技能'; + } + } + }, + trigger:{player:'phaseEnd'}, + filter:function(event,player){ + if(player.hasSkill('zhencha2')) return false; + return !player.storage.zhencha; + }, + content:function(){ + player.storage.bshaowei=false; + player.storage.zhencha=true; + if(player.marks.zhencha){ + player.marks.zhencha.firstChild.innerHTML='侦'; + } + player.addTempSkill('zhencha2'); + }, + subSkill:{ + sha:{ + trigger:{player:'shaBegin'}, + direct:true, + filter:function(event,player){ + return player.storage.zhencha&&event.card&&event.card.name=='sha'; + }, + content:function(){ + player.chooseDrawRecover(get.prompt('zhencha')).logSkill='zhencha'; + } + } + }, + group:'zhencha_sha' + }, + bshaowei:{ + init:function(player){ + player.storage.bshaowei=false; + }, + trigger:{player:'phaseEnd'}, + filter:function(event,player){ + if(player.hasSkill('zhencha2')) return false; + return !player.storage.bshaowei; + }, + check:function(event,player){ + if(!player.hasShan()) return true; + if(!player.hasSha()) return false; + return Math.random()<0.5; + }, + content:function(){ + player.storage.bshaowei=true; + player.storage.zhencha=false; + if(player.marks.zhencha){ + player.marks.zhencha.firstChild.innerHTML='哨'; + } + player.addTempSkill('zhencha2'); + }, + subSkill:{ + sha:{ + mod:{ + targetInRange:function(card,player,target,now){ + if(card.name=='sha'&&player.storage.bshaowei) return true; + }, + cardUsable:function(card,player,num){ + if(card.name=='sha'&&player.storage.bshaowei) return Infinity; + } + }, + trigger:{target:'shaBegin',player:'shaBegin'}, + forced:true, + filter:function(event,player){ + return player.storage.bshaowei; + }, + check:function(){ + return false; + }, + content:function(){ + trigger.directHit=true; + }, + ai:{ + unequip:true, + skillTagFilter:function(player,tag,arg){ + if(!player.storage.bshaowei) return false; + if(arg&&arg.name=='sha') return true; + return false; + } + } + } + }, + group:'bshaowei_sha', + ai:{ + threaten:function(player,target){ + if(target.storage.bshaowei) return 1.7; + return 1; + } + } + }, + zhencha2:{}, + pingzhang:{ + trigger:{global:'damageBegin'}, + // alter:true, + intro:{ + content:function(storage,player){ + if(player.hasSkill('pingzhang2')){ + if(player.hasSkill('pingzhang3')){ + return '已对自已和其他角色发动屏障'; + } + else{ + return '已对自已发动屏障'; + } + } + else{ + return '已对其他角色发动屏障'; + } + }, + markcount:function(storage,player){ + if(player.hasSkill('pingzhang2')&&player.hasSkill('pingzhang3')){ + return 2; + } + return 1; + } + }, + filter:function(event,player){ + if(event.num<=0) return false; + var position=get.is.altered('pingzhang')?'h':'he'; + if(event.player==player){ + if(player.hasSkill('pingzhang2')) return false; + return player.countCards(position,{suit:'heart'}); + } + else{ + if(player.hasSkill('pingzhang3')) return false; + return player.countCards(position,{suit:'spade'}); + } + }, + direct:true, + content:function(){ + 'step 0' + var position=get.is.altered('pingzhang')?'h':'he'; + var suit=(player==trigger.player)?'heart':'spade'; + var next=player.chooseToDiscard(position,{suit:suit},get.prompt('pingzhang',trigger.player)); + next.ai=function(card){ + if(get.damageEffect(trigger.player,trigger.source,player)<0){ + return 8-get.value(card); + } + return 0; + } + next.logSkill=['pingzhang',trigger.player]; + 'step 1' + if(result.bool){ + trigger.num--; + if(player==trigger.player){ + player.addSkill('pingzhang2'); + } + else{ + player.addSkill('pingzhang3'); + } + player.markSkill('pingzhang'); + } + }, + group:['pingzhang_count'], + subSkill:{ + count:{ + trigger:{player:'phaseBegin'}, + silent:true, + content:function(){ + player.storage.pingzhang=0; + if(player.hasSkill('pingzhang2')){ + player.storage.pingzhang++; + player.removeSkill('pingzhang2'); + } + if(player.hasSkill('pingzhang3')){ + player.storage.pingzhang++; + player.removeSkill('pingzhang3'); + } + player.unmarkSkill('pingzhang'); + } + } + }, + ai:{ + expose:0.2, + threaten:1.5 + } + }, + pingzhang2:{}, + pingzhang3:{}, + owliyong:{ + trigger:{player:'phaseDrawBegin'}, + forced:true, + filter:function(event,player){ + return player.storage.pingzhang>0; + }, + content:function(){ + trigger.num+=player.storage.pingzhang; + } + }, + liangou:{ + enable:'phaseUse', + usable:1, + filterTarget:function(card,player,target){ + return target!=player; + }, + filterCard:true, + position:'he', + check:function(card){ + return 5-get.value(card); + }, + content:function(){ + 'step 0' + player.judge(function(card){ + return get.suit(card)!='heart'?1:-1; + }); + 'step 1' + if(result.bool){ + target.addTempSkill('liangou2'); + target.storage.liangou2=player; + } + }, + ai:{ + order:10, + expose:0.2, + result:{ + target:function(player,target){ + if(get.damageEffect(target,player,target)<0&&player.hasCard(function(card){ + return get.tag(card,'damage')?true:false; + })){ + return -1; + } + return 0; + } + } + } + }, + liangou2:{ + mod:{ + // cardEnabled:function(card,player){ + // return false; + // }, + // cardUsable:function(card,player){ + // return false; + // }, + // cardRespondable:function(card,player){ + // return false; + // }, + // cardSavable:function(card,player){ + // return false; + // }, + globalTo:function(from,to){ + if(from==to.storage.liangou2) return -Infinity; + } + }, + onremove:true, + trigger:{player:'damageBegin'}, + usable:1, + forced:true, + popup:false, + content:function(){ + trigger.num++; + }, + // ai:{ + // effect:{ + // target:function(card,player,target){ + // if(get.tag(card,'damage')) return [1,-2]; + // if(get.tag(card,'respond')) return [1,-1]; + // } + // } + // } + }, + xiyang:{ + trigger:{player:'phaseEnd'}, + filter:function(event,player){ + return !player.isTurnedOver()&&player.isDamaged(); + }, + check:function(event,player){ + return player.hp<=1; + }, + content:function(){ + 'step 0' + player.turnOver(); + 'step 1' + player.recover(2); + } + }, + qinru:{ + trigger:{player:'useCardToBegin'}, + filter:function(event,player){ + return event.card.name=='sha'&&event.target!=player&&event.target&&!event.target.hasSkill('fengyin'); + }, + logTarget:'target', + check:function(event,player){ + return get.attitude(player,event.target)<0; + }, + intro:{ + content:'players', + mark:function(dialog,storage,player){ + var one=[],two=[],three=[]; + for(var i=0;i1){ + player.storage.qinru_turn[i]--; + } + else{ + player.storage.qinru.splice(i,1); + player.storage.qinru_turn.splice(i,1); + i--; + } + } + if(!player.storage.qinru.length){ + player.unmarkSkill('qinru'); + } + else{ + player.updateMarks(); + } + } + } + }, + group:['qinru_count','qinru_die'] + }, + yinshen:{ + trigger:{player:'loseEnd'}, + forced:true, + filter:function(event,player){ + if(player.countCards('h',{type:'basic'})) return false; + for(var i=0;i0; + }, + content:function(){ + "step 0" + var next=player.chooseToDiscard(get.prompt('yinshen'),'he',{type:'equip'}); + next.logSkill='yinshen'; + next.ai=function(card){ + if(player.hp==1) return 8-get.value(card); + if(player.isZhu) return 7-get.value(card); + if(player.hp==2) return 6-get.value(card); + return 5-get.value(card); + }; + "step 1" + if(result.bool){ + player.tempHide(); + } + }, + }, + maichong:{ + trigger:{player:'useCard'}, + forced:true, + filter:function(event,player){ + if(!player.hasSkill('qinru')||!player.storage.qinru||!player.storage.qinru.length) return false; + if(get.type(event.card)=='trick'&&event.cards[0]&&event.cards[0]==event.card){ + for(var i=0;i0; + }, + filterTarget:function(card,player,target){ + return !target.hujia; + }, + filterCard:true, + position:'he', + check:function(card){ + var player=_status.event.player; + if(game.hasPlayer(function(current){ + return current.hp==1&&get.attitude(player,current)>2; + })){ + return 7-get.value(card); + } + return 5-get.value(card); + }, + content:function(){ + player.changeHujia(-1); + target.changeHujia(); + }, + ai:{ + order:5, + expose:0.2, + result:{ + target:function(player,target){ + return 1/Math.max(1,target.hp); + } + } + } + }, + maoding:{ + trigger:{player:'damageEnd',source:'damageEnd'}, + frequent:true, + filter:function(event,player){ + if(get.is.altered('maoding')&&event.source!=player) return false; + return true; + }, + // alter:true, + content:function(){ + var list=get.typeCard('hslingjian'); + if(!list.length){ + return; + } + player.gain(game.createCard(list.randomGet()),'gain2'); + }, + group:'maoding2', + ai:{ + threaten:1.5, + maixie_defend:true + } + }, + maoding2:{ + enable:'phaseUse', + filter:function(event,player){ + return player.countCards('h',{type:'hslingjian'})>1; + }, + filterCard:{type:'hslingjian'}, + filterTarget:function(card,player,target){ + return !target.hujia; + }, + selectCard:2, + // usable:1, + content:function(){ + target.changeHujia(); + }, + ai:{ + order:9, + result:{ + target:function(player,target){ + return 2/Math.max(1,Math.sqrt(target.hp)); + }, + }, + } + }, + paotai:{ + enable:'phaseUse', + intro:{ + content:function(storage){ + var num; + switch(storage){ + case 1:num=30;break; + case 2:num=60;break; + case 3:num=100;break; + } + return '结束阶段,有'+num+'%机率对一名随机敌人造成一点火焰伤害'; + } + }, + init:function(player){ + player.storage.paotai=0; + }, + filter:function(event,player){ + return player.countCards('h','sha')>0&&player.storage.paotai<3; + }, + filterCard:{name:'sha'}, + content:function(){ + player.storage.paotai++; + player.markSkill('paotai'); + }, + ai:{ + order:5, + threaten:1.5, + result:{ + player:1 + } + }, + group:['paotai2','paotai3'] + }, + paotai2:{ + trigger:{player:'phaseEnd'}, + forced:true, + filter:function(event,player){ + var num=0; + switch(player.storage.paotai){ + case 1:num=30;break; + case 2:num=60;break; + case 3:num=100;break; + } + return 100*Math.random()0&&event.num>0; + }, + content:function(){ + player.storage.paotai-=trigger.num; + if(player.storage.paotai<=0){ + player.storage.paotai=0; + player.unmarkSkill('paotai'); + } + else{ + player.updateMarks(); + } + } + }, + bfengshi:{ + trigger:{player:'shaBegin'}, + forced:true, + // alter:true, + check:function(event,player){ + return get.attitude(player,event.target)<=0; + }, + filter:function(event,player){ + if(player.hasSkill('bfengshi4')) return false; + var num=0.2; + if(get.is.altered('bfengshi')) num=0.15; + return Math.random()0; + }, + check:function(card){ + return 7-get.value(card); + }, + content:function(){ + 'step 0' + var targets=player.getEnemies(function(target){ + return target.countCards('he')>0; + }); + if(targets.length){ + event.targets=targets.randomGets(3); + event.targets.sort(lib.sort.seat); + player.line(event.targets,'green'); + } + 'step 1' + if(event.targets.length){ + var target=event.targets.shift(); + var he=target.getCards('he'); + if(he.length){ + target.addExpose(0.1); + target.discard(he.randomGet()); + } + event.redo(); + } + }, + ai:{ + order:10, + expose:0.3, + result:{ + player:1 + } + } + }, + aqianghua:{ + enable:'phaseUse', + usable:1, + // alter:true, + filter:function(event,player){ + return player.countCards('h')>=1; + }, + filterTarget:function(card,player,target){ + return target!=player; + }, + filterCard:true, + selectCard:-1, + discard:false, + prepare:'give', + content:function(){ + target.gain(cards); + if(!get.is.altered('aqianghua')) target.changeHujia(); + target.addSkill('aqianghua2'); + }, + ai:{ + threaten:1.5, + order:2.1, + result:{ + target:function(player,target){ + if(target.hasSkillTag('nogain')) return 0; + if(get.attitude(player,target)<3) return 0; + if(target.hasJudge('lebu')) return 0; + if(target.hasSkill('aqianghua2')) return 0.1; + return 1; + } + } + } + }, + aqianghua2:{ + trigger:{source:'damageBegin'}, + forced:true, + content:function(){ + trigger.num++; + player.unmarkSkill('aqianghua2'); + player.removeSkill('aqianghua2'); + }, + mark:true, + intro:{ + content:'下一次造成的伤害+1' + } + }, + shihuo:{ + trigger:{global:'damageEnd'}, + forced:true, + filter:function(event){ + return event.nature=='fire'; + }, + content:function(){ + player.draw(); + } + }, + shoujia:{ + enable:'phaseUse', + usable:1, + filter:function(event,player){ + return player.countCards('h')>0; + }, + filterCard:true, + check:function(card){ + return 6-get.value(card); + }, + discard:false, + prepare:'give2', + filterTarget:function(card,player,target){ + return target!=player&&!target.hasSkill('shoujia2'); + }, + content:function(){ + target.storage.shoujia=cards[0]; + target.storage.shoujia2=player; + target.addSkill('shoujia2'); + target.syncStorage('shoujia'); + }, + ai:{ + order:1, + expose:0.2, + threaten:1.4, + result:{ + target:-1 + } + } + }, + shoujia2:{ + mark:true, + trigger:{player:'useCardToBegin'}, + forced:true, + filter:function(event,player){ + return get.suit(event.card)==get.suit(player.storage.shoujia)&&event.target&&event.target!=player; + }, + content:function(){ + 'step 0' + player.showCards([player.storage.shoujia],get.translation(player)+'发动了【兽夹】'); + 'step 1' + player.storage.shoujia.discard(); + delete player.storage.shoujia; + delete player.storage.shoujia2; + player.removeSkill('shoujia2'); + game.addVideo('storage',player,['shoujia',null]); + game.addVideo('storage',player,['shoujia2',null]); + player.turnOver(true); + }, + intro:{ + mark:function(dialog,content,player){ + if(player.storage.shoujia2&&player.storage.shoujia2.isUnderControl(true)){ + dialog.add([player.storage.shoujia]); + } + else{ + return '已成为'+get.translation(player.storage.shoujia2)+'的兽夹目标'; + } + }, + content:function(content,player){ + if(player.storage.shoujia2&&player.storage.shoujia2.isUnderControl(true)){ + return get.translation(player.storage.shoujia); + } + return '已成为'+get.translation(player.storage.shoujia2)+'的兽夹目标'; + } + }, + group:'shoujia3' + }, + shoujia3:{ + trigger:{global:'damageEnd'}, + forced:true, + filter:function(event,player){ + return event.player==player.storage.shoujia2; + }, + content:function(){ + player.storage.shoujia.discard(); + player.$throw(player.storage.shoujia); + game.log(player.storage.shoujia,'被置入弃牌堆') + delete player.storage.shoujia; + delete player.storage.shoujia2; + player.removeSkill('shoujia2'); + game.addVideo('storage',player,['shoujia',null]); + game.addVideo('storage',player,['shoujia2',null]); + } + }, + liudan:{ + trigger:{player:'useCard'}, + check:function(event,player){ + return game.countPlayer(function(current){ + if(event.targets.contains(current)==false&¤t!=player&& + lib.filter.targetEnabled(event.card,player,current)){ + return get.effect(current,event.card,player,player); + } + })>=0; + }, + filter:function(event,player){ + if(event.card.name!='sha') return false; + return game.hasPlayer(function(current){ + return (event.targets.contains(current)==false&¤t!=player&& + lib.filter.targetEnabled(event.card,player,current)); + }); + }, + content:function(){ + var list=game.filterPlayer(function(current){ + return (trigger.targets.contains(current)==false&¤t!=player&& + lib.filter.targetEnabled(trigger.card,player,current)); + }); + if(list.length){ + var list2=[]; + for(var i=0;iplayer.countCards('h')&&!player.skipList.contains('phaseUse')&&!player.skipList.contains('phaseDiscard'); + }, + check:function(event,player){ + var nh=player.countCards('h'); + if(Math.min(5,player.hp)-nh>=2) return true; + return false; + }, + content:function(){ + var num=Math.min(5,player.hp)-player.countCards('h'); + var cards=[]; + while(num--){ + cards.push(game.createCard('sha')); + } + player.gain(cards,'gain2'); + player.skip('phaseUse'); + player.skip('phaseDiscard'); + } + }, + shanguang:{ + enable:'phaseUse', + usable:1, + filterCard:{suit:'diamond'}, + position:'he', + filter:function(event,player){ + return player.countCards('he',{suit:'diamond'})>0; + }, + filterTarget:function(card,player,target){ + return target!=player&&get.distance(player,target,'attack')<=1; + }, + check:function(card){ + if(card.name=='sha'&&_status.event.player.countCards('h','sha')<3) return 0; + return 6-get.value(card); + }, + content:function(){ + target.addTempSkill('shanguang2'); + }, + ai:{ + order:7.9, + result:{ + target:function(player,target){ + var nh=target.countCards('h'); + if(get.attitude(player,target)<0&&nh>=3&& + player.canUse('sha',target)&&player.countCards('h','sha')&& + get.effect(target,{name:'sha'},player,player)>0){ + return -nh-5; + } + return -nh; + } + } + } + }, + shanguang2:{ + mod:{ + cardEnabled:function(){ + return false; + }, + cardUsable:function(){ + return false; + }, + cardRespondable:function(){ + return false; + }, + cardSavable:function(){ + return false; + } + }, + ai:{ + effect:{ + target:function(card,player,target,current){ + if(get.tag(card,'respondShan')||get.tag(card,'respondSha')){ + if(current<0) return 1.5; + } + } + } + } + }, + baoxue:{ + enable:'phaseUse', + init:function(player){ + player.storage.baoxue=false; + }, + intro:{ + content:'limited' + }, + mark:true, + unique:true, + skillAnimation:true, + animationColor:'water', + line:'thunder', + filter:function(event,player){ + return !player.storage.baoxue&&player.countCards('he',{color:'black'})>0; + }, + filterTarget:function(card,player,target){ + return target!=player; + }, + selectTarget:function(){ + return [1,_status.event.player.countCards('he',{color:'black'})]; + }, + // alter:true, + delay:false, + contentBefore:function(){ + 'step 0' + game.delayx(); + 'step 1' + player.storage.baoxue=true; + player.awakenSkill('baoxue'); + player.showHandcards(); + player.discard(player.getCards('he',{color:'black'})); + }, + content:function(){ + 'step 0' + if(!get.is.altered('baoxue')){ + var he=target.getCards('he'); + if(he.length){ + target.discard(he.randomGet()); + } + } + 'step 1' + target.turnOver(true); + }, + contentAfter:function(){ + player.turnOver(true); + }, + ai:{ + order:function(skill,player){ + var num=game.countPlayer(function(current){ + return get.attitude(player,current)<0; + }); + var nh=player.countCards('he',{color:'black'}); + if(nh==1&&num>1) return 0; + if(nh>num) return 1; + return 11; + }, + result:{ + target:function(player,target){ + if(target.hasSkillTag('noturn')) return 0; + if(player.hasUnknown()) return 0; + return -1; + } + } + } + }, + mianzhen:{ + enable:'phaseUse', + usable:1, + filter:function(event,player){ + return player.countCards('he')>0; + }, + filterTarget:function(card,player,target){ + return target!=player&&!target.hasSkill('mianzhen2'); + }, + filterCard:true, + position:'he', + check:function(card){ + return 8-get.value(card); + }, + content:function(){ + 'step 0' + target.chooseToRespond({name:'shan'}); + 'step 1' + if(!result.bool) target.addSkill('mianzhen2'); + }, + ai:{ + order:2.2, + result:{ + target:function(player,target){ + return Math.min(-0.1,-1-target.countCards('h')+Math.sqrt(target.hp)/2); + } + } + } + }, + mianzhen2:{ + mark:true, + intro:{ + content:'不能使用或打出手牌直到受到伤害或下一回合结束' + }, + trigger:{player:['damageEnd','phaseEnd']}, + forced:true, + popup:false, + content:function(){ + player.removeSkill('mianzhen2'); + }, + mod:{ + cardEnabled:function(){ + return false; + }, + cardUsable:function(){ + return false; + }, + cardRespondable:function(){ + return false; + }, + cardSavable:function(){ + return false; + } + }, + ai:{ + threaten:0.6 + } + }, + zhiyuan:{ + trigger:{source:'damageBefore'}, + check:function(event,player){ + player.disableSkill('tmp','zhiyuan'); + var eff=get.damageEffect(event.player,player,player); + var att=get.attitude(player,event.player); + var bool=false; + if(att>0){ + if(eff<=0||event.player.hp0; + }, + content:function(){ + trigger.cancel(); + trigger.player.recover(trigger.num); + }, + ai:{ + effect:{ + player:function(card,player,target){ + if(get.tag(card,'damage')&&get.attitude(player,target)>0){ + if(target.hp==target.maxHp||get.recoverEffect(target,player,player)<=0) return 'zeroplayertarget'; + return [0,0,0,1]; + } + } + } + } + }, + duwen:{ + trigger:{source:'damageBegin'}, + check:function(event,player){ + return get.attitude(player,event.player)<=0; + }, + forced:true, + filter:function(event,player){ + return player.countCards('h')==event.player.countCards('h')&&event.notLink(); + }, + content:function(){ + trigger.num++; + }, + ai:{ + threaten:1.5 + }, + }, + duwen2:{ + trigger:{source:'damageEnd'}, + forced:true, + filter:function(event,player){ + return event.card&&event.card.name=='sha'&&player.hp==event.player.hp&&event.notLink(); + }, + content:function(){ + player.draw(2); + } + }, + juji:{ + enable:'phaseUse', + usable:1, + position:'he', + filter:function(event,player){ + return player.countCards('he')>0; + }, + filterCard:function(card){ + var suit=get.suit(card); + for(var i=0;i0; + }, + check:function(card){ + if(ui.selected.cards.length>1) return 0; + return 5-get.value(card); + }, + selectCard:[1,4], + content:function(){ + var suits=[]; + for(var i=0;inum){ + min.length=0; + min.push(players[i]); + num=eff; + } + } + } + for(var i=0;i0) return 0; + if(min[i].countCards('h')<=1&&get.distance(player,min[i],'attack')<=1) return 0; + } + if(min.contains(target)) return -1; + return 0; + } + } + }, + }, + juji2:{ + ai:{ + effect:{ + player:function(card,player,target){ + if(card.name=='sha'&&target==player.storage.juji2) return [1,0,1,-1]; + } + } + }, + trigger:{player:'phaseAfter'}, + forced:true, + popup:false, + content:function(){ + player.unmarkSkill('juji2'); + player.removeSkill('juji2'); + delete player.storage.juji2; + }, + group:'juji3' + }, + juji3:{ + trigger:{player:'shaBegin'}, + forced:true, + filter:function(event,player){ + return event.target==player.storage.juji2; + }, + content:function(){ + trigger.directHit=true; + }, + mod:{ + globalFrom:function(from,to){ + if(to==from.storage.juji2) return -Infinity; + } + } + }, + dulei:{ + enable:'phaseUse', + filter:function(event,player){ + return !player.hasSkill('dulei2'); + }, + filterCard:true, + check:function(card){ + return 6-get.value(card); + }, + discard:false, + prepare:function(cards,player){ + player.$give(1,player,false); + }, + content:function(){ + player.storage.dulei=cards[0]; + player.addSkill('dulei2'); + player.syncStorage('dulei'); + }, + ai:{ + order:1, + result:{ + player:1 + } + } + }, + dulei2:{ + mark:true, + trigger:{target:'useCardToBegin'}, + forced:true, + filter:function(event,player){ + return event.player!=player&&get.suit(event.card)==get.suit(player.storage.dulei); + }, + content:function(){ + 'step 0' + player.showCards([player.storage.dulei],get.translation(player)+'发动了【诡雷】'); + 'step 1' + player.storage.dulei.discard(); + delete player.storage.dulei; + player.removeSkill('dulei2'); + game.addVideo('storage',player,['dulei',null]); + trigger.player.loseHp(); + 'step 2' + var he=trigger.player.getCards('he'); + if(he.length){ + trigger.player.discard(he.randomGet()); + } + }, + intro:{ + mark:function(dialog,content,player){ + if(player==game.me||player.isUnderControl()){ + dialog.add([player.storage.dulei]); + } + else{ + return '已发动诡雷'; + } + }, + content:function(content,player){ + if(player==game.me||player.isUnderControl()){ + return get.translation(player.storage.dulei); + } + return '已发动诡雷'; + } + } + }, + juji_old:{ + trigger:{player:'shaBegin'}, + forced:true, + filter:function(event,player){ + return get.distance(event.target,player,'attack')>1; + }, + content:function(){ + trigger.directHit=true; + }, + group:'juji2' + }, + juji2_old:{ + enable:'phaseUse', + usable:1, + filterTarget:function(card,player,target){ + return target!=player; + }, + content:function(){ + target.addTempSkill('juji3',{player:'phaseEnd'}); + if(!target.storage.juji3){ + target.storage.juji3=[]; + } + target.storage.juji3.push(player); + }, + mod:{ + targetInRange:function(card,player,target){ + if(target.hasSkill('juji3')&&Array.isArray(target.storage.juji3)&&target.storage.juji3.contains(player)){ + return true; + } + } + } + }, + juji3_old:{ + mark:true, + intro:{ + nocount:true, + content:function(storage){ + return '对'+get.translation(storage)+'使用卡牌无视距离'; + } + }, + mod:{ + targetInRange:function(card,player,target){ + if(Array.isArray(player.storage.juji3)&&player.storage.juji3.contains(target)){ + return true; + } + } + } + }, + zhuagou:{ + enable:'phaseUse', + usable:1, + changeSeat:true, + filterTarget:function(card,player,target){ + return player!=target&&player.next!=target; + }, + filterCard:true, + check:function(card){ + return 4-get.value(card); + }, + content:function(){ + while(player.next!=target){ + game.swapSeat(player,player.next); + } + }, + ai:{ + order:5, + result:{ + player:function(player,target){ + var att=get.attitude(player,target); + if(target==player.previous&&att>0) return 1; + if(target==player.next.next&&get.attitude(player,player.next)<0) return 1; + return 0; + } + } + } + }, + bingqiang:{ + enable:'phaseUse', + position:'he', + filterCard:function(card){ + var color=get.color(card); + for(var i=0;imax){ + max=num; + } + if(num-min){ + if(get.color(card)=='red') return 5-get.value(card); + } + else{ + if(get.color(card)=='black') return 5-get.value(card); + } + return 0; + }, + changeTarget:function(player,targets){ + var target=targets[0]; + var add=game.filterPlayer(function(player){ + return get.distance(target,player,'pure')==1; + }); + for(var i=0;i0; + }, + content:function(){ + for(var i=0;i0; + }, + content:function(){ + 'step 0' + var goon=false; + var goon2=false; + var att=get.attitude(player,trigger.player); + if(att>0){ + if(trigger.player.hp==1) goon=true; + } + else{ + if(Math.random()<0.5) goon=true; + } + if(Math.random()<0.3) goon2=true; + player.chooseToDiscard([1,player.countCards('h')],'he',get.prompt('bingqiang',trigger.player)).set('logSkill',['bingqiang',trigger.player]).ai=function(card){ + if(ui.selected.cards.length) return 0; + if(goon) return 6-get.value(card); + if(goon2) return 4-get.value(card); + return 0; + } + 'step 1' + if(result.bool){ + var num=result.cards.length; + event.num=num; + player.chooseControl('选项一','选项二','选项三','选项四',function(){ + if(get.attitude(player,trigger.player)>0){ + if(Math.random()<0.7) return '选项一'; + return '选项三'; + } + else{ + if(Math.random()<0.7) return '选项四'; + return '选项二'; + } + }).set('prompt','冰墙

选项一:防御距离+'+num+ + '

选项二:防御距离-'+num+ + '

选项三:进攻距离+'+num+ + '

选项四:进攻距离-'+num+'
'); + } + else{ + event.finish(); + } + 'step 2' + switch(result.control){ + case '选项一':{ + trigger.player.storage.bingqiang2=event.num; + trigger.player.addTempSkill('bingqiang2',{player:'phaseBegin'}); + break; + } + case '选项二':{ + trigger.player.storage.bingqiang3=event.num; + trigger.player.addTempSkill('bingqiang3',{player:'phaseBegin'}); + break; + } + case '选项三':{ + trigger.player.storage.bingqiang4=event.num; + trigger.player.addTempSkill('bingqiang4',{player:'phaseBegin'}); + break; + } + case '选项四':{ + trigger.player.storage.bingqiang5=event.num; + trigger.player.addTempSkill('bingqiang5',{player:'phaseBegin'}); + break; + } + } + }, + ai:{ + expose:0.1 + } + }, + bingqiang2:{ + mark:true, + intro:{ + content:'防御距离+#' + }, + mod:{ + globalTo:function(from,to,distance){ + if(typeof to.storage.bingqiang2=='number') return distance+to.storage.bingqiang2; + }, + } + }, + bingqiang3:{ + mark:true, + intro:{ + content:'防御距离-#' + }, + mod:{ + globalTo:function(from,to,distance){ + if(typeof to.storage.bingqiang3=='number') return distance-to.storage.bingqiang3; + }, + } + }, + bingqiang4:{ + mark:true, + intro:{ + content:'进攻距离+#' + }, + mod:{ + globalFrom:function(from,to,distance){ + if(typeof from.storage.bingqiang4=='number') return distance-from.storage.bingqiang4; + } + } + }, + bingqiang5:{ + mark:true, + intro:{ + content:'进攻距离-#' + }, + mod:{ + globalFrom:function(from,to,distance){ + if(typeof from.storage.bingqiang5=='number') return distance+from.storage.bingqiang5; + } + } + }, + shuangqiang:{ + trigger:{source:'damageBegin'}, + check:function(event,player){ + var att=get.attitude(player,event.player); + if(event.player.hp==1) return att>0; + return att<=0; + }, + logTarget:'player', + filter:function(event,player){ + return !event.player.isTurnedOver()&&event.num>0; + }, + content:function(){ + trigger.num--; + trigger.player.draw(); + trigger.player.turnOver(); + } + }, + jidong:{ + trigger:{global:'phaseEnd'}, + filter:function(event,player){ + return player.hp==1&&!player.isTurnedOver(); + }, + // alter:true, + content:function(){ + 'step 0' + player.turnOver(); + player.recover(2); + 'step 1' + if(player.isTurnedOver()&&!get.is.altered('jidong')){ + player.addTempSkill('jidong2',{player:'turnOverAfter'}); + } + }, + ai:{ + threaten:function(player,target){ + if(target.hp==1) return 2; + return 1; + } + } + }, + jidong2:{ + trigger:{player:'damageBefore'}, + forced:true, + content:function(){ + trigger.cancel(); + }, + ai:{ + nofire:true, + nothunder:true, + nodamage:true, + effect:{ + target:function(card,player,target,current){ + if(get.tag(card,'damage')) return [0,0]; + } + }, + }, + mod:{ + targetEnabled:function(card,player,target){ + if(player!=target) return false; + } + } + }, + chongzhuang:{ + trigger:{source:'damageEnd'}, + forced:true, + filter:function(event,player){ + return player.storage.jijia<=0&&event.num>0; + }, + popup:false, + unique:true, + content:function(){ + player.storage.jijia2+=trigger.num; + if(player.storage.jijia2>=4){ + player.storage.jijia=4; + player.storage.jijia2=0; + player.markSkill('jijia'); + if(lib.config.skill_animation_type!='off'){ + player.logSkill('chongzhuang'); + player.$skill('重装') + } + } + } + }, + tuijin:{ + enable:'phaseUse', + usable:1, + unique:true, + filter:function(event,player){ + if(player.storage.jijia>0){ + return game.hasPlayer(function(current){ + return get.distance(player,current)>1 + }); + } + return false; + }, + filterTarget:function(card,player,target){ + return target!=player&&get.distance(player,target)>1; + }, + content:function(){ + player.storage.tuijin2=target; + player.addTempSkill('tuijin2'); + }, + ai:{ + order:11, + result:{ + target:function(player,target){ + if(get.attitude(player,target)<0){ + if(get.distance(player,target)>2) return -1.5; + return -1; + } + return 0.3; + } + } + } + }, + tuijin2:{ + mod:{ + globalFrom:function(from,to){ + if(to==from.storage.tuijin2) return -Infinity; + } + }, + mark:'character', + intro:{ + content:'与$的距离视为1直到回合结束' + }, + onremove:true + }, + jijia:{ + mark:true, + unique:true, + init:function(player){ + player.storage.jijia=4; + player.storage.jijia2=0; + }, + intro:{ + content:'机甲体力值:#' + }, + mod:{ + maxHandcard:function(player,num){ + if(player.storage.jijia>0){ + return num+player.storage.jijia; + } + } + }, + trigger:{player:'changeHp'}, + forced:true, + popup:false, + filter:function(event,player){ + return player.storage.jijia>0&&event.parent.name=='damage'&&event.num<0; + }, + content:function(){ + player.hp-=trigger.num; + player.update(); + player.storage.jijia+=trigger.num; + if(player.storage.jijia<=0){ + player.unmarkSkill('jijia'); + } + else{ + player.updateMarks(); + } + }, + ai:{ + threaten:function(player,target){ + if(target.storage.jijia<=0) return 2; + return 1; + } + } + }, + zihui:{ + enable:'phaseUse', + filter:function(event,player){ + return player.storage.jijia>0; + }, + filterTarget:function(card,player,target){ + return target!=player&&get.distance(player,target)<=2; + }, + unique:true, + selectTarget:-1, + skillAnimation:true, + animationColor:'fire', + line:'fire', + // alter:true, + content:function(){ + 'step 0' + var num=player.storage.jijia; + if(get.is.altered('zihui')){ + num=Math.max(1,Math.min(num,target.countCards('he'))); + } + target.chooseToDiscard(num,'he','弃置'+get.cnNumber(num)+'张牌,或受到2点火焰伤害').ai=function(card){ + if(target.hasSkillTag('nofire')) return 0; + if(get.type(card)!='basic') return 11-get.value(card); + if(target.hp>4) return 7-get.value(card); + if(target.hp==4&&num>=3) return 7-get.value(card); + if(target.hp==3&&num>=4) return 7-get.value(card); + if(num>1) return 8-get.value(card); + return 10-get.value(card); + }; + 'step 1' + if(!result.bool){ + target.damage(2,'fire'); + } + if(target==targets[targets.length-1]){ + player.storage.jijia=0; + player.unmarkSkill('jijia'); + } + }, + ai:{ + order:2, + result:{ + player:function(player){ + var num=0; + var players=game.filterPlayer(); + for(var i=0;i2) continue; + var nh=players[i].countCards('h'); + var att=get.attitude(player,players[i]); + if(nh0){ + if(players[i].hp<=2){ + num-=2; + } + else{ + num-=1.5; + } + } + } + else if(nh==player.storage.jijia){ + if(att<0){ + num+=0.5; + } + else if(att>0){ + num-=0.5; + } + } + } + if(num>=2) return 1; + return 0; + } + } + } + }, + xiandan:{ + trigger:{player:'shaBegin'}, + direct:true, + content:function(){ + "step 0" + var dis=trigger.target.countCards('h','shan')||trigger.target.getEquip('bagua')||trigger.target.countCards('h')>2; + var att=get.attitude(player,trigger.target); + var next=player.chooseToDiscard(get.prompt('xiandan')); + next.ai=function(card){ + if(att) return 0; + if(dis) return 7-get.value(card); + return 0; + } + next.logSkill='xiandan'; + "step 1" + if(result.bool){ + if(get.color(result.cards[0])=='red'){ + trigger.directHit=true; + } + else{ + player.addTempSkill('xiandan2','shaAfter'); + } + } + } + }, + xiandan2:{ + trigger:{source:'damageBegin'}, + filter:function(event){ + return event.card&&event.card.name=='sha'&&event.notLink(); + }, + forced:true, + popup:false, + content:function(){ + trigger.num++; + } + }, + shouge:{ + trigger:{source:'dieAfter'}, + frequent:true, + content:function(){ + player.gain(game.createCard('zhiliaobo'),'gain2'); + } + }, + tuji:{ + mod:{ + globalFrom:function(from,to,distance){ + if(_status.currentPhase==from){ + return distance-from.countUsed(); + } + }, + }, + }, + mujing:{ + enable:['chooseToRespond','chooseToUse'], + filterCard:function(card){ + return get.color(card)=='black'; + }, + position:'he', + viewAs:{name:'sha'}, + viewAsFilter:function(player){ + if(!player.countCards('he',{color:'black'})) return false; + }, + prompt:'将一张黑色牌当杀使用或打出', + check:function(card){return 4-get.value(card)}, + ai:{ + skillTagFilter:function(player){ + if(!player.countCards('he',{color:'black'})) return false; + }, + respondSha:true, + }, + group:'mujing2' + }, + mujing2:{ + trigger:{player:'shaMiss'}, + forced:true, + popup:false, + filter:function(event){ + return !event.parent._mujinged; + }, + content:function(){ + trigger.parent._mujinged=true; + player.getStat().card.sha--; + } + }, + lichang:{ + trigger:{player:'phaseEnd'}, + direct:true, + filter:function(event,player){ + return player.countCards('he',{color:'red'})>0; + }, + content:function(){ + "step 0" + var next=player.chooseToDiscard(get.prompt('lichang'),'he',{color:'red'}); + next.logSkill='lichang'; + next.ai=function(card){ + return 6-get.value(card); + }; + "step 1" + if(result.bool){ + player.addSkill('lichang2'); + } + }, + }, + lichang2:{ + trigger:{player:'phaseBegin'}, + direct:true, + mark:true, + intro:{ + content:'下个准备阶段令一名距离1以内的角色回复一点体力或摸两张牌' + }, + content:function(){ + 'step 0' + player.chooseTarget(get.prompt('lichang'),function(card,player,target){ + return get.distance(player,target)<=1; + }).ai=function(target){ + var att=get.attitude(player,target); + if(att>0){ + if(target.hp==1&&target.maxHp>1) return att*2; + } + return att; + }; + player.removeSkill('lichang2'); + 'step 1' + if(result.bool){ + player.logSkill('lichang',result.targets); + result.targets[0].chooseDrawRecover(2,true); + } + } + }, + mujing_old:{ + trigger:{player:'useCardToBegin'}, + filter:function(event,player){ + return event.target&&event.target!=player&&get.distance(event.target,player,'attack')>1; + }, + direct:true, + content:function(){ + 'step 0' + player.discardPlayerCard(get.prompt('mujing'),trigger.target).logSkill=['mujing']; + 'step 1' + if(result.bool&&player.countCards('h')<=trigger.target.countCards('h')){ + player.draw(); + } + } + }, + zhanlong:{ + trigger:{player:'phaseBegin'}, + unique:true, + mark:true, + skillAnimation:true, + init:function(player){ + player.storage.zhanlong=false; + }, + check:function(event,player){ + if(player.hasJudge('lebu')) return false; + return true; + }, + filter:function(event,player){ + if(player.storage.zhanlong) return false; + if(player.countCards('he')==0) return false; + if(player.hp!=1) return false; + return true; + }, + content:function(){ + 'step 0' + player.discard(player.getCards('he')); + 'step 1' + player.addTempSkill('zhanlong2'); + player.awakenSkill('zhanlong'); + player.storage.zhanlong=true; + var cards=[]; + for(var i=0;i<3;i++){ + cards.push(game.createCard('sha')); + } + player.gain(cards,'gain2'); + }, + ai:{ + threaten:function(player,target){ + if(target.hp==1) return 3; + return 1; + }, + effect:{ + target:function(card,player,target){ + if(!target.hasFriend()) return; + if(get.tag(card,'damage')==1&&target.hp==2&&target.countCards('he')&& + !target.isTurnedOver()&&_status.currentPhase!=target){ + if(get.distance(_status.currentPhase,target,'absolute')<=2) return [0.5,1]; + return 0.8; + } + } + } + }, + intro:{ + content:'limited' + } + }, + zhanlong2:{ + mod:{ + cardUsable:function(card){ + if(card.name=='sha') return Infinity; + } + } + }, + feiren:{ + trigger:{source:'damageBegin'}, + forced:true, + // alter:true, + filter:function(event,player){ + return !get.is.altered('feiren')&&event.card&&event.card.name=='sha'&&get.suit(event.card)=='spade'&&event.notLink(); + }, + content:function(){ + trigger.num++; + }, + mod:{ + targetInRange:function(card){ + if(card.name=='sha') return true; + }, + selectTarget:function(card,player,range){ + if(card.name=='sha'&&range[1]!=-1&&get.suit(card)=='club'){ + range[1]++; + } + }, + }, + ai:{ + threaten:1.4 + } + }, + feiren3:{ + trigger:{player:'useCardAfter'}, + filter:function(event,player){ + if(event.parent.name=='feiren2') return false; + if(event.card.name!='sha') return false; + if(get.suit(event.card)!='spade') return false; + var card=game.createCard(event.card.name,event.card.suit,event.card.number,event.card.nature); + for(var i=0;i0){ + return 0; + } + return get.recoverEffect(target,player,target); + } + } + } + }, + xie2:{ + mark:true, + trigger:{global:'phaseEnd'}, + forced:true, + filter:function(event,player){ + if(player.storage.xie=='now'){ + return event.player==player; + } + var num=game.phaseNumber-player.storage.xie; + return num&&num%6==0; + }, + content:function(){ + if(player.storage.xie=='now'){ + player.storage.xie=game.phaseNumber; + } + player.recover(); + }, + intro:{ + content:function(storage,player){ + var str='每隔六回合回复一点体力,直到'+get.translation(storage)+'死亡'; + if(typeof player.storage.xie=='number'){ + var num=game.phaseNumber-player.storage.xie; + num=num%6; + if(num==0){ + str+='(下次生效于本回合)' + } + else{ + str+='(下次生效于'+(6-num)+'回合后)' + } + } + return str; + }, + onunmark:function(storage,player){ + delete player.storage.xie; + delete player.storage.xie2; + } + }, + group:['xie3','xie4'] + }, + xie3:{ + trigger:{global:'phaseBegin'}, + forced:true, + popup:false, + content:function(){ + var num=game.phaseNumber-player.storage.xie; + num=num%6; + if(num){ + num=6-num; + } + player.storage.xie2_markcount=num; + player.updateMarks(); + } + }, + xie4:{ + trigger:{global:'dieAfter'}, + forced:true, + popup:false, + filter:function(event,player){ + return event.player==player.storage.xie2; + }, + content:function(){ + game.log(player,'解除了','【谐】'); + player.removeSkill('xie2'); + } + }, + luan:{ + enable:'phaseUse', + unique:true, + filterTarget:function(card,player,target){ + return target!=player&&!target.hasSkill('luan2'); + }, + filter:function(event,player){ + return player.countCards('h',{suit:'spade'}); + }, + filterCard:{suit:'spade'}, + check:function(card){ + return 7-get.value(card); + }, + content:function(){ + var current=game.findPlayer(function(player){ + return player.hasSkill('luan2'); + }); + if(current){ + current.removeSkill('luan2'); + } + target.addSkill('luan2'); + // target.storage.luan='now'; + target.storage.luan2=player; + }, + ai:{ + expose:0.2, + order:9.1, + threaten:2, + result:{ + target:function(player,target){ + var current=game.findPlayer(function(player){ + return player.hasSkill('luan2'); + }); + if(current&&get.attitude(player,current)<0){ + return 0; + } + if(target.hp==1) return 0.5; + return -1; + } + } + } + }, + luan2:{ + mark:true, + intro:{ + content:'受到的伤害后流失一点体力,直到首次进入濒死状态' + }, + trigger:{player:'damageEnd'}, + forced:true, + content:function(){ + player.loseHp(); + }, + ai:{ + threaten:1.2 + }, + group:['luan3','luan4'] + }, + luan3:{ + trigger:{player:'dyingAfter'}, + forced:true, + popup:false, + content:function(){ + game.log(player,'解除了','【乱】'); + player.removeSkill('luan2'); + } + }, + luan2_old:{ + mark:true, + trigger:{global:'phaseEnd'}, + forced:true, + filter:function(event,player){ + if(player.storage.luan=='now'){ + return event.player==player; + } + var num=game.phaseNumber-player.storage.luan; + return num&&num%6==0; + }, + content:function(){ + if(player.storage.luan=='now'){ + player.storage.luan=game.phaseNumber; + } + player.loseHp(); + }, + intro:{ + content:function(storage,player){ + var str='每隔六回合失去一点体力,直到'+get.translation(storage)+'死亡'; + if(typeof player.storage.luan=='number'){ + var num=game.phaseNumber-player.storage.luan; + num=num%6; + if(num==0){ + str+='(下次生效于本回合)' + } + else{ + str+='(下次生效于'+(6-num)+'回合后)' + } + } + return str; + }, + onunmark:function(storage,player){ + delete player.storage.luan; + delete player.storage.luan2; + } + }, + group:['luan3','luan4'] + }, + luan3_old:{ + trigger:{global:'phaseBegin'}, + forced:true, + popup:false, + content:function(){ + var num=game.phaseNumber-player.storage.luan; + num=num%6; + if(num){ + num=6-num; + } + player.storage.luan2_markcount=num; + player.updateMarks(); + } + }, + luan4:{ + trigger:{global:'dieAfter'}, + forced:true, + popup:false, + filter:function(event,player){ + return event.player==player.storage.luan2; + }, + content:function(){ + game.log(player,'解除了','【乱】'); + player.removeSkill('luan2'); + } + }, + sheng:{ + enable:'phaseUse', + unique:true, + mark:true, + skillAnimation:true, + animationColor:'metal', + init:function(player){ + player.storage.sheng=false; + }, + filter:function(event,player){ + if(player.storage.sheng) return false; + return true; + }, + filterTarget:function(card,player,target){ + return target.isDamaged(); + }, + selectTarget:[1,Infinity], + contentBefore:function(){ + player.turnOver(); + player.addSkill('sheng2'); + player.awakenSkill('sheng'); + player.storage.sheng=true; + }, + content:function(){ + target.recover(); + }, + ai:{ + order:1, + result:{ + target:function(player,target){ + var eff=get.recoverEffect(target,player,target); + if(player.hp==1) return eff; + if(player.hasUnknown()) return 0; + var num1=0,num2=0,num3=0,players=game.filterPlayer(); + for(var i=0;i0){ + num1++; + if(players[i].isDamaged()){ + num2++; + if(players[i].hp<=1){ + num3++; + } + } + } + } + if(num1==num2) return eff; + if(num2==num1-1&&num3) return eff; + if(num3>=2) return eff; + return 0; + } + }, + }, + intro:{ + content:'limited' + } + }, + sheng2:{ + trigger:{player:'phaseBegin'}, + forced:true, + popup:false, + content:function(){ + player.removeSkill('sheng2'); + }, + mod:{ + targetEnabled:function(card,player,target){ + if(player!=target) return false; + } + } + }, + yihun:{ + trigger:{player:'phaseEnd'}, + direct:true, + filter:function(event,player){ + return player.countCards('he',{color:'black'})>0&&!player.hasSkill('yihun2'); + }, + content:function(){ + 'step 0' + var next=player.chooseCardTarget({ + prompt:get.prompt('yihun'), + position:'he', + filterCard:function(card,player){ + return get.color(card)=='black'&&lib.filter.cardDiscardable(card,player); + }, + ai1:function(card){ + return 7-get.value(card); + }, + ai2:function(target){ + var att=-get.attitude(player,target); + if(target==player.next){ + att/=10; + } + if(target==player.next.next){ + att/=2; + } + return att; + }, + filterTarget:function(card,player,target){ + return player!=target; + }, + }); + 'step 1' + if(result.bool){ + player.discard(result.cards); + player.logSkill('yihun',result.targets); + player.addSkill('yihun2'); + var target=result.targets[0] + player.storage.yihun2=target; + if(target&&(get.mode()!='guozhan')||!target.isUnseen()){ + player.markSkillCharacter('yihun2',target,'移魂','在'+get.translation(target)+'的下一准备阶段视为对其使用一张杀'); + } + } + }, + }, + yihun2:{ + trigger:{global:['phaseBegin','dieAfter']}, + forced:true, + filter:function(event,player){ + return event.player==player.storage.yihun2; + }, + content:function(){ + if(player.storage.yihun2.isIn()){ + player.useCard({name:'sha'},player.storage.yihun2); + } + player.removeSkill('yihun2'); + delete player.storage.yihun2; + }, + mod:{ + targetEnabled:function(){ + return false; + }, + cardEnabled:function(card,player){ + return false; + }, + } + }, + huoyu:{ + enable:'phaseUse', + unique:true, + mark:true, + skillAnimation:true, + animationColor:'fire', + init:function(player){ + player.storage.huoyu=false; + }, + filter:function(event,player){ + if(player.storage.huoyu) return false; + if(player.countCards('he',{color:'red'})<2) return false; + return true; + }, + filterTarget:function(card,player,target){ + return player.canUse('chiyuxi',target); + }, + filterCard:{color:'red'}, + selectCard:2, + position:'he', + check:function(card){ + return 7-get.value(card); + }, + selectTarget:-1, + multitarget:true, + multiline:true, + line:'fire', + content:function(){ + 'step 0' + targets.sort(lib.sort.seat); + player.awakenSkill('huoyu'); + player.storage.huoyu=true; + player.useCard({name:'chiyuxi'},targets).animate=false; + 'step 1' + player.useCard({name:'chiyuxi'},targets).animate=false; + }, + ai:{ + order:5, + result:{ + target:function(player,target){ + if(player.hasUnknown()) return 0; + return get.effect(target,{name:'chiyuxi'},player,target); + } + }, + }, + intro:{ + content:'limited' + } + }, + feidan:{ + trigger:{source:'damageAfter'}, + direct:true, + filter:function(event,player){ + if(player.countCards('he')==0) return false; + if(!event.card) return false; + if(event.card.name!='sha') return false; + return game.hasPlayer(function(current){ + return current!=event.player&&get.distance(event.player,current)<=1 + }); + }, + content:function(){ + "step 0" + var eff=0; + var targets=game.filterPlayer(function(current){ + if(current!=trigger.player&&get.distance(trigger.player,current)<=1){ + eff+=get.damageEffect(current,player,player); + return true; + } + }); + event.targets=targets; + player.chooseToDiscard(get.prompt('feidan',targets)).set('ai',function(card){ + if(eff>0) return 7-get.value(card); + return 0; + }).set('logSkill',['feidan',targets]); + "step 1" + if(result.bool){ + event.targets.sort(lib.sort.seat); + } + else{ + event.finish(); + } + "step 2" + if(event.targets.length){ + event.targets.shift().damage(); + event.redo(); + } + }, + mod:{ + targetInRange:function(card,player,target){ + if(card.name=='sha'){ + if(get.distance(player,target)<=1) return false; + return true; + } + } + } + }, + yuedong:{ + trigger:{player:'phaseUseEnd'}, + direct:true, + content:function(){ + 'step 0' + var num=1+player.storage.yuedong_num; + player.chooseTarget(get.prompt('yuedong'),[1,num],function(card,player,target){ + if(player.storage.yuedong_recover){ + return target.hp1) return att/5; + if(num2==1){ + if(num>1) return att/3; + return att/4; + } + return att*1.1; + } + return att; + }); + 'step 1' + if(result.bool){ + player.logSkill('yuedong',result.targets); + var eff=1+player.storage.yuedong_eff; + if(player.storage.yuedong_recover){ + result.targets.sort(lib.sort.seat); + for(var i=0;i1&&!player.storage.yuedong_recover; + }, + check:function(card){ + return 6-get.value(card); + }, + content:function(){ + player.storage.yuedong_recover=true; + }, + ai:{ + order:10.2, + result:{ + player:function(player){ + var num1=0,num2=0,players=game.filterPlayer(); + for(var i=0;i0){ + num2++; + if(players[i].hp<=2&&players[i].maxHp>2){ + num1++; + if(players[i].hp==1){ + num1++; + } + } + } + } + if(num1>=3){ + return 1; + } + return 0; + } + } + } + }, + kuoyin:{ + enable:'phaseUse', + filterCard:true, + selectCard:function(){ + if(get.is.altered('kuoyin')) return 1; + if(_status.event.player.storage.yuedong_eff) return 1; + if(_status.event.player.storage.yuedong_num) return 2; + return [1,2]; + }, + position:'he', + // alter:true, + filter:function(event,player){ + if(get.is.altered('kuoyin')&&player.storage.yuedong_num) return false; + if(player.storage.yuedong_eff&&player.storage.yuedong_num) return false; + return player.countCards('he')>0; + }, + check:function(card){ + var player=_status.event.player; + var num1=0,num2=0,players=game.filterPlayer(); + for(var i=0;i0){ + num2++; + if(players[i].hp<=2&&players[i].maxHp>2){ + num1++; + } + } + } + if(player.storage.yuedong_recover){ + if(num1>1&&!player.storage.yuedong_num){ + if(ui.selected.cards.length) return 0; + return 7-get.value(card); + } + return 0; + } + else{ + if(num2>1&&!player.storage.yuedong_num){ + if(ui.selected.cards.length) return 0; + return 7-get.value(card); + } + if(num2>2){ + return 6-get.value(card); + } + return 5-get.value(card); + } + }, + content:function(){ + if(cards.length==1){ + player.storage.yuedong_num+=2; + } + else{ + player.storage.yuedong_eff++; + } + }, + ai:{ + threaten:1.6, + order:10.1, + result:{ + player:1 + } + }, + group:'kuoyin2' + }, + kuoyin2:{ + trigger:{player:'phaseBegin'}, + silent:true, + content:function(){ + player.storage.yuedong_recover=false; + player.storage.yuedong_num=0; + player.storage.yuedong_eff=0; + } + }, + guangshu:{ + enable:'phaseUse', + check:function(card){ + var player=_status.event.player; + var suit=get.suit(card); + if(suit=='heart'){ + if(game.hasPlayer(function(current){ + return current.hp==1&&get.attitude(player,current)>0 + })); + } + else if(suit=='spade'){ + return 7-get.value(card); + } + return 6-get.value(card); + }, + filter:function(event,player){ + return player.countCards('he')>0; + }, + filterTarget:function(card,player,target){ + return !target.hasSkill('guangshu_heart')&& + !target.hasSkill('guangshu_spade')&& + !target.hasSkill('guangshu_club')&& + !target.hasSkill('guangshu_diamond'); + }, + filterCard:true, + position:'he', + content:function(){ + target.addSkill('guangshu_'+get.suit(cards[0])); + }, + ai:{ + expose:0.2, + threaten:1.6, + order:5, + result:{ + target:function(player,target){ + if(!ui.selected.cards.length) return 0; + switch(get.suit(ui.selected.cards[0])){ + case 'heart':if(target.hp==1) return 1;return 0.1; + case 'diamond':return 1+Math.sqrt(target.countCards('h')); + case 'club':return -target.countCards('h')-Math.sqrt(target.countCards('h','sha')); + case 'spade':return get.damageEffect(target,player,target,'thunder'); + default:return 0; + } + } + } + } + }, + guangshu_diamond:{ + mark:true, + intro:{ + content:'下次造成伤害时摸两张牌' + }, + trigger:{source:'damageEnd'}, + forced:true, + content:function(){ + player.draw(2); + player.removeSkill('guangshu_diamond'); + } + }, + guangshu_heart:{ + mark:true, + intro:{ + content:'下次受到伤害时回复一点体力' + }, + trigger:{player:'damageEnd'}, + priority:6, + forced:true, + content:function(){ + player.recover(); + player.removeSkill('guangshu_heart'); + } + }, + guangshu_club:{ + mark:true, + intro:{ + content:'无法使用杀直到下一回合结束' + }, + trigger:{player:'phaseEnd'}, + forced:true, + popup:false, + content:function(){ + player.removeSkill('guangshu_club'); + }, + mod:{ + cardEnabled:function(card){ + if(card.name=='sha') return false; + } + } + }, + guangshu_spade:{ + mark:true, + intro:{ + content:'下个结束阶段受到一点无来源的雷电伤害' + }, + trigger:{player:'phaseEnd'}, + forced:true, + content:function(){ + player.damage('thunder','nosource'); + player.removeSkill('guangshu_spade'); + } + }, + ziyu:{ + trigger:{global:'phaseEnd'}, + direct:true, + filter:function(event,player){ + if(get.is.altered('ziyu')) return game.phaseNumber%6==0; + return game.phaseNumber%4==0; + }, + // alter:true, + content:function(){ + player.chooseDrawRecover(get.prompt('ziyu')).logSkill='ziyu'; + } + }, + shouhu:{ + mod:{ + cardEnabled:function(card){ + if(card.name=='sha') return false; + }, + }, + enable:'phaseUse', + filter:function(event,player){ + return player.countCards('h','sha')>0; + }, + filterTarget:function(card,player,target){ + return target.hpplayer.hp&&player.countCards('h','lebu')==0)||get.distance(player,event.player)>1); + }, + // alter:true, + intro:{ + content:function(storage,player){ + var str=''; + if(player.storage.shanxian_h.length){ + if(player.isUnderControl(true)){ + str+='手牌区:'+get.translation(player.storage.shanxian_h); + } + else{ + str+='手牌区:'+(player.storage.shanxian_h.length)+'张牌'; + } + } + if(player.storage.shanxian_e.length){ + if(str.length) str+='、'; + if(player.isUnderControl(true)){ + str+='装备区:'+get.translation(player.storage.shanxian_e); + } + else{ + str+='装备区:'+(player.storage.shanxian_e.length)+'张牌'; + } + } + return str; + }, + mark:function(dialog,content,player){ + if(player.storage.shanxian_h.length){ + if(player.isUnderControl(true)){ + dialog.add('
手牌区
'); + dialog.addSmall(player.storage.shanxian_h); + } + else{ + dialog.add('
手牌区:'+player.storage.shanxian_h.length+'张牌
'); + } + } + if(player.storage.shanxian_e.length){ + if(player.isUnderControl(true)){ + dialog.add('
装备区
'); + dialog.addSmall(player.storage.shanxian_e); + } + else{ + dialog.add('
装备区:'+player.storage.shanxian_e.length+'张牌
'); + } + } + }, + }, + logTarget:'player', + content:function(){ + "step 0" + if(!get.is.altered('shanxian')){ + player.draw(false); + player.$draw(); + } + "step 1" + player.storage.shanxian_h=player.getCards('h'); + player.storage.shanxian_e=player.getCards('e'); + player.storage.shanxian_n=1; + player.syncStorage('shanxian_e'); + player.phase('shanxian'); + player.storage.shanxian=trigger.player; + player.removeSkill('shanxian2'); + player.markSkill('shanxian'); + "step 2" + player.turnOver(true); + delete player.storage.shanxian; + }, + mod:{ + targetInRange:function(card,player,target,now){ + if(target==player.storage.shanxian) return true; + }, + }, + ai:{ + expose:0.1, + effect:{ + target:function(card){ + if(card.name=='guiyoujie') return [0,0]; + } + } + } + }, + shanxian2:{ + trigger:{player:['gainBegin','loseBegin']}, + forced:true, + popup:false, + content:function(){ + player.removeSkill('shanxian2'); + } + }, + shanhui:{ + unique:true, + trigger:{player:'damageEnd',source:'damageEnd'}, + filter:function(event,player){ + return player.storage.shanxian_h&&player.storage.shanxian_e&& + player.storage.shanxian_n>0&&!player.hasSkill('shanxian2'); + }, + check:function(event,player){ + var n1=player.countCards('he'); + var n2=player.storage.shanxian_h.length+player.storage.shanxian_e.length; + if(n1player.storage.shanxian_h.length+player.storage.shanxian_e.length){ + player.recover(); + } + player.storage.shanxian_n--; + if(player.storage.shanxian_n<=0){ + delete player.storage.shanxian_h; + delete player.storage.shanxian_e; + delete player.storage.shanxian_n; + player.unmarkSkill('shanxian'); + } + else{ + player.addSkill('shanxian2'); + } + } + } + }, + translate:{ + woliu:'涡流', + woliu2:'涡流', + woliu_info:'结束阶段,你可以选择至多两名角色,当你或目标中的任意一名角色成为杀的目标时,其余角色也将被追加为目标,直到你死亡或下一回合开始', + qianggu:'强固', + qianggu_info:'出牌阶段限一次,你可以弃置两张牌并获得两点护甲,若如此做,直到你的下个回合开始,其他角色对你使用杀时需要弃置一张基本牌,否则杀对你无效', + qianggu2:'强固', + qianggu2_bg:'固', + qianggu2_info:'其他角色对你使用杀时需要弃置一张基本牌,否则杀对你无效', + pingzhang:'屏障', + pingzhang_info:'每轮各限一次,当你受到伤害时,你可以弃置一张红桃牌令伤害-1;当一名其他角色受到伤害时,你可以弃置一张黑桃牌令伤害-1', + pingzhang_info_alter:'每轮各限一次,当你受到伤害时,你可以弃置一张红桃手牌令伤害-1;当一名其他角色受到伤害时,你可以弃置一张黑桃手牌令伤害-1', + owliyong:'力涌', + owliyong_info:'锁定技,你摸牌阶段摸牌数+X,X为你上一轮发动屏障的次数', + dianji:'电击', + dianji_info:'出牌阶段限一次,你可以将一张手牌当作惊雷闪对距离2以内的角色使用', + feitiao:'飞跳', + feitiao2:'飞跳', + feitiao_info:'出牌阶段开始时,你可以弃置一张牌并指定一名角色,你与该角色的距离视为1直到回合结束,然后该角色随机弃置一张牌', + bshaowei:'哨卫', + bshaowei_info:'结束阶段,你可以切换至哨卫模式。当处于此模式时,你的杀无视距离和防具、无数量限制且不可闪避;你不能闪避杀', + zhencha:'侦查', + zhencha_info:'结束阶段,你可以切换至侦查模式。当处于此模式时,每当你使用一张杀,你摸一张牌或回复一点体力', + liangou:'链钩', + liangou_info:'出牌阶段限一次,你可以弃置一张牌,指定一名其他角色并进行一次判定,若结果不为红桃,该角色与你距离为1且受到的首次伤害+1直到回合结束', + xiyang:'吸氧', + xiyang_info:'结束阶段,若你武将牌正面朝上,你可以翻面并回复两点体力', + qinru:'侵入', + qinru_info:'每当你使用杀指定目标时,你可以令其进行一次判定,若结果不为红桃,该角色的非锁定技失效直到其下一回合结束', + yinshen:'隐身', + yinshen_info:'锁定技,每当你失去最后一张基本牌,你获得潜行直到下一回合开始', + yinshen_info_old:'结束阶段,你可以弃置一张装备牌并获得潜行直到下一回合开始', + maichong:'脉冲', + maichong_info:'锁定技,每当你使用一张普通锦囊牌,你令最近三回合内被你侵入过的角色各随机弃置一张牌', + maichong_info_alter:'准备阶段,你可以令最近两名被你侵入的角色各随机弃置一张牌', + lichang:'力场', + lichang2:'力场', + lichang_info:'结束阶段,你可以弃置一张红色牌,若如此做,你可以在下个准备阶段令一名距离1以内的角色回复一点体力或摸两张牌', + mengji:'猛击', + mengji_info:'锁定技,若你已发动重盾,当你没有护甲时,你的杀造成的伤害+1', + zhongdun:'重盾', + zhongdun_info:'游戏开始时,你获得8点护甲;出牌阶段限一次,你可以弃置一张牌并将一点护甲分给一名没有护甲的其他角色', + zhongdun_info_alter:'游戏开始时,你获得6点护甲;出牌阶段限一次,你可以弃置一张牌并将一点护甲分给一名没有护甲的其他角色', + paotai:'炮台', + paotai2:'炮台', + paotai_info:'出牌阶段,你可以弃置一张杀布置或升级一个炮台(最高3级);结束阶段,炮台有一定机率对一名随机敌人造成一点火焰伤害;每当你受到一点伤害,炮台降低一级', + maoding:'铆钉', + maoding2:'铆钉', + maoding_info:'每当你造成或受到一次伤害,你可以获得一个零件;出牌阶段,你可以弃置两张零件牌令一名没有护甲的角色获得一点护甲', + maoding_info_alter:'每当你造成一次伤害,你可以获得一个零件;出牌阶段,你可以弃置两张零件牌令一名没有护甲的角色获得一点护甲', + bfengshi:'风矢', + bfengshi2:'风矢', + bfengshi_info:'锁定技,在一合内每当你使用一张牌,你的攻击范围+1;你的首张杀增加20%的概率强制命中;你的首张杀造成伤害后增加20%的概率令伤害+1', + bfengshi_info_alter:'锁定技,在一合内每当你使用一张牌,你的攻击范围+1;你的首张杀增加15%的概率强制命中;你的首张杀造成伤害后增加15%的概率令伤害+1', + yinbo:'音波', + yinbo_info:'出牌阶段限一次,你可以弃置一张黑桃牌,然后随机弃置三名敌人各一张牌', + liudan:'榴弹', + liudan_info:'每当你使用一张杀,你可以令所有不是此杀目标的其他角色有50%概率成为此杀的额外目标', + shoujia:'兽夹', + shoujia2:'兽夹', + shoujia3:'兽夹', + shoujia_info:'出牌阶段限一次,你可以将一张牌背面朝上置于一名其他角色的武将牌上,当该角色使用一张与此牌花色相同的牌指定其他角色为目标时,移去此牌,该角色将武将牌翻至背面;当你受到伤害时,移去此牌', + shihuo:'嗜火', + shihuo_info:'锁定技,每当一名角色受到火焰伤害,你摸一张牌', + shanguang:'闪光', + shanguang_info:'出牌阶段限一次,你可以弃置一张方片牌令攻击范围内的一名其他角色本回合内不能使用或打出卡牌', + tiandan:'填弹', + tiandan_info:'摸牌阶段开始时,你可以跳过出牌和弃牌阶段,然后获得若干张杀直到你的手牌数等于你的体值(最多为5)', + shenqiang:'神枪', + shenqiang_info:'锁定技,每当你在出牌阶段使用杀造成伤害,本阶段内出杀次数上限+1', + mianzhen:'眠针', + mianzhen2:'眠针', + mianzhen_info:'出牌阶段限一次,你可以弃置一张牌并令一名其他角色打出一张闪,否则该角色不能使用或打出卡牌直到其受到伤害或下一回合结束', + aqianghua:'强化', + aqianghua2:'强化', + aqianghua_info:'出牌阶段限一次,你可以将你的全部手牌(至少一张)交给一名其他角色,该角色获得一点护甲且下一次造成的伤害+1', + aqianghua_info_alter:'出牌阶段限一次,你可以将你的全部手牌(至少一张)交给一名其他角色,该角色下一次造成的伤害+1', + zhiyuan:'支援', + zhiyuan_info:'每当你即将造成伤害,你可以防止此伤害,改为令目标回复等量的体力', + juji:'狙击', + juji2:'狙击', + juji3:'狙击', + juji_info:'出牌阶段限一次,你可以弃置任意张花色不同的牌并指定一名有手牌的其他角色,若该角色的手牌中含有与你弃置的牌花色相同的牌,则本回合内你与其距离为1且该角色不能闪避你的杀', + duwen:'毒吻', + duwen2:'毒吻', + duwen_info:'锁定技,当你造成伤害时,若你的手牌数与受伤害角色相等,此伤害+1', + zhuagou:'抓钩', + zhuagou_info:'出牌阶段限一次,你可以弃置一张手牌并将你的座位移到任意位置', + dulei:'诡雷', + dulei2:'诡雷', + dulei_info:'出牌阶段,若你武将牌上没有牌,你可以将一张牌背面朝上置于你的武将牌上,当一名角色使用与该牌花色相同的牌指定你为目标时,你展示并移去此牌,然后该角色失去一点体力并随机弃置一张牌', + shuangqiang:'霜枪', + shuangqiang_info:'每当你对一名未翻面的角色造成伤害,你可以令伤害-1,然后令受伤害角色翻面', + baoxue:'暴雪', + baoxue_info:'限定技,出牌阶段,若你未翻面,你可以展示并弃置你的所有黑色牌,然后令至多X名其他角色随机弃置一张牌并将武将牌翻至背面,X为你的弃牌数;结算后你将武将牌翻至背面', + baoxue_info_alter:'限定技,出牌阶段,你可以展示并弃置你的所有黑色牌,并选择等量其他角色将武将牌翻至背面,结算后你将武将牌翻至背面', + bingqiang:'冰墙', + bingqiang2:'冰墙', + bingqiang2_bg:'墙', + bingqiang3:'冰墙', + bingqiang3_bg:'墙', + bingqiang4:'冰墙', + bingqiang4_bg:'墙', + bingqiang5:'冰墙', + bingqiang5_bg:'障', + bingqiang_info:'出牌阶段,你可以弃置X张红色牌令一名角色和其相邻角色的防御离+X,或弃置X张黑色牌令一名角色和其相邻角色的进攻离-X,效果持续到你的下个回合开始', + jidong:'急冻', + jidong_info:'在一名角色的结束阶段,若你的体力值为1且未翻面,你可以翻面并回复两点体力,在你的武将牌翻至正面前,你防止所有伤害,也不能成为其他角色卡牌的目标', + jidong_info_alter:'在一名角色的结束阶段,若你的体力值为1,你可以翻面并回复两点体力', + jijia:'机甲', + jijia_info:'锁定技,游戏开始时,你获得一个体力为4的机甲;你的手牌上限为你和机甲的体力之和;你受到的伤害由机甲承担', + zihui:'自毁', + zihui_info:'出牌阶段,你可以令距离2以内的所有其他角色选择一项:弃置数量等同你机甲体力值的牌,或受到2点火焰伤害,并在结算完毕后摧毁你的机甲', + zihui_info_alter:'出牌阶段,你可以令距离2以内的所有其他角色选择一项:1. 弃置数量等同你机甲体力值的牌(不足则全弃,至少弃1张);2. 或受到2点火焰伤害,并在结算完毕后摧毁你的机甲', + tuijin:'推进', + tuijin2:'推进', + tuijin_info:'出牌阶段限一次,若你有机甲,你可以指定一名角色,本回合内视为与其距离为1', + chongzhuang:'重装', + chongzhuang_info:'在你失去机甲后,当你累计造成了4点伤害时,你重新获得机甲', + shouge:'收割', + shouge_info:'每当你杀死一名角色,你可以获得一张治疗波', + tuji:'突击', + tuji_info:'锁定技,在你的回合内,每当你使用一张牌,你的进攻距离+1', + mujing:'目镜', + mujing2:'目镜', + mujing_info:'你可以将一张黑色牌当作杀使用或打出;当你的杀被闪避后,此杀不计入出杀次数', + mujing_old_info:'每当你对攻击范围不含你的角色使用一张牌,你可以弃置目标一张牌;若你的手牌数不多于目标,你摸一张牌', + feiren:'飞刃', + feiren2:'飞刃', + feiren_info:'你的杀无视距离;你的黑桃杀造成的伤害+1,梅花杀可以额外指定一个目标', + feiren_info_alter:'你的杀无视距离;你的梅花杀可以额外指定一个目标', + zhanlong:'斩龙', + zhanlong_info:'限定技,准备阶段,若你体力值为1,你可以弃置所有牌(至少一张),然后将三张杀置入你的手牌,若如此做,你本回合使用杀无次数限制', + xie:'谐', + xie2:'谐', + xie_info:'出牌阶段,你可以弃置一张红桃手牌并指定一名角色,该角色自其下一回合开始每隔六回合回复一点体力,直到你死亡。同一时间只能对一人发动', + luan:'乱', + luan2:'乱', + luan_old_info:'出牌阶段,你可以弃置一张黑桃手牌并指定一名角色,该角色自其下一回合开始每隔六回合失去一点体力,直到你死亡。同一时间只能对一人发动', + luan_info:'出牌阶段,你可以弃置一张黑桃手牌并指定一名角色,该角色受到伤害后流失一点体力,直到你死亡或其首次进入濒死状态。同一时间只能对一人发动', + sheng:'圣', + sheng_info:'限定技,出牌阶段,你可以将你的武将牌翻面,然后令任意名角色回复一点体力,若如此做,你不能成为其他角色的卡牌目标直到下一回合开始', + xiandan:'霰弹', + xiandan_info:'每当你使用一张杀,你可以弃置一张红色牌令此杀不可闪避,或弃置一张黑色牌令此杀伤害+1', + yihun:'移魂', + yihun_info:'结束阶段,你可以弃置一张黑色牌并指定一名其他角色,你在该角色下一准备阶段视为对其使用一张杀;在此之前,你不能使用卡牌,也不能成为卡牌的目标', + feidan:'飞弹', + feidan_info:'你的杀只能对距离1以外的角色使用;每当你使用杀造成伤害后,你可以弃置一张牌对距离目标1以内的其他角色各造成一点伤害', + huoyu:'火雨', + huoyu_info:'限定技,出牌阶段,你可以弃置两张红色牌,视为使用两张炽羽袭', + yuedong:'乐动', + yuedong_info:'出牌阶段结束时,你可以令一名角色摸一张牌', + kuoyin:'扩音', + kuoyin_info:'出牌阶段,你可以弃置一张牌令本回合乐动的目标数改为3,或弃置两张牌令本回合乐动的摸牌量改为2', + kuoyin_info_alter:'出牌阶段,你可以弃置一张牌令本回合乐动的目标数改为3', + huhuan:'互换', + huhuan_info:'出牌阶段,你可以弃置两张牌令本回合乐动的摸牌效果改为回复等量体力', + guangshu:'光枢', + guangshu_heart:'光盾', + guangshu_spade:'光塔', + guangshu_club:'光井', + guangshu_diamond:'光流', + guangshu_info:'出牌阶段,你可以弃置一张牌,并指定一名角色,根据弃置牌的花色执行如下效果:♥该角色下次受到伤害时回复一点体力;♦︎该角色下次造成伤害时摸两张牌;♣该角色无法使用杀直到下一回合结束;♠该角色于下个结束阶段受到一点无来源的雷电伤害', + ziyu:'自愈', + ziyu_info:'在一名角色的结束阶段,你可以回复一点体力或摸一张牌,每隔四回合发动一次', + ziyu_info_alter:'在一名角色的结束阶段,你可以回复一点体力或摸一张牌,每隔六回合发动一次', + shouhu:'守护', + shouhu_info:'你不能使用杀;出牌阶段,你可以弃置一张杀令一名其他角色回复一点体力', + shanxian:'闪现', + shanxian_info:'在一名其他角色的回合开始前,若你的武将牌正面朝上,你可以摸一张牌并进行一个额外回合,并在回合结束后将武将牌翻至背面。若如此做,你对其使用卡牌无视距离直到回合结束。', + shanxian_info_alter:'在一名其他角色的回合开始前,若你的武将牌正面朝上,你可以进行一个额外回合,并在回合结束后将武将牌翻至背面。若如此做,你对其使用卡牌无视距离直到回合结束。', + shanhui:'闪回', + shanhui_info:'当你造成或受到伤害后,你可以将你的牌重置为上次发动闪现时的状态,若你的牌数因此而减少,你回复一点体力', + ow_liekong:'猎空', + ow_sishen:'死神', + ow_tianshi:'天使', + ow_falaozhiying:'法老之鹰', + ow_zhixuzhiguang:'秩序之光', + ow_luxiao:'卢西奥', + ow_shibing:'士兵76', + ow_yuanshi:'源氏', + ow_chanyata:'禅雅塔', + ow_dva:'DVA', + ow_mei:'小美', + ow_heibaihe:'黑百合', + ow_ana:'安娜', + ow_baolei:'堡垒', + ow_maikelei:'麦克雷', + ow_banzang:'半藏', + ow_kuangshu:'狂鼠', + ow_tuobiang:'托比昂', + ow_laiyinhate:'莱因哈特', + ow_luba:'路霸', + ow_wensidun:'温斯顿', + ow_zhaliya:'查莉娅', + ow_heiying:'黑影', + ow_orisa:'奥丽莎', + } + }; +}); diff --git a/character/rank.js b/character/rank.js index 1d89a6d72..297a0629d 100644 --- a/character/rank.js +++ b/character/rank.js @@ -938,6 +938,7 @@ window.noname_character_rank={ 'mini_zhangchunhua', 'hucheer', 'jin_xiahouhui', + 'xin_zhangfei', ], c:[ 'xiahoudun', @@ -1526,6 +1527,7 @@ window.noname_character_rank={ 'xin_lingtong', 'xin_liubiao', 're_xinxianying', + 'xin_zhangfei', 'wangrong', 're_quyi', 'hanfu', diff --git a/character/refresh.js b/character/refresh.js index d5ea86bd2..f68cae3b9 100755 --- a/character/refresh.js +++ b/character/refresh.js @@ -1182,7 +1182,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, ai:{ unequip_ai:true, + directHit_ai:true, skillTagFilter:function(player,tag,arg){ + if(get.attitude(player,arg.target)>0) return false; + if(tag=='directHit_ai') return arg.target.hp>=Math.max(1,arg.target.countCards('h')-1); if(arg&&arg.name=='sha'&&arg.target.getEquip(2)) return true; return false; } @@ -1318,7 +1321,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, ai:{ unequip_ai:true, + directHit_ai:true, skillTagFilter:function(player,tag,arg){ + if(tag=='directHit_ai') return arg.card.name=='sha'&&arg.target.countCards('e',function(card){ + return get.value(card)>1; + })>0; if(arg&&arg.name=='sha'&&arg.target.getEquip(2)) return true; return false; } @@ -2943,7 +2950,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, ai:{ unequip_ai:true, + directHit_ai:true, skillTagFilter:function(player,tag,arg){ + if(get.attitude(player,arg.target)>0) return false; + if(tag=='directHit_ai') return arg.target.hp>=Math.max(1,arg.target.countCards('h')-1); if(arg&&arg.name=='sha'&&arg.target.getEquip(2)) return true; return false; } @@ -3616,7 +3626,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ var skills=lib.character[name][3]; for(var j=0;jtarget.hp+1&&get.recoverEffect(target)>0){ @@ -4894,24 +4907,28 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, }, order:9, + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + if(!arg.target.hasSkillTag('new_yijue2')) return false; + }, }, }, "new_yijue2":{ trigger:{ player:"damageBegin1", }, - filter:function (event){ + filter:function(event){ return event.source&&event.source.hasSkill('new_yijue')&&event.card&&event.card.name=='sha'&&get.suit(event.card)=='heart'&&event.notLink(); }, silent:true, popup:false, forced:true, - content:function (){ + content:function(){ trigger.num++; }, mark:true, mod:{ - cardEnabled2:function (card){ + cardEnabled2:function(card){ if(get.position(card)=='h') return false; }, }, @@ -4919,10 +4936,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){ content:"不能使用或打出手牌", }, }, + paoxiao_re_zhangfei:{audio:2}, "new_repaoxiao":{ audio:"paoxiao", firstDo:true, - audioname2:{old_guanzhang:'old_fuhun'}, + audioname2:{ + old_guanzhang:'old_fuhun', + xin_zhangfei:'paoxiao_re_zhangfei', + }, audioname:['re_zhangfei','guanzhang','xiahouba'], trigger:{player:'useCard1'}, forced:true, @@ -5401,22 +5422,22 @@ game.import('character',function(lib,game,ui,get,ai,_status){ frequent:true, content:function(){ "step 0" - if(!player.storage.reluoshen) player.storage.reluoshen=[]; - if(event.cards==undefined) event.cards=[]; + player.addTempSkill('reluoshen_add'); + event.cards=[]; + "step 1" var next=player.judge(function(card){ if(get.color(card)=='black') return 1.5; return -1.5; }); if(get.mode()!='guozhan'&&!player.hasSkillTag('rejudge')) next.set('callback',function(){ if(event.judgeResult.color=='black'&&get.position(card,true)=='o'){ - player.storage.reluoshen.push(card); - player.gain(card,'gain2'); + player.gain(card,'gain2').gaintag.add('reluoshen'); } }); else next.set('callback',function(){ if(event.judgeResult.color=='black') event.getParent().orderingCards.remove(card); }); - "step 1" + "step 2" if(result.bool){ event.cards.push(result.card); player.chooseBool('是否再次发动【洛神】?').set('frequentSkill','reluoshen'); @@ -5429,14 +5450,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){ } } if(event.cards.length){ - player.gain(event.cards,'gain2'); - player.storage.reluoshen.addArray(event.cards); + player.gain(event.cards,'gain2').gaintag.add('reluoshen'); } event.finish(); } - "step 2" + "step 3" if(result.bool){ - event.goto(0); + event.goto(1); } else{ for(var i=0;i=0) return false; if(!arg.skill||!lib.skill[arg.skill]||lib.skill[arg.skill].charlotte||get.is.locked(arg.skill)||!arg.target.getSkills(true,false).contains(arg.skill)) return false; }, + directHit_ai:true, } }, reyicong:{ @@ -7017,7 +7037,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, content:function(){ trigger.directHit.addArray(game.players); - } + }, + ai:{ + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + return arg.card.name=='sha'&&get.color(arg.card)=='red'; + }, + }, }, zhuhai:{ trigger:{global:'phaseJieshuBegin'}, @@ -7460,7 +7486,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, content:function(){ "step 0" - target.chooseToUse({name:'sha'},'挑衅:对'+get.translation(player)+'使用一张杀,或令其弃置你的一张牌').set('targetRequired',true).set('complexSelect',true).set('filterTarget',function(card,player,target){ + target.chooseToUse(function(card,player,event){ + if(get.name(card)!='sha') return false; + return lib.filter.filterCard.apply(this,arguments); + },'挑衅:对'+get.translation(player)+'使用一张杀,或令其弃置你的一张牌').set('targetRequired',true).set('complexSelect',true).set('filterTarget',function(card,player,target){ if(target!=_status.event.sourcex&&!ui.selected.targets.contains(_status.event.sourcex)) return false; return lib.filter.filterTarget.apply(this,arguments); }).set('sourcex',player); @@ -8096,7 +8125,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ reguhuo_ally_bg:'真', reguhuo_betray_bg:'假', rehuashen:'化身', - rehuashen_info:'游戏开始后,你随机获得三张未加入游戏的武将牌,选一张置于你面前并声明该武将牌的一项技能,你拥有该技能且同时将性别和势力属性变成与该武将相同直到该化身被替换。你的每个准备阶段和结束后,你可以选择一项:①弃置至多两张未展示的化身牌并重新获得等量化身牌;②更换所展示的化身牌或技能。(你不可声明限定技、觉醒技或主公技)。', + rehuashen_info:'游戏开始后,你随机获得三张未加入游戏的武将牌,选一张置于你面前并声明该武将牌的一项技能,你拥有该技能且同时将性别和势力属性变成与该武将相同直到该化身被替换。你的每个准备阶段和结束后,你可以选择一项:①弃置至多两张未展示的化身牌并重新获得等量化身牌;②更换所展示的化身牌或技能。(你不可声明限定技、觉醒技、隐匿技、主公技等特殊技能)。', rexinsheng:'新生', rexinsheng_info:'当你受到1点伤害后,你可以获得一张新的化身牌。', re_zhurong:'界祝融', diff --git a/character/shenhua.js b/character/shenhua.js index 1cf7f101d..f3570ab75 100755 --- a/character/shenhua.js +++ b/character/shenhua.js @@ -1058,11 +1058,24 @@ game.import('character',function(lib,game,ui,get,ai,_status){ trigger:{ player:"useCard", }, - filter:function (event,player){ + filter:function(event,player){ return player.isPhaseUsing()&&(event.card.name=='sha'||get.type(event.card)=='trick'); }, - check:function(trigger,player){ - if(player.countCards('h')<=player.hp+1&&((get.type(trigger.card)=='trick'&&game.countPlayer(function(current){return get.attitude(current,player)<=0&¤t.countCards('h',{name:'wuxie'})})>0)||trigger.card.name=='sha')) return true; + check:function(event,player){ + if(['wuzhong','kaihua','dongzhuxianji'].contains(event.card.name)) return false; + player._wanglie_temp=true; + var eff=0; + for(var i of event.targets){ + eff+=get.effect(i,event.card,player,player); + } + delete player._wanglie_temp; + if(eff<0) return true; + if(!player.countCards('h',function(card){ + return player.hasValueTarget(card,null,true); + })) return true; + if(get.tag(event.card,'damage')&&!player.needsToDiscard()&&!player.countCards('h',function(card){ + return get.tag(card,'damage')&&player.hasValueTarget(card,null,true); + })) return true; return false; }, content:function(){ @@ -1070,6 +1083,35 @@ game.import('character',function(lib,game,ui,get,ai,_status){ trigger.directHit.addArray(game.players); player.addTempSkill('drlt_wanglie2'); }, + ai:{ + pretao:true, + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + if(player._wanglie_temp) return false; + player._wanglie_temp=true; + var bool=function(){ + if(['wuzhong','kaihua','dongzhuxianji'].contains(arg.card.name)) return false; + if(get.attitude(player,arg.target)>0||!player.isPhaseUsing()) return false; + var cards=player.getCards('h',function(card){ + return card!=arg.card&&(!arg.card.cards||!arg.card.cards.contains(card)); + }); + var sha=player.getCardUsable('sha'); + if(arg.card.name=='sha') sha--; + cards=cards.filter(function(card){ + if(card.name=='sha'&&sha<=0) return false; + return player.hasValueTarget(card,null,true); + }); + if(!cards.length) return true; + if(!get.tag(arg.card,'damage')) return false; + if(!player.needsToDiscard()&&!cards.filter(function(card){ + return get.tag(card,'damage'); + }).length) return true; + return false; + }(); + delete player._wanglie_temp; + return bool; + }, + }, }, "drlt_wanglie2":{ mod:{ @@ -1078,7 +1120,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, }, }, - liangyin:{ audio:2, group:["liangyin_1","liangyin_2"], @@ -2231,7 +2272,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, ai:{ unequip_ai:true, + directHit_ai:true, skillTagFilter:function(player,tag,arg){ + if(tag=='directHit_ai') return arg.card.name=='sha'&&arg.target.countCards('e',function(card){ + return get.value(card)>1; + })>0; if(arg&&arg.name=='sha'&&arg.target.getEquip(2)) return true; return false; } @@ -2748,7 +2793,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){ } }, ai:{ - threaten:0.5 + threaten:0.5, + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + if(get.attitude(player,arg.target)<=0&&arg.card.name=='sha'&&player.countCards('h',function(card){ + return card!=arg.card&&(!arg.card.cards||!arg.card.cards.contains(card)); + })>=arg.target.countCards('h')) return true; + return false; + }, } }, tiaoxin:{ @@ -2761,7 +2813,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, content:function(){ "step 0" - target.chooseToUse({name:'sha'},'挑衅:对'+get.translation(player)+'使用一张杀,或令其弃置你的一张牌').set('targetRequired',true).set('complexSelect',true).set('filterTarget',function(card,player,target){ + target.chooseToUse(function(card,player,event){ + if(get.name(card)!='sha') return false; + return lib.filter.filterCard.apply(this,arguments); + },'挑衅:对'+get.translation(player)+'使用一张杀,或令其弃置你的一张牌').set('targetRequired',true).set('complexSelect',true).set('filterTarget',function(card,player,target){ if(target!=_status.event.sourcex&&!ui.selected.targets.contains(_status.event.sourcex)) return false; return lib.filter.filterTarget.apply(this,arguments); }).set('sourcex',player); @@ -3707,7 +3762,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ var skills=lib.character[name][3].slice(0); for(var i=0;i1) return false; + }, + }, }, benghuai:{ audio:2, @@ -5917,7 +5978,15 @@ game.import('character',function(lib,game,ui,get,ai,_status){ attackFrom:function(from,to,distance){ if(get.zhu(from,'shouyue')) return distance-1; } - } + }, + ai:{ + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + if(get.attitude(player,arg.target)>0||arg.card.name!='sha') return false; + var length=arg.target.countCards('h'); + return (length>=player.hp||length<=player.getAttackRange()); + }, + }, }, kuanggu:{ audio:2, @@ -7402,7 +7471,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ beige_info:'当有角色受到【杀】造成的伤害后,你可以弃一张牌,并令其进行一次判定,若判定结果为:♥该角色回复1点体力;♦︎该角色摸两张牌;♣伤害来源弃两张牌;♠伤害来源将其武将牌翻面', duanchang_info:'锁定技,杀死你的角色失去当前的所有技能。', // fushen_info:'回合开始前,你可以选择与任意一名角色交换控制权,该角色可选择在下一个回合开始前与你换回', - huashen_info:'所有人都展示武将牌后,你随机获得两张未加入游戏的武将牌,选一张置于你面前并声明该武将的一项技能,你拥有该技能且同时将性别和势力属性变成与该武将相同直到该化身被替换。在你的每个准备阶段和结束后,你可以替换化身牌,你须为新的化身重新声明一项技能(你不可声明限定技、觉醒技或主公技)。', + huashen_info:'所有人都展示武将牌后,你随机获得两张未加入游戏的武将牌,选一张置于你面前并声明该武将的一项技能,你拥有该技能且同时将性别和势力属性变成与该武将相同直到该化身被替换。在你的每个准备阶段和结束后,你可以替换化身牌,你须为新的化身重新声明一项技能(你不可声明限定技、觉醒技、隐匿技、主公技等特殊技能)。', xinsheng_info:'每当你受到1点伤害后,你可获得一张新的化身牌。', jiangwei:'姜维', liushan:'刘禅', diff --git a/character/sp.js b/character/sp.js index 3c6408255..585a2c54e 100755 --- a/character/sp.js +++ b/character/sp.js @@ -566,7 +566,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ filter:function(event,player){ return event.player.getStockSkills('仲村由理','天下第一').filter(function(skill){ var info=get.info(skill); - return info&&!info.juexingji&&!info.zhuSkill&&!info.charlotte&&!info.limited; + return info&&!info.juexingji&&!info.hiddenSkill&&!info.zhuSkill&&!info.charlotte&&!info.limited; }).length>0; }, logTarget:'player', @@ -578,7 +578,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ player.awakenSkill('tuogu'); var list=trigger.player.getStockSkills('仲村由理','天下第一').filter(function(skill){ var info=get.info(skill); - return info&&!info.juexingji&&!info.zhuSkill&&!info.charlotte&&!info.limited; + return info&&!info.juexingji&&!info.hiddenSkill&&!info.zhuSkill&&!info.charlotte&&!info.limited; }); if(list.length==1) event._result={control:list[0]}; else trigger.player.chooseControl(list).set('prompt','选择令'+get.translation(player)+'获得一个技能').set('forceDie',true).set('ai',function(){ @@ -603,7 +603,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ filter:function(event,player){ return event.player.getStockSkills('仲村由理','天下第一').filter(function(skill){ var info=get.info(skill); - return info&&!info.juexingji&&!info.zhuSkill&&!info.charlotte&&!info.limited; + return info&&!info.juexingji&&!info.hiddenSkill&&!info.zhuSkill&&!info.charlotte&&!info.limited; }).length>0; }, logTarget:'player', @@ -611,7 +611,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ 'step 0' var list=trigger.player.getStockSkills('仲村由理','天下第一').filter(function(skill){ var info=get.info(skill); - return info&&!info.juexingji&&!info.zhuSkill&&!info.charlotte&&!info.limited; + return info&&!info.juexingji&&!info.hiddenSkill&&!info.zhuSkill&&!info.charlotte&&!info.limited; }); if(list.length==1) event._result={control:list[0]}; else trigger.player.chooseControl(list).set('prompt','选择令'+get.translation(player)+'获得一个技能').set('forceDie',true).set('ai',function(){ @@ -3095,11 +3095,25 @@ game.import('character',function(lib,game,ui,get,ai,_status){ } } }); - player.$throw(list); + player.$throw(list,1000); player.lose(list,ui.discardPile,'visible'); game.log(player,'将',list,'置入弃牌堆'); } }, + mark:{ + trigger:{ + player:'gainBegin', + global:'phaseBeginStart', + }, + silent:true, + filter:function(event,player){ + return event.name!='gain'||player!=_status.currentPhase; + }, + content:function(){ + if(trigger.name=='gain') trigger.gaintag.add('zishu'); + else player.removeGaintag('zishu'); + }, + }, draw:{ trigger:{player:'gainAfter'}, audio:"zishu", @@ -3117,7 +3131,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ threaten:1.2, nogain:1 }, - group:['zishu_draw','zishu_discard',] + group:['zishu_draw','zishu_discard','zishu_mark'] }, xinyingyuan:{ audio:'yingyuan', @@ -3504,6 +3518,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){ return current!=player&&get.distance(current,player)<=1; })); }, + ai:{ + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + return get.distance(arg.target,player)<=1; + }, + }, }, wylianji:{ enable:'phaseUse', @@ -4858,8 +4878,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ delay:false, filterCard:{name:'sha'}, content:function(){ - target.gain(cards,player,'giveAuto'); - target.storage.fuman3=cards[0]; + target.gain(cards,player,'giveAuto').gaintag.add('fuman'); target.storage.fuman2=player; target.addTempSkill('fuman2',{player:'phaseAfter'}); }, @@ -4879,13 +4898,20 @@ game.import('character',function(lib,game,ui,get,ai,_status){ fuman2:{ mod:{ aiOrder:function(player,card,num){ - if(card==player.storage.fuman3&&player.storage.fuman2.isIn()) return num+get.sgn(get.attitude(player,player.storage.fuman2)); + if(get.itemtype(card)=='card'&&card.hasGaintag('fuman')&&player.storage.fuman2.isIn()) return num+get.sgn(get.attitude(player,player.storage.fuman2)); }, }, trigger:{player:'useCard'}, forced:true, filter:function(event,player){ - return event.cards.contains(player.storage.fuman3)&&player.storage.fuman2.isIn(); + if(!player.storage.fuman2.isIn()) return false; + return player.getHistory('lose',function(evt){ + if(evt.getParent()!=event) return false; + for(var i in evt.gaintag_map){ + if(evt.gaintag_map[i].contains('fuman')) return true; + } + return false; + }).length>0; }, mark:true, intro:{ @@ -4900,7 +4926,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, onremove:function(player){ delete player.storage.fuman2; - delete player.storage.fuman3; + player.removeGaintag('fuman'); }, }, qizhou:{ @@ -5212,7 +5238,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ for(var i of list){ skills.addArray((lib.character[i][3]||[]).filter(function(skill){ var info=get.info(skill); - return info&&!info.zhuSkill&&!info.limited&&!info.juexingji&&!info.charlotte; + return info&&!info.zhuSkill&&!info.limited&&!info.juexingji&&!info.hiddenSkill&&!info.charlotte; })); } if(!list.length||!skills.length){event.finish();return;} @@ -5341,6 +5367,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ player:'damageEnd', }, forced:true, + locked:false, filter:function(event){ return event.card&&event.card.name=='sha'; }, @@ -5637,70 +5664,54 @@ game.import('character',function(lib,game,ui,get,ai,_status){ if(name=='phaseDiscard'&&get.color(card)=='black') return false; } }, - trigger:{global:'gainBegin'}, + trigger:{global:'gainAfter'}, forced:true, popup:false, filter:function(event,player){ - if(event.source==player&&event.player!=player){ - for(var i=0;i0; } return false; }, content:function(){ trigger.player.addSkill('xiehui2'); - if(!trigger.player.storage.xiehui2){ - trigger.player.storage.xiehui2=[]; - } - for(var i=0;i0) return 'cancel2'; - if(!source.storage.jilei2||!source.storage.jilei2.contains('basic')) return 'basic'; - if(_status.currentPhase!=source) return 'trick'; - if(lib.filter.cardUsable({name:'sha'},source)&&source.countCards('h')>=2) return 'basic'; - return 'trick'; + var list=['basic','trick','equip'].filter(function(name){ + return (!source.storage.jilei2||!source.storage.jilei2.contains(name)); + }); + if(!list.length) return 'cancel2'; + if(list.contains('trick')&&source.countCards('h',function(card){ + return get.type(card,source)=='trick'&&source.hasValueTarget(card); + })>1) return 'trick'; + return list[0]; }).set('prompt',get.prompt2('jilei',trigger.source)).set('source',trigger.source); 'step 1' if(result.control!='cancel2'){ @@ -15557,9 +15572,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){ olxingshen_info:'当你受到伤害后,你可以随机摸至多两张牌。若如此做,你获得X个“省”,且下一次发动〖严教〗展示牌时移去所有“省”并多展示等量的牌。(X为你已损失的体力值,且你至多拥有6个“省”)', caoshuang:'曹爽', tuogu:'托孤', - tuogu_info:'限定技,一名角色死亡时,你可以令其选择其武将牌上的一个技能(主公技,限定技,觉醒技等特殊技能除外),然后你获得其选择的技能。', + tuogu_info:'限定技,一名角色死亡时,你可以令其选择其武将牌上的一个技能(主公技,限定技,觉醒技,隐匿技等特殊技能除外),然后你获得其选择的技能。', retuogu:'托孤', - retuogu_info:'一名角色死亡时,你可以令其选择其武将牌上的一个技能(主公技,限定技,觉醒技等特殊技能除外),然后你获得其选择的技能并失去上次因〖托孤〗获得的技能。', + retuogu_info:'一名角色死亡时,你可以令其选择其武将牌上的一个技能(主公技,限定技,觉醒技,隐匿技等特殊技能除外),然后你获得其选择的技能并失去上次因〖托孤〗获得的技能。', shanzhuan:'擅专', shanzhuan_info:'当你对其他角色造成伤害后,若其判定区没有牌,则你你可以将其的一张牌置于其的判定区。若此牌不为延时锦囊牌且此牌为:红色,此牌视为【乐不思蜀】;黑色,此牌视为【兵粮寸断】。回合结束时,若你本回合内未造成伤害,你可摸一张牌。', spniluan:'逆乱', diff --git a/character/sp2.js b/character/sp2.js index a87caa2f1..d7418f42e 100644 --- a/character/sp2.js +++ b/character/sp2.js @@ -233,25 +233,20 @@ game.import('character',function(lib,game,ui,get,ai,_status){ content:function(){ 'step 0' player.addSkill('tairan2'); - if(!player.storage.tairan2) player.storage.tairan2={ - num:0, - cards:[], - }; + if(!player.storage.tairan2) player.storage.tairan2=0; var num=Math.min(player.maxHp,5)-player.hp; - if(num){ - player.storage.tairan2.num+=num; + if(num>0){ + player.storage.tairan2+=num; player.recover(num); } 'step 1' - player.drawTo(Math.min(player.maxHp,5)); - 'step 2' - if(get.itemtype(result)=='cards') player.storage.tairan2.cards.addArray(result); + player.drawTo(Math.min(player.maxHp,5)).gaintag=['tairan']; }, }, tairan2:{ mod:{ aiValue:function(player,card,num){ - if(player.storage.tairan2.cards.contains(card)) return num/10; + if(card.hasGaintag&&card.hasGaintag('tairan')) return num/10; }, }, audio:'tairan', @@ -261,12 +256,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){ onremove:true, content:function(){ var map=player.storage.tairan2; - if(map.num) player.loseHp(map.num); - var hs=player.getCards('h'); - var cards=map.cards.filter(function(card){ - return hs.contains(card); + if(map>0) player.loseHp(map); + var hs=player.getCards('h',function(card){ + return card.hasGaintag('tairan'); }); - if(cards.length) player.discard(cards); + if(hs.length) player.discard(hs); player.removeSkill('tairan2'); }, }, @@ -289,7 +283,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ event.card=card; player.gain(card,'gain2'); 'step 1' - if(player.getCards('h').contains(card)&&get.subtype(card)=='equip5') player.chooseUseTarget(card,true).nopopup=true; + if(player.getCards('h').contains(card)&&get.subtype(card)=='equip5') player.chooseUseTarget(card).nopopup=true; }, }, jyishi:{ @@ -444,11 +438,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){ 'step 1' player.showCards(result.cards); var type=get.type2(result.cards[0],target); - if(!target.storage.choufa2) target.storage.choufa2=[]; - target.storage.choufa2.addArray(target.getCards('h',function(card){ + var cards=target.getCards('h',function(card){ return get.type2(card,target)!=type; - })); - if(target.storage.choufa2.length) target.addTempSkill('choufa2',{player:'phaseAfter'}); + }); + if(cards.length){ + target.addTempSkill('choufa2',{player:'phaseAfter'}); + target.addGaintag(cards,'choufa'); + } }, ai:{ order:9, @@ -460,22 +456,18 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, }, choufa2:{ - onremove:true, + onremove:function(player){ + player.removeGaintag('choufa'); + }, charlotte:true, mod:{ cardname:function(card,player){ - if(player.storage.choufa2.contains(card)) return 'sha'; + if(card.hasGaintag('choufa')) return 'sha'; }, cardnature:function(card,player){ - if(player.storage.choufa2.contains(card)) return false; + if(card.hasGaintag('choufa')) return false; }, }, - trigger:{player:'loseEnd'}, - silent:true, - content:function(){ - player.storage.choufa2.removeArray(trigger.hs); - if(!player.storage.choufa2.length) player.removeSkill('choufa2'); - }, }, zhaoran:{ audio:2, @@ -631,21 +623,24 @@ game.import('character',function(lib,game,ui,get,ai,_status){ var next=player.chooseButton(true); next.set('dialog',event.videoId); next.set('ai',function(button){ + if(_status.event.answer) return button.link==_status.event.answer?1:0; return get.value(button.link,_status.event.player); }); + if(player.hasSkillTag('viewHandcard',null,target,true)) next.set('answer',card); 'step 3' game.broadcastAll('closeDialog',event.videoId); + player.addTempSkill('yanxi2'); var card2=result.links[0]; if(card2==card){ player.popup('洗具'); cards.remove(card2); player.$gain2(cards); - player.gain(cards,'log'); - player.gain(card,target,'bySelf','giveAuto'); + player.gain(cards,'log').gaintag.add('yanxi'); + player.gain(card,target,'bySelf','giveAuto').gaintag.add('yanxi'); } else{ player.popup('杯具'); - player.gain(card2,'gain2'); + player.gain(card2,'gain2').gaintag.add('yanxi'); } }, ai:{ @@ -656,6 +651,19 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, }, }, + yanxi2:{ + mod:{ + ignoredHandcard:function(card,player){ + if(card.hasGaintag('yanxi')) return true; + }, + cardDiscardable:function(card,player,name){ + if(name=='phaseDiscard'&&card.hasGaintag('yanxi')) return false; + }, + }, + onremove:function(player){ + player.removeGaintag('yanxi'); + }, + }, sanchen:{ enable:'phaseUse', usable:1, @@ -722,6 +730,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ player.loseMaxHp(); player.addSkillLog('pozhu'); }, + derivation:'pozhu', }, pozhu:{ enable:'phaseUse', @@ -772,10 +781,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){ forced:true, filter:function(event,player){ var stat=player.getStat(); - return stat.kill&&stat.kill>0||stat.damage&&stat.damage>1; + return stat.damage&&stat.damage>0; }, content:function(){ - player.addMark('xijue',1); + player.addMark('xijue',player.getStat().damage); }, }, xijue_tuxi:{ @@ -829,11 +838,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){ direct:true, content:function(){ "step 0" - var nono=(Math.abs(get.attitude(player,trigger.player))<3||trigger.player.hp>1||trigger.player.countCards('e')); + var nono=(Math.abs(get.attitude(player,trigger.player))<3||trigger.player.hp>(player.countMark('xijue')*1.5)||trigger.player.countCards('e',function(card){ + return get.value(card,trigger.player)<=0; + })); if(get.damageEffect(trigger.player,player,player)<=0){ nono=true; } - var next=player.chooseToDiscard('是否弃置一枚“爵”,对'+get.translation(trigger.player)+'发动【骁果】?',{type:'basic'}); + var next=player.chooseToDiscard('是否弃置一枚“爵”和一张基本牌,对'+get.translation(trigger.player)+'发动【骁果】?',{type:'basic'}); next.set('ai',function(card){ if(_status.event.nono) return 0; return 8-get.useful(card); @@ -1022,6 +1033,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){ return current!=player&&get.distance(player,current)<=1; })); }, + ai:{ + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + return get.distance(player,arg.target)<=1; + }, + }, }, zhuide:{ audio:2, @@ -1298,8 +1315,16 @@ game.import('character',function(lib,game,ui,get,ai,_status){ 'step 1' if(result.bool){ player.useCard(get.autoViewAs({name:'sha',nature:'ice'},result.cards),result.cards,false,trigger.player,'qingleng'); + if(!player.storage.qingleng||!player.storage.qingleng.contains(trigger.player)){ + player.draw(); + player.markAuto('qingleng',[trigger.player]); + player.storage.qingleng.sortBySeat(); + } } }, + intro:{ + content:'已对$发动过此技能', + }, }, xuanmu:{ audio:2, @@ -2103,13 +2128,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, position:'he', content:function(){ - 'step 0' - player.draw(cards.length*2); - 'step 1' - if(get.itemtype(result)=='cards'){ - player.addTempSkill('minsi2'); - player.markAuto('minsi2',result); - } + player.draw(cards.length*2).gaintag=['minsi2']; + player.addTempSkill('minsi2'); }, ai:{ order:5, @@ -2117,41 +2137,29 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, }, minsi2:{ - intro:{ - mark:function(dialog,content,player){ - if(content&&content.length){ - if(player==game.me||player.isUnderControl()){ - dialog.addAuto(content); - } - else{ - return '本回合以此法获得了'+get.cnNumber(content.length)+'张牌'; - } - } - }, - content:'cards', + onremove:function(player){ + player.removeGaintag('minsi2'); }, - onremove:true, mod:{ targetInRange:function(card,player,target){ if(!card.cards) return; - var storage=player.getStorage('minsi2'); for(var i of card.cards){ - if(!storage.contains(i)||get.color(i)!='black') return; + if(!i.hasGaintag('minsi2')||get.color(i)!='black') return; } return true; }, ignoredHandcard:function(card,player){ - if(player.getStorage('minsi2').contains(card)&&get.color(card)=='red'){ + if(card.hasGaintag('minsi2')&&get.color(card)=='red'){ return true; } }, cardDiscardable:function(card,player,name){ - if(name=='phaseDiscard'&&player.getStorage('minsi2').contains(card)&&get.color(card)=='red'){ + if(name=='phaseDiscard'&&card.hasGaintag('minsi2')&&get.color(card)=='red'){ return false; } }, aiOrder:function(player,card,num){ - if(player.getStorage('minsi2').contains(card)&&get.color(card)=='black') return num-0.1; + if(get.itemtype(card)=='card'&&card.hasGaintag('minsi2')&&get.color(card)=='black') return num-0.1; }, }, }, @@ -2243,16 +2251,30 @@ game.import('character',function(lib,game,ui,get,ai,_status){ } event.finish(); 'step 2' + var list=game.filterPlayer(function(current){ + return current.hasSkill('panshi'); + }); player.chooseCardTarget({ prompt:get.prompt('cixiao'), - prompt2:('弃置一张牌并将'+get.translation(game.filterPlayer(function(current){ - return current.hasSkill('panshi'); - }))+'的「义子」标记转移给其他角色'), + prompt2:('弃置一张牌并将'+get.translation(list)+'的「义子」标记转移给其他角色'), position:'he', filterTarget:function(card,player,target){ return player!=target&&!target.hasSkill('panshi'); }, filterCard:lib.filter.cardDiscardable, + ai1:function(card){ + if(_status.event.goon) return 5-get.value(card); + return 0; + }, + ai2:function(target){ + var player=_status.event.player; + var att=-get.attitude(player,target); + return att*target.countCards('h'); + }, + goon:function(target){ + var att=-get.attitude(player,target); + return att*target.countCards('h')<=0; + }(list[0]), }); 'step 3' if(result.bool){ @@ -4253,7 +4275,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ var max=0; var min=1; target.countCards('e',function(card){ - var val=get.value(card); + var val=get.value(card,target); if(val>max) max=val; if(val0) return -1; @@ -4521,13 +4543,19 @@ game.import('character',function(lib,game,ui,get,ai,_status){ if(target.isAlive()&&!result.bool) target.addTempSkill('xiying2'); if(targets.length) event.goto(2); }, + ai:{ + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + return arg.target.hasSkill('xiying2'); + }, + }, }, xiying2:{ mark:true, intro:{content:'本回合内不能使用或打出牌'}, mod:{ - cardEnabled2:function (card){ - if(get.position(card)=='h') return false; + cardEnabled2:function(card){ + return false; }, }, }, @@ -5737,7 +5765,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ game.expandSkills(list2); for(var k=0;k0&&event.player.countCards('he')>0; }, forced:true, logTarget:'player', - content:function (){ + content:function(){ trigger.player.chooseToDiscard(2,true,'he'); }, sub:true, @@ -7362,13 +7397,15 @@ game.import('character',function(lib,game,ui,get,ai,_status){ player:"phaseZhunbeiBegin", }, forced:true, - filter:function (event,player){ - if(!player.storage.xinfu_bijing)return false; - return player.getCards('h').contains(player.storage.xinfu_bijing); + filter:function(event,player){ + return player.getCards('h',function(card){ + return card.hasGaintag('xinfu_bijing'); + }).length>0; }, content:function (){ - player.discard(player.storage.xinfu_bijing); - delete player.storage.xinfu_bijing; + player.discard(player.getCards('h',function(card){ + return card.hasGaintag('xinfu_bijing'); + })); }, sub:true, }, @@ -7389,8 +7426,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ 'step 1' if(result.bool){ player.logSkill('xinfu_bijing'); - //player.showCards(result.cards); - player.storage.xinfu_bijing=result.cards[0]; + player.addGaintag(result.cards,'xinfu_bijing'); } }, }, @@ -8275,7 +8311,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ gaolan:'高览', xiying:'袭营', xiying2:'袭营', - xiying_info:'出牌阶段开始时,你可以弃置一张非基本手牌,然后令所有其他角色依次选择一项:弃置一张牌,或本回合内不能使用或打出手牌。', + xiying_info:'出牌阶段开始时,你可以弃置一张非基本手牌,然后令所有其他角色依次选择一项:弃置一张牌,或本回合内不能使用或打出牌。', lvkuanglvxiang:'吕旷吕翔', liehou:'列侯', liehou_info:'出牌阶段限一次,你可以令一名攻击范围内的角色交给你一张手牌,然后你将一张手牌交给攻击范围内的另一名角色。', @@ -8476,7 +8512,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ huishi:'慧识', huishi_info:'摸牌阶段,你可以放弃摸牌,改为观看牌堆顶的X张牌,获得其中的一半(向下取整),然后将其余牌置入牌堆底。(X为牌堆数量的个位数)', qingleng:'清冷', - qingleng_info:'一名角色的回合结束时,若其体力值与手牌数之和不小于X,你可将一张牌当无距离限制的冰属性【杀】对其使用。(X为牌堆数量的个位数)', + qingleng_info:'一名角色的回合结束时,若其体力值与手牌数之和不小于X,则你可将一张牌当无距离限制的冰属性【杀】对其使用(X为牌堆数量的个位数)。若你本局游戏内未对其发动过此技能,则你摸一张牌。', xuanmu:'宣穆', xuanmu2:'宣穆', xuanmu_info:'锁定技,隐匿技。你于其他角色的回合登场时,防止你受到的伤害直到回合结束。', @@ -8510,7 +8546,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ zhanghuyuechen:'张虎乐綝', xijue:'袭爵', xijue_gain:'袭爵', - xijue_info:'锁定技,游戏开始时,你获得4枚“爵”。回合结束时,若你于本回合内造成过的伤害点数总和大于1,或于本回合内杀死过角色,则你获得一枚“爵”。你可弃置一枚“爵”并在合适的时机发动〖突袭〗和〖骁果〗。', + xijue_info:'锁定技,游戏开始时,你获得4枚“爵”。回合结束时,你获得X枚“爵”(X为你本回合内造成的伤害数)。你可弃置一枚“爵”并在合适的时机发动〖突袭〗和〖骁果〗。', xijue_tuxi:'突袭', xijue_xiaoguo:'骁果', duyu:'杜预', @@ -8525,7 +8561,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){ shiren:'识人', shiren_info:'隐匿技。你于其他角色的回合内登场时,若其有手牌,则你可对其发动〖宴戏〗。', yanxi:'宴戏', - yanxi_info:'出牌阶段,你可选择一名有手牌的角色。你将该角色的一张随机手牌与牌堆顶的两张牌混合后展示,并选择其中一张。若你以此法选择的是该角色的手牌,则你获得这三张牌。否则你获得选择的牌。', + yanxi2:'宴戏', + yanxi_info:'出牌阶段,你可选择一名有手牌的角色。你将该角色的一张随机手牌与牌堆顶的两张牌混合后展示,并选择其中一张。若你以此法选择的是该角色的手牌,则你获得这三张牌。否则你获得选择的牌。你通过〖宴戏〗获得的牌,不计入当前回合的手牌上限。', jin_simazhao:'晋司马昭', jin_simazhao_ab:'司马昭', tuishi:'推弑', @@ -8541,7 +8578,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ jin_xiahouhui:'晋夏侯徽', jin_xiahouhui_ab:'夏侯徽', baoqie:'宝箧', - baoqie_info:'隐匿技,锁定技。你登场后,从牌堆中获得一张不为赠物的宝物牌。若此牌在你的手牌区内为宝物牌,则你使用此牌。', + baoqie_info:'隐匿技,锁定技。你登场后,从牌堆中获得一张不为赠物的宝物牌。若此牌在你的手牌区内为宝物牌,则你可以使用此牌。', jyishi:'宜室', jyishi_info:'每回合限一次,当有其他角色于其出牌阶段内因弃置而失去手牌后,你可令其获得这些牌中位于弃牌堆的一张,然后你获得其余位于弃牌堆的牌。', shiduo:'识度', diff --git a/character/standard.js b/character/standard.js index 334b02bd8..7a7d522ec 100755 --- a/character/standard.js +++ b/character/standard.js @@ -1594,7 +1594,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){ if(result.bool){ trigger.getParent().directHit.add(trigger.target); } - } + }, + ai:{ + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + if(get.attitude(player,arg.target)>0||arg.card.name!='sha'||!ui.cardPile.firstChild||get.color(ui.cardPile.firstChild,player)!='red') return false; + }, + }, }, jizhi:{ audio:2, @@ -2397,7 +2403,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){ else{ map[id].shanRequired=2; } - } + }, + ai:{ + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + if(arg.card.name!='sha'||arg.target.countCards('h','shan')>1) return false; + }, + }, }, wushuang2:{ audio:'wushuang', @@ -2421,10 +2433,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){ map[idt].shaReq[id]++; }, ai:{ - result:{ - target:function(card,player,target){ - if(card.name=='juedou'&&target.countCards('h')>0) return [1,0,0,-1]; - } + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + if(arg.card.name!='juedou'||Math.floor(arg.target.countCards('h','sha')/2)>player.countCards('h','sha')) return false; } } }, @@ -2683,7 +2694,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ xiahoudun:['re_xiahoudun','sp_xiahoudun','xin_xiahoudun','xiahoudun'], liubei:['re_liubei','sp_liubei','liubei'], guanyu:['re_guanyu','jsp_guanyu','guanyu'], - zhangfei:['re_zhangfei','sp_zhangfei','old_zhangfei','zhangfei'], + zhangfei:['re_zhangfei','sp_zhangfei','xin_zhangfei','old_zhangfei','zhangfei'], zhaoyun:['re_zhaoyun','sp_zhaoyun','jsp_zhaoyun','old_zhaoyun','zhaoyun'], machao:['re_machao','sp_machao','machao','old_machao'], zhugeliang:['re_zhugeliang','zhugeliang'], diff --git a/character/yijiang.js b/character/yijiang.js index a8316b0e4..60428c4c8 100755 --- a/character/yijiang.js +++ b/character/yijiang.js @@ -606,20 +606,32 @@ game.import('character',function(lib,game,ui,get,ai,_status){ case 0:{ if(game.hasPlayer(function(current){ return lib.filter.targetEnabled2(event.card,player,current)&&!event.targets.contains(current)&&get.effect(current,event.card,player,player)>0; - })) return 1.2+Math.random(); + })) return 1.6+Math.random(); return 0; } case 1:{ + if(event.targets.filter(function(current){ + var eff1=get.effect(current,event.card,player,player); + player._xinbenxi_ai=true; + var eff2=get.effect(current,event.card,player,player); + delete player._xinbenxi_ai; + return eff1>eff2; + }).length) return 1.9+Math.random(); return Math.random(); } case 2:{ - if(event.card.name=='sha'||event.card.name=='juedou'||get.type(event.type)=='trick'&&game.hasPlayer(function(current){ - return get.attitude(current,player)<0&¤t.hasWuxie(); - })) return 1+Math.random(); - return Math.random(); + var num=1.3; + if(event.card.name=='sha'&&event.targets.filter(function(current){ + if(current.mayHaveShan()&&get.attitude(player,current)<=0){ + if(current.hasSkillTag('useShan')) num=1.9; + return true; + } + return false; + }).length) return num+Math.random(); + return 0.5+Math.random(); } case 3:{ - return get.tag(event.card,'damage')+Math.random(); + return (get.tag(event.card,'damage')||0)+Math.random(); } } }); @@ -665,17 +677,21 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, ai:{ unequip:true, - //norespond:true, + unequip_ai:true, + directHit_ai:true, skillTagFilter:function(player,tag,arg){ if(tag=='unequip'){ if(arg&&player.storage.xinbenxi_unequip.contains(arg.card)) return true; return false; } - if(tag=='norespond'&&Array.isArray(arg)){ - var evt=arg[2].getParent(); - if(evt.type=='card'&&player.storage.xinbenxi_directHit.contains(evt.card)) return true; - return false; - } + if(_status.currentPhase!=player||game.hasPlayer(function(current){ + return get.distance(player,current)>1; + })) return false; + if(tag=='directHit_ai') return arg.card.name=='sha'; + if(arg.card.name!='sha'&&arg.card.name!='chuqibuyi') return false; + var card=arg.target.getEquip(2); + if(card&&card.name.indexOf('bagua')!=-1) return true; + if(player._xinbenxi_ai) return false; }, }, subSkill:{ @@ -2022,12 +2038,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){ if(get.itemtype(trigger.respondTo[1])=='card') cards.push(trigger.respondTo[1]); else if(trigger.respondTo[1].cards) cards.addArray(trigger.respondTo[1].cards); cards=cards.filterInD('od'); - trigger.player.gain(cards,'gain2','log'); + trigger.player.gain(cards,'gain2','log').gaintag.add('funan'); trigger.player.addTempSkill('funan_use'); - if(!trigger.player.storage.funan_use){ - trigger.player.storage.funan_use=[]; - } - trigger.player.storage.funan_use.addArray(cards); } 'step 1' var cards=trigger.cards.filterInD('od'); @@ -2042,10 +2054,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, }, use:{ - onremove:true, + onremove:function(player){ + player.removeGaintag('funan'); + }, + charlotte:true, mod:{ cardEnabled2:function(card,player){ - if(player.storage.funan_use&&player.storage.funan_use.contains(card)){ + if(get.itemtype(card)=='card'&&card.hasGaintag('funan')){ return false; } } @@ -2147,6 +2162,28 @@ game.import('character',function(lib,game,ui,get,ai,_status){ } }, ai:{ + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + if(player._zhuandui_temp) return false; + player._zhuandui_temp=true; + var bool=function(){ + if(arg.card.name!='sha'||get.attitude(player,arg.target)>=0||!arg.target.countCards('h')) return false; + if(arg.target.countCards('h')==1&&(!arg.target.getEquip('bagua')||player.hasSkillTag('unequip',false,{ + name:arg.card?arg.card.name:null, + target:arg.target, + card:arg.card + })||player.hasSkillTag('unequip_ai',false,{ + name:arg.card?arg.card.name:null, + target:arg.target, + card:arg.card + }))) return true; + return player.countCards('h',function(card){ + return card!=arg.card&&(!arg.card.cards||!arg.card.cards.contains(card))&&get.value(card)<=4&&(card.number>=(11+arg.target.countCards('h')/2)||get.suit(card,player)=='heart'); + })>0; + }(); + delete player._zhuandui_temp; + return bool; + }, effect:{ target:function(card,player,target,current){ if(card.name=='sha'&¤t<0) return 0.7; @@ -2161,7 +2198,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ var player=_status.event.player; return (!player.hasCard(function(card){ var val=get.value(card); - return val<0||(val<=4&&card.number>=11); + return val<0||(val<=4&&(card.number>=11||get.suit(card)=='heart')); },'h'))?20:0; }, filter:function(event){ @@ -4697,15 +4734,15 @@ game.import('character',function(lib,game,ui,get,ai,_status){ group:['fulin_count','fulin_reset'], subSkill:{ reset:{ - trigger:{player:['phaseZhunbeiBegin','phaseJieshuBegin']}, + trigger:{player:['phaseBefore','phaseAfter']}, silent:true, priority:10, content:function(){ - player.storage.fulin=[]; + player.removeGaintag('fulin'); } }, count:{ - trigger:{player:'gainEnd'}, + trigger:{player:'gainBegin'}, audio:'fulin', forced:true, silent:true, @@ -4713,25 +4750,23 @@ game.import('character',function(lib,game,ui,get,ai,_status){ return _status.currentPhase==player; }, content:function(){ - if(!player.storage.fulin){ - player.storage.fulin=[]; - } - for(var i=0;i=3||target.countCards('h')>=3) return 'zeroplayertarget'; if(player.countCards('h','tao')) return 'zeroplayertarget'; if(target.countCards('h','sha')>1) return 'zeroplayertarget'; @@ -7761,7 +7800,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){ }, ai:{ unequip_ai:true, + directHit_ai:true, skillTagFilter:function(player,tag,arg){ + if(get.attitude(player,arg.target)>0||!player.isPhaseUsing()) return false; + if(tag=='directHit_ai') return arg.target.hp>=Math.max(1,arg.target.countCards('h')-1); if(arg&&arg.name=='sha'&&arg.target.getEquip(2)) return true; return false; } @@ -8260,6 +8302,22 @@ game.import('character',function(lib,game,ui,get,ai,_status){ game.addVideo('storage',result.targets[0],['qianxi2',event.color]); } }, + ai:{ + directHit_ai:true, + skillTagFilter:function(player,tag,arg){ + if(!arg.target.hasSkill('qianxi2')) return false; + if(arg.card.name=='sha') return arg.target.storage.qianxi2=='red'&&(!arg.target.getEquip('bagua')||player.hasSkillTag('unequip',false,{ + name:arg.card?arg.card.name:null, + target:arg.target, + card:arg.card + })||player.hasSkillTag('unequip_ai',false,{ + name:arg.card?arg.card.name:null, + target:arg.target, + card:arg.card + })); + return arg.target.storage.qianxi2=='black'; + } + }, }, qianxi2:{ //trigger:{global:'phaseAfter'}, diff --git a/game/asset.js b/game/asset.js index 44ec4c943..3cc94a2a0 100644 --- a/game/asset.js +++ b/game/asset.js @@ -1,5 +1,5 @@ window.noname_asset_list=[ - 'v1.9.108.2.2', + 'v1.9.108.3', 'audio/background/aozhan_chaoming.mp3', 'audio/background/aozhan_online.mp3', 'audio/background/aozhan_rewrite.mp3', @@ -3657,6 +3657,7 @@ window.noname_asset_list=[ 'image/character/jin_xiahouhui.jpg', 'image/character/zhanghuyuechen.jpg', 'image/character/zhangling.jpg', + 'image/character/xin_zhangfei.jpg', 'image/character/baiwuchang.jpg', 'image/character/baosanniang.jpg', diff --git a/game/game.js b/game/game.js index e9b4d87d6..6248402f4 100644 --- a/game/game.js +++ b/game/game.js @@ -13776,7 +13776,8 @@ else{ event.targets[1].addJudge(link); } - event.targets[0].$give(link,event.targets[1]) + event.targets[0].$give(link,event.targets[1],false); + game.log(event.targets[0],'的',link,'被移动给了',event.targets[1]) event.result.card=link; event.result.position=get.position(link); game.delay(); @@ -14477,20 +14478,21 @@ } if(event.animate!=false){ if(event.visible){ - player.gain(cards,'gain2'); + var next=player.gain(cards,'gain2'); if(event.bottom) game.log(player,'从牌堆底摸了'+get.cnNumber(num)+'张牌(',cards,')'); else game.log(player,'摸了'+get.cnNumber(num)+'张牌(',cards,')'); } else{ - player.gain(cards,'draw'); + var next=player.gain(cards,'draw'); } } else{ - player.gain(cards); + var next=player.gain(cards); if(event.$draw){ player.$draw(cards.length); } } + if(event.gaintag) next.gaintag.addArray(event.gaintag); event.result=cards; }, discard:function(){ @@ -14673,6 +14675,7 @@ if(lib.config.reverse_sort) sort=-sort; cards[num].fix(); cards[num].style.transform=''; + cards[num].addGaintag(event.gaintag); if(_status.discarded){ _status.discarded.remove(cards[num]); } @@ -14690,14 +14693,14 @@ } var addv=function(){ if(player==game.me){ - game.addVideo('gain12',player,[get.cardsInfo(frag1.childNodes),get.cardsInfo(frag2.childNodes)]); + game.addVideo('gain12',player,[get.cardsInfo(frag1.childNodes),get.cardsInfo(frag2.childNodes),event.gaintag]); } }; var broadcast=function(){ - game.broadcast(function(player,cards,num){ - player.directgain(cards); + game.broadcast(function(player,cards,num,gaintag){ + player.directgain(cards,null,gaintag); _status.cardPileNum=num; - },player,cards,ui.cardPile.childNodes.length); + },player,cards,ui.cardPile.childNodes.length,event.gaintag); }; if(event.animate=='draw'){ player.$draw(cards.length); @@ -14819,10 +14822,15 @@ } } "step 1" + event.gaintag_map={}; var hs=[],es=[],js=[]; var hej=player.getCards('hej'); event.stockcards=cards.slice(0); for(var i=0;i1){ - return -get.number(card)-get.value(card)/2+addi; + var getn=function(card){ + if(player.hasSkill('tianbian')&&get.suit(card)=='heart') return 13; + return get.number(card); } - return get.number(card)-get.value(card)/2+addi; + if(source&&source!=player&&get.attitude(player,source)>1){ + return -getn(card)-get.value(card)/2+addi; + } + return getn(card)-get.value(card)/2+addi; } next.setContent('chooseToCompareMultiple'); } @@ -18106,21 +18138,25 @@ return ais(); } var player=get.owner(card); + var getn=function(card){ + if(player.hasSkill('tianbian')&&get.suit(card)=='heart') return 13; + return get.number(card); + } var event=_status.event.getParent(); var to=(player==event.player?event.target:event.player); var addi=(get.value(card)>=8&&get.type(card)!='equip')?-10:0; if(card.name=='du') addi+=5; if(player==event.player){ if(get.attitude(player,to)>0&&event.small){ - return -get.number(card)-get.value(card)/2+addi; + return -getn(card)-get.value(card)/2+addi; } - return get.number(card)-get.value(card)/2+addi; + return getn(card)-get.value(card)/2+addi; } else{ if(get.attitude(player,to)>0&&!event.small){ - return -get.number(card)-get.value(card)/2+addi; + return -getn(card)-get.value(card)/2+addi; } - return get.number(card)-get.value(card)/2+addi; + return getn(card)-get.value(card)/2+addi; } } next.setContent('chooseToCompare'); @@ -19159,7 +19195,7 @@ game.addVideo('directequip',this,get.cardsInfo(cards)); } }, - directgain:function(cards,broadcast){ + directgain:function(cards,broadcast,gaintag){ var hs=this.getCards('h'); for(var i=0;i0) return map; }; + next.gaintag=[]; return next; }, give:function(cards,target,visible){ @@ -23366,6 +23404,28 @@ } }, card:{ + addGaintag:function(gaintag){ + if(Array.isArray(gaintag)) this.gaintag=gaintag.slice(0); + else this.gaintag.add(gaintag); + var str=''; + for(var gi=0;gi.background.land { text-shadow: rgba(213, 194, 179,1) 0 0 3px,rgba(213, 194, 179,1) 0 0 3px,rgba(213, 194, 179,1) 0 0 3px, rgba(213, 194, 179,1) 0 0 3px,black 0 0 3px; } +.card>.gaintag { + bottom: 5px; + left: 5px; + text-align: left; + color: white; + text-shadow: rgba(255, 120, 0,1) 0 0 2px,rgba(255, 120, 0,1) 0 0 2px,rgba(255, 120, 0,1) 0 0 2px, + rgba(255, 120, 0,1) 0 0 2px,black 0 0 1px; +} .card>.name { top: 9px; left: 6px; @@ -3363,6 +3371,7 @@ div:not(.handcards)>.card>.info>span, #arena.selecting:not(.video) .player[data-position='0'] .card:not(.selectable)>.name2, #arena.selecting:not(.video) .player[data-position='0'] .card:not(.selectable)>.info, #arena.selecting:not(.video) .player[data-position='0'] .card:not(.selectable)>.range, +#arena.selecting:not(.video) .player[data-position='0'] .card:not(.selectable)>.gaintag, #arena.selecting:not(.video) .player[data-position='0'] .card:not(.selectable)>.addinfo, #arena.selecting:not(.video) .player.current_action .card:not(.selectable)>.background, #arena.selecting:not(.video) .player.current_action .card:not(.selectable)>.image, @@ -3370,6 +3379,7 @@ div:not(.handcards)>.card>.info>span, #arena.selecting:not(.video) .player.current_action .card:not(.selectable)>.name2, #arena.selecting:not(.video) .player.current_action .card:not(.selectable)>.info, #arena.selecting:not(.video) .player.current_action .card:not(.selectable)>.range, +#arena.selecting:not(.video) .player.current_action .card:not(.selectable)>.gaintag, #arena.selecting:not(.video) .player.current_action .card:not(.selectable)>.addinfo, #arena.selecting:not(.video) #me .card:not(.selectable)>.background, #arena.selecting:not(.video) #me .card:not(.selectable)>.image, @@ -3377,6 +3387,7 @@ div:not(.handcards)>.card>.info>span, #arena.selecting:not(.video) #me .card:not(.selectable)>.name2, #arena.selecting:not(.video) #me .card:not(.selectable)>.info, #arena.selecting:not(.video) #me .card:not(.selectable)>.range, +#arena.selecting:not(.video) #me .card:not(.selectable)>.gaintag, #arena.selecting:not(.video) #me .card:not(.selectable)>.addinfo, #arena.selecting:not(.video) .dialog:not(.noselect) .button:not(.selectable):not(.noclick):not(.replaceButton), .dead,.likedead { @@ -3461,6 +3472,7 @@ div:not(.handcards)>.card>.info>span, .card.selectable>.name2, .card.selectable>.info, .card.selectable>.range, +.card.selectable>.gaintag, .button.selectable { opacity: 1; } diff --git a/mode/guozhan.js b/mode/guozhan.js index 1793280ad..853399738 100644 --- a/mode/guozhan.js +++ b/mode/guozhan.js @@ -6036,6 +6036,10 @@ game.import('mode',function(lib,game,ui,get,ai,_status){ content:function(){ if(trigger.name=='addJudge'){ trigger.cancel(); + var owner=get.owner(trigger.card); + if(owner&&owner.getCards('hej').contains(trigger.card)) owner.lose(trigger.card,ui.discardPile); + else game.cardsDiscard(trigger.card); + game.log(trigger.card,'进入了弃牌堆'); } else trigger.getParent().targets.remove(player); }, @@ -6049,7 +6053,10 @@ game.import('mode',function(lib,game,ui,get,ai,_status){ }, gzqianxun:{ audio:'qianxun', - trigger:{target:'useCardToTarget',player:'addJudgeBefore'}, + trigger:{ + target:'useCardToTarget', + player:'addJudgeBefore', + }, forced:true, priority:15, check:function(event,player){ @@ -6061,6 +6068,10 @@ game.import('mode',function(lib,game,ui,get,ai,_status){ content:function(){ if(trigger.name=='addJudge'){ trigger.cancel(); + var owner=get.owner(trigger.card); + if(owner&&owner.getCards('hej').contains(trigger.card)) owner.lose(trigger.card,ui.discardPile); + else game.cardsDiscard(trigger.card); + game.log(trigger.card,'进入了弃牌堆'); } else trigger.getParent().targets.remove(player); },