This commit is contained in:
libccy 2017-03-27 17:12:10 +08:00
parent 6073f072f0
commit df742e4737
23 changed files with 200 additions and 200 deletions

View File

@ -75,7 +75,7 @@ card.extra={
if(lib.config.mode=='stone'&&!player.isMin()){
if(player.getActCount()+1>=player.actcount) return 0;
}
var shas=player.get('h','sha');
var shas=player.getCards('h','sha');
if(shas.length>1&&player.getCardUsable('sha')>1){
return 0;
}
@ -439,7 +439,7 @@ card.extra={
if(player.hasSkillTag('unequip',false,card)) return;
if(card.name=='nanman'||card.name=='wanjian') return 'zerotarget';
if(card.name=='sha'){
var equip1=player.get('e','1');
var equip1=player.getEquip(1);
if(equip1&&equip1.name=='zhuque') return 2;
if(equip1&&equip1.name=='qinggang') return 1;
if(!card.nature) return 'zerotarget';

View File

@ -1010,7 +1010,7 @@ card.guozhan={
enable:'phaseUse',
prompt:'将可连横的牌交给一名与你势力不同的角色,或未确定势力的角色,若你交给与你势力不同的角色,则你摸一张牌',
filter:function(event,player){
return (player.get('h',function(card){
return (player.getCards('h',function(card){
return get.info(card).lianheng;
}).length);
},

View File

@ -299,7 +299,7 @@ card.sp={
for(var i=0;i<cards.length;i++){
ui.special.appendChild(cards[i]);
}
var muniu=player.get('e','5');
var muniu=player.getEquip(5);
if(!muniu){
for(var i=0;i<cards.length;i++){
ui.discardPile.appendChild(cards[i]);
@ -313,7 +313,7 @@ card.sp={
muniu.cards=cards;
},muniu,muniu.cards);
var players=game.filterPlayer(function(current){
if(!current.get('e','5')&&current!=player&&!current.isTurnedOver()&&
if(!current.getEquip(5)&&current!=player&&!current.isTurnedOver()&&
ai.get.attitude(player,current)>=3&&ai.get.attitude(current,player)>=3){
return true;
}
@ -321,7 +321,7 @@ card.sp={
players.sort(lib.sort.seat);
var choice=players[0];
var next=player.chooseTarget('是否移动木牛流马?',function(card,player,target){
return !target.isMin()&&player!=target&&!target.get('e','5');
return !target.isMin()&&player!=target&&!target.getEquip(5);
});
next.set('ai',function(target){
return target==_status.event.choice?1:-1;
@ -329,7 +329,7 @@ card.sp={
next.set('choice',choice);
"step 1"
if(result.bool){
var card=player.get('e','5');
var card=player.getEquip(5);
result.targets[0].equip(card);
player.$give(card,result.targets[0]);
player.line(result.targets,'green');
@ -344,7 +344,7 @@ card.sp={
respondSha:true,
respondShan:true,
skillTagFilter:function(player,tag){
var muniu=player.get('e','5');
var muniu=player.getEquip(5);
if(!muniu||!muniu.cards) return false;
for(var i=0;i<muniu.cards.length;i++){
switch(tag){
@ -375,7 +375,7 @@ card.sp={
trigger:{player:'chooseToRespondBegin'},
filter:function(event,player){
if(event.responded) return false;
var muniu=player.get('e','5');
var muniu=player.getEquip(5);
if(!muniu.cards) return false;
lib.skill.muniu_skill.sync(muniu);
for(var i=0;i<muniu.cards.length;i++){
@ -386,7 +386,7 @@ card.sp={
direct:true,
content:function(){
"step 0"
player.chooseButton(['木牛流马',player.get('e','5').cards]).set('filterButton',function(button){
player.chooseButton(['木牛流马',player.getEquip(5).cards]).set('filterButton',function(button){
var evt=_status.event.getTrigger();
if(evt&&evt.filterCard){
return evt.filterCard(button.link,_status.event.player,evt);
@ -408,7 +408,7 @@ card.sp={
trigger.untrigger();
trigger.responded=true;
trigger.result={bool:true,card:result.links[0]};
var muniu=player.get('e','5');
var muniu=player.getEquip(5);
muniu.cards.remove(result.links[0]);
lib.skill.muniu_skill.sync(muniu);
player.updateMarks();
@ -423,7 +423,7 @@ card.sp={
muniu_skill4:{
enable:'chooseToUse',
filter:function(event,player){
var muniu=player.get('e','5');
var muniu=player.getEquip(5);
if(!muniu.cards) return false;
lib.skill.muniu_skill.sync(muniu);
for(var i=0;i<muniu.cards.length;i++){
@ -433,7 +433,7 @@ card.sp={
},
chooseButton:{
dialog:function(event,player){
return ui.create.dialog('木牛流马',player.get('e','5').cards,'hidden');
return ui.create.dialog('木牛流马',player.getEquip(5).cards,'hidden');
},
filter:function(button,player){
var evt=_status.event.getParent();
@ -449,7 +449,7 @@ card.sp={
if(get.select(get.info(button.link).selectTarget)[1]==-1){
if(get.type(button.link)=='delay') return -1;
if(get.type(button.link)=='equip'){
var current=player.get('e',{subtype:get.subtype(button.link)})[0];
var current=player.getCards('e',{subtype:get.subtype(button.link)})[0];
if(current&&ai.get.equipValue(current)>=ai.get.equipValue(button.link)) return -1;
return 1;
}
@ -470,7 +470,7 @@ card.sp={
selectCard:-1,
viewAs:links[0],
onuse:function(result,player){
var muniu=player.get('e','5');
var muniu=player.getEquip(5);
if(muniu&&muniu.cards){
muniu.cards.remove(result.card);
lib.skill.muniu_skill.sync(muniu);
@ -499,7 +499,7 @@ card.sp={
mark:true,
intro:{
content:function(storage,player){
var muniu=player.get('e','5');
var muniu=player.getEquip(5);
if(!muniu||!muniu.cards||!muniu.cards.length) return '共有〇张牌';
if(player.isUnderControl(true)){
return get.translation(muniu.cards);
@ -509,7 +509,7 @@ card.sp={
}
},
mark:function(dialog,storage,player){
var muniu=player.get('e','5');
var muniu=player.getEquip(5);
if(!muniu||!muniu.cards||!muniu.cards.length) return '共有〇张牌';
if(player.isUnderControl(true)){
dialog.addAuto(muniu.cards);
@ -519,7 +519,7 @@ card.sp={
}
},
markcount:function(storage,player){
var muniu=player.get('e','5');
var muniu=player.getEquip(5);
if(muniu&&muniu.cards) return muniu.cards.length;
return 0;
}
@ -528,7 +528,7 @@ card.sp={
muniu_skill7:{
filter:function(){return false},
hiddenCard:function(player,name){
var muniu=player.get('e','5');
var muniu=player.getEquip(5);
if(!muniu.cards) return false;
lib.skill.muniu_skill.sync(muniu);
for(var i=0;i<muniu.cards.length;i++){

View File

@ -868,8 +868,8 @@ card.standard={
if(ai.get.damageEffect(target,player,target)>0&&ai.get.attitude(player,target)>0&&ai.get.attitude(target,player)>0){
return 0;
}
var hs1=target.get('h','sha');
var hs2=player.get('h','sha');
var hs1=target.getCards('h','sha');
var hs2=player.getCards('h','sha');
if(hs1.length>hs2.length+1){
return -2;
}
@ -1026,7 +1026,7 @@ card.standard={
complexTarget:true,
filterTarget:function(card,player,target){
if(ui.selected.targets.length==0){
return (player!=target&&target.get('e',{subtype:'equip1'}).length);
return (player!=target&&target.getCards('e',{subtype:'equip1'}).length);
}
else{
return lib.filter.filterTarget({name:'sha'},ui.selected.targets[0],target);
@ -1043,8 +1043,8 @@ card.standard={
}
"step 1"
if(event.directfalse||result.bool==false){
player.gain(targets[0].get('e',{subtype:'equip1'}),targets[0]);
targets[0].$give(targets[0].get('e',{subtype:'equip1'}),player);
player.gain(targets[0].getCards('e',{subtype:'equip1'}),targets[0]);
targets[0].$give(targets[0].getCards('e',{subtype:'equip1'}),player);
}
},
ai:{
@ -1056,7 +1056,7 @@ card.standard={
result:{
target:-1.5,
player:function(player){
if(player.get('he',{subtype:'equip1'}).length) return 0;
if(player.getCards('he',{subtype:'equip1'}).length) return 0;
return 1.5;
},
},
@ -1459,7 +1459,7 @@ card.standard={
content:function(){
"step 0"
var next=player.chooseToDiscard(get.prompt('guanshi'),2,'he',function(card){
return _status.event.player.get('e',{subtype:'equip1'}).contains(card)==false;
return _status.event.player.getCards('e',{subtype:'equip1'}).contains(card)==false;
});
next.logSkill='guanshi_skill';
next.set('ai',function(card){
@ -1499,7 +1499,7 @@ card.standard={
qilin_skill:{
trigger:{player:'shaHit'},
filter:function(event,player){
return event.target.get('e',{subtype:['equip3','equip4']}).length>0
return event.target.getCards('e',{subtype:['equip3','equip4']}).length>0
},
direct:true,
audio:true,
@ -1508,7 +1508,7 @@ card.standard={
var att=(ai.get.attitude(player,trigger.target)<=0);
var next=player.chooseButton();
next.set('att',att);
next.set('createDialog',['选择要弃置的马',trigger.target.get('e',{subtype:['equip3','equip4']})]);
next.set('createDialog',['选择要弃置的马',trigger.target.getCards('e',{subtype:['equip3','equip4']})]);
next.set('ai',function(button){
if(_status.event.att) return ai.get.buttonValue(button);
return 0;

View File

@ -97,8 +97,8 @@ card.swd={
choice='basic';
}
else{
var e2=target.get('e','2');
var e3=target.get('e','3');
var e2=target.getEquip(2);
var e3=target.getEquip(3);
if((e2&&e3)||((e2||e3)&&target.needsToDiscard()<=1)||Math.random()<0.5){
choice='trick';
}
@ -346,7 +346,7 @@ card.swd={
},
content:function(){
'step 0'
var cards=target.get('h',function(card){
var cards=target.getCards('h',function(card){
return get.type(card)!='basic';
});
if(cards.length){
@ -1117,7 +1117,7 @@ card.swd={
order:4,
result:{
target:function(player,target){
if(target.get('e','2')){
if(target.getEquip(2)){
if(target.countCards('h')&&!target.hasSkillTag('noe')) return -0.6;
return 0;
}
@ -1611,7 +1611,7 @@ card.swd={
if(lib.config.mode=='stone'&&!player.isMin()){
if(player.getActCount()+1>=player.actcount) return false;
}
var shas=player.get('h','sha');
var shas=player.getCards('h','sha');
if(shas.length>1&&player.getCardUsable('sha')>1){
return 0;
}
@ -2265,7 +2265,7 @@ card.swd={
player.storage.shuchui2=false;
event.num=0;
'step 1'
var card=player.get('h','sha')[0];
var card=player.getCards('h','sha')[0];
if(card){
player.useCard(card,target);
}
@ -2407,7 +2407,7 @@ card.swd={
},
content:function(){
'step 0'
player.showCards(get.translation(player)+'发动了【青龙之圭】',player.get('h','qinglongzhigui'));
player.showCards(get.translation(player)+'发动了【青龙之圭】',player.getCards('h','qinglongzhigui'));
player.draw(2);
'step 1'
player.chooseToDiscard('he',true);
@ -2429,7 +2429,7 @@ card.swd={
};
"step 1"
if(result.bool){
player.showCards(get.translation(player)+'发动了【白兽之琥】',player.get('h','baishouzhihu'));
player.showCards(get.translation(player)+'发动了【白兽之琥】',player.getCards('h','baishouzhihu'));
player.logSkill('_baishouzhihu',result.targets);
player.discardPlayerCard(result.targets[0],'he',true);
}
@ -2450,7 +2450,7 @@ card.swd={
},
content:function(){
'step 0'
player.showCards(get.translation(player)+'发动了【朱雀之璋】',player.get('h','zhuquezhizhang'));
player.showCards(get.translation(player)+'发动了【朱雀之璋】',player.getCards('h','zhuquezhizhang'));
trigger.source.damage('fire');
'step 1'
game.delay();
@ -2463,7 +2463,7 @@ card.swd={
return player.num('h','xuanwuzhihuang')>0&&event.num>0&&player.hp<player.maxHp;
},
content:function(){
player.showCards(get.translation(player)+'发动了【玄武之璜】',player.get('h','xuanwuzhihuang'));
player.showCards(get.translation(player)+'发动了【玄武之璜】',player.getCards('h','xuanwuzhihuang'));
player.recover(trigger.num);
}
},
@ -2474,7 +2474,7 @@ card.swd={
return !player.hujia&&player.num('h','huanglinzhicong')>0;
},
content:function(){
player.showCards(get.translation(player)+'发动了【黄麟之琮】',player.get('h','huanglinzhicong'));
player.showCards(get.translation(player)+'发动了【黄麟之琮】',player.getCards('h','huanglinzhicong'));
player.changeHujia();
player.update();
},
@ -2496,7 +2496,7 @@ card.swd={
};
'step 1'
if(result.bool){
player.showCards(get.translation(player)+'发动了【苍螭之璧】',player.get('h','cangchizhibi'));
player.showCards(get.translation(player)+'发动了【苍螭之璧】',player.getCards('h','cangchizhibi'));
player.logSkill('_cangchizhibi',result.targets);
for(var i=0;i<result.targets.length;i++){
result.targets[i].link();
@ -3186,7 +3186,7 @@ card.swd={
trigger.finish();
player.hp=1;
player.draw();
player.discard(player.get('e',{subtype:'equip5'}));
player.discard(player.getCards('e',{subtype:'equip5'}));
game.delay();
}
},
@ -3487,7 +3487,7 @@ card.swd={
hslingjian_zhongxinghujia_equip1:{
trigger:{source:'damageEnd'},
check:function(event,player){
return !player.get('e','2');
return !player.getEquip(2);
},
filter:function(event){
return event.card&&event.card.name=='sha';
@ -3505,24 +3505,24 @@ card.swd={
return ai.get.attitude(player,event.source)<0;
},
filter:function(event){
return event.card&&event.card.name=='sha'&&event.source&&event.source.get('e','2');
return event.card&&event.card.name=='sha'&&event.source&&event.source.getEquip(2);
},
content:function(){
player.line(trigger.source,'green');
trigger.source.discard(trigger.source.get('e','2'));
trigger.source.discard(trigger.source.getEquip(2));
}
},
hslingjian_zhongxinghujia_equip3:{
mod:{
globalTo:function(from,to,distance){
if(to.get('e','2')) return distance+1;
if(to.getEquip(2)) return distance+1;
}
}
},
hslingjian_zhongxinghujia_equip4:{
mod:{
globalFrom:function(from,to,distance){
if(from.get('e','2')) return distance-1;
if(from.getEquip(2)) return distance-1;
}
}
},
@ -3549,7 +3549,7 @@ card.swd={
order:1,
result:{
target:function(player,target){
if(target.get('e','2')) return 0;
if(target.getEquip(2)) return 0;
return 1;
}
}
@ -4082,7 +4082,7 @@ card.swd={
complexCard:true,
filter:function(event,player){
if(!player.num('h',{type:['hslingjian','jiqi']})) return false;
var es=player.get('he',{type:'equip'});
var es=player.getCards('he',{type:'equip'});
for(var i=0;i<es.length;i++){
if(lib.inpile.contains(es[i].name)&&
!lib.card[es[i].name].nopower&&
@ -4321,7 +4321,7 @@ card.swd={
trigger.finish();
player.hp=1;
player.draw();
player.discard(player.get('e',{subtype:'equip5'}));
player.discard(player.getCards('e',{subtype:'equip5'}));
game.delay();
}
},

View File

@ -192,7 +192,7 @@ card.yunchou={
event.finish();
}
else{
var hs=target.get('h','sha');
var hs=target.getCards('h','sha');
player.gain(hs,target);
target.$give(hs,player);
}
@ -529,19 +529,19 @@ card.yunchou={
filterTarget:function(card,player,target){
if(target.isMin()) return false;
if(ui.selected.targets.length){
return target.get('e',{subtype:'equip5'}).length==0;
return target.getCards('e',{subtype:'equip5'}).length==0;
}
else{
return target.get('e',{subtype:'equip5'}).length>0;
return target.getCards('e',{subtype:'equip5'}).length>0;
}
},
selectTarget:2,
multitarget:true,
complexTarget:true,
content:function(){
if(target.get('e','5')){
target.$give(target.get('e','5'),event.addedTarget);
event.addedTarget.equip(target.get('e','5'));
if(target.getEquip(5)){
target.$give(target.getEquip(5),event.addedTarget);
event.addedTarget.equip(target.getEquip(5));
game.delay();
}
},
@ -549,7 +549,7 @@ card.yunchou={
order:1,
result:{
target:function(player,target){
if(target.get('e',{subtype:'equip5'}).length){
if(target.getCards('e',{subtype:'equip5'}).length){
if(ai.get.attitude(target,player)>0){
return -0.5;
}

View File

@ -229,7 +229,7 @@ character.diy={
'step 0'
var bool=false;
var subtype=get.subtype(trigger.cards[0]);
var current=trigger.player.get('e',subtype[5]);
var current=trigger.player.getEquip('e',parseInt(subtype[5]));
var att=ai.get.attitude(trigger.player,player);
if(current){
if(att>0){
@ -746,7 +746,7 @@ character.diy={
usable:1,
discard:false,
filter:function(event,player){
var cards=player.get('he',{color:'black'});
var cards=player.getCards('he',{color:'black'});
for(var i=0;i<cards.length;i++){
var type=get.type(cards[i]);
if(type=='basic') return true;
@ -903,7 +903,7 @@ character.diy={
return event.source&&event.source!=player&&event.source.num('he',{color:'red'})>0;
},
content:function(){
trigger.source.discard(trigger.source.get('he',{color:'red'}));
trigger.source.discard(trigger.source.getCards('he',{color:'red'}));
},
ai:{
expose:0.1,

View File

@ -206,7 +206,7 @@ character.extra={
result:{
player:function(player){
if(!player.storage.shenfen) return 0;
var cards=player.get('h','sha');
var cards=player.getCards('h','sha');
if(cards.length){
if(game.hasPlayer(function(current){
return (player.canUse('sha',current)&&

View File

@ -1851,7 +1851,7 @@ character.hearth={
result:{
player:1,
target:function(player,target){
if(target.get('e','1')) return 0;
if(target.getEquip(1)) return 0;
return 1;
}
}
@ -4707,10 +4707,10 @@ character.hearth={
enable:'phaseUse',
usable:1,
filter:function(event,player){
return player.get('e','1')?true:false;
return player.getEquip(1)?true:false;
},
filterCard:function(card,player){
return card==player.get('e','1');
return card==player.getEquip(1);
},
position:'e',
filterTarget:function(card,player,target){

View File

@ -232,7 +232,7 @@ character.ow={
if(card.name=='sha'){
if(_status.event.name=='qianggu2') return;
if(ai.get.attitude(player,target)>0) return;
var bs=player.get('h',{type:'basic'});
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.num('h','sha')<=1){
@ -1279,7 +1279,7 @@ character.ow={
player.storage.baoxue=true;
player.awakenSkill('baoxue');
player.showHandcards();
player.discard(player.get('he',{color:'black'}));
player.discard(player.getCards('he',{color:'black'}));
}
'step 1'
if(!get.is.altered('baoxue')){

View File

@ -579,7 +579,7 @@ character.refresh={
target.gain(cards[0],player);
"step 1"
target.chooseControl('refanjian_card','refanjian_hp').ai=function(event,player){
var cards=player.get('he',{suit:get.suit(player.storage.refanjian)});
var cards=player.getCards('he',{suit:get.suit(player.storage.refanjian)});
if(cards.length==1) return 0;
if(cards.length>=2){
for(var i=0;i<cards.length;i++){
@ -603,7 +603,7 @@ character.refresh={
event.finish();
}
"step 3"
target.discard(target.get('he',{suit:get.suit(target.storage.refanjian)}))
target.discard(target.getCards('he',{suit:get.suit(target.storage.refanjian)}))
delete target.storage.refanjian;
},
ai:{

View File

@ -420,7 +420,7 @@ character.shenhua={
animationColor:'metal',
content:function(){
'step 0'
var shas=player.get('h','sha');
var shas=player.getCards('h','sha');
var num;
if(player.hp>=4&&shas.length>=3){
num=3;
@ -455,7 +455,7 @@ character.shenhua={
result:{
player:function(player){
if(player.hp==1) return 0;
var shas=player.get('h','sha');
var shas=player.getCards('h','sha');
if(!shas.length) return 0;
var card=shas[0];
if(!lib.filter.cardEnabled(card,player)) return 0;
@ -655,7 +655,7 @@ character.shenhua={
target:function(card,player,target,current){
if(card.name=='sha'){
if(_status.event.name=='xiangle') return;
var bs=player.get('h',{type:'basic'});
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.num('h','sha')<=1){
@ -893,11 +893,11 @@ character.shenhua={
var players=game.filterPlayer();
for(var i=0;i<players.length;i++){
if(ai.get.attitude(player,players[i])>0){
if((target.get('e','1')&&!players[i].get('e','1'))||
(target.get('e','2')&&!players[i].get('e','2'))||
(target.get('e','3')&&!players[i].get('e','3'))||
(target.get('e','4')&&!players[i].get('e','4'))||
(target.get('e','5')&&!players[i].get('e','5'))) return -ai.get.attitude(player,target);
if((target.getEquip(1)&&!players[i].getEquip(1))||
(target.getEquip(2)&&!players[i].getEquip(2))||
(target.getEquip(3)&&!players[i].getEquip(3))||
(target.getEquip(4)&&!players[i].getEquip(4))||
(target.getEquip(5)&&!players[i].getEquip(5))) return -ai.get.attitude(player,target);
}
}
}
@ -914,11 +914,11 @@ character.shenhua={
if(!target.hasJudge(judges[i].viewAs||judges[i].name)) return true;
}
if(target.isMin()) return false;
if((from.get('e','1')&&!target.get('e','1'))||
(from.get('e','2')&&!target.get('e','2'))||
(from.get('e','3')&&!target.get('e','3'))||
(from.get('e','4')&&!target.get('e','4'))||
(from.get('e','5')&&!target.get('e','5'))) return true;
if((from.getEquip(1)&&!target.getEquip(1))||
(from.getEquip(2)&&!target.getEquip(2))||
(from.getEquip(3)&&!target.getEquip(3))||
(from.getEquip(4)&&!target.getEquip(4))||
(from.getEquip(5)&&!target.getEquip(5))) return true;
return false;
}
else{
@ -2617,7 +2617,7 @@ character.shenhua={
inherit:'bagua_skill',
filter:function(event,player){
if(!lib.skill.bagua_skill.filter(event,player)) return false;
if(player.get('e','2')) return false;
if(player.getEquip(2)) return false;
return true;
},
ai:{
@ -2626,7 +2626,7 @@ character.shenhua={
if(player==target&&get.subtype(card)=='equip2'){
if(ai.get.equipValue(card)<=7.5) return 0;
}
if(target.get('e','2')) return;
if(target.getEquip(2)) return;
return lib.skill.bagua_skill.ai.effect.target.apply(this,arguments);
}
}
@ -2966,13 +2966,13 @@ character.shenhua={
order:8,
result:{
player:function(player,target){
if(player.get('e','1')) return 0;
if(player.getEquip(1)) return 0;
if(player.hp>=target.hp) return -0.9;
if(player.hp<=2) return -10;
return -2;
},
target:function(player,target){
if(!player.get('e','1')){
if(!player.getEquip(1)){
if(player.hp<2) return 0;
if(player.hp==2&&target.hp>=2) return 0;
if(target.hp>player.hp) return 0;

View File

@ -570,7 +570,7 @@ character.sp={
'step 3'
event.target.showCards(result.cards);
event.cards1=result.cards;
event.cards2=event.target.get('h',function(card){
event.cards2=event.target.getCards('h',function(card){
return !event.cards1.contains(card);
});
'step 4'
@ -903,7 +903,7 @@ character.sp={
result:{
player:function(player,target){
if(get.distance(player,target)<=1) return 0;
var hs=player.get('h','shunshou');
var hs=player.getCards('h','shunshou');
if(hs.length&&player.canUse(hs[0],target,false)){
return 1;
}
@ -2357,8 +2357,8 @@ character.sp={
if(player.countCards('h')>player.hp) return -0.1;
return 0;
}
var hs1=target.get('h','sha');
var hs2=player.get('h','sha');
var hs1=target.getCards('h','sha');
var hs2=player.getCards('h','sha');
if(hs1.length>hs2.length){
return 0;
}
@ -3013,7 +3013,7 @@ character.sp={
inherit:'bagua_skill',
filter:function(event,player){
if(!lib.skill.bagua_skill.filter(event,player)) return false;
if(player.get('e','2')) return false;
if(player.getEquip(2)) return false;
return true;
},
ai:{
@ -3022,18 +3022,18 @@ character.sp={
if(player==target&&get.subtype(card)=='equip2'){
if(ai.get.equipValue(card)<=7.5) return 0;
}
if(target.get('e','2')) return;
if(target.getEquip(2)) return;
return lib.skill.bagua_skill.ai.effect.target.apply(this,arguments);
}
}
},
mod:{
maxHandcard:function(player,num){
if(player.get('e','3')||player.get('e','4')) return;
if(player.getEquip(3)||player.getEquip(4)) return;
return num+1;
},
targetInRange:function(card,player,target,now){
if(player.get('e','5')) return;
if(player.getEquip(5)) return;
var type=get.type(card);
if(type=='trick'||type=='delay') return true;
}
@ -3137,7 +3137,7 @@ character.sp={
var save=false;
if(ai.get.attitude(player,trigger.target)>2){
if(trigger.card.name=='sha'){
if(player.num('h','shan')||player.get('e','2')||
if(player.num('h','shan')||player.getEquip(2)||
trigger.target.hp==1||player.hp>trigger.target.hp+1){
if(!trigger.target.num('h','shan')||trigger.target.countCards('h')<player.countCards('h')){
save=true;
@ -3958,7 +3958,7 @@ character.sp={
logTarget:'player',
check:function(event,player){
if(ai.get.attitude(player,event.player)>=0) return false;
var e2=player.get('e','2');
var e2=player.getEquip(2);
if(e2){
if(e2.name=='tengjia') return true;
if(e2.name=='bagua') return true;
@ -4058,17 +4058,17 @@ character.sp={
},
filterTarget:function(card,player,target){
if(target==player) return false;
return target.get('e','1')||target.get('e','2');
return target.getEquip(1)||target.getEquip(2);
},
content:function(){
'step 0'
var e1=target.get('e','1');
var e2=target.get('e','2');
var e1=target.getEquip(1);
var e2=target.getEquip(2);
event.e1=e1;
event.e2=e2;
if(e1&&e2){
player.chooseControl('武器牌','防具牌').set('ai',function(){
if(_status.event.player.get('e','2')){
if(_status.event.player.getEquip(2)){
return '武器牌';
}
return '防具牌';
@ -4099,7 +4099,7 @@ character.sp={
order:8,
result:{
target:function(player,target){
if(target.get('e','2')&&!player.get('e','2')){
if(target.getEquip(2)&&!player.getEquip(2)){
return -2;
}
return -1;
@ -5802,7 +5802,7 @@ character.sp={
check:function(event,player){
if(player.isTurnedOver()) return true;
var num=game.countPlayer(function(current){
return current.get('e','1');
return current.getEquip(1);
});
return num>1;
},
@ -5811,7 +5811,7 @@ character.sp={
player.turnOver();
"step 1"
var num=game.countPlayer(function(current){
return current.get('e','1');
return current.getEquip(1);
});
player.draw(2+num);
player.addSkill('kuiwei2');
@ -5830,7 +5830,7 @@ character.sp={
audio:false,
content:function(){
var num=game.countPlayer(function(current){
return current.get('e','1');
return current.getEquip(1);
});
if(num>=player.countCards('he')){
player.discard(player.getCards('he'));
@ -5956,7 +5956,7 @@ character.sp={
"step 2"
if(!trigger.target.isMin()){
trigger.target.chooseBool('是否装备'+get.translation(event.card)+'').set('ai',function(){
var current=_status.event.player.get('e',{subtype:get.subtype(_status.event.card)});
var current=_status.event.player.getCards('e',{subtype:get.subtype(_status.event.card)});
if(current&&current.length){
return ai.get.equipValue(event.card)>ai.get.equipValue(current[0]);
}

View File

@ -298,7 +298,7 @@ character.swd={
return distance-from.countCards('e')*2;
},
cardUsable:function(card,player,num){
if(card.name=='sha'&&player.get('e','5')) return num+1;
if(card.name=='sha'&&player.getEquip(5)) return num+1;
}
},
group:['lingshi_hit','lingshi_draw'],
@ -306,7 +306,7 @@ character.swd={
hit:{
trigger:{player:'shaBegin'},
filter:function(event,player){
return player.get('e','1')||player.get('e','2');
return player.getEquip(1)||player.getEquip(2);
},
forced:true,
content:function(){
@ -316,7 +316,7 @@ character.swd={
draw:{
trigger:{player:'phaseDrawBegin'},
filter:function(event,player){
return player.get('e','3')||player.get('e','4');
return player.getEquip(3)||player.getEquip(4);
},
forced:true,
content:function(){
@ -678,7 +678,7 @@ character.swd={
for(var i=0;i<enemies.length;i++){
if(player.canUse('sha',enemies[i])&&
ai.get.effect(enemies[i],{name:'sha'},player,player)>0&&
!enemies[i].get('e','2')&&num>enemies[i].hp&&enemies[i].hp<=2){
!enemies[i].getEquip(2)&&num>enemies[i].hp&&enemies[i].hp<=2){
return 1;
}
}
@ -1153,17 +1153,17 @@ character.swd={
pingxu:{
mod:{
globalFrom:function(from,to,current){
if(!from.get('e','1')) return current-1;
if(!from.getEquip(1)) return current-1;
},
globalTo:function(from,to,current){
if(!to.get('e','2')) return current+1;
if(!to.getEquip(2)) return current+1;
},
}
},
jufu:{
trigger:{source:'damageBegin'},
filter:function(event,player){
if(event.card&&event.card.name=='sha'&&player.get('e','1')) return true;
if(event.card&&event.card.name=='sha'&&player.getEquip(1)) return true;
return false;
},
forced:true,
@ -1649,7 +1649,7 @@ character.swd={
"step 0"
target.showHandcards();
"step 1"
var cards=target.get('h','shan');
var cards=target.getCards('h','shan');
if(cards.length){
target.discard(cards);
}
@ -1848,7 +1848,7 @@ character.swd={
"step 0"
var save=false;
if(ai.get.attitude(player,trigger.target)>2){
if(player.num('h','shan')||player.get('e','2')||
if(player.num('h','shan')||player.getEquip(2)||
trigger.target.hp==1||player.hp>trigger.target.hp+1){
if(!trigger.target.num('h','shan')||trigger.target.countCards('h')<player.countCards('h')){
save=true;
@ -2753,7 +2753,7 @@ character.swd={
return current!=player&&current.num('e','xuanyuanjian');
});
if(target){
var card=target.get('e','xuanyuanjian');
var card=target.getEquip('xuanyuanjian');
player.gain(card,target);
target.$give(card,player);
player.line(target,'green');
@ -3018,7 +3018,7 @@ character.swd={
usable:1,
filter:function(){
return game.countPlayer(function(current){
return current.get('e','1');
return current.getEquip(1);
})>=1;
},
filterTarget:function(card,player,target){
@ -3030,7 +3030,7 @@ character.swd={
event.num=0;
var players=game.filterPlayer();
for(var i=0;i<players.length;i++){
if(players[i].get('e','1')){
if(players[i].getEquip(1)){
event.targets.push(players[i]);
}
}
@ -3038,7 +3038,7 @@ character.swd={
"step 1"
if(num<event.targets.length){
var targetn=event.targets[num];
var card=targetn.get('e','1');
var card=targetn.getEquip(1);
if(card){
targetn.discard(card);
}
@ -3054,7 +3054,7 @@ character.swd={
result:{
target:function(player,target){
var num=game.countPlayer(function(current){
return current.get('e','1');
return current.getEquip(1);
});
if(target.hp==1&&num<3){
return (num-3)/1.5;
@ -3110,7 +3110,7 @@ character.swd={
return ai.get.attitude(player,event.player)<0;
},
content:function(){
var hs=trigger.player.get('h',function(card){
var hs=trigger.player.getCards('h',function(card){
return get.type(card)!='basic';
});
if(get.is.altered('tuzhen')){
@ -3654,7 +3654,7 @@ character.swd={
trigger:{player:'damageBegin'},
forced:true,
filter:function(event,player){
if(player.get('e','2')) return false;
if(player.getEquip(2)) return false;
return lib.skill.guangshatianyi.filter(event,player);
},
content:function(){
@ -5624,14 +5624,14 @@ character.swd={
if(!player.countCards('he')) return false;
if(event.filterCard({name:'shan'})){
if(game.hasPlayer(function(current){
return current!=player&&current.get('e','2');
return current!=player&&current.getEquip(2);
})){
return true;
}
}
if(event.filterCard({name:'sha'})){
if(game.hasPlayer(function(current){
return current!=player&&current.get('e','1');
return current!=player&&current.getEquip(1);
})){
return true;
}
@ -5645,12 +5645,12 @@ character.swd={
var players=game.filterPlayer();
if(trigger.filterCard({name:'shan'})){
for(var i=0;i<players.length;i++){
if(players[i]!=player&&players[i].get('e','2')) list.push(players[i].get('e','2'));
if(players[i]!=player&&players[i].getEquip(2)) list.push(players[i].getEquip(2));
}
}
if(trigger.filterCard({name:'sha'})){
for(var i=0;i<players.length;i++){
if(players[i]!=player&&players[i].get('e','1')) list.push(players[i].get('e','1'));
if(players[i]!=player&&players[i].getEquip(1)) list.push(players[i].getEquip(1));
}
}
var dialog=ui.create.dialog('神工',list);
@ -5689,14 +5689,14 @@ character.swd={
if(he<=1) return;
if(get.tag(card,'respondShan')){
if(game.hasPlayer(function(current){
return current!=target&&current.get('e','2')&&ai.get.attitude(target,current)<=0;
return current!=target&&current.getEquip(2)&&ai.get.attitude(target,current)<=0;
})){
return 0.6/he;
}
}
if(get.tag(card,'respondSha')){
if(game.hasPlayer(function(current){
return current!=target&&current.get('e','2')&&ai.get.attitude(target,current)<=0;
return current!=target&&current.getEquip(2)&&ai.get.attitude(target,current)<=0;
})){
return 0.6/he;
}
@ -5910,20 +5910,20 @@ character.swd={
duoren:{
trigger:{target:'shaMiss'},
filter:function(event){
return event.player.get('e','1')!=undefined;
return event.player.getEquip(1)!=undefined;
},
check:function(event,player){
return ai.get.attitude(player,event.player)<0;
},
priority:5,
content:function(){
trigger.player.$give(trigger.player.get('e','1'),player);
player.gain(trigger.player.get('e','1'),trigger.player);
trigger.player.$give(trigger.player.getEquip(1),player);
player.gain(trigger.player.getEquip(1),trigger.player);
},
ai:{
effect:{
target:function(card,player,target,current){
if(card.name=='sha'&&target.countCards('h')>1&&player.get('e','1')){
if(card.name=='sha'&&target.countCards('h')>1&&player.getEquip(1)){
return [1,0.5,0,-0.5];
}
}
@ -6054,7 +6054,7 @@ character.swd={
"step 1"
if(result.bool){
player.logSkill('tanlin');
trigger.source.discard(trigger.source.get('h',lib.sort.random,result.cards.length));
trigger.source.randomDiscard('h',result.cards.length);
}
else{
event.finish();
@ -8050,10 +8050,10 @@ character.swd={
yunshen_old:{
mod:{
globalFrom:function(from,to,distance){
if(!from.get('e','1')) return distance-1;
if(!from.getEquip(1)) return distance-1;
},
globalTo:function(from,to,distance){
if(!to.get('e','2')) return distance+1;
if(!to.getEquip(2)) return distance+1;
}
}
},
@ -8658,7 +8658,7 @@ character.swd={
shending:{
inherit:'longfan',
filter:function(event,player){
return !player.get('e','5');
return !player.getEquip(5);
},
ai:{
order:11,
@ -8679,10 +8679,10 @@ character.swd={
poxiao:{
mod:{
attackFrom:function(from,to,distance){
if(!from.get('e','1')) return distance-1;
if(!from.getEquip(1)) return distance-1;
},
selectTarget:function(card,player,range){
if(!player.get('e','1')&&card.name=='sha') range[1]++;
if(!player.getEquip(1)&&card.name=='sha') range[1]++;
}
},
enable:'chooseToUse',

View File

@ -26,7 +26,7 @@ character.xiake={
rouquan:{
mod:{
selectTarget:function(card,player,range){
if(card.name=='sha'&&!player.get('e','1')&&range[1]!=-1) range[1]=Infinity;
if(card.name=='sha'&&!player.getEquip(1)&&range[1]!=-1) range[1]=Infinity;
}
},
enable:'phaseUse',
@ -41,7 +41,7 @@ character.xiake={
check:function(card,player){
var val=ai.get.equipValue(card);
var player=_status.event.player;
var cards=player.get('h',{subtype:get.subtype(card)});
var cards=player.getCards('h',{subtype:get.subtype(card)});
for(var i=0;i<cards.length;i++){
if(ai.get.equipValue(cards[i])>=val){
return 1;

View File

@ -563,7 +563,7 @@ character.xianjian={
return !event.targets.contains(target);
}).ai=function(target){
var att=ai.get.attitude(player,target);
if(att>0&&!target.get('e','5')){
if(att>0&&!target.getEquip(5)){
return att;
}
return 0;
@ -1814,7 +1814,7 @@ character.xianjian={
},
check:function(event,player){
if(ai.get.attitude(player,event.player)<=0) return false;
var cards=player.get('h',{color:'red'});
var cards=player.getCards('h',{color:'red'});
for(var i=0;i<cards.length;i++){
if(cards[i].name=='tao') return false;
if(ai.get.value(cards[i])>7&&cards.length>2) return false;
@ -1824,7 +1824,7 @@ character.xianjian={
"step 0"
player.showHandcards();
"step 1"
var cards=player.get('h',{color:'red'});
var cards=player.getCards('h',{color:'red'});
event.num=cards.length;
player.discard(cards);
"step 2"

View File

@ -1448,11 +1448,11 @@ character.yijiang={
player.showCards(cards);
'step 1'
ui.cardPile.insertBefore(cards[0],ui.cardPile.firstChild);
var n1=target.get('he',function(card){
var n1=target.getCards('he',function(card){
if(!lib.filter.cardDiscardable(card,player)) return false;
return get.type(card,'trick')=='trick';
});
var n2=target.get('he',function(card){
var n2=target.getCards('he',function(card){
if(!lib.filter.cardDiscardable(card,player)) return false;
return get.type(card,'trick')!='trick';
});
@ -1507,12 +1507,12 @@ character.yijiang={
return ai.get.attitude(player,event.player)<0;
},
filter:function(event,player){
return event.card&&event.card.name=='sha'&&player.get('e','1');
return event.card&&event.card.name=='sha'&&player.getEquip(1);
},
content:function(){
'step 0'
var num=1;
var info=get.info(player.get('e','1'));
var info=get.info(player.getEquip(1));
if(info&&info.distance&&info.distance.attackFrom){
num-=info.distance.attackFrom;
}
@ -1540,7 +1540,7 @@ character.yijiang={
}
'step 1'
if(!event.directfalse&&result.bool){
var e1=player.get('e','1');
var e1=player.getEquip(1);
if(e1){
player.discard(e1);
}
@ -2455,10 +2455,10 @@ character.yijiang={
'step 2'
var cards;
if(event.control=='红色'){
cards=player.get('h',{color:'red'});
cards=player.getCards('h',{color:'red'});
}
else{
cards=player.get('h',{color:'black'});
cards=player.getCards('h',{color:'black'});
}
player.discard(cards);
event.num=cards.length;
@ -2578,8 +2578,8 @@ character.yijiang={
result:{
target:function(player,target){
if(target.hasSkillTag('noe')) return 1;
if(target.get('e','1')||target.get('e','4')) return -1;
if(target.get('e','2')) return -0.7;
if(target.getEquip(1)||target.getEquip(4)) return -1;
if(target.getEquip(2)) return -0.7;
return -0.5;
}
}
@ -3189,7 +3189,7 @@ character.yijiang={
if(!event.filterCard({name:'shan'})) return false;
if(player.hasSkill('huomo2')) return false;
if(event.parent.name!='sha') return false;
var hs=player.get('he',{color:'black'});
var hs=player.getCards('he',{color:'black'});
for(var i=0;i<hs.length;i++){
if(get.type(hs[i])!='basic'){
break;
@ -3664,7 +3664,7 @@ character.yijiang={
duodao:{
trigger:{player:'damageEnd'},
filter:function(event,player){
return player.countCards('he')>0&&event.source&&event.source.get('e','1')!=undefined&&
return player.countCards('he')>0&&event.source&&event.source.getEquip(1)!=undefined&&
event.card&&event.card.name=='sha';
},
check:function(event,player){
@ -3685,8 +3685,8 @@ character.yijiang={
});
'step 1'
if(result.bool){
trigger.source.$give(trigger.source.get('e','1'),player);
player.gain(trigger.source.get('e','1'),trigger.source);
trigger.source.$give(trigger.source.getEquip(1),player);
player.gain(trigger.source.getEquip(1),trigger.source);
}
},
},
@ -5748,7 +5748,7 @@ character.yijiang={
forced:true,
audio:2,
filter:function(event,player){
if(player.get('e','2')) return false;
if(player.getEquip(2)) return false;
return (event.card.name=='sha'&&get.color(event.card)=='black')
},
content:function(){
@ -5761,7 +5761,7 @@ character.yijiang={
if(player==target&&get.subtype(card)=='equip2'){
if(ai.get.equipValue(card)<=8) return 0;
}
if(target.get('e','2')) return;
if(target.getEquip(2)) return;
if(card.name=='sha'&&get.color(card)=='black') return 'zerotarget';
}
}
@ -5925,7 +5925,7 @@ character.yijiang={
}
}
if(num<=0) return 0;
var e2=target.get('e','2');
var e2=target.getEquip(2);
if(e2){
if(e2.name=='tengjia'){
if(!player.num('h',{name:'sha',nature:'fire'})&&!player.num('e','zhuque')) return 0;
@ -6639,7 +6639,7 @@ character.yijiang={
},
check:function(event,player){
if(event.player.isUnderControl(true,player)){
return event.player.get('h',function(card){
return event.player.getCards('h',function(card){
return get.type(card)!='basic';
}).length>0;
}

View File

@ -574,7 +574,7 @@ character.yxs={
zyhufu:{
trigger:{player:'phaseDrawBegin'},
filter:function(event,player){
return !player.get('e','2');
return !player.getEquip(2);
},
forced:true,
content:function(){
@ -585,7 +585,7 @@ character.yxs={
},
mod:{
maxHandcard:function(player,num){
if(player.get('e','2')) return num+5;
if(player.getEquip(2)) return num+5;
}
}
},
@ -593,7 +593,7 @@ character.yxs={
trigger:{player:'shaBegin'},
forced:true,
filter:function(event,player){
if(player.get('e','3')||player.get('e','4')) return true;
if(player.getEquip(3)||player.getEquip(4)) return true;
return false;
},
content:function(){
@ -1132,7 +1132,7 @@ character.yxs={
hanqiang:{
mod:{
attackFrom:function(from,to,distance){
if(!from.get('e','1')) return distance-1
if(!from.getEquip(1)) return distance-1
}
}
},
@ -2049,7 +2049,7 @@ character.yxs={
if(trigger.target.hasSkill('shejie2')) return 0;
if(trigger.target.hasSkill('shanguang2')) return 0;
var equip=trigger.target.get('e','2');
var equip=trigger.target.getEquip(2);
if(equip&&equip.name=='bagua') return 1;
return trigger.target.countCards('h')<2?0:1;
};
@ -2481,11 +2481,11 @@ character.yxs={
if(!target.hasJudge(judges[i].viewAs||judges[i].name)) return true;
}
if(target.isMin()) return false;
if((from.get('e','1')&&!target.get('e','1'))||
(from.get('e','2')&&!target.get('e','2'))||
(from.get('e','3')&&!target.get('e','3'))||
(from.get('e','4')&&!target.get('e','4'))||
(from.get('e','5')&&!target.get('e','5'))) return true;
if((from.getEquip(1)&&!target.getEquip(1))||
(from.getEquip(2)&&!target.getEquip(2))||
(from.getEquip(3)&&!target.getEquip(3))||
(from.getEquip(4)&&!target.getEquip(4))||
(from.getEquip(5)&&!target.getEquip(5))) return true;
return false;
}
else{
@ -2534,11 +2534,11 @@ character.yxs={
var players=game.filterPlayer();
for(var i=0;i<players.length;i++){
if(ai.get.attitude(player,players[i])>0){
if((target.get('e','1')&&!players[i].get('e','1'))||
(target.get('e','2')&&!players[i].get('e','2'))||
(target.get('e','3')&&!players[i].get('e','3'))||
(target.get('e','4')&&!players[i].get('e','4'))||
(target.get('e','5')&&!players[i].get('e','5')))
if((target.getEquip(1)&&!players[i].getEquip(1))||
(target.getEquip(2)&&!players[i].getEquip(2))||
(target.getEquip(3)&&!players[i].getEquip(3))||
(target.getEquip(4)&&!players[i].getEquip(4))||
(target.getEquip(5)&&!players[i].getEquip(5)))
return -1;
}
}

View File

@ -112,7 +112,7 @@ character.zhuogui={
forced:true,
priority:6,
filter:function(event,player){
if(player.get('e','2')) return false;
if(player.getEquip(2)) return false;
if(event.player.num('s','unequip')) return false;
if(event.card.name=='nanman') return true;
if(event.card.name=='wanjian') return true;
@ -125,11 +125,11 @@ character.zhuogui={
ai:{
effect:{
target:function(card,player,target,current){
if(target.get('e','2')) return;
if(target.getEquip(2)) return;
if(player.num('s','unequip')) return;
if(card.name=='nanman'||card.name=='wanjian') return 0;
if(card.name=='sha'){
var equip1=player.get('e','1');
var equip1=player.getEquip(1);
if(equip1&&equip1.name=='zhuque') return 2;
if(equip1&&equip1.name=='qinggang') return 1;
if(!card.nature) return 0;
@ -141,7 +141,7 @@ character.zhuogui={
manjia2:{
trigger:{player:'damageBegin'},
filter:function(event,player){
if(player.get('e','2')) return false;
if(player.getEquip(2)) return false;
if(event.nature=='fire') return true;
},
forced:true,
@ -154,7 +154,7 @@ character.zhuogui={
ai:{
effect:{
target:function(card,player,target,current){
if(target.get('e','2')) return;
if(target.getEquip(2)) return;
if(card.name=='sha'){
if(card.nature=='fire'||player.hasSkill('zhuque_skill')) return 2;
}

View File

@ -11635,7 +11635,7 @@
game.addVideo('gain2',player,get.cardsInfo([card.clone]));
}
player.equiping=true;
player.lose(player.get('e',{subtype:get.subtype(card)}),false);
player.lose(player.getCards('e',{subtype:get.subtype(card)}),false);
"step 2"
if(player.isMin()){
event.finish();
@ -13812,8 +13812,8 @@
position=arguments[i];
}
}
var cards=this.get(position,num);
if(cards){
var cards=this.getCards(position).randomGets(num);
if(cards.length){
this.discard(cards);
}
return cards;

View File

@ -2220,7 +2220,7 @@ mode.boss={
forced:true,
priority:6,
filter:function(event,player){
if(player.get('e','2')) return false;
if(player.getEquip(2)) return false;
return lib.skill.tengjia1.filter(event,player);
},
content:function(){
@ -2230,7 +2230,7 @@ mode.boss={
ai:{
effect:{
target:function(card,player,target,current){
if(target.get('e','2')) return;
if(target.getEquip(2)) return;
return lib.skill.tengjia1.ai.effect.target.apply(this,arguments);
}
}
@ -2239,7 +2239,7 @@ mode.boss={
boss_manjia2:{
trigger:{player:'damageBegin'},
filter:function(event,player){
if(player.get('e','2')) return false;
if(player.getEquip(2)) return false;
if(event.nature=='fire') return true;
},
forced:true,
@ -2252,7 +2252,7 @@ mode.boss={
ai:{
effect:{
target:function(card,player,target,current){
if(target.get('e','2')) return;
if(target.getEquip(2)) return;
return lib.skill.tengjia2.ai.effect.target.apply(this,arguments);
}
}
@ -2452,7 +2452,7 @@ mode.boss={
var players=game.filterPlayer();
for(var i=0;i<players.length;i++){
if(players[i]!=player){
var e=players[i].get('e','qinggang');
var e=players[i].getEquip('qinggang');
if(e.length){
player.gain(e,players[i]);
players[i].$give(e,player);
@ -3292,11 +3292,11 @@ mode.boss={
mod:{
selectTarget:function(card,player,range){
if(range[1]==-1) return;
if(player.get('e','1')) return;
if(player.getEquip(1)) return;
if(card.name=='sha') range[1]+=2;
},
cardUsable:function(card,player,num){
if(player.get('e','1')) return;
if(player.getEquip(1)) return;
if(card.name=='sha') return num+1;
}
},
@ -3507,7 +3507,7 @@ mode.boss={
else{
player.chooseControl(list,function(){
if(!player.getStat().skill.qiangxi){
if(player.hasSkill('qiangxi')&&player.get('e','1')&&list.contains('xuanfeng')) return 'xuanfeng';
if(player.hasSkill('qiangxi')&&player.getEquip(1)&&list.contains('xuanfeng')) return 'xuanfeng';
if(list.contains('wansha')||list.contains('qiangxi')){
var players=game.filterPlayer();
for(var i=0;i<players.length;i++){
@ -3532,7 +3532,7 @@ mode.boss={
order:function(){
var player=_status.event.player;
if(!player.getStat().skill.qiangxi){
if(player.hasSkill('qiangxi')&&player.get('e','1')&&!player.hasSkill('xuanfeng')) return 10;
if(player.hasSkill('qiangxi')&&player.getEquip(1)&&!player.hasSkill('xuanfeng')) return 10;
if(player.hasSkill('wansha')) return 1;
var players=game.filterPlayer();
for(var i=0;i<players.length;i++){
@ -3544,7 +3544,7 @@ mode.boss={
result:{
player:function(player){
if(!player.getStat().skill.qiangxi){
if(player.hasSkill('qiangxi')&&player.get('e','1')&&!player.hasSkill('xuanfeng')) return 1;
if(player.hasSkill('qiangxi')&&player.getEquip(1)&&!player.hasSkill('xuanfeng')) return 1;
if(!player.hasSkill('wansha')||!player.hasSkill('qiangxi')){
var players=game.filterPlayer();
for(var i=0;i<players.length;i++){

View File

@ -446,7 +446,7 @@ mode.guozhan={
}
game.countPlayer(function(current){
if(current!=player){
var ej=current.get('ej','taipingyaoshu');
var ej=current.getCards('ej','taipingyaoshu');
if(ej.length){
list.addArray(ej);
}
@ -561,7 +561,7 @@ mode.guozhan={
var list=[];
game.countPlayer(function(current){
if(current!=player){
var es=current.get('e','feilongduofeng');
var es=current.getEquip('feilongduofeng');
if(es.length){
list.addArray(es);
}

View File

@ -3375,7 +3375,7 @@ mode.stone={
content:function(){
'step 0'
if(targets[0]){
var hs=targets[0].get('h',function(card){
var hs=targets[0].getCards('h',function(card){
return get.type(card)=='stonecharacter';
});
if(hs.length&&targets[0].canAddFellow()){
@ -3384,7 +3384,7 @@ mode.stone={
}
'step 1'
if(targets[1]){
var hs=targets[1].get('h',function(card){
var hs=targets[1].getCards('h',function(card){
return get.type(card)=='stonecharacter';
});
if(hs.length&&targets[1].canAddFellow()){
@ -3398,7 +3398,7 @@ mode.stone={
useful:5,
result:{
player:function(player){
var hs=player.get('h',function(card){
var hs=player.getCards('h',function(card){
return get.type(card)=='stonecharacter';
});
if(hs.length==0) return 0;
@ -4549,7 +4549,7 @@ mode.stone={
type:'stonecard',
fullimage:true,
enable:function(event,player){
return player.get('e','1')?true:false;
return player.getEquip(1)?true:false;
},
stoneact:2,
career:'rogue',
@ -4558,7 +4558,7 @@ mode.stone={
},
selectTarget:-1,
contentBefore:function(){
player.discard(player.get('e','1'));
player.discard(player.getEquip(1));
},
content:function(){
if(typeof player.storage.spell_modaoyou=='number'){
@ -5830,7 +5830,7 @@ mode.stone={
content:function(){
game.delay();
player.removeSkill('warlock_zhaohuan2');
var hs=player.get('h',function(card){
var hs=player.getCards('h',function(card){
return get.type(card)=='stonecharacter';
});
if(hs.length&&player.canAddFellow()){
@ -6333,7 +6333,7 @@ mode.stone={
content:function(){
'step 0'
var target=player.getLeader();
if(target.get('e','1')){
if(target.getEquip(1)){
target=target.getEnemy();
player.line(target,'green');
target.damage();
@ -8412,7 +8412,7 @@ mode.stone={
},
ai:{
order:function(skill,player){
if(!player.get('e','1')&&player.countCards('e')<2){
if(!player.getEquip(1)&&player.countCards('e')<2){
if(player.num('h','sha')&&player.getActCount()+3<=player.actcount){
return 4;
}