Commit 442597b8 authored by wildfirecode's avatar wildfirecode

Merge branch 'dev' of gitlab2.dui88.com:wanghongyuan/xiaoxiaole into dev

parents de0618a7 cecf8f87
{"options":{"layoutMath":"2","sizeMode":"2n","useExtension":1,"layoutGap":1,"extend":0},"projectName":"scratch","version":5,"files":["../assets/scratch/scratch_bg.png","../assets/scratch/scratch_hongbao.png","../assets/scratch/scratch_help.png","../assets/scratch/scratch_progress_bg.png","../assets/scratch/scratch_wx_tip.png","../assets/scratch/scratchbg2.png","../assets/scratch/scratch_invite.png","../assets/scratch/scratch_card_90.png","../assets/scratch/scratch_card_96.png","../assets/scratch/scratch_card_94.png","../assets/scratch/scratch_card_98.png","../assets/scratch/scratch_user1.png","../assets/scratch/scratch_card_bg.png","../assets/scratch/scratch_card_92.png","../assets/scratch/scratch_user2.png"]}
\ No newline at end of file
{"options":{"layoutMath":"2","sizeMode":"2n","useExtension":1,"layoutGap":1,"extend":0},"projectName":"scratch","version":5,"files":["../assets/scratch/scratch_bg.png","../assets/scratch/scratch_hongbao.png","../assets/scratch/scratch_help.png","../assets/scratch/scratch_progress_bg.png","../assets/scratch/scratch_wx_tip.png","../assets/scratch/scratchbg2.png","../assets/scratch/scratch_invite.png","../assets/scratch/scratch_card_90.png","../assets/scratch/scratch_card_96.png","../assets/scratch/scratch_card_94.png","../assets/scratch/scratch_card_98.png","../assets/scratch/scratch_user1.png","../assets/scratch/scratch_card_bg.png","../assets/scratch/scratch_card_92.png","../assets/scratch/scratch_user2.png","../assets/scratch/scratch_mask.png"]}
\ No newline at end of file
......@@ -163,8 +163,6 @@ export default class MainScene extends Scene {
oneStepScore: number;
//果冻有消除的标记;
jellyBrokenMark: boolean;
//有毛球消失的动画时,延迟掉落时间
hairballBrokenMark: boolean;
/**
* 判断连通的状态
* 1表示存在小列连通到大列,从右往左遍历
......@@ -1710,15 +1708,13 @@ export default class MainScene extends Scene {
this.eliminate();
}, 200)
} else {
//没有可消除元素,执行掉落,又加定制,因为毛球的消失动画比较长 650ms,用500
var time = this.hairballBrokenMark ? 500 : 200;
this.hairballBrokenMark = false;
//没有可消除元素,执行掉落,
setTimeout(() => {
this.fall(() => {
//掉落停止回调
this.fallCallback();
});
}, time)
}, 200)
}
}
/**
......@@ -2053,8 +2049,6 @@ export default class MainScene extends Scene {
ele.setState(StateType.HAIRBALLGREY, false)
//算个数
this.goElementTarget(ElementType.HAIRBALLGREY, [ele.x, ele.y]);
//标记有毛球消失
this.hairballBrokenMark = true
}
//有黑色毛球的,一次眩晕,两次消失
else if (ele.hasState(StateType.HAIRBALLGREY)) {
......@@ -2071,8 +2065,6 @@ export default class MainScene extends Scene {
ele.setState(StateType.HAIRBALLBLACK, false)
//算个数
this.goElementTarget(ElementType.HAIRBALLBLACK, [ele.x, ele.y]);
//标记有毛球消失
this.hairballBrokenMark = true
}
}
//如果有特效,存下
......
......@@ -26,6 +26,7 @@ import ScratchIcon from "./icon/ScratchIcon";
import TurntableIcon from "./icon/TurntableIcon";
let doHelpFlag = false;
let doScratchHelpFlag = false;
// let adTag = false;
export default class MapScene extends Scene {
static adData;
......@@ -43,12 +44,12 @@ export default class MapScene extends Scene {
sendInvite() {
const code = Utils.getRequestByKey('shareCode');
if(!code) return;
const dojoin = DataManager.ins.getData('hc_doJoin');
if(!dojoin) return;
if(doHelpFlag) {
return;
}
if(code.indexOf("12345678") == -1){ // 邀请有礼
const dojoin = DataManager.ins.getData('hc_doJoin');
if(!dojoin) return;
NetManager.ins.doHelp((success, res) => {
doHelpFlag = true;
switch(true) {
......
......@@ -72,17 +72,16 @@ export default class ScratchIcon extends IconBase {
return;
}
let status = res.data.taskStatus;
let data = Utils.deepClone(res.data);
switch(true) {
case (status == 0): // 当前无任务(一般icon不会出现),拦截
break;
case (status == 1): // 当前任务进行中 打开任务面板
loadSvga(getResPath() + 'resource/assets/svgas/sprize.svga').then(async (mv: any) => {
// await wait(100);
let data = Utils.deepClone(res.data);
data.mv = mv;
PanelCtrl.instance.show('scratch', data);
});
// PanelCtrl.instance.show('scratch', res.data);
break;
case (status == 2): // 当前任务完成待领奖 请求领奖接口
NetManager.ins.scratchTakePrize((success, res) => {
......@@ -92,7 +91,7 @@ export default class ScratchIcon extends IconBase {
}
return;
}
PanelCtrl.instance.show("scratchPrize", res.data);
PanelCtrl.instance.show("scratchPrize", data);
}, res.data.scratchCardTaskId);
break;
......
......@@ -188,25 +188,6 @@ export default class ScratchPanel extends Panel {
let dProgress = Math.abs(progress - this["progress"].width / this["progressBg"].width); // 比当前进度的差值的绝对值
let _duration = 1000 * dProgress / 100; // 算出变化的时间
egret.Tween.get(this["progress"]).to({width: _width}, _duration);
let i = new eui.Image();
// if(progress >= 100) {
// this["scratch_progress"].visible = false;
// } else if(progress >= 98 && progress < 100) {
// this["scratch_progress"].visible = true;
// this["scratch_progress"].source = "scratch_card_98_png";
// } else if(progress >= 96 && progress < 98) {
// this["scratch_progress"].visible = true;
// this["scratch_progress"].source = "scratch_card_96_png";
// } else if(progress >= 94 && progress < 96) {
// this["scratch_progress"].visible = true;
// this["scratch_progress"].source = "scratch_card_94_png";
// } else if(progress >= 92 && progress < 96) {
// this["scratch_progress"].visible = true;
// this["scratch_progress"].source = "scratch_card_92_png";
// } else if(progress < 92) {
// this["scratch_progress"].visible = true;
// this["scratch_progress"].source = "scratch_card_90_png";
// }
}
private setWXShareTip() {
......
......@@ -2,17 +2,17 @@
"success": true,
"code": "0000000000",
"desc": "OK",
"timestamp": 1572405066301,
"timestamp": 1572420059060,
"data": {
"scratchCardTaskId": 1,
"taskStatus": 1,
"scratchCardTaskId": 3,
"taskStatus": 2,
"prizeImage": "//yun.dui88.com/images/201910/9u6nk8sjt8.jpg",
"currentTime": 1572405066290,
"endTime": 1572491337000,
"completePercent": "96",
"remainPercent": "9.0",
"currentTime": 1572420059060,
"endTime": 1572493282000,
"completePercent": "100",
"remainPercent": "0",
"totalNeedCount": 1,
"helpedCount": 0,
"avatarList": []
"helpedCount": 1,
"avatarList": null
}
}
\ No newline at end of file
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