Commit 485b3e90 authored by haiyoucuv's avatar haiyoucuv

按钮放反了

parent 28894b9f
This diff is collapsed.
......@@ -20889,6 +20889,9 @@ var SuccessStarGroup = (function (_super) {
var time2 = 100;
var max = 3;
var interval = 100;
if (count < 1) {
return;
}
Tween.get(this.leftStarEn)
.wait(wait)
.set({ scaleX: max, scaleY: max })
......@@ -21307,11 +21310,12 @@ var TaskItem = (function (_super) {
});
break;
case TaskType.follow:
Main_1.GDispatcher.removeAllEventListenerByType(TaoBaoNet_1.TbNetName.favorShop);
TaoBaoNet_1.sendTbNet(TaoBaoNet_1.TbNetName.favorShop, {}, function (fs, fr) {
if (!fs)
return;
TaoBaoNet_1.sendTbNet(TaoBaoNet_1.TbNetName.doFollowTask, { taskType: _this.data.taskType }, function (cs, cr) { return Main_1.GDispatcher.dispatchEvent(G_EVENT_1.G_EVENT.UPDATE_TASK); });
});
}, true);
break;
case TaskType.invites:
TaoBaoNet_1.sendTbNet(TaoBaoNet_1.TbNetName.addStats, { type: 'invite' });
......@@ -23839,14 +23843,20 @@ var MusicBtn = (function (_super) {
if (isOn)
TaoBaoNet_1.sendTbNet(TaoBaoNet_1.TbNetName.openMusic, { isOn: true });
Main_1.GDispatcher.addEventListener(G_EVENT_1.G_EVENT.ON_SHOW, _this.onShow, _this);
Main_1.GDispatcher.addEventListener(G_EVENT_1.G_EVENT.ON_HIDE, _this.onHide, _this);
return _this;
}
MusicBtn.prototype.onShow = function () {
if (isOn)
TaoBaoNet_1.sendTbNet(TaoBaoNet_1.TbNetName.openMusic, { isOn: true });
};
MusicBtn.prototype.onHide = function () {
if (isOn)
TaoBaoNet_1.sendTbNet(TaoBaoNet_1.TbNetName.openMusic, { isOn: false });
};
MusicBtn.prototype.destroy = function () {
Main_1.GDispatcher.removeEventListener(G_EVENT_1.G_EVENT.ON_SHOW, this.onShow, this);
Main_1.GDispatcher.removeEventListener(G_EVENT_1.G_EVENT.ON_HIDE, this.onHide, this);
TaoBaoNet_1.sendTbNet(TaoBaoNet_1.TbNetName.openMusic, { isOn: false });
_super.prototype.destroy.call(this);
};
This diff is collapsed.
......@@ -184,6 +184,9 @@ export class SuccessStarGroup extends Container {
const time2 = 100;
const max = 3;
const interval = 100;
if (count < 1) {
return;
}
Tween.get(this.leftStarEn)
.wait(wait)
.set({scaleX: max, scaleY: max})
......
......@@ -270,13 +270,14 @@ class TaskItem extends Item {
});
break;
case TaskType.follow:
GDispatcher.removeAllEventListenerByType(TbNetName.favorShop);
sendTbNet(TbNetName.favorShop, {},
(fs, fr) => {
if (!fs) return;
sendTbNet(TbNetName.doFollowTask, {taskType: this.data.taskType},
(cs, cr) => GDispatcher.dispatchEvent(G_EVENT.UPDATE_TASK)
);
}
}, true
);
break;
case TaskType.invites:
......
This diff is collapsed.
......@@ -230,7 +230,7 @@ export class MapScene extends Scene {
// Tools.gameOver({
// level: 1,
// score: 666,
// stars: 2,
// stars: 0,
// isVisitSuccess: true,
// isPrizeLevel: false,
// // tool: {
......
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