Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
games
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
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
熊东起
games
Commits
81154e79
Commit
81154e79
authored
Jan 15, 2021
by
熊东起
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
666
parent
65485d09
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
28 additions
and
3 deletions
+28
-3
GameIndex.ts
src/GameIndex.ts
+2
-1
App.js
test/src/App.js
+26
-2
No files found.
src/GameIndex.ts
View file @
81154e79
...
...
@@ -99,6 +99,7 @@ export class GameIndex extends GAME.WidgetBase {
this
.
onMove
();
break
;
case
"refresh-data"
:
this
.
_index
=
0
;
GameMgr
.
options
.
curSteps
=
data
.
curSteps
;
GameMgr
.
GAME_STEP
=
data
.
gameSteps
;
GameMgr
.
SITE_NAME
=
data
.
siteName
;
...
...
@@ -190,7 +191,7 @@ export class GameIndex extends GAME.WidgetBase {
/** 盖住移动的人物 */
private
_index
=
0
;
onMaskPlayer
()
{
if
(
this
.
player
.
y
<=
4
4
89
&&
this
.
_index
==
0
)
{
if
(
this
.
player
.
y
<=
4
5
89
&&
this
.
_index
==
0
)
{
this
.
_index
++
;
this
.
gameMask
.
resetLayers
(
this
.
_index
);
}
else
if
(
this
.
player
.
y
<=
4400
&&
this
.
_index
==
1
)
{
...
...
test/src/App.js
View file @
81154e79
...
...
@@ -45,12 +45,36 @@ function App() {
}
function
onClickButton
(
type
)
{
_widget
.
dispatchInEvent
(
type
,{
curSteps
:
220000
,
endSteps
:
350000
})
switch
(
type
)
{
case
"game-start"
:
_widget
.
dispatchInEvent
(
type
,
{
curSteps
:
0
,
endSteps
:
200000
})
break
;
case
"refresh-data"
:
_widget
.
dispatchInEvent
(
type
,
{
curSteps
:
0
,
gameSteps
:
[
0
,
10000
,
30000
,
100000
,
200000
,
350000
],
siteName
:
[
"宝石山"
,
"金猪存钱罐"
,
"断桥残雪"
,
"平湖秋月"
,
"拆红包"
,
"苏堤春晓"
,
"曲苑风荷"
,
"打病毒"
,
"双峰插云"
],
linkList
:
[]
});
break
;
}
}
return
(
<
div
className
=
"App"
>
<
div
className
=
"control-bar"
>
<
button
onClick
=
{
e
=>
onClickButton
(
'refresh-data'
)}
>
refresh
-
data
<
/button
>
<
button
onClick
=
{
e
=>
onClickButton
(
'game-start'
)}
>
GO
<
/button
>
<
/div
>
<
CanvasWidget
className
=
"canvas-widget"
widgetFactory
=
{
WalkCom
}
widgetConfig
=
{
widgetConfig
}
...
...
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