v1.9.93.3

This commit is contained in:
Spmario233 2019-10-09 22:31:43 +08:00 committed by GitHub
parent 56b782eff4
commit 373cbcfe9c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
22 changed files with 837 additions and 368 deletions

View File

@ -884,11 +884,9 @@ game.import('card',function(lib,game,ui,get,ai,_status){
},
audio:true,
check:function(event,player){
var att=get.attitude(player,event.target);
if(event.target.hasSkillTag('nofire')){
return att>0;
}
return att<=0;
var eff1=get.effect(event.target,event.card,player,player);
var eff2=get.effect(event.target,{name:'sha',nature:'fire',suit:get.suit(event.card),number:get.number(event,card)},player,player);
return eff2>eff1;
},
content:function(){
trigger.card.nature='fire';

View File

@ -304,6 +304,7 @@ game.import('card',function(lib,game,ui,get,ai,_status){
var evt=event.getParent();
if(evt&&evt.targets&&evt.targets.contains(player)){
evt.fixedSeat=true;
evt.targets.sortBySeat();
evt.targets.remove(player);
evt.targets.push(player);
}
@ -366,6 +367,7 @@ game.import('card',function(lib,game,ui,get,ai,_status){
type:'trick',
enable:true,
mode:['guozhan'],
global:['g_chiling1','g_chiling2','g_chiling3'],
filterTarget:function(card,player,target){
return target.isUnseen();
},
@ -1089,7 +1091,7 @@ game.import('card',function(lib,game,ui,get,ai,_status){
}
},
},
_chiling1:{
g_chiling1:{
mode:['guozhan'],
trigger:{player:'discardAfter'},
filter:function(event,player){
@ -1118,7 +1120,7 @@ game.import('card',function(lib,game,ui,get,ai,_status){
}
},
},
_chiling2:{
g_chiling2:{
mode:['guozhan'],
trigger:{player:'judgeAfter'},
forced:true,
@ -1133,7 +1135,7 @@ game.import('card',function(lib,game,ui,get,ai,_status){
player.popup('敕令');
}
},
_chiling3:{
g_chiling3:{
mode:['guozhan'],
trigger:{player:'phaseAfter'},
forced:true,

View File

@ -600,7 +600,7 @@ game.import('card',function(lib,game,ui,get,ai,_status){
if(trigger.cards[i].name=='du'&&trigger.cards[i].original!='j') num++;
}
player.popup('毒','wood');
player.loseHp(num);
player.loseHp(num).type='du';
},
},
caomu_skill:{

View File

@ -256,6 +256,7 @@ game.import('card',function(lib,game,ui,get,ai,_status){
result:{
target:function(player,target){
// if(player==target&&player.hp<=0) return 2;
if(player.hasSkillTag('nokeep')) return 2;
var nd=player.needsToDiscard();
var keep=false;
if(nd<=0){
@ -366,7 +367,7 @@ game.import('card',function(lib,game,ui,get,ai,_status){
ai:{
equipValue:function(card,player){
if(!game.hasPlayer(function(current){
return player.canUse('sha',current)&&get.effect(current,{name:'sha'},player,player)>0;
return player.canUse('sha',current)&&get.distance(player,current)==1&&get.effect(current,{name:'sha'},player,player)>0;
})){
return 1;
}
@ -662,39 +663,13 @@ game.import('card',function(lib,game,ui,get,ai,_status){
enable:true,
selectTarget:-1,
cardcolor:'red',
//reverseOrder:true,
reverseOrder:true,
filterTarget:function(card,player,target){
//return target.hp<target.maxHp;
return true;
},
contentBefore:function(){
"step 0"
game.delay();
"step 1"
if(get.is.versus()){
player.chooseControl('顺时针','逆时针',function(event,player){
if(player.next.side==player.side) return '逆时针';
return '顺时针';
}).set('prompt','选择'+get.translation(card)+'的结算方向');
}
else{
event.goto(3);
}
"step 2"
if(result&&result.control=='顺时针'){
var evt=event.getParent();
evt.fixedSeat=true;
evt.targets.sortBySeat();
evt.targets.reverse();
if(evt.targets[evt.targets.length-1]==player){
evt.targets.unshift(evt.targets.pop());
}
}
"step 3"
var evt=event.getParent();
for(var i=0;i<evt.targets.length;i++){
if(evt.targets[i].isHealthy()) evt.excluded.push(evt.targets[i]);
}
ignoreTarget:function(card,player,target){
return target.isHealthy();
},
content:function(){
target.recover();
@ -1202,6 +1177,24 @@ game.import('card',function(lib,game,ui,get,ai,_status){
expose:0.2
},
notarget:true,
contentBefore:function(){
'step 0'
if(get.mode()=='guozhan'&&get.itemtype(card)=='card'&&card.hasTag('guo')){
var trigger=event.getParent(2);
if(trigger.triggername!='phaseJudge'&&!trigger.statecard&&trigger.target.identity!='ye'&&trigger.target.identity!='unknown'){
player.chooseControl('对单体使用','对势力使用').set('prompt','请选择'+get.translation(card)+'的使用方式').set('ai',function(){
return '对势力使用'
});
}
else event.finish();
}
else event.finish();
'step 1'
if(result.control=='对势力使用'){
player.chat('对势力使用');
event.getParent(2).guowuxie=true;
}
},
content:function(){
event.result='wuxied';
if(player.isOnline()){
@ -1694,7 +1687,7 @@ game.import('card',function(lib,game,ui,get,ai,_status){
filter:function(event,player){
if(event.responded) return false;
if(!event.filterCard({name:'shan'})) return false;
if(!lib.filter.cardRespondable({name:'sha'},player,event)) return false;
if(!lib.filter.cardRespondable({name:'shan'},player,event)) return false;
var evt=event.getParent();
if(evt.player&&evt.player.hasSkillTag('unequip',false,{
name:evt.card?evt.card.name:null,
@ -1862,7 +1855,8 @@ game.import('card',function(lib,game,ui,get,ai,_status){
id:id,
id2:id2
});
if(!isJudge){
if(event.stateplayer&&event.statecard) next.set('respondTo',[event.stateplayer,event.statecard]);
else if(!isJudge){
next.set('respondTo',[source,card]);
}
if(game.online){
@ -1881,7 +1875,7 @@ game.import('card',function(lib,game,ui,get,ai,_status){
}
else{
trigger.cancel();
if(get.mode()=='guozhan'&&get.itemtype(event.statecard)=='card'&&event.statecard.hasTag('guo')){
if(event.guowuxie==true){
if(trigger.target.identity!='ye'&&trigger.target.identity!='unknown'){
trigger.getParent().excluded.addArray(game.filterPlayer(function(current){
return current.identity==trigger.target.identity;
@ -1897,10 +1891,12 @@ game.import('card',function(lib,game,ui,get,ai,_status){
if(event.triggername=='phaseJudge'){
if(game.checkMod(trigger.card,player,current,'unchanged','wuxieJudgeEnabled',current)==false) return false;
if(game.checkMod(trigger.card,player,current,'unchanged','wuxieJudgeRespondable',player)==false) return false;
if(event.stateplayer&&event.statecard&&(game.checkMod(event.statecard,event.stateplayer,player,current,'unchanged','wuxieRespondable',event.stateplayer)==false)) return false;
}
else{
if(game.checkMod(trigger.card,player,trigger.target,current,'unchanged','wuxieEnabled',current)==false) return false;
if(game.checkMod(trigger.card,player,trigger.target,current,'unchanged','wuxieRespondable',player)==false) return false;
if(event.stateplayer&&event.statecard&&(game.checkMod(event.statecard,event.stateplayer,trigger.player,current,'unchanged','wuxieRespondable',event.stateplayer)==false)) return false;
}
return current.hasWuxie();
});
@ -2007,13 +2003,12 @@ game.import('card',function(lib,game,ui,get,ai,_status){
'step 9'
if(event.wuxieresult){
if(result=='wuxied'){
if(!event.statecard){
if(event.wuxieresult2&&event.wuxieresult2.used){
event.statecard=event.wuxieresult2.used;
}
else{
event.statecard=true;
}
if(!event.stateplayer&&event.wuxieresult)event.stateplayer=event.wuxieresult;
if(event.wuxieresult2&&event.wuxieresult2.used){
event.statecard=event.wuxieresult2.used;
}
else{
event.statecard=true;
}
event.state=!event.state;
}

View File

@ -6,6 +6,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
connectBanned:['diy_tianyu','diy_yangyi','diy_lukang','ns_huamulan','ns_yuji','ns_duangui','ns_liuzhang'],
character:{
diy_wenyang:['male','wei','4/6',['lvli','choujue']],
key_lucia:['female','qun','1/3',['lucia_duqu','lucia_zhenren']],
key_kyousuke:['male','qun',4,['nk_shekong','key_huanjie']],
key_yuri:['female','qun',3,['yuri_xingdong','key_huanjie','yuri_wangxi'],['zhu']],
// diy_caocao:['male','wei',4,['xicai','diyjianxiong','hujia']],
// diy_hanlong:['male','wei',4,['siji','ciqiu']],
diy_feishi:['male','shu',3,['shuaiyan','moshou']],
@ -78,6 +81,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
return mode!='chess'&&mode!='tafang';
}
},
characterSort:{
diy:{
diy_tieba:["diy_wenyang","ns_zuoci","ns_lvzhi","ns_wangyun","ns_nanhua","ns_nanhua_left","ns_nanhua_right","ns_huamulan","ns_huangzu","ns_jinke","ns_yanliang","ns_wenchou","ns_caocao","ns_caocaosp","ns_zhugeliang","ns_wangyue","ns_yuji","ns_xinxianying","ns_guanlu","ns_simazhao","ns_sunjian","ns_duangui","ns_zhangbao","ns_masu","ns_zhangxiu","ns_lvmeng","ns_shenpei","ns_yujisp","ns_yangyi","ns_liuzhang","ns_xinnanhua"],
diy_default:["diy_feishi","diy_liuyan","diy_yuji","diy_caiwenji","diy_lukang","diy_zhenji","diy_liufu","diy_xizhenxihong","diy_liuzan","diy_zaozhirenjun","diy_yangyi","diy_tianyu"],
diy_key:["key_lucia","key_kyousuke","key_yuri"],
},
},
characterIntro:{
diy_feishi:'字公举,生卒年不详,益州犍为郡南安县(今四川省乐山市)人。刘璋占据益州时,以费诗为绵竹县县令。刘备进攻刘璋夺取益州,费诗举城而降,后受拜督军从事,转任牂牁郡太守,再为州前部司马。',
//diy_liuyan:'字元海,新兴(今山西忻州北)人,匈奴族,匈奴首领冒顿单于之后[1] 南匈奴单于于夫罗之孙左贤王刘豹之子母呼延氏十六国时期前赵政权开国皇帝304年310年在位。',
@ -89,7 +99,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
diy_tianyu:'字国让,渔阳雍奴(今天津市武清区东北)人。三国时期曹魏将领。初从刘备,因母亲年老回乡,后跟随公孙瓒,公孙瓒败亡,劝说鲜于辅加入曹操。曹操攻略河北时,田豫正式得到曹操任用,历任颖阴、郎陵令、弋阳太守等。',
},
characterTitle:{
diy_wenyang:'最粗的梦想XD',
key_lucia:'Rewrite',
key_kyousuke:'#bLittle Busters!',
key_yuri:'#rAngel Beats!',
diy_wenyang:'#g最粗的梦想XD',
ns_zuoci:'#bskystarwuwei',
ns_lvzhi:'#bskystarwuwei',
ns_wangyun:'#rSukincen',
@ -124,6 +137,272 @@ game.import('character',function(lib,game,ui,get,ai,_status){
yuji:['zuoci']
},
skill:{
yuri_xingdong:{
subSkill:{
mark:{
mark:true,
marktext:'令',
intro:{
content:'跳过下个回合的判定阶段和摸牌阶段',
},
},
},
enable:'phaseUse',
usable:1,
filter:function(event,player){
return player.countCards('h',lib.skill.yuri_xingdong.filterCard);
},
filterCard:function(card){
return card.name=='sha'||get.type(card)=='trick';
},
check:function(card){return 1},
filterTarget:lib.filter.notMe,
discard:false,
lose:false,
delay:0,
content:function(){
'step 0'
target.gain(cards,player,'give');
'step 1'
target.chooseUseTarget(cards[0],game.filterPlayer(function(current){
return current!=player;
}),'请使用得到的牌,或者跳过下回合的判定阶段和摸牌阶段');
'step 2'
if(result.bool) game.asyncDraw([player,target]);
else{
target.addTempSkill('yuri_xingdong_mark','phaseJudgeSkipped');
target.skip('phaseJudge');
target.skip('phaseDraw');
event.finish();
}
'step 3'
game.delay();
},
ai:{
order:7,
result:{
target:function(player,target){
var card=ui.selected.cards[0];
if(target.hasSkill('pingkou')) return 1;
if(!card) return 0;
var info=get.info(card);
if(info.selectTarget==-1){
var eff=0;
game.countPlayer(function(current){
if(current!=player&&target.canUse(card,current)) eff+=get.effect(current,card,target,target)>0
});
return eff;
}
else if(game.hasPlayer(function(current){
return current!=player&&target.canUse(card,current)&&get.effect(current,card,target,target)>0
})) return 1.5;
else return -1;
},
},
},
},
yuri_wangxi:{
trigger:{global:'dieAfter'},
direct:true,
limited:true,
zhuSkill:true,
unique:true,
skillAnimation:true,
animationColor:'thunder',
filter:function(event,player){
if(get.mode()!='identity') return false;
if(!player.hasZhuSkill('yuri_wangxi')) return false;
if(event.player.isAlive()) return false;
if(event.player.identity=='mingzhong') return false;
var evt=event.getParent('yuri_xingdong');
return evt&&evt.name=='yuri_xingdong'&&evt.player==player;
},
content:function(){
'step 0'
trigger.player.chooseBool('是否发动'+get.translation(player)+'的【忘隙】?').forceDie=true;
'step 1'
if(result.bool){
player.logSkill('yuri_wangxi',trigger.player);
player.awakenSkill('yuri_wangxi');
game.broadcastAll(function(source){
source.revive(2,false);
source.identity='zhong';
source.setIdentity();
},trigger.player);
trigger.player.changeGroup(player.group);
trigger.player.draw();
var evt=trigger.getParent('damage');
if(evt.untrigger) evt.untrigger(false,trigger.player);
game.addVideo('setIdentity',trigger.player,'zhong');
}
},
},
nk_shekong:{
enable:'phaseUse',
usable:1,
filter:function(event,player){
return player.countCards('h')>0;
},
filterCard:true,
selectCard:function(){
if(ui.selected.targets.length) return [1,ui.selected.targets[0].countCards('he')];
return [1,Infinity];
},
filterTarget:function(event,player,target){
return target!=player&&target.countCards('he')>=Math.max(1,ui.selected.cards.length);
},
check:function(card){
if(!game.hasPlayer(function(current){
return current!=_status.event.player&&get.attitude(_status.event.player,current)<0&&current.countCards('he')>ui.selected.cards.length;
})) return 0;
return 6-get.value(card);
},
content:function(){
'step 0'
event.cardsx=cards.slice(0);
var num=get.cnNumber(cards.length);
var trans=get.translation(player);
var prompt=('弃置'+num+'张牌,然后'+trans+'摸一张牌');
if(cards.length>1) prompt+=(';或弃置一张牌,然后'+trans+'摸'+num+'张牌');
var next=target.chooseToDiscard(prompt,'he',true);
next.numx=cards.length;
next.selectCard=function(){
if(ui.selected.cards.length>1) return _status.event.numx;
return [1,_status.event.numx];
};
next.complexCard=true;
next.ai=function(card){
if(ui.selected.cards.length==0||(_status.event.player.countCards('he',function(cardxq){
return get.value(cardxq)<7;
})>=_status.event.numx)) return 7-get.value(card);
return -1;
};
'step 1'
if(result.bool){
if(result.cards.length==cards.length) player.draw();
else player.draw(cards.length);
event.cardsx.addArray(result.cards);
for(var i=0;i<event.cardsx.length;i++){
if(get.position(event.cardsx[i])!='d') event.cardsx.splice(i--,1);
}
}
else event.finish();
'step 2'
if(event.cardsx.length){
player.chooseButton(['请按顺序将卡牌置于牌堆顶(先选择的在上)',event.cardsx],true,event.cardsx.length);
}
else event.finish();
'step 3'
if(result.bool){
var cardsx=result.links;
while(cardsx.length){
var card=cardsx.pop();
card.fix();
ui.cardPile.insertBefore(card,ui.cardPile.firstChild);
}
}
},
ai:{
order:10,
result:{
target:-1,
},
},
},
key_huanjie:{
trigger:{player:['drawBegin','judgeBegin']},
forced:true,
silent:true,
popup:false,
priority:-1,
filter:function(event){
return event.name=='draw'||!event.directresult;
},
content:function(){
if(trigger.name=='draw'){
if(trigger.bottom) trigger.bottom=false;
else trigger.bottom=true;
}
else trigger.directresult=get.bottomCards()[0];
},
},
lucia_duqu:{
mod:{
cardSavable:function(card,player){
if(card.name=='du'&&!player.hasSkill('lucia_duqu_terra')) return true;
},
},
trigger:{
player:['damage','loseHpBefore','useCardBefore'],
source:'damage',
},
forced:true,
charlotte:true,
filter:function(event,player,onrewrite){
if(onrewrite=='loseHpBefore'){
return event.type=='du';
}
if(onrewrite=='useCardBefore'){
return event.card.name=='du'&&event.getParent().type=='dying';
}
return event.source!=undefined&&event.source!=event.player;
},
content:function(){
var onrewrite=event.triggername;
if(onrewrite=='loseHpBefore'){
trigger.cancel();
player.recover(trigger.num);
}
else if(onrewrite=='useCardBefore'){
player.addTempSkill('lucia_duqu_terra');
}
else{
var another=trigger[trigger.source==player?'player':'source'];
player.line(another,{color:[220, 90, 139]});
var card=game.createCard('du');
player.$gain2(card);
player.gain(card);
another.gain(game.createCard('du'),'gain2');
}
},
ai:{usedu:true,save:true},
subSkill:{terra:{sub:true}}
},
lucia_zhenren:{
trigger:{global:'phaseEnd'},
forced:true,
charlotte:true,
filter:function(event,player){
return player.countCards('e')>0;
},
content:function(){
'step 0'
var es=player.getCards('e');
event.count=es.length;
player.discard(es);
'step 1'
event.count--;
if(game.hasPlayer(function(current){
return current.countDiscardableCards(player,'ej')>0;
})){
player.chooseTarget('请选择一名角色,弃置其装备区或判定区内的一张牌。',true,function(card,player,target){
return target.countDiscardableCards(player,'ej')>0;
}).ai=function(target){
var att=get.attitude(_status.event.player,target);
if(target.countCards('j')&&att>0) return att*1.5;
return -att;
};
}
else event.finish();
'step 2'
if(result.bool&&result.targets&&result.targets.length){
var target=result.targets[0];
player.line(target,{color:[220, 90, 139]});
player.discardPlayerCard(target,'ej',true);
if(event.count) event.goto(1);
}
},
},
ns_chuanshu:{
audio:["xingshuai",2],
trigger:{
@ -1456,6 +1735,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
typeof player.storage.nstuiyan=='number'&&event.card.number>player.storage.nstuiyan;
},
frequent:true,
priority:2,
content:function(){
player.draw();
},
@ -1510,7 +1790,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
}
},
group:['nstuiyan_use','nstuiyan_clear','nstuiyan_disable'],
group:['nstuiyan_use','nstuiyan_clear'],
subSkill:{
bugua:{
trigger:{player:'useCardAfter'},
@ -1538,12 +1818,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
return _status.currentPhase==player&&event.getParent('phaseUse',true)&&typeof event.card.number=='number';
},
content:function(){
if(typeof player.storage.nstuiyan!='number'){
player.storage.nstuiyan=0;
}
if(typeof player.storage.nstuiyan2!='number'){
player.storage.nstuiyan2=0;
}
if(!player.hasSkill('nstuiyan_fail')&&
(trigger.card.number<=player.storage.nstuiyan||typeof trigger.card.number!='number')){
player.storage.nstuiyan_done=true;
player.addTempSkill('nstuiyan_fail');
}
player.storage.nstuiyan=trigger.card.number;
player.storage.nstuiyan2+=trigger.card.number;
if(player.storage.nstuiyan2%8==0&&!player.storage.nstuiyan2_done){
@ -1564,18 +1846,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
player.unmarkSkill('nstuiyan');
}
},
disable:{
trigger:{player:'useCard'},
filter:function(event,player){
return _status.currentPhase==player&&event.getParent('phaseUse',true)&&!player.hasSkill('nstuiyan_fail')&&
(event.card.number<=player.storage.nstuiyan||typeof event.card.number!='number');
},
silent:true,
content:function(){
player.storage.nstuiyan_done=true;
player.addTempSkill('nstuiyan_fail');
},
},
fail:{}
},
ai:{
@ -4813,7 +5083,23 @@ game.import('character',function(lib,game,ui,get,ai,_status){
ns_liuzhang:'刘璋',
ns_xinnanhua:'南华老仙',
ns_chuanshu:'传术',
key_lucia:'此花露西娅',
key_kyousuke:'棗恭介',
key_yuri:'仲村ゆり',
lucia_duqu:'毒躯',
lucia_duqu_info:'锁定技,①当你对其他角色造成伤害或受到其他角色的伤害时,你和对方各获得一张花色点数随机的【毒】。<br>②当你因【毒】失去体力时,你改为回复等量的体力。<br>③当你处于濒死状态时,你可以使用一张【毒】(每回合限一次)。',
lucia_zhenren:'振刃',
lucia_zhenren_info:'锁定技每个结束阶段若你的装备区内有牌则你弃置之。然后你依次弃置场上的X张牌。X为你以此法弃置的牌数',
nk_shekong:'设控',
nk_shekong_info:'出牌阶段限一次你可以弃置任意张手牌并选择一名其他角色不能超过该角色的牌数然后令其选择一项弃置一张牌并令你摸X张牌或弃置X张牌并令你摸一张牌。然后你将你与其弃置的且位于弃牌堆中的牌以任意顺序置于牌堆顶。',
key_huanjie:'幻界',
key_huanjie_info:'锁定技,当你进行判定或摸牌时,你改为从牌堆的另一端获取相应的牌。',
yuri_xingdong:'行动',
yuri_xingdong_info:'出牌阶段限一次,你可以将一张【杀】或普通锦囊牌交给一名其他角色,然后该角色选择一项:对除你以外的角色使用此牌并在此牌结算完成后和你各摸一张牌;或跳过下回合的判定阶段和摸牌阶段。',
yuri_wangxi:'忘隙',
yuri_wangxi_info:'主公技限定技当有角色因你发动的【行动】而死亡后若其身份不为【明忠】则其可以将身份改为忠臣并重新加入游戏然后将势力改为与你相同将体力值回复至2点并摸一张牌。',
ns_chuanshu:'传术',
ns_chuanshu_info:'<span class=yellowtext>限定技</span> 当一名其他角色进入濒死状态时你可以令其选择获得技能【雷击】或【鬼道】其回复体力至1并摸两张牌。当该被【传术】的角色造成或受到一次伤害后你摸一张牌。其阵亡后你重置技能【传术】',
ns_xiandao1:'仙道',
ns_xiandao1_info:'<font color=#f00>锁定技</font> 游戏开始和回合结束阶段,你随机获得技能【雷击】或【鬼道】,直到下个出牌阶段开始',
@ -4848,7 +5134,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
nsfuge:'覆戈',
nsfuge_info:'你的回合结束后你可以执行一个额外的回合此回合的摸牌阶段你于摸牌阶段额外摸X张牌X为你已损失的体力值若如此做直到洗牌前你不能再发动此技能',
nstanbing:'谈兵',
nstanbing_info:'牌阶段开始时你可弃置一张牌然后摸X张牌(X为你弃置牌的名称字数),若如此做,本回合你不可使用或打出【杀】',
nstanbing_info:'牌阶段开始时你可弃置一张牌然后摸X张牌(X为你弃置牌的名称字数),若如此做,本回合你不可使用或打出【杀】',
nsxinzhan:'心战',
nsxinzhan_info:'出牌阶段限一次你可将任意张手牌交给一名其他角色若如此做该角色失去X点体力(X为你交给其的牌张数的一半向下取整),若你给的牌达到六张,则改为该角色失去一点体力上限',
nsfuhuo:'符火',
@ -5034,6 +5320,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
moshou_info:'锁定技,你不能成为乐不思蜀和兵粮寸断的目标。',
xicai_info:'你可以立即获得对你造成伤害的牌',
diyjianxiong_info:'锁定技,在身份局中,在你回合内死亡的角色均视为反贼,国战中,在你回合内死亡的角色若与你势力相同则随机改为另一个势力',
diy_tieba:'吧友设计',
diy_default:'常规',
diy_key:'论外',
},
};
});

View File

@ -153,15 +153,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
var cards=target.getCards(range[i]);
if(cards.length){
var card=cards.randomGet();
player.gain(card);
target.$giveAuto(card,player);
player.gain(card,target,'giveAuto');
break;
}
}
event.num++;
}
"step 4"
game.delay(0.7);
if(num<event.targets.length) event.goto(3);
"step 5"
player.turnOver();
@ -452,14 +450,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
player.markSkill('baonu');
player.syncStorage('baonu');
},
trigger:{source:'damageEnd',player:'damageEnd'},
trigger:{source:'damageSource',player:'damageEnd'},
forced:true,
filter:function(event){
return event.num>0;
},
content:function(){
if(player==trigger.player) player.storage.baonu+=trigger.num;
if(player==trigger.source) player.storage.baonu+=trigger.num;
player.storage.baonu+=trigger.num;
player.markSkill('baonu');
player.syncStorage('baonu');
},
@ -2030,18 +2027,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){
mark:true,
trigger:{
player:"damageAfter",
source:"damageAfter",
source:"damageSource",
},
forced:true,
content:function(){
if(player==trigger.source){
player.storage.nzry_junlve+=trigger.num;
game.log(player,'获得了',trigger.num,'个“军略”标记');
}
if(player==trigger.player){
player.storage.nzry_junlve+=trigger.num;
game.log(player,'获得了',trigger.num,'个“军略”标记');
}
player.storage.nzry_junlve+=trigger.num;
game.log(player,'获得了',trigger.num,'个“军略”标记');
player.syncStorage('nzry_junlve');
},
},
@ -2163,7 +2154,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
player.storage.drlt_duorui=[];
},
trigger:{
source:'damageAfter'
source:'damageSource'
},
filter:function(event,player){
if(player.storage.drlt_duorui.length) return false;
@ -2450,6 +2441,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
content:function(){
trigger.num++;
},
ai:{nokeep:true},
},
'drlt_jieying':{
audio:2,

View File

@ -9,7 +9,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
mobile_default:["miheng","taoqian","liuzan","lingcao","sunru","lifeng","zhuling","liuye","zhaotongzhaoguang","majun","simazhao","wangyuanji","pangdegong","shenpei"],
mobile_fire:["re_sp_zhugeliang","re_xunyu","re_dianwei","re_yanwen","re_pangtong","xin_yuanshao"],
mobile_forest:['re_zhurong','re_menghuo'],
mobile_others:["re_jikang","old_bulianshi","old_yuanshu"],
mobile_others:["re_jikang","old_bulianshi","old_yuanshu","re_wangyun"],
},
},
character:{
@ -38,6 +38,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
shenpei:["male","qun","2/3",["shouye","liezhi"],[]],
re_zhurong:['female','shu',4,['juxiang','relieren']],
re_menghuo:['male','shu',4,['huoshou','rezaiqi']],
re_wangyun:['male','qun',3,['relianji','remoucheng']],
},
characterIntro:{
shenpei:'审配204年字正南魏郡阴安今河北清丰北人。为人正直 袁绍领冀州,审配被委以腹心之任,并总幕府。河北平定,袁绍以审配、逢纪统军事,审配恃其强盛,力主与曹操决战。曾率领弓弩手大破曹军于官渡。官渡战败,审配二子被俘,反因此受谮见疑,幸得逢纪力保。袁绍病死,审配等矫诏立袁尚为嗣,导致兄弟相争,被曹操各个击破。曹操围邺,审配死守数月,终城破被擒,拒不投降,慷慨受死。',
@ -81,6 +82,139 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},
characterFilter:{},
skill:{
relianji:{
audio:2,
enable:'phaseUse',
usable:1,
filter:function(event,player){
return game.players.length>1;
},
filterTarget:lib.filter.notMe,
targetprompt:['打人','被打'],
selectTarget:2,
multitarget:true,
content:function(){
'step 0'
game.delay(0.5);
if(targets[0].isDisabled(1)) event.goto(2);
'step 1'
var target=targets[0];
var equip1=get.cardPile2(function(card){
return get.subtype(card)=='equip1';
});
if(!equip1){
player.popup('连计失败');
game.log('牌堆中无装备');
event.finish();
return;
}
target.$draw(equip1);
target.chooseUseTarget(equip1,'noanimate','nopopup');
'step 2'
targets[0].useCard({name:['nanman','wanjian','huogong','juedou','sha'].randomGet()},targets[1],'noai').animate=false;
game.delay(0.5);
},
ai:{
order:8,
result:{
target:function(player,target){
if(ui.selected.targets.length==0){
return 1;
}
else{
return -1;
}
}
},
expose:0.4,
threaten:3,
},
group:'relianji_count',
subSkill:{
count:{
sub:true,
forced:true,
popup:false,
silent:true,
trigger:{global:'damageEnd'},
filter:function(event,player){
var evt=event.getParent(3);
return evt&&evt.name=='relianji'&&evt.player==player;
},
content:function(){
if(!player.storage.relianji) player.storage.relianji=0;
player.storage.relianji++;
if(player.storage.relianji>2){
event.trigger('remoucheng_awaken');
}
},
},
},
},
remoucheng:{
derivation:'rejingong',
trigger:{
player:'remoucheng_awaken'
},
forced:true,
juexingji:true,
skillAnimation:true,
animationColor:'thunder',
content:function(){
player.awakenSkill('remoucheng');
player.removeSkill('relianji');
player.addSkill('rejingong');
player.gainMaxHp();
player.recover();
},
},
rejingong:{
enable:'phaseUse',
delay:0,
usable:1,
content:function(){
'step 0'
var list=get.inpile('trick','trick').randomGets(2);
if(Math.random()<0.5){
list.push('wy_meirenji');
}
else{
list.push('wy_xiaolicangdao');
}
for(var i=0;i<list.length;i++){
list[i]=['锦囊','',list[i]];
}
player.chooseButton(['矜功',[list,'vcard']]).set('filterButton',function(button,player){
return game.hasPlayer(function(current){
return player.canUse(button.link[2],current,true,false);
});
}).set('ai',function(button){
var player=_status.event.player;
var name=button.link[2];
if(game.hasPlayer(function(current){
return player.canUse(name,current)&&get.effect(current,{name:name},player,player)>0;
})){
if(name=='wy_meirenji'||name=='wy_xiaolicangdao') return Math.random()+0.5;
return Math.random();
}
return 0;
});
'step 1'
if(result.bool){
player.chooseUseTarget(result.links[0][2],true);
player.addTempSkill('jingong2');
}
},
ai:{
order:2,
result:{
player:function(player){
if((player.hp<=2||player.needsToDiscard())&&!player.getStat('damage')) return 0;
return 1;
}
}
}
},
relieren:{
audio:'lieren',
audioname:['boss_lvbu3'],
@ -484,6 +618,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
shenpei:'审配',
re_zhurong:'界祝融',
re_menghuo:'界孟获',
re_wangyun:'手杀王允',
relianji:'连计',
relianji_info:'出牌阶段限一次你可以选择两名其他角色。第一名角色随机使用牌堆中的一张武器牌然后这名角色视为对另一名角色随机使用一张下列的牌名的牌【决斗】、【火攻】、【南蛮入侵】、【万箭齐发】或普【杀】。然后若此牌造成伤害你获得X枚“连计”标记X为此次扣减的体力值点数。',
remoucheng:'谋逞',
remoucheng_info:'觉醒技当一名角色造成伤害后若你拥有的“连计”标记数大于2你加1点体力上限回复1点体力失去“连计”获得“矜功”。',
rejingong:'矜功',
rejingong_info:'每回合可以用三个随机锦囊中的一个三个锦囊中有一个是专属锦囊本回合未造成伤害会失去1点体力。',
mobile_default:'常规',
mobile_fire:'界限突破•火',
mobile_forest:'界限突破•林',

View File

@ -30,7 +30,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
re_huangyueying:['female','shu',3,['rejizhi','reqicai']],
re_sunquan:['male','wu',4,['rezhiheng','rejiuyuan'],['zhu']],
re_sunshangxiang:['female','wu',3,['xiaoji','rejieyin']],
re_zhenji:['female','wei',3,['reluoshen','qingguo']],
re_zhenji:['female','wei',3,['reluoshen','reqingguo']],
re_zhugeliang:['male','shu',3,['reguanxing','kongcheng']],
re_huaxiong:["male","qun",6,["new_reyaowu"]],
},
@ -39,6 +39,31 @@ game.import('character',function(lib,game,ui,get,ai,_status){
re_lidian:'字曼成,曹操麾下将领。李典深明大义,不与人争功,崇尚学习与高贵儒雅,尊重博学之士,在军中被称为长者。李典有长者之风,官至破虏将军,三十六岁去世。魏文帝曹丕继位后追谥号为愍侯。',
},
skill:{
reqingguo:{
audio:2,
enable:['chooseToRespond'],
filterCard:function(card){
return get.color(card)=='black';
},
position:'he',
viewAs:{name:'shan'},
viewAsFilter:function(player){
if(!player.countCards('he',{color:'black'})) return false;
},
prompt:'将一张黑色牌当闪打出',
check:function(){return 1},
ai:{
respondShan:true,
skillTagFilter:function(player){
if(!player.countCards('he',{color:'black'})) return false;
},
effect:{
target:function(card,player,target,current){
if(get.tag(card,'respondShan')&&current<0) return 0.6
}
}
}
},
reqiangxi:{
subSkill:{
off:{
@ -381,7 +406,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
"new_liyu":{
audio:"liyu",
trigger:{
source:"damageEnd",
source:"damageSource",
},
filter:function (event,player){
if(event._notrigger.contains(event.player)) return false;
@ -509,9 +534,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
});
"step 3"
if(result.bool){
player.$giveAuto(result.cards,result.targets[0]);
player.line(result.targets,'green');
result.targets[0].gain(result.cards);
result.targets[0].gain(result.cards,player,'giveAuto');
event.given+=result.cards.length;
if(event.given<2){
event.temp=result.targets[0];
@ -584,11 +608,21 @@ game.import('character',function(lib,game,ui,get,ai,_status){
trigger:{
player:"phaseDrawBegin",
},
forced:true,
locked:false,
content:function (){
"step 0"
event.cards=get.cards(3);
var cards=get.cards(3);
event.cards=cards;
player.showCards(event.cards,'裸衣');
player.chooseBool("是否放弃摸牌?").ai=function(event,player){
var cardsx=[];
for(var i=0;i<cards.length;i++){
if(get.type(cards[i])=='basic'||cards[i].name=='juedou'||
(get.type(cards[i])=='equip'&&get.subtype(cards[i])!='equip1')){
cardsx.push(cards[i]);
}
}
player.chooseBool("是否放弃摸牌,改为获得"+get.translation(cardsx)+"").ai=function(event,player){
var num=3
for(var i=0;i<event.cards.length;i++){
if(get.type(event.cards[i])!='basic'&&event.cards[i].name!='juedou'&&
@ -596,7 +630,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
num--;
}
}
return num>1
return num>=trigger.num;
};
"step 1"
if(result.bool){
@ -726,8 +760,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
event.finish();
}
else{
target.$give(event.card2,player);
player.gain(event.card2);
player.gain(event.card2,target,'give');
if(target.hp<target.maxHp){
player.chooseBool('是否让目标回复一点体力?').ai=function(event,player){
return get.recoverEffect(target,player,player)>0;
@ -924,8 +957,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
player.storage.new_qingjian++;
player.logSkill('new_qingjian',target);
target.gain(cards,player);
player.$give(cards,target);
target.gain(cards,player,'give');
_status.currentPhase.addTempSkill('qingjian_add');
_status.currentPhase.storage.qingjian_add=type.length;
}
@ -1495,7 +1527,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
if(type=='trick'||type=='delay') return true;
},
canBeDiscarded:function(card){
if(get.position(card)=='e') return false;
if(get.position(card)=='e'&&['equip2','equip5'].contains(get.subtype(card))) return false;
},
},
},
@ -1723,7 +1755,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},
liyu:{
audio:2,
trigger:{source:'damageEnd'},
trigger:{source:'damageSource'},
forced:true,
filter:function(event,player){
if(event._notrigger.contains(event.player)) return false;
@ -2673,7 +2705,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},
qiaomeng:{
audio:2,
trigger:{source:'damageEnd'},
trigger:{source:'damageSource'},
direct:true,
filter:function(event){
if(event._notrigger.contains(event.player)) return false;
@ -2791,7 +2823,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
audio:2,
unique:true,
juexingji:true,
trigger:{source:'damageAfter'},
trigger:{source:'damageSource'},
forced:true,
derivation:'jianyan',
filter:function(event,player){
@ -3009,7 +3041,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},
wangxi:{
audio:2,
trigger:{player:'damageEnd',source:'damageEnd'},
trigger:{player:'damageEnd',source:'damageSource'},
filter:function(event){
if(event._notrigger.contains(event.player)) return false;
return event.num&&event.source&&event.player&&
@ -3098,7 +3130,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
rejieming:"节命",
"rejieming_info":"当你受到1点伤害后你可以令一名角色摸两张牌。然后若其手牌数小于体力上限则你摸一张牌。",
reshuangxiong:"双雄",
"reshuangxiong_info":"摸牌阶段,你可以放弃摸牌。若如此做,你展示牌堆顶的两张牌并选择获得其中的一张。然后,你本回合内可以将与此牌颜色不同的一张手牌当做【决斗】使用。",
"reshuangxiong_info":"摸牌阶段,你可以放弃摸牌。若如此做,你展示牌堆顶的两张牌并选择获得其中的一张。然后,你本回合内可以将与此牌颜色不同的一张手牌当做【决斗】使用。当你受到以此法使用的【决斗】的伤害时,你获得对方于此决斗中打出的所有【杀】",
"reshuangxiong2":"双雄",
"reshuangxiong2_info":"",
@ -3113,7 +3145,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
rejizhi:'集智',
rejizhi_info:'当你使用非延时锦囊牌时,你可以摸一张牌。若此牌为基本牌,则你可以弃置之,然后令本回合手牌上限+1。',
reqicai:'奇才',
reqicai_info:'锁定技,你使用锦囊牌无距离限制,你装备区内的牌不能被其他角色弃置',
reqicai_info:'锁定技,你使用锦囊牌无距离限制,你装备区内的防具牌和宝物牌不能被其他角色弃置',
rezhiheng:'制衡',
rezhiheng_info:'出牌阶段限一次,你可以弃置任意张牌并摸等量的牌,若你在发动“制衡”时弃置了所有手牌,则你多摸一张牌',
rejiuyuan:'救援',
@ -3151,6 +3183,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
"new_reqingnang_info":"出牌阶段,你可以弃置一张手牌,令一名本回合内未成为过〖青囊〗的目标的角色回复一点体力。若你弃置的是黑色牌,则你本回合内不能再发动〖青囊〗。",
"new_reyaowu":"耀武",
"new_reyaowu_info":"锁定技当任意一名角色使用【杀】对你造成伤害时若此杀为红色该角色回复1点体力或摸一张牌。若为黑色则你摸一张牌。",
reqingguo:'倾国',
reqingguo_info:'你可以将一张黑色牌当做【闪】使用或打出。',
qinxue:'勤学',
retuxi:'突袭',

View File

@ -152,7 +152,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
mark:true,
audio:2,
trigger:{
source:'damageAfter',
source:'damageSource',
},
filter:function(event,player){
return event.player!=player&&event.player.countCards('h')>player.countCards('h');
@ -662,7 +662,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
player.line(result.targets);
player.$give(event.cards[0],result.targets[0]);
result.targets[0].gain(event.cards[0],player);
result.targets[0].gain(event.cards[0]);
event.gived.add(result.targets[0]);
};
event.cards.remove(event.cards[0]);
@ -805,9 +805,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
if(result.bool){
event.target=result.targets[0];
player.line(event.target);
player.logSkill('drlt_congjian')
player.$give(result.cards[0],event.target);
event.target.gain(result.cards[0],player);
player.logSkill('drlt_congjian');
event.target.gain(result.cards[0],player,'give');
var num=1;
if(get.type(result.cards[0])=='equip') num=2;
player.draw(num);
@ -1004,9 +1003,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
'step 2'
player.gain(player.storage.kongsheng2,'gain2','fromStorage');
'step 3'
for(var i=0;i<player.storage.kongsheng2.length;i++){
player.storage.kongsheng2.remove(player.storage.kongsheng2[i]);
};
delete player.storage.kongsheng2;
player.removeSkill('kongsheng2');
},
},
@ -1153,7 +1150,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
};
player.line(event.target);
if(event.control=='令一名手牌数大于你的角色交给你一张牌'){
event.target.chooseCard(1,'h',true).set('ai',function(card){
event.target.chooseCard(1,'he',true).set('ai',function(card){
return 6-get.value(card);
});
}else{
@ -1165,8 +1162,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
};
'step 3'
if(result.bool){
event.target.$giveAuto(result.cards,player);
player.gain(result.cards,event.target);
player.gain(result.cards,event.target,'giveAuto');
};
},
ai:{
@ -1885,8 +1881,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
});
"step 1"
if(result.bool){
player.$give(result.cards.length,trigger.source);
trigger.source.gain(result.cards);
trigger.source.gain(result.cards,player,'give');
trigger.source.storage.nzry_shenshi1=result.cards[0];
trigger.source.storage.nzry_shenshi2=player;
trigger.source.addSkill('nzry_shenshi1');
@ -2312,7 +2307,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
},
damage:{
trigger:{source:'damageEnd'},
trigger:{source:'damage'},
forced:true,
silent:true,
popup:false,
@ -2434,7 +2429,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
},
xinkuanggu:{
trigger:{source:'damageEnd'},
trigger:{source:'damageSource'},
filter:function(event,player){
return get.distance(player,event.player)<=1&&event.num>0;
},
@ -2900,7 +2895,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
dist:{
mod:{
globalFrom:function(from,to,distance){
if(from.storage.tuntian) return distance-from.storage.tuntian.length;
if(from.storage.tuntian){
var num=distance-from.storage.tuntian.length;
if(_status.event.skill=='jixi_backup'||_status.event.skill=='gzjixi') num++;
return num;
}
}
}
}
@ -3118,9 +3117,20 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}).set('preserve','lose');
"step 2"
if(result.bool==false){
target.gain([result.player,result.target]);
target.$gain2([result.player,result.target]);
var list=[];
if(get.position(result.player)=='d') list.push(result.player);
if(get.position(result.target)=='d') list.push(result.target);
if(!list.length) event.finish();
else{
event.list=list;
target.chooseBool('是否获得'+get.translation(list)+'').ai=function(){
return get.value(list)>0;
};
}
}
else event.finish();
"step 3"
if(result.bool) target.gain(event.list,'gain2');
},
ai:{
basic:{
@ -3865,7 +3875,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
lieren:{
audio:2,
audioname:['boss_lvbu3'],
trigger:{source:'damageEnd'},
trigger:{source:'damageSource'},
filter:function(event,player){
if(event._notrigger.contains(event.player)) return false;
return (event.card&&event.card.name=='sha'&&
@ -3897,12 +3907,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
content:function(){
"step 0"
event.togain=trigger.player.getCards('he');
event.shown=trigger.player.getCards('e');
var num=event.togain.length-event.shown.length;
player.gain(event.togain);
if(num) trigger.player.$give(num,player);
if(event.shown.length) trigger.player.$give(event.shown,player);
game.delay();
player.gain(event.togain,trigger.player,'giveAuto');
},
},
fangzhu:{
@ -4115,8 +4120,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
});
"step 1"
if(result.targets&&result.targets[0]){
result.targets[0].gain(result.cards,player);
player.$give(result.cards.length,result.targets[0]);
result.targets[0].gain(result.cards,player,'giveAuto');
}
}
},
@ -4455,7 +4459,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
baonue2:{
audio:2,
forceaudio:true,
trigger:{source:'damageEnd'},
trigger:{source:'damageSource'},
filter:function(event,player){
if(player.group!='qun') return false;
return game.hasPlayer(function(target){
@ -5549,7 +5553,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},
kuanggu:{
audio:2,
trigger:{source:'damageEnd'},
trigger:{source:'damageSource'},
forced:true,
filter:function(event,player){
return get.distance(player,event.player)<=1&&player.isDamaged();
@ -6105,7 +6109,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
if(get.mode()!='guozhan'&&player.storage.buqu&&player.storage.buqu.length) return num-player.hp+player.storage.buqu.length;
},
},
ai:{save:true},
ai:{
save:true,
skillTagFilter:function(player){
if(player.storage.niepan) return false;
if(player.hp>0) return false;
},
},
intro:{
content:'cards',
onunmark:function(storage,player){
@ -6386,6 +6396,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
type:"equip",
subtype:"equip5",
},
disable_judge:{},
},
translate:{
"feichu_equip1":"已废除",
@ -6403,6 +6414,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
"feichu_equip3_bg":"废",
"feichu_equip4_bg":"废",
"feichu_equip5_bg":"废",
disable_judge:'已废除',
disable_judge_info:'判定区已废除',
disable_judge_bg:'废',
re_yuanshao:'袁绍',
re_lusu:'鲁肃',

View File

@ -559,7 +559,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
//文鸯
xinlvli:{
audio:'lvli',
trigger:{player:'damageEnd',source:'damageEnd'},
trigger:{player:'damageEnd',source:'damageSource'},
filter:function(event,player){
if(player.hp==player.countCards('h')) return false;
if(player.hp<player.countCards('h')&&player.isHealthy()) return false;
@ -1143,27 +1143,28 @@ game.import('character',function(lib,game,ui,get,ai,_status){
event.cards=get.cards(num);
player.showCards(event.cards);
"step 1"
event.preResult=lib.skill.yanjiao.getResult(cards);
if(!event.preResult.length){
event.getedResult=lib.skill.yanjiao.getResult(cards);
if(!event.getedResult.length){
game.cardsDiscard(cards);
player.addTempSkill('yanjiao2');
event.finish();
}
"step 2"
target.chooseControl("自动分配","手动分配").set("prompt","【严教】:是否让系统自动分配方案?").ai=function(){
return "自动分配";
return 0;
};
"step 3"
if(result.control=="手动分配"){
event.map=[cards,[],[]];
event.goto(8);
game.log('38');
}
else if(!_status.connectMode){
var choiceList=ui.create.dialog('请选择一种方案','hidden','forcebutton');
for(var i=0;i<event.preResult.length;i++){
for(var i=0;i<event.getedResult.length;i++){
var str='<div class="popup text" style="width:calc(100% - 10px);display:inline-block">方案'+get.cnNumber(i+1,true);
str+='<br>第一组:';
var current=event.preResult[i];
var current=event.getedResult[i];
str+=get.translation(current[0]);
str+='<br>第二组:';
str+=get.translation(current[1]);
@ -1186,8 +1187,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
});
}
"step 4"
event.index=result.links[0]||0;
event.togain=event.preResult[event.index];
if(result.bool&&result.links) event.index=result.links[0];
else event.index=0;
event.togain=event.getedResult[event.index];
target.showCards(event.togain[0],get.translation(target)+'分出的第一份牌');
"step 5"
target.showCards(event.togain[1],get.translation(target)+'分出的第二份牌');
@ -1204,7 +1206,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
if(event.togain[2].length>1) player.addTempSkill('yanjiao2');
}
event.finish();
"step 8"
event.videoId=lib.status.videoId++;
var dialogx=['严教:选择要移动的牌'];
@ -1249,7 +1250,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
target.send('closeDialog',event.videoId);
}
event.dialog.close();
event.togain=[event.map[1],event.map[2],event.map[0]];
target.showCards(event.togain[0],get.translation(target)+'分出的第一份牌');
event.goto(5);
@ -1299,7 +1299,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
target.send('closeDialog',event.videoId);
}
event.dialog.close();
var position={
"取消分组":0,
"移动到第一组":1,
@ -1493,8 +1492,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
'step 2'
if(result.bool){
var cards=result.cards;
trigger.target.$giveAuto(cards,player)
player.gain(cards);
player.gain(cards,trigger.target,'giveAuto');
}
else trigger.directHit=true;
game.delay();
@ -1761,8 +1759,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
if(result.bool){
var target=result.targets[0];
player.line(target,'green');
target.gain(card,player)
player.$give(card,target);
target.gain(card,player,'give');
}
},
},
@ -1802,8 +1799,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
player.line(result.targets,'green');
if(result.cards.length){
event.cards=result.cards;
result.targets[0].gain(result.cards,player);
player.$give(result.cards,result.targets[0]);
result.targets[0].gain(result.cards,player,'give');
}
else{
player.storage.zhengbi_eff1=result.targets[0];
@ -1824,8 +1820,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
else{
if(target.countCards('h')){
var cards=target.getCards('h');
player.gain(cards,target);
target.$giveAuto(cards,player);
player.gain(cards,target,'giveAuto');
event.finish();
}
else event.finish();
@ -1835,8 +1830,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
target.chooseCard('he',(check?1:2),{type:(check?['trick','delay','equip']:'basic')},true);
'step 5'
if(result.cards){
player.gain(result.cards,target);
target.$giveAuto(result.cards,player);
player.gain(result.cards,target,'giveAuto');
}
},
subSkill:{
@ -2271,8 +2265,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
else{
if(event.e){
player.gain(event.e);
event.target.$give(event.e,player);
player.gain(event.e,event.target,'give');
player.addTempSkill('new_mumu2')
}
}
@ -2960,7 +2953,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
},
ly_piliche:{
trigger:{source:'damageEnd'},
trigger:{source:'damageSource'},
check:function(event,player){
return get.attitude(player,event.player)<0;
},
@ -3273,12 +3266,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){
global:"chooseToRespondBegin",
},
filter:function(event,player){
return player==event.source&&player!=event.player&&get.distance(player,event.player)<=1;
return player==event.source&&player!=event.player&&get.distance(event.player,player)<=1;
},
content:function(){},
mod:{
wuxieRespondable:function(card,player,target,current){
if(player!=current&&get.distance(player,current)<=1){
if(player!=current&&get.distance(current,player)<=1){
return false;
}
}
@ -3544,7 +3537,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
for(var i=0;i<list.length;i++){
list[i]=['锦囊','',list[i]];
}
player.chooseButton('矜功',[[list,'vcard']]).set('filterButton',function(button,player){
player.chooseButton(['矜功',[list,'vcard']]).set('filterButton',function(button,player){
return game.hasPlayer(function(current){
return player.canUse(button.link[2],current,true,false);
});
@ -3771,8 +3764,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
types.add(get.type(cards[i]));
}
player.logSkill('yirang',target);
player.$give(cards,target);
target.gain(cards,player);
target.gain(cards,player,'give');
player.gainMaxHp(target.maxHp-player.maxHp,true);
player.recover(types.length);
game.delay();
@ -3835,7 +3827,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
//ui.auto.show();
player.removeSkill('kuangcai_use');
player.removeSkill('kuangcai_cancel');
delete player.storage.counttrigger.kuangcai_use;
if(player.storage.counttrigger) delete player.storage.counttrigger.kuangcai_use;
}
}
},
@ -3849,6 +3841,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
direct:true,
filter:function(event,player){
if(event.cards){
if(event.cards.length<2) return false;
var suits=[];
for(var i=0;i<event.cards.length;i++){
var suit=get.suit(event.cards[i]);
@ -3867,7 +3860,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
'step 0'
player.chooseTarget(get.prompt('shejian'),'弃置一名其他角色的一张牌',function(card,player,target){
if(player==target) return false;
return target.countCards('he')>0;
return target.countDiscardableCards(player,'he')>0;
}).ai=function(target){
return -get.attitude(player,target);
};
@ -4328,8 +4321,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
player.logSkill('xiashu',result.targets);
event.target=result.targets[0];
var hs=player.getCards('h');
event.target.gain(hs,player);
player.$give(hs.length,event.target);
event.target.gain(hs,player,'giveAuto');
}
else{
event.finish();
@ -4395,12 +4387,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
'获得'+get.translation(event.target)+'未展示的牌']).set('choice',choice);
'step 5'
if(result.index==0){
player.gain(event.cards1,target);
target.$give(event.cards1,player);
player.gain(event.cards1,target,'give');
}
else{
player.gain(event.cards2,target);
target.$giveAuto(event.cards2,player);
player.gain(event.cards2,target,'giveAuto');
}
},
ai:{
@ -4526,7 +4516,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
player.chooseControl(function(event,player){
var target=event.target;
if(get.attitude(player,target)<0) return 1;
if(target.countCards('h')==target.hp+1) return 1;
return 0;
}).set('choiceList',['令'+get.translation(event.target)+'摸一张牌',
'令'+get.translation(event.target)+'弃置一张手牌']);
@ -4576,8 +4565,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
'step 4'
if(result.bool){
event.target.gain(result.cards,player);
player.$giveAuto(result.cards,event.target);
event.target.gain(result.cards,player,'giveAuto');
}
},
ai:{
@ -4904,7 +4892,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
intro:{
content:'mark'
},
trigger:{source:'damageAfter'},
trigger:{source:'damageSource'},
forced:true,
filter:function(event){
return event.card&&event.card.name=='sha';
@ -5962,10 +5950,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
multitarget:true,
content:function(){
'step 0'
player.$give(cards,targets[0]);
player.awakenSkill('jianshu');
player.storage.jianshu=true;
targets[0].gain(cards,player);
targets[0].gain(cards,player,'give');
'step 1'
targets[0].chooseToCompare(targets[1]);
'step 2'
@ -6018,7 +6005,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
content:function(){
'step 0'
player.chooseTarget(get.prompt2('yongdi'),function(card,player,target){
return target.sex=='male'&&target!=player;
return (target.sex=='male'||target.name=='key_yuri')&&target!=player;
}).set('ai',function(target){
if(!_status.event.goon) return 0;
var player=_status.event.player;
@ -6474,7 +6461,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},
zhidao:{
audio:2,
trigger:{source:'damageEnd'},
trigger:{source:'damageSource'},
filter:function(event,player){
if(event._notrigger.contains(event.player)) return false;
return _status.currentPhase==player&&event.player.isAlive()&&
@ -6517,7 +6504,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
},
},
trigger:{source:'damageEnd'},
trigger:{source:'damageSource'},
audio:2,
forced:true,
mark:true,
@ -6891,7 +6878,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},
canBeDiscarded:function (card,player){
if(player.getEquip(5)) return;
if(get.position(card)=='e') return false;
if(get.position(card)=='e'&&['equip2','equip5'].contains(get.subtype(card))) return false;
},
/*cardDiscardable:function (card,player){
if(player.getEquip(5)) return;
@ -8820,9 +8807,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){
direct:true,
content:function(){
'step 0'
trigger.player.chooseCardButton('选择获得一张“米”',player.storage.yishe);
event.count=trigger.num;
'step 1'
trigger.player.chooseCardButton('选择获得一张“米”',player.storage.yishe);
'step 2'
if(result.bool){
event.count--;
player.logSkill('bushi');
trigger.player.gain(result.links[0],'draw2','log','fromStorage');
player.storage.yishe.remove(result.links[0]);
@ -8833,6 +8823,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
else{
player.markSkill('yishe');
if(event.count>0) event.goto(1);
}
}
}
@ -9719,6 +9710,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
forced:true,
priority:10,
mark:'card',
filter:function(event){
return !event.directresult;
},
content:function(){
"step 0"
trigger.directresult=player.storage.zhoufu2;
@ -9928,8 +9922,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
event.finish();
}
"step 1"
trigger.target.gain(result.cards,player);
player.$give(result.cards,trigger.target);
trigger.target.gain(result.cards,player,'give');
game.delay();
event.card=result.cards[0];
if(get.type(event.card)!='equip'||trigger.target.isDisabled(get.subtype(event.card))) event.finish();
@ -10553,8 +10546,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
"step 0"
player.awakenSkill('cunsi');
var cards=player.getCards('h');
target.gain(cards,player);
player.$give(cards.length,target);
target.gain(cards,player,'giveAuto');
player.storage.cunsi=true;
game.delay();
target.addSkill('yongjue');
@ -10676,7 +10668,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
"step 1"
if(result.bool){
var nono=(get.damageEffect(trigger.player,player,trigger.player)>=0);
trigger.player.chooseToDiscard('he',{type:'equip'}).set('ai',function(card){
trigger.player.chooseToDiscard('he','弃置一张装备牌,或受到一点伤害',{type:'equip'}).set('ai',function(card){
if(_status.event.nono){
return 0;
}
@ -10874,16 +10866,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
"step 1"
var cards=player.getCards('h');
target.gain(cards,player);
target.gain(cards,player,'giveAuto');
event.num=cards.length;
player.$give(event.num,target);
game.delay();
"step 2"
target.chooseCard('选择还给'+get.translation(player)+'的牌',true,event.num);
game.delay(0.2);
"step 3"
player.gain(result.cards,target);
target.$give(result.cards.length,player);
player.gain(result.cards,target,'giveAuto');
game.delay();
}
},
@ -11169,7 +11159,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
},
huxiao:{
trigger:{source:'damageEnd'},
trigger:{source:'damageSource'},
silent:true,
filter:function(event,player){
if(event._notrigger.contains(event.player)) return false;
@ -11184,7 +11174,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
group:['huxiao_draw','huxiao_clear'],
subSkill:{
draw:{
trigger:{source:'damageAfter'},
trigger:{source:'damageSource'},
priority:-6,
filter:function(event,player){
if(!player.storage.huxiao||!player.storage.huxiao.length) return false;
@ -11212,7 +11202,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
},
clear:{
trigger:{source:'damageAfter'},
trigger:{source:'damageSource'},
priority:-7,
silent:true,
content:function(){
@ -11327,7 +11317,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
save:true,
result:{
player:function(player){
if(player.tempSkills.aocai4) return 0;
if(_status.event.dying) return get.attitude(player,_status.event.dying);
return 1;
}
@ -11788,15 +11777,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){
trigger:{player:'shaBefore'},
filter:function(event,player){
if(event.skill!='longdan_sha'&&event.skill!='fanghun_sha') return false;
return event.target.countCards('h')>0;
return event.target.countGainableCards(player,'h')>0;
},
logTarget:'target',
prompt2:'每当你发动“龙胆”使用或打出一张手牌时,你可以立即获得对方的一张手牌。',
content:function(){
var card=trigger.target.getCards('h').randomGet();
player.gain(card,trigger.target);
trigger.target.$giveAuto(card,player);
game.delay();
player.gainPlayerCard(trigger.target,'h',true);
}
},
chongzhen2:{
@ -11805,15 +11791,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){
filter:function(event,player){
if(event.skill!='longdan_shan'&&event.skill!='longdan_sha'&&
event.skill!='fanghun_shan'&&event.skill!='fanghun_sha') return false;
return event.source&&event.source.countCards('h')>0;
return event.source&&event.source.countGainableCards(player,'h')>0;
},
logTarget:'source',
prompt2:'每当你发动“龙胆”使用或打出一张手牌时,你可以立即获得对方的一张手牌。',
content:function(){
var card=trigger.source.getCards('h').randomGet();
player.gain(card,trigger.source);
trigger.source.$giveAuto(card,player);
game.delay();
player.gainPlayerCard(trigger.target,'h',true);
}
},
lihun:{
@ -11826,8 +11809,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
filterCard:true,
position:'he',
content:function(){
player.gain(target.getCards('h'),target);
target.$give(target.countCards('h'),player);
player.gain(target.getCards('h'),target,'giveAuto');
player.turnOver();
player.addSkill('lihun2');
player.storage.lihun=target;
@ -12220,7 +12202,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
},
kuangfu:{
trigger:{source:'damageEnd'},
trigger:{source:'damageSource'},
direct:true,
audio:2,
filter:function(event){
@ -12429,7 +12411,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
weicheng:'伪诚',
weicheng_info:'当其他角色获得你的手牌后,若你的手牌数小于体力值,你可以摸一张牌。',
daoshu:'盗书',
daoshu_info:'出牌阶段你可以选择一个花色并获得一名其他角色的一张手牌。若此牌花色与你选择的相同则你对其造成1点伤害。否则你须交给其一张与你选择的花色不同的手牌(没有则展示手牌),且本阶段内不能再发动【盗书】',
daoshu_info:'出牌阶段你可以选择一个花色并获得一名其他角色的一张手牌。若此牌花色与你选择的相同则你对其造成1点伤害。否则你须交给其一张与此牌花色不同的手牌(没有则展示手牌),且本阶段内不能再发动【盗书】',
xinshanjia:"缮甲",
"xinshanjia_info":"出牌阶段开始时你可以摸三张牌然后弃置3-X张牌(X为你本局游戏内失去过的装备区内的牌的数目且至多为3)。若你没有以此法弃置基本牌或锦囊牌,则你可以视为使用了一张不计入出牌阶段使用次数的【杀】。",

View File

@ -1786,8 +1786,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
event.choice=result.control;
target.popup(event.choice);
event.card=player.getCards('h').randomGet();
target.gain(event.card,player);
player.$give(event.card,target);
target.gain(event.card,player,'give');
game.delay();
"step 2"
if(get.suit(event.card)+'2'!=event.choice) target.damage('nocard');

View File

@ -344,9 +344,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
if(result.control!='cancel2'){
player.logSkill('twyanqin');
var group=result.control.slice(0,3);
player.group=group;
player.node.name.dataset.nature=get.groupnature(group);
game.log(player,'将势力变为了','#y'+get.translation(group+2));
player.changeGroup(group);
}
},
},
@ -504,10 +502,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
'step 1'
if(result.control!='cancel2'){
if(!event.renshe) player.logSkill('chijie');
var group=result.control;
player.group=group;
player.node.name.dataset.nature=get.groupnature(group);
game.log(player,'将势力变为了','#y'+get.translation(group));
player.changeGroup(result.control);
}
},
},

View File

@ -61,6 +61,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
if(result.bool&&result.targets&&result.targets.length){
player.logSkill('xinfu_langxi',result.targets);
var num=[1,2,0].randomGet();
if(get.isLuckyStar()) num=2;
player.line(result.targets[0],'green');
result.targets[0].damage(num);
}
@ -161,8 +162,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
else{
var card=target.getCards('hej').randomGet();
target.$giveAuto(card,player);
player.gain(card,target);
player.gain(card,target,'giveAuto');
}
},
ai:{
@ -274,8 +274,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
"step 1"
if(result.index==0){
var card=target.getCards('hej').randomGet();
target.$giveAuto(card,player);
player.gain(card,target);
player.gain(card,target,'giveAuto');
target.addTempSkill('tanbei_effect2','phaseAfter');
}
else{
@ -1184,12 +1183,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
content:function(){
"step 0"
event.togain=trigger.player.getCards('he');
event.shown=trigger.player.getCards('e');
var num=event.togain.length-event.shown.length;
player.gain(event.togain);
if(num) trigger.player.$give(num,player);
if(event.shown.length) trigger.player.$give(event.shown,player);
game.delay();
player.gain(event.togain,trigger.player,'giveAuto');
},
},
"xinfu_fujian":{
@ -1267,8 +1261,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
if(card1) list.push(card1);
if(card2) list.push(card2);
if(list.length>0){
trigger.player.$giveAuto(list,player);
player.gain(list,trigger.player);
player.gain(list,trigger.player,'giveAuto');
}
game.delay();
},
@ -2280,6 +2273,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
game.delay();
player.logSkill('xinfu_zhennan',result.targets);
var num=[1,2,3,1,1,2].randomGet();
if(get.isLuckyStar()) num=3;
player.line(result.targets[0],'fire');
result.targets[0].damage(num);
}
@ -2734,8 +2728,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
});
"step 2"
if(result.bool&&result.cards&&result.cards.length){
event.current.$giveAuto(result.cards,player);
player.gain(result.cards,event.current);
player.gain(result.cards,event.current,'giveAuto');
}
event.current=event.current.next;
if(event.current!=player) event.goto(1);
@ -4787,6 +4780,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
group:["xinfu_jingxie2"],
position:"he",
enable:"phaseUse",
filter:function(event,player){
var he=player.getCards('he');
for(var i=0;i<he.length;i++){
if(["bagua","baiyin","lanyinjia","renwang","tengjia","zhuge"].contains(he[i].name)) return true;
}
return false;
},
filterCard:function (card){
return ["bagua","baiyin","lanyinjia","renwang","tengjia","zhuge"].contains(card.name);
},
@ -4851,7 +4851,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
usable:1,
content:function (){
'step 0'
player.throwDice();
if(get.isLuckyStar()){
event.num=6;
player.throwDice(6);
}
else player.throwDice();
'step 1'
event.cards=get.cards(event.num);
player.showCards(event.cards);

View File

@ -1050,29 +1050,24 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},
content_choose:function(){
'step 0'
var index;
if(get.attitude(player,target)>0){
if(target.isHealthy()){
index=0;
}
else{
index=1;
}
if(target.isHealthy()){
event._result={index:0}
}
else{
if(target.isHealthy()&&target.countCards('e')){
var index;
if(get.attitude(player,target)>0){
index=1;
}
else{
index=0;
}
player.chooseControlList(
['令'+get.translation(target)+'失去1点体力随机使用一张装备牌',
'令'+get.translation(target)+'回复1点体力弃置一张装备牌'],
true,function(event,player){
return _status.event.index;
}).set('index',index);
}
player.chooseControlList(
['令'+get.translation(target)+'失去1点体力随机使用一张装备牌',
'令'+get.translation(target)+'回复1点体力弃置一张装备牌'],
true,function(event,player){
return _status.event.index;
}).set('index',index);
'step 1'
if(result.index==0){
target.loseHp();
@ -1773,7 +1768,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
"step 2"
if(event.target){
player.logSkill('wengua',event.target);
player.addTempSkill('wengua3');
player.addTempSkill('wengua3','phaseUseEnd');
event.card=cards[0];
if(event.target!=player){
player.give(cards,event.target);
@ -2574,8 +2569,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
'step 2'
var target=event.target;
if(result.bool){
player.gain(result.cards,target);
target.$give(result.cards,player);
player.gain(result.cards,target,'give');
}
else{
player.addTempSkill('taoluan3');
@ -2786,13 +2780,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
'step 2'
if(result.bool){
var card=result.links[0];
trigger.source.gain(card,player);
if(get.position(card)=='e'){
player.$give(card,trigger.source);
}
else{
player.$giveAuto(card,trigger.source);
}
trigger.source.gain(card,player,'giveAuto');
trigger.cancel();
player.storage.huisheng.push(trigger.source);
}
@ -3255,8 +3243,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
'step 2'
if(result.bool&&result.cards&&result.cards.length){
player.gain(result.cards,target);
target.$give(result.cards,player);
player.gain(result.cards,target,'give');
}
},
ai:{
@ -3533,7 +3520,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
},
xinjuece:{
audio:2,
audio:'juece',
trigger:{player:'phaseEnd'},
direct:true,
filter:function(event,player){
@ -3551,7 +3538,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
});
'step 1'
if(result.bool){
player.logSkill('juece',result.targets);
player.logSkill('xinjuece',result.targets);
result.targets[0].damage();
}
}
@ -3898,7 +3885,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
group:'lihuo2'
},
lihuo2:{
trigger:{source:'damageEnd'},
trigger:{source:'damageSource'},
forced:true,
popup:false,
filter:function(event,player){
@ -4155,7 +4142,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
group:'yonglve2'
},
yonglve2:{
trigger:{source:'damageAfter'},
trigger:{source:'damage'},
forced:true,
popup:false,
filter:function(event){
@ -4533,6 +4520,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
if(!_status.currentPhase) return false;
if(event.responded) return false;
if(!event.filterCard({name:'shan'})) return false;
if(!lib.filter.cardRespondable({name:'shan'},player,event)) return false;
return true;
},
check:function(event,player){
@ -4551,7 +4539,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
player.line(_status.currentPhase,'green');
_status.currentPhase.draw();
'step 1'
if(_status.currentPhase.isMaxHandcard()){
if(_status.currentPhase.isMaxHandcard(true)){
event.finish();
return;
}
@ -4669,7 +4657,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},
yaoming:{
audio:2,
trigger:{player:'damageEnd',source:'damageEnd'},
trigger:{player:'damageEnd',source:'damageSource'},
direct:true,
filter:function(event,player){
if(player.hasSkill('yaoming2')) return false;
@ -4858,8 +4846,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
'step 1'
if(result.bool){
var es=target.getCards('e');
player.gain(es,target);
target.$give(es,player);
player.gain(es,target,'give');
player.removeSkill('yanzhu');
}
else{
@ -5847,26 +5834,28 @@ game.import('character',function(lib,game,ui,get,ai,_status){
duodao:{
trigger:{player:'damageEnd'},
filter:function(event,player){
return player.countCards('he')>0&&event.source&&event.source.getEquip(1)!=undefined&&
return player.countCards('he')>0&&event.source&&
event.card&&event.card.name=='sha';
},
direct:true,
priority:5,
//priority:5,
audio:2,
content:function(){
'step 0'
var next=player.chooseToDiscard('he',get.prompt('duodao'),'弃置一张牌,然后获得'+get.translation(trigger.source)+'装备区中的'+trigger.source.getEquip(1));
var prompt='弃置一张牌'
if(trigger.source.getEquip(1)) prompt+=(',然后获得'+get.translation(trigger.source)+'装备区中的'+get.translation(trigger.source.getEquip(1)));
var next=player.chooseToDiscard('he',get.prompt('duodao',trigger.source),prompt);
next.logSkill=['duodao',trigger.source];
next.set('ai',function(card){
if(!_status.event.getTrigger().source.getEquip(1)) return 0;
if(get.attitude(_status.event.player,_status.event.getTrigger().source)<=0){
return 6-get.value(card);
}
return 0;
});
'step 1'
if(result.bool){
trigger.source.$give(trigger.source.getEquip(1),player);
player.gain(trigger.source.getEquip(1),trigger.source);
if(result.bool&&trigger.source.getEquip(1)){
player.gain(trigger.source.getEquip(1),trigger.source,'give');
}
},
ai:{
@ -6084,7 +6073,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
group:'fuhun2'
},
fuhun2:{
trigger:{source:'damageAfter'},
trigger:{source:'damageSource'},
forced:true,
filter:function(event,player){
if(player.hasSkill('fuhun3')) return false;
@ -6703,12 +6692,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
return 0;
});
"step 2"
trigger.player.gain(result.cards,player);
if(player==game.me||trigger.player==game.me)
player.$give(result.cards,trigger.player);
else
player.$give(2,trigger.player);
game.delay();
trigger.player.gain(result.cards,player,'giveAuto');
trigger.player.addSkill('xiantu2');
trigger.player.storage.xiantu=player;
},
@ -6929,9 +6913,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
});
"step 3"
if(result.bool){
player.gain(result.cards,event.target);
event.target.$give(1,player);
game.delay();
player.gain(result.cards,event.target,'giveAuto');
trigger.untrigger();
trigger.player=event.target;
trigger.trigger('useCard');
@ -7094,9 +7076,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
"step 0"
player.awakenSkill('xianzhou');
var cards=player.getCards('e');
target.gain(cards,player);
target.gain(cards,player,'give');
event.num=cards.length;
player.$give(cards,target);
player.storage.xianzhou=true;
game.delay();
"step 1"
@ -7296,8 +7277,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
"step 2"
if(result.bool){
player.gain(result.cards,event.target);
event.target.$give(result.cards,player);
player.gain(result.cards,event.target,'giveAuto');
game.delay();
}
else{
@ -7517,8 +7497,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
event.giver=giver;
'step 1'
var card=result.cards[0];
event.gainner.gain(card,event.giver);
event.giver.$give(1,event.gainner);
event.gainner.gain(card,event.giver,'giveAuto');
'step 2'
if(event.gainner.countCards('h')==event.giver.countCards('h')){
player.chooseDrawRecover(true);
@ -7805,8 +7784,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}).set('check',check);
"step 2"
if(result.bool){
result.targets[0].gain(result.cards,event.player);
event.player.$give(result.cards.length,result.targets[0]);
result.targets[0].gain(result.cards,event.player,'giveAuto');
player.line(result.targets,'green');
}
},
@ -8321,7 +8299,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
},
olddanshou:{
trigger:{source:'damageEnd'},
trigger:{source:'damageSource'},
priority:9,
check:function(event,player){
return get.attitude(player,event.player)<=0;
@ -8392,8 +8370,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
if(num!=2) event.finish();
'step 1'
if(result.cards){
player.gain(result.cards,target);
target.$give(result.cards.length,player);
player.gain(result.cards,target,'giveAuto');
}
},
ai:{
@ -8697,8 +8674,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
});
"step 2"
if(result.bool){
player.gain(result.cards[0],trigger.source);
trigger.source.$give(1,player);
player.gain(result.cards,trigger.source,'giveAuto');
}
else{
trigger.source.loseHp();
@ -8781,8 +8757,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
});
"step 1"
if(result.bool){
player.gain(result.cards[0],trigger.source);
trigger.source.$give(1,player);
player.gain(result.cards,'giveAuto',trigger.source);
}
else{
trigger.source.loseHp();
@ -8830,8 +8805,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}).set('source',target);
"step 3"
if(result.bool){
result.targets[0].gain(card,player);
player.$give(1,result.targets[0]);
result.targets[0].gain(card,player,'give');
game.delay();
}
},
@ -8960,7 +8934,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},
pojun:{
audio:2,
trigger:{source:'damageEnd'},
trigger:{source:'damageSource'},
check:function(event,player){
if(event.player.isTurnedOver()) return get.attitude(player,event.player)>0;
if(event.player.hp<3){
@ -9539,7 +9513,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}
},
zyexin:{
trigger:{player:'damageEnd',source:'damageEnd'},
trigger:{player:'damageEnd',source:'damageSource'},
frequent:true,
init:function(player){
player.storage.zyexin=[];

View File

@ -1,5 +1,5 @@
window.noname_asset_list=[
'1.9.93.1',
'1.9.93.3',
'audio/background/aozhan_chaoming.mp3',
'audio/background/aozhan_online.mp3',
'audio/background/music_danji.mp3',
@ -2234,6 +2234,10 @@ window.noname_asset_list=[
'image/character/old_zhangfei.jpg',
'image/character/old_zhoutai.jpg',
'image/character/wenyang.jpg',
'image/character/re_wangyun.jpg',
'image/character/key_yuri.jpg',
'image/character/key_kyousuke.jpg',
'image/character/key_lucia.jpg',
'image/character/baiwuchang.jpg',
'image/character/baosanniang.jpg',
@ -2798,7 +2802,6 @@ window.noname_asset_list=[
'image/character/re_yuanshao.jpg',
'image/character/re_yuanshu.jpg',
'image/character/re_yuji.jpg',
'image/character/re_yujin.jpg',
'image/character/re_zhangfei.jpg',
'image/character/re_zhangliang.jpg',
'image/character/re_zhangliao.jpg',

View File

@ -457,6 +457,12 @@
init:false,
unfrequent:true
},
lucky_star:{
name:'幸运星模式',
intro:'在涉及随机数等的技能中,必定得到效果最好的结果。(联机模式无效)',
init:false,
unfrequent:true
},
dev:{
name:'开发者模式',
intro:'开启后可使用浏览器控制台控制游戏,同时可更新到开发版',
@ -5900,7 +5906,7 @@
'<li>玩家的上/下家(含阵亡)<br>game.me.previousSeat/<br>nextSeat'+
'<li>牌堆<br>ui.cardPile<li>弃牌堆<br>ui.discardPile</ul>'+
'<div style="margin:10px">角色属性</div><ul style="margin-top:0"><li>体力值<br>player.hp'+
'<li>体力上限<br>player.maxHp<li>身份<br>player.identity<li>手牌<br>player.get("h")<li>装备牌<br>player.get("e")<li>判定牌<br>player.get("j")'+
'<li>体力上限<br>player.maxHp<li>身份<br>player.identity<li>手牌<br>player.getCards("h")<li>装备牌<br>player.getCards("e")<li>判定牌<br>player.getCards("j")'+
'<li>是否存活/横置/翻面<br>player.isAlive()/<br>isLinked()/<br>isTurnedOver()</ul>'+
'<div style="margin:10px">角色操作</div><ul style="margin-top:0"><li>受到伤害<br>player.damage(source,<br>num)'+
'<li>回复体力<br>player.recover(num)<li>摸牌<br>player.draw(num)<li>获得牌<br>player.gain(cards)<li>弃牌<br>player.discard(cards)'+
@ -9517,7 +9523,16 @@
}
else event.targets2=[];
if(!event.forced){
player.chooseBool('是否'+(event.targets2.length?'对':'')+get.translation(event.targets2)+'使用'+get.translation(card)+'?');
var next=player.chooseBool();
next.prompt=event.prompt||('是否'+(event.targets2.length?'对':'')+get.translation(event.targets2)+'使用'+get.translation(card)+'?');
if(event.prompt2) next.prompt2=event.prompt2;
next.ai=function(){
var eff=0;
for(var i=0;i<event.targets2.length;i++){
eff+=get.effect(event.targets2[i],card,player,player);
}
return eff>0;
};
}
else event._result={bool:true};
}
@ -9539,11 +9554,11 @@
if(event.forced) next.forced=true;
next.targets=targets;
next.prompt=event.prompt||('选择'+get.translation(card)+'的目标');
if(event.prompt2) next.prompt2=event.prompt2;
if(event.prompt2) next.prompt2=event.prompt2;
}
'step 1'
if(result.bool){
event._result={
event.result={
bool:true,
targets:event.targets2||result.targets,
};
@ -9555,7 +9570,8 @@
player.logSkill.apply(player,event.logSkill);
}
}
var next=player.useCard(card,event.targets2||result.targets,cards);
var next=player.useCard(card,event.targets2||result.targets);
if(cards) next.cards=cards;
if(event.nopopup) next.nopopup=true;
if(event.animate===false) next.animate=false;
if(event.addCount===false) next.addCount=false;
@ -9832,11 +9848,34 @@
};
},
disableJudge:function(){
'step 0'
game.log(player,'废除了判定区');
var js=player.getCards('j');
if(js.length) player.discard(js);
player.storage._disableJudge=true;
player.markSkill('_disableJudge');
game.log(player,'废除了判定区');
//player.markSkill('_disableJudge');
'step 1'
game.broadcastAll(function(player,card){
card.fix();
card.classList.add('feichu');
card.style.transform='';
card.classList.add('drawinghidden');
player.node.judges.insertBefore(card,player.node.judges.firstChild);
ui.updatej(player);
},player,game.createCard('disable_judge','',''));
},
enableJudge:function(){
if(!player.storage._disableJudge) return;
game.log(player,'恢复了判定区');
game.broadcastAll(function(player){
player.storage._disableJudge=false;
for(var i=0;i<player.node.judges.childNodes.length;i++){
if(player.node.judges.childNodes[i].name=='disable_judge'){
player.node.judges.removeChild(player.node.judges.childNodes[i]);
break;
}
}
},player);
},
/*----分界线----*/
phasing:function(){
@ -12847,22 +12886,16 @@
event.cards=cards;
event.trigger("rewriteGainResult");
"step 4"
if(event.visibleMove){
target.$give(cards,player);
}
else{
target.$giveAuto(cards,player);
}
"step 5"
if(event.boolline){
player.line(target,'green');
}
if(!event.chooseonly){
var next=player.gain(event.cards,target);
var next=player.gain(event.cards,target,event.visibleMove?'give':'giveAuto');
if(event.delay===false){
next.set('delay',false);
}
}
else target[event.visibleMove?'$give':'$giveAuto'](cards,player);
},
showHandcards:function(){
"step 0"
@ -13160,20 +13193,6 @@
if(event.animate!=false&&event.line!=false){
if((card.name=='wuxie'||card.name=='youdishenru')&&event.getParent().source){
var lining=event.getParent().sourcex||event.getParent().source2||event.getParent().source;
if(get.mode()=='guozhan'&&card.hasTag&&card.hasTag('guo')){
if(!Array.isArray(lining)){
lining=[lining];
}
if(lining.length){
var evt=event.getParent()._trigger;
lining.addArray(game.filterPlayer(function(current){
return current.sameIdentityAs(lining[0],true)&&evt.targets&&evt.targets.contains(current);
}));
}
if(lining.length==1){
lining=lining[0];
}
}
if(lining==player&&event.getParent().sourcex2){
lining=event.getParent().sourcex2;
}
@ -13331,6 +13350,7 @@
if(targets[num]&&targets[num].isOut()) return;
if(targets[num]&&targets[num].removed) return;
if(targets[num]&&event.excluded.contains(targets[num])) return;
if(targets[num]&&info.ignoreTarget&&info.ignoreTarget(card,player,targets[num])) return;
if(targets.length==0&&!info.notarget) return;
var next=game.createEvent(card.name);
next.setContent(info.content);
@ -13906,7 +13926,7 @@
event.finish();
return;
}
if(event.source&&event.delay!==false) game.delayx();
//if(event.source&&event.delay!==false) game.delayx();
"step 2"
if(player.getStat().gain==undefined){
player.getStat().gain=cards.length;
@ -14138,6 +14158,7 @@
},
damage:function(){
"step 0"
event.forceDie=true;
if(num<0) num=0;
if(num>0&&player.hujia&&!player.hasSkillTag('nohujia')){
if(num>=player.hujia){
@ -14255,6 +14276,8 @@
}
}
}
"step 3"
if(!event.notrigger) event.trigger('damageSource');
},
recover:function(){
if(lib.config.background_audio){
@ -14864,6 +14887,13 @@
},
player:{
//新函数
changeGroup:function(group,log){
game.broadcastAll(function(player,group){
player.group=group;
player.node.name.dataset.nature=get.groupnature(group);
},this,group);
if(log!==false) game.log(this,'将势力变为了','#y'+get.translation(group+2));
},
chooseToDuiben:function(target){
var next=game.createEvent('chooseToDuiben');
next.player=this;
@ -14994,6 +15024,13 @@
next.setContent('disableJudge');
return next;
},
enableJudge:function(){
var next=game.createEvent('enableJudge');
next.player=this;
next.source=_status.event.player;
next.setContent('enableJudge');
return next;
},
//原有函数
init:function(character,character2,skill){
if(typeof character=='string'&&!lib.character[character]){
@ -15992,7 +16029,7 @@
}
else if(arg1[i]=='j'){
for(j=0;j<this.node.judges.childElementCount;j++){
if(!this.node.judges.childNodes[j].classList.contains('removing')){
if(!this.node.judges.childNodes[j].classList.contains('removing')&&!this.node.judges.childNodes[j].classList.contains('feichu')){
cards.push(this.node.judges.childNodes[j]);
if(this.node.judges.childNodes[j].viewAs&&arguments.length>1){
this.node.judges.childNodes[j].tempJudge=this.node.judges.childNodes[j].name;
@ -16141,7 +16178,7 @@
var es=[];
if(arg3!==false){
for(i=0;i<this.node.equips.childElementCount;i++){
if(!this.node.equips.childNodes[i].classList.contains('removing')){
if(!this.node.equips.childNodes[i].classList.contains('removing')&&!this.node.equips.childNodes[i].classList.contains('feichu')){
var equipskills=get.info(this.node.equips.childNodes[i]).skills;
if(equipskills){
es.addArray(equipskills);
@ -16182,19 +16219,19 @@
for(i=0;i<arg1.length;i++){
if(arg1[i]=='h'){
for(j=0;j<this.node.handcards1.childElementCount;j++){
if(!this.node.handcards1.childNodes[j].classList.contains('removing')){
if(!this.node.handcards1.childNodes[j].classList.contains('removing')&&!this.node.handcards1.childNodes[j].classList.contains('feichu')){
cards.push(this.node.handcards1.childNodes[j]);
}
}
for(j=0;j<this.node.handcards2.childElementCount;j++){
if(!this.node.handcards2.childNodes[j].classList.contains('removing')){
if(!this.node.handcards2.childNodes[j].classList.contains('removing')&&!this.node.handcards2.childNodes[j].classList.contains('feichu')){
cards.push(this.node.handcards2.childNodes[j]);
}
}
}
else if(arg1[i]=='e'){
for(j=0;j<this.node.equips.childElementCount;j++){
if(!this.node.equips.childNodes[j].classList.contains('removing')){
if(!this.node.equips.childNodes[j].classList.contains('removing')&&!this.node.equips.childNodes[j].classList.contains('feichu')){
cards.push(this.node.equips.childNodes[j]);
}
}
@ -16207,7 +16244,7 @@
}
else if(arg1[i]=='j'){
for(j=0;j<this.node.judges.childElementCount;j++){
if(!this.node.judges.childNodes[j].classList.contains('removing')){
if(!this.node.judges.childNodes[j].classList.contains('removing')&&!this.node.judges.childNodes[j].classList.contains('feichu')){
cards.push(this.node.judges.childNodes[j]);
if(this.node.judges.childNodes[j].viewAs&&arguments.length>1){
this.node.judges.childNodes[j].tempJudge=this.node.judges.childNodes[j].name;
@ -18025,7 +18062,7 @@
var next=game.createEvent('dying');
next.player=this;
next.reason=reason;
next.source=reason.source;
if(reason&&reason.source) next.source=reason.source;
next.setContent('dying');
return next;
},
@ -30768,8 +30805,8 @@
if(!info.intro) info.intro={};
if(info.intro.content===undefined) info.intro.content='limited';
if(info.skillAnimation===undefined) info.skillAnimation=true;
if(info.init===undefined) info.init=function(player){
player.storage[i]=false;
if(info.init===undefined) info.init=function(player,skill){
player.storage[skill]=false;
}
}
if(info.subSkill&&!sub){
@ -45432,6 +45469,10 @@
},
};
var get={
isLuckyStar:function(){
if(_status.connectMode) return false;
return lib.config.lucky_star==true;
},
infoHp:function(hp){
if(typeof hp=='number') return hp;
else if(typeof hp=='string'&&hp.indexOf('/')!=-1){
@ -48286,7 +48327,7 @@
uiintro.add('<div class="text center">特殊'+get.translation(lib.card[name].type)+'牌</div>');
}
else{
uiintro.add('<div class="text center">'+get.translation(lib.card[name].type)+'牌</div>');
if(lib.card[name].type&&lib.translate[lib.card[name].type]) uiintro.add('<div class="text center">'+get.translation(lib.card[name].type)+'牌</div>');
}
}
if(lib.card[name].unique&&lib.card[name].type=='equip'){

View File

@ -1,27 +1,30 @@
window.noname_update={
version:'1.9.93.2',
update:'1.9.93.1',
version:'1.9.93.3',
update:'1.9.93.2',
changeLog:[
'手杀王允',
'无懈可击结算调整',
'BUG修复',
],
files:[
//'card/extra.js',
//'card/sp.js',
//'card/standard.js',
'card/swd.js',
//'card/guozhan.js',
//'character/diy.js',
'card/extra.js',
'card/sp.js',
'card/standard.js',
//'card/swd.js',
'card/guozhan.js',
'character/diy.js',
'character/extra.js',
'character/mobile.js',
'character/old.js',
//'character/old.js',
'character/refresh.js',
'character/shenhua.js',
'character/sp.js',
'character/tw.js',
//'character/standard.js',
'character/standard.js',
'character/xinghuoliaoyuan.js',
'character/yijiang.js',
'mode/guozhan.js',
'mode/doudizhu.js',
//'mode/guozhan.js',
//'mode/boss.js',
'game/game.js',
]

Binary file not shown.

After

Width:  |  Height:  |  Size: 150 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 160 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 289 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 29 KiB

View File

@ -750,20 +750,23 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
},
logAi:function(targets,card){},
showIdentity:function(){
this.node.identity.classList.remove('guessing');
this.identityShown=true;
this.ai.shown=1;
this.setIdentity();
if(this.identity=='zhu'){
this.isZhu=true;
}
if(_status.clickingidentity){
for(var i=0;i<_status.clickingidentity[1].length;i++){
_status.clickingidentity[1][i].delete();
_status.clickingidentity[1][i].style.transform='';
game.broadcastAll(function(player,identity){
player.identity=identity;
player.node.identity.classList.remove('guessing');
player.identityShown=true;
player.ai.shown=1;
player.setIdentity();
if(player.identity=='zhu'){
player.isZhu=true;
}
delete _status.clickingidentity;
}
if(_status.clickingidentity){
for(var i=0;i<_status.clickingidentity[1].length;i++){
_status.clickingidentity[1][i].delete();
_status.clickingidentity[1][i].style.transform='';
}
delete _status.clickingidentity;
}
},this,this.identity);
}
}
},