This commit is contained in:
libccy 2017-02-25 13:58:39 +08:00
parent 88fde2ae78
commit 37a1b53aae
2 changed files with 102 additions and 22 deletions

View File

@ -5823,29 +5823,61 @@ character.sp={
content:function(){
"step 0"
if(trigger.delay==false) game.delay();
event.cards=[];
for(var i=0;i<trigger.cards.length;i++){
if(get.position(trigger.cards[i])=='d'){
event.cards.push(trigger.cards[i]);
ui.special.appendChild(trigger.cards[i]);
}
}
"step 1"
player.chooseTarget(get.prompt('lirang'),function(card,player,target){
return player!=target
}).set('ai',function(target){
var att=ai.get.attitude(_status.event.player,target);
if(_status.event.du) return -att;
return att;
}).set('du',(trigger.cards.length==1&&trigger.cards[0].name=='du'));
if(event.cards.length){
player.chooseCardButton(get.prompt('lirang'),event.cards,[1,event.cards.length]).set('ai',function(button){
if(!_status.event.goon||ui.selected.buttons.length) return 0;
return 1;
}).set('goon',game.hasPlayer(function(current){
return Math.abs(ai.get.attitude(player,current))>1;
}));
}
else{
event.finish();
}
"step 2"
if(result.bool){
var target=result.targets[0];
player.logSkill('lirang',target);
var cards=[];
for(var i=0;i<trigger.cards.length;i++){
if(get.position(trigger.cards[i])=='d'){
cards.push(trigger.cards[i]);
event.togive=result.links.slice(0);
player.chooseTarget('将'+get.translation(result.links)+'交给一名角色',true,function(card,player,target){
return target!=player;
}).set('ai',function(target){
var att=ai.get.attitude(_status.event.player,target);
if(_status.event.enemy){
return -att;
}
else{
return att/Math.sqrt(1+target.num('h'));
}
}).set('enemy',ai.get.value(event.togive[0])<0);
}
else{
for(var i=0;i<event.cards.length;i++){
ui.discardPile(event.cards[i]);
}
target.gain(cards);
target.$gain2(cards);
if(target==game.me){
game.delayx();
event.finish();
}
"step 3"
if(result.bool){
player.logSkill('lirang',result.targets);
for(var i=0;i<event.togive.length;i++){
event.cards.remove(event.togive[i]);
}
result.targets[0].gain(event.togive,player);
result.targets[0].$gain2(event.togive);
event.goto(1);
}
else{
for(var i=0;i<event.cards.length;i++){
ui.discardPile(event.cards[i]);
}
event.finish();
}
},
ai:{
@ -6610,8 +6642,31 @@ character.sp={
player.awakenSkill('xiongyi');
game.asyncDraw(targets,3);
"step 1"
if(targets.length<=2){
player.recover();
if(player.isDamaged()){
if(get.mode()=='guozhan'){
if(player.identity=='ye'){
player.recover();
}
else{
var groups={
wei:0,
shu:0,
wu:0,
qun:0
}
game.countPlayer(function(current){
if(groups.hasOwnProperty(current.identity)){
groups[current.identity]++;
}
});
if(groups.qun<=groups.wei&&groups.qun<=groups.shu&&groups.qun<=groups.wu){
player.recover();
}
}
}
else if(targets.length<=2){
player.recover();
}
}
},
intro:{
@ -8211,7 +8266,7 @@ character.sp={
kaikang_info:'每当你距离1以内的角色成为杀的目标后你可以摸一张牌。若如此做你交给其一张牌并展示之若该牌为装备牌该角色可以使用此牌。',
liangzhu_info:'当一名角色于其出牌阶段内回复体力时你可以选择一项1、摸一张牌2、令该角色摸两张牌 ',
mingshi_info:'当你即将受到伤害时,若伤害来源的体力值大于你,你可以弃置一张黑色手牌令伤害-1 ',
lirang_info:'你可以将你弃置的卡牌交给一名其他角色 ',
lirang_info:'当你的牌因弃置而置入弃牌堆时,你可以将其中的任意张牌交给其他角色',
moukui_info:'当你使用【杀】指定一名角色为目标后,你可以选择一项:摸一张牌,或弃置其一张牌。若如此做,此【杀】被【闪】抵消时,该角色弃置你的一张牌。 ',
qiangwu_info:'出牌阶段,你可以进行一次判定。若如此做,则直到回合结束,你使用点数小于判定牌的 【杀】时不受距离限制,且你使用点数大于判定牌的【杀】时不计入出牌阶段的使用次数。',
shenxian_info:'每名角色的回合限一次,你的回合外,每当有其他角色因弃置而失去牌时,若其中有基本牌,你可以摸一张牌。',

View File

@ -211,7 +211,7 @@ mode.guozhan={
gz_zhangjiao:['male','qun',3,['leiji','guidao']],
gz_caiwenji:['female','qun',3,['beige','gzduanchang']],
gz_mateng:['male','qun',4,['mashu','xiongyi']],
gz_kongrong:['male','qun',3,['mingshi','lirang']],
gz_kongrong:['male','qun',3,['gzmingshi','lirang']],
gz_jiling:['male','qun',4,['shuangren']],
gz_tianfeng:['male','qun',3,['sijian','suishi']],
gz_panfeng:['male','qun',4,['kuangfu']],
@ -236,6 +236,29 @@ mode.guozhan={
}
},
skill:{
gzmingshi:{
trigger:{player:'damageBegin'},
forced:true,
filter:function(event,player){
return event.num>0&&event.source&&(event.source.classList.contains('unseen')||event.source.classList.contains('unseen2'));
},
content:function(){
trigger.num--;
},
ai:{
effect:{
target:function(card,player,target){
if(player.hasSkill('jueqing')) return;
if(!player.classList.contains('unseen')&&!player.classList.contains('unseen2')) return;
var num=get.tag(card,'damage');
if(num){
if(num>1) return 0.5;
return 0;
}
}
}
},
},
hunshang:{
init:function(player){
if(player.hasViceSkill('hunshang')){
@ -468,7 +491,7 @@ mode.guozhan={
return player!=target;
},
check:function(card){
if(ui.selected.cards.length>1) return 0;
if(ui.selected.cards.length>2) return 0;
if(ui.selected.cards.length&&ui.selected.cards[0].name=='du') return 0;
if(!ui.selected.cards.length&&card.name=='du') return 20;
var player=get.owner(card);
@ -1570,6 +1593,8 @@ mode.guozhan={
tongshimingzhi:'同时明置',
mode_guozhan_character_config:'国战武将',
gzmingshi:'名士',
gzmingshi_info:'锁定技,当你受到伤害时,若伤害来源有暗置的武将牌,此伤害-1',
chuanxin:'锋矢',
chuanxin_info:'阵法技,在同一个围攻关系中,若你是围攻角色,则你或另一名围攻角色使用【杀】指定被围攻角色为目标后,可令该角色弃置装备区里的一张牌',
fengshi:'穿心',