link
This commit is contained in:
parent
dc6fed9de1
commit
316e604776
80
game/game.js
80
game/game.js
|
@ -1200,29 +1200,26 @@
|
|||
ui.arena.dataset.target_shake=bool;
|
||||
}
|
||||
},
|
||||
cursor_style:{
|
||||
name:'指针样式',
|
||||
init:'auto',
|
||||
turned_style:{
|
||||
name:'翻面文字',
|
||||
init:true,
|
||||
unfrequent:true,
|
||||
item:{
|
||||
auto:'自动',
|
||||
pointer:'指针'
|
||||
},
|
||||
onclick:function(item){
|
||||
game.saveConfig('cursor_style',item);
|
||||
if(item=='pointer'){
|
||||
ui.window.classList.add('nopointer');
|
||||
onclick:function(bool){
|
||||
game.saveConfig('turned_style',bool);
|
||||
if(bool){
|
||||
ui.arena.classList.remove('hide_turned');
|
||||
}
|
||||
else{
|
||||
ui.window.classList.remove('nopointer');
|
||||
ui.arena.classList.add('hide_turned');
|
||||
}
|
||||
}
|
||||
},
|
||||
link_style:{
|
||||
link_style2:{
|
||||
name:'横置样式',
|
||||
init:'rotate',
|
||||
init:'chain',
|
||||
unfrequent:true,
|
||||
item:{
|
||||
chain:'铁索',
|
||||
rotate:'横置',
|
||||
mark:'标记'
|
||||
},
|
||||
|
@ -1233,7 +1230,7 @@
|
|||
list.push(game.players[i]);
|
||||
}
|
||||
}
|
||||
game.saveConfig('link_style',style);
|
||||
game.saveConfig('link_style2',style);
|
||||
for(var i=0;i<list.length;i++){
|
||||
if(get.is.linked2(list[i])){
|
||||
list[i].classList.add('linked2');
|
||||
|
@ -1244,6 +1241,12 @@
|
|||
list[i].classList.remove('linked2');
|
||||
}
|
||||
}
|
||||
if(style=='chain'){
|
||||
ui.arena.classList.remove('nolink');
|
||||
}
|
||||
else{
|
||||
ui.arena.classList.add('nolink');
|
||||
}
|
||||
ui.updatem();
|
||||
}
|
||||
},
|
||||
|
@ -1297,6 +1300,24 @@
|
|||
}
|
||||
}
|
||||
},
|
||||
cursor_style:{
|
||||
name:'指针样式',
|
||||
init:'auto',
|
||||
unfrequent:true,
|
||||
item:{
|
||||
auto:'自动',
|
||||
pointer:'指针'
|
||||
},
|
||||
onclick:function(item){
|
||||
game.saveConfig('cursor_style',item);
|
||||
if(item=='pointer'){
|
||||
ui.window.classList.add('nopointer');
|
||||
}
|
||||
else{
|
||||
ui.window.classList.remove('nopointer');
|
||||
}
|
||||
}
|
||||
},
|
||||
name_font:{
|
||||
name:'人名字体',
|
||||
init:'xinwei',
|
||||
|
@ -27400,7 +27421,10 @@
|
|||
if(update.version!=lib.version||dev){
|
||||
var files=null;
|
||||
var version=lib.version;
|
||||
if(Array.isArray(update.files)&&update.update&&!dev){
|
||||
if(Array.isArray(update.dev)&&dev){
|
||||
files=update.dev;
|
||||
}
|
||||
else if(Array.isArray(update.files)&&update.update&&!dev){
|
||||
var version1=version.split('.');
|
||||
var version2=update.update.split('.');
|
||||
for(var i=0;i<version1.length&&i<version2.length;i++){
|
||||
|
@ -29683,6 +29707,12 @@
|
|||
if(lib.config.cursor_style=='pointer'){
|
||||
ui.window.classList.add('nopointer');
|
||||
}
|
||||
if(lib.config.turned_style==false){
|
||||
ui.arena.classList.add('hide_turned');
|
||||
}
|
||||
if(lib.config.link_style2!='chain'){
|
||||
ui.arena.classList.add('nolink');
|
||||
}
|
||||
|
||||
ui.arenalog=ui.create.div('#arenalog',ui.arena);
|
||||
if(lib.config.show_log=='off'){
|
||||
|
@ -30273,11 +30303,16 @@
|
|||
nameol:ui.create.div('.nameol',node),
|
||||
count:ui.create.div('.count',node).hide(),
|
||||
equips:ui.create.div('.equips',node).hide(),
|
||||
turnedover:ui.create.div('.turned','<div>翻<br>面<div>',node),
|
||||
judges:ui.create.div('.judges',node),
|
||||
marks:ui.create.div('.marks',node),
|
||||
chain:ui.create.div('.chain','<div></div>',node),
|
||||
handcards1:ui.create.div('.handcards'),
|
||||
handcards2:ui.create.div('.handcards'),
|
||||
};
|
||||
for(var i=0;i<40;i++){
|
||||
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.skipList=[];
|
||||
|
@ -30374,7 +30409,7 @@
|
|||
}
|
||||
if(!num) num=5;
|
||||
for(var i=0;i<num;i++){
|
||||
var player=ui.create.player(ui.arena).animate('start');
|
||||
var player=ui.create.player().animate('start');
|
||||
game.players.push(player);
|
||||
player.dataset.position=i;
|
||||
}
|
||||
|
@ -30394,6 +30429,9 @@
|
|||
players[players.length-1].next=players[0];
|
||||
players[players.length-1].nextSeat=players[0];
|
||||
ui.arena.setNumber(num);
|
||||
for(var i=0;i<num;i++){
|
||||
ui.arena.appendChild(players[i]);
|
||||
}
|
||||
return players;
|
||||
},
|
||||
me:function(hasme){
|
||||
|
@ -33118,7 +33156,11 @@
|
|||
},
|
||||
updatem:function(player){
|
||||
if(player){
|
||||
ui.updatejm(player,player.node.marks,player.classList.contains('linked2')?0:1,get.is.mobileMe(player));
|
||||
var start=0;
|
||||
if(!player.classList.contains('linked2')||!ui.arena.classList.contains('nolink')){
|
||||
start=1;
|
||||
}
|
||||
ui.updatejm(player,player.node.marks,start,get.is.mobileMe(player));
|
||||
}
|
||||
else{
|
||||
for(var i=0;i<game.players.length;i++){
|
||||
|
@ -33396,7 +33438,7 @@
|
|||
return false;
|
||||
},
|
||||
linked2:function(player){
|
||||
if(lib.config.link_style=='mark') return true;
|
||||
if(lib.config.link_style2!='rotate') return true;
|
||||
if(game.chess) return false;
|
||||
if(game.layout=='long'||game.layout=='long2') return true;
|
||||
if(player.dataset.position=='0'){
|
||||
|
|
|
@ -1274,6 +1274,7 @@ div:not(.handcards)>.card>.info>span,
|
|||
}
|
||||
|
||||
#arena.oldlayout .player:not(.linked2) .marks>div:first-child,
|
||||
#arena.oldlayout:not(.nolink) .player .marks>div:first-child,
|
||||
#arena.oldlayout .player .marks .removing {
|
||||
transform: scale(0.2);
|
||||
opacity: 0;
|
||||
|
@ -1736,7 +1737,80 @@ div:not(.handcards)>.card>.info>span,
|
|||
top: 87px;
|
||||
left: 18px;
|
||||
}
|
||||
|
||||
.player>.turned{
|
||||
font-family: 'xinwei';
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
line-height: 68px;
|
||||
left: 0;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
text-align: center;
|
||||
font-size: 70px;
|
||||
opacity: 0;
|
||||
pointer-events: none;
|
||||
text-shadow: none;
|
||||
background: black;
|
||||
top: 0;
|
||||
border-radius: 8px;
|
||||
color: rgba(255,255,255,0.8);
|
||||
text-shadow: none;
|
||||
}
|
||||
.player>.turned>div{
|
||||
top:calc(50% - 68px);
|
||||
width: 100%;
|
||||
left: 0;
|
||||
}
|
||||
.player>.chain{
|
||||
top: calc(50% - 10px);
|
||||
left: 0;
|
||||
height: 20px;
|
||||
width: 100%;
|
||||
overflow-x: hidden;
|
||||
overflow-y: visible;
|
||||
white-space: nowrap;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
z-index: 3;
|
||||
pointer-events: none;
|
||||
}
|
||||
.player>.chain>div{
|
||||
overflow: visible;
|
||||
left: 0;
|
||||
top: 0;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
.player:not(.linked2)>.chain>div{
|
||||
opacity: 0;
|
||||
transform: translateX(-40px);
|
||||
}
|
||||
#arena.nolink .player>.chain{
|
||||
display: none;
|
||||
}
|
||||
.player>.chain>div>div{
|
||||
position: absolute;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
left: 0;
|
||||
box-shadow: rgba(0, 0, 0, 0.4) 0 0 0 1px,rgba(0, 0, 0, 0.4) 0 0 2px;
|
||||
}
|
||||
.player>.chain>div>div:nth-child(odd){
|
||||
height: 8px;
|
||||
width: 10px;
|
||||
border-radius: 2px;
|
||||
top: 6px;
|
||||
}
|
||||
.player>.chain>div>div:nth-child(even){
|
||||
width: 10px;
|
||||
height: 2px;
|
||||
top: 9px;
|
||||
z-index: 1;
|
||||
border-radius: 2px;
|
||||
}
|
||||
#arena:not(.hide_turned):not(.oldlayout) .player.turnedover>.turned{
|
||||
opacity: 0.2;
|
||||
}
|
||||
.player>.damage,
|
||||
#window>.damage {
|
||||
font-family: 'huangcao','xinwei';
|
||||
|
@ -3497,6 +3571,7 @@ div:hover>.wunature {
|
|||
#window[data-radius_size='reduce'] #mebg,
|
||||
#window[data-radius_size='reduce'] .control,
|
||||
#window[data-radius_size='reduce'] .player,
|
||||
#window[data-radius_size='reduce'] .player>.turned,
|
||||
#window[data-radius_size='reduce'] .player::after,
|
||||
#window[data-radius_size='reduce'] .card,
|
||||
#window[data-radius_size='reduce'] .card::after,
|
||||
|
@ -3516,6 +3591,7 @@ div:hover>.wunature {
|
|||
#window[data-radius_size='off'] #mebg,
|
||||
#window[data-radius_size='off'] .control,
|
||||
#window[data-radius_size='off'] .player,
|
||||
#window[data-radius_size='off'] .player>.turned,
|
||||
#window[data-radius_size='off'] .player::after,
|
||||
#window[data-radius_size='off'] .card,
|
||||
#window[data-radius_size='off'] .card::after,
|
||||
|
@ -3535,6 +3611,7 @@ div:hover>.wunature {
|
|||
#window[data-radius_size='increase'] #mebg,
|
||||
#window[data-radius_size='increase'] .control,
|
||||
#window[data-radius_size='increase'] .player,
|
||||
#window[data-radius_size='increase'] .player>.turned,
|
||||
#window[data-radius_size='increase'] .player::after,
|
||||
#window[data-radius_size='increase'] .card,
|
||||
#window[data-radius_size='increase'] .card::after,
|
||||
|
|
|
@ -135,6 +135,9 @@
|
|||
border-radius: 0 !important;
|
||||
pointer-events: none;
|
||||
}
|
||||
#arena:not(.chess) .player[data-position='0']>.chain{
|
||||
width: 120px
|
||||
}
|
||||
#arena.oblongcard:not(.chess) .player[data-position='0']{
|
||||
height: 140px;
|
||||
}
|
||||
|
|
|
@ -160,7 +160,8 @@
|
|||
top:26px;
|
||||
left:auto;
|
||||
}
|
||||
.player:not(.linked2) .marks>div:first-child{
|
||||
.player:not(.linked2) .marks>div:first-child,
|
||||
#arena:not(.nolink) .player .marks>div:first-child{
|
||||
transform: scale(0.2);
|
||||
opacity:0;
|
||||
pointer-events: none;
|
||||
|
|
|
@ -199,6 +199,10 @@ html{
|
|||
box-shadow:none;
|
||||
}
|
||||
|
||||
.player>.turned{
|
||||
color: rgba(0,0,0,0.8);
|
||||
background: white;
|
||||
}
|
||||
.player .marks>div:first-child>div{
|
||||
-webkit-filter: invert(0.8) sepia(1);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue