Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
X
xiaoxiaole
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
wildfirecode13
xiaoxiaole
Commits
27ef644a
Commit
27ef644a
authored
Sep 19, 2019
by
wildfirecode
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
3645723e
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
10 deletions
+10
-10
index.html
egret/index.html
+1
-1
MapScene.ts
egret/src/mapScene/MapScene.ts
+7
-7
Prize2Panel.ts
egret/src/panels/Prize2Panel.ts
+1
-1
SignPrizePanel.ts
egret/src/panels/SignPrizePanel.ts
+1
-1
No files found.
egret/index.html
View file @
27ef644a
...
...
@@ -49,7 +49,7 @@
<img
id=
"pic"
style=
"width:100%;position: absolute;z-index: 999;display: none;"
/>
<script>
window
[
'total_level'
]
=
18
+
13
*
5
;
window
[
'last_level'
]
=
8
2
;
//必须大于等于total_level
window
[
'last_level'
]
=
7
2
;
//必须大于等于total_level
// localStorage.clear();
var
sharePic
=
document
.
getElementById
(
'pic'
);
...
...
egret/src/mapScene/MapScene.ts
View file @
27ef644a
...
...
@@ -81,8 +81,8 @@ export default class MapScene extends Scene {
const
homeData
=
getHomeData
();
if
(
homeData
.
levels
.
length
==
0
)
{
target
=
1
;
}
else
if
(
homeData
.
levels
.
length
==
70
)
{
target
=
70
+
1
;
}
else
if
(
homeData
.
levels
.
length
==
window
[
'total_level'
]
)
{
target
=
window
[
'total_level'
]
+
1
;
}
else
{
target
=
homeData
.
levels
.
length
+
1
;
}
...
...
@@ -98,7 +98,7 @@ export default class MapScene extends Scene {
},
this
);
}
if
(
homeData
.
levels
.
length
<
70
)
{
if
(
homeData
.
levels
.
length
<
window
[
'total_level'
]
)
{
const
targetIcon
=
MapScene
.
iconHash
[
target
];
const
light
=
RES
.
getRes
(
'lightani_png'
);
const
pic
=
new
egret
.
Bitmap
(
light
);
//76 61
...
...
@@ -135,8 +135,8 @@ export default class MapScene extends Scene {
},
this
);
let
lastOrder
=
homeData
.
levels
.
length
+
1
;
if
(
homeData
.
levels
.
length
>=
70
)
lastOrder
=
70
;
if
(
homeData
.
levels
.
length
>=
window
[
'total_level'
]
)
lastOrder
=
window
[
'total_level'
]
;
this
.
scroll
.
viewport
.
scrollV
=
this
.
getScrollV
(
lastOrder
,
this
.
stage
.
stageHeight
);
// console.warn(this.getScrollV(lastOrder, this.stage.stageHeight))
...
...
@@ -235,7 +235,7 @@ export default class MapScene extends Scene {
this
[
'bloodTxt'
].
text
=
`
${
homeData
.
remainEnargy
}
/5`
;
this
[
'goldTxt'
].
text
=
`
${
homeData
.
wealth
}
`
;
for
(
let
j
=
1
;
j
<
70
;
j
++
)
{
for
(
let
j
=
1
;
j
<
window
[
'total_level'
]
;
j
++
)
{
this
.
disableIcon
(
j
+
1
);
}
for
(
let
i
=
0
;
i
<
homeData
.
levels
.
length
;
i
++
)
{
...
...
@@ -252,7 +252,7 @@ export default class MapScene extends Scene {
const
star
=
MapScene
.
starHash
[
1
];
star
.
setStar
(
0
);
this
.
enableIcon
(
1
);
}
else
if
(
homeData
.
levels
.
length
==
70
)
{
}
else
if
(
homeData
.
levels
.
length
==
window
[
'total_level'
]
)
{
}
else
{
const
star
=
MapScene
.
starHash
[
homeData
.
levels
.
length
+
1
];
...
...
egret/src/panels/Prize2Panel.ts
View file @
27ef644a
...
...
@@ -34,7 +34,7 @@ export default class Prize2Panel extends Panel {
this
[
'goBtn'
].
addEventListener
(
egret
.
TouchEvent
.
TOUCH_TAP
,
()
=>
{
this
.
hidePanel
();
if
(
this
.
_level
+
1
<=
70
)
if
(
this
.
_level
+
1
<=
window
[
'total_level'
]
)
changeMapScene
({
level
:
this
.
_level
+
1
});
else
changeMapScene
();
...
...
egret/src/panels/SignPrizePanel.ts
View file @
27ef644a
...
...
@@ -32,7 +32,7 @@ export default class SignPrizePanel extends Panel {
this
[
'goBtn'
].
addEventListener
(
egret
.
TouchEvent
.
TOUCH_TAP
,
()
=>
{
this
.
hidePanel
();
if
(
this
.
_level
+
1
<=
70
)
if
(
this
.
_level
+
1
<=
window
[
'total_level'
]
)
changeMapScene
({
level
:
this
.
_level
+
1
});
else
changeMapScene
();
...
...
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