This commit is contained in:
parent
3d987a9802
commit
b45bcc83c4
|
@ -3,17 +3,113 @@ card.mingzhong={
|
|||
card:{
|
||||
shengdong:{
|
||||
fullskin:true,
|
||||
enable:'phaseUse',
|
||||
enable:function(card,player){
|
||||
var hs=player.get('h');
|
||||
if(hs.length>1) return true;
|
||||
if(hs.length==1&&hs[0]!=card) return true;
|
||||
return false;
|
||||
},
|
||||
type:'trick',
|
||||
selectTarget:2,
|
||||
multitarget:true,
|
||||
targetprompt:['交给其一张牌','得两张牌'],
|
||||
filterTarget:function(card,player,target){
|
||||
return target!=player;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
if(!player.num('h')){
|
||||
event.finish();
|
||||
}
|
||||
else{
|
||||
event.target1=targets[0];
|
||||
event.target2=targets[1];
|
||||
player.chooseCard('h','将一张手牌交给'+get.translation(event.target1),true);
|
||||
}
|
||||
'step 1'
|
||||
player.$give(1,event.target1);
|
||||
event.target1.gain(result.cards);
|
||||
'step 2'
|
||||
if(!event.target1.num('h')){
|
||||
event.finish();
|
||||
}
|
||||
else{
|
||||
var he=event.target1.get('he');
|
||||
if(he.length<=2){
|
||||
event.directresult=he;
|
||||
}
|
||||
else{
|
||||
event.target1.chooseCard('he','将两张牌交给'+get.translation(event.target2),true);
|
||||
}
|
||||
}
|
||||
'step 3'
|
||||
if(!event.directresult){
|
||||
event.directresult=result.cards;
|
||||
}
|
||||
event.target1.$give(2,event.target2);
|
||||
event.target2.gain(result.cards);
|
||||
},
|
||||
ai:{
|
||||
order:2.5,
|
||||
value:[4,1],
|
||||
useful:1,
|
||||
result:{
|
||||
target:function(player,target){
|
||||
var ok=false;
|
||||
var hs=player.get('h');
|
||||
for(var i=0;i<hs.length;i++){
|
||||
if(ai.get.value(hs[i])<=5){
|
||||
ok=true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(!ok) return 0;
|
||||
if(ui.selected.targets.length==1) return 2;
|
||||
if(player.hasFriend()) return -1;
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
zengbin:{
|
||||
fullskin:true,
|
||||
enable:'phaseUse',
|
||||
enable:true,
|
||||
type:'trick',
|
||||
filterTarget:function(card,player,target){
|
||||
return get.distance(player,target)<=1;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
target.draw(3);
|
||||
'step 1'
|
||||
if(target.num('he',{type:'basic'})<target.num('he')){
|
||||
target.chooseToDiscard('弃置一张非基本牌(或取消并弃置两张牌)','he',function(card){
|
||||
return get.type(card)!='basic';
|
||||
}).ai=function(card){
|
||||
return 6-ai.get.value(card);
|
||||
};
|
||||
event.more=true;
|
||||
}
|
||||
else{
|
||||
target.chooseToDiscard('he',2,true);
|
||||
}
|
||||
'step 2'
|
||||
if(event.more&&!result.bool){
|
||||
target.chooseToDiscard('he',2,true);
|
||||
}
|
||||
},
|
||||
ai:{
|
||||
order:7,
|
||||
useful:4,
|
||||
value:10,
|
||||
result:{
|
||||
target:1
|
||||
}
|
||||
}
|
||||
},
|
||||
caomu:{
|
||||
fullskin:true,
|
||||
enable:'phaseUse',
|
||||
enable:true,
|
||||
type:'delay',
|
||||
}
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue