Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
shuijf2
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
shuijf2
Commits
502498b2
Commit
502498b2
authored
Jun 27, 2019
by
wildfirecode
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
dbff5354
Changes
14
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
103 additions
and
128 deletions
+103
-128
.DS_Store
.DS_Store
+0
-0
main.scene
assets/scenes/main.scene
+1
-1
PrizeDialogContent.ts
assets/scripts/dialogs/PrizeDialogContent.ts
+7
-5
ScoreDialogContent.ts
assets/scripts/dialogs/ScoreDialogContent.ts
+17
-8
ScenePlay.ts
assets/scripts/scenes/ScenePlay.ts
+1
-1
SceneStart.ts
assets/scripts/scenes/SceneStart.ts
+19
-12
rankbg.jpg
assets/singles/rankbg.jpg
+0
-0
bundle.js
debug/bundle.js
+42
-43
bundle.js.map
debug/bundle.js.map
+1
-1
.DS_Store
dist/.DS_Store
+0
-0
fuck.html
fuck.html
+5
-2
manifest.1.json
manifest.1.json
+0
-28
manifest.json
manifest.json
+2
-2
rankInfo.json
mock/customActivity/sjf/activity/rankInfo.json
+8
-25
No files found.
.DS_Store
View file @
502498b2
No preview for this file type
assets/scenes/main.scene
View file @
502498b2
...
...
@@ -486,7 +486,7 @@
"uuid": "1fb25a95-98c0-4f3c-9ae9-e8d4e67adf79"
}
],
"disabled":
fals
e
"disabled":
tru
e
},
{
"name": "ScenePlay",
...
...
assets/scripts/dialogs/PrizeDialogContent.ts
View file @
502498b2
...
...
@@ -8,11 +8,12 @@ import { TextureRenderer } from "scilla-components/src";
import
{
AssetsManager
,
createTexture
,
EngineConfig
,
Entity
,
Texture
,
dynamic
}
from
"scilla/src"
;
import
DialogContent
from
"../popup/DialogContent"
;
import
{
setScale
,
setText
}
from
"../transformUtils"
;
import
{
getRecordURL
}
from
"./ScoreDialogContent"
;
export
default
class
PrizeDialogContent
extends
DialogContent
{
pic
:
Entity
;
name
:
Entity
;
title
:
Entity
;
name
:
Entity
;
title
:
Entity
;
private
loadImage
=
(
url
:
string
):
Promise
<
HTMLImageElement
>
=>
{
return
new
Promise
<
HTMLImageElement
>
((
resolve
,
reject
)
=>
{
...
...
@@ -36,8 +37,9 @@ export default class PrizeDialogContent extends DialogContent {
return
texture
;
}
onClick_usebtn
(){
onClick_usebtn
()
{
// window.location.href=this.getOrderStatus.lottery.link
window
.
location
.
href
=
getRecordURL
();
}
onAwake
()
{
...
...
@@ -45,8 +47,8 @@ export default class PrizeDialogContent extends DialogContent {
}
async
setup
(
data
:
any
=
{})
{
setText
(
this
.
name
,
data
.
prizeName
);
setText
(
this
.
title
,
this
.
getTypeStr
(
data
.
prizeType
))
setText
(
this
.
name
,
data
.
prizeName
);
setText
(
this
.
title
,
this
.
getTypeStr
(
data
.
prizeType
))
const
texRender
=
this
.
pic
.
getComponent
(
TextureRenderer
);
const
texture
=
await
this
.
loadTexture
(
data
.
prizeImage
);
texRender
.
texture
=
texture
;
...
...
assets/scripts/dialogs/ScoreDialogContent.ts
View file @
502498b2
...
...
@@ -26,14 +26,23 @@ export default class ScoreDialogContent extends DialogContent {
onclick_ranbtn
()
{
this
.
hide
();
this
.
broadcast
(
'callApi'
,
1
,
'rankInfo'
,
{
weddingId
:
window
[
'CFG'
].
weddingId
,
activityId
:
window
[
'CFG'
].
activityId
})
// this.broadcast('callApi', 1, 'rankInfo', {
// weddingId: window['CFG'].weddingId,
// activityId: window['CFG'].activityId
// })
window
.
location
.
href
=
getRankURL
();
}
onResponse_rank1
()
{
console
.
log
(
'score dialog content,onResponse_rank'
)
this
.
bubbling
(
'fuckNavigator'
,
'result'
);
}
// onResponse_rank1() {
// console.log('score dialog content,onResponse_rank')
// this.bubbling('fuckNavigator', 'result');
// }
}
export
const
getRankURL
=
()
=>
{
return
`/customActivity/sjf/activity/recordIndex?weddingId=
${
window
[
'CFG'
].
weddingId
}
&activityId=
${
window
[
'CFG'
].
activityId
}
&brickType=7`
}
export
const
getRecordURL
=
()
=>
{
return
`/customActivity/sjf/activity/recordIndex?weddingId=
${
window
[
'CFG'
].
weddingId
}
&activityId=
${
window
[
'CFG'
].
activityId
}
&brickType=6`
;
}
assets/scripts/scenes/ScenePlay.ts
View file @
502498b2
...
...
@@ -17,7 +17,7 @@ export default class ScenePlay extends ScillaComponent implements INavigatorView
box1
:
Entity
;
box2
:
Entity
;
box3
:
Entity
;
private
COUNT_DOWN_SEC
=
4
;
private
COUNT_DOWN_SEC
=
window
[
'COUNT_DOWN_SEC'
]
;
private
_startTag
=
false
;
private
_msPassed
=
0
;
private
_ballCounter
=
0
;
...
...
assets/scripts/scenes/SceneStart.ts
View file @
502498b2
...
...
@@ -8,6 +8,7 @@ import { dynamic, Entity } from "scilla/src";
import
{
alien
}
from
"../navigator/StackNavigator"
;
import
{
INavigatorViewBase
}
from
"../navigator/VirtualNavigator"
;
import
{
setText
,
setRotation
,
getRotation
}
from
"../transformUtils"
;
import
{
getRankURL
,
getRecordURL
}
from
"../dialogs/ScoreDialogContent"
;
export
default
class
SceneStart
extends
ScillaComponent
implements
INavigatorViewBase
{
doJoin
:
dynamic
;
...
...
@@ -66,17 +67,21 @@ export default class SceneStart extends ScillaComponent implements INavigatorVie
}
onResponse_rankInfo2
(
data
)
{
if
(
data
.
openPrize
)
{
//开奖了,都是线下奖品
if
(
data
.
openPrize
&&
data
.
score
>
0
)
{
//开奖了,都是线下奖品
let
prize
;
window
[
'CFG'
].
activity
.
prizeList
.
forEach
(
p
=>
{
if
(
p
.
prizeType
==
data
.
prizeType
)
prize
=
p
;
});
if
(
!
window
.
localStorage
.
getItem
(
'prizeShowed'
))
{
if
(
prize
)
//中奖了
this
.
bubbling
(
'showDialog'
,
'Prize'
,
prize
);
else
this
.
bubbling
(
'showDialog'
,
'Alert'
,
'您与奖品擦肩而过~'
);
}
window
.
localStorage
.
setItem
(
'prizeShowed'
,
'1'
)
}
}
updateCountTxt
()
{
...
...
@@ -88,7 +93,7 @@ export default class SceneStart extends ScillaComponent implements INavigatorVie
}
if
(
limit
<
0
)
limit
=
0
;
setText
(
this
.
countTxt
,
`剩余
可抽奖次数为
${
limit
}
`
);
setText
(
this
.
countTxt
,
`剩余
次数:
${
limit
}
`
);
}
initGameStage
()
{
console
.
log
(
'initGameStage'
)
...
...
@@ -148,11 +153,12 @@ export default class SceneStart extends ScillaComponent implements INavigatorVie
}
onClick_rankbtn
()
{
this
.
rankbtn
.
getComponent
(
Button
).
enabled
=
false
;
this
.
broadcast
(
'callApi'
,
1
,
'rankInfo'
,
{
weddingId
:
window
[
'CFG'
].
weddingId
,
activityId
:
window
[
'CFG'
].
activityId
})
window
.
location
.
href
=
getRankURL
();
// this.rankbtn.getComponent(Button).enabled = false;
// this.broadcast('callApi', 1, 'rankInfo', {
// weddingId: window['CFG'].weddingId,
// activityId: window['CFG'].activityId
// })
}
onResponse_rank
()
{
...
...
@@ -161,7 +167,8 @@ export default class SceneStart extends ScillaComponent implements INavigatorVie
}
onClick_recordbtn
()
{
alert
(
'onClick_recordbtn'
)
// alert('onClick_recordbtn')
window
.
location
.
href
=
getRecordURL
();
// globalEvent.emit('alert', {title: 'Success', content: 'You complete this puzzle', button: 'Next level'}, this.onAlertClose);
}
...
...
assets/singles/rankbg.jpg
View replaced file @
dbff5354
View file @
502498b2
40.8 KB
|
W:
|
H:
41.3 KB
|
W:
|
H:
2-up
Swipe
Onion skin
debug/bundle.js
View file @
502498b2
...
...
@@ -7176,7 +7176,7 @@
__extends
(
ScenePlay
,
_super
);
function
ScenePlay
()
{
var
_this_1
=
_super
!==
null
&&
_super
.
apply
(
this
,
arguments
)
||
this
;
_this_1
.
COUNT_DOWN_SEC
=
4
;
_this_1
.
COUNT_DOWN_SEC
=
window
[
'COUNT_DOWN_SEC'
]
;
_this_1
.
_startTag
=
false
;
_this_1
.
_msPassed
=
0
;
_this_1
.
_ballCounter
=
0
;
...
...
@@ -7489,6 +7489,35 @@
return
SceneResult
;
}(
ScillaComponent
));
var
ScoreDialogContent
=
(
function
(
_super
)
{
__extends
(
ScoreDialogContent
,
_super
);
function
ScoreDialogContent
()
{
return
_super
!==
null
&&
_super
.
apply
(
this
,
arguments
)
||
this
;
}
ScoreDialogContent
.
prototype
.
onAwake
=
function
()
{
_super
.
prototype
.
onAwake
.
call
(
this
);
};
ScoreDialogContent
.
prototype
.
setup
=
function
(
data
)
{
if
(
data
===
void
0
)
{
data
=
{};
}
setText
(
this
.
content
,
"
\
u606D
\
u559C
\
u4F60
\
u5171
\
u6447
\
u51FA"
+
data
+
"
\
u9897
\
u7CD6
\
u679C"
);
};
ScoreDialogContent
.
prototype
.
onTapCloseButton
=
function
()
{
_super
.
prototype
.
onTapCloseButton
.
call
(
this
);
this
.
bubbling
(
'fuckNavigator'
,
'start'
);
};
ScoreDialogContent
.
prototype
.
onclick_ranbtn
=
function
()
{
this
.
hide
();
window
.
location
.
href
=
getRankURL
();
};
return
ScoreDialogContent
;
}(
DialogContent
));
var
getRankURL
=
function
()
{
return
"/customActivity/sjf/activity/recordIndex?weddingId="
+
window
[
'CFG'
].
weddingId
+
"&activityId="
+
window
[
'CFG'
].
activityId
+
"&brickType=7"
;
};
var
getRecordURL
=
function
()
{
return
"/customActivity/sjf/activity/recordIndex?weddingId="
+
window
[
'CFG'
].
weddingId
+
"&activityId="
+
window
[
'CFG'
].
activityId
+
"&brickType=6"
;
};
var
SceneStart
=
(
function
(
_super
)
{
__extends
(
SceneStart
,
_super
);
function
SceneStart
()
{
...
...
@@ -7536,17 +7565,20 @@
setRotation
(
this
.
box
,
0
);
};
SceneStart
.
prototype
.
onResponse_rankInfo2
=
function
(
data
)
{
if
(
data
.
openPrize
)
{
if
(
data
.
openPrize
&&
data
.
score
>
0
)
{
var
prize_1
;
window
[
'CFG'
].
activity
.
prizeList
.
forEach
(
function
(
p
)
{
if
(
p
.
prizeType
==
data
.
prizeType
)
prize_1
=
p
;
});
if
(
!
window
.
localStorage
.
getItem
(
'prizeShowed'
))
{
if
(
prize_1
)
this
.
bubbling
(
'showDialog'
,
'Prize'
,
prize_1
);
else
this
.
bubbling
(
'showDialog'
,
'Alert'
,
'您与奖品擦肩而过~'
);
}
window
.
localStorage
.
setItem
(
'prizeShowed'
,
'1'
);
}
};
SceneStart
.
prototype
.
updateCountTxt
=
function
()
{
var
limit
=
0
;
...
...
@@ -7558,7 +7590,7 @@
}
if
(
limit
<
0
)
limit
=
0
;
setText$1
(
this
.
countTxt
,
"
\
u5269
\
u4F59
\
u
53EF
\
u62BD
\
u5956
\
u6B21
\
u6570
\
u4E3
A"
+
limit
);
setText$1
(
this
.
countTxt
,
"
\
u5269
\
u4F59
\
u
6B21
\
u6570
\
uFF1
A"
+
limit
);
};
SceneStart
.
prototype
.
initGameStage
=
function
()
{
console
.
log
(
'initGameStage'
);
...
...
@@ -7603,18 +7635,14 @@
this
.
bubbling
(
'showDialog'
,
'Rule'
);
};
SceneStart
.
prototype
.
onClick_rankbtn
=
function
()
{
this
.
rankbtn
.
getComponent
(
Button
).
enabled
=
false
;
this
.
broadcast
(
'callApi'
,
1
,
'rankInfo'
,
{
weddingId
:
window
[
'CFG'
].
weddingId
,
activityId
:
window
[
'CFG'
].
activityId
});
window
.
location
.
href
=
getRankURL
();
};
SceneStart
.
prototype
.
onResponse_rank
=
function
()
{
this
.
bubbling
(
'fuck'
,
'result'
);
this
.
rankbtn
.
getComponent
(
Button
).
enabled
=
true
;
};
SceneStart
.
prototype
.
onClick_recordbtn
=
function
()
{
alert
(
'onClick_recordbtn'
);
window
.
location
.
href
=
getRecordURL
(
);
};
SceneStart
.
prototype
.
onDidEnter
=
function
(
last
,
action
,
parameters
)
{
this
.
entity
.
enabled
=
true
;
...
...
@@ -8595,6 +8623,7 @@
return
_this
;
}
PrizeDialogContent
.
prototype
.
onClick_usebtn
=
function
()
{
window
.
location
.
href
=
getRecordURL
();
};
PrizeDialogContent
.
prototype
.
onAwake
=
function
()
{
_super
.
prototype
.
onAwake
.
call
(
this
);
...
...
@@ -8643,36 +8672,6 @@
return
PrizeDialogContent
;
}(
DialogContent
));
var
ScoreDialogContent
=
(
function
(
_super
)
{
__extends
(
ScoreDialogContent
,
_super
);
function
ScoreDialogContent
()
{
return
_super
!==
null
&&
_super
.
apply
(
this
,
arguments
)
||
this
;
}
ScoreDialogContent
.
prototype
.
onAwake
=
function
()
{
_super
.
prototype
.
onAwake
.
call
(
this
);
};
ScoreDialogContent
.
prototype
.
setup
=
function
(
data
)
{
if
(
data
===
void
0
)
{
data
=
{};
}
setText
(
this
.
content
,
"
\
u606D
\
u559C
\
u4F60
\
u5171
\
u6447
\
u51FA"
+
data
+
"
\
u9897
\
u7CD6
\
u679C"
);
};
ScoreDialogContent
.
prototype
.
onTapCloseButton
=
function
()
{
_super
.
prototype
.
onTapCloseButton
.
call
(
this
);
this
.
bubbling
(
'fuckNavigator'
,
'start'
);
};
ScoreDialogContent
.
prototype
.
onclick_ranbtn
=
function
()
{
this
.
hide
();
this
.
broadcast
(
'callApi'
,
1
,
'rankInfo'
,
{
weddingId
:
window
[
'CFG'
].
weddingId
,
activityId
:
window
[
'CFG'
].
activityId
});
};
ScoreDialogContent
.
prototype
.
onResponse_rank1
=
function
()
{
console
.
log
(
'score dialog content,onResponse_rank'
);
this
.
bubbling
(
'fuckNavigator'
,
'result'
);
};
return
ScoreDialogContent
;
}(
DialogContent
));
var
Icon
=
(
function
(
_super
)
{
__extends
(
Icon
,
_super
);
function
Icon
()
{
...
...
debug/bundle.js.map
View file @
502498b2
This diff is collapsed.
Click to expand it.
dist/.DS_Store
View file @
502498b2
No preview for this file type
fuck.html
View file @
502498b2
...
...
@@ -10,6 +10,8 @@
<body
duiba-page-id=
"4"
>
<meta
name=
"viewport"
content=
"width=device-width,initial-scale=1, minimum-scale=1, maximum-scale=1, user-scalable=no"
/>
<meta
name=
"apple-mobile-web-app-capable"
content=
"yes"
/>
...
...
@@ -21,12 +23,13 @@
<div
id=
"gameContainer"
style=
"width: 100%;height: 100%;overflow: hidden;"
></div>
<script
src=
"//yun.duiba.com.cn/db_games/zepto.min.js"
></script>
<script
src=
"//yun.duiba.com.cn/db_games/security.js"
></script>
<script
src=
"//yun.duiba.com.cn/db_games/15616
16731
/bundle.js"
></script>
<script
src=
"//yun.duiba.com.cn/db_games/15616
30480
/bundle.js"
></script>
<script>
setTimeout
(
function
()
{
var
loadingEl
=
document
.
getElementById
(
'loading'
);
function
onProcess
(
p
)
{
if
(
p
>=
1
)
{
loadingEl
.
style
.
display
=
'none'
;
}
}
var
options
=
{
resPath
:
"//yun.duiba.com.cn/db_games/15616
16731
/"
};
window
[
'shuijf'
].
startup
(
document
.
getElementById
(
'gameContainer'
),
options
,
onProcess
);
var
options
=
{
resPath
:
"//yun.duiba.com.cn/db_games/15616
26859
/"
};
window
[
'shuijf'
].
startup
(
document
.
getElementById
(
'gameContainer'
),
options
,
onProcess
);
},
100
);
window
[
'COUNT_DOWN_SEC'
]
=
10
;
window
[
'ruleContent'
]
=
'starttttttt<br>第1行第1行第1行第1行第1行第1行第1行第1行第1行第1行第1行第1行第1行第1行<br>第2行<br>第3行<br>第4行<br>第5行<br>第6行<br>第7行<br>第1行<br>第2行<br>第3行<br>第4行<br>第5行<br>第6行<br>第7行endddddd'
;
</script>
...
...
manifest.1.json
deleted
100755 → 0
View file @
dbff5354
{
"name"
:
"shuijf"
,
"engineConfig"
:
{
"fps"
:
63
,
"designWidth"
:
750
,
"designHeight"
:
1624
,
"scaleMode"
:
"fixedWidth"
,
"modifyCanvasSize"
:
false
,
"resPath"
:
""
},
"customConfig"
:
{
"scene"
:
{
"scenes"
:
{
"main"
:
"scenes/main.scene"
},
"entryScene"
:
"main"
},
"webServiceUrl-"
:
"http://10.10.93.204:7555 http://localhost:3010"
,
"webServiceUrl"
:
"http://localhost:4001"
,
"webServiceUrl2"
:
"http://localhost:4001"
},
"dataCenterConfig"
:
{
"dataCenterRoot"
:
[
"API"
,
"CFG"
]
}
}
manifest.json
View file @
502498b2
...
...
@@ -16,8 +16,8 @@
"entryScene"
:
"main"
},
"webServiceUrl-"
:
"http://10.10.93.204:7555 http://localhost:3010"
,
"webServiceUrl"
:
""
,
"webServiceUrl
3
"
:
"http://localhost:4001"
"webServiceUrl"
:
"
http://localhost:4001
"
,
"webServiceUrl
1
"
:
"http://localhost:4001"
},
"dataCenterConfig"
:
{
"dataCenterRoot"
:
[
...
...
mock/customActivity/sjf/activity/rankInfo.json
View file @
502498b2
...
...
@@ -2,32 +2,15 @@
"success"
:
true
,
"code"
:
null
,
"desc"
:
null
,
"timestamp"
:
15616
15572296
,
"timestamp"
:
15616
25108247
,
"data"
:
{
"openPrize"
:
false
,
"weiXinUid"
:
null
,
"nickName"
:
null
,
"avatar"
:
null
,
"score"
:
0
,
"rank"
:
"未上榜"
,
"prizeType"
:
1
,
"list"
:
[
{
"openPrize"
:
true
,
"weiXinUid"
:
"weiXinUid"
,
"nickName"
:
"nickName"
,
"avatar"
:
"nickName"
,
"appId"
:
null
,
"score"
:
105
,
"rank"
:
"1"
},
{
"weiXinUid"
:
"weiXinUid1"
,
"nickName"
:
"nickName1"
,
"avatar"
:
"nickName1"
,
"appId"
:
null
,
"score"
:
4
,
"rank"
:
"2"
}
]
"score"
:
1
,
"rank"
:
"未上榜"
,
"prizeType"
:
null
,
"list"
:
[]
}
}
\ No newline at end of file
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