Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OP46
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
OP46
Commits
4388318f
Commit
4388318f
authored
3 years ago
by
Tt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
调整需求
parent
656979e6
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
118 additions
and
105 deletions
+118
-105
OP46.fire
assets/OP46/scene/OP46.fire
+105
-104
OP46.js
assets/OP46/scene/OP46.js
+13
-1
No files found.
assets/OP46/scene/OP46.fire
View file @
4388318f
...
...
@@ -289,9 +289,6 @@
{
"__id__": 50
},
{
"__id__": 53
},
{
"__id__": 55
}
...
...
@@ -2465,14 +2462,18 @@
"_parent": {
"__id__": 5
},
"_children": [],
"_children": [
{
"__id__": 51
}
],
"_active": true,
"_components": [
{
"__id__": 5
1
"__id__": 5
3
},
{
"__id__": 5
2
"__id__": 5
4
}
],
"_prefab": null,
...
...
@@ -2523,6 +2524,100 @@
"groupIndex": 0,
"_id": "977Zla+vpGmpD8y2lqL226"
},
{
"__type__": "cc.Node",
"_name": "la_layout",
"_objFlags": 0,
"_parent": {
"__id__": 50
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 52
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 124.6,
"height": 200
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
-16.686,
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": "0cA2rTLH5GB4a22UQMyjgM"
},
{
"__type__": "cc.Layout",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 51
},
"_enabled": true,
"_layoutSize": {
"__type__": "cc.Size",
"width": 124.6,
"height": 200
},
"_resize": 1,
"_N$layoutType": 1,
"_N$cellSize": {
"__type__": "cc.Size",
"width": 40,
"height": 40
},
"_N$startAxis": 0,
"_N$paddingLeft": 0,
"_N$paddingRight": 0,
"_N$paddingTop": 0,
"_N$paddingBottom": 0,
"_N$spacingX": 100,
"_N$spacingY": 0,
"_N$verticalDirection": 1,
"_N$horizontalDirection": 0,
"_N$affectedByScale": false,
"_id": "9bBKJpxXNCG6JBLAg98JUf"
},
{
"__type__": "cc.Sprite",
"_name": "",
...
...
@@ -2593,7 +2688,7 @@
"_active": true,
"_components": [
{
"__id__": 5
4
"__id__": 5
6
}
],
"_prefab": null,
...
...
@@ -2619,8 +2714,8 @@
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
-16.68
6
,
629.8
5
,
-16.68
5999999999922
,
629.8
499999999999
,
0,
0,
0,
...
...
@@ -2649,7 +2744,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 5
3
"__id__": 5
5
},
"_enabled": true,
"_materials": [
...
...
@@ -2679,100 +2774,6 @@
"_N$cacheMode": 0,
"_id": "f3aCXfwJpAEbg2UPj/vUwK"
},
{
"__type__": "cc.Node",
"_name": "la_layout",
"_objFlags": 0,
"_parent": {
"__id__": 5
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 56
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 124.6,
"height": 200
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
-16.686,
629.85,
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": "0cA2rTLH5GB4a22UQMyjgM"
},
{
"__type__": "cc.Layout",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 55
},
"_enabled": true,
"_layoutSize": {
"__type__": "cc.Size",
"width": 124.6,
"height": 200
},
"_resize": 1,
"_N$layoutType": 1,
"_N$cellSize": {
"__type__": "cc.Size",
"width": 40,
"height": 40
},
"_N$startAxis": 0,
"_N$paddingLeft": 0,
"_N$paddingRight": 0,
"_N$paddingTop": 0,
"_N$paddingBottom": 0,
"_N$spacingX": 100,
"_N$spacingY": 0,
"_N$verticalDirection": 1,
"_N$horizontalDirection": 0,
"_N$affectedByScale": false,
"_id": "9bBKJpxXNCG6JBLAg98JUf"
},
{
"__type__": "cc.Widget",
"_name": "",
...
...
This diff is collapsed.
Click to expand it.
assets/OP46/scene/OP46.js
View file @
4388318f
...
...
@@ -170,6 +170,15 @@ cc.Class({
//TODO:copy
this
.
hideFlower
();
const
box
=
cc
.
find
(
'
Canvas/bg/box
'
);
box
.
removeAllChildren
();
const
box_mid
=
cc
.
find
(
'
Canvas/bg/box_mid
'
);
box_mid
.
removeAllChildren
();
let
group1
=
cc
.
find
(
'
Canvas/bg/group1
'
);
group1
.
removeAllChildren
();
let
group2
=
cc
.
find
(
'
Canvas/bg/group2
'
);
group2
.
removeAllChildren
();
this
.
coolCatSpeakStart
(()
=>
{
this
.
showSubmitBtn
();
this
.
jumpToQuestion
(
this
.
status
.
currentQuestionIdx
);
...
...
@@ -202,18 +211,21 @@ cc.Class({
let
group2
=
cc
.
find
(
'
Canvas/bg/group2
'
);
group2
.
removeAllChildren
();
let
la_layout
=
cc
.
find
(
"
Canvas/bg/la_layout
"
);
let
la_layout
=
cc
.
find
(
"
Canvas/bg/
paizi/
la_layout
"
);
la_layout
.
removeAllChildren
();
let
desc
=
cc
.
find
(
"
Canvas/bg/desc
"
);
const
optiontext
=
this
.
data
.
question_arr
[
questionIdx
].
desc1
;
const
optiontext2
=
this
.
data
.
question_arr
[
questionIdx
].
desc2
;
let
textArr
=
[
optiontext
,
optiontext2
];
textArr
.
forEach
((
item
)
=>
{
if
(
!
item
||
item
==
""
)
return
;
let
d
=
cc
.
instantiate
(
desc
);
d
.
getComponent
(
cc
.
Label
).
string
=
item
;
la_layout
.
addChild
(
d
);
d
.
y
=
0
;
})
let
paizi
=
cc
.
find
(
"
Canvas/bg/paizi
"
);
paizi
.
active
=
la_layout
.
children
.
length
>
0
;
let
size
=
cc
.
view
.
getCanvasSize
();
let
scale
=
(
size
.
width
/
size
.
height
)
/
(
1280
/
720
);
group2
.
getComponent
(
cc
.
Layout
).
spacingX
=
scale
<
1
?
75
*
scale
:
85
;
...
...
This diff is collapsed.
Click to expand it.
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