Commit 4711eb01 authored by wildfirecode13's avatar wildfirecode13

u

parent 381060c5
...@@ -5,19 +5,32 @@ ...@@ -5,19 +5,32 @@
"options": [ "options": [
{ {
"extra": null, "extra": null,
"optionId": "thanks", "optionId": "et esse laborum",
"optionImg": null, "optionImg": "https://yun.duiba.com.cn/db_games/sxbank.png",
"optionName": "谢谢参与", "optionName": "aliquip dolore qui nulla",
"position": null, "position": -13810392,
"prizeId": "thanks", "prizeId": "non labore eiusmod consequat",
"prizeType": 0, "prizeType": -25600732,
"ruleId": "ru_1", "ruleId": "fugiat minim in adipisicing",
"sendCount": 1, "sendCount": 3860338,
"url": null, "url": "eu veniam ipsum tempor",
"userRecordId": null "userRecordId": -15254782
},
{
"extra": null,
"optionId": "et esse laborum",
"optionImg": "https://yun.duiba.com.cn/db_games/sxbank.png",
"optionName": "aliquip dolore qui nulla",
"position": -13810392,
"prizeId": "non labore eiusmod consequat",
"prizeType": -25600732,
"ruleId": "fugiat minim in adipisicing",
"sendCount": 3860338,
"url": "eu veniam ipsum tempor",
"userRecordId": -15254782
} }
] ]
}, },
"message": null, "message": "12312312",
"success": true "success": 0
} }
\ No newline at end of file
...@@ -2,6 +2,97 @@ ...@@ -2,6 +2,97 @@
"code": null, "code": null,
"data": { "data": {
"options": [ "options": [
{
"degree": "10",
"icon": "//yun.dui88.com/projectxh5/credit-250-250.png",
"icon2": null,
"id": "oca13f7f4",
"index": 1,
"name": "积分",
"prizeId": "sss_2",
"prizeType": 2,
"refId": "",
"refType": "increase-credits",
"sendCount": 1
},
{
"degree": "10",
"icon": "//yun.dui88.com/projectxh5/credit-250-250.png",
"icon2": null,
"id": "oca13f7f4",
"index": 1,
"name": "积分",
"prizeId": "sss_2",
"prizeType": 2,
"refId": "",
"refType": "increase-credits",
"sendCount": 1
},
{
"degree": "10",
"icon": "//yun.dui88.com/projectxh5/credit-250-250.png",
"icon2": null,
"id": "oca13f7f4",
"index": 1,
"name": "积分",
"prizeId": "sss_2",
"prizeType": 2,
"refId": "",
"refType": "increase-credits",
"sendCount": 1
},
{
"degree": "10",
"icon": "//yun.dui88.com/projectxh5/credit-250-250.png",
"icon2": null,
"id": "oca13f7f4",
"index": 1,
"name": "积分",
"prizeId": "sss_2",
"prizeType": 2,
"refId": "",
"refType": "increase-credits",
"sendCount": 1
},
{
"degree": "10",
"icon": "//yun.dui88.com/projectxh5/credit-250-250.png",
"icon2": null,
"id": "oca13f7f4",
"index": 1,
"name": "积分",
"prizeId": "sss_2",
"prizeType": 2,
"refId": "",
"refType": "increase-credits",
"sendCount": 1
},
{
"degree": "10",
"icon": "//yun.dui88.com/projectxh5/credit-250-250.png",
"icon2": null,
"id": "oca13f7f4",
"index": 1,
"name": "积分",
"prizeId": "sss_2",
"prizeType": 2,
"refId": "",
"refType": "increase-credits",
"sendCount": 1
},
{
"degree": "10",
"icon": "//yun.dui88.com/projectxh5/credit-250-250.png",
"icon2": null,
"id": "oca13f7f4",
"index": 1,
"name": "积分",
"prizeId": "sss_2",
"prizeType": 2,
"refId": "",
"refType": "increase-credits",
"sendCount": 1
},
{ {
"degree": "10", "degree": "10",
"icon": "//yun.dui88.com/projectxh5/credit-250-250.png", "icon": "//yun.dui88.com/projectxh5/credit-250-250.png",
...@@ -29,8 +120,8 @@ ...@@ -29,8 +120,8 @@
"sendCount": 1 "sendCount": 1
} }
], ],
"surplusCount": 10, "surplusCount": 1,
"credits": 235, "credits": 111111,
"needCredits": 110, "needCredits": 110,
"type": 1, "type": 1,
"isMember":1 "isMember":1
......
...@@ -720,5 +720,5 @@ export const ResJson = { ...@@ -720,5 +720,5 @@ export const ResJson = {
} }
} }
], ],
"path": "https://yun.duiba.com.cn/db_games/activity/template/1629083454/resource/" "path": "https://yun.duiba.com.cn/db_games/activity/template/1629096619/resource/"
} }
\ No newline at end of file
...@@ -15,14 +15,15 @@ let section; ...@@ -15,14 +15,15 @@ let section;
export class CostPanel extends Panel { export class CostPanel extends Panel {
start() { start() {
super.start(); super.start();
const cost = 1234567890; const indexResult = getWebData(WebNetName.index);
const cost = indexResult.data.needCredits;
getObject(this, "cost_tips").text = `消耗${cost}积分拆开1个盲盒`; getObject(this, "cost_tips").text = `消耗${cost}积分拆开1个盲盒`;
} }
cost_open() { cost_open() {
sendLog("click", 1); sendLog("click", 1);
this.dispatchEvent("stopIndexEnterFrame", {}); this.dispatchEvent("stopIndexEnterFrame", {});
this.hidePanel();
this.getPrize(); this.getPrize();
} }
...@@ -37,6 +38,7 @@ export class CostPanel extends Panel { ...@@ -37,6 +38,7 @@ export class CostPanel extends Panel {
if (indexResult.data.type == 1) { if (indexResult.data.type == 1) {
params.credits = indexResult.data.needCredits; params.credits = indexResult.data.needCredits;
result = await sendWebNet(WebNetName.getCreditCost, params); result = await sendWebNet(WebNetName.getCreditCost, params);
if(!result.success) return;
prizeData = await sendWebNetWithToken(WebNetName.drawPrize, { ticket: result.data }); prizeData = await sendWebNetWithToken(WebNetName.drawPrize, { ticket: result.data });
} }
else { else {
...@@ -49,6 +51,7 @@ export class CostPanel extends Panel { ...@@ -49,6 +51,7 @@ export class CostPanel extends Panel {
if (prizeData && prizeData.success) { if (prizeData && prizeData.success) {
if (prizeData.data && prizeData.data.options) { if (prizeData.data && prizeData.data.options) {
this.hidePanel();
if (prizeData.data.options[0].optionId == "thanks") { if (prizeData.data.options[0].optionId == "thanks") {
showPanel(NoPrizePanel) showPanel(NoPrizePanel)
} else { } else {
......
...@@ -36,8 +36,8 @@ export class getTimesPanel extends Panel { ...@@ -36,8 +36,8 @@ export class getTimesPanel extends Panel {
centerTextField(getObject(this,'getTimes_tips2'),496); centerTextField(getObject(this,'getTimes_tips2'),496);
centerTextField(getObject(this,'getTimes_tips1'),496); centerTextField(getObject(this,'getTimes_tips1'),496);
getObject(this,'getTimes_tips2').text = `12312313123次免费拆盒机会`; getObject(this,'getTimes_tips2').text = `次免费拆盒机会`;
getObject(this,'getTimes_tips1').text = `最多可增加11231231231次拆盒机会/天`; getObject(this,'getTimes_tips1').text = `最多可增加1次拆盒机会/天`;
} }
initEvents() { initEvents() {
......
...@@ -69,7 +69,7 @@ export class IndexScene extends Scene { ...@@ -69,7 +69,7 @@ export class IndexScene extends Scene {
this.addChild(hand); this.addChild(hand);
this.getIndex(); this.getIndex();
const result = getWebData(WebNetName.index) const result = getWebData(WebNetName.index)
const array = ['//yun.duiba.com.cn/spark/assets/1398924a1b804f0f20f9d3e16ed3158c2b3d686b.png','//yun.duiba.com.cn/spark/assets/1398924a1b804f0f20f9d3e16ed3158c2b3d686b.png','//yun.duiba.com.cn/spark/assets/1398924a1b804f0f20f9d3e16ed3158c2b3d686b.png','//yun.duiba.com.cn/spark/assets/1398924a1b804f0f20f9d3e16ed3158c2b3d686b.png','//yun.duiba.com.cn/spark/assets/1398924a1b804f0f20f9d3e16ed3158c2b3d686b.png']; const array = result.data.options.filter(i=>i.id!='thanks');
list.updateData(array); list.updateData(array);
hand && FYGE.Tween.get(hand, { loop: true }).to({ scaleX: 1.5, scaleY: 1.5 }, 1000).to({ scaleX: 1, scaleY: 1 }, 1000); hand && FYGE.Tween.get(hand, { loop: true }).to({ scaleX: 1.5, scaleY: 1.5 }, 1000).to({ scaleX: 1, scaleY: 1 }, 1000);
this.stage.addEventListener("restartEnterFrame", this.onRestartFrame, this); this.stage.addEventListener("restartEnterFrame", this.onRestartFrame, this);
......
...@@ -12,7 +12,9 @@ export class ScrollItem extends Item { ...@@ -12,7 +12,9 @@ export class ScrollItem extends Item {
this.addChild(contanier); this.addChild(contanier);
FYGE.GlobalLoader.loadImage((e, image) => { FYGE.GlobalLoader.loadImage((e, image) => {
const item = this.addChild(new FYGE.Sprite(FYGE.Texture.from(image))); const item = this.addChild(new FYGE.Sprite(FYGE.Texture.from(image)));
}, data); item.width=item.height=100;
item.x=item.y=11;
}, data.icon);
} }
} }
......
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