Commit b9fb01c5 authored by limingzhe's avatar limingzhe

fix: debug

parent 954acf62
This diff is collapsed.
......@@ -611,6 +611,8 @@ cc.Class({
this.initListener();
this.showBackBtn();
// this.initBg();
// this.initPanel();
// this.initScore();
......@@ -634,6 +636,22 @@ cc.Class({
},
showBackBtn() {
const backBtn = cc.find('Canvas/back_btn');
backBtn.active = true;
backBtn.zIndex = 30;
backBtn.on('touchstart', () => {
const middleLayer = global["middleLayer"];
if (middleLayer) {
// 有些模板需要在返回时上报数据,直接把数据作为参数传入就可以了
middleLayer.exitGame({});
} else {
console.log("==触发返回事件==");
}
})
},
initArrow() {
if (!this.data.isTurnPage) {
......
{
"ver": "2.3.5",
"uuid": "89a6c9c2-06fd-46d2-98b4-03c7c212370d",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 100,
"height": 80,
"platformSettings": {},
"subMetas": {
"back_btn": {
"ver": "1.0.4",
"uuid": "dd8481f7-8fc1-48bf-a54e-7b1d5a5eaa42",
"rawTextureUuid": "89a6c9c2-06fd-46d2-98b4-03c7c212370d",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 100,
"height": 80,
"rawWidth": 100,
"rawHeight": 80,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ 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