Commit 211a47bc authored by asdf's avatar asdf

背景位置bug

parent 92fde8ad
......@@ -427,7 +427,7 @@
"__id__": 12
}
],
"_active": true,
"_active": false,
"_components": [
{
"__id__": 15
......@@ -446,7 +446,7 @@
},
"_contentSize": {
"__type__": "cc.Size",
"width": 70.18,
"width": 0,
"height": 58
},
"_anchorPoint": {
......@@ -510,7 +510,7 @@
},
"_contentSize": {
"__type__": "cc.Size",
"width": 70.18,
"width": 0,
"height": 63
},
"_anchorPoint": {
......@@ -562,8 +562,8 @@
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "123",
"_N$string": "123",
"_string": "",
"_N$string": "",
"_fontSize": 42,
"_lineHeight": 50,
"_enableWrapText": true,
......@@ -603,7 +603,7 @@
"_enabled": true,
"_layoutSize": {
"__type__": "cc.Size",
"width": 70.18,
"width": 0,
"height": 58
},
"_resize": 1,
......
......@@ -138,11 +138,11 @@ cc.Class({
// 初始化文本
initRichText() {
// this.data.text = 'I am flying';
this.sprBg.node.y = 0;
this.dragonBone.node.y = 0;
if (this.data.text) {
this.sprBg.node.y = 40;
this.dragonBone.node.y = 40;
this.sprBg.node.y = 40;
this.dragonBone.node.y = 40;
if (!this.data.text) {
this.sprBg.node.y = 0;
this.dragonBone.node.y = 0;
return;
}
this.data.text = this.data.text.replace(/ /g, " |");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment