Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
E
East_L228
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
East_L228
Commits
0012ea38
Commit
0012ea38
authored
May 13, 2020
by
李维
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dev commit
This reverts commit ac8918d802389ee88d0101c828dcb32d90a57159.
parent
6801ce0b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
1 deletion
+9
-1
play.component.ts
src/app/play/play.component.ts
+9
-1
No files found.
src/app/play/play.component.ts
View file @
0012ea38
...
...
@@ -224,6 +224,7 @@ export class PlayComponent implements OnInit, OnDestroy {
this
.
initCamera
();
this
.
initCards
();
this
.
m_enableAutoRunFocus
=
true
;
console
.
log
(
"
Init auto
"
)
this
.
autoRunFocus
()
this
.
initShowCard
();
this
.
g_cartoon
.
playAudio
(
"
sm-run
"
,
false
,
null
,
true
,
(
audio
)
=>
{
...
...
@@ -302,6 +303,7 @@ export class PlayComponent implements OnInit, OnDestroy {
this
.
subscribeMapDownEvent
(
element
.
id
,
()
=>
{
if
(
this
.
m_enableCamera
){
console
.
log
(
"
Enable camera -> 1 false
"
)
this
.
m_enableCamera
=
false
;
this
.
g_cartoon
.
stopAudio
(
"
sm-run
"
)
clearTimeout
(
this
.
m_autoFocusID
)
...
...
@@ -495,6 +497,7 @@ export class PlayComponent implements OnInit, OnDestroy {
}
if
(
this
.
g_cartoon
.
getCartoonElement
(
this
.
m_allCardIds
[
next
]).
ref
.
x
>=
this
.
g_canvasWidth
-
300
*
this
.
g_mapScale
){
console
.
log
(
"
Enable camera -> 2 false
"
)
this
.
m_enableCamera
=
false
;
this
.
g_enableMapDown
=
false
;
let
distance
=
this
.
g_cartoon
.
getCartoonElement
(
this
.
m_allCardIds
[
current
]).
ref
.
x
/
2
...
...
@@ -503,6 +506,7 @@ export class PlayComponent implements OnInit, OnDestroy {
this
.
g_cartoon
.
getCartoonElement
(
this
.
m_allCardIds
[
current
]).
hideHighlight
()
}
this
.
g_cartoon
.
getCartoonElement
(
this
.
m_allCardIds
[
next
]).
showHighlight
(()
=>
{
console
.
log
(
"
Enable camera -> 3 true
"
)
this
.
m_enableCamera
=
true
;
this
.
g_enableMapDown
=
true
;
callback
&&
callback
()
...
...
@@ -526,6 +530,7 @@ export class PlayComponent implements OnInit, OnDestroy {
if
(
this
.
m_enableAutoRunFocus
){
this
.
m_autoFocusID
=
setTimeout
(()
=>
{
if
(
this
.
m_enableAutoRunFocus
){
console
.
log
(
"
Set timeout auto
"
)
this
.
autoRunFocus
()
}
},
3000
)
...
...
@@ -609,6 +614,7 @@ export class PlayComponent implements OnInit, OnDestroy {
let
text
=
this
.
g_cartoon
.
createLabel
(
data
.
text
,
"
BerlinSansFBDemi-Bold
"
,
null
,
50
)
let
lineNum
=
data
.
text
.
split
(
"
"
).
length
console
.
log
(
lineNum
)
text
.
maxSingalLineWidth
=
165
text
.
fontColor
=
"
#e05e14
"
;
if
(
lineNum
>
1
){
...
...
@@ -638,6 +644,7 @@ export class PlayComponent implements OnInit, OnDestroy {
this
.
m_enableAutoRunFocus
=
true
;
element
.
audio_url
=
null
;
this
.
g_cartoon
.
stopAudio
(
element
.
audio_url
)
console
.
log
(
"
Close auto
"
)
this
.
autoRunFocus
()
tweenChange
(
element
.
ref
,
{
scaleX
:
0
,
scaleY
:
0
},
0.3
,
()
=>
{
element
.
ref
.
visible
=
false
;
...
...
@@ -664,7 +671,8 @@ export class PlayComponent implements OnInit, OnDestroy {
})
this
.
subscribeMapDownEvent
(
closeBntton
.
id
,
()
=>
{
this
.
g_cartoon
.
stopAudio
(
element
.
audio_url
)
this
.
g_cartoon
.
playAudio
(
"
sm-camera
"
)
console
.
log
(
"
Enable camera -> 4 true
"
)
this
.
m_enableCamera
=
true
;
element
.
hide
(()
=>
{
this
.
g_enableMapDown
=
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