This commit is contained in:
libccy 2017-05-21 10:07:10 +08:00
parent 6ae0db927b
commit c5b0c0d583
3 changed files with 91 additions and 111 deletions

View File

@ -767,66 +767,11 @@ game.import('card',function(lib,game,ui,get,ai,_status){
filterTarget:true, filterTarget:true,
wuxieable:true, wuxieable:true,
content:function(){ content:function(){
var list=[1,2,3,4,5,6];
if(player.getEnemies().contains(target)){ if(player.getEnemies().contains(target)){
if(target.countCards('he')==0){ target.getDebuff();
list.remove(1);
}
if(target.isLinked()){
list.remove(4);
}
if(target.hasSkill('fengyin')){
list.remove(5);
}
switch(list.randomGet()){
case 1:target.discard(target.getCards('he').randomGet());break;
case 2:target.loseHp();break;
case 3:target.damage();break;
case 4:if(!target.isLinked()) target.link();break;
case 5:target.addTempSkill('fengyin',{player:'phaseAfter'});break;
case 6:{
var list=[];
for(var i=0;i<lib.inpile.length;i++){
var info=lib.card[lib.inpile[i]];
if(info.type=='delay'&&!info.cancel&&!target.hasJudge(lib.inpile[i])){
list.push(lib.inpile[i]);
}
}
if(list.length){
var card=game.createCard(list.randomGet());
target.addJudge(card);
target.$draw(card);
game.delay();
}
break;
}
}
} }
else{ else{
if(target.isHealthy()){ target.getBuff();
list.remove(2);
}
if(!target.countCards('j')){
list.remove(5);
}
if(!target.isLinked()&&!target.isTurnedOver()){
list.remove(6);
}
if(target.hasSkill('qianxing')){
list.remove(4);
}
switch(list.randomGet()){
case 1:target.draw();break;
case 2:target.recover();break;
case 3:target.changeHujia();break;
case 4:target.addTempSkill('qianxing',{player:'phaseBegin'});break;
case 5:target.discard(target.getCards('j'));break;
case 6:{
if(target.isLinked()) target.link();
if(target.isTurnedOver()) target.turnOver();
break;
}
}
} }
}, },
ai:{ ai:{

View File

@ -760,40 +760,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}, },
frequent:true, frequent:true,
content:function(){ content:function(){
var list=[1,2,3,4,5,6]; target.getDebuff();
var target=trigger.target;
if(target.countCards('he')==0){
list.remove(1);
}
if(target.isLinked()){
list.remove(4);
}
if(target.hasSkill('fengyin')){
list.remove(5);
}
switch(list.randomGet()){
case 1:target.discard(target.getCards('he').randomGet());break;
case 2:target.loseHp();break;
case 3:target.damage();break;
case 4:if(!target.isLinked()) target.link();break;
case 5:target.addTempSkill('fengyin',{player:'phaseAfter'});break;
case 6:{
var list=[];
for(var i=0;i<lib.inpile.length;i++){
var info=lib.card[lib.inpile[i]];
if(info.type=='delay'&&!info.cancel&&!target.hasJudge(lib.inpile[i])){
list.push(lib.inpile[i]);
}
}
if(list.length){
var card=game.createCard(list.randomGet());
target.addJudge(card);
target.$draw(card);
game.delay();
}
break;
}
}
} }
}, },
shiying:{ shiying:{
@ -2259,30 +2226,15 @@ game.import('character',function(lib,game,ui,get,ai,_status){
'step 1' 'step 1'
if(result.bool){ if(result.bool){
player.logSkill('danqing',result.targets); player.logSkill('danqing',result.targets);
var effs=['draw','hujia','equip','stealth'];
for(var i=0;i<result.targets.length;i++){ for(var i=0;i<result.targets.length;i++){
var eff=effs.randomRemove(); result.targets[i].getBuff(false);
var current=result.targets[i];
switch(eff){
case 'draw':current.draw();break;
case 'hujia':current.changeHujia();break;
case 'equip':
var card=game.createCard(get.inpile('equip').randomGet());
current.equip(card);
current.$draw(card);
break;
case 'stealth':
current.addTempSkill('qianxing',{player:'phaseBegin'});
break;
}
}
if(effs.contains('draw')){
game.delay();
} }
} }
else{ else{
event.finish(); event.finish();
} }
'step 2'
game.delay();
}, },
group:'danqing_count' group:'danqing_count'
}, },
@ -4357,8 +4309,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
xuanmo:'玄墨', xuanmo:'玄墨',
xuanmo_info:'出牌阶段限一次,你可以将一张手牌置于牌堆顶并随机获得两张与之类别相同的牌', xuanmo_info:'出牌阶段限一次,你可以将一张手牌置于牌堆顶并随机获得两张与之类别相同的牌',
danqing:'丹青', danqing:'丹青',
danqing_info:'结束阶段若你累计使用了4张花色不同的牌你可以选择至多4名角色分别获得以下4种效果中的随机一个1、摸一张牌2、获得一点护甲3、装备一件随机装备4、获得潜行直到下一回合开始', danqing_info:'结束阶段若你累计使用了4张花色不同的牌你可以选择至多4名角色随机获得一个正面效果',
danqing_info_alter:'结束阶段若你累计使用了4张花色不同的牌你可以选择至多2名角色分别获得以下4种效果中的随机一个1、摸一张牌2、获得一点护甲3、装备一件随机装备4、获得潜行直到下一回合开始', danqing_info_alter:'结束阶段若你累计使用了4张花色不同的牌你可以选择至多2名角色随机获得一个正面效果',
zhangmu:'障目', zhangmu:'障目',
zhangmu_info:'每回合限一次,当你需要使用或打出一张闪时,你可以展示一张闪,视为使用或打出了此闪', zhangmu_info:'每回合限一次,当你需要使用或打出一张闪时,你可以展示一张闪,视为使用或打出了此闪',
feizhua:'飞爪', feizhua:'飞爪',

View File

@ -14997,6 +14997,89 @@
next.setContent('changeHujia'); next.setContent('changeHujia');
return next; return next;
}, },
getBuff:function(){
var list=[1,2,3,4,5,6];
var nodelay=false;
for(var i=0;i<arguments.length;i++){
if(typeof arguments[i]=='number'){
list.remove(arguments[i]);
}
else if(arguments[i]===false){
nodelay=true;
}
}
if(this.isHealthy()){
list.remove(2);
}
if(!this.countCards('j')){
list.remove(5);
}
if(!this.isLinked()&&!this.isTurnedOver()){
list.remove(6);
}
if(this.hasSkill('qianxing')){
list.remove(4);
}
switch(list.randomGet()){
case 1:this.draw(nodelay?'nodelay':1);break;
case 2:this.recover();break;
case 3:this.changeHujia();break;
case 4:this.addTempSkill('qianxing',{player:'phaseBegin'});break;
case 5:this.discard(this.getCards('j')).delay=(!nodelay);break;
case 6:{
if(this.isLinked()) this.link();
if(this.isTurnedOver()) this.turnOver();
break;
}
}
},
getDebuff:function(){
var list=[1,2,3,4,5,6];
var nodelay=false;
for(var i=0;i<arguments.length;i++){
if(typeof arguments[i]=='number'){
list.remove(arguments[i]);
}
else if(arguments[i]===false){
nodelay=true;
}
}
if(this.countCards('he')==0){
list.remove(1);
}
if(this.isLinked()){
list.remove(4);
}
if(this.hasSkill('fengyin')){
list.remove(5);
}
switch(list.randomGet()){
case 1:this.randomDiscard(nodelay?false:'he');break;
case 2:this.loseHp();break;
case 3:this.damage();break;
case 4:if(!this.isLinked()) this.link();break;
case 5:this.addTempSkill('fengyin',{player:'phaseAfter'});break;
case 6:{
var list=[];
for(var i=0;i<lib.inpile.length;i++){
var info=lib.card[lib.inpile[i]];
if(info.type=='delay'&&!info.cancel&&!this.hasJudge(lib.inpile[i])){
list.push(lib.inpile[i]);
}
}
if(list.length){
var card=game.createCard(list.randomGet());
this.addJudge(card);
this.$draw(card);
if(!nodelay) game.delay();
}
else{
this.getDebuff(6);
}
break;
}
}
},
dying:function(reason){ dying:function(reason){
if(this.nodying||this.hp>0||this.isDying()) return; if(this.nodying||this.hp>0||this.isDying()) return;
var next=game.createEvent('dying'); var next=game.createEvent('dying');