This commit is contained in:
libccy 2017-05-22 13:13:06 +08:00
parent 37480bb706
commit 27caaede35
4 changed files with 36 additions and 9 deletions

View File

@ -1096,7 +1096,9 @@ game.import('card',function(lib,game,ui,get,ai,_status){
type:'spell', type:'spell',
subtype:'spell_bronze', subtype:'spell_bronze',
enable:true, enable:true,
filterTarget:true, filterTarget:function(card,player,target){
return target.hujia||!target.hasSkill('fengyin');
},
content:function(){ content:function(){
target.addTempSkill('fengyin',{player:'phaseAfter'}); target.addTempSkill('fengyin',{player:'phaseAfter'});
if(target.hujia){ if(target.hujia){
@ -1115,6 +1117,9 @@ game.import('card',function(lib,game,ui,get,ai,_status){
else if(target.hasSkill('fengyin')){ else if(target.hasSkill('fengyin')){
return 0; return 0;
} }
if(target.hasSkillTag('maixie_hp')){
threaten*=1.5;
}
return -threaten; return -threaten;
} }
}, },

View File

@ -6229,7 +6229,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
} }
}, },
ai:{ ai:{
effect:function(card,player){ effect:function(card,player,target){
if(get.tag(card,'damage')){ if(get.tag(card,'damage')){
if(player.hasSkillTag('jueqing',false,target)) return [1,1]; if(player.hasSkillTag('jueqing',false,target)) return [1,1];
return 1.2; return 1.2;
@ -6381,7 +6381,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
result:{ result:{
player:1 player:1
}, },
effect:function(card,player){ effect:function(card,player,target){
if(get.tag(card,'damage')){ if(get.tag(card,'damage')){
if(player.hasSkillTag('jueqing',false,target)) return; if(player.hasSkillTag('jueqing',false,target)) return;
return 1.2; return 1.2;

View File

@ -1176,7 +1176,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
return player.countCards('h')<=player.hp?1:0; return player.countCards('h')<=player.hp?1:0;
} }
}, },
effect:function(card,player){ effect:function(card,player,target){
if(get.tag(card,'damage')){ if(get.tag(card,'damage')){
if(player.hasSkillTag('jueqing',false,target)) return [1,1]; if(player.hasSkillTag('jueqing',false,target)) return [1,1];
return 1.2; return 1.2;

View File

@ -737,7 +737,10 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
list[lib.character[i][1]].push(i); list[lib.character[i][1]].push(i);
} }
} }
var dialog=ui.create.dialog('选择角色',[list[game.me.identity].randomGets(8),'character']); event.friendChoice=list[game.me.identity].randomRemove();
var dialog=ui.create.dialog('选择角色',[list[game.me.identity].randomGets(7).concat([event.friendChoice]),'character']);
dialog.buttons[7].node.name.innerHTML=get.verticalStr('队友选择');
var addSetting=function(dialog){ var addSetting=function(dialog){
dialog.add('选择座位'); dialog.add('选择座位');
var seats=document.createElement('table'); var seats=document.createElement('table');
@ -813,7 +816,10 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
} }
var buttons=ui.create.div('.buttons'); var buttons=ui.create.div('.buttons');
var node=_status.event.dialog.buttons[0].parentNode; var node=_status.event.dialog.buttons[0].parentNode;
_status.event.dialog.buttons=ui.create.buttons(list[game.me.identity].randomGets(8),'character',buttons); list[game.me.identity].add(event.friendChoice);
event.friendChoice=list[game.me.identity].randomRemove();
_status.event.dialog.buttons=ui.create.buttons(list[game.me.identity].randomGets(7).concat([event.friendChoice]),'character',buttons);
_status.event.dialog.buttons[7].node.name.innerHTML=get.verticalStr('队友选择');
_status.event.dialog.content.insertBefore(buttons,node); _status.event.dialog.content.insertBefore(buttons,node);
buttons.animate('start'); buttons.animate('start');
node.remove(); node.remove();
@ -824,6 +830,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
} }
var createCharacterDialog=function(){ var createCharacterDialog=function(){
event.dialogxx=ui.create.characterDialog(function(name){ event.dialogxx=ui.create.characterDialog(function(name){
if(name==event.friendChoice) return true;
if(lib.character[name][1]!=game.me.identity) return true; if(lib.character[name][1]!=game.me.identity) return true;
}); });
if(ui.cheat2){ if(ui.cheat2){
@ -874,7 +881,10 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
ui.cheat2.classList.add('disabled'); ui.cheat2.classList.add('disabled');
} }
} }
game.me.chooseButton(dialog,true).set('onfree',true); game.me.chooseButton(dialog,true).set('onfree',true).set('filterButton',function(button){
if(button==button.parentNode.lastChild) return false;
return true;
});
if(!ui.cheat&&get.config('change_choice')){ if(!ui.cheat&&get.config('change_choice')){
ui.create.cheat(); ui.create.cheat();
} }
@ -896,7 +906,12 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
for(var i=0;i<game.players.length;i++){ for(var i=0;i<game.players.length;i++){
game.players[i].node.identity.style.display=''; game.players[i].node.identity.style.display='';
if(game.players[i]!=game.me){ if(game.players[i]!=game.me){
game.players[i].init(event.list[game.players[i].side].randomRemove()); if(game.players[i].identity==game.me.identity){
game.players[i].init(event.friendChoice);
}
else{
game.players[i].init(event.list[game.players[i].side].randomRemove());
}
} }
game.players[i].addSkill('longchuanzhibao'); game.players[i].addSkill('longchuanzhibao');
if(added[game.players[i].side]==0){ if(added[game.players[i].side]==0){
@ -3530,6 +3545,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
}, },
content:function(){ content:function(){
player.gainZhibao(1,trigger.player); player.gainZhibao(1,trigger.player);
game.delay();
}, },
group:'longchuanzhibao_over', group:'longchuanzhibao_over',
subSkill:{ subSkill:{
@ -5174,12 +5190,14 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
map[current.side]+=get.condition(current)*get.threaten(current,false,false); map[current.side]+=get.condition(current)*get.threaten(current,false,false);
map2[current.side]+=current.storage.longchuanzhibao; map2[current.side]+=current.storage.longchuanzhibao;
} }
var allin=false;
for(var i in map){ for(var i in map){
if(get.population(i)==1){ if(get.population(i)==1){
map[i]/=1.5; map[i]/=1.5;
} }
if(map2[i]>=4){ if(map2[i]>=4){
map[i]+=50; allin=i;
break;
} }
else if(map2[i]==3){ else if(map2[i]==3){
map[i]+=10; map[i]+=10;
@ -5188,6 +5206,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
map[i]++; map[i]++;
} }
} }
if(allin) return to.side==allin?-20:0;
list.sort(function(a,b){ list.sort(function(a,b){
return map[b]-map[a]; return map[b]-map[a];
}); });
@ -5229,6 +5248,9 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
else if(map2[to.side]==2){ else if(map2[to.side]==2){
att-=0.5; att-=0.5;
} }
if(to.storage.longchuanzhibao){
return att*1.2;
}
return att; return att;
} }
else{ else{