This commit is contained in:
libccy 2017-03-27 17:29:09 +08:00
parent 1c1ca4bb8c
commit 6f0a7b2c95
6 changed files with 13 additions and 12 deletions

View File

@ -154,13 +154,13 @@ card.sp={
'step 0'
target.draw(3);
'step 1'
if(target.num('he',{type:'basic'})<target.countCards('he')){
if(target.countCards('he',{type:'basic'})<target.countCards('he')){
target.chooseToDiscard('弃置一张非基本牌(或取消并弃置两张牌)','he',function(card){
return get.type(card)!='basic';
}).set('ai',function(card){
if(_status.event.goon) return 7-ai.get.value(card);
return 8-ai.get.value(card);
}).set('goon',target.num('h','basic')>2);
return 9-ai.get.value(card);
}).set('goon',target.countCards('h',{type:'basic'})>2);
event.more=true;
}
else{

View File

@ -1103,7 +1103,7 @@ character.hearth={
})>0;
},
content:function(){
player.gain(game.createCard(trigger.target.get('e',function(card){
player.gain(game.createCard(trigger.target.getCards('e',function(card){
return !get.info(card).unique;
}).randomGet()),'draw');
}

View File

@ -7753,7 +7753,7 @@ character.sp={
},
position:'he',
filterTarget:function(card,player,target){
return !target.get('e',get.subtype(card)[5]);
return !target.getEquip(parseInt(get.subtype(card)[5]));
},
ai1:function(card){
return 6-ai.get.value(card);

View File

@ -251,14 +251,14 @@ character.swd={
if(info.nomod) return false;
if(info.unique) return false;
if(!info.subtype) return false;
if(!player.get('e',info.subtype[5])) return false;
if(!player.getEquip(parseInt(info.subtype[5]))) return false;
return true;
},
content:function(){
'step 0'
var list=['equip1','equip2','equip3','equip4','equip5'];
for(var i=0;i<list.length;i++){
if(player.get('e',list[i][5])){
if(player.getEquip(parseInt(list[i][5]))){
list.splice(i--,1);
}
}

View File

@ -7615,7 +7615,7 @@
for(var i=0;i<cards.length;i++){
var str=get.subtype(cards[i])[5];
if(!str) continue;
var card=target.get('e',str);
var card=target.getEquip(parseInt(str));
if(card){
console.log(card);
ui.discardPile.appendChild(card);
@ -24840,8 +24840,9 @@
if(card.ai.basic.value==undefined)card.ai.basic.value=function(card,player){
var value=0;
var info=get.info(card);
if(player.get('e',info.subtype[5])&&card!=player.get('e',info.subtype[5])){
value=ai.get.value(player.get('e',info.subtype[5]),player);
var current=player.getEquip(parseInt(info.subtype[5]));
if(current&&card!=current){
value=ai.get.value(current,player);
}
var equipValue=info.ai.equipValue||info.ai.basic.equipValue;
if(typeof equipValue=='function') return equipValue(card,player)-value;
@ -40414,7 +40415,7 @@
}
var value1=ai.get.value(card,target);
var value2=0;
var current=target.get('e',get.subtype(card)[5]);
var current=target.getEquip(parseInt(get.subtype(card)[5]));
if(current&&current!=card){
value2=ai.get.value(current,target);
if(value2>0&&!target.needsToDiscard()){

View File

@ -889,7 +889,7 @@ mode.guozhan={
},
position:'he',
filterTarget:function(card,player,target){
return !target.get('e',get.subtype(card)[5]);
return !target.getEquip(parseInt(get.subtype(card)[5]));
},
ai1:function(card){
return 6-ai.get.value(card);