Commit 96f9670f authored by liujiangnan's avatar liujiangnan

feat: 加载课件等

parent 00cbacfd
......@@ -298,16 +298,16 @@
"__id__": 22
},
{
"__id__": 64
"__id__": 84
}
],
"_active": true,
"_components": [
{
"__id__": 99
"__id__": 119
},
{
"__id__": 100
"__id__": 120
}
],
"_prefab": null,
......@@ -460,7 +460,7 @@
"__id__": 7
},
"_children": [],
"_active": true,
"_active": false,
"_components": [
{
"__id__": 11
......@@ -1062,12 +1062,21 @@
},
{
"__id__": 56
},
{
"__id__": 67
},
{
"__id__": 74
},
{
"__id__": 81
}
],
"_active": true,
"_components": [
{
"__id__": 63
"__id__": 83
}
],
"_prefab": null,
......@@ -1156,7 +1165,7 @@
"ctor": "Float64Array",
"array": [
-489,
132,
211.856,
0,
0,
0,
......@@ -1261,7 +1270,7 @@
"ctor": "Float64Array",
"array": [
206,
132,
211.856,
0,
0,
0,
......@@ -1727,7 +1736,7 @@
"ctor": "Float64Array",
"array": [
356,
133,
212.856,
0,
0,
0,
......@@ -2094,7 +2103,7 @@
"ctor": "Float64Array",
"array": [
-489,
-115,
86.761,
0,
0,
0,
......@@ -2199,7 +2208,7 @@
"ctor": "Float64Array",
"array": [
56,
-118,
83.761,
0,
0,
0,
......@@ -2625,7 +2634,7 @@
},
{
"__type__": "cc.Node",
"_name": "BtnStartOnline",
"_name": "courseId",
"_objFlags": 0,
"_parent": {
"__id__": 22
......@@ -2633,12 +2642,18 @@
"_children": [
{
"__id__": 57
},
{
"__id__": 60
},
{
"__id__": 63
}
],
"_active": true,
"_components": [
{
"__id__": 62
"__id__": 66
}
],
"_prefab": null,
......@@ -2652,7 +2667,7 @@
},
"_contentSize": {
"__type__": "cc.Size",
"width": 100,
"width": 160,
"height": 40
},
"_anchorPoint": {
......@@ -2664,8 +2679,8 @@
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
209,
-119,
56,
-33.674,
0,
0,
0,
......@@ -2687,27 +2702,23 @@
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "d1Sy79j41DT7pkuJD6jHpc"
"_id": "f8PQrlI/xFMoQv/V9st+77"
},
{
"__type__": "cc.Node",
"_name": "Background",
"_name": "BACKGROUND_SPRITE",
"_objFlags": 512,
"_parent": {
"__id__": 56
},
"_children": [
{
"__id__": 58
}
],
"_children": [],
"_active": true,
"_components": [
{
"__id__": 60
"__id__": 58
},
{
"__id__": 61
"__id__": 59
}
],
"_prefab": null,
......@@ -2721,7 +2732,7 @@
},
"_contentSize": {
"__type__": "cc.Size",
"width": 100,
"width": 160,
"height": 40
},
"_anchorPoint": {
......@@ -2756,47 +2767,109 @@
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "ddylI7PAJHvq7yMkZVf4jN"
"_id": "05fUW2NbhHX75/oR+ftGPt"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 57
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "ff0e91c7-55c6-4086-a39f-cb6e457b8c3b"
},
"_type": 1,
"_sizeMode": 0,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "8bzWaChlJMPrwJiPvKVfaR"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 57
},
"_enabled": true,
"alignMode": 0,
"_target": null,
"_alignFlags": 45,
"_left": 0,
"_right": 0,
"_top": 0,
"_bottom": 0,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 160,
"_originalHeight": 40,
"_id": "dao+CsABlHNLOeQic9CHLz"
},
{
"__type__": "cc.Node",
"_name": "Label",
"_name": "TEXT_LABEL",
"_objFlags": 512,
"_parent": {
"__id__": 57
"__id__": 56
},
"_children": [],
"_active": true,
"_active": false,
"_components": [
{
"__id__": 59
"__id__": 61
},
{
"__id__": 62
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 0,
"g": 0,
"b": 0,
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 100,
"width": 158,
"height": 40
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
"x": 0,
"y": 1
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
0,
-78,
20,
0,
0,
0,
......@@ -2818,27 +2891,23 @@
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "96VvRoU+ZKKr1+RCGL5OwZ"
"_id": "46ACEkPMtEBZ6w7rpuQBFR"
},
{
"__type__": "cc.Label",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 58
"__id__": 60
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_materials": [],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "开始",
"_N$string": "开始",
"_string": "",
"_N$string": "",
"_fontSize": 20,
"_lineHeight": 40,
"_lineHeight": 25,
"_enableWrapText": false,
"_N$file": null,
"_isSystemFontUsed": true,
......@@ -2846,57 +2915,25 @@
"_batchAsBitmap": false,
"_styleFlags": 0,
"_underlineHeight": 0,
"_N$horizontalAlign": 1,
"_N$horizontalAlign": 0,
"_N$verticalAlign": 1,
"_N$fontFamily": "Arial",
"_N$overflow": 1,
"_N$cacheMode": 1,
"_id": "ffBFJDR9NFl7H5qZQ4xki/"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 57
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952"
},
"_type": 1,
"_sizeMode": 0,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "26jSdeuENJUpWwBz8a8SpJ"
"_N$cacheMode": 0,
"_id": "96/Uy0dr1K8ZGx0tBOGgNd"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 57
"__id__": 60
},
"_enabled": true,
"alignMode": 0,
"_target": null,
"_alignFlags": 45,
"_left": 0,
"_left": 2,
"_right": 0,
"_top": 0,
"_bottom": 0,
......@@ -2908,59 +2945,874 @@
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 100,
"_originalWidth": 158,
"_originalHeight": 40,
"_id": "56xCa0P9RIA6F862cWkc2K"
"_id": "ba8uqiaqdEtahQoa4UNrWH"
},
{
"__type__": "cc.Button",
"_name": "",
"_objFlags": 0,
"node": {
"__type__": "cc.Node",
"_name": "PLACEHOLDER_LABEL",
"_objFlags": 512,
"_parent": {
"__id__": 56
},
"_enabled": true,
"_normalMaterial": null,
"_grayMaterial": null,
"duration": 0.1,
"zoomScale": 1.2,
"clickEvents": [],
"_N$interactable": true,
"_N$enableAutoGrayEffect": false,
"_N$transition": 2,
"transition": 2,
"_N$normalColor": {
"__type__": "cc.Color",
"r": 230,
"g": 230,
"b": 230,
"a": 255
"_children": [],
"_active": true,
"_components": [
{
"__id__": 64
},
"_N$pressedColor": {
{
"__id__": 65
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 200,
"g": 200,
"b": 200,
"r": 187,
"g": 187,
"b": 187,
"a": 255
},
"pressedColor": {
"__type__": "cc.Color",
"r": 200,
"g": 200,
"b": 200,
"a": 255
"_contentSize": {
"__type__": "cc.Size",
"width": 158,
"height": 40
},
"_N$hoverColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0,
"y": 1
},
"hoverColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
-78,
20,
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": "ccEAse40NBO7vxTnHtVDCX"
},
{
"__type__": "cc.Label",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 63
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "Enter text here...",
"_N$string": "Enter text here...",
"_fontSize": 20,
"_lineHeight": 25,
"_enableWrapText": false,
"_N$file": null,
"_isSystemFontUsed": true,
"_spacingX": 0,
"_batchAsBitmap": false,
"_styleFlags": 0,
"_underlineHeight": 0,
"_N$horizontalAlign": 0,
"_N$verticalAlign": 1,
"_N$fontFamily": "Arial",
"_N$overflow": 1,
"_N$cacheMode": 0,
"_id": "d5Wef4TtRJlK+Gj7Pi8ZYI"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 63
},
"_enabled": true,
"alignMode": 0,
"_target": null,
"_alignFlags": 45,
"_left": 2,
"_right": 0,
"_top": 0,
"_bottom": 0,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 158,
"_originalHeight": 40,
"_id": "81Adxi4xtMP5ajECAWx9cw"
},
{
"__type__": "cc.EditBox",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 56
},
"_enabled": true,
"_string": "",
"returnType": 0,
"maxLength": 50,
"_tabIndex": 0,
"editingDidBegan": [],
"textChanged": [],
"editingDidEnded": [],
"editingReturn": [],
"_N$textLabel": {
"__id__": 61
},
"_N$placeholderLabel": {
"__id__": 64
},
"_N$background": {
"__id__": 58
},
"_N$inputFlag": 5,
"_N$inputMode": 6,
"_N$stayOnTop": false,
"_id": "67fnpb71lFSohLJbui/0nw"
},
{
"__type__": "cc.Node",
"_name": "BtnStartOnline",
"_objFlags": 0,
"_parent": {
"__id__": 22
},
"_children": [
{
"__id__": 68
}
],
"_active": true,
"_components": [
{
"__id__": 73
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 100,
"height": 40
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
209,
82.761,
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": "d1Sy79j41DT7pkuJD6jHpc"
},
{
"__type__": "cc.Node",
"_name": "Background",
"_objFlags": 512,
"_parent": {
"__id__": 67
},
"_children": [
{
"__id__": 69
}
],
"_active": true,
"_components": [
{
"__id__": 71
},
{
"__id__": 72
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 100,
"height": 40
},
"_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": "ddylI7PAJHvq7yMkZVf4jN"
},
{
"__type__": "cc.Node",
"_name": "Label",
"_objFlags": 512,
"_parent": {
"__id__": 68
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 70
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 0,
"g": 0,
"b": 0,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 100,
"height": 40
},
"_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": "96VvRoU+ZKKr1+RCGL5OwZ"
},
{
"__type__": "cc.Label",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 69
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "开始",
"_N$string": "开始",
"_fontSize": 20,
"_lineHeight": 40,
"_enableWrapText": false,
"_N$file": null,
"_isSystemFontUsed": true,
"_spacingX": 0,
"_batchAsBitmap": false,
"_styleFlags": 0,
"_underlineHeight": 0,
"_N$horizontalAlign": 1,
"_N$verticalAlign": 1,
"_N$fontFamily": "Arial",
"_N$overflow": 1,
"_N$cacheMode": 1,
"_id": "ffBFJDR9NFl7H5qZQ4xki/"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 68
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952"
},
"_type": 1,
"_sizeMode": 0,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "26jSdeuENJUpWwBz8a8SpJ"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 68
},
"_enabled": true,
"alignMode": 0,
"_target": null,
"_alignFlags": 45,
"_left": 0,
"_right": 0,
"_top": 0,
"_bottom": 0,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 100,
"_originalHeight": 40,
"_id": "56xCa0P9RIA6F862cWkc2K"
},
{
"__type__": "cc.Button",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 67
},
"_enabled": true,
"_normalMaterial": null,
"_grayMaterial": null,
"duration": 0.1,
"zoomScale": 1.2,
"clickEvents": [],
"_N$interactable": true,
"_N$enableAutoGrayEffect": false,
"_N$transition": 2,
"transition": 2,
"_N$normalColor": {
"__type__": "cc.Color",
"r": 230,
"g": 230,
"b": 230,
"a": 255
},
"_N$pressedColor": {
"__type__": "cc.Color",
"r": 200,
"g": 200,
"b": 200,
"a": 255
},
"pressedColor": {
"__type__": "cc.Color",
"r": 200,
"g": 200,
"b": 200,
"a": 255
},
"_N$hoverColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"hoverColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_N$disabledColor": {
"__type__": "cc.Color",
"r": 120,
"g": 120,
"b": 120,
"a": 200
},
"_N$normalSprite": {
"__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952"
},
"_N$pressedSprite": {
"__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a"
},
"pressedSprite": {
"__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a"
},
"_N$hoverSprite": {
"__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952"
},
"hoverSprite": {
"__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952"
},
"_N$disabledSprite": {
"__uuid__": "29158224-f8dd-4661-a796-1ffab537140e"
},
"_N$target": {
"__id__": 68
},
"_id": "a8UkrQqyVHAbAt4qkVPJj8"
},
{
"__type__": "cc.Node",
"_name": "BtnStartCourseWare",
"_objFlags": 0,
"_parent": {
"__id__": 22
},
"_children": [
{
"__id__": 75
}
],
"_active": true,
"_components": [
{
"__id__": 80
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 100,
"height": 40
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
211.315,
-31.768,
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": "a9asdHdhBB9b/xiryrw9+h"
},
{
"__type__": "cc.Node",
"_name": "Background",
"_objFlags": 512,
"_parent": {
"__id__": 74
},
"_children": [
{
"__id__": 76
}
],
"_active": true,
"_components": [
{
"__id__": 78
},
{
"__id__": 79
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 100,
"height": 40
},
"_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": "9b6Vj6boJC8altxco3c5fa"
},
{
"__type__": "cc.Node",
"_name": "Label",
"_objFlags": 512,
"_parent": {
"__id__": 75
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 77
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 0,
"g": 0,
"b": 0,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 100,
"height": 40
},
"_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": "34W1LrOMFMVIAgBEJn+iTZ"
},
{
"__type__": "cc.Label",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 76
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "开始",
"_N$string": "开始",
"_fontSize": 20,
"_lineHeight": 40,
"_enableWrapText": false,
"_N$file": null,
"_isSystemFontUsed": true,
"_spacingX": 0,
"_batchAsBitmap": false,
"_styleFlags": 0,
"_underlineHeight": 0,
"_N$horizontalAlign": 1,
"_N$verticalAlign": 1,
"_N$fontFamily": "Arial",
"_N$overflow": 1,
"_N$cacheMode": 1,
"_id": "55vLr1gSBEj4CTOZbvld2B"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 75
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952"
},
"_type": 1,
"_sizeMode": 0,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "eeFumZSk1Oi566wDnLhzHp"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 75
},
"_enabled": true,
"alignMode": 0,
"_target": null,
"_alignFlags": 45,
"_left": 0,
"_right": 0,
"_top": 0,
"_bottom": 0,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 100,
"_originalHeight": 40,
"_id": "b2w1ue6JVMJ5rk6ePM3wY+"
},
{
"__type__": "cc.Button",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 74
},
"_enabled": true,
"_normalMaterial": null,
"_grayMaterial": null,
"duration": 0.1,
"zoomScale": 1.2,
"clickEvents": [],
"_N$interactable": true,
"_N$enableAutoGrayEffect": false,
"_N$transition": 2,
"transition": 2,
"_N$normalColor": {
"__type__": "cc.Color",
"r": 230,
"g": 230,
"b": 230,
"a": 255
},
"_N$pressedColor": {
"__type__": "cc.Color",
"r": 200,
"g": 200,
"b": 200,
"a": 255
},
"pressedColor": {
"__type__": "cc.Color",
"r": 200,
"g": 200,
"b": 200,
"a": 255
},
"_N$hoverColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"hoverColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
......@@ -2990,9 +3842,104 @@
"__uuid__": "29158224-f8dd-4661-a796-1ffab537140e"
},
"_N$target": {
"__id__": 57
"__id__": 75
},
"_id": "a8UkrQqyVHAbAt4qkVPJj8"
"_id": "88xG4oGSJDxpWGPwL/h6xx"
},
{
"__type__": "cc.Node",
"_name": "New Label",
"_objFlags": 0,
"_parent": {
"__id__": 22
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 82
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 440,
"height": 50.4
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
-491.821,
-33.162,
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": "0c82Ku+IJHG5geRCtjuyT/"
},
{
"__type__": "cc.Label",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 81
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "线上测试:请输入课件ID",
"_N$string": "线上测试:请输入课件ID",
"_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": "90lLVYuItAwohmPV+CWljy"
},
{
"__type__": "cc.Widget",
......@@ -3030,25 +3977,25 @@
},
"_children": [
{
"__id__": 65
"__id__": 85
},
{
"__id__": 71
"__id__": 91
},
{
"__id__": 74
"__id__": 94
},
{
"__id__": 82
"__id__": 102
},
{
"__id__": 90
"__id__": 110
}
],
"_active": true,
"_components": [
{
"__id__": 98
"__id__": 118
}
],
"_prefab": null,
......@@ -3104,20 +4051,20 @@
"_name": "content",
"_objFlags": 0,
"_parent": {
"__id__": 64
"__id__": 84
},
"_children": [
{
"__id__": 66
"__id__": 86
}
],
"_active": false,
"_components": [
{
"__id__": 69
"__id__": 89
},
{
"__id__": 70
"__id__": 90
}
],
"_prefab": null,
......@@ -3173,16 +4120,16 @@
"_name": "label",
"_objFlags": 0,
"_parent": {
"__id__": 65
"__id__": 85
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 67
"__id__": 87
},
{
"__id__": 68
"__id__": 88
}
],
"_prefab": null,
......@@ -3238,7 +4185,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 66
"__id__": 86
},
"_enabled": true,
"_materials": [
......@@ -3271,7 +4218,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 66
"__id__": 86
},
"_enabled": true,
"alignMode": 1,
......@@ -3298,7 +4245,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 65
"__id__": 85
},
"_enabled": true,
"_layoutSize": {
......@@ -3330,7 +4277,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 65
"__id__": 85
},
"_enabled": true,
"alignMode": 2,
......@@ -3357,16 +4304,16 @@
"_name": "bg",
"_objFlags": 0,
"_parent": {
"__id__": 64
"__id__": 84
},
"_children": [],
"_active": false,
"_components": [
{
"__id__": 72
"__id__": 92
},
{
"__id__": 73
"__id__": 93
}
],
"_prefab": null,
......@@ -3422,7 +4369,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 71
"__id__": 91
},
"_enabled": true,
"_materials": [
......@@ -3454,7 +4401,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 71
"__id__": 91
},
"_enabled": true,
"alignMode": 1,
......@@ -3481,26 +4428,26 @@
"_name": "Console",
"_objFlags": 0,
"_parent": {
"__id__": 64
"__id__": 84
},
"_children": [
{
"__id__": 75
"__id__": 95
}
],
"_active": false,
"_components": [
{
"__id__": 78
"__id__": 98
},
{
"__id__": 79
"__id__": 99
},
{
"__id__": 80
"__id__": 100
},
{
"__id__": 81
"__id__": 101
}
],
"_prefab": null,
......@@ -3556,16 +4503,16 @@
"_name": "content",
"_objFlags": 0,
"_parent": {
"__id__": 74
"__id__": 94
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 76
"__id__": 96
},
{
"__id__": 77
"__id__": 97
}
],
"_prefab": null,
......@@ -3621,7 +4568,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 75
"__id__": 95
},
"_enabled": true,
"_layoutSize": {
......@@ -3653,7 +4600,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 75
"__id__": 95
},
"_enabled": true,
"alignMode": 1,
......@@ -3680,7 +4627,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 74
"__id__": 94
},
"_enabled": true,
"alignMode": 2,
......@@ -3707,7 +4654,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 74
"__id__": 94
},
"_enabled": true,
"_materials": [
......@@ -3727,7 +4674,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 74
"__id__": 94
},
"_enabled": true,
"horizontal": false,
......@@ -3739,10 +4686,10 @@
"scrollEvents": [],
"cancelInnerEvents": true,
"_N$content": {
"__id__": 75
"__id__": 95
},
"content": {
"__id__": 75
"__id__": 95
},
"_id": "43wBGhGBpFP7OYyNM+j0Ho"
},
......@@ -3751,7 +4698,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 74
"__id__": 94
},
"_enabled": true,
"_layoutSize": {
......@@ -3783,20 +4730,20 @@
"_name": "BtnClose",
"_objFlags": 0,
"_parent": {
"__id__": 64
"__id__": 84
},
"_children": [
{
"__id__": 83
"__id__": 103
}
],
"_active": false,
"_components": [
{
"__id__": 88
"__id__": 108
},
{
"__id__": 89
"__id__": 109
}
],
"_prefab": null,
......@@ -3852,20 +4799,20 @@
"_name": "Background",
"_objFlags": 512,
"_parent": {
"__id__": 82
"__id__": 102
},
"_children": [
{
"__id__": 84
"__id__": 104
}
],
"_active": true,
"_components": [
{
"__id__": 86
"__id__": 106
},
{
"__id__": 87
"__id__": 107
}
],
"_prefab": null,
......@@ -3921,13 +4868,13 @@
"_name": "Label",
"_objFlags": 512,
"_parent": {
"__id__": 83
"__id__": 103
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 85
"__id__": 105
}
],
"_prefab": null,
......@@ -3983,7 +4930,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 84
"__id__": 104
},
"_enabled": true,
"_materials": [
......@@ -4016,7 +4963,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 83
"__id__": 103
},
"_enabled": true,
"_materials": [
......@@ -4048,7 +4995,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 83
"__id__": 103
},
"_enabled": true,
"alignMode": 0,
......@@ -4075,7 +5022,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 82
"__id__": 102
},
"_enabled": true,
"_normalMaterial": null,
......@@ -4148,7 +5095,7 @@
"__uuid__": "29158224-f8dd-4661-a796-1ffab537140e"
},
"_N$target": {
"__id__": 83
"__id__": 103
},
"_id": "54SC9WcmBAZ6cTznyI0o+3"
},
......@@ -4157,7 +5104,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 82
"__id__": 102
},
"_enabled": true,
"alignMode": 1,
......@@ -4184,20 +5131,20 @@
"_name": "BtnOpen",
"_objFlags": 0,
"_parent": {
"__id__": 64
"__id__": 84
},
"_children": [
{
"__id__": 91
"__id__": 111
}
],
"_active": true,
"_components": [
{
"__id__": 96
"__id__": 116
},
{
"__id__": 97
"__id__": 117
}
],
"_prefab": null,
......@@ -4223,8 +5170,8 @@
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
590,
20,
573.537,
42.637,
0,
0,
0,
......@@ -4253,20 +5200,20 @@
"_name": "Background",
"_objFlags": 512,
"_parent": {
"__id__": 90
"__id__": 110
},
"_children": [
{
"__id__": 92
"__id__": 112
}
],
"_active": true,
"_components": [
{
"__id__": 94
"__id__": 114
},
{
"__id__": 95
"__id__": 115
}
],
"_prefab": null,
......@@ -4322,13 +5269,13 @@
"_name": "Label",
"_objFlags": 512,
"_parent": {
"__id__": 91
"__id__": 111
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 93
"__id__": 113
}
],
"_prefab": null,
......@@ -4384,7 +5331,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 92
"__id__": 112
},
"_enabled": true,
"_materials": [
......@@ -4417,7 +5364,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 91
"__id__": 111
},
"_enabled": true,
"_materials": [
......@@ -4449,7 +5396,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 91
"__id__": 111
},
"_enabled": true,
"alignMode": 0,
......@@ -4476,7 +5423,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 90
"__id__": 110
},
"_enabled": true,
"_normalMaterial": null,
......@@ -4549,7 +5496,7 @@
"__uuid__": "29158224-f8dd-4661-a796-1ffab537140e"
},
"_N$target": {
"__id__": 91
"__id__": 111
},
"_id": "81HoUuRyJOppi+n4Av/u0p"
},
......@@ -4558,16 +5505,16 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 90
"__id__": 110
},
"_enabled": true,
"alignMode": 1,
"_target": null,
"_alignFlags": 36,
"_left": 0,
"_right": 0,
"_right": 16.462999999999965,
"_top": 179,
"_bottom": 0,
"_bottom": 22.637,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
......@@ -4585,7 +5532,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 64
"__id__": 84
},
"_enabled": true,
"alignMode": 1,
......
{
"ver": "1.0.8",
"uuid": "5db4ac00-dc44-44aa-a996-19aefa0955c5",
"isPlugin": false,
"loadPluginInWeb": true,
"loadPluginInNative": true,
"loadPluginInEditor": false,
"subMetas": {}
}
\ No newline at end of file
......@@ -8,32 +8,6 @@ cc.Class({
initAir(this);
},
getData(callBack) {
callBack(null);
return;
const uri = 'courseware/v1/getdata';
const syllabus_id = this.bundleInfoList[this.currentBundleIndex].syllabus_id;
const data = {
courseid: syllabus_id
};
this.callNetworkApiGet(uri, data, callBack);
},
onHomeworkFinish(callBack) {
return;
if (this.role == 'teacher') {
return;
}
const uri = 'app_source/v1/student/homework/finished';
const data = {
syllabus_id: this.syllabus_id,
homework_id: this.homework_id,
token: this.token,
score: 100
};
console.log('data = ' + JSON.stringify(data));
this.callNetworkApiPost(uri, data, callBack);
},
callNetworkApiPost(uri, data, callBack) {
const xhr = new XMLHttpRequest();
const url = `${this.baseUrl}${uri}`;
......@@ -49,12 +23,9 @@ cc.Class({
start() {
this.node.zIndex = 9999;
cc.game.addPersistRootNode(this.node);
this.initListener();
const addressText = cc.find('middleLayer/ui/address');
const str = cc.sys.localStorage.getItem('ip');
console.log('str = ' + str);
......@@ -68,6 +39,12 @@ cc.Class({
nameText.getComponent(cc.EditBox).string = bundleName;
}
const courseIdNode = cc.find('middleLayer/ui/courseId');
const courseId = cc.sys.localStorage.getItem('courseId');
if (courseId) {
courseIdNode.getComponent(cc.EditBox).string = courseId;
}
global.middleLayer = cc.find('middleLayer').getComponent('middleLayer');
middleLayer.log("middleLayer.log('像这样在这里打log')");
......@@ -103,21 +80,32 @@ cc.Class({
},
initListener() {
const exitBtn = this.node.getChildByName('ExitBtn');
const exitBtn = cc.find('middleLayer/ExitBtn');
exitBtn.on('click', () => {
cc.find('middleLayer/BtnRight').active = false;
cc.find('middleLayer/BtnLeft').active = false;
cc.tween(exitBtn)
.to(0.1, { scaleX: 0.9, scaleY: 1.1 })
.to(0.1, { scaleX: 1.1, scaleY: 0.9 })
.to(0.1, { scaleX: 1, scaleY: 1 })
.call(() => {
exitBtn.active = false;
cc.game.removePersistRootNode(this.node);
cc.director.loadScene("middleLayer_for_debug", () => {
exitBtn.active = false;
});
})
.start();
});
cc.find('middleLayer/BtnRight').on('click', ()=>{
this.goNextPage();
});
cc.find('middleLayer/BtnLeft').on('click', ()=>{
this.goPrePage();
});
const BtnStartLocal = cc.find('middleLayer/ui/BtnStartLocal');
BtnStartLocal.on('click', () => {
const addressText = cc.find('middleLayer/ui/address');
......@@ -143,6 +131,17 @@ cc.Class({
exitBtn.active = true;
});
const BtnStartCourseWare = cc.find('middleLayer/ui/BtnStartCourseWare');
BtnStartCourseWare.on('click', () => {
this.showWaitingLetters();
this.hideUI();
const courseIdNode = cc.find('middleLayer/ui/courseId');
const courseId = courseIdNode.getComponent(cc.EditBox).string;
cc.sys.localStorage.setItem('courseId', courseId);
this.loadOnlineCourseWare(courseId);
exitBtn.active = true;
});
const btnClose = cc.find('middleLayer/ConsoleNode/BtnClose');
const btnOpen = cc.find('middleLayer/ConsoleNode/BtnOpen');
const consoleNode = cc.find('middleLayer/ConsoleNode/Console');
......@@ -162,6 +161,30 @@ cc.Class({
});
},
goPrePage() {
this.goTarIndexPage(this.courseIndex - 1);
},
goNextPage() {
this.goTarIndexPage(this.courseIndex + 1);
},
goTarIndexPage(index) {
if(!this.courses || index == this.courseIndex || index < 0 || index > this.courses.length-1){
return;
}
this.courseIndex = index;
this.courseItem = this.courses[this.courseIndex];
if(this.courseIndex==0){
cc.find('middleLayer/BtnLeft').active = false;
}else{
cc.find('middleLayer/BtnLeft').active = true;
}
if(this.courseIndex==this.courses.length-1){
cc.find('middleLayer/BtnRight').active = false;
}else{
cc.find('middleLayer/BtnRight').active = true;
}
this.loadPageBundle();
},
log(str) {
const logStr = `${new Date().toLocaleString()}: ${str}`;
console.log(logStr);
......@@ -173,33 +196,84 @@ cc.Class({
consoleContent.addChild(content);
consoleContent.getComponent(cc.Layout).updateLayout();
},
hideUI() {
cc.find('middleLayer/ui').active = false;
},
loadOnlineBundle(bundleName) {
this.callNetworkApiGet(`http://staging-teach.ireadabc.com`, `/api/template/v1/${bundleName}`, {}, (datastr) => {
const data = JSON.parse(datastr);
const configData = data.data.conf.android;
let configData = null;
if(cc.sys.os == cc.sys.OS_IOS){
configData = data.data.conf.ios;
} else if (cc.sys.os == cc.sys.OS_ANDROID){
configData = data.data.conf.android;
} else {
configData = data.data.conf.web_desktop;
}
const sceneName = configData.sceneName;
const version = configData.version;
const bondleUrl = configData.bondleUrl;
this.loadBundle(sceneName, version, bondleUrl);
});
},
courses: null,
courseIndex: 0,
courseItem: null,
loadOnlineCourseWare(courseId) {
this.callNetworkApiGet(`http://staging-teach.ireadabc.com`, `/api/courseware/v1/${courseId}/list`, {}, (datastr) => {
const data = JSON.parse(datastr);
if(data.rows&&data.rows.length>0){
this.courses = data.rows;
this.courseIndex = 0;
this.courseItem = data.rows[0];
}
if(this.courses && this.courses.length>1){
cc.find('middleLayer/BtnRight').active = true;
}
this.reWriteAir();
this.loadPageBundle();
});
},
loadLocalBundle(address, port) {
this.callNetworkApiGet(`http://${address}:${port}`, '/dist/config.json', {}, (datastr) => {
const data = JSON.parse(datastr);
console.log(JSON.stringify(data));
const sceneName = data.android.sceneName;
const version = data.android.version;
const bondleUrl = `http://${address}:${port}/dist/android/${sceneName}/`;
let sceneName = '';
let version = '';
let bondleUrl = '';
if(cc.sys.os == cc.sys.OS_IOS){
sceneName = data.ios.sceneName;
version = data.ios.version;
bondleUrl = `http://${address}:${port}/dist/ios/${sceneName}/`;
} else if (cc.sys.os == cc.sys.OS_ANDROID){
sceneName = data.android.sceneName;
version = data.android.version;
bondleUrl = `http://${address}:${port}/dist/android/${sceneName}/`;
} else {
sceneName = data.android.sceneName;
version = "";
bondleUrl = `http://${address}:${port}/dist/web_desktop/`;
}
this.loadBundle(sceneName, version, bondleUrl);
});
},
loadPageBundle() {
let sceneName, version, bondleUrl = "";
if(cc.sys.os == cc.sys.OS_IOS){
sceneName = this.courseItem.conf.ios.sceneName;
version = this.courseItem.conf.ios.version;
bondleUrl = this.courseItem.conf.ios.bondleUrl;
} else if (cc.sys.os == cc.sys.OS_ANDROID){
sceneName = this.courseItem.conf.android.sceneName;
version = this.courseItem.conf.android.version;
bondleUrl = this.courseItem.conf.android.bondleUrl;
} else {
sceneName = this.courseItem.conf.web_desktop.sceneName;
version = this.courseItem.conf.web_desktop.version;
bondleUrl = this.courseItem.conf.web_desktop.bondleUrl;
}
this.loadBundle(sceneName, version, bondleUrl);
},
loadBundle(sceneName, version, bondleUrl) {
cc.assetManager.loadBundle(bondleUrl, { version: version }, async (err, bundle) => {
if (err) {
......@@ -215,6 +289,22 @@ cc.Class({
});
},
reWriteAir() {
window.courseware.getData = (callback) => {
let data = null;
if(this.courseItem.data){
data = JSON.parse(this.courseItem.data);
}
callback && callback(data);
}
window.courseware.nextPage = () => {
this.goNextPage();
}
window.courseware.beforePage = () => {
this.goPrePage();
}
},
callNativeFunction(param) {
const paramStr = JSON.stringify(param);
if (cc.sys.isNative && cc.sys.os == cc.sys.OS_IOS) {
......
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