Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
R
RB-studyChina-20250617
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
SparkProjects
RB-studyChina-20250617
Commits
d4bcfd26
Commit
d4bcfd26
authored
Jun 20, 2025
by
俞嘉婷
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
游戏引导
parent
99493a80
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
1 deletion
+8
-1
main.ts
mock/main.ts
+1
-1
GamePage.tsx
src/pages/GamePage/GamePage.tsx
+5
-0
store.ts
src/store/store.ts
+2
-0
No files found.
mock/main.ts
View file @
d4bcfd26
...
@@ -22,7 +22,7 @@ export default [
...
@@ -22,7 +22,7 @@ export default [
"isAgent"
:
true
,
"isAgent"
:
true
,
"boundYkCode"
:
"eiusmod in dolor"
,
"boundYkCode"
:
"eiusmod in dolor"
,
"agreePrivacyFlag"
:
true
,
"agreePrivacyFlag"
:
true
,
"newGuideFlag"
:
0
,
// 从0开始
"newGuideFlag"
:
1
,
// 从0开始
}
}
}
}
},
},
...
...
src/pages/GamePage/GamePage.tsx
View file @
d4bcfd26
...
@@ -21,6 +21,7 @@ import { LOG_KEY, pageView, sensorLog } from "@/utils/sensors";
...
@@ -21,6 +21,7 @@ import { LOG_KEY, pageView, sensorLog } from "@/utils/sensors";
import
"./js/output"
;
import
"./js/output"
;
import
API
from
'@/api'
;
declare
const
Game
:
any
;
declare
const
Game
:
any
;
...
@@ -54,7 +55,11 @@ class GamePage extends React.Component<any, any> {
...
@@ -54,7 +55,11 @@ class GamePage extends React.Component<any, any> {
targetStudy
:
1
,
//背包数量
targetStudy
:
1
,
//背包数量
targetTravel
:
1
,
//飞机数量
targetTravel
:
1
,
//飞机数量
time
:
120
,
//时间,秒计
time
:
120
,
//时间,秒计
needGuide
:
store
.
indexData
?.
newGuideFlag
==
1
,
})
})
if
(
store
.
indexData
?.
newGuideFlag
==
1
)
{
API
.
completeGuide
({
flag
:
2
})
}
//监听事件,比如游戏结果,gameResult|exitGame
//监听事件,比如游戏结果,gameResult|exitGame
game
.
addGlobalEvent
(
"gameResult"
,
(
e
)
=>
{
game
.
addGlobalEvent
(
"gameResult"
,
(
e
)
=>
{
console
.
log
(
e
.
data
)
//成功
console
.
log
(
e
.
data
)
//成功
...
...
src/store/store.ts
View file @
d4bcfd26
...
@@ -99,6 +99,8 @@ class Store {
...
@@ -99,6 +99,8 @@ class Store {
validUid
?:
boolean
,
validUid
?:
boolean
,
rulePop
?:
boolean
,
rulePop
?:
boolean
,
newGuideFlag
:
number
,
}
=
{};
}
=
{};
firstIn
=
true
;
firstIn
=
true
;
async
updateIndex
()
{
async
updateIndex
()
{
...
...
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