From bf80a74e2dcb7dbda3405e4cbfa0b7aebd7396fe Mon Sep 17 00:00:00 2001 From: libccy Date: Sun, 19 Feb 2017 13:54:28 +0800 Subject: [PATCH] a --- character/extra.js | 1 + character/gujian.js | 1 + character/hearth.js | 1 + character/refresh.js | 2 ++ character/shenhua.js | 4 +++ character/sp.js | 8 +++++- character/standard.js | 3 +++ character/swd.js | 1 + character/xianjian.js | 4 +++ character/yijiang.js | 3 +++ game/game.js | 35 ++++++++++++++++++++++++++ layout/default/menu.css | 55 ++++++++++++++++++++++++++++++++++------- mode/boss.js | 2 ++ 13 files changed, 110 insertions(+), 10 deletions(-) diff --git a/character/extra.js b/character/extra.js index f14e73be1..96293055b 100644 --- a/character/extra.js +++ b/character/extra.js @@ -187,6 +187,7 @@ character.extra={ wuqian:{ audio:2, enable:'phaseUse', + derivation:'wushuang', filter:function(event,player){ return player.storage.baonu>=2&&!player.hasSkill('wushuang'); }, diff --git a/character/gujian.js b/character/gujian.js index 2a9a12e5f..de1341b37 100644 --- a/character/gujian.js +++ b/character/gujian.js @@ -1040,6 +1040,7 @@ character.gujian={ enable:'chooseToUse', skillAnimation:true, animationColor:'fire', + derivation:'juejing', filter:function(event,player){ return !player.storage.shahun&&player.hp<=0; }, diff --git a/character/hearth.js b/character/hearth.js index 522f80813..352deab89 100644 --- a/character/hearth.js +++ b/character/hearth.js @@ -4110,6 +4110,7 @@ character.hearth={ enable:'phaseUse', skillAnimation:'epic', animationColor:'thunder', + derivation:'xinci', filter:function(event,player){ return !player.storage.anying&&player.num('he',{color:'black'})>1; }, diff --git a/character/refresh.js b/character/refresh.js index c458c0135..35e0d87fb 100644 --- a/character/refresh.js +++ b/character/refresh.js @@ -458,6 +458,7 @@ character.refresh={ skillAnimation:true, audio:2, unique:true, + derivation:'gongxin', trigger:{player:'phaseBegin'}, forced:true, filter:function(event,player){ @@ -1203,6 +1204,7 @@ character.refresh={ unique:true, trigger:{source:'damageAfter'}, forced:true, + derivation:'jianyan', filter:function(event,player){ return player.hp=3&&!player.storage.zhiri; }, @@ -4906,6 +4908,7 @@ character.sp={ skillAnimation:true, unique:true, audio:2, + derivation:'tiaoxin', trigger:{player:'dying'}, priority:10, forced:true, @@ -5682,6 +5685,7 @@ character.sp={ audio:2, unique:true, forceunique:true, + derivation:'xiaoji', trigger:{player:'phaseBegin'}, filter:function(event,player){ if(player.storage.fanxiang) return false; @@ -6131,6 +6135,7 @@ character.sp={ unique:true, enable:'phaseUse', mark:true, + derivation:'yongjue', filter:function(event,player){ return !player.storage.cunsi&&player.num('h')&&!player.isTurnedOver(); }, @@ -7532,6 +7537,7 @@ character.sp={ juyi:{ skillAnimation:true, audio:true, + derivation:['benghuai','weizhong'], trigger:{player:'phaseBegin'}, filter:function(event,player){ return player.maxHp>game.players.length&&player.hp=4&&!player.storage.zzili; diff --git a/game/game.js b/game/game.js index 299d0e0f1..be5368e7d 100644 --- a/game/game.js +++ b/game/game.js @@ -29,6 +29,7 @@ video:[], _onDB:[], skilllist:[], + characterIntro:{}, characterPack:{}, cardPack:{}, onresize:[], @@ -33827,6 +33828,40 @@ if(lib.config.favouriteCharacter.contains(name)){ fav.classList.add('active'); } + var intro=ui.create.div('.characterintro',uiintro,lib.characterIntro[name]||'123'); + var intro2=ui.create.div('.characterintro.intro2',uiintro); + + var list=lib.character[name][3]; + var skills=ui.create.div('.characterskill',uiintro); + if(lib.config.mousewheel){ + skills.onmousewheel=ui.click.mousewheel; + } + var clickSkill=function(){ + var current=this.parentNode.querySelector('.active'); + if(current){ + current.classList.remove('active'); + } + this.classList.add('active'); + intro2.innerHTML=''+get.translation(this.link)+''+lib.translate[this.link+'_info']; + var info=get.info(this.link); + if(info.derivation){ + var derivation=info.derivation; + if(typeof derivation=='string'){ + derivation=[derivation]; + } + for(var i=0;i'+lib.translate[derivation[i]+'_info']; + } + } + //trySkillAudio + } + for(var i=0;i.menubutton.large{ width: 85px; @@ -204,10 +205,46 @@ pointer-events: none; opacity: 0.6; } -#window:not(.nopointer) .menubg.charactercard .menubutton:not(.ava), +#window:not(.nopointer) .menubg.charactercard .menubutton:not(.ava):not(.intro), #window:not(.nopointer) .menubg.charactercard>.ava>.avatars>div{ cursor: pointer; } +.menubg.charactercard>.characterskill{ + left: 191px; + padding-left: 9px; + padding-right: 10px; + width: 290px; + top: 125px; + height: 50px; + white-space: nowrap; + overflow-x: scroll; +} +.menubg.charactercard>.characterskill>.menubutton.large{ + height: 20px; + line-height: 20px; + padding: 5px; + margin-top: 10px; + position: relative; + font-size: 20px; + margin-right: 10px; +} +.menubg.charactercard .characterintro{ + left: 200px; + width: 280px; + height: 105px; + padding: 5px; + overflow: scroll; + border-radius: 4px; + box-shadow: rgba(0,0,0,0.2) 0 0 0 1px; +} +.menubg.charactercard .characterintro:not(.intro2){ + top: 10px; + bottom: auto; +} +.menubg.charactercard .characterintro.intro2{ + top: auto; + bottom: 10px; +} .menubg.charactercard>.ava>.avatars{ opacity: 0; pointer-events: none; @@ -255,14 +292,14 @@ pointer-events: none; } .menubg.charactercard>.ava>.avatar{ - left: 3px; - top: 3px; - width: calc(100% - 6px); - height: calc(100% - 6px); - background-position: 50% 0; - border-radius: 4px !important; - z-index: 1; - box-shadow: rgba(0, 0, 0, 0.2) 0 0 0 1px, rgba(0, 0, 0, 0.45) 0 0 5px; + left: 0; + top: 0; + width: calc(100% - 0px); + height: calc(100% - 0px); + background-position: 50% 0; + border-radius: 0px !important; + z-index: 1; + box-shadow: none; } .menu.main>.menu-tab{ height:37px; diff --git a/mode/boss.js b/mode/boss.js index 7fad56402..9a45e2b63 100644 --- a/mode/boss.js +++ b/mode/boss.js @@ -2867,6 +2867,7 @@ mode.boss={ unique:true, enable:'chooseToUse', mark:true, + derivation:['tinqin','boss_huixin'], init:function(player){ player.storage.boss_guihan=false; }, @@ -3039,6 +3040,7 @@ mode.boss={ trigger:{player:'niepanAfter'}, forced:true, unique:true, + derivation:['shenwei','zhuyu'], content:function(){ player.addSkill('kanpo'); player.addSkill('shenwei');