Commit 47069cc0 authored by haiyoucuv's avatar haiyoucuv

背包奖品高亮

parent ab10010f
......@@ -26,25 +26,28 @@
},
{
"__id__": 58
},
{
"__id__": 68
}
],
"_active": true,
"_components": [
{
"__id__": 68
"__id__": 78
},
{
"__id__": 70
"__id__": 80
},
{
"__id__": 72
"__id__": 82
},
{
"__id__": 74
"__id__": 84
}
],
"_prefab": {
"__id__": 78
"__id__": 89
},
"_lpos": {
"__type__": "cc.Vec3",
......@@ -1205,7 +1208,7 @@
},
"_lpos": {
"__type__": "cc.Vec3",
"x": 162,
"x": 15,
"y": -301.00000000000006,
"z": 0
},
......@@ -1319,7 +1322,7 @@
},
"_alignFlags": 12,
"_target": null,
"_left": 854,
"_left": 707,
"_right": 0,
"_top": 0,
"_bottom": 29.999999999999943,
......@@ -1439,7 +1442,7 @@
},
"_lpos": {
"__type__": "cc.Vec3",
"x": -134,
"x": -285,
"y": -301,
"z": 0
},
......@@ -1553,7 +1556,7 @@
},
"_alignFlags": 12,
"_target": null,
"_left": 558,
"_left": 407,
"_right": 0,
"_top": 0,
"_bottom": 30,
......@@ -1644,6 +1647,240 @@
"targetOverrides": null,
"nestedPrefabInstanceRoots": null
},
{
"__type__": "cc.Node",
"_name": "去开福袋",
"_objFlags": 0,
"__editorExtras__": {},
"_parent": {
"__id__": 1
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 69
},
{
"__id__": 71
},
{
"__id__": 73
},
{
"__id__": 75
}
],
"_prefab": {
"__id__": 77
},
"_lpos": {
"__type__": "cc.Vec3",
"x": 315,
"y": -301,
"z": 0
},
"_lrot": {
"__type__": "cc.Quat",
"x": 0,
"y": 0,
"z": 0,
"w": 1
},
"_lscale": {
"__type__": "cc.Vec3",
"x": 1,
"y": 1,
"z": 1
},
"_mobility": 0,
"_layer": 33554432,
"_euler": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_id": ""
},
{
"__type__": "cc.UITransform",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 68
},
"_enabled": true,
"__prefab": {
"__id__": 70
},
"_contentSize": {
"__type__": "cc.Size",
"width": 240,
"height": 88
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_id": ""
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "67/gPXfXVDqomG4t4kJ/Zy"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 68
},
"_enabled": true,
"__prefab": {
"__id__": 72
},
"_customMaterial": null,
"_srcBlendFactor": 2,
"_dstBlendFactor": 4,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_spriteFrame": {
"__uuid__": "21c0a207-8051-4c56-91b0-8ef9682f2d3d@f9941",
"__expectedType__": "cc.SpriteFrame"
},
"_type": 0,
"_fillType": 0,
"_sizeMode": 1,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_useGrayscale": false,
"_atlas": null,
"_id": ""
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "4ddvroTwlKRbDojzmTWKwC"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 68
},
"_enabled": true,
"__prefab": {
"__id__": 74
},
"_alignFlags": 12,
"_target": null,
"_left": 1007,
"_right": 0,
"_top": 0,
"_bottom": 30,
"_horizontalCenter": 0,
"_verticalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 0,
"_originalHeight": 0,
"_alignMode": 2,
"_lockFlags": 0,
"_id": ""
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "665PaXSCFCzoLweJRn/ohT"
},
{
"__type__": "cc.Button",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 68
},
"_enabled": true,
"__prefab": {
"__id__": 76
},
"clickEvents": [],
"_interactable": true,
"_transition": 3,
"_normalColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_hoverColor": {
"__type__": "cc.Color",
"r": 211,
"g": 211,
"b": 211,
"a": 255
},
"_pressedColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_disabledColor": {
"__type__": "cc.Color",
"r": 124,
"g": 124,
"b": 124,
"a": 255
},
"_normalSprite": null,
"_hoverSprite": null,
"_pressedSprite": null,
"_disabledSprite": null,
"_duration": 0.05,
"_zoomScale": 0.9,
"_target": null,
"_id": ""
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "c7HaiKTS1LwZEahDYPZWBi"
},
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 1
},
"asset": {
"__id__": 0
},
"fileId": "d2QAhlVhVHxab6JlhN/fN9",
"instance": null,
"targetOverrides": null,
"nestedPrefabInstanceRoots": null
},
{
"__type__": "cc.UITransform",
"_name": "",
......@@ -1654,7 +1891,7 @@
},
"_enabled": true,
"__prefab": {
"__id__": 69
"__id__": 79
},
"_contentSize": {
"__type__": "cc.Size",
......@@ -1682,7 +1919,7 @@
},
"_enabled": true,
"__prefab": {
"__id__": 71
"__id__": 81
},
"_alignFlags": 18,
"_target": null,
......@@ -1718,7 +1955,7 @@
},
"_enabled": true,
"__prefab": {
"__id__": 73
"__id__": 83
},
"closeBtn": {
"__id__": 58
......@@ -1726,6 +1963,9 @@
"shareBtn": {
"__id__": 48
},
"goBag": {
"__id__": 68
},
"PrizeImg": {
"__id__": 22
},
......@@ -1754,14 +1994,17 @@
},
"_enabled": true,
"__prefab": {
"__id__": 75
"__id__": 85
},
"skinNodeArr": [
{
"__id__": 76
"__id__": 86
},
{
"__id__": 77
"__id__": 87
},
{
"__id__": 88
}
],
"_genSkinNode": true,
......@@ -1833,6 +2076,37 @@
"node1": null,
"node2": null
},
{
"__type__": "SkinNode",
"node": {
"__id__": 68
},
"type": 0,
"color1": {
"__type__": "cc.Color",
"r": 0,
"g": 0,
"b": 0,
"a": 255
},
"color2": {
"__type__": "cc.Color",
"r": 0,
"g": 0,
"b": 0,
"a": 255
},
"skin1": {
"__uuid__": "21c0a207-8051-4c56-91b0-8ef9682f2d3d@f9941",
"__expectedType__": "cc.SpriteFrame"
},
"skin2": {
"__uuid__": "86cb9153-d9a5-4b02-adf7-6a5122734654@f9941",
"__expectedType__": "cc.SpriteFrame"
},
"node1": null,
"node2": null
},
{
"__type__": "cc.PrefabInfo",
"root": {
......
import Panel from "../../Module/Panel";
import { _decorator, Button, Label, Node, Sprite, } from "cc";
import { _decorator, Button, director, Label, Node, Sprite, } from "cc";
import store from "../store/store";
import { observer, render } from "../store/decorators";
import { _asyncThrottle, dateFormatter } from "../Utils/Utils";
import { showPanel } from "../../Module/UIFast";
import { changeScene, showPanel } from "../../Module/UIFast";
import SharePop from "./SharePop";
import { LOG_TYPE, sendLog } from "../Utils/WebNet/WebNet";
import { BlessingBagPage } from "../Scenes/BlessingBagPage";
import { UIMgr } from "../../Module/UIMgr";
const { ccclass, property } = _decorator;
......@@ -18,6 +20,7 @@ export default class RankPrizePanel extends Panel {
@property(Node) closeBtn: Node = null;
@property(Node) shareBtn: Node = null;
@property(Node) goBag: Node = null;
@property(Sprite) PrizeImg: Sprite = null;
@property(Label) PrizeName: Label = null;
......@@ -28,6 +31,7 @@ export default class RankPrizePanel extends Panel {
onLoad() {
this.closeBtn.on(Button.EventType.CLICK, this.clickClose);
this.shareBtn.on(Button.EventType.CLICK, this.doShare);
this.goBag.on(Button.EventType.CLICK, this.clickGoBag);
}
async start() {
......@@ -46,6 +50,12 @@ export default class RankPrizePanel extends Panel {
}, 200);
}
clickGoBag = _asyncThrottle(async () => {
if (!director.getScene().getComponent(BlessingBagPage)) {
await changeScene(BlessingBagPage);
}
this.hidePanel();
});
doShare = _asyncThrottle(async () => {
sendLog(LOG_TYPE.CLICK, 16)
......
......@@ -197,7 +197,10 @@ export class HomeScene extends Scene {
clickBag = _asyncThrottle(async () => {
sendLog(LOG_TYPE.CLICK, 6);
if (!store.checkActTime()) return;
if(!store.homeInfo.bagSwitch) {
showToast("暂未开启");
return;
}
await changeScene(BlessingBagPage);
});
......
......@@ -48,7 +48,6 @@
"prizeImage":"//yun.dui88.com/images/201907/tua0um9jjp.jpg"
}
],
"rankPopList": [],
"signPopFlag": false,
"bagLightFlag": true,
"bagSwitch": false,
......
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