This commit is contained in:
libccy 2018-08-19 10:17:31 +08:00
parent 1c733888c1
commit 5b35eee7fc
4 changed files with 64 additions and 30 deletions

View File

@ -520,9 +520,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},
guixin:{
audio:2,
alter:true,
trigger:{player:'damageEnd'},
check:function(event,player){
if(player.isTurnedOver()) return true;
if(player.isTurnedOver()||event.num>1) return true;
var num=game.countPlayer(function(current){
if(current.countCards('he')&&current!=player&&get.attitude(player,current)<=0){
return true;
@ -539,26 +540,47 @@ game.import('character',function(lib,game,ui,get,ai,_status){
targets.remove(player);
targets.sort(lib.sort.seat);
event.targets=targets;
event.count=trigger.num;
"step 1"
event.num=0;
player.line(targets,'green');
"step 1"
"step 2"
if(num<event.targets.length){
var hej=event.targets[num].getCards('hej')
if(hej.length){
var card=hej.randomGet();
player.gain(card,event.targets[num]);
if(get.position(card)=='h'){
event.targets[num].$giveAuto(card,player);
if(!get.is.altered('guixin')){
if(event.targets[num].countGainableCards(player,'hej')){
player.gainPlayerCard(event.targets[num],true);
}
else{
event.targets[num].$give(card,player);
}
else{
var hej=event.targets[num].getCards('hej')
if(hej.length){
var card=hej.randomGet();
player.gain(card,event.targets[num]);
if(get.position(card)=='h'){
event.targets[num].$giveAuto(card,player);
}
else{
event.targets[num].$give(card,player);
}
}
}
event.num++;
event.redo();
}
"step 2"
"step 3"
player.turnOver();
"step 4"
event.count--;
if(event.count){
player.chooseBool(get.prompt2('guixin'));
}
else{
event.finish();
}
"step 5"
if(event.count&&result.bool){
event.goto(1);
}
},
ai:{
maixie:true,
@ -1193,7 +1215,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
yeyan:'业炎',
shelie_info:'摸牌阶段,你可以改为从牌堆顶亮出五张牌,你获得不同花色的牌各一张',
gongxin_info:'出牌阶段,你可以观看一名其他角色的手牌,并可以展示其中一张红桃牌,然后将其弃置或置于牌堆顶,每阶段限一次。',
guixin_info:'当你受到1次伤害后你可以随机获得每名其他角色区域里的一张牌然后你翻面',
guixin_info:'当你受到1点伤害后你可以获得每名其他角色区域里的一张牌然后你翻面',
guixin_info_alter:'当你受到1点伤害后你可以随机获得每名其他角色区域里的一张牌然后你翻面',
qinyin_info:'弃牌阶段结束时若你于此阶段内弃置过你的至少两张手牌则你可以选择一项1. 所有角色各回复1点体力2. 所有角色各失去1点体力。',
// qinyin_info:'每当你于弃牌阶段内因你的弃置而失去第X张手牌时X至少为2你可以选择一项1.令所有角色各回复1点体力2.令所有角色各失去1点体力。每阶段限一次。',
yeyan_info:'限定技出牌阶段你可以对一至三名角色造成至多共3点火焰伤害你可以任意分配每名目标角色受到的伤害点数若你将对一名角色分配2点或更多的火焰伤害你须先弃置四张不同花色的手牌再失去3点体力。',

View File

@ -81,6 +81,7 @@ window.config={
customBackgroundPack:[],
favouriteCharacter:[],
recentIP:[],
vintageSkills:[],
alteredSkills:[],
brokenFile:[],

View File

@ -29016,7 +29016,7 @@
var info=lib.skill[i];
if(info.alter){
lib.translate[i+'_info_origin']=lib.translate[i+'_info'];
if(lib.config.alteredSkills.contains(i)){
if(!lib.config.vintageSkills.contains(i)){
lib.translate[i+'_info']=lib.translate[i+'_info_alter'];
}
}
@ -32476,7 +32476,7 @@
if(lib.skill[info[i][3][j]].alter){
alterableSkills.add(info[i][3][j]);
alterableCharacters.add(i);
if(!lib.config.alteredSkills.contains(info[i][3][j])){
if(lib.config.vintageSkills.contains(info[i][3][j])){
charactersToAlter.add(i);
}
}
@ -32523,17 +32523,17 @@
onclick:function(bool){
if(bool){
for(var i=0;i<alterableSkills.length;i++){
lib.config.alteredSkills.add(alterableSkills[i]);
lib.config.vintageSkills.remove(alterableSkills[i]);
lib.translate[alterableSkills[i]+'_info']=lib.translate[alterableSkills[i]+'_info_alter'];
}
}
else{
for(var i=0;i<alterableSkills.length;i++){
lib.config.alteredSkills.remove(alterableSkills[i]);
lib.config.vintageSkills.add(alterableSkills[i]);
lib.translate[alterableSkills[i]+'_info']=lib.translate[alterableSkills[i]+'_info_origin'];
}
}
game.saveConfig('alteredSkills',lib.config.alteredSkills);
game.saveConfig('vintageSkills',lib.config.vintageSkills);
}
});
cfgnode2.style.marginTop='0px';
@ -42406,17 +42406,24 @@
}
}
if(info.alter){
intro2.innerHTML+='<br><br><div class="hrefnode skillversion">切换版本</div>';
intro2.querySelector('.hrefnode.skillversion').listen(function(){
if(lib.config.alteredSkills.contains(skill)){
lib.config.alteredSkills.remove(skill);
lib.translate[skill+'_info']=lib.translate[skill+'_info_origin'];
}
else{
lib.config.alteredSkills.push(skill);
intro2.innerHTML+='<br><br><div class="hrefnode skillversion"></div>';
var skillversionnode=intro2.querySelector('.hrefnode.skillversion');
if(lib.config.vintageSkills.contains(skill)){
skillversionnode.innerHTML='切换至新版';
}
else{
skillversionnode.innerHTML='切换至旧版';
}
skillversionnode.listen(function(){
if(lib.config.vintageSkills.contains(skill)){
lib.config.vintageSkills.remove(skill);
lib.translate[skill+'_info']=lib.translate[skill+'_info_alter'];
}
game.saveConfig('alteredSkills',lib.config.alteredSkills);
else{
lib.config.vintageSkills.push(skill);
lib.translate[skill+'_info']=lib.translate[skill+'_info_origin'];
}
game.saveConfig('vintageSkills',lib.config.vintageSkills);
clickSkill.call(skillnode,'init');
});
}
@ -43420,7 +43427,7 @@
},
altered:function(skill){
if(_status.connectMode) return true;
return lib.config.alteredSkills.contains(skill);
return !lib.config.vintageSkills.contains(skill);
},
node:function(obj){
var str=Object.prototype.toString.call(obj);
@ -44186,7 +44193,7 @@
}
}
for(var i=0;i<skills.length;i++){
if(lib.config.alteredSkills.contains(skills[i])){
if(!lib.config.vintageSkills.contains(skills[i])){
name=lib.rank.a[0];break;
}
}

View File

@ -1,12 +1,15 @@
window.noname_update={
version:'1.9.55.4',
version:'1.9.56',
update:'1.9.55.2',
changeLog:[
'bug修复',
'技能可单独选择新旧版'
'技能可单独选择新旧版(默认新版)'
],
files:[
'mode/guozhan.js',
'game/config.js',
'game/game.js',
'character/extra.js',
'character/yijiang.js',
]
};