|
@ -61,12 +61,17 @@ character.hearth={
|
||||||
hs_bilanyoulong:['male','wei',4,['lingzhou']],
|
hs_bilanyoulong:['male','wei',4,['lingzhou']],
|
||||||
hs_jinglinglong:['male','wu',3,['mianyi']],
|
hs_jinglinglong:['male','wu',3,['mianyi']],
|
||||||
// hs_ruanniguai:['male','wu',3,['nianfu']],
|
// hs_ruanniguai:['male','wu',3,['nianfu']],
|
||||||
hs_hudunren:['male','shu',3,['hhudun']],
|
// hs_hudunren:['male','shu',3,['hhudun']],
|
||||||
hs_nate:['male','wu',4,['chuidiao']],
|
hs_nate:['male','wu',4,['chuidiao']],
|
||||||
hs_jiaziruila:['male','wu',4,['hannu']],
|
hs_jiaziruila:['male','wu',4,['hannu']],
|
||||||
// hs_shifazhe:['male','wei',3,['jizhi','shifa']],
|
// hs_shifazhe:['male','wei',3,['jizhi','shifa']],
|
||||||
hs_lafamu:['male','shu',4,['xieneng']],
|
hs_lafamu:['male','shu',4,['xieneng']],
|
||||||
hs_yelise:['female','wei',3,['xunbao','zhuizong']],
|
hs_yelise:['female','wei',3,['xunbao','zhuizong']],
|
||||||
|
hs_fandral:['male','shu',4,['nuyan']],
|
||||||
|
hs_hallazeal:['male','shu',4,['nuyan']],
|
||||||
|
hs_nzoth:['male','shu',4,['nuyan']],
|
||||||
|
hs_walian:['male','shu',4,['nuyan']],
|
||||||
|
hs_pengpeng:['male','shu',4,['nuyan']],
|
||||||
},
|
},
|
||||||
perfectPair:{
|
perfectPair:{
|
||||||
hs_sthrall:['hs_totemic','hs_alakir','hs_neptulon','hs_yngvar','hs_tgolem'],
|
hs_sthrall:['hs_totemic','hs_alakir','hs_neptulon','hs_yngvar','hs_tgolem'],
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
window.noname_asset_list=[
|
window.noname_asset_list=[
|
||||||
'1.8.10',
|
'1.8.11',
|
||||||
'image/background/huangtian_bg.jpg',
|
'image/background/huangtian_bg.jpg',
|
||||||
'image/background/shengshi_bg.jpg',
|
'image/background/shengshi_bg.jpg',
|
||||||
'image/background/xueji_bg.jpg',
|
'image/background/xueji_bg.jpg',
|
||||||
|
@ -440,10 +440,12 @@ window.noname_asset_list=[
|
||||||
'image/character/hs_brann.jpg',
|
'image/character/hs_brann.jpg',
|
||||||
'image/character/hs_aedwin.jpg',
|
'image/character/hs_aedwin.jpg',
|
||||||
'image/character/hs_finley.jpg',
|
'image/character/hs_finley.jpg',
|
||||||
|
'image/character/hs_fandral.jpg',
|
||||||
'image/character/hs_jaina.jpg',
|
'image/character/hs_jaina.jpg',
|
||||||
'image/character/hs_fuding.jpg',
|
'image/character/hs_fuding.jpg',
|
||||||
'image/character/hs_guldan.jpg',
|
'image/character/hs_guldan.jpg',
|
||||||
'image/character/hs_hudunren.jpg',
|
'image/character/hs_hudunren.jpg',
|
||||||
|
'image/character/hs_hallazeal.jpg',
|
||||||
'image/character/hs_huzhixiannv.jpg',
|
'image/character/hs_huzhixiannv.jpg',
|
||||||
'image/character/hs_jgarrosh.jpg',
|
'image/character/hs_jgarrosh.jpg',
|
||||||
'image/character/hs_jiaziruila.jpg',
|
'image/character/hs_jiaziruila.jpg',
|
||||||
|
@ -465,6 +467,7 @@ window.noname_asset_list=[
|
||||||
'image/character/hs_nate.jpg',
|
'image/character/hs_nate.jpg',
|
||||||
'image/character/hs_neptulon.jpg',
|
'image/character/hs_neptulon.jpg',
|
||||||
'image/character/hs_nozdormu.jpg',
|
'image/character/hs_nozdormu.jpg',
|
||||||
|
'image/character/hs_nzoth.jpg',
|
||||||
'image/character/hs_ronghejuren.jpg',
|
'image/character/hs_ronghejuren.jpg',
|
||||||
'image/character/hs_ruanniguai.jpg',
|
'image/character/hs_ruanniguai.jpg',
|
||||||
'image/character/hs_sainaliusi.jpg',
|
'image/character/hs_sainaliusi.jpg',
|
||||||
|
@ -473,10 +476,12 @@ window.noname_asset_list=[
|
||||||
'image/character/hs_shifazhe.jpg',
|
'image/character/hs_shifazhe.jpg',
|
||||||
'image/character/hs_siwangzhiyi.jpg',
|
'image/character/hs_siwangzhiyi.jpg',
|
||||||
'image/character/hs_sthrall.jpg',
|
'image/character/hs_sthrall.jpg',
|
||||||
|
'image/character/hs_pengpeng.jpg',
|
||||||
'image/character/hs_tgolem.jpg',
|
'image/character/hs_tgolem.jpg',
|
||||||
'image/character/hs_totemic.jpg',
|
'image/character/hs_totemic.jpg',
|
||||||
'image/character/hs_trueheart.jpg',
|
'image/character/hs_trueheart.jpg',
|
||||||
'image/character/hs_waleera.jpg',
|
'image/character/hs_waleera.jpg',
|
||||||
|
'image/character/hs_walian.jpg',
|
||||||
'image/character/hs_wujiyuansu.jpg',
|
'image/character/hs_wujiyuansu.jpg',
|
||||||
'image/character/hs_wuther.jpg',
|
'image/character/hs_wuther.jpg',
|
||||||
'image/character/hs_wvelen.jpg',
|
'image/character/hs_wvelen.jpg',
|
||||||
|
|
|
@ -2774,7 +2774,7 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
story:{
|
story:{
|
||||||
name:'剧情',
|
name:'群侠',
|
||||||
config:{
|
config:{
|
||||||
save:{
|
save:{
|
||||||
name:'选择历程',
|
name:'选择历程',
|
||||||
|
@ -3263,7 +3263,7 @@
|
||||||
lib.config.gameRecord={};
|
lib.config.gameRecord={};
|
||||||
}
|
}
|
||||||
if(lib.config.debug){
|
if(lib.config.debug){
|
||||||
mode.pack.story='剧情';
|
mode.pack.story='群侠';
|
||||||
mode.pack.realtime='即时';
|
mode.pack.realtime='即时';
|
||||||
}
|
}
|
||||||
for(i in mode.pack){
|
for(i in mode.pack){
|
||||||
|
|
|
@ -9,6 +9,7 @@ window.noname_update={
|
||||||
'character/yijiang.js',
|
'character/yijiang.js',
|
||||||
'mode/chess.js',
|
'mode/chess.js',
|
||||||
'game/game.js',
|
'game/game.js',
|
||||||
|
'game/asset.js',
|
||||||
],
|
],
|
||||||
'1.8.15.4':[]
|
'1.8.15.4':[]
|
||||||
}
|
}
|
||||||
|
|
After Width: | Height: | Size: 50 KiB |
After Width: | Height: | Size: 53 KiB |
After Width: | Height: | Size: 46 KiB |
After Width: | Height: | Size: 96 KiB |
After Width: | Height: | Size: 53 KiB |
After Width: | Height: | Size: 13 KiB |
After Width: | Height: | Size: 36 KiB |
After Width: | Height: | Size: 23 KiB |
|
@ -109,6 +109,7 @@
|
||||||
left: 0;
|
left: 0;
|
||||||
top: 0;
|
top: 0;
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
|
overflow: scroll;
|
||||||
}
|
}
|
||||||
.storyscene>.scene>.background>.avatar{
|
.storyscene>.scene>.background>.avatar{
|
||||||
width: calc(100% - 26px);
|
width: calc(100% - 26px);
|
||||||
|
@ -130,6 +131,66 @@
|
||||||
width: 70px;
|
width: 70px;
|
||||||
left: calc(50% - 35px);
|
left: calc(50% - 35px);
|
||||||
}
|
}
|
||||||
|
.scene>.menu>.conversation{
|
||||||
|
display: table;
|
||||||
|
position: absolute;
|
||||||
|
left: 16px;
|
||||||
|
top: 0;
|
||||||
|
width: calc(100% - 32px);
|
||||||
|
height: 100%;
|
||||||
|
font-size: 24px;
|
||||||
|
font-family: 'xinwei';
|
||||||
|
white-space: normal;
|
||||||
|
text-align: left;
|
||||||
|
}
|
||||||
|
.scene>.menu>.conversation.center{
|
||||||
|
text-align: center;
|
||||||
|
font-size: 30px;
|
||||||
|
}
|
||||||
|
.scene>.menu>.avatarconversation{
|
||||||
|
position: relative;
|
||||||
|
display: block;
|
||||||
|
width: 100%;
|
||||||
|
height: 100px;
|
||||||
|
left: 0;
|
||||||
|
margin-top: 10px;
|
||||||
|
}
|
||||||
|
.scene>.menu>.avatarconversation:last-child{
|
||||||
|
margin-bottom: 10px;
|
||||||
|
}
|
||||||
|
.scene>.menu>.avatarconversation>div{
|
||||||
|
height: 100%;
|
||||||
|
top:0;
|
||||||
|
}
|
||||||
|
.scene>.menu>.avatarconversation>.avatar{
|
||||||
|
width: 100px;
|
||||||
|
height: 100px;
|
||||||
|
left: 10px;
|
||||||
|
background-size: cover;
|
||||||
|
}
|
||||||
|
.scene>.menu>.avatarconversation.swap>.avatar{
|
||||||
|
left: auto;
|
||||||
|
right: 10px;
|
||||||
|
}
|
||||||
|
.scene>.menu>.avatarconversation>div:not(.avatar){
|
||||||
|
width: calc(100% - 120px);
|
||||||
|
left: 120px;
|
||||||
|
top: 5px;
|
||||||
|
height: calc(100% - 5px);
|
||||||
|
text-align: left;
|
||||||
|
white-space: normal;
|
||||||
|
line-height: 18px;
|
||||||
|
}
|
||||||
|
.scene>.menu>.avatarconversation.swap>div:not(.avatar){
|
||||||
|
left: auto;
|
||||||
|
right: 120px;
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
.scene>.menu>.conversation>div{
|
||||||
|
display: table-cell;
|
||||||
|
vertical-align: middle;
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
@-webkit-keyframes scene_start{
|
@-webkit-keyframes scene_start{
|
||||||
from{
|
from{
|
||||||
|
|
172
mode/story.js
|
@ -9,6 +9,17 @@ mode.story={
|
||||||
},
|
},
|
||||||
story:{
|
story:{
|
||||||
version:1,
|
version:1,
|
||||||
|
character:{
|
||||||
|
zuoci:{
|
||||||
|
name:'左慈'
|
||||||
|
},
|
||||||
|
yuji:{
|
||||||
|
name:'于吉'
|
||||||
|
},
|
||||||
|
nanhua:{
|
||||||
|
name:'南华'
|
||||||
|
}
|
||||||
|
},
|
||||||
scene:{
|
scene:{
|
||||||
connect:{
|
connect:{
|
||||||
hulaoguan:{
|
hulaoguan:{
|
||||||
|
@ -35,9 +46,45 @@ mode.story={
|
||||||
middle:{
|
middle:{
|
||||||
taoyuanxiang:{
|
taoyuanxiang:{
|
||||||
name:'桃源乡',
|
name:'桃源乡',
|
||||||
|
content:{
|
||||||
|
default:[
|
||||||
|
'东汉末年,桃源乡仙人南华预见了三国时代将会是纷扰的乱世,便施展“九天逆龙大法”扭转时序,打算将曹操、刘备、孙权三位天命王者的出现时间错开',
|
||||||
|
'然而此举却造成上古魔神“刑天”逃脱,并与当世残虐的当权者董卓合而为一,顿时时空陷入前所未有的混乱中',
|
||||||
|
'(洛阳郊外)',
|
||||||
|
['nanhua','完了,完了。。。'],
|
||||||
|
['yuji','倒底发生了什么'],
|
||||||
|
['nanhua','完了,完了。。。'],
|
||||||
|
['nanhua','完了。。。'],
|
||||||
|
['yuji','。。。'],
|
||||||
|
['zuoci','算了,这里魔气太重,我们回去再说'],
|
||||||
|
'(第二天)',
|
||||||
|
['zuoci','快告诉我,外面的世界现在怎样了'],
|
||||||
|
function(){
|
||||||
|
_status.lockScene=false;
|
||||||
|
var node=ui.window.querySelector('.storyscene');
|
||||||
|
game.data.scene.enabled.push('yingxiongting');
|
||||||
|
game.saveData();
|
||||||
|
var scene=node.childNodes[1];
|
||||||
|
scene.namenode.innerHTML='英雄亭';
|
||||||
|
scene.classList.remove('unselectable')
|
||||||
|
ui.click.scene.call(scene);
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
},
|
},
|
||||||
yingxiongting:{
|
yingxiongting:{
|
||||||
name:'英雄亭',
|
name:'英雄亭',
|
||||||
|
content:{
|
||||||
|
default:[
|
||||||
|
'(英雄亭)',
|
||||||
|
function(){
|
||||||
|
console.log(1);
|
||||||
|
_status.lockScene=false;
|
||||||
|
var node=ui.window.querySelector('.storyscene');
|
||||||
|
ui.click.scene2(node.childNodes[1],true);
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
},
|
},
|
||||||
nanyang:{
|
nanyang:{
|
||||||
name:'南阳',
|
name:'南阳',
|
||||||
|
@ -104,12 +151,12 @@ mode.story={
|
||||||
chengdu:{
|
chengdu:{
|
||||||
name:'成都'
|
name:'成都'
|
||||||
},
|
},
|
||||||
wulin:{
|
|
||||||
name:'武陵'
|
|
||||||
},
|
|
||||||
nanman:{
|
nanman:{
|
||||||
name:'南蛮'
|
name:'南蛮'
|
||||||
},
|
},
|
||||||
|
wulin:{
|
||||||
|
name:'武陵'
|
||||||
|
},
|
||||||
shanyue:{
|
shanyue:{
|
||||||
name:'山越'
|
name:'山越'
|
||||||
},
|
},
|
||||||
|
@ -411,7 +458,8 @@ mode.story={
|
||||||
scene:{
|
scene:{
|
||||||
area:'middle',
|
area:'middle',
|
||||||
enabled:['taoyuanxiang'],
|
enabled:['taoyuanxiang'],
|
||||||
new:['taoyuanxiang']
|
new:['taoyuanxiang'],
|
||||||
|
content:{}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
game.data=lib.storage[save];
|
game.data=lib.storage[save];
|
||||||
|
@ -427,6 +475,7 @@ mode.story={
|
||||||
for(var i in lib.story.scene){
|
for(var i in lib.story.scene){
|
||||||
if(i!='connect'){
|
if(i!='connect'){
|
||||||
scenes[i]=ui.create.div('.storyscene');
|
scenes[i]=ui.create.div('.storyscene');
|
||||||
|
scenes[i].area=i;
|
||||||
if(!lib.config.touchscreen&&lib.config.mousewheel){
|
if(!lib.config.touchscreen&&lib.config.mousewheel){
|
||||||
scenes[i]._scrollspeed=30;
|
scenes[i]._scrollspeed=30;
|
||||||
scenes[i]._scrollnum=10;
|
scenes[i]._scrollnum=10;
|
||||||
|
@ -437,10 +486,11 @@ mode.story={
|
||||||
}
|
}
|
||||||
ui.window.appendChild(scenes[game.data.scene.area].animate('start'));
|
ui.window.appendChild(scenes[game.data.scene.area].animate('start'));
|
||||||
var clickScene=function(e){
|
var clickScene=function(e){
|
||||||
|
if(_status.lockScene) return;
|
||||||
if(this.classList.contains('unselectable')) return;
|
if(this.classList.contains('unselectable')) return;
|
||||||
if(this._clicking) return;
|
if(this._clicking) return;
|
||||||
|
if(e&&e.stopPropagation) e.stopPropagation();
|
||||||
if(this.classList.contains('flipped')){
|
if(this.classList.contains('flipped')){
|
||||||
e.stopPropagation();
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
game.data.scene.new.remove(this.name);
|
game.data.scene.new.remove(this.name);
|
||||||
|
@ -451,8 +501,18 @@ mode.story={
|
||||||
if(current){
|
if(current){
|
||||||
restoreScene(current,true);
|
restoreScene(current,true);
|
||||||
}
|
}
|
||||||
|
this.content.innerHTML='';
|
||||||
|
if(this.info.to){
|
||||||
|
ui.create.div('.menubutton.large.enter','进入',this.content,switchScene);
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
var content=this.info.content[game.data.scene.content[this.name]||'default'];
|
||||||
|
if(Array.isArray(content)){
|
||||||
|
_status.lockScene=true;
|
||||||
|
game.loadConversation(this.content,content);
|
||||||
|
}
|
||||||
|
}
|
||||||
sceneNode.classList.add('lockscroll');
|
sceneNode.classList.add('lockscroll');
|
||||||
_status.clicked=true;
|
|
||||||
var node=this;
|
var node=this;
|
||||||
node._clicking=true;
|
node._clicking=true;
|
||||||
setTimeout(function(){
|
setTimeout(function(){
|
||||||
|
@ -462,13 +522,6 @@ mode.story={
|
||||||
if(Math.abs(sceneNode.dx)<20){
|
if(Math.abs(sceneNode.dx)<20){
|
||||||
sceneNode.dx=0;
|
sceneNode.dx=0;
|
||||||
}
|
}
|
||||||
// else{
|
|
||||||
// console.log(sceneNode.scrollLeft,sceneNode.dx);
|
|
||||||
// if(sceneNode.scrollLeft<20&&sceneNode.dx<0){
|
|
||||||
// console.log(1);
|
|
||||||
// sceneNode.dx=0;
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
if(!sceneNode.interval&&sceneNode.dx){
|
if(!sceneNode.interval&&sceneNode.dx){
|
||||||
sceneNode.interval=setInterval(function(){
|
sceneNode.interval=setInterval(function(){
|
||||||
var dx=sceneNode.dx;
|
var dx=sceneNode.dx;
|
||||||
|
@ -495,6 +548,7 @@ mode.story={
|
||||||
};
|
};
|
||||||
node.addEventListener('webkitTransitionEnd',onEnd);
|
node.addEventListener('webkitTransitionEnd',onEnd);
|
||||||
}
|
}
|
||||||
|
ui.click.scene=clickScene;
|
||||||
var restoreScene=function(node,forced){
|
var restoreScene=function(node,forced){
|
||||||
if(_status.lockScene) return;
|
if(_status.lockScene) return;
|
||||||
if(node._clicking&&!forced) return;
|
if(node._clicking&&!forced) return;
|
||||||
|
@ -520,9 +574,16 @@ mode.story={
|
||||||
};
|
};
|
||||||
node.addEventListener('webkitTransitionEnd',onEnd);
|
node.addEventListener('webkitTransitionEnd',onEnd);
|
||||||
}
|
}
|
||||||
|
ui.click.scene2=restoreScene;
|
||||||
var switchScene=function(){
|
var switchScene=function(){
|
||||||
var to=this.parentNode.to;
|
|
||||||
var current=this.parentNode.parentNode;
|
var current=this.parentNode.parentNode;
|
||||||
|
var to=current.info.to;
|
||||||
|
if(to[0]==current.parentNode.area){
|
||||||
|
to=to[1];
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
to=to[0];
|
||||||
|
}
|
||||||
restoreScene(current,true);
|
restoreScene(current,true);
|
||||||
current.parentNode.delete();
|
current.parentNode.delete();
|
||||||
ui.window.appendChild(scenes[to].animate('start'));
|
ui.window.appendChild(scenes[to].animate('start'));
|
||||||
|
@ -539,9 +600,9 @@ mode.story={
|
||||||
node.style.transform='perspective(1600px) rotateY(0deg) scale(0.7)';
|
node.style.transform='perspective(1600px) rotateY(0deg) scale(0.7)';
|
||||||
node.name=name;
|
node.name=name;
|
||||||
node.bgnode=ui.create.div('.background.player',node);
|
node.bgnode=ui.create.div('.background.player',node);
|
||||||
|
node.info=scene;
|
||||||
ui.create.div('.avatar',node.bgnode).setBackground('mode/story/scene/'+name);
|
ui.create.div('.avatar',node.bgnode).setBackground('mode/story/scene/'+name);
|
||||||
node.namenode=ui.create.div('.name',node,get.verticalStr(scene.name));
|
node.namenode=ui.create.div('.name',node,get.verticalStr(scene.name));
|
||||||
// ui.create.div('',get.verticalStr('未开启'),ui.create.div('.mask',node));
|
|
||||||
if(game.data.scene.enabled.contains(name)){
|
if(game.data.scene.enabled.contains(name)){
|
||||||
if(game.data.scene.new.contains(name)){
|
if(game.data.scene.new.contains(name)){
|
||||||
node.classList.add('glow3');
|
node.classList.add('glow3');
|
||||||
|
@ -553,24 +614,22 @@ mode.story={
|
||||||
node.namenode.innerHTML=get.verticalStr('未开启');
|
node.namenode.innerHTML=get.verticalStr('未开启');
|
||||||
}
|
}
|
||||||
var content=ui.create.div('.menu',node);
|
var content=ui.create.div('.menu',node);
|
||||||
|
lib.setScroll(content);
|
||||||
node.content=content;
|
node.content=content;
|
||||||
if(connect){
|
|
||||||
content.to=scene.to;
|
|
||||||
if(content.to[0]==position){
|
|
||||||
content.to=content.to[1];
|
|
||||||
}
|
|
||||||
else{
|
|
||||||
content.to=content.to[0];
|
|
||||||
}
|
|
||||||
ui.create.div('.menubutton.large.enter','进入',node.content,switchScene);
|
|
||||||
}
|
|
||||||
scenes[position].appendChild(node);
|
scenes[position].appendChild(node);
|
||||||
return node;
|
return node;
|
||||||
}
|
}
|
||||||
event.custom.add.window=function(){
|
event.custom.add.window=function(){
|
||||||
var current=document.querySelector('.flipped.scene');
|
if(_status.lockScene){
|
||||||
if(current){
|
if(typeof _status.lockScene=='function'){
|
||||||
restoreScene(current);
|
_status.lockScene();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
var current=document.querySelector('.flipped.scene');
|
||||||
|
if(current){
|
||||||
|
restoreScene(current);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
for(var i in lib.story.scene){
|
for(var i in lib.story.scene){
|
||||||
|
@ -586,6 +645,63 @@ mode.story={
|
||||||
}
|
}
|
||||||
game.pause();
|
game.pause();
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
loadConversation:function(node,content,onfinish){
|
||||||
|
content=content.slice(0);
|
||||||
|
var write=function(){
|
||||||
|
if(content.length){
|
||||||
|
var item=content.shift();
|
||||||
|
var node2;
|
||||||
|
if(typeof item=='function'){
|
||||||
|
item(node);
|
||||||
|
}
|
||||||
|
else if(typeof item=='string'){
|
||||||
|
node.innerHTML='';
|
||||||
|
node2=ui.create.div(node,'.conversation');
|
||||||
|
if(item.length<=10){
|
||||||
|
node2.classList.add('center');
|
||||||
|
}
|
||||||
|
ui.create.div('',item,node2);
|
||||||
|
}
|
||||||
|
else if(Array.isArray(item)){
|
||||||
|
if(!node.firstChild||!node.firstChild.classList||!node.firstChild.classList.contains('avatarconversation')){
|
||||||
|
node.innerHTML='';
|
||||||
|
}
|
||||||
|
node2=ui.create.div(node,'.avatarconversation');
|
||||||
|
node2.name=item[0];
|
||||||
|
var first=true;
|
||||||
|
for(var i=0;i<node.childElementCount-1;i++){
|
||||||
|
if(node.childNodes[i].name==node2.name){
|
||||||
|
first=false;
|
||||||
|
if(node.childNodes[i].classList.contains('swap')){
|
||||||
|
node2.classList.add('swap');
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if(first){
|
||||||
|
if(node2.previousSibling&&!node2.previousSibling.classList.contains('swap')){
|
||||||
|
node2.classList.add('swap');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
ui.create.div('.avatar',node2).style.backgroundImage='url("image/mode/story/character/'+item[0]+'.jpg")';
|
||||||
|
ui.create.div('',item[1],node2);
|
||||||
|
if(node.scrollHeight>node.offsetHeight){
|
||||||
|
node.scrollTop=node.scrollHeight-node.offsetHeight;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
write();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
if(typeof onfinish=='function'){
|
||||||
|
onfinish();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
write();
|
||||||
|
_status.lockScene=write;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
element:{
|
element:{
|
||||||
|
|