修复bug
This commit is contained in:
parent
5abd377c3d
commit
e00f1eaffc
|
@ -4,7 +4,6 @@
|
||||||
"funcscope": true,
|
"funcscope": true,
|
||||||
"esnext": true,
|
"esnext": true,
|
||||||
"eqnull": true,
|
"eqnull": true,
|
||||||
"strict": true,
|
|
||||||
"newcap": false,
|
"newcap": false,
|
||||||
"browser": true,
|
"browser": true,
|
||||||
"unused": true,
|
"unused": true,
|
||||||
|
|
|
@ -198,15 +198,15 @@ card.standard={
|
||||||
target:function(player,target){
|
target:function(player,target){
|
||||||
if(target.num('h')<=target.hp&&target.hp>2) return 0;
|
if(target.num('h')<=target.hp&&target.hp>2) return 0;
|
||||||
if(target.hp<0&&target!=player&&target.identity!='zhu') return 0;
|
if(target.hp<0&&target!=player&&target.identity!='zhu') return 0;
|
||||||
if(ai.get.attitude(player,target)<3) return 0;
|
var att=ai.get.attitude(player,target);
|
||||||
|
if(att<3&&att>=0) return 0;
|
||||||
var tri=_status.event.parent._trigger;
|
var tri=_status.event.parent._trigger;
|
||||||
if(lib.config.mode=='identity'&&player.identity=='fan'&&target.identity=='fan'){
|
if(lib.config.mode=='identity'&&player.identity=='fan'&&target.identity=='fan'){
|
||||||
if(tri&&tri.name=='dying'&&tri.source&&tri.source.identity=='fan'&&tri.source!=target){
|
if(tri&&tri.name=='dying'&&tri.source&&tri.source.identity=='fan'&&tri.source!=target){
|
||||||
var num=target.num('h','jiu')?1:0;
|
|
||||||
for(var i=0;i<game.players.length;i++){
|
for(var i=0;i<game.players.length;i++){
|
||||||
if(game.players[i].identity=='fan'){
|
if(game.players[i].identity=='fan'){
|
||||||
num+=game.players[i].num('h','tao');
|
num+=game.players[i].num('h','tao');
|
||||||
if(num>1) return 2;
|
if(num>2) return 2;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
|
|
|
@ -154,7 +154,7 @@ character.hearth={
|
||||||
game.delay(0.5);
|
game.delay(0.5);
|
||||||
var target=result.targets[0];
|
var target=result.targets[0];
|
||||||
player.logSkill('tzhenji',target,'thunder');
|
player.logSkill('tzhenji',target,'thunder');
|
||||||
target.damage('thunder',Math.floor(Math.random()*2));
|
target.damage('thunder',0);
|
||||||
var cs=target.get('he');
|
var cs=target.get('he');
|
||||||
if(cs.length){
|
if(cs.length){
|
||||||
target.discard(cs.randomGet());
|
target.discard(cs.randomGet());
|
||||||
|
@ -162,7 +162,15 @@ character.hearth={
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
ai:{
|
ai:{
|
||||||
threaten:0.7
|
threaten:1.2,
|
||||||
|
expose:0.3,
|
||||||
|
effect:{
|
||||||
|
target:function(card,player,target,current){
|
||||||
|
if(get.tag(card,'loseCard')&&target.num('he')){
|
||||||
|
return 0.7;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
tzhenji_old:{
|
tzhenji_old:{
|
||||||
|
@ -373,12 +381,12 @@ character.hearth={
|
||||||
tuteng4:{
|
tuteng4:{
|
||||||
mark:'image',
|
mark:'image',
|
||||||
intro:{
|
intro:{
|
||||||
content:'你的锦囊牌造成的伤害+1'
|
content:'你的属性伤害+1'
|
||||||
},
|
},
|
||||||
trigger:{source:'damageBegin'},
|
trigger:{source:'damageBegin'},
|
||||||
forced:true,
|
forced:true,
|
||||||
filter:function(event){
|
filter:function(event){
|
||||||
return event.card&&get.type(event.card)=='trick';
|
return event.nature?true:false;
|
||||||
},
|
},
|
||||||
content:function(){
|
content:function(){
|
||||||
trigger.num++;
|
trigger.num++;
|
||||||
|
@ -459,7 +467,7 @@ character.hearth={
|
||||||
tuteng3:'石爪图腾',
|
tuteng3:'石爪图腾',
|
||||||
tuteng4:'空气之怒图腾',
|
tuteng4:'空气之怒图腾',
|
||||||
tzhenji:'震击',
|
tzhenji:'震击',
|
||||||
tzhenji_info:'每当你因弃置而失去黑色牌,可对一名角色造成0~1点雷电伤害,然后随机弃置其一张牌',
|
tzhenji_info:'每当你因弃置而失去黑色牌,可对一名角色造成0点雷电伤害,然后随机弃置其一张牌',
|
||||||
fenliu:'分流',
|
fenliu:'分流',
|
||||||
fenliu_info:'出牌阶段限一次,你可以失去一点体力并获得3张牌',
|
fenliu_info:'出牌阶段限一次,你可以失去一点体力并获得3张牌',
|
||||||
hongxi:'虹吸',
|
hongxi:'虹吸',
|
||||||
|
|
|
@ -806,10 +806,7 @@ character.sp={
|
||||||
return event.player!=player&&_status.currentPhase==event.player;
|
return event.player!=player&&_status.currentPhase==event.player;
|
||||||
},
|
},
|
||||||
content:function(){
|
content:function(){
|
||||||
"step 0"
|
game.asyncDraw([trigger.player,player]);
|
||||||
trigger.player.draw();
|
|
||||||
"step 1"
|
|
||||||
player.draw();
|
|
||||||
},
|
},
|
||||||
ai:{
|
ai:{
|
||||||
expose:0.2
|
expose:0.2
|
||||||
|
|
|
@ -1327,7 +1327,7 @@ character.standard={
|
||||||
return -3;
|
return -3;
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
return ai.get.effect(ui.selected.targets[0],{name:'juedou'},target,player);
|
return ai.get.effect(ui.selected.targets[0],{name:'juedou'},target,target);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
@ -10,7 +10,7 @@ character.swd={
|
||||||
swd_nicole:['female','wu',3,['minjing','lingwu','huanjian'],['fullskin']],
|
swd_nicole:['female','wu',3,['minjing','lingwu','huanjian'],['fullskin']],
|
||||||
swd_wangsiyue:['female','wei',3,['duishi','guisi','biyue']],
|
swd_wangsiyue:['female','wei',3,['duishi','guisi','biyue']],
|
||||||
swd_weida:['female','qun',3,['yueren','zhenlie']],
|
swd_weida:['female','qun',3,['yueren','zhenlie']],
|
||||||
swd_xuanyuanjianxian:['male','qun',4,['fengmo','pozhou','huajian'],['fullskin']],
|
swd_xuanyuanjianxian:['male','qun',4,['pozhou','huajian'],['fullskin']],
|
||||||
|
|
||||||
swd_chenjingchou:['male','wu',3,['youyin','yihua'],['fullskin']],
|
swd_chenjingchou:['male','wu',3,['youyin','yihua'],['fullskin']],
|
||||||
swd_duguningke:['female','qun',3,['lianji','touxi'],['fullskin']],
|
swd_duguningke:['female','qun',3,['lianji','touxi'],['fullskin']],
|
||||||
|
|
|
@ -1672,6 +1672,7 @@
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
player._damagepopup=-num;
|
player._damagepopup=-num;
|
||||||
|
player._damagenature=event.nature;
|
||||||
setTimeout(function(){
|
setTimeout(function(){
|
||||||
player.popup(player._damagepopup,player._damagenature);
|
player.popup(player._damagepopup,player._damagenature);
|
||||||
delete player._damagepopup;
|
delete player._damagepopup;
|
||||||
|
@ -8506,6 +8507,7 @@
|
||||||
translate[1]+=e.y-ddialog._dragorigin.y;
|
translate[1]+=e.y-ddialog._dragorigin.y;
|
||||||
ddialog.style.webkitTransform='translate('+translate[0]+'px,'+translate[1]+'px)'
|
ddialog.style.webkitTransform='translate('+translate[0]+'px,'+translate[1]+'px)'
|
||||||
}
|
}
|
||||||
|
_status.clicked=true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
@ -194,6 +194,9 @@ mode.chess={
|
||||||
game.over(game.me.side==game.players[0].side);
|
game.over(game.me.side==game.players[0].side);
|
||||||
},
|
},
|
||||||
$draw:function(num){
|
$draw:function(num){
|
||||||
|
return this.$gainmod(num);
|
||||||
|
},
|
||||||
|
$drawx:function(num){
|
||||||
var cards,node;
|
var cards,node;
|
||||||
if(get.itemtype(num)=='cards'){
|
if(get.itemtype(num)=='cards'){
|
||||||
cards=num;
|
cards=num;
|
||||||
|
@ -663,6 +666,7 @@ mode.chess={
|
||||||
if(this._chessdrag){
|
if(this._chessdrag){
|
||||||
this.parentNode.scrollLeft=this._chessdrag[1]-e.x+this._chessdrag[0].x;
|
this.parentNode.scrollLeft=this._chessdrag[1]-e.x+this._chessdrag[0].x;
|
||||||
this.parentNode.scrollTop=this._chessdrag[2]-e.y+this._chessdrag[0].y;
|
this.parentNode.scrollTop=this._chessdrag[2]-e.y+this._chessdrag[0].y;
|
||||||
|
_status.clicked=true;
|
||||||
}
|
}
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
});
|
});
|
||||||
|
@ -820,7 +824,11 @@ mode.chess={
|
||||||
clickChessInfo:function(e){
|
clickChessInfo:function(e){
|
||||||
if(this.link.isAlive()){
|
if(this.link.isAlive()){
|
||||||
this.link.chessFocus();
|
this.link.chessFocus();
|
||||||
ui.click.target.call(this.link,e);
|
if(this.link.classList.contains('selectable')||
|
||||||
|
this.link.classList.contains('selected')){
|
||||||
|
this.link.click();
|
||||||
|
}
|
||||||
|
// ui.click.target.call(this.link,e);
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -1051,6 +1059,7 @@ mode.chess={
|
||||||
game.me.node.avatar.classList.remove('glow2');
|
game.me.node.avatar.classList.remove('glow2');
|
||||||
player.node.avatar.classList.add('glow2');
|
player.node.avatar.classList.add('glow2');
|
||||||
game.swapControl(player);
|
game.swapControl(player);
|
||||||
|
player.chessFocus();
|
||||||
ui.create.fakeme();
|
ui.create.fakeme();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -1305,7 +1314,7 @@ mode.chess={
|
||||||
zhiming:{
|
zhiming:{
|
||||||
trigger:{source:'damageBegin'},
|
trigger:{source:'damageBegin'},
|
||||||
filter:function(event,player){
|
filter:function(event,player){
|
||||||
return get.distance(event.player,player,'attack')>1;
|
return get.distance(event.player,player,'attack')>1&&event.card&&event.card.name=='sha';
|
||||||
},
|
},
|
||||||
forced:true,
|
forced:true,
|
||||||
content:function(){
|
content:function(){
|
||||||
|
|
|
@ -310,6 +310,11 @@ mode.versus={
|
||||||
ui.auto.show();
|
ui.auto.show();
|
||||||
ui.wuxie.show();
|
ui.wuxie.show();
|
||||||
ui.control.style.display='none';
|
ui.control.style.display='none';
|
||||||
|
setTimeout(function(){
|
||||||
|
ui.control.style.top='';
|
||||||
|
ui.control.style.display='';
|
||||||
|
ui.control.style.transition='';
|
||||||
|
},500);
|
||||||
if(ui.cheat){
|
if(ui.cheat){
|
||||||
ui.cheat.close();
|
ui.cheat.close();
|
||||||
delete ui.cheat;
|
delete ui.cheat;
|
||||||
|
@ -419,9 +424,6 @@ mode.versus={
|
||||||
// game.enemy[i].node.identity.style.backgroundColor=get.translation(!_status.color+'Color');
|
// game.enemy[i].node.identity.style.backgroundColor=get.translation(!_status.color+'Color');
|
||||||
}
|
}
|
||||||
"step 2"
|
"step 2"
|
||||||
ui.control.style.top='';
|
|
||||||
ui.control.style.display='';
|
|
||||||
ui.control.style.transition='';
|
|
||||||
var num=lib.storage.number;
|
var num=lib.storage.number;
|
||||||
if(result&&result.buttons){
|
if(result&&result.buttons){
|
||||||
var list=[];
|
var list=[];
|
||||||
|
|
Loading…
Reference in New Issue