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
29cc45fd
Commit
29cc45fd
authored
Oct 31, 2019
by
wjf
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' of gitlab2.dui88.com:wanghongyuan/xiaoxiaole into dev
parents
7d3632c3
a0b23c3c
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
17 additions
and
18 deletions
+17
-18
MainBase.ts
egret/libs/new_wx/MainBase.ts
+0
-2
ScratchSkin.exml
egret/resource/skins/ScratchSkin.exml
+2
-3
TurntablePrize2Skin.exml
egret/resource/skins/TurntablePrize2Skin.exml
+1
-1
CutTimer.ts
egret/src/CutTimer.ts
+3
-1
TurntableIcon.ts
egret/src/mapScene/icon/TurntableIcon.ts
+1
-1
ScratchPanel.ts
egret/src/panels/ScratchPanel.ts
+5
-6
TurntablePrize2Panel.ts
egret/src/panels/TurntablePanel/TurntablePrize2Panel.ts
+3
-2
scratchGetTaskInfo.json
mock/happyclear/scratchGetTaskInfo.json
+1
-1
turnablebaseInfo.json
mock/happyclear/turnablebaseInfo.json
+1
-1
No files found.
egret/libs/new_wx/MainBase.ts
View file @
29cc45fd
...
...
@@ -351,8 +351,6 @@ export default class MainBase extends eui.UILayer {
loadSvga
(
getResPath
()
+
'resource/assets/svgas/turntable.svga'
);
loadSvga
(
getResPath
()
+
'resource/assets/svgas/turnprize.svga'
);
loadSvga
(
getResPath
()
+
'resource/assets/svgas/sprize.svga'
);
RES
.
getResAsync
(
'FZY4JW_TTF'
);
RES
.
getResAsync
(
'FZY3JW_1_TTF'
);
}
catch
(
e
)
{
console
.
error
(
e
);
...
...
egret/resource/skins/ScratchSkin.exml
View file @
29cc45fd
...
...
@@ -25,8 +25,7 @@
</e:Skin>
</e:skinName>
</e:Button>
<e:Label
id=
"cutTimeLabel"
text=
"23:43:21"
y=
"895.33"
size=
"28"
textColor=
"0xffffff"
fontFamily=
"FZY3JW"
bold=
"true"
x=
"310"
/>
<e:Label
text=
"将在 后失效"
y=
"895.33"
size=
"28"
textColor=
"0xFFFFFF"
fontFamily=
"FZY3JW"
horizontalCenter=
"0"
/>
<e:Label
id=
"cutTimeLabel"
text=
"23:43:21"
y=
"888.5"
size=
"28"
textColor=
"0xffffff"
fontFamily=
"FZY3JW"
verticalAlign=
"middle"
anchorOffsetX=
"0"
width=
"749"
textAlign=
"center"
horizontalCenter=
"0"
/>
<e:Label
text=
"帮刮\n记录"
y=
"805"
size=
"28"
textColor=
"0xFFFFFF"
horizontalCenter=
"-248"
/>
<e:Scroller
width=
"487"
height=
"90"
y=
"783"
anchorOffsetX=
"0"
anchorOffsetY=
"0"
horizontalCenter=
"32.5"
>
<e:Group
anchorOffsetX=
"0"
y=
"2"
>
...
...
@@ -49,7 +48,7 @@
<e:Group
id=
"progressGroup"
x=
"8"
verticalCenter=
"0"
>
<e:Image
id=
"progressBg"
source=
"scratch_progress_bg_png"
anchorOffsetX=
"0"
anchorOffsetY=
"0"
x=
"0"
y=
"0"
width=
"437"
height=
"22"
/>
<e:Rect
id=
"progress"
fillColor=
"0xeb1917"
left=
"0"
verticalCenter=
"0"
width=
"0"
top=
"0"
bottom=
"0"
/>
<e:Label
id=
"progressLabel"
text=
"仅剩90.7%"
size=
"18"
verticalCenter=
"2"
bold=
"true"
verticalAlign=
"middle"
textAlign=
"center"
fontFamily=
"FZY3JW"
horizontalCenter=
"0"
/>
<e:Label
id=
"progressLabel"
text=
"仅剩90.7%"
size=
"18"
verticalCenter=
"2"
verticalAlign=
"middle"
textAlign=
"center"
fontFamily=
"FZY3JW"
horizontalCenter=
"0"
/>
</e:Group>
<e:Image
id=
"hongbao"
source=
"scratch_hongbao_png"
scaleX=
"1"
scaleY=
"1"
verticalCenter=
"0"
horizontalCenter=
"219"
/>
</e:Group>
...
...
egret/resource/skins/TurntablePrize2Skin.exml
View file @
29cc45fd
...
...
@@ -21,7 +21,7 @@
<e:Group
id=
"progressGroup"
x=
"8"
verticalCenter=
"0"
>
<e:Image
id=
"progressBg"
source=
"scratch_progress_bg_png"
anchorOffsetX=
"0"
anchorOffsetY=
"0"
x=
"0"
y=
"0"
width=
"437"
height=
"22"
/>
<e:Rect
id=
"progress"
fillColor=
"0xEB1917"
left=
"0"
verticalCenter=
"0"
width=
"0"
top=
"0"
bottom=
"0"
/>
<e:Label
id=
"progressLabel"
text=
"仅剩90.7%"
size=
"18"
bold=
"true"
verticalAlign=
"middle"
textAlign=
"center"
horizontalCenter=
"0"
verticalCenter=
"0"
fontFamily=
"FZY3JW"
/>
<e:Label
id=
"progressLabel"
text=
"仅剩90.7%"
size=
"18"
verticalAlign=
"middle"
textAlign=
"center"
horizontalCenter=
"0"
verticalCenter=
"0"
fontFamily=
"FZY3JW"
/>
</e:Group>
<e:Image
id=
"hongbao"
source=
"scratch_hongbao_png"
scaleX=
"1"
scaleY=
"1"
verticalCenter=
"0"
horizontalCenter=
"219"
/>
</e:Group>
...
...
egret/src/CutTimer.ts
View file @
29cc45fd
import
{
HtmlTextParser
}
from
"../libs/new_wx/HtmlTextParser"
;
/**
* 简单的倒计时
* Created on 2019/10/24
...
...
@@ -109,7 +111,7 @@ export default class CutTimer {
str
=
str
.
replace
(
/hh/g
,
timer
.
hour
);
str
=
str
.
replace
(
/mm/g
,
timer
.
min
);
str
=
str
.
replace
(
/ss/g
,
timer
.
sec
);
this
.
_label
.
text
=
str
;
this
.
_label
.
text
Flow
=
(
new
HtmlTextParser
).
parser
(
str
)
;
}
/**
...
...
egret/src/mapScene/icon/TurntableIcon.ts
View file @
29cc45fd
...
...
@@ -29,7 +29,6 @@ export default class TurntableIcon extends IconBase {
this
.
visible
=
false
;
return
;
}
this
.
visible
=
true
;
let
data
=
res
.
data
;
if
(
data
.
remainTimes
>
0
||
(
getHomeData
().
wealth
>
data
.
nextTimeNeedCoin
))
{
this
.
tipsVisible
=
true
;
...
...
@@ -37,6 +36,7 @@ export default class TurntableIcon extends IconBase {
}
else
{
this
.
tipsVisible
=
false
;
}
this
.
visible
=
res
.
data
.
luckyDrawInfo
.
enable
;
})
}
...
...
egret/src/panels/ScratchPanel.ts
View file @
29cc45fd
...
...
@@ -5,10 +5,8 @@ import { NetManager } from "../../libs/tw/manager/NetManager";
import
{
iswx
}
from
"../iswx"
;
import
ScratchRulePanel
from
"./ScratchRulePanel"
;
import
CutTimer
from
"../CutTimer"
;
import
Utils
from
"../Utils"
;
import
{
DataManager
}
from
"../../libs/tw/manager/DataManager"
;
import
GradientType
=
egret
.
GradientType
;
import
{
getlogItem
}
from
"../Main"
;
import
{
HtmlTextParser
}
from
"../../libs/new_wx/HtmlTextParser"
;
export
default
class
ScratchPanel
extends
Panel
{
private
cutTimer
:
CutTimer
;
...
...
@@ -160,7 +158,7 @@ export default class ScratchPanel extends Panel {
this
.
setProgress
(
+
this
.
data
.
completePercent
);
// 倒计时
this
.
cutTimer
=
new
CutTimer
(
this
[
"cutTimeLabel"
],
"
hh:mm:ss
"
,
()
=>
{
this
.
cutTimer
=
new
CutTimer
(
this
[
"cutTimeLabel"
],
"
将在<b>hh:mm:ss</b>失效
"
,
()
=>
{
this
.
hidePanel
();
GDispatcher
.
dispatchEvent
(
"updateScratchTips"
);
}
...
...
@@ -182,8 +180,9 @@ export default class ScratchPanel extends Panel {
}
else
if
(
progress
<
0
)
{
progress
=
0
;
}
this
[
'numLabel'
].
text
=
`共
${
2
+
this
.
data
.
helpedCount
}
位好友帮你刮了
${
progress
.
toFixed
(
2
)}
%`
;
this
[
"progressLabel"
].
text
=
`仅剩
${(
100
-
progress
).
toFixed
(
2
)}
%`
;
// 进度条文字
this
[
'numLabel'
].
textFlow
=
(
new
HtmlTextParser
).
parser
(
`共<b>
${
2
+
this
.
data
.
helpedCount
}
</b>位好友帮你刮了<b>
${
progress
.
toFixed
(
2
)}
</b>%`
)
;
this
[
"progressLabel"
].
textFlow
=
(
new
HtmlTextParser
).
parser
(
`仅剩<b>
${(
100
-
progress
).
toFixed
(
2
)}
</b>%`
);
// 进度条文字
let
_width
=
this
[
"progressBg"
].
width
*
progress
/
100
;
// 宽度
let
dProgress
=
Math
.
abs
(
progress
-
this
[
"progress"
].
width
/
this
[
"progressBg"
].
width
);
// 比当前进度的差值的绝对值
let
_duration
=
1000
*
dProgress
/
100
;
// 算出变化的时间
...
...
egret/src/panels/TurntablePanel/TurntablePrize2Panel.ts
View file @
29cc45fd
...
...
@@ -8,6 +8,7 @@ import CutTimer from "../../CutTimer";
import
Utils
from
"../../Utils"
;
import
{
getlogItem
}
from
"../../Main"
;
import
{
showToast
}
from
"../../../libs/new_wx/ctrls/toastCtrl"
;
import
{
HtmlTextParser
}
from
"../../../libs/new_wx/HtmlTextParser"
;
export
default
class
TurnPrize2Panel
extends
Panel
{
...
...
@@ -75,8 +76,8 @@ export default class TurnPrize2Panel extends Panel {
}
else
if
(
progress
<
0
)
{
progress
=
0
;
}
this
[
"progressLabel"
].
text
=
`仅剩
${(
100
-
progress
).
toFixed
(
2
)}
%`
;
// 进度条文字
this
[
"progressLabel"
].
text
Flow
=
(
new
HtmlTextParser
).
parser
(
`仅剩<b>
${(
100
-
progress
).
toFixed
(
2
)}
</b>%`
)
;
// 进度条文字
const
_width
=
this
[
"progressBg"
].
width
*
progress
/
100
;
// 宽度
const
dProgress
=
Math
.
abs
(
progress
-
this
[
"progress"
].
width
/
this
[
"progressBg"
].
width
);
// 比当前进度的差值的绝对值
const
_duration
=
1000
*
dProgress
/
100
;
// 算出变化的时间
...
...
mock/happyclear/scratchGetTaskInfo.json
View file @
29cc45fd
...
...
@@ -9,7 +9,7 @@
"prizeImage"
:
"//yun.dui88.com/images/201910/gxqaecxymq.jpg"
,
"currentTime"
:
1572427313215
,
"endTime"
:
1572513706000
,
"completePercent"
:
"9
1.0
"
,
"completePercent"
:
"9
9
"
,
"remainPercent"
:
"9.0"
,
"totalNeedCount"
:
1
,
"helpedCount"
:
0
,
...
...
mock/happyclear/turnablebaseInfo.json
View file @
29cc45fd
...
...
@@ -8,7 +8,7 @@
"costCoinJoinTimes"
:
0
,
"nextTimeNeedCoin"
:
20
,
"luckyDrawInfo"
:
{
"enable"
:
tru
e
,
"enable"
:
fals
e
,
"id"
:
null
,
"baseCount"
:
20
,
"bonusCount"
:
0
,
...
...
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