diff --git a/CHANGELOG.MD b/CHANGELOG.MD index bd8914fd7..cef9d785f 100644 --- a/CHANGELOG.MD +++ b/CHANGELOG.MD @@ -1,2 +1,4 @@ -1.5.8 -低性能模式改进 +1.6.0 +低性能模式优化 +双击换肤 +新手向导 diff --git a/character/rank.js b/character/rank.js index 32a5585cc..0f21d68de 100644 --- a/character/rank.js +++ b/character/rank.js @@ -90,6 +90,7 @@ window.characterRank={ 'liuchen', ], am:[ + 'zhugeguo', 'sp_caiwenji', 'caorui', 'manchong', diff --git a/character/refresh.js b/character/refresh.js index 809711040..abe3d8fcd 100755 --- a/character/refresh.js +++ b/character/refresh.js @@ -909,7 +909,8 @@ character.refresh={ result:{ player:function(player){ if(player.hp<=2) return player.num('h')==0?1:0; - return player.num('h').tutorial_tap{ + width:30px; + height:30px; + border-radius: 100%; + background: rgba(255,255,255,0.5); + box-shadow: rgba(255,255,255,0.5) 0 0 5px; + left:calc(50% - 15px); + top:calc(50% - 15px); + position: absolute; + transition: all 1s; +} +#window.noclick_important *{pointer-events: none !important;} +#window.noclick_important .noclick_click_important div{pointer-events: auto !important} #arena{width:90%;height: 90%;top: calc(5% + 10px);left: 5%;} #arena.right:not(.noleft){left:240px;opacity: 0.6;} #arena.left:not(.noleft){left:calc(10% - 240px);opacity: 0.6;} @@ -23,6 +36,10 @@ table{table-layout: fixed;} top:0; z-index:20 } +#arena.only_dialog>div:not(.dialog):not(#control){ + opacity: 0 !important; + pointer-events: none !important; +} #arena>canvas{ z-index: 10; pointer-events: none; @@ -197,6 +214,9 @@ body>.background{z-index:-2} transform:scale(0.8); transform-origin:bottom left; } +.dialog .buttons>.button.character{ + height:108px; +} .card.center{top:calc(50% - 52px);left:calc(50% - 52px);} .card>.background{font-size: 80px;height: 80px;padding-top: 14px;text-align: center;} .equips>.card>.background{font-size: 36px;height: 36px;padding-top: 3px;} diff --git a/manifest.json b/manifest.json index 66cfc64de..c2e31639d 100644 --- a/manifest.json +++ b/manifest.json @@ -1,6 +1,6 @@ { "name": "noname", - "xwalk_version": "1.5.8", + "xwalk_version": "1.6.0", "start_url": "index.html", "icons": [ { diff --git a/mode/chess.js b/mode/chess.js index 1387969bc..25ad97daf 100755 --- a/mode/chess.js +++ b/mode/chess.js @@ -2240,8 +2240,8 @@ mode.chess={ intro.classList.add('showintro'); intro.style.fontFamily='huangcao'; intro.style.fontSize='20px'; - intro.style.top='67px'; - intro.style.left='1px'; + intro.style.top='82px'; + intro.style.left='2px'; switch(rarity){ case 'rare':intro.dataset.nature='waterm';break; case 'epic':intro.dataset.nature='thunderm';break; diff --git a/mode/identity.js b/mode/identity.js index 0aeefcb81..5df74c4be 100755 --- a/mode/identity.js +++ b/mode/identity.js @@ -44,16 +44,180 @@ mode.identity={ else{ game.prepareArena(); } - game.delay(); + if(!lib.config.new_tutorial){ + game.delay(); + } } "step 1" + if(!lib.config.new_tutorial){ + var clear=function(){ + ui.dialog.close(); + while(ui.controls.length) ui.controls[0].close(); + }; + var clear2=function(){ + ui.auto.show(); + ui.arena.classList.remove('only_dialog'); + }; + var step1=function(){ + ui.create.dialog('欢迎来到无名杀,是否进入新手向导?'); + game.saveConfig('new_tutorial',true); + ui.dialog.add('
跳过后,你可以在选项-其它中重置新手向导'); + ui.auto.hide(); + ui.create.control('跳过向导',function(){ + clear(); + clear2(); + game.resume(); + }); + ui.create.control('继续',step2); + } + var step2=function(){ + if(lib.config.layout!='phone'){ + clear(); + ui.create.dialog('如果你在使用手机,可能会觉得按钮有点小'+ + ',将布局改成移动可以使按钮变大'); + ui.dialog.add('
你可以在选项-外观-布局中更改此设置'); + var lcontrol=ui.create.control('使用移动布局',function(){ + if(lib.config.layout=='phone'){ + ui.control.firstChild.firstChild.innerHTML='使用移动布局'; + lib.init.layout('mobile'); + } + else{ + ui.control.firstChild.firstChild.innerHTML='使用默认布局'; + lib.init.layout('phone'); + } + }); + ui.create.control('继续',step3); + } + else{ + step3(); + } + }; + var step3=function(){ + if(lib.config.layout=='phone'){ + clear(); + ui.create.dialog('在移动布局后,点击顶部的左半边或右半边可以显示按钮'); + var node=ui.create.div('.tutorial_tap',ui.window); + var nodefunc=function(){ + setTimeout(function(){ + node.style.top='20px'; + node.style.left='10%'; + setTimeout(function(){ + node.style.transition='all 0.2s'; + node.style.opacity=0; + setTimeout(function(){ + node.style.opacity=''; + setTimeout(function(){ + node.style.transition=''; + },300); + },300); + },1200); + setTimeout(function(){ + node.style.left='calc(90% - 30px)'; + setTimeout(function(){ + node.style.transition='all 0.2s'; + node.style.opacity=0; + setTimeout(function(){ + node.style.opacity=''; + setTimeout(function(){ + node.style.transition=''; + },300); + },300); + },1200); + setTimeout(function(){ + node.style.top=''; + node.style.left=''; + },2000); + },2000); + },1000); + }; + nodefunc(); + var interval=setInterval(nodefunc,7000); + var interval2,node2; + var double=true; + ui.create.control('继续',function(){ + if(double){ + node2=ui.create.div('.tutorial_tap',ui.window); + ui.refresh(node2); + node2.style.top='20px'; + node2.style.left='calc(50% - 15px)'; + interval2=setInterval(function(){ + node2.style.transition='all 0.2s'; + node2.style.opacity=0; + setTimeout(function(){ + node2.style.opacity=''; + setTimeout(function(){ + node2.style.opacity=0; + setTimeout(function(){ + node2.style.opacity=''; + setTimeout(function(){ + node2.style.transition=''; + },300); + },300); + },300); + },300); + },3000); + clearInterval(interval); + node.delete(); + double=false; + ui.dialog.close(); + ui.create.dialog('双击顶部可令界面下移,方便进行标身份等操作'); + } + else{ + clearInterval(interval2); + node2.delete(); + step4(); + } + }); + } + else{ + step4(); + } + }; + var step4=function(){ + clear(); + ui.window.classList.add('noclick_important'); + ui.click.configMenu(); + ui.control.classList.add('noclick_click_important'); + ui.control.style.top='calc(100% - 105px)'; + ui.create.control('在菜单中,可以进行各项设置',function(){ + ui.click.menuTab('选项'); + ui.controls[0].replace('如果你感到游戏较卡,可以开启低性能模式',function(){ + ui.controls[0].replace('在技能一栏中,可以设置自动发动或双将禁配的技能',function(){ + ui.click.menuTab('武将'); + ui.controls[0].replace('在武将或卡牌一栏中,单击武将/卡牌可以将其禁用',function(){ + ui.click.menuTab('战局'); + ui.controls[0].replace('在战局中可以输入游戏命令,或者管理录像',function(){ + ui.click.configMenu(); + ui.window.classList.remove('noclick_important'); + ui.control.classList.remove('noclick_click_important'); + ui.control.style.top=''; + step5(); + }); + }); + }); + }); + }) + }; + var step5=function(){ + clear(); + ui.create.dialog('如果还有其它问题,欢迎来到百度无名杀吧进行交流'); + ui.create.control('完成',function(){ + clear(); + clear2(); + game.resume(); + }) + }; + game.pause(); + step1(); + } + "step 2" if(lib.storage.test){ lib.config.game_speed='vfast'; _status.auto=true; ui.auto.classList.add('glow'); } game.chooseCharacter(); - "step 2" + "step 3" if(game.players.length==2){ game.showIdentity(true); } diff --git a/mode/versus.js b/mode/versus.js index 9b03d248f..a782f4065 100755 --- a/mode/versus.js +++ b/mode/versus.js @@ -965,7 +965,7 @@ mode.versus={ var info=lib.character[name]; if(lib.config.layout=='newlayout'&&info[4]&&info[4].contains('fullskin')){ ui.fakeme.classList.add('fullskin'); - ui.fakemebg.style.backgroundImage='url("image/character/fullskin/'+name+'.jpg")'; + ui.fakemebg.style.backgroundImage='url("image/character/'+name+'.jpg")'; ui.fakemebg.style.backgroundSize='cover'; } else{ diff --git a/package.json b/package.json index e2baafcf7..154fea0a4 100755 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { "name" : "无名杀", - "version" : "1.5.8", + "version" : "1.6.0", "main" : "main.js" }