Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
tb_project
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
钱根
tb_project
Commits
068af7ad
Commit
068af7ad
authored
Sep 10, 2021
by
Master Q
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
0910
parent
7378540a
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
16 additions
and
12 deletions
+16
-12
sceneCtrl.ts
module/ctrls/sceneCtrl.ts
+2
-2
waitingCtrl.ts
module/ctrls/waitingCtrl.ts
+3
-6
ResJson.ts
src/ResJson.ts
+1
-1
PrizeShowPanel.ts
src/panels/PrizeShowPanel.ts
+3
-2
GameScene.ts
src/scenes/GameScene/GameScene.ts
+7
-1
No files found.
module/ctrls/sceneCtrl.ts
View file @
068af7ad
...
@@ -18,12 +18,12 @@ export default class SceneCtrl {
...
@@ -18,12 +18,12 @@ export default class SceneCtrl {
this
.
_parent
=
parent
;
this
.
_parent
=
parent
;
}
}
change
(
cls
:
any
,
data
?:
any
)
{
async
change
(
cls
:
any
,
data
?:
any
)
{
//如果是同一个场景,考虑是替换还是return
//如果是同一个场景,考虑是替换还是return
// if (this._currentScene && this._currentScene instanceof cls) return;//new一个得了,playScene维护太蛋疼,到时看性能吧
// if (this._currentScene && this._currentScene instanceof cls) return;//new一个得了,playScene维护太蛋疼,到时看性能吧
showWaiting
();
let
scene
:
Scene
=
new
cls
(
data
);
let
scene
:
Scene
=
new
cls
(
data
);
scene
.
visible
=
false
;
scene
.
visible
=
false
;
showWaiting
();
let
preScene
:
Scene
=
this
.
_currentScene
;
let
preScene
:
Scene
=
this
.
_currentScene
;
scene
.
onLoaded
=
()
=>
{
scene
.
onLoaded
=
()
=>
{
hideWaiting
();
hideWaiting
();
...
...
module/ctrls/waitingCtrl.ts
View file @
068af7ad
...
@@ -39,11 +39,7 @@ export const showWaiting = async (msg?: string) => {
...
@@ -39,11 +39,7 @@ export const showWaiting = async (msg?: string) => {
// initWaiting();
// initWaiting();
// _waiting.show(msg)
// _waiting.show(msg)
// _parent.addChild(_waiting);
// _parent.addChild(_waiting);
sendTbNet
(
TbNetName
.
showCustomLoading
,
{},
(
s
,
d
)
=>
{
return
sendTbNet
(
TbNetName
.
showCustomLoading
,{}
,
null
,
null
,
true
)
if
(
s
)
{
customLoadingClose
=
d
.
data
}
}
,
null
,
true
)
}
}
/**
/**
...
@@ -51,7 +47,8 @@ export const showWaiting = async (msg?: string) => {
...
@@ -51,7 +47,8 @@ export const showWaiting = async (msg?: string) => {
*/
*/
export
const
hideWaiting
=
()
=>
{
export
const
hideWaiting
=
()
=>
{
// _parent.removeChild(_waiting);
// _parent.removeChild(_waiting);
typeof
customLoadingClose
==
'function'
&&
customLoadingClose
()
// typeof customLoadingClose == 'function' && customLoadingClose()
return
sendTbNet
(
TbNetName
.
closeCustomLoading
,
null
,
null
,
null
,
true
)
}
}
export
const
destroyWaiting
=
()
=>
{
export
const
destroyWaiting
=
()
=>
{
...
...
src/ResJson.ts
View file @
068af7ad
...
@@ -3826,5 +3826,5 @@ export const ResJson = {
...
@@ -3826,5 +3826,5 @@ export const ResJson = {
}
}
}
}
],
],
"path"
:
"https://yun.duiba.com.cn/db_games/activity/template/1631
179244
/resource/"
"path"
:
"https://yun.duiba.com.cn/db_games/activity/template/1631
206618
/resource/"
}
}
\ No newline at end of file
src/panels/PrizeShowPanel.ts
View file @
068af7ad
...
@@ -29,7 +29,7 @@ export class PrizeShowPanel extends Panel {
...
@@ -29,7 +29,7 @@ export class PrizeShowPanel extends Panel {
.
drawRoundedRect
(
150
,
236
,
300
,
300
,
20
)
.
drawRoundedRect
(
150
,
236
,
300
,
300
,
20
)
.
endFill
()
.
endFill
()
UI
.
Btn
(
panelCtn
,
'confirm-btn.png'
,
function
()
{
UI
.
Btn
(
panelCtn
,
'confirm-btn.png'
,
async
function
()
{
this
.
btnDelay
(
this
)
this
.
btnDelay
(
this
)
if
(
this
.
data
.
type
==
3
)
{
if
(
this
.
data
.
type
==
3
)
{
this
.
hidePanel
()
this
.
hidePanel
()
...
@@ -39,12 +39,13 @@ export class PrizeShowPanel extends Panel {
...
@@ -39,12 +39,13 @@ export class PrizeShowPanel extends Panel {
GDispatcher
.
dispatchEvent
(
'init-score'
)
GDispatcher
.
dispatchEvent
(
'init-score'
)
},
},
once
:
true
once
:
true
})
}
,
null
,
null
,
true
)
changeScene
(
GameOverScene
,
Object
.
assign
({},
this
.
data
,
{
hideMusic
:
true
}))
changeScene
(
GameOverScene
,
Object
.
assign
({},
this
.
data
,
{
hideMusic
:
true
}))
//@ts-ignore
//@ts-ignore
my
&&
my
.
navigateTo
({
my
&&
my
.
navigateTo
({
url
:
`/pages/rewardinfofill/rewardinfofill?id=
${
this
.
data
.
id
}
&prizeId=
${
this
.
data
.
prizeId
}
`
url
:
`/pages/rewardinfofill/rewardinfofill?id=
${
this
.
data
.
id
}
&prizeId=
${
this
.
data
.
prizeId
}
`
})
})
}
else
{
}
else
{
// @ts-ignore
// @ts-ignore
showToast
(
'奖品已为您发放至淘宝卡券~'
)
showToast
(
'奖品已为您发放至淘宝卡券~'
)
...
...
src/scenes/GameScene/GameScene.ts
View file @
068af7ad
...
@@ -180,7 +180,13 @@ export class GameScene extends MotionInitScene {
...
@@ -180,7 +180,13 @@ export class GameScene extends MotionInitScene {
var
fail
=
UI
.
Lottie
(
this
,
yoga_fail
,
180
,
290
)
var
fail
=
UI
.
Lottie
(
this
,
yoga_fail
,
180
,
290
)
fail
.
play
(
1
,
()
=>
{
fail
.
play
(
1
,
()
=>
{
// close bgm
// close bgm
this
.
musicBoolean
=
false
sendTbNet
(
TbNetName
.
openMusic
,
{
isOn
:
false
,
kurl
:
TBBgm
.
gameBgm
,
loop
:
true
,
force
:
true
},
null
,
null
,
true
)
sendTbNet
(
TbNetName
.
addTrack
,
{
sendTbNet
(
TbNetName
.
addTrack
,
{
type
:
'wildwoodmg:app_finish_game'
type
:
'wildwoodmg:app_finish_game'
...
...
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