Commit 0401fc9e authored by 章红平's avatar 章红平

提交

parent c487e0ff
......@@ -82,18 +82,21 @@
},
{
"__id__": 122
},
{
"__id__": 124
}
],
"_active": true,
"_components": [
{
"__id__": 124
"__id__": 126
},
{
"__id__": 125
"__id__": 127
},
{
"__id__": 126
"__id__": 128
}
],
"_prefab": null,
......@@ -5338,6 +5341,101 @@
"_atlas": null,
"_id": "97/iB2961M1JrrQqo97iIL"
},
{
"__type__": "cc.Node",
"_name": "middleLayer",
"_objFlags": 0,
"_parent": {
"__id__": 2
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 125
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 97.87,
"height": 50.4
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
0,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "a59n4Am5NDHbPEPSmZgspE"
},
{
"__type__": "cc.Label",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 124
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "Label",
"_N$string": "Label",
"_fontSize": 40,
"_lineHeight": 40,
"_enableWrapText": true,
"_N$file": null,
"_isSystemFontUsed": true,
"_spacingX": 0,
"_batchAsBitmap": false,
"_styleFlags": 0,
"_underlineHeight": 0,
"_N$horizontalAlign": 1,
"_N$verticalAlign": 1,
"_N$fontFamily": "Arial",
"_N$overflow": 0,
"_N$cacheMode": 0,
"_id": "acmavZ9yVIJp8DPDqxu3JE"
},
{
"__type__": "cc.Canvas",
"_name": "",
......
......@@ -60,6 +60,7 @@ export class MyCocosSceneComponent extends cc.Component {
this.preloadItem();
})
} else {
this.log('data:' + "======");
this.data = this.getDefaultData();
this.preloadItem();
}
......@@ -106,9 +107,9 @@ export class MyCocosSceneComponent extends cc.Component {
}
log(str) {
const node = cc.find('middleLayer');
const node = cc.find('Canvas/middleLayer');
if (node) {
node.getComponent('middleLayer').log(str);
node.getComponent(cc.Label).string=str;
} else {
console.log(str);
}
......
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