control
This commit is contained in:
parent
b991e6707c
commit
22dcf80004
|
@ -89,7 +89,7 @@ game.import('play',function(){
|
|||
boss_shihuosuanni:['male','wei',3,['boss_jiguan','boss_lianyujg'],['jiangemech','hiddenboss','bossallowed'],'wei'],
|
||||
boss_lieshiyazi:['male','wei',4,['boss_jiguan','boss_nailuo'],['jiangemech','hiddenboss','bossallowed'],'wei'],
|
||||
}
|
||||
if(get.mode()!='versus'){
|
||||
if(get.mode()!='versus'||get.config('versus_mode')!='jiange'){
|
||||
lib.characterPack.mode_extension_jiange=list2;
|
||||
for(var i in list2){
|
||||
lib.characterPack.mode_extension_jiange[i]=list2[i];
|
||||
|
|
30
game/game.js
30
game/game.js
|
@ -18461,6 +18461,9 @@
|
|||
ui.refresh(this);
|
||||
this.style.transition='';
|
||||
}
|
||||
else{
|
||||
this.animate('controlpressdownx',500);
|
||||
}
|
||||
ui.updatec();
|
||||
return this;
|
||||
},
|
||||
|
@ -18472,6 +18475,8 @@
|
|||
node.addEventListener(lib.config.touchscreen?'touchend':'click',ui.click.control);
|
||||
},
|
||||
close:function(){
|
||||
this.animate('controlpressdownx',500);
|
||||
|
||||
ui.controls.remove(this);
|
||||
this.delete();
|
||||
|
||||
|
@ -18484,6 +18489,8 @@
|
|||
if(ui.skills3==this) delete ui.skills3;
|
||||
},
|
||||
replace:function(){
|
||||
// this.animate('controlpressdownx',500);
|
||||
|
||||
while(this.childNodes.length) this.firstChild.remove();
|
||||
var i,controls;
|
||||
if(get.objtype(arguments[0])=='array') controls=arguments[0];
|
||||
|
@ -34314,6 +34321,7 @@
|
|||
if(control.childNodes.length){
|
||||
// if(nozoom||true){
|
||||
control.style.transition='opacity 0.5s';
|
||||
control.animate('controlpressdownx',500);
|
||||
// }
|
||||
// else{
|
||||
// control.style.transition='';
|
||||
|
@ -34334,14 +34342,12 @@
|
|||
control.addEventListener(lib.config.touchscreen?'touchstart':'mousedown',function(){
|
||||
if(this.classList.contains('disabled')) return;
|
||||
this.classList.add('controlpressdown');
|
||||
this.classList.add('controlpressdownx');
|
||||
if(typeof this._offset=='number'){
|
||||
this.style.transform='translateX('+this._offset+'px) scale(0.97)';
|
||||
}
|
||||
});
|
||||
control.addEventListener(lib.config.touchscreen?'touchend':'mouseup',function(){
|
||||
this.classList.remove('controlpressdown');
|
||||
this.classList.remove('controlpressdownx');
|
||||
if(typeof this._offset=='number'){
|
||||
this.style.transform='translateX('+this._offset+'px)';
|
||||
}
|
||||
|
@ -38471,6 +38477,7 @@
|
|||
fullwidth+=154;
|
||||
}
|
||||
if(game.layout!='default'&&game.layout!='newlayout'&&ui.arena.offsetWidth/2>=fullwidth){
|
||||
var current_offset=stayleft._offset;
|
||||
if(fullright){
|
||||
stayleft._offset=Math.ceil(-ui.arena.offsetWidth/2)+135;
|
||||
if(game.layout=='long2'&&ui.arena.dataset.number=='8'&&get.mode()!='boss'){
|
||||
|
@ -38480,7 +38487,10 @@
|
|||
else{
|
||||
stayleft._offset=Math.ceil(-ui.arena.offsetWidth/2)+165;
|
||||
}
|
||||
stayleft.style.transform='translateX('+stayleft._offset+'px)';
|
||||
if(current_offset!=stayleft._offset){
|
||||
stayleft.animate('controlpressdownx',500);
|
||||
stayleft.style.transform='translateX('+stayleft._offset+'px)';
|
||||
}
|
||||
}
|
||||
else{
|
||||
add(stayleft,true);
|
||||
|
@ -38489,8 +38499,11 @@
|
|||
if(!controls.length) return;
|
||||
var offset=-length/2;
|
||||
var control=controls.shift();
|
||||
control.style.transform='translateX('+offset+'px)';
|
||||
control._offset=offset;
|
||||
if(control._offset!=offset){
|
||||
control.animate('controlpressdownx',500);
|
||||
control.style.transform='translateX('+offset+'px)';
|
||||
control._offset=offset;
|
||||
}
|
||||
while(controls.length){
|
||||
var control=controls.shift();
|
||||
var width=widths.shift();
|
||||
|
@ -38498,8 +38511,11 @@
|
|||
if(get.is.phoneLayout()){
|
||||
offset+=6;
|
||||
}
|
||||
control.style.transform='translateX('+offset+'px)';
|
||||
control._offset=offset;
|
||||
if(control._offset!=offset){
|
||||
control.animate('controlpressdownx',500);
|
||||
control.style.transform='translateX('+offset+'px)';
|
||||
control._offset=offset;
|
||||
}
|
||||
}
|
||||
},
|
||||
updatex:function(){
|
||||
|
|
|
@ -1070,9 +1070,12 @@ input.fileinput::-webkit-file-upload-button {
|
|||
#system>div>.pressdown{
|
||||
transform: scale(0.97);
|
||||
}
|
||||
.controlpressdownx{
|
||||
.control:not(.disabled) {
|
||||
transition: all 0.1s;
|
||||
}
|
||||
.control:not(.disabled).controlpressdownx {
|
||||
transition: all 0.5s;
|
||||
}
|
||||
#system>div>.pressdown2{
|
||||
background-image: linear-gradient(rgba(47,101,150,1), rgba(43, 90, 132,1));
|
||||
}
|
||||
|
|
|
@ -2425,6 +2425,7 @@ game.import('mode',function(){
|
|||
}
|
||||
},get.config('onlyguozhanexpand')?'expandall':undefined,get.config('onlyguozhan')?'onlypack:mode_guozhan':undefined);
|
||||
if(ui.cheat2){
|
||||
ui.cheat2.animate('controlpressdownx',500);
|
||||
ui.cheat2.classList.remove('disabled');
|
||||
}
|
||||
};
|
||||
|
@ -2447,7 +2448,8 @@ game.import('mode',function(){
|
|||
game.uncheck();
|
||||
game.check();
|
||||
if(ui.cheat){
|
||||
ui.cheat.classList.add('disabled');
|
||||
ui.cheat.animate('controlpressdownx',500);
|
||||
ui.cheat.classList.remove('disabled');
|
||||
}
|
||||
}
|
||||
else{
|
||||
|
@ -2462,7 +2464,7 @@ game.import('mode',function(){
|
|||
game.uncheck();
|
||||
game.check();
|
||||
if(ui.cheat){
|
||||
ui.cheat.classList.remove('disabled');
|
||||
ui.cheat.classList.add('disabled');
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
|
@ -1024,6 +1024,7 @@ game.import('mode',function(){
|
|||
lib.onfree.push(function(){
|
||||
event.dialogxx=ui.create.characterDialog();
|
||||
if(ui.cheat2){
|
||||
ui.cheat2.animate('controlpressdownx',500);
|
||||
ui.cheat2.classList.remove('disabled');
|
||||
}
|
||||
});
|
||||
|
@ -1045,6 +1046,7 @@ game.import('mode',function(){
|
|||
game.uncheck();
|
||||
game.check();
|
||||
if(ui.cheat){
|
||||
ui.cheat.animate('controlpressdownx',500);
|
||||
ui.cheat.classList.remove('disabled');
|
||||
}
|
||||
}
|
||||
|
|
|
@ -597,6 +597,7 @@ game.import('mode',function(){
|
|||
if(lib.character[name][1]!=game.me.identity) return true;
|
||||
});
|
||||
if(ui.cheat2){
|
||||
ui.cheat2.animate('controlpressdownx',500);
|
||||
ui.cheat2.classList.remove('disabled');
|
||||
}
|
||||
};
|
||||
|
@ -619,6 +620,7 @@ game.import('mode',function(){
|
|||
game.uncheck();
|
||||
game.check();
|
||||
if(ui.cheat){
|
||||
ui.cheat.animate('controlpressdownx',500);
|
||||
ui.cheat.classList.remove('disabled');
|
||||
}
|
||||
}
|
||||
|
@ -871,6 +873,7 @@ game.import('mode',function(){
|
|||
lib.onfree.push(function(){
|
||||
event.dialogxx=ui.create.characterDialog();
|
||||
if(ui.cheat2){
|
||||
ui.cheat2.animate('controlpressdownx',500);
|
||||
ui.cheat2.classList.remove('disabled');
|
||||
}
|
||||
});
|
||||
|
@ -891,7 +894,8 @@ game.import('mode',function(){
|
|||
game.uncheck();
|
||||
game.check();
|
||||
if(ui.cheat){
|
||||
ui.cheat.classList.remove('hidden');
|
||||
ui.cheat.animate('controlpressdownx',500);
|
||||
ui.cheat.classList.remove('disabled');
|
||||
}
|
||||
}
|
||||
else{
|
||||
|
@ -906,7 +910,7 @@ game.import('mode',function(){
|
|||
game.uncheck();
|
||||
game.check();
|
||||
if(ui.cheat){
|
||||
ui.cheat.classList.add('hidden');
|
||||
ui.cheat.classList.add('disabled');
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue