Commit 11120bef authored by zhangjinzhou's avatar zhangjinzhou

代码暂存

parent 6cdf9bf0
...@@ -19,6 +19,8 @@ module.exports = { ...@@ -19,6 +19,8 @@ module.exports = {
'/activityPlugin/*': 'http://localhost:3000', '/activityPlugin/*': 'http://localhost:3000',
'/aaw/*': 'http://localhost:3000', '/aaw/*': 'http://localhost:3000',
'/wechatShare/*': 'http://localhost:3000', '/wechatShare/*': 'http://localhost:3000',
'/summer/*': 'http://localhost:3000' '/summer/*': 'http://localhost:3000',
'/activity/*': 'http://localhost:3000',
'/statistics/*': 'http://localhost:3000',
} }
} }
\ No newline at end of file
This diff is collapsed.
! function () {
"use strict";
var i, t, m, e, o;
function n() {
if (void 0 !== t) return t;
if (window.TA && void 0 !== window.TA.isSupportWebp) {
if (t = window.TA.isSupportWebp, window.localStorage) try {
window.localStorage.setItem("iswebp", t)
} catch (e) {}
return t
}
if (window.localStorage) {
var e = window.localStorage.getItem("ta_webp");
if (null != e) return t = "true" === e
}
try {
t = !![].map && 0 === document.createElement("canvas").toDataURL("image/webp").indexOf("data:image/webp")
} catch (e) {
t = !1
}
if (window.localStorage) try {
window.localStorage.setItem("ta_webp", t)
} catch (e) {}
return t
}
function p(e) {
return e && "[object String]" === Object.prototype.toString.call(e) && -1 === e.indexOf("data:image") && -1 === e.indexOf("?x-oss-process") && n() ? e + "?x-oss-process=image/format,webp" : e
}
function w(e) {
var t = window.CFG || {};
return e ? t[e] : t
}
function a(e) {
var t = o.clientWidth;
!navigator.userAgent.match(/Android|iPhone|iPad|iPod/i) && 1024 < t && (t = 640, "function" == typeof e && setTimeout(function () {
e(t)
}, 0)), window.remScale = t / 640;
var n = t / 640 * 2 * 100;
n !== i && (i = n, o.style.fontSize = "".concat(i, "px"))
}(o = document.documentElement).getAttribute["data-dpr"] || (e = navigator.userAgent.match(/iPhone|iPad|iPod/i) ? Math.min(window.devicePixelRatio || 1, 3) : 1, o.setAttribute("data-dpr", e), a(function (e) {
document.body.style.margin = "0 auto", document.body.style.maxWidth = "".concat(e, "px")
}), window.addEventListener("pageshow", a, !1), window.addEventListener("orientationchange" in window ? "orientationchange" : "resize", a, !1)),
function (e) {
var t = 0 < arguments.length && void 0 !== e ? e : "ta-webp";
!n() || -1 === ((e = document.documentElement).className || "").indexOf(t) && e.classList.add(t)
}(),
function (e) {
var t, n = 0 < arguments.length && void 0 !== e ? e : "ta-hairlines",
i = document.documentElement;
2 <= (window.devicePixelRatio || 1) && -1 === i.className.indexOf(n) && (t = document.createElement("div"), e = document.createElement("body"), t.style.border = ".5px solid transparent", e.appendChild(t), i.insertBefore(e, i.firstElementChild || i.firstChild), 1 === t.offsetHeight && i.classList.add(n), i.removeChild(e))
}();
var r = window.TA = window.TA || {};
r.px2rem = function (e) {
return parseFloat(e) / 234.375
}, r.rem2px = function (e) {
return parseFloat(e) * i * 2
}, r.getWebpUrl = p, r.getConfig = w, r.getSkinConfig = function (e) {
if (m) return e ? m[e] || {} : m;
m = {};
for (var t = w("styleConfig"), n = t ? t.skinConfig : [], i = 0; i < n.length; i++) {
var o = n[i].childrens;
if (o)
for (var a = 0; a < o.length; a++) {
var r = o[a],
d = r.type,
c = r.name,
l = r.title,
s = r.webp,
u = o[a].value,
r = u;
switch (d) {
case "image":
u = !1 === s ? u : p(u);
break;
case "position":
case "bottom":
u = parseFloat(u.toString().replace(/<[^>]*>/g, ""))
}
m[c] = {
value: u,
oldValue: r,
type: d,
title: l
}
}
}
return e ? m[e] : m
}, r.addPreloadStyle = function (e) {
var t = document.createElement("style");
t.type = "text/css", t.styleSheet ? t.styleSheet.cssText = e : t.appendChild(document.createTextNode(e)), document.getElementsByTagName("head")[0].appendChild(t)
}, r.preloadImage = function (e) {
for (var t = 0; t < e.length; t++) {
var n = [];
n[t] = new Image, n[t].src = e[t]
}
}, Object.defineProperty(r, "isSupportWebp", {
get: n
})
}();
\ No newline at end of file
...@@ -50,9 +50,12 @@ export default class PrizePanel extends Panel { ...@@ -50,9 +50,12 @@ export default class PrizePanel extends Panel {
//打开宝箱 //打开宝箱
this["doubleBtn"].addEventListener(egret.TouchEvent.TOUCH_TAP, () => { this["doubleBtn"].addEventListener(egret.TouchEvent.TOUCH_TAP, () => {
this.visible = false;
Utils.couponJoin(CouponJoinScene.Checkpoint,this._level,()=>{ Utils.couponJoin(CouponJoinScene.Checkpoint,this._level,()=>{
this.visible = true;
this.changeSceneShow(2);
},()=>{ },()=>{
this.visible = true;
this.changeSceneShow(2); this.changeSceneShow(2);
}) })
}) })
......
...@@ -30,6 +30,8 @@ ...@@ -30,6 +30,8 @@
</e:Group> </e:Group>
<e:Image id="settingBtn" x="-0.47" y="1" source="setting_png"/> <e:Image id="settingBtn" x="-0.47" y="1" source="setting_png"/>
</e:Group> </e:Group>
<e:Label id="tosucbtn" text="一键成功" y="180" backgroundColor="0xdba013" background="true" left="0"/>
<e:Label id="tofailbtn" text="一键失败" y="224" background="true" backgroundColor="0xff0000" left="0"/>
......
import { DataManager } from "../libs/tw/manager/DataManager"; import { DataManager } from "../libs/tw/manager/DataManager";
export const TACore = window["TACore"];
export enum CouponJoinScene { export enum CouponJoinScene {
BlindBox = 0,//盲盒 BlindBox = 0,//盲盒
//星级宝箱 //星级宝箱
...@@ -192,15 +193,18 @@ export default class Utils { ...@@ -192,15 +193,18 @@ export default class Utils {
afterClose: afterClose afterClose: afterClose
} }
console.error("奖品弹窗点击===》", scene); console.error("奖品弹窗点击===》", scene);
beforeUse && beforeUse(); // beforeUse && beforeUse();
afterClose && afterClose(); // afterClose && afterClose();
TACore.couponJoin(options);
} }
//展示大转盘 //展示大转盘
static showTurnCircle(afterClose = () => { }): void { static showTurnCircle(afterClose = () => { }): void {
let options: ShowTurnCircleOptions = { let options: ShowTurnCircleOptions = {
afterClose, afterClose,
} }
afterClose && afterClose(); // afterClose && afterClose();
TACore.showTurnCircle(options);
} }
//是否存在视频 //是否存在视频
/** 是否展示观看视频按钮 */ /** 是否展示观看视频按钮 */
......
This diff is collapsed.
...@@ -870,7 +870,9 @@ export default class MapScene extends Scene { ...@@ -870,7 +870,9 @@ export default class MapScene extends Scene {
//打开转盘 //打开转盘
onTap_turnGroup() { onTap_turnGroup() {
console.log("打开转盘"); Utils.showTurnCircle(()=>{
console.log("转盘关闭");
})
} }
//兑换 //兑换
onTap_exchangeBtn() { onTap_exchangeBtn() {
......
...@@ -18,8 +18,14 @@ export default class FailedPanel extends Panel { ...@@ -18,8 +18,14 @@ export default class FailedPanel extends Panel {
start(data) { start(data) {
super.start(); super.start();
this.data = data; this.data = data;
const { showVideo,videoAdd } = data; let { showVideo,videoAdd } = data;
this.changeSceneShow(showVideo); let _v = showVideo
if(showVideo&&Utils.isShowVideoEntrance(VideoEntranceScene.defeated)){
_v = true;
}else{
_v = false;
}
this.changeSceneShow(_v);
if (showVideo) { if (showVideo) {
let propNumShow = new PropNumber(); let propNumShow = new PropNumber();
......
...@@ -34,6 +34,15 @@ export default class StartPanel extends Panel { ...@@ -34,6 +34,15 @@ export default class StartPanel extends Panel {
//闯关前弹框曝光 //闯关前弹框曝光
NetManager.ins.showLog(getlogItem(1)) NetManager.ins.showLog(getlogItem(1))
let _v = false;
if(Utils.isShowVideoEntrance(VideoEntranceScene.gameprops)){
_v = true;
}
this['video1btn'].visible = _v;
this['video2btn'].visible = _v;
this['video3btn'].visible = _v;
super.start(); super.start();
this['price2'].text = `-${window['price2']}元宝`; this['price2'].text = `-${window['price2']}元宝`;
this['price3'].text = `-${window['price3']}元宝`; this['price3'].text = `-${window['price3']}元宝`;
...@@ -103,8 +112,13 @@ export default class StartPanel extends Panel { ...@@ -103,8 +112,13 @@ export default class StartPanel extends Panel {
onTap_startBtn() { onTap_startBtn() {
const homeData = getHomeData(); const homeData = getHomeData();
if (homeData.remainEnargy <= 0) { if (homeData.remainEnargy <= 0) {
if(Utils.isShowVideoEntrance(VideoEntranceScene.life)){
PanelCtrl.instance.show('addBloodV');
}else{
showToast("体力不足");
}
// if (homeData.askForEnergy) { // if (homeData.askForEnergy) {
PanelCtrl.instance.show('addBloodV');
// } else { // } else {
// if (iswx()) { // if (iswx()) {
// getShareUrl(this.stage); // getShareUrl(this.stage);
......
This diff is collapsed.
...@@ -203,6 +203,15 @@ const config = { ...@@ -203,6 +203,15 @@ const config = {
}, },
'/mixloanv/happyclear/submitStarBox':{ '/mixloanv/happyclear/submitStarBox':{
data: './happyclear/submitStarBox.json' data: './happyclear/submitStarBox.json'
},
'/activity/doJoin':{
data: './activity/doJoin.json'
},
'/mixloanv/happyclear/openBox':{
data: './mixloanv/happyclear/openBox.json'
},
'/statistics/activityPagePerf':{
data: './activity/doJoin.json'
} }
}; };
......
...@@ -1011,15 +1011,15 @@ ...@@ -1011,15 +1011,15 @@
"remainProp": [ "remainProp": [
{ {
"type": 2, "type": 2,
"num": 0 "num": 10
}, },
{ {
"type": 3, "type": 3,
"num": 0 "num": 10
}, },
{ {
"type": 4, "type": 4,
"num": 0 "num": 10
} }
], ],
"remainEnargy": 2, "remainEnargy": 2,
......
{
"code": "000000",
"data": 9,
"success": true,
"comment": "根据不同场景和关卡获取碎片/积分/高级货币"
}
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