Commit 754ce332 authored by AU-Pro-mac's avatar AU-Pro-mac

add new code --06

parent 50d67c3b
......@@ -3,7 +3,7 @@
"data": {
"fakeUserName": "cccccccccc",
"fakeUserImgUrl": "https://yun.duiba.com.cn/spark-dev/assets/白色.41dae4fd01f4750aea58f694b40d97a9da8f23ca.png",
"win": false,
"win": true,
"userName": "xxxxxxxxxxx",
"userImgUrl": "https://yun.duiba.com.cn/spark-dev/assets/白色.41dae4fd01f4750aea58f694b40d97a9da8f23ca.png",
"isNewUser": false
......
......@@ -129,23 +129,26 @@ export default class Root extends FYGE.Container {
this.goodsContainer.removeAllGoods()
this.scoreBoard.stopTime()
if (this.userInfo.win && this.scoreBoard.scoreLeft) {
console.log('user win')
// 用户出了结果,请求开奖,并展示相应弹窗
// const gamePrizeRes = await sendTbNet(TbNetName.getPrizeInfo, {})
// let res = gamePrizeRes.data
// console.log('CSD-GAME over data:', res)
// showPanel(MatchingPanel, res)
if (this.userInfo.win) {
} else {
console.log('user fail')
}
// 用户出了结果,请求开奖,并展示相应弹窗
// const gamePrizeRes = await sendTbNet(TbNetName.getPrizeInfo, {})
// let res = gamePrizeRes.data
// console.log('CSD-GAME over data:', res)
// showPanel(MatchingPanel, res)
if (this.userInfo.win && this.scoreBoard.scoreLeft) {
//胜利
const prizeInfo = await sendTbNet(TbNetName.getPrizeInfo)
const prize = prizeInfo.data
console.log('user win --- CSD-GAME over data:', prizeInfo.data)
if (prize.type > 3) {
showPanel(SuccessPanel, prize)
} else {
showPanel(SuccessNoAwardPanel, prize)
}
} else {
//失败
console.log('user fail --- CSD-GAME over data:')
showPanel(FailedPanel)
}
// GDispatcher.dispatchEvent('gameOver-csd', {score: score})
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment