This commit is contained in:
libccy 2017-02-13 16:19:44 +08:00
parent aa58fcd41b
commit 9f306f67cc
7 changed files with 127 additions and 74 deletions

View File

@ -1278,11 +1278,11 @@ card.gujian={
nopop:true, nopop:true,
intro:{ intro:{
content:function(storage,player){ content:function(storage,player){
return '结束阶段,你有70%的机率弃置一名随机敌人的一张随机牌(剩余'+player.storage.mapodoufu_markcount+'回合)' return '结束阶段,你有65%的机率弃置一名随机敌人的一张随机牌(剩余'+player.storage.mapodoufu_markcount+'回合)'
} }
}, },
content:function(){ content:function(){
if(Math.random()<0.7){ if(Math.random()<0.65){
var list=player.getEnemies(); var list=player.getEnemies();
for(var i=0;i<list.length;i++){ for(var i=0;i<list.length;i++){
if(!list[i].num('he')){ if(!list[i].num('he')){
@ -1632,7 +1632,7 @@ card.gujian={
molicha:'茉莉茶', molicha:'茉莉茶',
molicha_info:'弃置判定区内的所有牌;你不能成为延时锦囊牌的目标,持续五回合', molicha_info:'弃置判定区内的所有牌;你不能成为延时锦囊牌的目标,持续五回合',
mapodoufu:'麻婆豆腐', mapodoufu:'麻婆豆腐',
mapodoufu_info:'结束阶段,你有70%的机率弃置一名随机敌人的一张随机牌,持续三回合', mapodoufu_info:'结束阶段,你有65%的机率弃置一名随机敌人的一张随机牌,持续三回合',
}, },
list:[ list:[
['spade',2,'tanhuadong'], ['spade',2,'tanhuadong'],

View File

@ -1154,9 +1154,6 @@ character.xianjian={
}, },
luanjian:{ luanjian:{
enable:'phaseUse', enable:'phaseUse',
filter:function(event,player){
return player.num('h','sha')>1&&lib.filter.filterCard({name:'sha'},player);
},
filterCard:{name:'sha'}, filterCard:{name:'sha'},
selectCard:2, selectCard:2,
check:function(card){ check:function(card){
@ -1172,50 +1169,19 @@ character.xianjian={
} }
return 0; return 0;
}, },
viewAs:{name:'sha'},
selectTarget:[1,Infinity], selectTarget:[1,Infinity],
discard:false,
line:false,
multiline:true,
prepare:'throw',
filterTarget:function(card,player,target){ filterTarget:function(card,player,target){
return lib.filter.targetEnabled({name:'sha'},player,target); return lib.filter.targetEnabled({name:'sha'},player,target);
}, },
content:function(){
"step 0"
if(!player.hasSkill('unequip')){
event.added=true;
player.skills.push('unequip');
}
targets.sort(lib.sort.seat);
player.useCard({name:'sha'},cards,targets,'luanjian').animate=false;
"step 1"
if(event.added){
player.skills.remove('unequip');
}
},
multitarget:true,
ai:{ ai:{
order:function(){ order:function(){
return lib.card.sha.ai.order+0.1; return lib.card.sha.ai.order+0.1;
}, },
result:{
target:function(player,target){
var added=false;
if(!player.hasSkill('unequip')){
added=true;
player.skills.push('unequip');
}
var eff=ai.get.effect(target,{name:'sha'},player,target);
if(added){
player.skills.remove('unequip');
}
return eff;
}
},
effect:{ effect:{
player:function(card,player){ player:function(card,player){
if(_status.currentPhase!=player) return; if(_status.currentPhase!=player) return;
if(card.name=='sha'&&player.num('h','sha')<2&&player.num('h')<=player.hp){ if(card.name=='sha'&&player.num('h','sha')<2&&!player.needsToDiscard()){
var num=0; var num=0;
var player=_status.event.player; var player=_status.event.player;
var players=game.filterPlayer(); var players=game.filterPlayer();
@ -1229,6 +1195,18 @@ character.xianjian={
} }
} }
}, },
},
group:'luanjian2'
},
luanjian2:{
trigger:{source:'damageBegin'},
forced:true,
popup:false,
filter:function(event,player){
return event.card&&event.card.name=='sha'&&event.parent.skill=='luanjian';
},
content:function(){
if(Math.random()<0.5) trigger.num++;
} }
}, },
tianfu:{ tianfu:{
@ -2496,7 +2474,7 @@ character.xianjian={
xfenxin2:'焚心', xfenxin2:'焚心',
xfenxin_info:'锁定技,每当你的体力值发生改变,你摸等量的牌;每当你杀死一名角色,你增加一点体力上限并回复一点体力', xfenxin_info:'锁定技,每当你的体力值发生改变,你摸等量的牌;每当你杀死一名角色,你增加一点体力上限并回复一点体力',
luanjian:'乱剑', luanjian:'乱剑',
luanjian_info:'你可以将两张杀当杀使用,此杀无视距离和防具可以指定任意名目标', luanjian_info:'出牌阶段,你可以将两张杀当杀使用,此杀无视距离,可以指定任意名目标且有50%的机率伤害+1',
tianfu:'天符', tianfu:'天符',
tianfu2:'天符', tianfu2:'天符',
tianfu3:'天符', tianfu3:'天符',

View File

@ -985,6 +985,11 @@
init:true, init:true,
unfrequent:true unfrequent:true
}, },
right_range:{
name:'显示距离信息',
init:true,
unfrequent:true
},
hide_card_image:{ hide_card_image:{
name:'隐藏卡牌背景', name:'隐藏卡牌背景',
init:false, init:false,
@ -18110,6 +18115,7 @@
} }
game.singleHandcard=true; game.singleHandcard=true;
ui.arena.classList.add('single-handcard'); ui.arena.classList.add('single-handcard');
ui.window.classList.add('single-handcard');
ui.fakeme=ui.create.div('.fakeme.avatar',ui.me); ui.fakeme=ui.create.div('.fakeme.avatar',ui.me);
} }
ui.arena.style.display=''; ui.arena.style.display='';
@ -18120,6 +18126,7 @@
if(!players.boss){ if(!players.boss){
game.singleHandcard=true; game.singleHandcard=true;
ui.arena.classList.add('single-handcard'); ui.arena.classList.add('single-handcard');
ui.window.classList.add('single-handcard');
ui.fakeme=ui.create.div('.fakeme.avatar',ui.me); ui.fakeme=ui.create.div('.fakeme.avatar',ui.me);
} }
ui.arena.setNumber(8); ui.arena.setNumber(8);
@ -27418,7 +27425,13 @@
} }
} }
game.saveConfig('check_version',update.version); game.saveConfig('check_version',update.version);
if(update.version!=lib.version||dev){ var goon=true;
if(!dev){
if(update.version.indexOf('beta')!=-1||update.version==lib.version){
goon=false;
}
}
if(goon){
var files=null; var files=null;
var version=lib.version; var version=lib.version;
if(Array.isArray(update.dev)&&dev){ if(Array.isArray(update.dev)&&dev){
@ -29676,7 +29689,10 @@
if(lib.config.textequip=='text') ui.arena.classList.add('textequip'); if(lib.config.textequip=='text') ui.arena.classList.add('textequip');
} }
if(game.layout=='long'||game.layout=='long2'||game.layout=='mobile'){ if(game.layout=='long'||game.layout=='long2'||game.layout=='mobile'){
if(lib.config.cardshape=='oblong') ui.arena.classList.add('oblongcard'); if(lib.config.cardshape=='oblong'){
ui.window.classList.add('oblongcard');
ui.arena.classList.add('oblongcard');
}
} }
if(lib.config.blur_ui){ if(lib.config.blur_ui){
ui.window.classList.add('blur_ui'); ui.window.classList.add('blur_ui');
@ -30310,7 +30326,8 @@
handcards1:ui.create.div('.handcards'), handcards1:ui.create.div('.handcards'),
handcards2:ui.create.div('.handcards'), handcards2:ui.create.div('.handcards'),
}; };
for(var i=0;i<40;i++){ var chainlength=game.layout=='default'?64:40;
for(var i=0;i<chainlength;i++){
ui.create.div(node.node.chain.firstChild,'.cardbg').style.transform='translateX('+(i*5-5)+'px)'; ui.create.div(node.node.chain.firstChild,'.cardbg').style.transform='translateX('+(i*5-5)+'px)';
} }
node.node.action=ui.create.div('.action',node.node.avatar); node.node.action=ui.create.div('.action',node.node.avatar);
@ -35060,6 +35077,45 @@
} }
} }
} }
if(lib.config.right_range){
uiintro.add(ui.create.div('.placeholder'));
var table,tr,td;
table=document.createElement('table');
tr=document.createElement('tr');
table.appendChild(tr);
td=document.createElement('td');
td.innerHTML='攻击';
tr.appendChild(td);
td=document.createElement('td');
td.innerHTML='进攻';
tr.appendChild(td);
td=document.createElement('td');
td.innerHTML='防御';
tr.appendChild(td);
td=document.createElement('td');
td.innerHTML='手牌';
tr.appendChild(td);
tr=document.createElement('tr');
table.appendChild(tr);
td=document.createElement('td');
td.innerHTML=node.getAttackRange();
tr.appendChild(td);
td=document.createElement('td');
td.innerHTML=node.getGlobalFrom();
tr.appendChild(td);
td=document.createElement('td');
td.innerHTML=node.getGlobalTo();
tr.appendChild(td);
td=document.createElement('td');
td.innerHTML=node.num('h');
tr.appendChild(td);
table.style.width='calc(100% - 20px)';
table.style.marginLeft='10px';
uiintro.content.appendChild(table);
}
if(!simple||get.is.phoneLayout()){ if(!simple||get.is.phoneLayout()){
var es=node.get('e'); var es=node.get('e');
for(var i=0;i<es.length;i++){ for(var i=0;i<es.length;i++){
@ -35091,38 +35147,7 @@
addFavourite.listen(ui.click.favouriteCharacter) addFavourite.listen(ui.click.favouriteCharacter)
uiintro.add(addFavourite); uiintro.add(addFavourite);
} }
if(!simple||get.is.phoneLayout()){ if(!simple||get.is.phoneLayout()){
if(lib.falseitem){
uiintro.add(ui.create.div('.placeholder'));
var table,tr,td;
table=document.createElement('table');
tr=document.createElement('tr');
table.appendChild(tr);
td=document.createElement('td');
td.innerHTML='攻击范围';
tr.appendChild(td);
td=document.createElement('td');
td.innerHTML='进攻距离';
tr.appendChild(td);
td=document.createElement('td');
td.innerHTML='防御距离';
tr.appendChild(td);
tr=document.createElement('tr');
table.appendChild(tr);
td=document.createElement('td');
td.innerHTML=node.getAttackRange();
tr.appendChild(td);
td=document.createElement('td');
td.innerHTML=node.getGlobalFrom();
tr.appendChild(td);
td=document.createElement('td');
td.innerHTML=node.getGlobalTo();
tr.appendChild(td);
uiintro.content.appendChild(table);
}
if(lib.config.change_skin&&(!node.classList.contains('unseen')||!node.classList.contains('unseen2'))){ if(lib.config.change_skin&&(!node.classList.contains('unseen')||!node.classList.contains('unseen2'))){
var num=1; var num=1;
var introadded=false; var introadded=false;

View File

@ -1,8 +1,40 @@
@import "../mobile/layout.css"; @import "../mobile/layout.css";
#window.rightbar #system,
#window.leftbar #system{
width: calc(100% - 62px);
}
#window.leftbar #system{
left: 50px;
}
#window.rightbar #historybar{
left: calc(100% - 50px);
}
#window.leftbar #historybar{
left: 0;
}
#historybar{
left: calc(100% - 50px);
border-radius: 0;
top: 0;
height: calc(100% - 121px);
}
#window.oblongcard #historybar{
height: calc(100% - 141px);
}
#arena:not(.fewplayer)>.player:not(.minskin):not(*[data-position='0']){ #arena:not(.fewplayer)>.player:not(.minskin):not(*[data-position='0']){
width: 120px !important; width: 120px !important;
height: 220px !important; height: 220px !important;
} }
#arena:not(.fewplayer)>.player:not(.minskin):not(*[data-position='0'])>.marks{
left: -15px;
}
#arena:not(.fewplayer)>.player:not(.minskin):not(*[data-position='0'])>.judges{
right: -27px;
}
#arena:not(.fewplayer)[data-player_height='default']>.player:not(.minskin):not(*[data-position='0']){ #arena:not(.fewplayer)[data-player_height='default']>.player:not(.minskin):not(*[data-position='0']){
height: 200px !important; height: 200px !important;
} }

View File

@ -73,6 +73,14 @@
top: 0; top: 0;
height: 100%; height: 100%;
} }
#window.single-handcard #historybar{
height: calc(100% - 121px);
}
#window.oblongcard.single-handcard #historybar{
height: calc(100% - 141px);
}
#window.leftbar #arena:not(.chess)>#me, #window.leftbar #arena:not(.chess)>#me,
#window.leftbar #arena:not(.chess)>#mebg, #window.leftbar #arena:not(.chess)>#mebg,
#window.leftbar #arena:not(.chess)>#autonode{ #window.leftbar #arena:not(.chess)>#autonode{
@ -192,6 +200,13 @@
} }
#arena>.player:not(.minskin)>.marks{
left: -15px;
}
#arena>.player:not(.minskin)>.judges{
right: -27px;
}
#arena>.player:not(.minskin){ #arena>.player:not(.minskin){
width: 120px !important; width: 120px !important;

View File

@ -234,6 +234,7 @@ mode.boss={
if(game.me!==boss){ if(game.me!==boss){
game.singleHandcard=true; game.singleHandcard=true;
ui.arena.classList.add('single-handcard'); ui.arena.classList.add('single-handcard');
ui.window.classList.add('single-handcard');
ui.fakeme=ui.create.div('.fakeme.avatar',ui.me); ui.fakeme=ui.create.div('.fakeme.avatar',ui.me);
// ui.fakeme.dataset.position=0; // ui.fakeme.dataset.position=0;
// ui.fakeme.line=lib.element.player.line; // ui.fakeme.line=lib.element.player.line;

View File

@ -1112,6 +1112,7 @@ mode.versus={
} }
game.singleHandcard=true; game.singleHandcard=true;
ui.arena.classList.add('single-handcard'); ui.arena.classList.add('single-handcard');
ui.window.classList.add('single-handcard');
ui.fakeme=ui.create.div('.fakeme.avatar'); ui.fakeme=ui.create.div('.fakeme.avatar');
_status.prepareArena=true; _status.prepareArena=true;
ui.create.me(); ui.create.me();
@ -1514,6 +1515,7 @@ mode.versus={
} }
game.singleHandcard=true; game.singleHandcard=true;
ui.arena.classList.add('single-handcard'); ui.arena.classList.add('single-handcard');
ui.window.classList.add('single-handcard');
ui.fakeme=ui.create.div('.fakeme.avatar'); ui.fakeme=ui.create.div('.fakeme.avatar');
// ui.fakeme.line=lib.element.player.line; // ui.fakeme.line=lib.element.player.line;
// ui.fakemebg=ui.create.div('.avatar',ui.fakeme).hide(); // ui.fakemebg=ui.create.div('.avatar',ui.fakeme).hide();