diff --git a/mode/doudizhu.js b/mode/doudizhu.js index cfc702fe0..c96b92544 100644 --- a/mode/doudizhu.js +++ b/mode/doudizhu.js @@ -113,8 +113,10 @@ game.import('mode',function(lib,game,ui,get,ai,_status){ game.addGlobalSkill('binglin_bingjin'); break; default: - game.zhu.addSkill('feiyang'); - game.zhu.addSkill('bahu'); + if(!game.zhu.isInitFilter('noZhuSkill')){ + game.zhu.addSkill('feiyang'); + game.zhu.addSkill('bahu'); + } } game.syncState(); event.trigger('gameStart'); @@ -489,9 +491,11 @@ game.import('mode',function(lib,game,ui,get,ai,_status){ } else player.addSkill('binglin_neihong'); } - game.zhu.hp++; - game.zhu.maxHp++; - game.zhu.update(); + if(!game.zhu.isInitFilter('noZhuHp')){ + game.zhu.maxHp++; + game.zhu.hp++; + game.zhu.update(); + } for(var i=0;i4){ - player.hp++; - player.maxHp++; - player.update(); + if(!player.isInitFilter('noZhuHp')){ + player.hp++; + player.maxHp++; + player.$update(); + } } } else if(player.identity=='zhong'&&(Math.random()<0.5||['sunliang','key_akane'].includes(game.zhu.name))&&!stratagemMode){ @@ -2099,9 +2111,11 @@ game.import('mode',function(lib,game,ui,get,ai,_status){ event.list.remove(get.sourceCharacter(game.me.name1)); event.list.remove(get.sourceCharacter(game.me.name2)); if(!event.stratagemMode&&game.me==game.zhu&&game.players.length>4){ - game.me.hp++; - game.me.maxHp++; - game.me.update(); + if(!game.me.isInitFilter('noZhuHp')){ + game.me.hp++; + game.me.maxHp++; + game.me.$update(); + } } for(var i=0;i4){ - game.zhu.maxHp++; - game.zhu.hp++; - game.zhu.update(); + if(!game.zhu.isInitFilter('noZhuHp')){ + game.zhu.maxHp++; + game.zhu.hp++; + game.zhu.update(); + } } game.broadcast(function(zhu,name,name2,addMaxHp){ if(!zhu.name){ zhu.init(name,name2); } if(addMaxHp){ - zhu.maxHp++; - zhu.hp++; - zhu.update(); + if(!zhu.isInitFilter('noZhuHp')){ + zhu.maxHp++; + zhu.hp++; + zhu.update(); + } } },game.zhu,result.links[0],result.links[1],game.players.length>4); diff --git a/mode/versus.js b/mode/versus.js index 20be6250b..bb70efa4c 100644 --- a/mode/versus.js +++ b/mode/versus.js @@ -1607,9 +1607,11 @@ game.import('mode',function(lib,game,ui,get,ai,_status){ choice=list[0]; } player.init(choice); - player.hp++; - player.maxHp++; - player.update(); + if(!player.isInitFilter('noZhuHp')){ + player.hp++; + player.maxHp++; + player.$update(); + } } else if(Math.random()<0.5){ var choice=0; @@ -1873,9 +1875,11 @@ game.import('mode',function(lib,game,ui,get,ai,_status){ event.list.remove(event.current.name1); event.list2.remove(event.current.name1); if(event.current.identity=='zhu'){ - event.current.hp++; - event.current.maxHp++; - event.current.update(); + if(!event.current.isInitFilter('noZhuHp')){ + event.current.hp++; + event.current.maxHp++; + event.current.$update(); + } } event.current.node.name_seat.remove(); } @@ -2038,13 +2042,17 @@ game.import('mode',function(lib,game,ui,get,ai,_status){ game.friend[i].node.identity.dataset.color=get.translation(_status.color+'Color'); game.enemy[i].node.identity.dataset.color=get.translation(!_status.color+'Color'); } - game.friendZhu.maxHp++; - game.friendZhu.hp++; - game.friendZhu.update(); + if(!game.friendZhu.isInitFilter('noZhuHp')){ + game.friendZhu.maxHp++; + game.friendZhu.hp++; + game.friendZhu.update(); + } - game.enemyZhu.maxHp++; - game.enemyZhu.hp++; - game.enemyZhu.update(); + if(!game.enemyZhu.isInitFilter('noZhuHp')){ + game.enemyZhu.maxHp++; + game.enemyZhu.hp++; + game.enemyZhu.update(); + } game.onSwapControl(); }); @@ -2528,13 +2536,17 @@ game.import('mode',function(lib,game,ui,get,ai,_status){ game.enemy[i].node.identity.dataset.color=get.translation(!_status.color+'Color'); } if(lib.storage.zhu&&lib.storage.main_zhu){ - game.friendZhu.maxHp++; - game.friendZhu.hp++; - game.friendZhu.update(); - - game.enemyZhu.maxHp++; - game.enemyZhu.hp++; - game.enemyZhu.update(); + if(!game.friendZhu.isInitFilter('noZhuHp')){ + game.friendZhu.maxHp++; + game.friendZhu.hp++; + game.friendZhu.update(); + } + + if(!game.enemyZhu.isInitFilter('noZhuHp')){ + game.enemyZhu.maxHp++; + game.enemyZhu.hp++; + game.enemyZhu.update(); + } } _status.friend.splice(0,num); _status.enemy.splice(0,num); @@ -2898,9 +2910,11 @@ game.import('mode',function(lib,game,ui,get,ai,_status){ } },event.current,result.links[0]); if(event.current.identity=='zhu'){ - event.current.hp++; - event.current.maxHp++; - event.current.update(); + if(!event.current.isInitFilter('noZhuHp')){ + event.current.maxHp++; + event.current.hp++; + event.current.update(); + } } event.current.classList.remove('selectedx'); for(var i=0;i