Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
sn09_xuanze
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
sn09_xuanze
Commits
878a08e4
Commit
878a08e4
authored
Sep 15, 2023
by
Tt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改跳出和点击bug
parent
8424e16d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
4 deletions
+6
-4
sn09_xuanze.ts
assets/sn09_xuanze/scene/sn09_xuanze.ts
+6
-4
No files found.
assets/sn09_xuanze/scene/sn09_xuanze.ts
View file @
878a08e4
...
...
@@ -174,6 +174,7 @@ export default class SceneComponent extends MyCocosSceneComponent {
layer_paopao
.
addChild
(
item
)
this
.
updatePaoPao
(
item
,
data
,
pos
,
i
);
}
pg
.
hw
.
playLocalAudio
(
'
fly
'
)
this
.
scheduleOnce
(()
=>
{
this
.
canTouch
=
true
;
},
2
)
...
...
@@ -217,7 +218,7 @@ export default class SceneComponent extends MyCocosSceneComponent {
item
.
y
=
pos
.
y
-
1000
let
time
=
i
==
1
?
1.3
:
i
==
2
?
1.6
:
2
;
//
cc
.
tween
(
item
)
.
to
(
time
,
{
y
:
pos
.
y
})
.
to
(
time
/
3
,
{
y
:
pos
.
y
})
.
call
(()
=>
{
this
.
repeatFly
(
item
)
}).
start
();
...
...
@@ -226,9 +227,6 @@ export default class SceneComponent extends MyCocosSceneComponent {
cc
.
tween
(
item
)
.
repeatForever
(
cc
.
tween
()
.
call
(()
=>
{
pg
.
hw
.
playLocalAudio
(
'
fly
'
)
})
.
to
(
0.5
,
{
scaleY
:
1.1
,
y
:
60
})
.
to
(
0.5
,
{
scaleY
:
1
,
y
:
0
})
.
delay
(
0.7
)
...
...
@@ -240,6 +238,7 @@ export default class SceneComponent extends MyCocosSceneComponent {
// 点击泡泡
touchPaoPao
(
e
:
any
)
{
if
(
!
this
.
canTouch
)
return
;
this
.
canTouch
=
false
;
// 如果泡泡没有到指定位置不允许点击
let
item
=
e
.
target
;
let
data
=
e
.
target
.
data
;
...
...
@@ -263,11 +262,13 @@ export default class SceneComponent extends MyCocosSceneComponent {
let
children
=
layer_paopao
.
children
;
children
.
forEach
((
node
,
i
)
=>
{
if
(
this
.
rightList
.
some
(
dt
=>
node
.
data
.
id
==
dt
.
id
))
return
;
cc
.
Tween
.
stopAllByTarget
(
node
);
cc
.
tween
(
node
).
by
(
0.5
+
(
i
/
children
.
length
)
*
0.5
,
{
y
:
-
1500
}).
start
();
})
}
this
.
scheduleOnce
(()
=>
{
item
.
parent
=
null
;
this
.
canTouch
=
true
;
if
(
this
.
rightList
.
length
==
this
.
currentRightList
.
length
)
{
cc
.
Tween
.
stopAll
();
this
.
startCreate
=
false
;
...
...
@@ -286,6 +287,7 @@ export default class SceneComponent extends MyCocosSceneComponent {
pg
.
view
.
visible
(
bubble
,
true
)
pg
.
view
.
visible
(
broken
,
false
)
this
.
repeatFly
(
item
);
this
.
canTouch
=
true
;
})
}
}
...
...
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