细节优化
This commit is contained in:
parent
a00ad6f772
commit
ea34e08d4f
|
@ -2031,7 +2031,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
if(trigger.targets&&trigger.targets.length){
|
if(trigger.targets&&trigger.targets.length){
|
||||||
let result=yield player.chooseControl(['额外结算','摸一张牌']).set('prompt','实荐:请选择一项').set('prompt2',`令${get.translation(trigger.card)}额外结算一次,或摸一张牌`).set('ai',()=>{
|
let result=yield player.chooseControl(['额外结算','摸一张牌']).set('prompt','实荐:请选择一项').set('prompt2',`令${get.translation(trigger.card)}额外结算一次,或摸一张牌`).set('ai',()=>{
|
||||||
return get.event('choice');
|
return get.event('choice');
|
||||||
}).set('choice',['basic','trick'].includes(get.type(trigger.card))&&trigger.targets.map(i=>get.effect(i,trigger.card,target,player)).reduce((p,c)=>p+c,0)>=5?0:1);
|
}).set('choice',function(){
|
||||||
|
if(trigger.card.name==='tiesuo'||!['basic','trick'].includes(get.type(trigger.card))) return 1;
|
||||||
|
if(trigger.targets.reduce((p,c)=>{
|
||||||
|
return p+get.effect(c,trigger.card,target,_status.event.player);
|
||||||
|
},0)>=get.effect(player,{name:'draw'},player,_status.event.player)) return 0;
|
||||||
|
return 1;
|
||||||
|
}());
|
||||||
if(result.index==0){
|
if(result.index==0){
|
||||||
trigger.getParent().effectCount++;
|
trigger.getParent().effectCount++;
|
||||||
game.log(player,'令',trigger.card,'额外结算一次');
|
game.log(player,'令',trigger.card,'额外结算一次');
|
||||||
|
|
|
@ -14594,7 +14594,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
if(event.current.needsToDiscard()){
|
if(event.current.needsToDiscard()){
|
||||||
att=1;
|
att=1;
|
||||||
}
|
}
|
||||||
player.chooseControlList(['令'+name+'摸一张牌展示','令'+name+'手牌上永久+1','弃置一张牌并令'+name+'获得一张本回进入弃牌堆的牌'],function(){
|
player.chooseControlList(['令'+name+'摸一张牌展示','令'+name+'手牌上永久+1','弃置一张牌并令'+name+'获得一张本回合进入弃牌堆的牌'],function(){
|
||||||
return _status.event.att;
|
return _status.event.att;
|
||||||
}).set('att',att);
|
}).set('att',att);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1830,7 +1830,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
let result;
|
let result;
|
||||||
if(_status.connectMode) game.broadcastAll(()=>{_status.noclearcountdown=true});
|
if(_status.connectMode) game.broadcastAll(()=>{_status.noclearcountdown=true});
|
||||||
if(choices.length==1) result={control:choices[0]};
|
if(choices.length==1) result={control:choices[0]};
|
||||||
else result=yield player.chooseControl(choices,'cancel2').set('choiceList',choiceList).set('prompt',get.prompt('dcxunjie')).set('ai',()=>{
|
else result=yield player.chooseControl(choices,'cancel2').set('choiceList',choiceList).set('prompt',get.prompt('dcxunjie')).set('ai',()=>{
|
||||||
return get.event('choice');
|
return get.event('choice');
|
||||||
}).set('choice',(()=>{
|
}).set('choice',(()=>{
|
||||||
const getValue=(index,target)=>{
|
const getValue=(index,target)=>{
|
||||||
|
|
|
@ -5733,7 +5733,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
var num=0;
|
var num=0;
|
||||||
for(var i of cards) num+=get.number(i,player);
|
for(var i of cards) num+=get.number(i,player);
|
||||||
num=num%13;
|
num=num%13;
|
||||||
if(num==0) num=13;
|
if(num==0) num=13;
|
||||||
var card=get.cardPile2(function(card){
|
var card=get.cardPile2(function(card){
|
||||||
return get.number(card,false)==num;
|
return get.number(card,false)==num;
|
||||||
});
|
});
|
||||||
|
@ -14293,34 +14293,34 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
},
|
},
|
||||||
filter:function(event,player){
|
filter:function(event,player){
|
||||||
if(!player.storage.yizan&&player.countCards('hes')<2) return false;
|
if(!player.storage.yizan&&player.countCards('hes')<2) return false;
|
||||||
if(!player.hasCard(function(card){
|
if(!player.hasCard(function(card){
|
||||||
return get.type(card)=='basic';
|
return get.type(card)=='basic';
|
||||||
},'hs')) return false;
|
},'hs')) return false;
|
||||||
for(var name of lib.inpile){
|
for(var name of lib.inpile){
|
||||||
if(get.type(name)!='basic') continue;
|
if(get.type(name)!='basic') continue;
|
||||||
if(event.filterCard(get.autoViewAs({name},'unsure'),player,event)) return true;
|
if(event.filterCard(get.autoViewAs({name},'unsure'),player,event)) return true;
|
||||||
if(name=='sha'){
|
if(name=='sha'){
|
||||||
for(var nature of lib.inpile_nature){
|
for(var nature of lib.inpile_nature){
|
||||||
if(event.filterCard(get.autoViewAs({name,nature},'unsure'),player,event)) return true;
|
if(event.filterCard(get.autoViewAs({name,nature},'unsure'),player,event)) return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
},
|
},
|
||||||
chooseButton:{
|
chooseButton:{
|
||||||
dialog:function(event,player){
|
dialog:function(event,player){
|
||||||
var list=[];
|
var list=[];
|
||||||
for(var name of lib.inpile){
|
for(var name of lib.inpile){
|
||||||
if(get.type(name)!='basic') continue;
|
if(get.type(name)!='basic') continue;
|
||||||
if(event.filterCard(get.autoViewAs({name},'unsure'),player,event)){
|
if(event.filterCard(get.autoViewAs({name},'unsure'),player,event)){
|
||||||
list.push(['基本','',name]);
|
list.push(['基本','',name]);
|
||||||
}
|
}
|
||||||
if(name=='sha'){
|
if(name=='sha'){
|
||||||
for(var nature of lib.inpile_nature){
|
for(var nature of lib.inpile_nature){
|
||||||
if(event.filterCard(get.autoViewAs({name,nature},'unsure'),player,event)) list.push(['基本','','sha',nature]);
|
if(event.filterCard(get.autoViewAs({name,nature},'unsure'),player,event)) list.push(['基本','','sha',nature]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return ui.create.dialog('翊赞',[list,'vcard'],'hidden');
|
return ui.create.dialog('翊赞',[list,'vcard'],'hidden');
|
||||||
},
|
},
|
||||||
check:function(button){
|
check:function(button){
|
||||||
|
@ -15664,7 +15664,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
sunru:['dc_sunru','sunru'],
|
sunru:['dc_sunru','sunru'],
|
||||||
liuye:['dc_liuye','liuye'],
|
liuye:['dc_liuye','liuye'],
|
||||||
zhaotongzhaoguang:['dc_zhaotongzhaoguang','zhaotongzhaoguang'],
|
zhaotongzhaoguang:['dc_zhaotongzhaoguang','zhaotongzhaoguang'],
|
||||||
yangbiao:['yangbiao','dc_yangbiao','jsrg_yangbiao'],
|
yangbiao:['yangbiao','dc_yangbiao','jsrg_yangbiao'],
|
||||||
qiaozhou:['yj_qiaozhou','qiaozhou'],
|
qiaozhou:['yj_qiaozhou','qiaozhou'],
|
||||||
sunhanhua:['dc_sunhanhua','sunhanhua'],
|
sunhanhua:['dc_sunhanhua','sunhanhua'],
|
||||||
zhoubuyi:['zhoubuyi','yj_zhoubuyi'],
|
zhoubuyi:['zhoubuyi','yj_zhoubuyi'],
|
||||||
|
|
|
@ -1141,7 +1141,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
});
|
});
|
||||||
if(!target){
|
if(!target){
|
||||||
event.finish();
|
event.finish();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
event.target=target;
|
event.target=target;
|
||||||
player.logSkill('sbqicai_gain',target);
|
player.logSkill('sbqicai_gain',target);
|
||||||
|
|
|
@ -7640,7 +7640,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
'step 3'
|
'step 3'
|
||||||
game.delayx();
|
game.delayx();
|
||||||
game.broadcastAll(function(onEnd){
|
game.broadcastAll(function(onEnd){
|
||||||
_status.event.onEnd01=onEnd;
|
_status.event.onEnd01=onEnd;
|
||||||
if(_status.guhuoNode) _status.guhuoNode.listenTransition(onEnd,300);
|
if(_status.guhuoNode) _status.guhuoNode.listenTransition(onEnd,300);
|
||||||
},event.onEnd01);
|
},event.onEnd01);
|
||||||
'step 4'
|
'step 4'
|
||||||
|
|
|
@ -15889,7 +15889,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
twkujian_info:'出牌阶段限一次。你可以将至多三张手牌交给一名其他角色,称为“谏”,你获得以下效果:当其他角色使用或打出牌后,若其中有“谏”,你与其各摸一张牌;当其他角色不因使用或打出而失去牌后,若其中有“谏”,你与其各弃置一张牌。',
|
twkujian_info:'出牌阶段限一次。你可以将至多三张手牌交给一名其他角色,称为“谏”,你获得以下效果:当其他角色使用或打出牌后,若其中有“谏”,你与其各摸一张牌;当其他角色不因使用或打出而失去牌后,若其中有“谏”,你与其各弃置一张牌。',
|
||||||
twruilian:'睿敛',
|
twruilian:'睿敛',
|
||||||
twruilian2:'睿敛',
|
twruilian2:'睿敛',
|
||||||
twruilian_info:'一轮游戏开始时,你可以选择一名角色。其下回合结束时,若其本回弃置过至少两张其的牌,你可以选择其本回合弃置过的一种类别,你与其各从弃牌堆中获得一张此类别的牌。',
|
twruilian_info:'一轮游戏开始时,你可以选择一名角色。其下回合结束时,若其本回合弃置过至少两张牌,你可以选择其本回合弃置过的一种类别,你与其各从弃牌堆中获得一张此类别的牌。',
|
||||||
tw_xiahouen:'夏侯恩',
|
tw_xiahouen:'夏侯恩',
|
||||||
twfujian:'负剑',
|
twfujian:'负剑',
|
||||||
twfujian_info:'锁定技。①游戏开始时或准备阶段,若你的装备区里没有武器牌,你随机将牌堆中的一张武器牌置入装备区。②当你于回合外失去武器牌后,你失去1点体力。',
|
twfujian_info:'锁定技。①游戏开始时或准备阶段,若你的装备区里没有武器牌,你随机将牌堆中的一张武器牌置入装备区。②当你于回合外失去武器牌后,你失去1点体力。',
|
||||||
|
|
|
@ -154,10 +154,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
ai:{
|
ai:{
|
||||||
order:9,
|
order:9,
|
||||||
result:{
|
result:{
|
||||||
player:1,
|
player:function(player,target){
|
||||||
|
if(player.storage.dcsbquanmou) return 1;
|
||||||
|
return 1+game.countPlayer(i=>player!==i&&target!==i&&!i.hasSkill('false_mark')&&get.attitude(player,i)<0);
|
||||||
|
},
|
||||||
target:function(player,target){
|
target:function(player,target){
|
||||||
if(!player.storage.dcsbquanmou) return 1.2;
|
let res=target.hasSkillTag('noh')?0:-1;
|
||||||
return -0.2;
|
if(player.storage.dcsbquanmou) return res+0.6;
|
||||||
|
return res;
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -218,6 +222,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
},
|
},
|
||||||
ai:{
|
ai:{
|
||||||
threaten:2.5,
|
threaten:2.5,
|
||||||
|
effect:{
|
||||||
|
target(card,player,target){
|
||||||
|
if(get.tag(card,'damage')&&player&&player.hasSkill('dcsbquanmou_true')){
|
||||||
|
let tars=game.countPlayer(i=>player!==i&&target!==i&&get.damageEffect(i,player,player)>0);
|
||||||
|
return [1,0,1,6*Math.min(3,tars)/(3+Math.pow(target.countCards('h'),2))];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
false:{
|
false:{
|
||||||
|
@ -253,10 +265,17 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
ai:{
|
ai:{
|
||||||
filterDamage:true,
|
nodamage:true,
|
||||||
|
nofire:true,
|
||||||
|
nothunder:true,
|
||||||
skillTagFilter(player,tag,arg){
|
skillTagFilter(player,tag,arg){
|
||||||
return (arg&&arg.player&&arg.player.hasSkill('dcsbquanmou_false'));
|
return (arg&&arg.player&&arg.player.hasSkill('dcsbquanmou_false'));
|
||||||
},
|
},
|
||||||
|
effect:{
|
||||||
|
target(card,player,target){
|
||||||
|
if(get.tag(card,'damage')&&player&&player.hasSkill('dcsbquanmou_false')) return 'zeroplayertarget';
|
||||||
|
}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
|
@ -4342,8 +4342,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
longxi2:'龙息',
|
longxi2:'龙息',
|
||||||
longxi_info:'锁定技,在回合外每当你需要使用或打出一张卡牌时,若牌堆顶的前两张中有可使用或打出的牌,你立即获得之。',
|
longxi_info:'锁定技,在回合外每当你需要使用或打出一张卡牌时,若牌堆顶的前两张中有可使用或打出的牌,你立即获得之。',
|
||||||
zhuyue:'逐月',
|
zhuyue:'逐月',
|
||||||
zhuyue_info:'出牌阶段限一次,你可以弃置一张非基本牌并指定至多两个目标各随机弃置一张牌,若如此做,你本回使用的杀须指定选中角色为目标。',
|
zhuyue_info:'出牌阶段限一次,你可以弃置一张非基本牌并指定至多两个目标各随机弃置一张牌,若如此做,你本回合使用的杀须指定选中角色为目标。',
|
||||||
zhuyue_info_alter:'出牌阶段限一次,你可以弃置一张黑色非基本牌并指定至多两个目标各随机弃置一张牌,若如此做,你本回使用的杀须指定选中角色为目标。',
|
zhuyue_info_alter:'出牌阶段限一次,你可以弃置一张黑色非基本牌并指定至多两个目标各随机弃置一张牌,若如此做,你本回合使用的杀须指定选中角色为目标。',
|
||||||
guanri:'贯日',
|
guanri:'贯日',
|
||||||
guanri_info:'限制技,你可以弃置两张红色手牌并失去1点体力,然后对一名体力值不少于你的其他角色造成2点火焰伤害并弃置其所有装备牌。',
|
guanri_info:'限制技,你可以弃置两张红色手牌并失去1点体力,然后对一名体力值不少于你的其他角色造成2点火焰伤害并弃置其所有装备牌。',
|
||||||
tianxian:'天弦',
|
tianxian:'天弦',
|
||||||
|
|
|
@ -13963,7 +13963,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
chengong:['chengong','re_chengong','sb_chengong'],
|
chengong:['chengong','re_chengong','sb_chengong'],
|
||||||
xunyou:['xunyou','re_xunyou'],
|
xunyou:['xunyou','re_xunyou'],
|
||||||
xuezong:['xuezong','tw_xuezong'],
|
xuezong:['xuezong','tw_xuezong'],
|
||||||
huanghao:['huanghao','dc_huanghao','old_huanghao'],
|
huanghao:['huanghao','dc_huanghao','old_huanghao'],
|
||||||
caorui:['caorui','re_caorui','old_caorui'],
|
caorui:['caorui','re_caorui','old_caorui'],
|
||||||
sunziliufang:['sunziliufang','dc_sunziliufang'],
|
sunziliufang:['sunziliufang','dc_sunziliufang'],
|
||||||
liyan:['liyan','old_liyan'],
|
liyan:['liyan','old_liyan'],
|
||||||
|
|
|
@ -10587,10 +10587,10 @@ return event.junling=='junling5'?1:0;});
|
||||||
if(huoshao&&player.inline(target.getNext())) return -3;
|
if(huoshao&&player.inline(target.getNext())) return -3;
|
||||||
if(target.isUnseen()) return 0;
|
if(target.isUnseen()) return 0;
|
||||||
if(player.isMajor()) return 0;
|
if(player.isMajor()) return 0;
|
||||||
if(!player.isMajor()&&huoshao&&player.getNext().isMajor()) return -2;
|
if(!player.isMajor()&&huoshao&&player.getNext().isMajor()) return -2;
|
||||||
if(!player.isMajor()&&huoshao&&player.getNext().isMajor()&&player.getNext().getNext().isMajor()) return -3;
|
if(!player.isMajor()&&huoshao&&player.getNext().isMajor()&&player.getNext().getNext().isMajor()) return -3;
|
||||||
if(!player.isMajor()&&huoshao&&!target.isMajor()&&target.getNext().isMajor()&&target.getNext().getNext().isMajor()) return 3;
|
if(!player.isMajor()&&huoshao&&!target.isMajor()&&target.getNext().isMajor()&&target.getNext().getNext().isMajor()) return 3;
|
||||||
if(!player.isMajor()&&huoshao&&!target.isMajor()&&target.getNext().isMajor()) return 1.5;
|
if(!player.isMajor()&&huoshao&&!target.isMajor()&&target.getNext().isMajor()) return 1.5;
|
||||||
return 1;
|
return 1;
|
||||||
},
|
},
|
||||||
target:function(player,target){
|
target:function(player,target){
|
||||||
|
|
|
@ -580,7 +580,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
||||||
case 'fan':list[i]='反贼';break;
|
case 'fan':list[i]='反贼';break;
|
||||||
case 'zhong':list[i]='忠臣';break;
|
case 'zhong':list[i]='忠臣';break;
|
||||||
case 'nei':list[i]='内奸';break;
|
case 'nei':list[i]='内奸';break;
|
||||||
case 'commoner':list[i]='平民'; break;
|
case 'commoner':list[i]='平民'; break;
|
||||||
case 'zhu':list[i]='主公';break;
|
case 'zhu':list[i]='主公';break;
|
||||||
case 'enemy':list[i]='敌方';break;
|
case 'enemy':list[i]='敌方';break;
|
||||||
case 'friend':list[i]='友方';break;
|
case 'friend':list[i]='友方';break;
|
||||||
|
@ -737,7 +737,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
||||||
switch(me.identity){
|
switch(me.identity){
|
||||||
case 'fan':game.over(false);break;
|
case 'fan':game.over(false);break;
|
||||||
case 'zhong':game.over(true);break;
|
case 'zhong':game.over(true);break;
|
||||||
case 'commoner':game.over(true); break;
|
case 'commoner':game.over(true); break;
|
||||||
default:game.over();break;
|
default:game.over();break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -745,7 +745,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
||||||
switch(me.identity){
|
switch(me.identity){
|
||||||
case 'fan':game.over(true);break;
|
case 'fan':game.over(true);break;
|
||||||
case 'zhong':game.over(false);break;
|
case 'zhong':game.over(false);break;
|
||||||
case 'commoner':game.over(true); break;
|
case 'commoner':game.over(true); break;
|
||||||
default:game.over();break;
|
default:game.over();break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -765,7 +765,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if(me.identity=='nei'){
|
else if(me.identity=='nei'){
|
||||||
if(game.players.length==(1+game.players.filter(i=>i.identity=='commoner').length)&&me.isAlive()){
|
if(game.players.length==(1+game.players.filter(i=>i.identity=='commoner').length)&&me.isAlive()){
|
||||||
game.over(true);
|
game.over(true);
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
|
@ -781,8 +781,8 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
||||||
game.over(false);
|
game.over(false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if(me.identity=='commoner'){
|
else if(me.identity=='commoner'){
|
||||||
game.over(true);
|
game.over(true);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
checkOnlineResult:function(player){
|
checkOnlineResult:function(player){
|
||||||
|
@ -794,7 +794,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
||||||
if(game.zhu.isAlive()){
|
if(game.zhu.isAlive()){
|
||||||
return (player.identity=='zhu'||player.identity=='zhong'||player.identity=='mingzhong'||player.identity=='commoner'&&player.isAlive());
|
return (player.identity=='zhu'||player.identity=='zhong'||player.identity=='mingzhong'||player.identity=='commoner'&&player.isAlive());
|
||||||
}
|
}
|
||||||
else if(game.players.length==(1+game.players.filter(i=>i.identity=='commoner').length)&&game.players[0].identity=='nei'||game.players[0].identity=='commoner'){
|
else if(game.players.length==(1+game.players.filter(i=>i.identity=='commoner').length)&&game.players[0].identity=='nei'||game.players[0].identity=='commoner'){
|
||||||
return player.isAlive();
|
return player.isAlive();
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
|
@ -1568,9 +1568,9 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
||||||
link=['zhu','zhong','nei','fan','mingzhong'].randomGet();
|
link=['zhu','zhong','nei','fan','mingzhong'].randomGet();
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
var listi=['zhu','zhong','nei','fan'];
|
var listi=['zhu','zhong','nei','fan'];
|
||||||
if(get.config('enable_commoner')&&!event.stratagemMode) listi.push('commoner');
|
if(get.config('enable_commoner')&&!event.stratagemMode) listi.push('commoner');
|
||||||
link=listi.randomGet();
|
link=listi.randomGet();
|
||||||
}
|
}
|
||||||
for(var i=0;i<this.parentNode.childElementCount;i++){
|
for(var i=0;i<this.parentNode.childElementCount;i++){
|
||||||
if(this.parentNode.childNodes[i].link==link){
|
if(this.parentNode.childNodes[i].link==link){
|
||||||
|
@ -2712,7 +2712,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(this.identity=='fan'&&source) source.draw(3);
|
if(this.identity=='fan'&&source) source.draw(3);
|
||||||
else if(this.identity=='commoner'&&source) source.draw(2);
|
else if(this.identity=='commoner'&&source) source.draw(2);
|
||||||
else if(this.identity=='mingzhong'&&source){
|
else if(this.identity=='mingzhong'&&source){
|
||||||
if(source.identity=='zhu'){
|
if(source.identity=='zhu'){
|
||||||
source.discard(source.getCards('he'));
|
source.discard(source.getCards('he'));
|
||||||
|
@ -3506,11 +3506,11 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
||||||
game.players[i].ai.shown<1){
|
game.players[i].ai.shown<1){
|
||||||
identity2='nei';break;
|
identity2='nei';break;
|
||||||
}
|
}
|
||||||
else if(game.players[i].identity=='commoner'&&
|
else if(game.players[i].identity=='commoner'&&
|
||||||
game.players[i].ai.identity_mark=='zhong'&&
|
game.players[i].ai.identity_mark=='zhong'&&
|
||||||
game.players[i].ai.shown<1){
|
game.players[i].ai.shown<1){
|
||||||
identity2='commoner'; break;
|
identity2='commoner'; break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
var zhongmode=false;
|
var zhongmode=false;
|
||||||
|
@ -3596,13 +3596,13 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
||||||
if(zhongmode&&to.ai.sizhong&&to.ai.shown<1) return 6;
|
if(zhongmode&&to.ai.sizhong&&to.ai.shown<1) return 6;
|
||||||
return Math.min(3,-situation);
|
return Math.min(3,-situation);
|
||||||
case 'fan': return -8;
|
case 'fan': return -8;
|
||||||
case 'commoner':
|
case 'commoner':
|
||||||
return Math.min(3,Math.max(-3,situation-0.2));
|
return Math.min(3,Math.max(-3,situation-0.2));
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 'nei':
|
case 'nei':
|
||||||
if(identity2=='zhu'&&game.players.length==2) return -10;
|
if(identity2=='zhu'&&game.players.length==2) return -10;
|
||||||
if(from!=to&&identity2!='zhu'&&identity2!='commoner'&&game.players.length==3) return -8;
|
if(from!=to&&identity2!='zhu'&&identity2!='commoner'&&game.players.length==3) return -8;
|
||||||
var strategy=get.aiStrategy();
|
var strategy=get.aiStrategy();
|
||||||
if(strategy==4){
|
if(strategy==4){
|
||||||
if(from==to) return 10;
|
if(from==to) return 10;
|
||||||
|
@ -3706,8 +3706,8 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
||||||
if(game.zhu&&game.zhu.hp<=2) return -1;
|
if(game.zhu&&game.zhu.hp<=2) return -1;
|
||||||
return Math.min(3,situation);
|
return Math.min(3,situation);
|
||||||
case 'fan': return 5;
|
case 'fan': return 5;
|
||||||
case 'commoner':
|
case 'commoner':
|
||||||
return 2*get.population('fan')-3;
|
return 2*get.population('fan')-3;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 'commoner':
|
case 'commoner':
|
||||||
|
|
Loading…
Reference in New Issue