Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
DG_FAF
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
template admin
DG_FAF
Commits
d1a0b3fe
Commit
d1a0b3fe
authored
Feb 19, 2023
by
李维
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
文字热区 文字输入 音频播放 热区选项添加完成
parent
9678c8be
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
652 additions
and
91 deletions
+652
-91
SelectModal_DG_FAF.ts
assets/DG_FAF/prefabs/SelectModal/SelectModal_DG_FAF.ts
+1
-0
keyboard_DG_FAF.ts
assets/DG_FAF/prefabs/keyboard/keyboard_DG_FAF.ts
+6
-6
DG_FAF.fire
assets/DG_FAF/scene/DG_FAF.fire
+261
-8
DG_FAF.ts
assets/DG_FAF/scene/DG_FAF.ts
+240
-66
defaultData_DG_FAF.ts
assets/DG_FAF/script/defaultData_DG_FAF.ts
+144
-11
No files found.
assets/DG_FAF/prefabs/SelectModal/SelectModal_DG_FAF.ts
View file @
d1a0b3fe
...
@@ -58,6 +58,7 @@ export default class NewClass extends cc.Component {
...
@@ -58,6 +58,7 @@ export default class NewClass extends cc.Component {
initEventListener
()
{
initEventListener
()
{
const
closeBtn
=
cc
.
find
(
"
center/header/close
"
,
this
.
node
);
const
closeBtn
=
cc
.
find
(
"
center/header/close
"
,
this
.
node
);
closeBtn
.
on
(
"
click
"
,
()
=>
{
closeBtn
.
on
(
"
click
"
,
()
=>
{
this
.
node
.
emit
(
"
onCancel
"
);
this
.
hide
();
this
.
hide
();
})
})
...
...
assets/DG_FAF/prefabs/keyboard/keyboard_DG_FAF.ts
View file @
d1a0b3fe
...
@@ -58,7 +58,7 @@ export default class NewClass extends cc.Component {
...
@@ -58,7 +58,7 @@ export default class NewClass extends cc.Component {
mainContainer
.
scale
=
s2
;
mainContainer
.
scale
=
s2
;
}
}
show
()
{
show
(
defaultText
=
""
)
{
if
(
this
.
isShow
)
{
if
(
this
.
isShow
)
{
// 如果正在显示 不处理
// 如果正在显示 不处理
return
;
return
;
...
@@ -70,9 +70,9 @@ export default class NewClass extends cc.Component {
...
@@ -70,9 +70,9 @@ export default class NewClass extends cc.Component {
this
.
node
.
y
=
this
.
node
.
y
=
-
canvas
.
height
/
2
-
this
.
node
.
height
/
2
;
this
.
node
.
y
=
this
.
node
.
y
=
-
canvas
.
height
/
2
-
this
.
node
.
height
/
2
;
// 显示组件
// 显示组件
this
.
node
.
active
=
true
;
this
.
node
.
active
=
true
;
//
清空输入字符串变量
//
显示默认传进来的字符串
this
.
text
=
""
;
this
.
text
=
defaultText
;
//
清空当前显示
//
显示默认传进来的字符串
this
.
inputText
(
""
);
this
.
inputText
(
""
);
// 显示标记位置为true
// 显示标记位置为true
this
.
isShow
=
true
;
this
.
isShow
=
true
;
...
@@ -130,8 +130,8 @@ export default class NewClass extends cc.Component {
...
@@ -130,8 +130,8 @@ export default class NewClass extends cc.Component {
})
})
// 订阅节点事件监听 - 外部调用键盘时会发送事件消息
// 订阅节点事件监听 - 外部调用键盘时会发送事件消息
this
.
node
.
on
(
"
show
"
,
()
=>
{
this
.
node
.
on
(
"
show
"
,
(
defaultText
)
=>
{
this
.
show
();
this
.
show
(
defaultText
);
})
})
}
}
...
...
assets/DG_FAF/scene/DG_FAF.fire
View file @
d1a0b3fe
...
@@ -88,18 +88,21 @@
...
@@ -88,18 +88,21 @@
},
},
{
{
"__id__": 206
"__id__": 206
},
{
"__id__": 218
}
}
],
],
"_active": true,
"_active": true,
"_components": [
"_components": [
{
{
"__id__": 2
16
"__id__": 2
21
},
},
{
{
"__id__": 2
17
"__id__": 2
22
},
},
{
{
"__id__": 2
18
"__id__": 2
23
}
}
],
],
"_prefab": null,
"_prefab": null,
...
@@ -7823,7 +7826,7 @@
...
@@ -7823,7 +7826,7 @@
"__id__": 210
"__id__": 210
},
},
{
{
"__id__": 21
3
"__id__": 21
5
}
}
],
],
"_active": false,
"_active": false,
...
@@ -8041,6 +8044,9 @@
...
@@ -8041,6 +8044,9 @@
"_children": [
"_children": [
{
{
"__id__": 211
"__id__": 211
},
{
"__id__": 213
}
}
],
],
"_active": true,
"_active": true,
...
@@ -8183,6 +8189,96 @@
...
@@ -8183,6 +8189,96 @@
"_atlas": null,
"_atlas": null,
"_id": "7dNKhuld5Lo78FZfSVa0u2"
"_id": "7dNKhuld5Lo78FZfSVa0u2"
},
},
{
"__type__": "cc.Node",
"_name": "icon_play_audio",
"_objFlags": 0,
"_parent": {
"__id__": 210
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 214
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 61,
"height": 65
},
"_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": "b8au8Qh/lAH5Yg55Tf3Ycl"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 213
},
"_enabled": true,
"_materials": [],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "a7b53583-16db-42a1-b923-b73852383a5e"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "82K3w/4rtE1KU4M0GNfg7P"
},
{
{
"__type__": "cc.Node",
"__type__": "cc.Node",
"_name": "audio",
"_name": "audio",
...
@@ -8192,7 +8288,7 @@
...
@@ -8192,7 +8288,7 @@
},
},
"_children": [
"_children": [
{
{
"__id__": 21
4
"__id__": 21
6
}
}
],
],
"_active": true,
"_active": true,
...
@@ -8250,13 +8346,13 @@
...
@@ -8250,13 +8346,13 @@
"_name": "btn",
"_name": "btn",
"_objFlags": 0,
"_objFlags": 0,
"_parent": {
"_parent": {
"__id__": 21
3
"__id__": 21
5
},
},
"_children": [],
"_children": [],
"_active": true,
"_active": true,
"_components": [
"_components": [
{
{
"__id__": 21
5
"__id__": 21
7
}
}
],
],
"_prefab": null,
"_prefab": null,
...
@@ -8312,7 +8408,7 @@
...
@@ -8312,7 +8408,7 @@
"_name": "",
"_name": "",
"_objFlags": 0,
"_objFlags": 0,
"node": {
"node": {
"__id__": 21
4
"__id__": 21
6
},
},
"_enabled": true,
"_enabled": true,
"_clip": {
"_clip": {
...
@@ -8326,6 +8422,163 @@
...
@@ -8326,6 +8422,163 @@
"preload": false,
"preload": false,
"_id": "dey05oKrBIspvsDa6pOIQz"
"_id": "dey05oKrBIspvsDa6pOIQz"
},
},
{
"__type__": "cc.Node",
"_name": "New Node",
"_objFlags": 0,
"_parent": {
"__id__": 2
},
"_children": [
{
"__id__": 219
}
],
"_active": true,
"_components": [],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 100,
"height": 100
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_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": "91i2wGBUNO/aVEV0M402zJ"
},
{
"__type__": "cc.Node",
"_name": "New Label",
"_objFlags": 0,
"_parent": {
"__id__": 218
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 220
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 22.25,
"height": 50.4
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
50,
50,
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": "6cCRKENvFE5I9978OAy3iB"
},
{
"__type__": "cc.Label",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 219
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "3",
"_N$string": "3",
"_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": "d8hatUvWxAi5F+od2lb3r1"
},
{
{
"__type__": "cc.Canvas",
"__type__": "cc.Canvas",
"_name": "",
"_name": "",
...
...
assets/DG_FAF/scene/DG_FAF.ts
View file @
d1a0b3fe
This diff is collapsed.
Click to expand it.
assets/DG_FAF/script/defaultData_DG_FAF.ts
View file @
d1a0b3fe
...
@@ -136,38 +136,171 @@
...
@@ -136,38 +136,171 @@
// }
// }
export
const
defaultData
=
{
export
const
defaultData
=
{
hotZoneConfigArr
:
[
{
linkHotZoneIndex
:
0
,
contentList
:
[{
index
:
0
,
text
:
"
item-1
"
}],
hotZoneType
:
"
2
"
,
audio_url
:
"
http://staging-teach.cdn.ireadabc.com/2bf96923b83ee0c5f20930386ce07384.mp3
"
,
score
:
"
1
"
,
},
{
linkHotZoneIndex
:
1
,
contentList
:
[
{
index
:
0
,
text
:
"
1
"
,
isCorrect
:
true
},
{
text
:
"
2
"
,
image_url
:
""
,
hotZoneIndex
:
null
,
score
:
0
},
{
text
:
"
3
"
,
image_url
:
""
,
hotZoneIndex
:
null
,
score
:
0
},
],
hotZoneType
:
"
0
"
,
score
:
"
1
"
,
},
{
linkHotZoneIndex
:
2
,
contentList
:
[
{
index
:
0
,
text
:
"
item-1
"
,
selectHotZoneIndex
:
2
,
isCorrect
:
true
},
{
text
:
""
,
image_url
:
""
,
hotZoneIndex
:
null
,
score
:
0
,
selectHotZoneIndex
:
3
,
},
],
hotZoneType
:
"
3
"
,
score
:
"
2
"
,
},
{
linkHotZoneIndex
:
4
,
contentList
:
[{
index
:
0
,
text
:
"
item-1
"
}],
hotZoneType
:
"
4
"
,
inputText
:
"
Hello World
"
,
score
:
"
1
"
,
},
],
scoreConfigArr
:
[
{
linkHotZoneIndex
:
7
,
linkHotZoneIndexArr
:
[
1
]
},
{
linkHotZoneIndex
:
8
,
linkHotZoneIndexArr
:
[
2
,
3
]
},
],
bgItem
:
{
bgItem
:
{
url
:
"
http://staging-teach.cdn.ireadabc.com/
b6c249637c2892d75121dbb76717508e
.png
"
,
url
:
"
http://staging-teach.cdn.ireadabc.com/
5c84b987ea2291c8d6013fffd39dda32
.png
"
,
rect
:
{
rect
:
{
x
:
316.90215716486904
,
x
:
178.53182751540032
,
y
:
0
,
y
:
0
,
width
:
236.19568567026195
,
width
:
1182.9363449691994
,
height
:
333
,
height
:
1665
,
},
},
},
},
hotZoneItemArr
:
[
hotZoneItemArr
:
[
{
{
index
:
0
,
index
:
0
,
itemType
:
"
rect
"
,
itemType
:
"
rect
"
,
itemName
:
"
1-音频
"
,
fontSize
:
50
,
fontSize
:
50
,
fontName
:
"
BRLNSR_1
"
,
fontName
:
"
BRLNSR_1
"
,
fontColor
:
"
#8f3758
"
,
fontColor
:
"
#8f3758
"
,
fontScale
:
0.679687
5
,
fontScale
:
1.20312
5
,
imgScale
:
1
,
imgScale
:
1
,
mapScale
:
0.679687
5
,
mapScale
:
1.20312
5
,
rect
:
{
x
:
11.6
,
y
:
234
,
width
:
93
,
height
:
93
},
rect
:
{
x
:
438.97
,
y
:
216
,
width
:
45
,
height
:
45
},
},
},
{
{
index
:
1
,
index
:
1
,
itemType
:
"
rect
"
,
itemType
:
"
rect
"
,
itemName
:
"
1-1选项
"
,
fontSize
:
50
,
fontName
:
"
BRLNSR_1
"
,
fontColor
:
"
#8f3758
"
,
fontScale
:
1.203125
,
imgScale
:
1
,
mapScale
:
1.203125
,
rect
:
{
x
:
226.47
,
y
:
445.5
,
width
:
40
,
height
:
40
},
},
{
index
:
2
,
itemType
:
"
rect
"
,
itemName
:
"
2-1Alex
"
,
fontSize
:
50
,
fontName
:
"
BRLNSR_1
"
,
fontColor
:
"
#8f3758
"
,
fontScale
:
1.203125
,
imgScale
:
1
,
mapScale
:
1.203125
,
rect
:
{
x
:
164.47
,
y
:
573
,
width
:
62
,
height
:
37
},
},
{
index
:
3
,
itemType
:
"
rect
"
,
itemName
:
"
2-1Anna
"
,
fontSize
:
50
,
fontName
:
"
BRLNSR_1
"
,
fontColor
:
"
#8f3758
"
,
fontScale
:
1.203125
,
imgScale
:
1
,
mapScale
:
1.203125
,
rect
:
{
x
:
234.47
,
y
:
574
,
width
:
78
,
height
:
35
},
},
{
index
:
4
,
itemType
:
"
rect
"
,
itemName
:
"
3-1输入文本
"
,
fontSize
:
50
,
fontName
:
"
BRLNSR_1
"
,
fontColor
:
"
#8f3758
"
,
fontScale
:
1.203125
,
imgScale
:
1
,
mapScale
:
1.203125
,
rect
:
{
x
:
493.47
,
y
:
1049
,
width
:
200
,
height
:
39
},
},
{
index
:
5
,
itemType
:
"
rect
"
,
itemName
:
"
提交按钮
"
,
fontSize
:
50
,
fontName
:
"
BRLNSR_1
"
,
fontColor
:
"
#8f3758
"
,
fontScale
:
1.203125
,
imgScale
:
1
,
mapScale
:
1.203125
,
rect
:
{
x
:
553.47
,
y
:
1511
,
width
:
150
,
height
:
45
},
},
{
index
:
6
,
itemType
:
"
rect
"
,
itemName
:
"
重做按钮
"
,
fontSize
:
50
,
fontName
:
"
BRLNSR_1
"
,
fontColor
:
"
#8f3758
"
,
fontScale
:
1.203125
,
imgScale
:
1
,
mapScale
:
1.203125
,
rect
:
{
x
:
755.47
,
y
:
1512
,
width
:
132
,
height
:
41
},
},
{
index
:
7
,
itemType
:
"
rect
"
,
itemName
:
"
1得分
"
,
fontSize
:
50
,
fontName
:
"
BRLNSR_1
"
,
fontColor
:
"
#8f3758
"
,
fontScale
:
1.203125
,
imgScale
:
1
,
mapScale
:
1.203125
,
rect
:
{
x
:
1040.47
,
y
:
217
,
width
:
74
,
height
:
41
},
},
{
index
:
8
,
itemType
:
"
rect
"
,
itemName
:
"
2得分
"
,
fontSize
:
50
,
fontSize
:
50
,
fontName
:
"
BRLNSR_1
"
,
fontName
:
"
BRLNSR_1
"
,
fontColor
:
"
#8f3758
"
,
fontColor
:
"
#8f3758
"
,
fontScale
:
0.679687
5
,
fontScale
:
1.20312
5
,
imgScale
:
1
,
imgScale
:
1
,
mapScale
:
0.679687
5
,
mapScale
:
1.20312
5
,
rect
:
{
x
:
1
62.1
,
y
:
26.5
,
width
:
68
,
height
:
68
},
rect
:
{
x
:
1
040.47
,
y
:
520
,
width
:
76
,
height
:
39
},
},
},
],
],
itemCombineGroup
:
[],
submitHotZoneIndex
:
5
,
replayHotZoneIndex
:
6
,
};
};
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment