Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
PS_001
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
PS_001
Commits
1ad21c4a
Commit
1ad21c4a
authored
Jan 14, 2022
by
范雪寒
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat:
parent
810ea134
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
26 additions
and
52 deletions
+26
-52
PS_001_scene1.fire
assets/PS_001/ani/scene/PS_001_scene1.fire
+7
-7
PS_001_scene1.ts
assets/PS_001/ani/script/PS_001_scene1.ts
+14
-3
PS_001_scene8.ts
assets/PS_001/ani/script/PS_001_scene8.ts
+5
-2
PS_001.ts
assets/PS_001/scene/PS_001.ts
+0
-40
No files found.
assets/PS_001/ani/scene/PS_001_scene1.fire
View file @
1ad21c4a
...
...
@@ -386,8 +386,8 @@
},
"_contentSize": {
"__type__": "cc.Size",
"width":
0
,
"height":
0
"width":
2048
,
"height":
1152
},
"_anchorPoint": {
"__type__": "cc.Vec2",
...
...
@@ -398,8 +398,8 @@
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
-59.759,
277.71,
-59.759
000000000015
,
277.71
000000000004
,
0,
0,
0,
...
...
@@ -1219,7 +1219,7 @@
"ctor": "Float64Array",
"array": [
0,
0
,
399.133
,
0,
0,
0,
...
...
@@ -1399,7 +1399,7 @@
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0
.5
,
"x": 0,
"y": 0.5
},
"_trs": {
...
...
@@ -1627,7 +1627,7 @@
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0
.5
,
"x": 0,
"y": 0.5
},
"_trs": {
...
...
assets/PS_001/ani/script/PS_001_scene1.ts
View file @
1ad21c4a
...
...
@@ -31,6 +31,18 @@ export default class PS_001_scene1 extends cc.Component {
this
.
camera
=
cameraNode
this
.
parent
=
parent
this
.
camera
.
zIndex
=
1
;
const
light_left
=
cc
.
find
(
'
Canvas/Main Camera/light_left
'
);
const
light_right
=
cc
.
find
(
'
Canvas/Main Camera/light_right
'
);
const
bg
=
cc
.
find
(
'
Canvas/Main Camera/bg
'
);
light_left
.
active
=
false
;
light_left
.
angle
=
0
;
light_right
.
active
=
false
;
light_right
.
angle
=
0
;
bg
.
active
=
false
;
if
(
PS_001_Ctrl
.
getIns
().
time
==
0
)
{
this
.
beforeStartFirstTime
();
}
else
{
...
...
@@ -42,9 +54,6 @@ export default class PS_001_scene1 extends cc.Component {
const
light_left
=
cc
.
find
(
'
Canvas/Main Camera/light_left
'
);
const
light_right
=
cc
.
find
(
'
Canvas/Main Camera/light_right
'
);
const
bg
=
cc
.
find
(
'
Canvas/Main Camera/bg
'
);
light_left
.
active
=
false
;
light_right
.
active
=
false
;
bg
.
active
=
false
;
const
canvas
=
cc
.
find
(
'
Canvas
'
);
const
zoom
=
this
.
camera
.
getComponent
(
cc
.
Camera
).
zoomRatio
;
const
cameraWidth
=
canvas
.
width
/
zoom
;
...
...
@@ -54,6 +63,8 @@ export default class PS_001_scene1 extends cc.Component {
light_right
.
active
=
true
;
bg
.
active
=
true
;
console
.
log
(
'
cameraWidth =
'
+
cameraWidth
);
cc
.
tween
(
light_left
)
.
set
({
x
:
-
cameraWidth
/
2
,
y
:
cameraHeight
/
2
})
.
to
(
1
,
{
angle
:
angle
},
{
easing
:
'
cubicIn
'
})
...
...
assets/PS_001/ani/script/PS_001_scene8.ts
View file @
1ad21c4a
...
...
@@ -70,8 +70,7 @@ export default class PS_001_scene8 extends cc.Component {
.
delay
(
5
)
.
delay
(
10
)
.
call
(()
=>
{
this
.
parent
.
toNext
(
8
)
this
.
node
.
destroy
()
this
.
onFinishFrirstTime
();
})
.
start
()
}
...
...
@@ -123,8 +122,10 @@ export default class PS_001_scene8 extends cc.Component {
}
else
{
const
bg
=
cc
.
find
(
'
Canvas/Main Camera/bg
'
);
bg
.
active
=
true
;
bg
.
zIndex
=
1
;
cc
.
tween
(
bg
).
to
(
1
,
{
opacity
:
255
}).
start
();
const
wellDown
=
cc
.
find
(
'
Canvas/wellDown
'
);
wellDown
.
zIndex
=
1
;
wellDown
.
active
=
true
;
wellDown
.
x
=
this
.
camera
.
x
;
wellDown
.
y
=
this
.
camera
.
y
;
...
...
@@ -139,6 +140,7 @@ export default class PS_001_scene8 extends cc.Component {
}
async
onFinishFrirstTime
()
{
console
.
log
(
'
汪汪汪8
'
);
const
canvas
=
cc
.
find
(
'
Canvas
'
);
const
zoom
=
this
.
camera
.
getComponent
(
cc
.
Camera
).
zoomRatio
;
const
cameraWidth
=
canvas
.
width
/
zoom
;
...
...
@@ -146,6 +148,7 @@ export default class PS_001_scene8 extends cc.Component {
const
ranbow
=
cc
.
find
(
'
Canvas/ranbow
'
);
ranbow
.
active
=
true
;
ranbow
.
zIndex
=
1
;
ranbow
.
scale
=
(
cameraHeight
+
20
)
/
ranbow
.
height
;
ranbow
.
x
=
cameraWidth
/
2
+
this
.
camera
.
x
;
ranbow
.
y
=
this
.
camera
.
y
;
...
...
assets/PS_001/scene/PS_001.ts
View file @
1ad21c4a
...
...
@@ -52,46 +52,6 @@ export default class SceneComponent extends MyCocosSceneComponent {
PS_001_Ctrl
.
getIns
().
time
=
1
;
PS_001_Ctrl
.
getIns
().
goscene
(
conf
[
step
].
id
);
});
// if (!cc.game.isPersistRootNode(cc.find('bk'))) {
// cc.game.addPersistRootNode(cc.find('bk'));
// cc.game.addPersistRootNode(cc.find('hand'));
// }
// cc.director.loadScene(`PS_001_scene1`);
// if (this.data.step == 0) {
// // handManager.getIns().isStart = false;
// cc.director.loadScene(`PS_001_scene1`, () => {
// // cc.find('Canvas').getComponent(`PS_001_scene1`).play();
// });
// } else if (this.data.step <= PS_001_handManager.getIns().conf.length + 1) {
// this.jumpToStep(this.data.step);
// } else {
// cc.director.loadScene(`PS_001_scene8`, () => {
// // cc.find('Canvas').getComponent(`PS_001_scene8`).play();
// });
// }
}
jumpToStep
(
step
)
{
const
conf
=
[
null
,
{
time
:
5
,
scene
:
1
},
{
time
:
12
,
scene
:
1
},
{
time
:
9
,
scene
:
2
},
{
time
:
13
,
scene
:
3
},
{
time
:
18
,
scene
:
4
},
{
time
:
18
,
scene
:
5
},
{
time
:
10
,
scene
:
6
},
{
time
:
16
,
scene
:
6
},
{
time
:
18
,
scene
:
7
},
{
time
:
24
,
scene
:
8
},
{
time
:
33
,
scene
:
8
},
{
time
:
50
,
scene
:
8
},
];
cc
.
director
.
loadScene
(
`PS_001_scene
${
conf
[
step
].
scene
}
`
,
()
=>
{
cc
.
find
(
'
Canvas
'
).
getComponent
(
`PS_001_scene
${
conf
[
step
].
scene
}
`
).
play
(
step
);
});
}
playLocalAudio
(
audioName
)
{
...
...
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