Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Z
zeroing-libs
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
劳工
zeroing-libs
Commits
c8ec6a6a
Commit
c8ec6a6a
authored
Sep 27, 2020
by
刘畅
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
superman
parent
d811d190
Changes
23
Show whitespace changes
Inline
Side-by-side
Showing
23 changed files
with
2169 additions
and
0 deletions
+2169
-0
superman.json
dist/customs/superman.json
+106
-0
Buried.js
src/custom/superman/debug/Buried.js
+79
-0
NetBuried.js
src/custom/superman/debug/NetBuried.js
+94
-0
app.js
src/custom/superman/debug/app.js
+91
-0
index.html
src/custom/superman/debug/index.html
+53
-0
load-assets.js
src/custom/superman/debug/load-assets.js
+52
-0
main.js
src/custom/superman/debug/main.js
+491
-0
main.js.map
src/custom/superman/debug/main.js.map
+1
-0
props.js
src/custom/superman/debug/props.js
+7
-0
meta.json
src/custom/superman/meta.json
+104
-0
Buried.ts
src/custom/superman/src/game/Buried.ts
+91
-0
GTime.ts
src/custom/superman/src/game/GTime.ts
+49
-0
GameView.ts
src/custom/superman/src/game/GameView.ts
+301
-0
GameWrapper.ts
src/custom/superman/src/game/GameWrapper.ts
+43
-0
IExposureData.ts
src/custom/superman/src/game/IExposureData.ts
+19
-0
INetData.ts
src/custom/superman/src/game/INetData.ts
+22
-0
QAText.ts
src/custom/superman/src/game/QAText.ts
+313
-0
TestView.ts
src/custom/superman/src/game/TestView.ts
+106
-0
getlogItem.ts
src/custom/superman/src/game/getlogItem.ts
+8
-0
test.json
src/custom/superman/src/game/test.json
+3
-0
utils.ts
src/custom/superman/src/game/utils.ts
+107
-0
index.ts
src/custom/superman/src/index.ts
+14
-0
props.ts
src/custom/superman/src/props.ts
+15
-0
No files found.
dist/customs/superman.json
0 → 100644
View file @
c8ec6a6a
{
"name"
:
"蛋黄超人自定义模块"
,
"desc"
:
"蛋黄超人自定义模块1.0"
,
"props"
:
{
"QTextStrArr"
:
{
"alias"
:
"问题文案组,用逗号隔开,不填为默认"
,
"type"
:
"string"
,
"default"
:
"1、什么是筑梦空间?,2、金币是什么?,3、怎么获得金币?,4、如何更改用户昵称?,5、个人信息可以进行哪些操作?,6、通过二维码添加好友之后在哪里查看?,7、我的勋章是什么?,8、任务有哪些分类?"
},
"ATextStrArr"
:
{
"alias"
:
"答案文案组,用逗号隔开,不填为默认"
,
"type"
:
"string"
,
"default"
:
"筑梦空间带给用户吃喝玩乐的不同体验,在这里你可以进行生活缴费、体验本地优惠、建设我的庄园、畅玩游戏中心等等。,金币是筑梦空间中的虚拟货币,用户可以使用金币游玩游戏、种植植物、兑换实物,同时金币可以按一定比例兑换波豆,波豆可以在波豆商城兑换更丰富的商品。,用户可以通过签到、任务、参与活动以及我的庄园果实售卖方式获得金币。,用户可以点击左上角个人信息按钮进入个人信息弹窗,点击昵称旁的修改按钮对昵称进行修改。,用户可以在个人信息页面进行修改昵称、修改头像、兑换波豆、查询金币明细、扫二维码添加好友等操作。,用户A通过扫描用户B的二维码进入活动之后,双方即绑定为好友,可以排行榜-好友排行榜进行查看。,当用户在筑梦空间的各种行为动作达到一定次数时,会点亮相应的激励勋章。,任务中分为一次性任务、永久开放任务和周期更新任务,一次性任务为完成一次或多次后消失的任务,如浏览车主服务任务、升级房屋任务;永久开放任务为一直可以完成并获得奖励的任务,如邀请好友任务;周期任务为以周期(每日/周/月)为单位进行更新的任务,如分享筑梦空间、去商店购买种子任务,积极完成任务可以获得更多金币。"
},
"ACTTextStrArr"
:
{
"alias"
:
"互动文案组,用逗号隔开,不填为默认"
,
"type"
:
"string"
,
"default"
:
"主人你多久没来看我了,我好想你啊,Whoooo,主人你太棒了,主人,果子都成熟了,赶紧去采摘吧,主人,有空地可以种植哦,赶紧去吧!"
},
"type"
:
{
"alias"
:
"类型,用于区分所在场景,用于埋点,0:首页,1:庄园"
,
"type"
:
"number"
,
"default"
:
"0"
}
},
"assets"
:
[
{
"name"
:
"大对话泡"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/a3d49f913ee300b2834260967010a2e7b2d5c265.png"
,
"uuid"
:
"21d8b7ca-6ed3-44e5-ada0-f0433f471ac9"
,
"ext"
:
".png"
},
{
"name"
:
"小对话泡"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/c034f14785a2a36dce266cef0f46bd783ad03cb2.png"
,
"uuid"
:
"9e4d1860-4762-4ac1-bc44-b3dd8fb307a6"
,
"ext"
:
".png"
},
{
"name"
:
"蛋黄超人关闭按钮"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/7a346d4e2c2cbce5ab3ac0a74e481525b048fcdd.png"
,
"uuid"
:
"76f2c800-2174-4a90-ad6d-5853e95eb144"
,
"ext"
:
".png"
},
{
"name"
:
"返回按钮"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/8f55741c71b2aa7babe5cc517707cdd51b33c3d9.png"
,
"uuid"
:
"2a555da9-dc05-4046-a5fb-551f0c2692fa"
,
"ext"
:
".png"
},
{
"name"
:
"蛋黄超人icon"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/baeec26a873006fabf031af8c918153384a732ef.png"
,
"uuid"
:
"d5df1198-2cad-42e0-a197-fd56a2502d99"
,
"ext"
:
".png"
},
{
"name"
:
"蛋黄超人名称"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/11b02c3908bcb8d685610caafdab9785fac5fccf.png"
,
"uuid"
:
"fef58cbd-9c24-4216-896a-2799011df1dc"
,
"ext"
:
".png"
},
{
"name"
:
"右箭头"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/8be77ba8ce699c4d302cd58e4d3be06919ac732f.png"
,
"uuid"
:
"8546dcf7-a6e8-4ba2-89f7-b929118e473a"
,
"ext"
:
".png"
},
{
"name"
:
"常规呼吸动作"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/adc7212454ea1d84ac5824982a57f37d2e745b54.svga"
,
"uuid"
:
"ba2f8259-71b5-49ac-8310-08538a6b5d07"
,
"ext"
:
".svga"
},
{
"name"
:
"招手"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/cf78c2f55369b597dfc744159687dc255f18a2b4.svga"
,
"uuid"
:
"97de87e9-2ea4-4a31-9986-25edcd807c05"
,
"ext"
:
".svga"
}
],
"events"
:
{
"in"
:
{
"pictures-ActLabel"
:
{
"alias"
:
"互动显示"
,
"data"
:
{
"type"
:
"0:24小时未登录互动,1:任务完成互动,2:农作物成熟互动,3:有土地未种植互动"
}
},
"pictures-setProjectId"
:
{
"alias"
:
"设置星速台id与appid"
,
"data"
:
{
"projectId"
:
"默认为'0'"
,
"appId"
:
"默认为'0'"
}
}
},
"out"
:
{
"pictures-end"
:
{
"alias"
:
"结束"
}
}
},
"id"
:
"superman"
,
"code"
:
"(function (global, factory) {
\n\t
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('tslib')) :
\n\t
typeof define === 'function' && define.amd ? define(['tslib'], factory) :
\n\t
(global = global || self, global.superman = factory(global.tslib));
\n
}(this, (function (tslib) { 'use strict';
\n\n\t
var props = {};
\r\n\t
function prepareProps() {
\r\n\t
var metaProps = getProps();
\r\n\t
engine.injectProp(props, metaProps);
\r\n\t
}
\r\n\t
function injectProps(p) {
\r\n\t
engine.injectProp(props, p);
\r\n\t
}
\n\n\t
var GTime = (function () {
\r\n\t
function GTime() {
\r\n\t
}
\r\n\t
GTime.getTimestamp = function () {
\r\n\t
return new Date().getTime();
\r\n\t
};
\r\n\t
GTime.GetTimeHMS = function (time) {
\r\n\t
var t;
\r\n\t
var h = Math.floor(time / 3600);
\r\n\t
var hstr = h > 9 ? h : '0' + h;
\r\n\t
var m = Math.floor((time % 3600) / 60);
\r\n\t
var mstr = m > 9 ? m : '0' + m;
\r\n\t
var s = Math.floor(time % 60);
\r\n\t
var sstr = s > 9 ? s : '0' + s;
\r\n\t
t = hstr + ':' + mstr + ':' + sstr;
\r\n\t
return t;
\r\n\t
};
\r\n\t
GTime.GetTimeMS = function (time) {
\r\n\t
var t;
\r\n\t
var m = Math.floor((time % 3600) / 60);
\r\n\t
var mstr = m > 9 ? m : '0' + m;
\r\n\t
var s = Math.floor(time % 60);
\r\n\t
var sstr = s > 9 ? s : '0' + s;
\r\n\t
t = mstr + ':' + sstr;
\r\n\t
return t;
\r\n\t
};
\r\n\t
return GTime;
\r\n\t
}());
\n\n\t
function getTexture(uuid) {
\r\n\t
return engine.Texture.from(getAssetByUUID(uuid).uuid);
\r\n\t
}
\r\n\t
function createSvga(name, anchorName) {
\r\n\t
var inst = new svga.Svga();
\r\n\t
inst.source = 'asset://' + engine.getAssetByName(name).uuid;
\r\n\t
return inst;
\r\n\t
}
\r\n\t
function clickLog(exposure) {
\r\n\t
var net = {
\r\n\t
name: 'clickLog',
\r\n\t
uri: '/log/click',
\r\n\t
type: 'get',
\r\n\t
dataType: 'jsonp',
\r\n\t
param: exposure,
\r\n\t
callback: null,
\r\n\t
hideMsg: true
\r\n\t
};
\r\n\t
send(net);
\r\n\t
}
\r\n\t
function showLog(exposure) {
\r\n\t
var net = {
\r\n\t
name: 'showLog',
\r\n\t
uri: exposure.domain + '/exposure/standard',
\r\n\t
type: 'get',
\r\n\t
dataType: 'jsonp',
\r\n\t
param: exposure,
\r\n\t
callback: null,
\r\n\t
hideMsg: true
\r\n\t
};
\r\n\t
send(net);
\r\n\t
}
\r\n\t
function send(net) {
\r\n\t
var gTime = '?_=' + GTime.getTimestamp();
\r\n\t
var realUrl = net.uri;
\r\n\t
if (realUrl.indexOf('?') != -1) {
\r\n\t
gTime = '&_=' + GTime.getTimestamp();
\r\n\t
}
\r\n\t
if (net.addUrl) {
\r\n\t
realUrl += net.addUrl;
\r\n\t
}
\r\n\t
window['$'].ajax({
\r\n\t
type: net.type,
\r\n\t
url: realUrl,
\r\n\t
cache: false,
\r\n\t
dataType: net.dataType,
\r\n\t
data: net.param,
\r\n\t
async: true,
\r\n\t
});
\r\n\t
}
\n\n\t
var Buried = (function () {
\r\n\t
function Buried() {
\r\n\t
}
\r\n\t
Buried.init = function () {
\r\n\t
};
\r\n\t
Buried.createExposure = function (dpm, dcm, embedDomain) {
\r\n\t
if (embedDomain === void 0) { embedDomain = '//embedlog.duiba.com.cn'; }
\r\n\t
var exposure = {
\r\n\t
dpm: dpm,
\r\n\t
dcm: dcm,
\r\n\t
appId: Buried.appId,
\r\n\t
domain: embedDomain
\r\n\t
};
\r\n\t
return exposure;
\r\n\t
};
\r\n\t
Buried.connectDpm = function (pageId, area, dpm) {
\r\n\t
return Buried.appId + '.' + pageId + '.' + area + '.' + dpm;
\r\n\t
};
\r\n\t
Buried.connectDcm = function (typeId, contentInfo, dcm) {
\r\n\t
return typeId + '.' + Buried.oaId + '.' + contentInfo + '.' + dcm;
\r\n\t
};
\r\n\t
Buried.connectPlugDcm = function (plugId, type) {
\r\n\t
return 212 + '.' + plugId + '.' + type + '.' + Buried.oaId;
\r\n\t
};
\r\n\t
Buried.connectActivityDcm = function (type) {
\r\n\t
return 202 + '.' + Buried.oaId + '.' + type + '.' + Buried.oaId;
\r\n\t
};
\r\n\t
Buried.appId = '0';
\r\n\t
Buried.oaId =
\"
0
\"
;
\r\n\t
return Buried;
\r\n\t
}());
\n\n\t
var getlogItem = function (i) {
\r\n\t
var Dpm = Buried.connectDpm(110, i, 1);
\r\n\t
var Dcm = Buried.connectDcm(202, 0, 0);
\r\n\t
return Buried.createExposure(Dpm, Dcm);
\r\n\t
};
\n\n\t
var QAText = (function (_super) {
\r\n\t
tslib.__extends(QAText, _super);
\r\n\t
function QAText() {
\r\n\t
var _this = _super.call(this) || this;
\r\n\t
_this.bg = [];
\r\n\t
_this.bgTexture = [];
\r\n\t
_this.QLabel = [];
\r\n\t
_this.ALabel = [];
\r\n\t
_this.addEventListener(engine.Event.ADDED_TO_STAGE, _this.setup, _this);
\r\n\t
_this.init();
\r\n\t
return _this;
\r\n\t
}
\r\n\t
QAText.prototype.init = function () {
\r\n\t
var that = this;
\r\n\t
that.bigBgOrigin = new engine.Point();
\r\n\t
that.smallBgOrigin = new engine.Point();
\r\n\t
that.QText = props.QTextStrArr.split(',');
\r\n\t
console.log(props.QTextStrArr.split(','));
\r\n\t
that.AText = props.ATextStrArr.split(',');
\r\n\t
console.log(props.ATextStrArr.split(','));
\r\n\t
that.ActText = props.ACTTextStrArr.split(',');
\r\n\t
console.log(props.ACTTextStrArr.split(','));
\r\n\t
};
\r\n\t
QAText.prototype.setup = function () {
\r\n\t
var that = this;
\r\n\t
that.removeEventListener(engine.Event.ADDED_TO_STAGE, that.setup, that);
\r\n\t
that.hideText();
\r\n\t
that.setGroup();
\r\n\t
that.setQLabel();
\r\n\t
that.setALabel();
\r\n\t
that.setActLabel();
\r\n\t
that.setEvent();
\r\n\t
};
\r\n\t
QAText.prototype.setEvent = function () {
\r\n\t
};
\r\n\t
QAText.prototype.setGroup = function () {
\r\n\t
var that = this;
\r\n\t
that.QlabelGroup = new engine.Sprite();
\r\n\t
that.addChild(that.QlabelGroup);
\r\n\t
that.QlabelGroup.visible = false;
\r\n\t
that.AlabelGroup = new engine.Sprite();
\r\n\t
that.addChild(that.AlabelGroup);
\r\n\t
that.AlabelGroup.visible = false;
\r\n\t
that.ActlabelGroup = new engine.Sprite();
\r\n\t
that.addChild(that.ActlabelGroup);
\r\n\t
that.ActlabelGroup.visible = false;
\r\n\t
for (var i = 0; i < 3; i++) {
\r\n\t
var bg = new engine.Image();
\r\n\t
if (i < 2) {
\r\n\t
bg.texture = getTexture(
\"
21d8b7ca-6ed3-44e5-ada0-f0433f471ac9
\"
);
\r\n\t
if (i == 0) {
\r\n\t
that.QlabelGroup.addChild(bg);
\r\n\t
}
\r\n\t
else {
\r\n\t
that.AlabelGroup.addChild(bg);
\r\n\t
}
\r\n\t
}
\r\n\t
else {
\r\n\t
bg.texture = getTexture(
\"
9e4d1860-4762-4ac1-bc44-b3dd8fb307a6
\"
);
\r\n\t
that.ActlabelGroup.addChild(bg);
\r\n\t
}
\r\n\t
that.bg.push(bg);
\r\n\t
}
\r\n\t
that.closeBtn = new engine.Image(getTexture(
\"
76f2c800-2174-4a90-ad6d-5853e95eb144
\"
));
\r\n\t
that.addChild(that.closeBtn);
\r\n\t
that.closeBtn.mouseEnabled = true;
\r\n\t
that.closeBtn.addEventListener(engine.MouseEvent.CLICK, that.hideText, that);
\r\n\t
that.QScrList = new engine.ScrollView();
\r\n\t
that.QlabelGroup.addChild(that.QScrList);
\r\n\t
that.QScrList.x = 30;
\r\n\t
that.QScrList.y = 85;
\r\n\t
that.QScrList.width = that.bg[0].width - 50;
\r\n\t
that.QScrList.height = 195;
\r\n\t
};
\r\n\t
QAText.prototype.setQText = function (e) {
\r\n\t
console.log('engine.Event.UPDATE_DATA', e);
\r\n\t
e.target.getChildByName('问题文本').text = e.data;
\r\n\t
e.target.name = 'Q_' + e.data.substring(0, 1);
\r\n\t
};
\r\n\t
QAText.prototype.setQLabel = function () {
\r\n\t
var that = this;
\r\n\t
var label = new engine.Label();
\r\n\t
label.text = '你想问哪些问题?';
\r\n\t
label.x = 30;
\r\n\t
label.y = 30;
\r\n\t
label.size = 34;
\r\n\t
label.width = that.bg[0].width - 50;
\r\n\t
that.QlabelGroup.addChild(label);
\r\n\t
for (var i = 0; i < that.QText.length; i++) {
\r\n\t
var img = new engine.Image(getTexture(
\"
8546dcf7-a6e8-4ba2-89f7-b929118e473a
\"
));
\r\n\t
that.QScrList.addChild(img);
\r\n\t
img.name = 'Q_' + i;
\r\n\t
img.y = 5 + i * 50;
\r\n\t
img.x = that.QScrList.width - img.width;
\r\n\t
img.mouseEnabled = true;
\r\n\t
img.addEventListener(engine.MouseEvent.CLICK, that.showALabelGroup, that);
\r\n\t
var label_1 = new engine.Label();
\r\n\t
that.QScrList.addChild(label_1);
\r\n\t
label_1.name = 'Q_' + i;
\r\n\t
label_1.text = that.QText[i];
\r\n\t
label_1.fillColor =
\"
#d36800
\"
;
\r\n\t
label_1.size = 24;
\r\n\t
label_1.width = img.x;
\r\n\t
label_1.height = 50;
\r\n\t
label_1.y = img.y;
\r\n\t
label_1.mouseEnabled = true;
\r\n\t
label_1.addEventListener(engine.MouseEvent.CLICK, that.showALabelGroup, that);
\r\n\t
that.QLabel.push(label_1);
\r\n\t
}
\r\n\t
};
\r\n\t
QAText.prototype.setALabel = function () {
\r\n\t
var that = this;
\r\n\t
that.AScrView = new engine.ScrollView();
\r\n\t
that.AlabelGroup.addChild(that.AScrView);
\r\n\t
that.AScrView.x = 32;
\r\n\t
that.AScrView.y = 62;
\r\n\t
that.AScrView.width = that.bg[0].width - 55;
\r\n\t
that.AScrView.height = that.bg[0].height - 120;
\r\n\t
for (var i = 0; i < 2; i++) {
\r\n\t
var label = new engine.Label();
\r\n\t
label.x = 0;
\r\n\t
label.y = 5 + i * 40;
\r\n\t
label.size = 24;
\r\n\t
label.width = that.AScrView.width;
\r\n\t
label.lineSpacing = 11;
\r\n\t
label.lineType = engine.TEXT_lINETYPE.MULTI;
\r\n\t
that.AScrView.addChild(label);
\r\n\t
that.ALabel.push(label);
\r\n\t
}
\r\n\t
that.returnBtn = new engine.Image(getTexture('2a555da9-dc05-4046-a5fb-551f0c2692fa'));
\r\n\t
that.AlabelGroup.addChild(that.returnBtn);
\r\n\t
that.returnBtn.x = 18;
\r\n\t
that.returnBtn.y = 20;
\r\n\t
that.returnBtn.mouseEnabled = true;
\r\n\t
that.returnBtn.addEventListener(engine.MouseEvent.CLICK, that.showQLabelGroup, that);
\r\n\t
};
\r\n\t
QAText.prototype.setActLabel = function () {
\r\n\t
var that = this;
\r\n\t
that.ActLabel = new engine.Label();
\r\n\t
that.ActlabelGroup.addChild(that.ActLabel);
\r\n\t
that.ActLabel.x = 0;
\r\n\t
that.ActLabel.y = that.getSmallBgSize().h * 0.5 - 24;
\r\n\t
that.ActLabel.width = that.getSmallBgSize().w;
\r\n\t
that.ActLabel.textAlign = engine.TEXT_ALIGN.CENTER;
\r\n\t
that.ActLabel.size = 24;
\r\n\t
};
\r\n\t
QAText.prototype.showQLabelGroup = function (e) {
\r\n\t
var that = this;
\r\n\t
if (e && e.target == that.returnBtn) {
\r\n\t
if (props.type == 0) {
\r\n\t
clickLog(getlogItem(30));
\r\n\t
}
\r\n\t
else if (props.type == 1) {
\r\n\t
clickLog(getlogItem(80));
\r\n\t
}
\r\n\t
}
\r\n\t
that.x = that.bigBgOrigin.x;
\r\n\t
that.y = that.bigBgOrigin.y;
\r\n\t
that.closeBtn.x = that.bg[0].width - that.closeBtn.width + 20;
\r\n\t
that.closeBtn.y = -10;
\r\n\t
that.AlabelGroup.visible = false;
\r\n\t
that.ActlabelGroup.visible = false;
\r\n\t
that.QlabelGroup.visible = true;
\r\n\t
that.QScrList.scrollTo(-1);
\r\n\t
that.showText();
\r\n\t
};
\r\n\t
QAText.prototype.showALabelGroup = function (e) {
\r\n\t
console.log(
\"
展示答案
\"
+ e.target.name);
\r\n\t
var that = this;
\r\n\t
that.x = that.bigBgOrigin.x;
\r\n\t
that.y = that.bigBgOrigin.y;
\r\n\t
that.closeBtn.x = that.bg[0].width - that.closeBtn.width + 20;
\r\n\t
that.closeBtn.y = -10;
\r\n\t
var str = e.target.name.split('_');
\r\n\t
if (str && str.length > 0)
\r\n\t
var index = str[1];
\r\n\t
that.ALabel[0].text = that.QText[index];
\r\n\t
that.ALabel[1].text = that.AText[index];
\r\n\t
that.QlabelGroup.visible = false;
\r\n\t
that.ActlabelGroup.visible = false;
\r\n\t
that.AlabelGroup.visible = true;
\r\n\t
this.AScrView.scrollTo(-1);
\r\n\t
that.showText();
\r\n\t
if (props.type == 0) {
\r\n\t
showLog(getlogItem(30));
\r\n\t
}
\r\n\t
else if (props.type == 1) {
\r\n\t
showLog(getlogItem(80));
\r\n\t
}
\r\n\t
};
\r\n\t
QAText.prototype.showActLabelGroup = function (type) {
\r\n\t
var index = type;
\r\n\t
var that = this;
\r\n\t
that.x = that.smallBgOrigin.x;
\r\n\t
that.y = that.smallBgOrigin.y;
\r\n\t
that.closeBtn.x = that.bg[2].width - that.closeBtn.width - 10;
\r\n\t
that.closeBtn.y = 20;
\r\n\t
that.ActLabel.text = that.ActText[index];
\r\n\t
that.QlabelGroup.visible = false;
\r\n\t
that.AlabelGroup.visible = false;
\r\n\t
that.ActlabelGroup.visible = true;
\r\n\t
that.showText();
\r\n\t
if (!that.actLabelTimer) {
\r\n\t
that.actLabelTimer = setTimeout(function () {
\r\n\t
that.ActlabelGroup.visible = false;
\r\n\t
that.hideText();
\r\n\t
clearTimeout(that.actLabelTimer);
\r\n\t
}, 3000);
\r\n\t
}
\r\n\t
else {
\r\n\t
clearTimeout(that.actLabelTimer);
\r\n\t
that.actLabelTimer = setTimeout(function () {
\r\n\t
that.hideText();
\r\n\t
that.ActlabelGroup.visible = false;
\r\n\t
}, 3000);
\r\n\t
}
\r\n\t
};
\r\n\t
QAText.prototype.setBigBgPositon = function (x, y) {
\r\n\t
this.bigBgOrigin.x = x;
\r\n\t
this.bigBgOrigin.y = y;
\r\n\t
};
\r\n\t
QAText.prototype.setSmallBgPositon = function (x, y) {
\r\n\t
this.smallBgOrigin.x = x;
\r\n\t
this.smallBgOrigin.y = y;
\r\n\t
};
\r\n\t
QAText.prototype.getBigBgSize = function () {
\r\n\t
return { w: this.bg[0].width, h: this.bg[0].height };
\r\n\t
};
\r\n\t
QAText.prototype.getSmallBgSize = function () {
\r\n\t
return { w: this.bg[2].width, h: this.bg[2].height };
\r\n\t
};
\r\n\t
QAText.prototype.showText = function () {
\r\n\t
this.visible = true;
\r\n\t
};
\r\n\t
QAText.prototype.hideText = function () {
\r\n\t
if (this.actLabelTimer) {
\r\n\t
clearTimeout(this.actLabelTimer);
\r\n\t
}
\r\n\t
engine.globalEvent.dispatchEvent(
\"
hideRect
\"
);
\r\n\t
this.visible = false;
\r\n\t
};
\r\n\t
return QAText;
\r\n\t
}(engine.Sprite));
\n\n\t
var TestView = (function (_super) {
\r\n\t
tslib.__extends(TestView, _super);
\r\n\t
function TestView() {
\r\n\t
var _this = _super.call(this) || this;
\r\n\t
_this.qaisOpen = false;
\r\n\t
_this.addEventListener(engine.Event.ADDED_TO_STAGE, _this.setup, _this);
\r\n\t
return _this;
\r\n\t
}
\r\n\t
TestView.prototype.setup = function () {
\r\n\t
var that = this;
\r\n\t
that.removeEventListener(engine.Event.ADDED_TO_STAGE, this.setup, this);
\r\n\t
that.rect = new engine.Rect();
\r\n\t
that.rect.fillColor =
\"
#000000
\"
;
\r\n\t
that.rect.alpha = 0.7;
\r\n\t
that.rect.width = 2000;
\r\n\t
that.rect.height = 2000;
\r\n\t
that.rect.visible = false;
\r\n\t
that.addChild(that.rect);
\r\n\t
that.breathSvga = createSvga(
\"
常规呼吸动作
\"
);
\r\n\t
that.waveSvga = createSvga(
\"
招手
\"
);
\r\n\t
that.waveSvga.visible = false;
\r\n\t
that.breathSvga.visible = true;
\r\n\t
that.breathSvga.mouseEnabled = that.waveSvga.mouseEnabled = true;
\r\n\t
that.addChild(that.breathSvga);
\r\n\t
that.addChild(that.waveSvga);
\r\n\t
that.breathSvga.x = that.waveSvga.x = engine.gameStage.stage.width - 178 * 0.7;
\r\n\t
that.breathSvga.y = that.waveSvga.y = engine.gameStage.stage.height / 3 * 2 - 60;
\r\n\t
that.breathSvga.gotoAndPlay(1);
\r\n\t
that.breathSvga.scaleX = that.breathSvga.scaleY = 0.7;
\r\n\t
that.waveSvga.scaleX = that.waveSvga.scaleY = 0.7;
\r\n\t
that.QAText = new QAText();
\r\n\t
that.addChild(that.QAText);
\r\n\t
that.QAText.setBigBgPositon(engine.gameStage.stage.width - that.QAText.getBigBgSize().w - 35, engine.gameStage.stage.height / 3 * 2 - 60 - that.QAText.getBigBgSize().h);
\r\n\t
that.QAText.setSmallBgPositon(engine.gameStage.stage.width - that.QAText.getSmallBgSize().w - 35, engine.gameStage.stage.height / 3 * 2 - 60 - that.QAText.getSmallBgSize().h);
\r\n\t
that.addEvnt();
\r\n\t
};
\r\n\t
TestView.prototype.addEvnt = function () {
\r\n\t
var that = this;
\r\n\t
that.breathSvga.addEventListener(engine.MouseEvent.CLICK, that.touchSuperManImg, that);
\r\n\t
that.waveSvga.addEventListener(engine.MouseEvent.CLICK, that.touchSuperManImg, that);
\r\n\t
engine.globalEvent.addEventListener(
\"
pictures-ActLabel
\"
, that.showActLabelGroup, that);
\r\n\t
engine.globalEvent.addEventListener(
\"
pictures-supermanAnim
\"
, that.supermanAnim, that);
\r\n\t
engine.globalEvent.addEventListener(
\"
hideRect
\"
, function () { that.rect.visible = false; }, that);
\r\n\t
};
\r\n\t
TestView.prototype.supermanAnim = function () {
\r\n\t
};
\r\n\t
TestView.prototype.touchSuperManImg = function (e) {
\r\n\t
console.log(
\"
点击蛋黄超人
\"
);
\r\n\t
var that = this;
\r\n\t
if (that.QAText.visible)
\r\n\t
return;
\r\n\t
if (props.type == 0) {
\r\n\t
clickLog(getlogItem(17));
\r\n\t
}
\r\n\t
else if (props.type == 1) {
\r\n\t
clickLog(getlogItem(51));
\r\n\t
}
\r\n\t
that.showWaveSvga();
\r\n\t
that.QAText.showQLabelGroup(null);
\r\n\t
that.rect.visible = true;
\r\n\t
};
\r\n\t
TestView.prototype.showActLabelGroup = function (e) {
\r\n\t
var that = this;
\r\n\t
that.showWaveSvga();
\r\n\t
that.QAText.showActLabelGroup(parseInt(e.data.type));
\r\n\t
};
\r\n\t
TestView.prototype.showWaveSvga = function () {
\r\n\t
var that = this;
\r\n\t
that.breathSvga.visible = false;
\r\n\t
that.waveSvga.visible = true;
\r\n\t
that.waveSvga.play(false, false);
\r\n\t
that.waveSvga.once(engine.Event.END_FRAME, function () {
\r\n\t
that.waveSvga.visible = false;
\r\n\t
that.breathSvga.gotoAndPlay(1);
\r\n\t
that.breathSvga.visible = true;
\r\n\t
}, that);
\r\n\t
};
\r\n\t
return TestView;
\r\n\t
}(engine.Container));
\n\n\t
var GameWrapper = (function (_super) {
\r\n\t
tslib.__extends(GameWrapper, _super);
\r\n\t
function GameWrapper() {
\r\n\t
var _this = _super.call(this) || this;
\r\n\t
engine.globalEvent.addEventListener(
\"
pictures-setProjectId
\"
, _this.setProjectId, _this);
\r\n\t
var testView = _this._testView = new TestView();
\r\n\t
_this.addChild(testView);
\r\n\t
return _this;
\r\n\t
}
\r\n\t
GameWrapper.prototype.setProjectId = function (event) {
\r\n\t
injectProps(event.data);
\r\n\t
Buried.oaId = event.data.projectId;
\r\n\t
Buried.appId = event.data.appId;
\r\n\t
};
\r\n\t
GameWrapper.prototype.start = function (event) {
\r\n\t
injectProps(event.data);
\r\n\t
};
\r\n\t
GameWrapper.prototype.stop = function (event) {
\r\n\t
};
\r\n\t
return GameWrapper;
\r\n\t
}(engine.Container));
\n\n\t
function index (props) {
\r\n\t
prepareProps();
\r\n\t
injectProps(props);
\r\n\t
var instance = new GameWrapper();
\r\n\t
return instance;
\r\n\t
}
\n\n\t
return index;
\n\n
})));
\n
"
}
src/custom/superman/debug/Buried.js
0 → 100644
View file @
c8ec6a6a
export
class
Buried
{
appId
;
consumerId
;
oaId
;
/**
* 初始化
*/
static
init
()
{
// appId = window["appId"];
// oaId = window["projectId"];
this
.
appId
=
window
.
CFG
.
appID
;
this
.
oaId
=
window
.
CFG
.
projectId
;
}
/**
* 创建dpm埋点数据
* @param {string} dpm 点击埋点
* @param {string} dcm 曝光埋点
* @param {string} embedDomain 埋点域名
* @returns {{dpm: string; consumerId: number; domain: string; appId: number}}
*/
static
createExposure
(
dpm
,
dcm
,
embedDomain
=
'//embedlog.duiba.com.cn'
)
{
let
dom
dom
=
"1.0.0.0"
const
exposure
=
{
dpm
:
dpm
,
dcm
:
dcm
,
// dom: dom,
appId
:
Buried
.
appId
,
domain
:
embedDomain
};
return
exposure
;
}
/**
* dpm拼接
* @param pageId 页面ID
* @param area 区域
* @param dpm 埋点号
* @returns {string}
*/
static
connectDpm
(
pageId
,
area
,
dpm
)
{
return
Buried
.
appId
+
'.'
+
pageId
+
'.'
+
area
+
'.'
+
dpm
;
}
/**
* dcm拼接
* @param typeId 类型ID
* @param contentInfo 内容信息
* @param dcm 埋点号
* @returns {string}
*/
static
connectDcm
(
typeId
,
contentInfo
,
dcm
)
{
return
typeId
+
'.'
+
Buried
.
oaId
+
'.'
+
contentInfo
+
'.'
+
dcm
;
}
/**
* 插件dcm拼接
* @param plugId 插件ID
* @param type 1 活动工具 2 主会场 4 楼层 5 游戏 7 子页面
* @returns {string}
*/
static
connectPlugDcm
(
plugId
,
type
)
{
return
212
+
'.'
+
plugId
+
'.'
+
type
+
'.'
+
Buried
.
oaId
;
}
/**
* 活动dcm拼接
* @param type 1 活动工具 2 主会场 4 楼层 5 游戏 7 子页面
* @returns {string}
*/
static
connectActivityDcm
(
type
)
{
return
202
+
'.'
+
Buried
.
oaId
+
'.'
+
type
+
'.'
+
Buried
.
oaId
;
}
}
src/custom/superman/debug/NetBuried.js
0 → 100644
View file @
c8ec6a6a
import
{
Buried
}
from
"./Buried"
;
export
class
NetBuried
{
// constructor() { }
exposure
=
[]
dpm
=
[]
dcm
=
[]
showLog
(
i
,
d
)
{
var
appId
=
window
.
CFG
.
appID
||
77208
;
var
oaId
=
window
.
CFG
.
projectId
;
if
(
d
)
{
this
.
dpm
[
i
]
=
`
${
appId
}
.110.
${
i
}
.
${
d
}
`
;
}
else
{
this
.
dpm
[
i
]
=
`
${
appId
}
.110.
${
i
}
.1`
;
}
this
.
dcm
[
i
]
=
`202.
${
oaId
}
.0.0`
;
this
.
exposure
[
i
]
=
Buried
.
createExposure
(
this
.
dpm
[
i
],
this
.
dcm
[
i
]);
this
.
_showLog
(
this
.
exposure
[
i
]);
}
clickLog
(
i
,
d
)
{
var
appId
=
window
.
CFG
.
appID
||
77208
;
var
oaId
=
window
.
CFG
.
projectId
;
if
(
d
)
{
this
.
dpm
[
i
]
=
`
${
appId
}
.110.
${
i
}
.
${
d
}
`
;
}
else
{
this
.
dpm
[
i
]
=
`
${
appId
}
.110.
${
i
}
.1`
;
}
this
.
dcm
[
i
]
=
`202.
${
oaId
}
.0.0`
;
this
.
exposure
[
i
]
=
Buried
.
createExposure
(
this
.
dpm
[
i
],
this
.
dcm
[
i
]);
this
.
_clickLog
(
this
.
exposure
[
i
]);
}
/**
* 兑吧点击埋点
* @param {IExposureData} exposure
*/
_clickLog
(
exposure
)
{
const
net
=
{
name
:
'clickLog'
,
uri
:
'/log/click'
,
type
:
'get'
,
dataType
:
'jsonp'
,
param
:
exposure
,
callback
:
null
,
hideMsg
:
true
};
this
.
send
(
net
);
}
/**
* 兑吧曝光埋点
* @param {IExposureData} exposure
*/
_showLog
(
exposure
)
{
const
net
=
{
name
:
'showLog'
,
uri
:
exposure
.
domain
+
'/exposure/standard'
,
type
:
'get'
,
dataType
:
'jsonp'
,
param
:
exposure
,
callback
:
null
,
hideMsg
:
true
};
this
.
send
(
net
);
}
/**
* 发送请求
* @param net
*/
send
(
net
)
{
let
realUrl
=
net
.
uri
;
//url加参数等特殊需求(例如再玩一次需要在dostart接口的url上加埋点)
if
(
net
.
addUrl
)
{
realUrl
+=
net
.
addUrl
;
}
window
[
'$'
].
ajax
({
type
:
net
.
type
,
url
:
realUrl
,
dataType
:
net
.
dataType
,
data
:
net
.
param
,
async
:
true
,
success
:
(
result
)
=>
{
},
error
:
(
message
)
=>
{
}
});
}
}
\ No newline at end of file
src/custom/superman/debug/app.js
0 → 100644
View file @
c8ec6a6a
/**
* Created by renjianfeng on 2020-03-13.
*/
const
customId
=
'superman'
;
(
async
function
()
{
let
customModule
=
await
fetch
(
`../meta.json`
);
customModule
=
await
customModule
.
json
();
console
.
log
(
customModule
);
await
loadAssets
(
customModule
.
assets
);
launchWithCustomModule
(
customModule
);
})();
function
launchWithCustomModule
(
customModule
)
{
//engine.registerCustomCodeModule(customModule);
engine
.
registerCustomModule
(
customId
,
window
[
customId
]);
const
{
props
:
propsOption
,
assets
}
=
customModule
;
let
props
=
engine
.
computeProps
(
customModuleProps
,
propsOption
);
const
customModuleIns
=
{
id
:
customId
,
props
,
assets
,
};
engine
.
registerCustomModules
([
customModuleIns
]);
engine
.
launchWithConfig
({
options
:
{
entrySceneView
:
'entry'
,
},
assets
:
[],
views
:
[{
name
:
'entry'
,
type
:
'node'
,
properties
:
{
x
:
0
,
y
:
0
,
}
}],
customs
:
[],
},
null
,
function
()
{
setTimeout
(()
=>
{
engine
.
addCustomModule
(
customId
,
engine
.
gameStage
.
sceneContainer
.
getChildAt
(
0
));
},
100
);
// setTimeout(() => {
// engine.globalEvent.dispatchEvent('pictures-setProjectId',{projectId:"wegg",appId:"77205"})
// },1000);
// setTimeout(() => {
// engine.globalEvent.dispatchEvent('pictures-ActLabel',{type:2})
// },1000);
// setTimeout(() => {
// engine.globalEvent.dispatchEvent('pictures-ActLabel',{type:3})
// },2000);
// // const d = engine.gameStage.sceneContainer.getChildAt(0);
// // engine.gameStage.sceneContainer.getChildAt(0).x = (d.stage.width-props.W)/2;
// // engine.gameStage.sceneContainer.getChildAt(0).y = (d.stage.height-props.H)/2;
// }, 3000);
// setTimeout(()=>{
// engine.globalEvent.dispatchEvent("pictures-reset",{})
// },10000);
// setTimeout(() => {
// engine.globalEvent.dispatchEvent('pictures-start', {
// picUrl: "http://yun.duiba.com.cn/aurora/assets/e1593b97c27077b85b92f7eaaeae1ed64a1eb79a.png",
// // picUrl: "http://yun.duiba.com.cn/aurora/assets/d23e73d37ec01931e48cbd0a4095367044c5675c.png"
// blockUrl: "888"
// });
// }, 30*1000);
});
// engine.globalEvent.addEventListener('pictures-game-fail', (e) => {
// console.log(e.type, e.data);
// });
// engine.globalEvent.addEventListener('pictures-game-success', (e) => {
// console.log(e.type, e.data);
// });
}
function
getAssetByUUID
(
uuid
)
{
return
engine
.
resolveCustomAsset
(
customId
,
uuid
);
}
function
getProps
()
{
return
engine
.
getProps
(
customId
);
}
src/custom/superman/debug/index.html
0 → 100644
View file @
c8ec6a6a
<!DOCTYPE html>
<html
lang=
"en"
>
<head>
<meta
charset=
"UTF-8"
>
<title>
test
</title>
<meta
name=
"viewport"
content=
"width=device-width,initial-scale=1, minimum-scale=1, maximum-scale=1, user-scalable=no"
/>
<meta
name=
"apple-mobile-web-app-capable"
content=
"yes"
/>
<meta
name=
"full-screen"
content=
"true"
/>
<meta
name=
"screen-orientation"
content=
"portrait"
/>
<meta
name=
"x5-fullscreen"
content=
"true"
/>
<meta
name=
"360-fullscreen"
content=
"true"
/>
<style>
html
,
body
{
padding
:
0
;
margin
:
0
;
border
:
0
;
width
:
100%
;
height
:
100%
;
overflow
:
hidden
;
position
:
absolute
;
background-color
:
gray
;
}
.game-container
{
width
:
100%
;
height
:
100%
;
line-height
:
0
;
font-size
:
0
;
}
</style>
</head>
<body>
<div
id=
"game-container"
class=
"game-container"
></div>
<script
crossorigin=
"anonymous"
src=
"//yun.duiba.com.cn/editor/zeroing/libs/engine.1de84ff79dba19e949088de63aa75af51a515e5c.js"
></script>
<script
crossorigin=
"anonymous"
src=
"//yun.duiba.com.cn/editor/zeroing/libs/svga.fd3923ae6e664251ca7981801a65809cc5f36bc3.js"
></script>
<script
src=
"https://apps.bdimg.com/libs/jquery/2.1.4/jquery.min.js"
></script>
<!-- <script src="//yun.duiba.com.cn/editor/zeroing/libs/engine.ebc906f6b50b8da0a669f77027981d5f3cb560ce.js"></script> -->
<!-- <script src="http://localhost:4002/debug/engine.js"></script>
<script src="http://localhost:4003/debug/engine-svga.js"></script> -->
<!--<script src="//yun.duiba.com.cn/editor/zeroing/libs/engine.9a9dbfda4cb2dd5508ecddfe3d95dfd88063f7b5.js"></script>-->
<script
src=
"app.js"
></script>
<script
src=
"props.js"
></script>
<script
src=
"load-assets.js"
></script>
<script
src=
"main.js"
></script>
<script>
</script>
</body>
\ No newline at end of file
src/custom/superman/debug/load-assets.js
0 → 100644
View file @
c8ec6a6a
/**
* Created by rockyl on 2020-01-21.
*/
const
assets
=
[
{
"name"
:
"玩家icon"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/5b3e30496b2d9fdafb0cf3835fd6704ce10e45b4.png"
,
"uuid"
:
"888"
,
"ext"
:
".png"
},
{
"name"
:
"雨滴"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/8564c8c9be3aead71b05a0bab8d7d07ac3f778a1.png"
,
"uuid"
:
"264a6192-d7bf-45e8-8f15-6ba2c439a532"
,
"ext"
:
".png"
},
{
"name"
:
"炸弹"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/171e92283cd13c013ee1b76d28d252ff08815d47.png"
,
"uuid"
:
"eb88b42d-e151-4c1b-94b9-7c16f7bfac29"
,
"ext"
:
".png"
},
{
"name"
:
"石块"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/99b0af0c59fe79a415a3f032149cfacc27e3ac2c.png"
,
"uuid"
:
"ab1bdabc-21ba-46bf-9299-6c638f766c88"
,
"ext"
:
".png"
},
{
"name"
:
"水花"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/93d37b4a0e367e80e375308a6b4414d72d7666fc.svga"
,
"uuid"
:
"b521bf94-20e1-44dd-8eca-d24996cbaeae"
,
"ext"
:
".svga"
},
{
"name"
:
"炸弹"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/4dd18f0689c663bbcf710a7afc4d929084d97d36.svga"
,
"uuid"
:
"322edf39-805b-4e84-9d07-5573dfeebc0e"
,
"ext"
:
".svga"
},
{
"name"
:
"玩家"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/b66300c5d4f27134b0aac3dc90a3220e8ae572eb.svga"
,
"uuid"
:
"71d8dcbc-3931-471a-b585-b3ae01b25aa6"
,
"ext"
:
".svga"
}
];
function
loadAssets
(
customModuleAssets
,
onProgress
,
onComplete
){
return
engine
.
loadAssets
(
assets
.
concat
(...
customModuleAssets
),
onProgress
,
onComplete
);
}
src/custom/superman/debug/main.js
0 → 100644
View file @
c8ec6a6a
(
function
(
global
,
factory
)
{
typeof
exports
===
'object'
&&
typeof
module
!==
'undefined'
?
module
.
exports
=
factory
(
require
(
'tslib'
))
:
typeof
define
===
'function'
&&
define
.
amd
?
define
([
'tslib'
],
factory
)
:
(
global
=
global
||
self
,
global
.
superman
=
factory
(
global
.
tslib
));
}(
this
,
(
function
(
tslib
)
{
'use strict'
;
var
props
=
{};
function
prepareProps
()
{
var
metaProps
=
getProps
();
engine
.
injectProp
(
props
,
metaProps
);
}
function
injectProps
(
p
)
{
engine
.
injectProp
(
props
,
p
);
}
var
GTime
=
(
function
()
{
function
GTime
()
{
}
GTime
.
getTimestamp
=
function
()
{
return
new
Date
().
getTime
();
};
GTime
.
GetTimeHMS
=
function
(
time
)
{
var
t
;
var
h
=
Math
.
floor
(
time
/
3600
);
var
hstr
=
h
>
9
?
h
:
'0'
+
h
;
var
m
=
Math
.
floor
((
time
%
3600
)
/
60
);
var
mstr
=
m
>
9
?
m
:
'0'
+
m
;
var
s
=
Math
.
floor
(
time
%
60
);
var
sstr
=
s
>
9
?
s
:
'0'
+
s
;
t
=
hstr
+
':'
+
mstr
+
':'
+
sstr
;
return
t
;
};
GTime
.
GetTimeMS
=
function
(
time
)
{
var
t
;
var
m
=
Math
.
floor
((
time
%
3600
)
/
60
);
var
mstr
=
m
>
9
?
m
:
'0'
+
m
;
var
s
=
Math
.
floor
(
time
%
60
);
var
sstr
=
s
>
9
?
s
:
'0'
+
s
;
t
=
mstr
+
':'
+
sstr
;
return
t
;
};
return
GTime
;
}());
function
getTexture
(
uuid
)
{
return
engine
.
Texture
.
from
(
getAssetByUUID
(
uuid
).
uuid
);
}
function
createSvga
(
name
,
anchorName
)
{
var
inst
=
new
svga
.
Svga
();
inst
.
source
=
'asset://'
+
engine
.
getAssetByName
(
name
).
uuid
;
return
inst
;
}
function
clickLog
(
exposure
)
{
var
net
=
{
name
:
'clickLog'
,
uri
:
'/log/click'
,
type
:
'get'
,
dataType
:
'jsonp'
,
param
:
exposure
,
callback
:
null
,
hideMsg
:
true
};
send
(
net
);
}
function
showLog
(
exposure
)
{
var
net
=
{
name
:
'showLog'
,
uri
:
exposure
.
domain
+
'/exposure/standard'
,
type
:
'get'
,
dataType
:
'jsonp'
,
param
:
exposure
,
callback
:
null
,
hideMsg
:
true
};
send
(
net
);
}
function
send
(
net
)
{
var
gTime
=
'?_='
+
GTime
.
getTimestamp
();
var
realUrl
=
net
.
uri
;
if
(
realUrl
.
indexOf
(
'?'
)
!=
-
1
)
{
gTime
=
'&_='
+
GTime
.
getTimestamp
();
}
if
(
net
.
addUrl
)
{
realUrl
+=
net
.
addUrl
;
}
window
[
'$'
].
ajax
({
type
:
net
.
type
,
url
:
realUrl
,
cache
:
false
,
dataType
:
net
.
dataType
,
data
:
net
.
param
,
async
:
true
,
});
}
var
Buried
=
(
function
()
{
function
Buried
()
{
}
Buried
.
init
=
function
()
{
};
Buried
.
createExposure
=
function
(
dpm
,
dcm
,
embedDomain
)
{
if
(
embedDomain
===
void
0
)
{
embedDomain
=
'//embedlog.duiba.com.cn'
;
}
var
exposure
=
{
dpm
:
dpm
,
dcm
:
dcm
,
appId
:
Buried
.
appId
,
domain
:
embedDomain
};
return
exposure
;
};
Buried
.
connectDpm
=
function
(
pageId
,
area
,
dpm
)
{
return
Buried
.
appId
+
'.'
+
pageId
+
'.'
+
area
+
'.'
+
dpm
;
};
Buried
.
connectDcm
=
function
(
typeId
,
contentInfo
,
dcm
)
{
return
typeId
+
'.'
+
Buried
.
oaId
+
'.'
+
contentInfo
+
'.'
+
dcm
;
};
Buried
.
connectPlugDcm
=
function
(
plugId
,
type
)
{
return
212
+
'.'
+
plugId
+
'.'
+
type
+
'.'
+
Buried
.
oaId
;
};
Buried
.
connectActivityDcm
=
function
(
type
)
{
return
202
+
'.'
+
Buried
.
oaId
+
'.'
+
type
+
'.'
+
Buried
.
oaId
;
};
Buried
.
appId
=
'0'
;
Buried
.
oaId
=
"0"
;
return
Buried
;
}());
var
getlogItem
=
function
(
i
)
{
var
Dpm
=
Buried
.
connectDpm
(
110
,
i
,
1
);
var
Dcm
=
Buried
.
connectDcm
(
202
,
0
,
0
);
return
Buried
.
createExposure
(
Dpm
,
Dcm
);
};
var
QAText
=
(
function
(
_super
)
{
tslib
.
__extends
(
QAText
,
_super
);
function
QAText
()
{
var
_this
=
_super
.
call
(
this
)
||
this
;
_this
.
bg
=
[];
_this
.
bgTexture
=
[];
_this
.
QLabel
=
[];
_this
.
ALabel
=
[];
_this
.
addEventListener
(
engine
.
Event
.
ADDED_TO_STAGE
,
_this
.
setup
,
_this
);
_this
.
init
();
return
_this
;
}
QAText
.
prototype
.
init
=
function
()
{
var
that
=
this
;
that
.
bigBgOrigin
=
new
engine
.
Point
();
that
.
smallBgOrigin
=
new
engine
.
Point
();
that
.
QText
=
props
.
QTextStrArr
.
split
(
','
);
console
.
log
(
props
.
QTextStrArr
.
split
(
','
));
that
.
AText
=
props
.
ATextStrArr
.
split
(
','
);
console
.
log
(
props
.
ATextStrArr
.
split
(
','
));
that
.
ActText
=
props
.
ACTTextStrArr
.
split
(
','
);
console
.
log
(
props
.
ACTTextStrArr
.
split
(
','
));
};
QAText
.
prototype
.
setup
=
function
()
{
var
that
=
this
;
that
.
removeEventListener
(
engine
.
Event
.
ADDED_TO_STAGE
,
that
.
setup
,
that
);
that
.
hideText
();
that
.
setGroup
();
that
.
setQLabel
();
that
.
setALabel
();
that
.
setActLabel
();
that
.
setEvent
();
};
QAText
.
prototype
.
setEvent
=
function
()
{
};
QAText
.
prototype
.
setGroup
=
function
()
{
var
that
=
this
;
that
.
QlabelGroup
=
new
engine
.
Sprite
();
that
.
addChild
(
that
.
QlabelGroup
);
that
.
QlabelGroup
.
visible
=
false
;
that
.
AlabelGroup
=
new
engine
.
Sprite
();
that
.
addChild
(
that
.
AlabelGroup
);
that
.
AlabelGroup
.
visible
=
false
;
that
.
ActlabelGroup
=
new
engine
.
Sprite
();
that
.
addChild
(
that
.
ActlabelGroup
);
that
.
ActlabelGroup
.
visible
=
false
;
for
(
var
i
=
0
;
i
<
3
;
i
++
)
{
var
bg
=
new
engine
.
Image
();
if
(
i
<
2
)
{
bg
.
texture
=
getTexture
(
"21d8b7ca-6ed3-44e5-ada0-f0433f471ac9"
);
if
(
i
==
0
)
{
that
.
QlabelGroup
.
addChild
(
bg
);
}
else
{
that
.
AlabelGroup
.
addChild
(
bg
);
}
}
else
{
bg
.
texture
=
getTexture
(
"9e4d1860-4762-4ac1-bc44-b3dd8fb307a6"
);
that
.
ActlabelGroup
.
addChild
(
bg
);
}
that
.
bg
.
push
(
bg
);
}
that
.
closeBtn
=
new
engine
.
Image
(
getTexture
(
"76f2c800-2174-4a90-ad6d-5853e95eb144"
));
that
.
addChild
(
that
.
closeBtn
);
that
.
closeBtn
.
mouseEnabled
=
true
;
that
.
closeBtn
.
addEventListener
(
engine
.
MouseEvent
.
CLICK
,
that
.
hideText
,
that
);
that
.
QScrList
=
new
engine
.
ScrollView
();
that
.
QlabelGroup
.
addChild
(
that
.
QScrList
);
that
.
QScrList
.
x
=
30
;
that
.
QScrList
.
y
=
85
;
that
.
QScrList
.
width
=
that
.
bg
[
0
].
width
-
50
;
that
.
QScrList
.
height
=
195
;
};
QAText
.
prototype
.
setQText
=
function
(
e
)
{
console
.
log
(
'engine.Event.UPDATE_DATA'
,
e
);
e
.
target
.
getChildByName
(
'问题文本'
).
text
=
e
.
data
;
e
.
target
.
name
=
'Q_'
+
e
.
data
.
substring
(
0
,
1
);
};
QAText
.
prototype
.
setQLabel
=
function
()
{
var
that
=
this
;
var
label
=
new
engine
.
Label
();
label
.
text
=
'你想问哪些问题?'
;
label
.
x
=
30
;
label
.
y
=
30
;
label
.
size
=
34
;
label
.
width
=
that
.
bg
[
0
].
width
-
50
;
that
.
QlabelGroup
.
addChild
(
label
);
for
(
var
i
=
0
;
i
<
that
.
QText
.
length
;
i
++
)
{
var
img
=
new
engine
.
Image
(
getTexture
(
"8546dcf7-a6e8-4ba2-89f7-b929118e473a"
));
that
.
QScrList
.
addChild
(
img
);
img
.
name
=
'Q_'
+
i
;
img
.
y
=
5
+
i
*
50
;
img
.
x
=
that
.
QScrList
.
width
-
img
.
width
;
img
.
mouseEnabled
=
true
;
img
.
addEventListener
(
engine
.
MouseEvent
.
CLICK
,
that
.
showALabelGroup
,
that
);
var
label_1
=
new
engine
.
Label
();
that
.
QScrList
.
addChild
(
label_1
);
label_1
.
name
=
'Q_'
+
i
;
label_1
.
text
=
that
.
QText
[
i
];
label_1
.
fillColor
=
"#d36800"
;
label_1
.
size
=
24
;
label_1
.
width
=
img
.
x
;
label_1
.
height
=
50
;
label_1
.
y
=
img
.
y
;
label_1
.
mouseEnabled
=
true
;
label_1
.
addEventListener
(
engine
.
MouseEvent
.
CLICK
,
that
.
showALabelGroup
,
that
);
that
.
QLabel
.
push
(
label_1
);
}
};
QAText
.
prototype
.
setALabel
=
function
()
{
var
that
=
this
;
that
.
AScrView
=
new
engine
.
ScrollView
();
that
.
AlabelGroup
.
addChild
(
that
.
AScrView
);
that
.
AScrView
.
x
=
32
;
that
.
AScrView
.
y
=
62
;
that
.
AScrView
.
width
=
that
.
bg
[
0
].
width
-
55
;
that
.
AScrView
.
height
=
that
.
bg
[
0
].
height
-
120
;
for
(
var
i
=
0
;
i
<
2
;
i
++
)
{
var
label
=
new
engine
.
Label
();
label
.
x
=
0
;
label
.
y
=
5
+
i
*
40
;
label
.
size
=
24
;
label
.
width
=
that
.
AScrView
.
width
;
label
.
lineSpacing
=
11
;
label
.
lineType
=
engine
.
TEXT_lINETYPE
.
MULTI
;
that
.
AScrView
.
addChild
(
label
);
that
.
ALabel
.
push
(
label
);
}
that
.
returnBtn
=
new
engine
.
Image
(
getTexture
(
'2a555da9-dc05-4046-a5fb-551f0c2692fa'
));
that
.
AlabelGroup
.
addChild
(
that
.
returnBtn
);
that
.
returnBtn
.
x
=
18
;
that
.
returnBtn
.
y
=
20
;
that
.
returnBtn
.
mouseEnabled
=
true
;
that
.
returnBtn
.
addEventListener
(
engine
.
MouseEvent
.
CLICK
,
that
.
showQLabelGroup
,
that
);
};
QAText
.
prototype
.
setActLabel
=
function
()
{
var
that
=
this
;
that
.
ActLabel
=
new
engine
.
Label
();
that
.
ActlabelGroup
.
addChild
(
that
.
ActLabel
);
that
.
ActLabel
.
x
=
0
;
that
.
ActLabel
.
y
=
that
.
getSmallBgSize
().
h
*
0.5
-
24
;
that
.
ActLabel
.
width
=
that
.
getSmallBgSize
().
w
;
that
.
ActLabel
.
textAlign
=
engine
.
TEXT_ALIGN
.
CENTER
;
that
.
ActLabel
.
size
=
24
;
};
QAText
.
prototype
.
showQLabelGroup
=
function
(
e
)
{
var
that
=
this
;
if
(
e
&&
e
.
target
==
that
.
returnBtn
)
{
if
(
props
.
type
==
0
)
{
clickLog
(
getlogItem
(
30
));
}
else
if
(
props
.
type
==
1
)
{
clickLog
(
getlogItem
(
80
));
}
}
that
.
x
=
that
.
bigBgOrigin
.
x
;
that
.
y
=
that
.
bigBgOrigin
.
y
;
that
.
closeBtn
.
x
=
that
.
bg
[
0
].
width
-
that
.
closeBtn
.
width
+
20
;
that
.
closeBtn
.
y
=
-
10
;
that
.
AlabelGroup
.
visible
=
false
;
that
.
ActlabelGroup
.
visible
=
false
;
that
.
QlabelGroup
.
visible
=
true
;
that
.
QScrList
.
scrollTo
(
-
1
);
that
.
showText
();
};
QAText
.
prototype
.
showALabelGroup
=
function
(
e
)
{
console
.
log
(
"展示答案"
+
e
.
target
.
name
);
var
that
=
this
;
that
.
x
=
that
.
bigBgOrigin
.
x
;
that
.
y
=
that
.
bigBgOrigin
.
y
;
that
.
closeBtn
.
x
=
that
.
bg
[
0
].
width
-
that
.
closeBtn
.
width
+
20
;
that
.
closeBtn
.
y
=
-
10
;
var
str
=
e
.
target
.
name
.
split
(
'_'
);
if
(
str
&&
str
.
length
>
0
)
var
index
=
str
[
1
];
that
.
ALabel
[
0
].
text
=
that
.
QText
[
index
];
that
.
ALabel
[
1
].
text
=
that
.
AText
[
index
];
that
.
QlabelGroup
.
visible
=
false
;
that
.
ActlabelGroup
.
visible
=
false
;
that
.
AlabelGroup
.
visible
=
true
;
this
.
AScrView
.
scrollTo
(
-
1
);
that
.
showText
();
if
(
props
.
type
==
0
)
{
showLog
(
getlogItem
(
30
));
}
else
if
(
props
.
type
==
1
)
{
showLog
(
getlogItem
(
80
));
}
};
QAText
.
prototype
.
showActLabelGroup
=
function
(
type
)
{
var
index
=
type
;
var
that
=
this
;
that
.
x
=
that
.
smallBgOrigin
.
x
;
that
.
y
=
that
.
smallBgOrigin
.
y
;
that
.
closeBtn
.
x
=
that
.
bg
[
2
].
width
-
that
.
closeBtn
.
width
-
10
;
that
.
closeBtn
.
y
=
20
;
that
.
ActLabel
.
text
=
that
.
ActText
[
index
];
that
.
QlabelGroup
.
visible
=
false
;
that
.
AlabelGroup
.
visible
=
false
;
that
.
ActlabelGroup
.
visible
=
true
;
that
.
showText
();
if
(
!
that
.
actLabelTimer
)
{
that
.
actLabelTimer
=
setTimeout
(
function
()
{
that
.
ActlabelGroup
.
visible
=
false
;
that
.
hideText
();
clearTimeout
(
that
.
actLabelTimer
);
},
3000
);
}
else
{
clearTimeout
(
that
.
actLabelTimer
);
that
.
actLabelTimer
=
setTimeout
(
function
()
{
that
.
hideText
();
that
.
ActlabelGroup
.
visible
=
false
;
},
3000
);
}
};
QAText
.
prototype
.
setBigBgPositon
=
function
(
x
,
y
)
{
this
.
bigBgOrigin
.
x
=
x
;
this
.
bigBgOrigin
.
y
=
y
;
};
QAText
.
prototype
.
setSmallBgPositon
=
function
(
x
,
y
)
{
this
.
smallBgOrigin
.
x
=
x
;
this
.
smallBgOrigin
.
y
=
y
;
};
QAText
.
prototype
.
getBigBgSize
=
function
()
{
return
{
w
:
this
.
bg
[
0
].
width
,
h
:
this
.
bg
[
0
].
height
};
};
QAText
.
prototype
.
getSmallBgSize
=
function
()
{
return
{
w
:
this
.
bg
[
2
].
width
,
h
:
this
.
bg
[
2
].
height
};
};
QAText
.
prototype
.
showText
=
function
()
{
this
.
visible
=
true
;
};
QAText
.
prototype
.
hideText
=
function
()
{
if
(
this
.
actLabelTimer
)
{
clearTimeout
(
this
.
actLabelTimer
);
}
engine
.
globalEvent
.
dispatchEvent
(
"hideRect"
);
this
.
visible
=
false
;
};
return
QAText
;
}(
engine
.
Sprite
));
var
TestView
=
(
function
(
_super
)
{
tslib
.
__extends
(
TestView
,
_super
);
function
TestView
()
{
var
_this
=
_super
.
call
(
this
)
||
this
;
_this
.
qaisOpen
=
false
;
_this
.
addEventListener
(
engine
.
Event
.
ADDED_TO_STAGE
,
_this
.
setup
,
_this
);
return
_this
;
}
TestView
.
prototype
.
setup
=
function
()
{
var
that
=
this
;
that
.
removeEventListener
(
engine
.
Event
.
ADDED_TO_STAGE
,
this
.
setup
,
this
);
that
.
rect
=
new
engine
.
Rect
();
that
.
rect
.
fillColor
=
"#000000"
;
that
.
rect
.
alpha
=
0.7
;
that
.
rect
.
width
=
2000
;
that
.
rect
.
height
=
2000
;
that
.
rect
.
visible
=
false
;
that
.
addChild
(
that
.
rect
);
that
.
breathSvga
=
createSvga
(
"常规呼吸动作"
);
that
.
waveSvga
=
createSvga
(
"招手"
);
that
.
waveSvga
.
visible
=
false
;
that
.
breathSvga
.
visible
=
true
;
that
.
breathSvga
.
mouseEnabled
=
that
.
waveSvga
.
mouseEnabled
=
true
;
that
.
addChild
(
that
.
breathSvga
);
that
.
addChild
(
that
.
waveSvga
);
that
.
breathSvga
.
x
=
that
.
waveSvga
.
x
=
engine
.
gameStage
.
stage
.
width
-
178
*
0.7
;
that
.
breathSvga
.
y
=
that
.
waveSvga
.
y
=
engine
.
gameStage
.
stage
.
height
/
3
*
2
-
60
;
that
.
breathSvga
.
gotoAndPlay
(
1
);
that
.
breathSvga
.
scaleX
=
that
.
breathSvga
.
scaleY
=
0.7
;
that
.
waveSvga
.
scaleX
=
that
.
waveSvga
.
scaleY
=
0.7
;
that
.
QAText
=
new
QAText
();
that
.
addChild
(
that
.
QAText
);
that
.
QAText
.
setBigBgPositon
(
engine
.
gameStage
.
stage
.
width
-
that
.
QAText
.
getBigBgSize
().
w
-
35
,
engine
.
gameStage
.
stage
.
height
/
3
*
2
-
60
-
that
.
QAText
.
getBigBgSize
().
h
);
that
.
QAText
.
setSmallBgPositon
(
engine
.
gameStage
.
stage
.
width
-
that
.
QAText
.
getSmallBgSize
().
w
-
35
,
engine
.
gameStage
.
stage
.
height
/
3
*
2
-
60
-
that
.
QAText
.
getSmallBgSize
().
h
);
that
.
addEvnt
();
};
TestView
.
prototype
.
addEvnt
=
function
()
{
var
that
=
this
;
that
.
breathSvga
.
addEventListener
(
engine
.
MouseEvent
.
CLICK
,
that
.
touchSuperManImg
,
that
);
that
.
waveSvga
.
addEventListener
(
engine
.
MouseEvent
.
CLICK
,
that
.
touchSuperManImg
,
that
);
engine
.
globalEvent
.
addEventListener
(
"pictures-ActLabel"
,
that
.
showActLabelGroup
,
that
);
engine
.
globalEvent
.
addEventListener
(
"pictures-supermanAnim"
,
that
.
supermanAnim
,
that
);
engine
.
globalEvent
.
addEventListener
(
"hideRect"
,
function
()
{
that
.
rect
.
visible
=
false
;
},
that
);
};
TestView
.
prototype
.
supermanAnim
=
function
()
{
};
TestView
.
prototype
.
touchSuperManImg
=
function
(
e
)
{
console
.
log
(
"点击蛋黄超人"
);
var
that
=
this
;
if
(
that
.
QAText
.
visible
)
return
;
if
(
props
.
type
==
0
)
{
clickLog
(
getlogItem
(
17
));
}
else
if
(
props
.
type
==
1
)
{
clickLog
(
getlogItem
(
51
));
}
that
.
showWaveSvga
();
that
.
QAText
.
showQLabelGroup
(
null
);
that
.
rect
.
visible
=
true
;
};
TestView
.
prototype
.
showActLabelGroup
=
function
(
e
)
{
var
that
=
this
;
that
.
showWaveSvga
();
that
.
QAText
.
showActLabelGroup
(
parseInt
(
e
.
data
.
type
));
};
TestView
.
prototype
.
showWaveSvga
=
function
()
{
var
that
=
this
;
that
.
breathSvga
.
visible
=
false
;
that
.
waveSvga
.
visible
=
true
;
that
.
waveSvga
.
play
(
false
,
false
);
that
.
waveSvga
.
once
(
engine
.
Event
.
END_FRAME
,
function
()
{
that
.
waveSvga
.
visible
=
false
;
that
.
breathSvga
.
gotoAndPlay
(
1
);
that
.
breathSvga
.
visible
=
true
;
},
that
);
};
return
TestView
;
}(
engine
.
Container
));
var
GameWrapper
=
(
function
(
_super
)
{
tslib
.
__extends
(
GameWrapper
,
_super
);
function
GameWrapper
()
{
var
_this
=
_super
.
call
(
this
)
||
this
;
engine
.
globalEvent
.
addEventListener
(
"pictures-setProjectId"
,
_this
.
setProjectId
,
_this
);
var
testView
=
_this
.
_testView
=
new
TestView
();
_this
.
addChild
(
testView
);
return
_this
;
}
GameWrapper
.
prototype
.
setProjectId
=
function
(
event
)
{
injectProps
(
event
.
data
);
Buried
.
oaId
=
event
.
data
.
projectId
;
Buried
.
appId
=
event
.
data
.
appId
;
};
GameWrapper
.
prototype
.
start
=
function
(
event
)
{
injectProps
(
event
.
data
);
};
GameWrapper
.
prototype
.
stop
=
function
(
event
)
{
};
return
GameWrapper
;
}(
engine
.
Container
));
function
index
(
props
)
{
prepareProps
();
injectProps
(
props
);
var
instance
=
new
GameWrapper
();
return
instance
;
}
return
index
;
})));
//# sourceMappingURL=main.js.map
\ No newline at end of file
src/custom/superman/debug/main.js.map
0 → 100644
View file @
c8ec6a6a
{"version":3,"file":"index.js","sources":["src/custom/superman/src/props.ts","src/custom/superman/src/game/GTime.ts","src/custom/superman/src/game/utils.ts","src/custom/superman/src/game/Buried.ts","src/custom/superman/src/game/getlogItem.ts","src/custom/superman/src/game/QAText.ts","src/custom/superman/src/game/TestView.ts","src/custom/superman/src/game/GameWrapper.ts","src/custom/superman/src/index.ts"],"sourcesContent":["/**\r\n * Created by rockyl on 2020-01-21.\r\n */\r\n\r\nexport let props: any = {};\r\n\r\nexport function prepareProps() {\r\n\tlet metaProps = getProps();\r\n\r\n\tengine.injectProp(props, metaProps);\r\n}\r\n\r\nexport function injectProps(p) {\r\n\tengine.injectProp(props, p);\r\n}\r\n","\r\nexport class GTime {\r\n /**\r\n * 获取当前时间戳\r\n * @returns {number}\r\n */\r\n public static getTimestamp(): number {\r\n return new Date().getTime();\r\n }\r\n\r\n /**\r\n * 转化时分秒\r\n * @param time \r\n */\r\n public static GetTimeHMS(time:number):string{\r\n let t;\r\n\r\n let h = Math.floor(time / 3600);\r\n let hstr = h > 9 ? h : '0' + h;\r\n\r\n let m = Math.floor((time % 3600) / 60);\r\n let mstr = m > 9 ? m : '0' + m;\r\n\r\n let s = Math.floor(time % 60);\r\n let sstr = s > 9 ? s : '0' + s;\r\n\r\n t = hstr + ':' + mstr + ':' + sstr;\r\n\r\n return t;\r\n }\r\n\r\n /**\r\n * 转化分秒\r\n * @param time \r\n */\r\n public static GetTimeMS(time:number):string{\r\n let t;\r\n\r\n let m = Math.floor((time % 3600) / 60);\r\n let mstr = m > 9 ? m : '0' + m;\r\n\r\n let s = Math.floor(time % 60);\r\n let sstr = s > 9 ? s : '0' + s;\r\n\r\n t = mstr + ':' + sstr;\r\n\r\n return t;\r\n }\r\n}","/**\r\n * Created by rockyl on 2020-01-21.\r\n */\r\nimport {IExposureData} from './IExposureData'\r\nimport {INetData} from './INetData'\r\nimport { GTime } from './GTime';\r\n\r\nexport function getTexture(uuid) {\r\n\treturn engine.Texture.from(getAssetByUUID(uuid).uuid);\r\n}\r\n\r\nexport function getTextureByName(name) {\r\n\treturn getTexture(engine.getAssetByName(name).uuid);\r\n}\r\n\r\nexport function playSound(name) {\r\n\tengine.playSound(engine.getAssetByName(name).uuid, {keep: true});\r\n}\r\nexport function createSvga(name, anchorName?) {\r\n\tlet inst = new svga.Svga();\r\n\tinst.source = 'asset://' + engine.getAssetByName(name).uuid;\r\n\treturn inst;\r\n}\r\n\r\nexport function getIndexFromRC(row,col,maxCol){\r\n\tlet index;\r\n\tindex = row * maxCol + col ;\r\n\treturn index\r\n}\r\n\r\n\r\n\r\n\r\nexport function getRandomArray(array){\r\n\tarray.sort(function() {\r\n\t\treturn .5 - Math.random();\r\n\t});\r\n}\r\n\r\n/**\r\n * 兑吧点击埋点\r\n * @param {IExposureData} exposure\r\n */\r\n export function clickLog(exposure: IExposureData): void {\r\n const net: INetData = {\r\n name: 'clickLog',\r\n uri: '/log/click',\r\n type: 'get',\r\n dataType: 'jsonp',\r\n param: exposure,\r\n callback: null,\r\n hideMsg: true\r\n };\r\n send(net);\r\n }\r\n\r\n /**\r\n * 兑吧曝光埋点\r\n * @param {IExposureData} exposure\r\n */\r\n export function showLog(exposure: IExposureData): void {\r\n const net: INetData = {\r\n name: 'showLog',\r\n uri: exposure.domain + '/exposure/standard',\r\n type: 'get',\r\n dataType: 'jsonp',\r\n param: exposure,\r\n callback: null,\r\n hideMsg: true\r\n };\r\n send(net);\r\n }\r\n\r\n /**\r\n * 发送请求\r\n * @param net \r\n */\r\n export function send(net: INetData): void {\r\n let gTime: string = '?_=' + GTime.getTimestamp();\r\n let realUrl: string = net.uri;\r\n if (realUrl.indexOf('?') != -1) {\r\n gTime = '&_=' + GTime.getTimestamp();\r\n }\r\n\r\n //url加参数等特殊需求(例如再玩一次需要在dostart接口的url上加埋点)\r\n if (net.addUrl) {\r\n realUrl += net.addUrl;\r\n }\r\n\r\n window['$'].ajax({\r\n type: net.type,\r\n // url: realUrl + gTime,\r\n url: realUrl,\r\n cache: false,\r\n dataType: net.dataType,\r\n data: net.param,\r\n async: true,\r\n // success: (result) => {\r\n // this.onResponse(net, result);\r\n // },\r\n // error: (message) => {\r\n // this.onError(net);\r\n // }\r\n });\r\n }\r\n\r\n ","// import { DataManager } from './../manager/DataManager';\r\nimport { IExposureData } from './IExposureData';\r\n// import { IExposureData } from '..';\r\n\r\nexport class Buried {\r\n public static appId: string = '0';\r\n public static consumerId: number;\r\n public static oaId: string = \"0\";\r\n\r\n /**\r\n * 初始化\r\n */\r\n public static init(): void {\r\n // if(DataManager.ins.gameCfgData) {\r\n // this.appId = DataManager.ins.gameCfgData.appInfo.appId;\r\n // this.consumerId = DataManager.ins.getInfoData.consumerId;\r\n // this.oaId = DataManager.ins.gameCfgData.gameInfo.oaId;\r\n // } else if(DataManager.ins.customCfgData){\r\n // this.appId = DataManager.ins.customCfgData.appId;\r\n // this.consumerId = DataManager.ins.customCfgData.consumerId;\r\n // this.oaId = DataManager.ins.customCfgData.oaId ;\r\n // } else if(DataManager.ins.petIndexData && DataManager.ins.petIndexData.appId && DataManager.ins.petIndexData.activityId){\r\n // this.appId = DataManager.ins.petIndexData.appId;\r\n // this.consumerId = DataManager.ins.petIndexData.consumerId;\r\n // this.oaId = DataManager.ins.petIndexData.activityId ;\r\n // } else if(DataManager.ins.petsIndexData && DataManager.ins.petsIndexData.appId && DataManager.ins.petsIndexData.activityId){\r\n // this.appId = DataManager.ins.petsIndexData.appId;\r\n // this.consumerId = DataManager.ins.petsIndexData.consumerId;\r\n // this.oaId = DataManager.ins.petsIndexData.activityId ;\r\n // }\r\n }\r\n\r\n /**\r\n * 创建dpm埋点数据\r\n * @param {string} dpm 点击埋点\r\n * @param {string} dcm 曝光埋点\r\n * @param {string} embedDomain 埋点域名\r\n * @returns {{dpm: string; consumerId: number; domain: string; appId: number}}\r\n */\r\n public static createExposure(dpm: string, dcm: string, embedDomain = '//embedlog.duiba.com.cn'): IExposureData {\r\n const exposure: any = {\r\n dpm: dpm,\r\n dcm: dcm,\r\n appId: Buried.appId,\r\n domain: embedDomain\r\n };\r\n return exposure;\r\n }\r\n\r\n /**\r\n * dpm拼接\r\n * @param pageId 页面ID \r\n * @param area 区域\r\n * @param dpm 埋点号\r\n * @returns {string}\r\n */\r\n public static connectDpm(pageId: number, area: number, dpm: number): string {\r\n return Buried.appId + '.' + pageId + '.' + area + '.' + dpm;\r\n }\r\n\r\n /**\r\n * dcm拼接\r\n * @param typeId 类型ID\r\n * @param contentInfo 内容信息\r\n * @param dcm 埋点号\r\n * @returns {string}\r\n */\r\n public static connectDcm(typeId: number, contentInfo: number, dcm: number): string {\r\n return typeId + '.' + Buried.oaId + '.' + contentInfo + '.' + dcm;\r\n }\r\n\r\n /**\r\n * 插件dcm拼接\r\n * @param plugId 插件ID\r\n * @param type 1 活动工具 2 主会场 4 楼层 5 游戏 7 子页面\r\n * @returns {string}\r\n */\r\n public static connectPlugDcm(plugId: number, type: number): string {\r\n return 212 + '.' + plugId + '.' + type + '.' + Buried.oaId;\r\n }\r\n\r\n /**\r\n * 活动dcm拼接\r\n * @param type 1 活动工具 2 主会场 4 楼层 5 游戏 7 子页面\r\n * @returns {string}\r\n */\r\n public static connectActivityDcm(type: number): string {\r\n return 202 + '.' + Buried.oaId + '.' + type + '.' + Buried.oaId;\r\n }\r\n\r\n}\r\n","import { Buried } from \"./Buried\";\r\nimport {props} from '../props'\r\n\r\nexport const getlogItem = (i) =>{\r\n const Dpm = Buried.connectDpm(110, i, 1); // 点击埋点\r\n const Dcm = Buried.connectDcm(202, 0, 0); // 曝光埋点\r\n return Buried.createExposure(Dpm, Dcm);\r\n};","import { getTexture, clickLog, showLog } from \"./utils\";\r\nimport {props, injectProps} from \"../props\";\r\nimport { getlogItem } from \"./getlogItem\";\r\n\r\nexport default class QAText extends engine.Sprite{\r\n bg:engine.Image[] = [];\r\n bgTexture:engine.Texture[] = [];\r\n titelLabel:engine.Label;\r\n QLabel:engine.Label[] = [];\r\n ALabel:engine.Label[] = [];\r\n ActLabel:engine.Label;\r\n QlabelGroup:engine.Sprite;\r\n AlabelGroup:engine.Sprite;\r\n ActlabelGroup:engine.Sprite;\r\n QText:string[]; //问题文本组\r\n AText:string[]; //回答文本组\r\n ActText:string[]; //互动文本组\r\n bigBgOrigin:engine.Point;\r\n smallBgOrigin:engine.Point;\r\n returnBtn:engine.Image; //回答文本组的返回按钮\r\n closeBtn:engine.Image; //关闭按钮\r\n QScrList:engine.ScrollView;//问题滚动视图\r\n AScrView:engine.ScrollView;//答案滚动视图\r\n\r\n actLabelTimer;\r\n\r\n constructor(){\r\n super();\r\n this.addEventListener(engine.Event.ADDED_TO_STAGE,this.setup,this)\r\n this.init();\r\n }\r\n\r\n init(){\r\n var that = this; \r\n that.bigBgOrigin = new engine.Point();\r\n that.smallBgOrigin = new engine.Point();\r\n that.QText = props.QTextStrArr.split(',');\r\n //that.QText.unshift('你想问哪些问题?')\r\n console.log(props.QTextStrArr.split(','));\r\n\r\n that.AText = props.ATextStrArr.split(',')\r\n console.log(props.ATextStrArr.split(','));\r\n \r\n that.ActText = props.ACTTextStrArr.split(',');\r\n console.log(props.ACTTextStrArr.split(','));\r\n }\r\n\r\n setup(){\r\n var that = this;\r\n that.removeEventListener(engine.Event.ADDED_TO_STAGE,that.setup,that);\r\n that.hideText();\r\n that.setGroup();\r\n that.setQLabel();\r\n that.setALabel();\r\n that.setActLabel();\r\n that.setEvent();\r\n }\r\n\r\n setEvent(){\r\n \r\n }\r\n\r\n /**设置各个文本组 */\r\n setGroup(){\r\n var that = this;\r\n //问题文本组\r\n that.QlabelGroup = new engine.Sprite();\r\n // that.QlabelGroup.addChild(that.bg[0]);\r\n that.addChild(that.QlabelGroup);\r\n that.QlabelGroup.visible = false;\r\n \r\n //答案文本组\r\n that.AlabelGroup = new engine.Sprite();\r\n // that.AlabelGroup.addChild(that.bg[1]);\r\n that.addChild(that.AlabelGroup)\r\n that.AlabelGroup.visible = false;\r\n\r\n //互动文本组\r\n that.ActlabelGroup = new engine.Sprite();\r\n // that.ActlabelGroup.addChild(that.bg[1]);\r\n that.addChild(that.ActlabelGroup);\r\n that.ActlabelGroup.visible = false;\r\n \r\n for(let i=0;i<3;i++){\r\n let bg = new engine.Image();\r\n if(i<2){\r\n bg.texture = getTexture(\"21d8b7ca-6ed3-44e5-ada0-f0433f471ac9\"); //大气泡\r\n if(i==0){\r\n that.QlabelGroup.addChild(bg);\r\n }else{\r\n that.AlabelGroup.addChild(bg);\r\n }\r\n }\r\n else{\r\n bg.texture = getTexture(\"9e4d1860-4762-4ac1-bc44-b3dd8fb307a6\"); //小气泡\r\n that.ActlabelGroup.addChild(bg);\r\n }\r\n that.bg.push(bg);\r\n }\r\n\r\n that.closeBtn = new engine.Image(getTexture(\"76f2c800-2174-4a90-ad6d-5853e95eb144\"));\r\n that.addChild(that.closeBtn);\r\n that.closeBtn.mouseEnabled = true;\r\n that.closeBtn.addEventListener(engine.MouseEvent.CLICK,that.hideText,that);\r\n\r\n //问题列表\r\n that.QScrList = new engine.ScrollView();\r\n that.QlabelGroup.addChild(that.QScrList);\r\n that.QScrList.x = 30;\r\n that.QScrList.y = 85;\r\n that.QScrList.width = that.bg[0].width-50;\r\n that.QScrList.height = 195;\r\n \r\n }\r\n /**设置列表内问题文本 */\r\n setQText(e){\r\n console.log('engine.Event.UPDATE_DATA', e)\r\n e.target.getChildByName('问题文本').text = e.data;\r\n e.target.name = 'Q_'+ e.data.substring(0,1);\r\n }\r\n\r\n /**设置问题文本组 */\r\n setQLabel(){\r\n var that = this;\r\n let label = new engine.Label();\r\n label.text = '你想问哪些问题?';\r\n label.x = 30;\r\n label.y = 30;\r\n label.size = 34;\r\n label.width = that.bg[0].width-50;\r\n that.QlabelGroup.addChild(label);\r\n for(let i=0;i<that.QText.length;i++){\r\n let img = new engine.Image(getTexture(\"8546dcf7-a6e8-4ba2-89f7-b929118e473a\"))\r\n that.QScrList.addChild(img);\r\n img.name = 'Q_'+i;\r\n img.y = 5 + i*50;\r\n img.x = that.QScrList.width - img.width;\r\n img.mouseEnabled = true;\r\n img.addEventListener(engine.MouseEvent.CLICK,that.showALabelGroup,that);\r\n\r\n let label = new engine.Label();\r\n that.QScrList.addChild(label);\r\n label.name = 'Q_'+i;\r\n label.text = that.QText[i];\r\n label.fillColor = \"#d36800\";\r\n label.size = 24;\r\n label.width = img.x;\r\n label.height = 50;\r\n label.y = img.y;\r\n label.mouseEnabled = true;\r\n label.addEventListener(engine.MouseEvent.CLICK,that.showALabelGroup,that);\r\n that.QLabel.push(label); \r\n \r\n }\r\n }\r\n\r\n /**设置答案文本 */\r\n setALabel(){\r\n var that = this;\r\n that.AScrView = new engine.ScrollView();\r\n that.AlabelGroup.addChild(that.AScrView);\r\n that.AScrView.x = 32\r\n that.AScrView.y = 62\r\n that.AScrView.width = that.bg[0].width - 55;\r\n that.AScrView.height = that.bg[0].height - 120;\r\n for(let i=0;i<2;i++){\r\n let label = new engine.Label();\r\n label.x = 0\r\n label.y = 5 + i * 40\r\n label.size = 24;\r\n label.width = that.AScrView.width;\r\n label.lineSpacing = 11;\r\n label.lineType = engine.TEXT_lINETYPE.MULTI;\r\n //that.AlabelGroup.addChild(label);\r\n that.AScrView.addChild(label);\r\n that.ALabel.push(label);\r\n }\r\n \r\n that.returnBtn = new engine.Image(getTexture('2a555da9-dc05-4046-a5fb-551f0c2692fa'));\r\n that.AlabelGroup.addChild(that.returnBtn);\r\n // that.returnBtn.x = that.bg[1].width - that.returnBtn.width*2;\r\n // that.returnBtn.y = that.bg[1].height - that.returnBtn.height-30;\r\n that.returnBtn.x = 18;\r\n that.returnBtn.y = 20;\r\n\r\n that.returnBtn.mouseEnabled = true;\r\n that.returnBtn.addEventListener(engine.MouseEvent.CLICK,that.showQLabelGroup,that);\r\n }\r\n\r\n /**设置互动文本 */\r\n setActLabel(){\r\n var that = this;\r\n that.ActLabel = new engine.Label();\r\n that.ActlabelGroup.addChild(that.ActLabel);\r\n that.ActLabel.x = 0;\r\n that.ActLabel.y = that.getSmallBgSize().h*0.5-24;\r\n that.ActLabel.width = that.getSmallBgSize().w;\r\n // that.ActLabel.height = that.getSmallBgSize().h;\r\n that.ActLabel.textAlign = engine.TEXT_ALIGN.CENTER;\r\n // that.ActLabel.verticalAlign = engine.VERTICAL_ALIGN.MIDDLE;\r\n that.ActLabel.size = 24;\r\n }\r\n\r\n /**展示问题组 */\r\n showQLabelGroup(e:engine.MouseEvent){\r\n var that = this;\r\n if(e&&e.target == that.returnBtn){\r\n if(props.type == 0){\r\n clickLog(getlogItem(30));\r\n }else if(props.type == 1){\r\n clickLog(getlogItem(80));\r\n }\r\n }\r\n that.x = that.bigBgOrigin.x;\r\n that.y = that.bigBgOrigin.y;\r\n that.closeBtn.x = that.bg[0].width - that.closeBtn.width + 20;\r\n that.closeBtn.y = -10;\r\n that.AlabelGroup.visible = false;\r\n that.ActlabelGroup.visible = false;\r\n that.QlabelGroup.visible = true;\r\n that.QScrList.scrollTo(-1);\r\n that.showText();\r\n \r\n }\r\n\r\n /**展示答案组 */\r\n showALabelGroup(e:engine.MouseEvent){\r\n console.log(\"展示答案\"+e.target.name);\r\n var that = this;\r\n that.x = that.bigBgOrigin.x;\r\n that.y = that.bigBgOrigin.y;\r\n that.closeBtn.x = that.bg[0].width - that.closeBtn.width + 20;\r\n that.closeBtn.y = -10;\r\n\r\n let str = e.target.name.split('_');\r\n if(str&&str.length>0)\r\n var index = str[1];\r\n that.ALabel[0].text = that.QText[index];\r\n //that.ALabel[0].visible = false;//不显示问题\r\n that.ALabel[1].text = that.AText[index];\r\n that.QlabelGroup.visible = false;\r\n that.ActlabelGroup.visible = false;\r\n that.AlabelGroup.visible = true;\r\n this.AScrView.scrollTo(-1); \r\n that.showText();\r\n if(props.type == 0){\r\n showLog(getlogItem(30));\r\n }else if(props.type == 1){\r\n showLog(getlogItem(80));\r\n }\r\n }\r\n\r\n /**展示互动组 */\r\n showActLabelGroup(type){\r\n // injectProps(event.data);\r\n let index = type;\r\n var that = this;\r\n that.x = that.smallBgOrigin.x;\r\n that.y = that.smallBgOrigin.y;\r\n that.closeBtn.x = that.bg[2].width - that.closeBtn.width-10;\r\n that.closeBtn.y = 20;\r\n that.ActLabel.text = that.ActText[index];\r\n that.QlabelGroup.visible = false;\r\n that.AlabelGroup.visible = false;\r\n that.ActlabelGroup.visible = true;\r\n that.showText();\r\n if(!that.actLabelTimer){\r\n that.actLabelTimer = setTimeout(() => {\r\n that.ActlabelGroup.visible = false;\r\n that.hideText();\r\n clearTimeout(that.actLabelTimer)\r\n }, 3000);\r\n }else{\r\n clearTimeout(that.actLabelTimer);\r\n that.actLabelTimer = setTimeout(() => {\r\n that.hideText();\r\n that.ActlabelGroup.visible = false;\r\n }, 3000);\r\n }\r\n \r\n \r\n }\r\n\r\n setBigBgPositon(x:number,y:number){\r\n this.bigBgOrigin.x = x;\r\n this.bigBgOrigin.y = y;\r\n }\r\n\r\n setSmallBgPositon(x:number,y:number){\r\n this.smallBgOrigin.x = x;\r\n this.smallBgOrigin.y = y;\r\n }\r\n\r\n getBigBgSize(){\r\n return {w:this.bg[0].width,h:this.bg[0].height}\r\n }\r\n\r\n getSmallBgSize(){\r\n return {w:this.bg[2].width,h:this.bg[2].height}\r\n }\r\n\r\n showText(){\r\n this.visible = true;\r\n }\r\n\r\n hideText(){\r\n if(this.actLabelTimer){\r\n clearTimeout(this.actLabelTimer);\r\n }\r\n engine.globalEvent.dispatchEvent(\"hideRect\");\r\n this.visible = false;\r\n }\r\n}","import {getTexture, createSvga, showLog, clickLog} from './utils'\r\nimport QAText from './QAText';\r\nimport {getlogItem} from './getlogItem';\r\nimport { props } from '../props';\r\n\r\n\r\nexport default class TestView extends engine.Container{\r\n worldTime:number;\r\n supermanImg:engine.Image;\r\n qaisOpen:boolean = false;\r\n QAText:QAText;\r\n breathSvga:svga.Svga;\r\n waveSvga:svga.Svga;\r\n rect:engine.Rect;\r\n\r\n constructor(){\r\n super()\r\n this.addEventListener(engine.Event.ADDED_TO_STAGE, this.setup, this);\r\n }\r\n\r\n setup(){\r\n var that = this;\r\n that.removeEventListener(engine.Event.ADDED_TO_STAGE, this.setup, this)\r\n that.rect = new engine.Rect();\r\n that.rect.fillColor = \"#000000\";\r\n that.rect.alpha = 0.7;\r\n that.rect.width = 2000;\r\n that.rect.height = 2000;\r\n that.rect.visible = false;\r\n that.addChild(that.rect);\r\n that.breathSvga = createSvga(\"常规呼吸动作\");\r\n that.waveSvga = createSvga(\"招手\");\r\n that.waveSvga.visible = false;\r\n that.breathSvga.visible = true;\r\n that.breathSvga.mouseEnabled = that.waveSvga.mouseEnabled = true;\r\n that.addChild(that.breathSvga);\r\n that.addChild(that.waveSvga);\r\n that.breathSvga.x = that.waveSvga.x = engine.gameStage.stage.width - 178*0.7; \r\n that.breathSvga.y = that.waveSvga.y = engine.gameStage.stage.height/3*2-60;\r\n that.breathSvga.gotoAndPlay(1);\r\n // that.breathSvga.scale = 0.6;\r\n // that.waveSvga.scale = 0.6;\r\n that.breathSvga.scaleX = that.breathSvga.scaleY = 0.7;\r\n that.waveSvga.scaleX = that.waveSvga.scaleY = 0.7;\r\n \r\n that.QAText = new QAText();\r\n that.addChild(that.QAText);\r\n that.QAText.setBigBgPositon(engine.gameStage.stage.width - that.QAText.getBigBgSize().w-35,engine.gameStage.stage.height/3*2-60 - that.QAText.getBigBgSize().h)\r\n that.QAText.setSmallBgPositon(engine.gameStage.stage.width - that.QAText.getSmallBgSize().w-35,engine.gameStage.stage.height/3*2-60 - that.QAText.getSmallBgSize().h)\r\n\r\n that.addEvnt();\r\n }\r\n\r\n addEvnt(){\r\n var that = this;\r\n // that.supermanImg.addEventListener(engine.MouseEvent.CLICK,that.touchSuperManImg,that);\r\n that.breathSvga.addEventListener(engine.MouseEvent.CLICK,that.touchSuperManImg,that);\r\n that.waveSvga.addEventListener(engine.MouseEvent.CLICK,that.touchSuperManImg,that);\r\n engine.globalEvent.addEventListener(\"pictures-ActLabel\",that.showActLabelGroup,that);\r\n engine.globalEvent.addEventListener(\"pictures-supermanAnim\",that.supermanAnim,that);\r\n engine.globalEvent.addEventListener(\"hideRect\",()=>{that.rect.visible = false},that);\r\n }\r\n\r\n /**蛋黄超人动效 */\r\n supermanAnim(){\r\n\r\n }\r\n\r\n /**点击蛋黄超人 */\r\n touchSuperManImg(e:engine.MouseEvent){\r\n console.log(\"点击蛋黄超人\")\r\n var that = this;\r\n if(that.QAText.visible) return;\r\n if(props.type == 0){\r\n clickLog(getlogItem(17))\r\n }else if(props.type == 1){\r\n clickLog(getlogItem(51))\r\n }\r\n //蛋黄超人动效\r\n that.showWaveSvga();\r\n that.QAText.showQLabelGroup(null);\r\n that.rect.visible = true;\r\n }\r\n\r\n /**展示互动文案组 */\r\n showActLabelGroup(e:engine.Event){\r\n var that = this;\r\n //蛋黄超人动效\r\n that.showWaveSvga();\r\n that.QAText.showActLabelGroup(parseInt(e.data.type))\r\n }\r\n\r\n showWaveSvga(){\r\n var that = this;\r\n that.breathSvga.visible = false;\r\n that.waveSvga.visible = true;\r\n that.waveSvga.play(false,false);\r\n that.waveSvga.once(engine.Event.END_FRAME,()=>{\r\n that.waveSvga.visible = false;\r\n that.breathSvga.gotoAndPlay(1)\r\n that.breathSvga.visible = true;\r\n },that)\r\n }\r\n\r\n\r\n}","// import GameView from \"./GameView\";\r\nimport { injectProps } from \"../props\";\r\n\r\nimport TestView from './TestView'\r\nimport { Buried } from \"./Buried\";\r\n\r\n\r\nexport class GameWrapper extends engine.Container{\r\n\t// private _gameView:GameView\r\n\t\r\n\tprivate _testView:TestView\r\n\r\n constructor(){\r\n super();\r\n // engine.globalEvent.addEventListener('pictures-start', this.start, this);\r\n // engine.globalEvent.addEventListener('pictures-stop', this.stop, this);\r\n engine.globalEvent.addEventListener(\"pictures-setProjectId\",this.setProjectId,this);\r\n\r\n\t\t//创建实例\r\n\t\t// let gameView = this._gameView = new GameView();\r\n\t\t// this.addChild(gameView);\r\n\r\n\t\tlet testView = this._testView = new TestView();\r\n\t\tthis.addChild(testView);\r\n }\r\n\r\n setProjectId(event:engine.Event){\r\n injectProps(event.data);\r\n Buried.oaId = event.data.projectId;\r\n Buried.appId = event.data.appId;\r\n }\r\n\r\n\tstart(event: engine.Event) {\r\n\t\tinjectProps(event.data);\r\n\r\n\t\t// this._status = 1;\r\n\r\n\t\t// this._testView.start();\r\n\t}\r\n\tstop(event: engine.Event) {\r\n\t\t// this._testView.stop();\r\n\t}\r\n}","\r\n\r\nimport {GameWrapper} from \"./game/GameWrapper\";\r\nimport {injectProps, prepareProps} from \"./props\";\r\n\r\nexport default function (props) {\r\n\tprepareProps();\r\n\tinjectProps(props);\r\n\r\n\tlet instance = new GameWrapper();\r\n\t\r\n\treturn instance;\r\n\t\r\n}\r\n"],"names":["__extends"],"mappings":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,UAAK,KAAmB;MAEvB;KACF,kBAAC;CAAD,CAAC,CAnCgC,MAAM,CAAC,SAAS,GAmChD;;iBCrCwB,KAAK;KAC7B,YAAY,EAAE,CAAC;KACf,WAAW,CAAC,KAAK,CAAC,CAAC;KAEnB,IAAI,QAAQ,GAAG,IAAI,WAAW,EAAE,CAAC;KAEjC,OAAO,QAAQ,CAAC;CAEjB,CAAC;;;;;;;;"}
\ No newline at end of file
src/custom/superman/debug/props.js
0 → 100644
View file @
c8ec6a6a
/**
* Created by rockyl on 2020-01-21.
*/
let
customModuleProps
=
{
};
src/custom/superman/meta.json
0 → 100644
View file @
c8ec6a6a
{
"name"
:
"蛋黄超人自定义模块"
,
"desc"
:
"蛋黄超人自定义模块1.0"
,
"props"
:
{
"QTextStrArr"
:{
"alias"
:
"问题文案组,用逗号隔开,不填为默认"
,
"type"
:
"string"
,
"default"
:
"1、什么是筑梦空间?,2、金币是什么?,3、怎么获得金币?,4、如何更改用户昵称?,5、个人信息可以进行哪些操作?,6、通过二维码添加好友之后在哪里查看?,7、我的勋章是什么?,8、任务有哪些分类?"
},
"ATextStrArr"
:{
"alias"
:
"答案文案组,用逗号隔开,不填为默认"
,
"type"
:
"string"
,
"default"
:
"筑梦空间带给用户吃喝玩乐的不同体验,在这里你可以进行生活缴费、体验本地优惠、建设我的庄园、畅玩游戏中心等等。,金币是筑梦空间中的虚拟货币,用户可以使用金币游玩游戏、种植植物、兑换实物,同时金币可以按一定比例兑换波豆,波豆可以在波豆商城兑换更丰富的商品。,用户可以通过签到、任务、参与活动以及我的庄园果实售卖方式获得金币。,用户可以点击左上角个人信息按钮进入个人信息弹窗,点击昵称旁的修改按钮对昵称进行修改。,用户可以在个人信息页面进行修改昵称、修改头像、兑换波豆、查询金币明细、扫二维码添加好友等操作。,用户A通过扫描用户B的二维码进入活动之后,双方即绑定为好友,可以排行榜-好友排行榜进行查看。,当用户在筑梦空间的各种行为动作达到一定次数时,会点亮相应的激励勋章。,任务中分为一次性任务、永久开放任务和周期更新任务,一次性任务为完成一次或多次后消失的任务,如浏览车主服务任务、升级房屋任务;永久开放任务为一直可以完成并获得奖励的任务,如邀请好友任务;周期任务为以周期(每日/周/月)为单位进行更新的任务,如分享筑梦空间、去商店购买种子任务,积极完成任务可以获得更多金币。"
},
"ACTTextStrArr"
:{
"alias"
:
"互动文案组,用逗号隔开,不填为默认"
,
"type"
:
"string"
,
"default"
:
"主人你多久没来看我了,我好想你啊,Whoooo,主人你太棒了,主人,果子都成熟了,赶紧去采摘吧,主人,有空地可以种植哦,赶紧去吧!"
},
"type"
:{
"alias"
:
"类型,用于区分所在场景,用于埋点,0:首页,1:庄园"
,
"type"
:
"number"
,
"default"
:
"0"
}
},
"assets"
:
[
{
"name"
:
"大对话泡"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/a3d49f913ee300b2834260967010a2e7b2d5c265.png"
,
"uuid"
:
"21d8b7ca-6ed3-44e5-ada0-f0433f471ac9"
,
"ext"
:
".png"
},
{
"name"
:
"小对话泡"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/c034f14785a2a36dce266cef0f46bd783ad03cb2.png"
,
"uuid"
:
"9e4d1860-4762-4ac1-bc44-b3dd8fb307a6"
,
"ext"
:
".png"
},
{
"name"
:
"蛋黄超人关闭按钮"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/7a346d4e2c2cbce5ab3ac0a74e481525b048fcdd.png"
,
"uuid"
:
"76f2c800-2174-4a90-ad6d-5853e95eb144"
,
"ext"
:
".png"
},
{
"name"
:
"返回按钮"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/8f55741c71b2aa7babe5cc517707cdd51b33c3d9.png"
,
"uuid"
:
"2a555da9-dc05-4046-a5fb-551f0c2692fa"
,
"ext"
:
".png"
},
{
"name"
:
"蛋黄超人icon"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/baeec26a873006fabf031af8c918153384a732ef.png"
,
"uuid"
:
"d5df1198-2cad-42e0-a197-fd56a2502d99"
,
"ext"
:
".png"
},
{
"name"
:
"蛋黄超人名称"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/11b02c3908bcb8d685610caafdab9785fac5fccf.png"
,
"uuid"
:
"fef58cbd-9c24-4216-896a-2799011df1dc"
,
"ext"
:
".png"
},
{
"name"
:
"右箭头"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/8be77ba8ce699c4d302cd58e4d3be06919ac732f.png"
,
"uuid"
:
"8546dcf7-a6e8-4ba2-89f7-b929118e473a"
,
"ext"
:
".png"
},
{
"name"
:
"常规呼吸动作"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/adc7212454ea1d84ac5824982a57f37d2e745b54.svga"
,
"uuid"
:
"ba2f8259-71b5-49ac-8310-08538a6b5d07"
,
"ext"
:
".svga"
},
{
"name"
:
"招手"
,
"url"
:
"//yun.duiba.com.cn/aurora/assets/cf78c2f55369b597dfc744159687dc255f18a2b4.svga"
,
"uuid"
:
"97de87e9-2ea4-4a31-9986-25edcd807c05"
,
"ext"
:
".svga"
}
],
"events"
:
{
"in"
:
{
"pictures-ActLabel"
:{
"alias"
:
"互动显示"
,
"data"
:{
"type"
:
"0:24小时未登录互动,1:任务完成互动,2:农作物成熟互动,3:有土地未种植互动"
}
},
"pictures-setProjectId"
:{
"alias"
:
"设置星速台id与appid"
,
"data"
:{
"projectId"
:
"默认为'0'"
,
"appId"
:
"默认为'0'"
}
}
},
"out"
:
{
"pictures-end"
:
{
"alias"
:
"结束"
}
}
}
}
\ No newline at end of file
src/custom/superman/src/game/Buried.ts
0 → 100644
View file @
c8ec6a6a
// import { DataManager } from './../manager/DataManager';
import
{
IExposureData
}
from
'./IExposureData'
;
// import { IExposureData } from '..';
export
class
Buried
{
public
static
appId
:
string
=
'0'
;
public
static
consumerId
:
number
;
public
static
oaId
:
string
=
"0"
;
/**
* 初始化
*/
public
static
init
():
void
{
// if(DataManager.ins.gameCfgData) {
// this.appId = DataManager.ins.gameCfgData.appInfo.appId;
// this.consumerId = DataManager.ins.getInfoData.consumerId;
// this.oaId = DataManager.ins.gameCfgData.gameInfo.oaId;
// } else if(DataManager.ins.customCfgData){
// this.appId = DataManager.ins.customCfgData.appId;
// this.consumerId = DataManager.ins.customCfgData.consumerId;
// this.oaId = DataManager.ins.customCfgData.oaId ;
// } else if(DataManager.ins.petIndexData && DataManager.ins.petIndexData.appId && DataManager.ins.petIndexData.activityId){
// this.appId = DataManager.ins.petIndexData.appId;
// this.consumerId = DataManager.ins.petIndexData.consumerId;
// this.oaId = DataManager.ins.petIndexData.activityId ;
// } else if(DataManager.ins.petsIndexData && DataManager.ins.petsIndexData.appId && DataManager.ins.petsIndexData.activityId){
// this.appId = DataManager.ins.petsIndexData.appId;
// this.consumerId = DataManager.ins.petsIndexData.consumerId;
// this.oaId = DataManager.ins.petsIndexData.activityId ;
// }
}
/**
* 创建dpm埋点数据
* @param {string} dpm 点击埋点
* @param {string} dcm 曝光埋点
* @param {string} embedDomain 埋点域名
* @returns {{dpm: string; consumerId: number; domain: string; appId: number}}
*/
public
static
createExposure
(
dpm
:
string
,
dcm
:
string
,
embedDomain
=
'//embedlog.duiba.com.cn'
):
IExposureData
{
const
exposure
:
any
=
{
dpm
:
dpm
,
dcm
:
dcm
,
appId
:
Buried
.
appId
,
domain
:
embedDomain
};
return
exposure
;
}
/**
* dpm拼接
* @param pageId 页面ID
* @param area 区域
* @param dpm 埋点号
* @returns {string}
*/
public
static
connectDpm
(
pageId
:
number
,
area
:
number
,
dpm
:
number
):
string
{
return
Buried
.
appId
+
'.'
+
pageId
+
'.'
+
area
+
'.'
+
dpm
;
}
/**
* dcm拼接
* @param typeId 类型ID
* @param contentInfo 内容信息
* @param dcm 埋点号
* @returns {string}
*/
public
static
connectDcm
(
typeId
:
number
,
contentInfo
:
number
,
dcm
:
number
):
string
{
return
typeId
+
'.'
+
Buried
.
oaId
+
'.'
+
contentInfo
+
'.'
+
dcm
;
}
/**
* 插件dcm拼接
* @param plugId 插件ID
* @param type 1 活动工具 2 主会场 4 楼层 5 游戏 7 子页面
* @returns {string}
*/
public
static
connectPlugDcm
(
plugId
:
number
,
type
:
number
):
string
{
return
212
+
'.'
+
plugId
+
'.'
+
type
+
'.'
+
Buried
.
oaId
;
}
/**
* 活动dcm拼接
* @param type 1 活动工具 2 主会场 4 楼层 5 游戏 7 子页面
* @returns {string}
*/
public
static
connectActivityDcm
(
type
:
number
):
string
{
return
202
+
'.'
+
Buried
.
oaId
+
'.'
+
type
+
'.'
+
Buried
.
oaId
;
}
}
src/custom/superman/src/game/GTime.ts
0 → 100644
View file @
c8ec6a6a
export
class
GTime
{
/**
* 获取当前时间戳
* @returns {number}
*/
public
static
getTimestamp
():
number
{
return
new
Date
().
getTime
();
}
/**
* 转化时分秒
* @param time
*/
public
static
GetTimeHMS
(
time
:
number
):
string
{
let
t
;
let
h
=
Math
.
floor
(
time
/
3600
);
let
hstr
=
h
>
9
?
h
:
'0'
+
h
;
let
m
=
Math
.
floor
((
time
%
3600
)
/
60
);
let
mstr
=
m
>
9
?
m
:
'0'
+
m
;
let
s
=
Math
.
floor
(
time
%
60
);
let
sstr
=
s
>
9
?
s
:
'0'
+
s
;
t
=
hstr
+
':'
+
mstr
+
':'
+
sstr
;
return
t
;
}
/**
* 转化分秒
* @param time
*/
public
static
GetTimeMS
(
time
:
number
):
string
{
let
t
;
let
m
=
Math
.
floor
((
time
%
3600
)
/
60
);
let
mstr
=
m
>
9
?
m
:
'0'
+
m
;
let
s
=
Math
.
floor
(
time
%
60
);
let
sstr
=
s
>
9
?
s
:
'0'
+
s
;
t
=
mstr
+
':'
+
sstr
;
return
t
;
}
}
\ No newline at end of file
src/custom/superman/src/game/GameView.ts
0 → 100644
View file @
c8ec6a6a
// import {props} from '../props'
// import {getTexture,getTextureByName} from './utils'
// // import {Ball} from './Ball';
// import {Bullets} from './Bullets';
// export default class GameView extends engine.Container{
// startBtn:engine.Sprite
// stageBg: engine.Sprite;
// planeModel:engine.Sprite;
// pictureWrapper: engine.Sprite;
// gameBg: engine.Sprite;
// bullet: engine.Sprite;
// ball:engine.Sprite;
// constructor(){
// super()
// this.once(engine.Event.ADDED_TO_STAGE, this.setup, this);
// }
// setup(){
// this.stageBg = new engine.Sprite(getTexture('308742a0-0ea2-4610-b34a-a230add82021'))
// this.addChild(this.stageBg)
// this.gameBg = new engine.Sprite(getTexture('76820072-df5a-4ab7-8cb7-10c8cd8605c8'))
// this.bullet = new engine.Sprite(getTexture('18852543-1f1d-498b-af64-88cd3b343758'))
// // 开始按钮
// this.startBtn = new engine.Sprite(getTexture('855e3d77-ffff-443d-b884-4f67a2ebe458'))
// this.startBtn.x = (750 - this.startBtn.width) / 2;
// this.startBtn.y = (this.stage.height - this.startBtn.height) / 2 + 300;
// this.stageBg.addChild(this.startBtn)
// this.startBtn.addEventListener(engine.MouseEvent.CLICK,this.onClick,this)
// }
// mouseX;
// mouseY;
// planeCenterX;
// centerX
// ballArray:engine.Sprite[] = []
// bulletArray:engine.Sprite[] = []
// // baller:Ball
// bulleter:Bullets
// ballerArray:any[] = []
// bulletsArray:any[] = []
// score:number = 0
// start(){
// // 炮车
// this.planeModel = new engine.Sprite(getTexture('32ec481a-3f75-4c36-95ed-ee97aa936517'))
// this.planeModel.x = (750 - this.planeModel.width) / 2;
// this.planeModel.y = (this.stage.height - this.planeModel.height)
// this.planeModel.addEventListener(engine.MouseEvent.MOUSE_DOWN,this.onDown,this)
// // 子弹
// // this.bullet.x = 375;
// // this.bullet.y = 1150
// this.gameBg.addChild(this.planeModel)
// let boom = new engine.Sprite(getTexture('38ec6627-efa8-4f7a-9bdc-3c73cea717f1'))
// // 计分
// // 敌机
// setInterval(()=>{
// let ball = new engine.Sprite(getTexture('780b6b63-3abd-4246-94ba-2a3fbdb3c5af'));
// ball.x = Math.random() * (750 - ball.width ) ;
// ball.y = Math.random() * (ball.height);
// let life = 5
// this.ballerArray.push({ball,life})
// this.gameBg.addChild(ball)
// },500)
// // 敌机移动
// // setInterval(()=>{
// // let index
// // for(let ball of this.ballerArray){
// // // ball.x += Math.random() * (40) + (-20);
// // ball.y += 1;
// // if(ball.y > this.stage.height){
// // this.gameBg.removeChild(ball)
// // index = this.ballerArray.indexOf(ball)
// // this.ballerArray = this.ballerArray.filter((ele,i)=>i != index)
// // }
// // }
// // },16)
// // 添加生命值
// setInterval(()=>{
// let index
// for(let ballObj of this.ballerArray){
// // ball.x += Math.random() * (40) + (-20);
// ballObj.ball.y += 1;
// if(ballObj.ball.y > this.stage.height){
// this.gameBg.removeChild(ballObj.ball)
// index = this.ballerArray.indexOf(ballObj)
// this.ballerArray = this.ballerArray.filter((ele,i)=>i != index)
// }
// }
// },16)
// // 子弹
// setInterval(()=>{
// let bullet = new engine.Sprite(getTexture('18852543-1f1d-498b-af64-88cd3b343758'))
// bullet.x = this.planeModel ? this.planeModel.x + this.planeModel.width / 2 - bullet.width / 2 : 375 - bullet.width / 2 ;
// bullet.y = 1150
// let harm = 1;
// this.bulletsArray.push({bullet,harm});
// this.gameBg.addChild(bullet)
// },100)
// // 子弹移动
// // 计算伤害
// // 碰撞
// // setInterval(()=>{
// // for(let bullet of this.bulletsArray){
// // console.log(this.ballerArray)
// // console.log(this.bulletsArray)
// // console.log("===================");
// // bullet.y -= 40;
// // if(bullet.y < -40){
// // this.gameBg.removeChild(bullet)
// // let index = this.bulletsArray.indexOf(bullet)
// // this.bulletsArray = this.bulletsArray.filter((ele,i)=>i != index)
// // }
// // for(let baller of this.ballerArray){
// // let y = bullet.y - baller.y;
// // let bulletRight = bullet.x + bullet.width;
// // if(bulletRight > baller.x && bulletRight < (baller.x + baller.width) || bullet.x > baller.x && bullet.x < (baller.x + baller.width)){
// // if(y <= 0){
// // // 击中 移除敌机
// // this.gameBg.removeChild(bullet)
// // let index = this.bulletsArray.indexOf(bullet)
// // this.bulletsArray = this.bulletsArray.filter((ele,i)=>i != index)
// // boom.x = baller.x;
// // boom.y = baller.y;
// // this.gameBg.addChild(boom)
// // this.gameBg.removeChild(baller)
// // let ind = this.ballerArray.indexOf(baller)
// // this.ballerArray = this.ballerArray.filter((ele,i)=>i != ind)
// // setTimeout(() => {
// // this.gameBg.removeChild(boom);
// // }, 1500);
// // }
// // }
// // }
// // }
// // },20)
// setInterval(()=>{
// for(let bulletObj of this.bulletsArray){
// console.log(this.ballerArray)
// console.log(this.bulletsArray)
// console.log("得分:"+this.score)
// console.log("===================");
// bulletObj.bullet.y -= 40;
// if(bulletObj.bullet.y < -40){
// this.gameBg.removeChild(bulletObj.bullet)
// let index = this.bulletsArray.indexOf(bulletObj)
// this.bulletsArray = this.bulletsArray.filter((ele,i)=>i != index)
// }
// for(let ballObj of this.ballerArray){
// let y = bulletObj.bullet.y - ballObj.ball.y;
// let bulletRight = bulletObj.bullet.x + bulletObj.bullet.width;
// if(bulletRight > ballObj.ball.x && bulletRight < (ballObj.ball.x + ballObj.ball.width) || bulletObj.bullet.x > ballObj.ball.x && bulletObj.bullet.x < (ballObj.ball.x + ballObj.ball.width)){
// if(y <= 0){
// // 击中 移除敌机
// ballObj.life -= bulletObj.harm;
// // 加分
// this.score += bulletObj.harm;
// // console.log("得分:"+this.score)
// //子弹移除
// this.gameBg.removeChild(bulletObj.bullet)
// let index = this.bulletsArray.indexOf(bulletObj)
// this.bulletsArray = this.bulletsArray.filter((ele,i)=>i != index)
// if(ballObj.life === 0){
// this.gameBg.removeChild(ballObj.ball)
// let ind = this.ballerArray.indexOf(ballObj)
// this.ballerArray = this.ballerArray.filter((ele,i)=>i != ind)
// boom.x = ballObj.ball.x;
// boom.y = ballObj.ball.y;
// this.gameBg.addChild(boom)
// setTimeout(() => {
// this.gameBg.removeChild(boom);
// }, 1500);
// }
// }
// }
// }
// }
// },20)
// }
// stop(){}
// onDown(e){
// this.mouseX = e.localX
// this.mouseY = e.localY
// this.stage.addEventListener(engine.MouseEvent.MOUSE_MOVE,this.onMove,this)
// this.planeModel.x = e.stageX - this.mouseX;
// this.planeCenterX = this.planeModel.x + this.planeModel.width / 2;
// }
// onMove(e:engine.MouseEvent){
// // 以图片中心为准
// this.centerX = this.planeModel.width / 2;
// let movedCenter = this.centerX + e.stageX - this.mouseX;
// if(movedCenter < 0){
// this.planeModel.x = -this.centerX;
// } else if(movedCenter >750){
// this.planeModel.x = 750 - this.centerX;
// } else {
// this.planeModel.x = e.stageX - this.mouseX;
// this.planeCenterX = this.planeModel.x + this.planeModel.width / 2;
// // console.log(e.stageX,e.stageY)
// }
// }
// onClick(){
// this.addChild(this.gameBg);
// this.gameBg.addChild(this.planeModel)
// }
// shoot(w){
// setInterval(()=>{
// let bullet = new engine.Sprite(getTexture('18852543-1f1d-498b-af64-88cd3b343758'));
// bullet.x = this.planeModel.x && this.planeModel.x + this.centerX - this.bullet.width / 2 + w || 375 - this.bullet.width / 2 + w;
// bullet.y = 1150
// this.gameBg.addChild(bullet)
// this.bullet.y = this.bullet.y - 40;
// let timeid = setInterval(()=>{
// bullet.y = bullet.y - 40;
// if(bullet.y < -40){
// this.gameBg.removeChild(bullet)
// clearInterval(timeid)
// }
// },1000/60)
// },1000/60)
// }
// // ball:engine.Sprite;
// drop(){
// let ball = new engine.Sprite(getTexture('780b6b63-3abd-4246-94ba-2a3fbdb3c5af'));
// ball.x = Math.random() * (750 - ball.width ) + ball.width;
// ball.y = Math.random() * (ball.height)
// this.gameBg.addChild(ball)
// setInterval(()=>{
// ball.y += 1;
// if(ball.y > this.stage.height){
// this.gameBg.removeChild(ball)
// }
// },50)
// }
// }
\ No newline at end of file
src/custom/superman/src/game/GameWrapper.ts
0 → 100644
View file @
c8ec6a6a
// import GameView from "./GameView";
import
{
injectProps
}
from
"../props"
;
import
TestView
from
'./TestView'
import
{
Buried
}
from
"./Buried"
;
export
class
GameWrapper
extends
engine
.
Container
{
// private _gameView:GameView
private
_testView
:
TestView
constructor
(){
super
();
// engine.globalEvent.addEventListener('pictures-start', this.start, this);
// engine.globalEvent.addEventListener('pictures-stop', this.stop, this);
engine
.
globalEvent
.
addEventListener
(
"pictures-setProjectId"
,
this
.
setProjectId
,
this
);
//创建实例
// let gameView = this._gameView = new GameView();
// this.addChild(gameView);
let
testView
=
this
.
_testView
=
new
TestView
();
this
.
addChild
(
testView
);
}
setProjectId
(
event
:
engine
.
Event
){
injectProps
(
event
.
data
);
Buried
.
oaId
=
event
.
data
.
projectId
;
Buried
.
appId
=
event
.
data
.
appId
;
}
start
(
event
:
engine
.
Event
)
{
injectProps
(
event
.
data
);
// this._status = 1;
// this._testView.start();
}
stop
(
event
:
engine
.
Event
)
{
// this._testView.stop();
}
}
\ No newline at end of file
src/custom/superman/src/game/IExposureData.ts
0 → 100644
View file @
c8ec6a6a
/**
*Created by cuiliqiang on 2018/3/1
* 埋点信息
*/
export
interface
IExposureData
{
activityId
?:
number
;
activityUseType
?:
string
;
advertId
?:
number
;
appId
:
number
;
consumerId
:
number
;
dcm
:
string
;
domain
:
string
;
dpm
:
string
;
ip
?:
string
;
isEmbed
?:
boolean
;
materialId
?:
number
;
orderId
?:
string
;
os
?:
string
;
}
\ No newline at end of file
src/custom/superman/src/game/INetData.ts
0 → 100644
View file @
c8ec6a6a
export
interface
INetData
{
//名字
name
:
any
;
//地址
uri
:
string
;
//接口类型 get、post等
type
:
string
;
//返回数据类型
dataType
:
string
;
//参数
param
:
any
;
//回调
callback
:
Function
;
//轮询次数
pollingCount
?:
number
;
//轮询条件检查
pollingCheck
?:
Function
;
//url拼接内容
addUrl
?:
string
;
//是否显示错误提示
hideMsg
?:
boolean
;
}
\ No newline at end of file
src/custom/superman/src/game/QAText.ts
0 → 100644
View file @
c8ec6a6a
import
{
getTexture
,
clickLog
,
showLog
}
from
"./utils"
;
import
{
props
,
injectProps
}
from
"../props"
;
import
{
getlogItem
}
from
"./getlogItem"
;
export
default
class
QAText
extends
engine
.
Sprite
{
bg
:
engine
.
Image
[]
=
[];
bgTexture
:
engine
.
Texture
[]
=
[];
titelLabel
:
engine
.
Label
;
QLabel
:
engine
.
Label
[]
=
[];
ALabel
:
engine
.
Label
[]
=
[];
ActLabel
:
engine
.
Label
;
QlabelGroup
:
engine
.
Sprite
;
AlabelGroup
:
engine
.
Sprite
;
ActlabelGroup
:
engine
.
Sprite
;
QText
:
string
[];
//问题文本组
AText
:
string
[];
//回答文本组
ActText
:
string
[];
//互动文本组
bigBgOrigin
:
engine
.
Point
;
smallBgOrigin
:
engine
.
Point
;
returnBtn
:
engine
.
Image
;
//回答文本组的返回按钮
closeBtn
:
engine
.
Image
;
//关闭按钮
QScrList
:
engine
.
ScrollView
;
//问题滚动视图
AScrView
:
engine
.
ScrollView
;
//答案滚动视图
actLabelTimer
;
constructor
(){
super
();
this
.
addEventListener
(
engine
.
Event
.
ADDED_TO_STAGE
,
this
.
setup
,
this
)
this
.
init
();
}
init
(){
var
that
=
this
;
that
.
bigBgOrigin
=
new
engine
.
Point
();
that
.
smallBgOrigin
=
new
engine
.
Point
();
that
.
QText
=
props
.
QTextStrArr
.
split
(
','
);
//that.QText.unshift('你想问哪些问题?')
console
.
log
(
props
.
QTextStrArr
.
split
(
','
));
that
.
AText
=
props
.
ATextStrArr
.
split
(
','
)
console
.
log
(
props
.
ATextStrArr
.
split
(
','
));
that
.
ActText
=
props
.
ACTTextStrArr
.
split
(
','
);
console
.
log
(
props
.
ACTTextStrArr
.
split
(
','
));
}
setup
(){
var
that
=
this
;
that
.
removeEventListener
(
engine
.
Event
.
ADDED_TO_STAGE
,
that
.
setup
,
that
);
that
.
hideText
();
that
.
setGroup
();
that
.
setQLabel
();
that
.
setALabel
();
that
.
setActLabel
();
that
.
setEvent
();
}
setEvent
(){
}
/**设置各个文本组 */
setGroup
(){
var
that
=
this
;
//问题文本组
that
.
QlabelGroup
=
new
engine
.
Sprite
();
// that.QlabelGroup.addChild(that.bg[0]);
that
.
addChild
(
that
.
QlabelGroup
);
that
.
QlabelGroup
.
visible
=
false
;
//答案文本组
that
.
AlabelGroup
=
new
engine
.
Sprite
();
// that.AlabelGroup.addChild(that.bg[1]);
that
.
addChild
(
that
.
AlabelGroup
)
that
.
AlabelGroup
.
visible
=
false
;
//互动文本组
that
.
ActlabelGroup
=
new
engine
.
Sprite
();
// that.ActlabelGroup.addChild(that.bg[1]);
that
.
addChild
(
that
.
ActlabelGroup
);
that
.
ActlabelGroup
.
visible
=
false
;
for
(
let
i
=
0
;
i
<
3
;
i
++
){
let
bg
=
new
engine
.
Image
();
if
(
i
<
2
){
bg
.
texture
=
getTexture
(
"21d8b7ca-6ed3-44e5-ada0-f0433f471ac9"
);
//大气泡
if
(
i
==
0
){
that
.
QlabelGroup
.
addChild
(
bg
);
}
else
{
that
.
AlabelGroup
.
addChild
(
bg
);
}
}
else
{
bg
.
texture
=
getTexture
(
"9e4d1860-4762-4ac1-bc44-b3dd8fb307a6"
);
//小气泡
that
.
ActlabelGroup
.
addChild
(
bg
);
}
that
.
bg
.
push
(
bg
);
}
that
.
closeBtn
=
new
engine
.
Image
(
getTexture
(
"76f2c800-2174-4a90-ad6d-5853e95eb144"
));
that
.
addChild
(
that
.
closeBtn
);
that
.
closeBtn
.
mouseEnabled
=
true
;
that
.
closeBtn
.
addEventListener
(
engine
.
MouseEvent
.
CLICK
,
that
.
hideText
,
that
);
//问题列表
that
.
QScrList
=
new
engine
.
ScrollView
();
that
.
QlabelGroup
.
addChild
(
that
.
QScrList
);
that
.
QScrList
.
x
=
30
;
that
.
QScrList
.
y
=
85
;
that
.
QScrList
.
width
=
that
.
bg
[
0
].
width
-
50
;
that
.
QScrList
.
height
=
195
;
}
/**设置列表内问题文本 */
setQText
(
e
){
console
.
log
(
'engine.Event.UPDATE_DATA'
,
e
)
e
.
target
.
getChildByName
(
'问题文本'
).
text
=
e
.
data
;
e
.
target
.
name
=
'Q_'
+
e
.
data
.
substring
(
0
,
1
);
}
/**设置问题文本组 */
setQLabel
(){
var
that
=
this
;
let
label
=
new
engine
.
Label
();
label
.
text
=
'你想问哪些问题?'
;
label
.
x
=
30
;
label
.
y
=
30
;
label
.
size
=
34
;
label
.
width
=
that
.
bg
[
0
].
width
-
50
;
that
.
QlabelGroup
.
addChild
(
label
);
for
(
let
i
=
0
;
i
<
that
.
QText
.
length
;
i
++
){
let
img
=
new
engine
.
Image
(
getTexture
(
"8546dcf7-a6e8-4ba2-89f7-b929118e473a"
))
that
.
QScrList
.
addChild
(
img
);
img
.
name
=
'Q_'
+
i
;
img
.
y
=
5
+
i
*
50
;
img
.
x
=
that
.
QScrList
.
width
-
img
.
width
;
img
.
mouseEnabled
=
true
;
img
.
addEventListener
(
engine
.
MouseEvent
.
CLICK
,
that
.
showALabelGroup
,
that
);
let
label
=
new
engine
.
Label
();
that
.
QScrList
.
addChild
(
label
);
label
.
name
=
'Q_'
+
i
;
label
.
text
=
that
.
QText
[
i
];
label
.
fillColor
=
"#d36800"
;
label
.
size
=
24
;
label
.
width
=
img
.
x
;
label
.
height
=
50
;
label
.
y
=
img
.
y
;
label
.
mouseEnabled
=
true
;
label
.
addEventListener
(
engine
.
MouseEvent
.
CLICK
,
that
.
showALabelGroup
,
that
);
that
.
QLabel
.
push
(
label
);
}
}
/**设置答案文本 */
setALabel
(){
var
that
=
this
;
that
.
AScrView
=
new
engine
.
ScrollView
();
that
.
AlabelGroup
.
addChild
(
that
.
AScrView
);
that
.
AScrView
.
x
=
32
that
.
AScrView
.
y
=
62
that
.
AScrView
.
width
=
that
.
bg
[
0
].
width
-
55
;
that
.
AScrView
.
height
=
that
.
bg
[
0
].
height
-
120
;
for
(
let
i
=
0
;
i
<
2
;
i
++
){
let
label
=
new
engine
.
Label
();
label
.
x
=
0
label
.
y
=
5
+
i
*
40
label
.
size
=
24
;
label
.
width
=
that
.
AScrView
.
width
;
label
.
lineSpacing
=
11
;
label
.
lineType
=
engine
.
TEXT_lINETYPE
.
MULTI
;
//that.AlabelGroup.addChild(label);
that
.
AScrView
.
addChild
(
label
);
that
.
ALabel
.
push
(
label
);
}
that
.
returnBtn
=
new
engine
.
Image
(
getTexture
(
'2a555da9-dc05-4046-a5fb-551f0c2692fa'
));
that
.
AlabelGroup
.
addChild
(
that
.
returnBtn
);
// that.returnBtn.x = that.bg[1].width - that.returnBtn.width*2;
// that.returnBtn.y = that.bg[1].height - that.returnBtn.height-30;
that
.
returnBtn
.
x
=
18
;
that
.
returnBtn
.
y
=
20
;
that
.
returnBtn
.
mouseEnabled
=
true
;
that
.
returnBtn
.
addEventListener
(
engine
.
MouseEvent
.
CLICK
,
that
.
showQLabelGroup
,
that
);
}
/**设置互动文本 */
setActLabel
(){
var
that
=
this
;
that
.
ActLabel
=
new
engine
.
Label
();
that
.
ActlabelGroup
.
addChild
(
that
.
ActLabel
);
that
.
ActLabel
.
x
=
0
;
that
.
ActLabel
.
y
=
that
.
getSmallBgSize
().
h
*
0.5
-
24
;
that
.
ActLabel
.
width
=
that
.
getSmallBgSize
().
w
;
// that.ActLabel.height = that.getSmallBgSize().h;
that
.
ActLabel
.
textAlign
=
engine
.
TEXT_ALIGN
.
CENTER
;
// that.ActLabel.verticalAlign = engine.VERTICAL_ALIGN.MIDDLE;
that
.
ActLabel
.
size
=
24
;
}
/**展示问题组 */
showQLabelGroup
(
e
:
engine
.
MouseEvent
){
var
that
=
this
;
if
(
e
&&
e
.
target
==
that
.
returnBtn
){
if
(
props
.
type
==
0
){
clickLog
(
getlogItem
(
30
));
}
else
if
(
props
.
type
==
1
){
clickLog
(
getlogItem
(
80
));
}
}
that
.
x
=
that
.
bigBgOrigin
.
x
;
that
.
y
=
that
.
bigBgOrigin
.
y
;
that
.
closeBtn
.
x
=
that
.
bg
[
0
].
width
-
that
.
closeBtn
.
width
+
20
;
that
.
closeBtn
.
y
=
-
10
;
that
.
AlabelGroup
.
visible
=
false
;
that
.
ActlabelGroup
.
visible
=
false
;
that
.
QlabelGroup
.
visible
=
true
;
that
.
QScrList
.
scrollTo
(
-
1
);
that
.
showText
();
}
/**展示答案组 */
showALabelGroup
(
e
:
engine
.
MouseEvent
){
console
.
log
(
"展示答案"
+
e
.
target
.
name
);
var
that
=
this
;
that
.
x
=
that
.
bigBgOrigin
.
x
;
that
.
y
=
that
.
bigBgOrigin
.
y
;
that
.
closeBtn
.
x
=
that
.
bg
[
0
].
width
-
that
.
closeBtn
.
width
+
20
;
that
.
closeBtn
.
y
=
-
10
;
let
str
=
e
.
target
.
name
.
split
(
'_'
);
if
(
str
&&
str
.
length
>
0
)
var
index
=
str
[
1
];
that
.
ALabel
[
0
].
text
=
that
.
QText
[
index
];
//that.ALabel[0].visible = false;//不显示问题
that
.
ALabel
[
1
].
text
=
that
.
AText
[
index
];
that
.
QlabelGroup
.
visible
=
false
;
that
.
ActlabelGroup
.
visible
=
false
;
that
.
AlabelGroup
.
visible
=
true
;
this
.
AScrView
.
scrollTo
(
-
1
);
that
.
showText
();
if
(
props
.
type
==
0
){
showLog
(
getlogItem
(
30
));
}
else
if
(
props
.
type
==
1
){
showLog
(
getlogItem
(
80
));
}
}
/**展示互动组 */
showActLabelGroup
(
type
){
// injectProps(event.data);
let
index
=
type
;
var
that
=
this
;
that
.
x
=
that
.
smallBgOrigin
.
x
;
that
.
y
=
that
.
smallBgOrigin
.
y
;
that
.
closeBtn
.
x
=
that
.
bg
[
2
].
width
-
that
.
closeBtn
.
width
-
10
;
that
.
closeBtn
.
y
=
20
;
that
.
ActLabel
.
text
=
that
.
ActText
[
index
];
that
.
QlabelGroup
.
visible
=
false
;
that
.
AlabelGroup
.
visible
=
false
;
that
.
ActlabelGroup
.
visible
=
true
;
that
.
showText
();
if
(
!
that
.
actLabelTimer
){
that
.
actLabelTimer
=
setTimeout
(()
=>
{
that
.
ActlabelGroup
.
visible
=
false
;
that
.
hideText
();
clearTimeout
(
that
.
actLabelTimer
)
},
3000
);
}
else
{
clearTimeout
(
that
.
actLabelTimer
);
that
.
actLabelTimer
=
setTimeout
(()
=>
{
that
.
hideText
();
that
.
ActlabelGroup
.
visible
=
false
;
},
3000
);
}
}
setBigBgPositon
(
x
:
number
,
y
:
number
){
this
.
bigBgOrigin
.
x
=
x
;
this
.
bigBgOrigin
.
y
=
y
;
}
setSmallBgPositon
(
x
:
number
,
y
:
number
){
this
.
smallBgOrigin
.
x
=
x
;
this
.
smallBgOrigin
.
y
=
y
;
}
getBigBgSize
(){
return
{
w
:
this
.
bg
[
0
].
width
,
h
:
this
.
bg
[
0
].
height
}
}
getSmallBgSize
(){
return
{
w
:
this
.
bg
[
2
].
width
,
h
:
this
.
bg
[
2
].
height
}
}
showText
(){
this
.
visible
=
true
;
}
hideText
(){
if
(
this
.
actLabelTimer
){
clearTimeout
(
this
.
actLabelTimer
);
}
engine
.
globalEvent
.
dispatchEvent
(
"hideRect"
);
this
.
visible
=
false
;
}
}
\ No newline at end of file
src/custom/superman/src/game/TestView.ts
0 → 100644
View file @
c8ec6a6a
import
{
getTexture
,
createSvga
,
showLog
,
clickLog
}
from
'./utils'
import
QAText
from
'./QAText'
;
import
{
getlogItem
}
from
'./getlogItem'
;
import
{
props
}
from
'../props'
;
export
default
class
TestView
extends
engine
.
Container
{
worldTime
:
number
;
supermanImg
:
engine
.
Image
;
qaisOpen
:
boolean
=
false
;
QAText
:
QAText
;
breathSvga
:
svga
.
Svga
;
waveSvga
:
svga
.
Svga
;
rect
:
engine
.
Rect
;
constructor
(){
super
()
this
.
addEventListener
(
engine
.
Event
.
ADDED_TO_STAGE
,
this
.
setup
,
this
);
}
setup
(){
var
that
=
this
;
that
.
removeEventListener
(
engine
.
Event
.
ADDED_TO_STAGE
,
this
.
setup
,
this
)
that
.
rect
=
new
engine
.
Rect
();
that
.
rect
.
fillColor
=
"#000000"
;
that
.
rect
.
alpha
=
0.7
;
that
.
rect
.
width
=
2000
;
that
.
rect
.
height
=
2000
;
that
.
rect
.
visible
=
false
;
that
.
addChild
(
that
.
rect
);
that
.
breathSvga
=
createSvga
(
"常规呼吸动作"
);
that
.
waveSvga
=
createSvga
(
"招手"
);
that
.
waveSvga
.
visible
=
false
;
that
.
breathSvga
.
visible
=
true
;
that
.
breathSvga
.
mouseEnabled
=
that
.
waveSvga
.
mouseEnabled
=
true
;
that
.
addChild
(
that
.
breathSvga
);
that
.
addChild
(
that
.
waveSvga
);
that
.
breathSvga
.
x
=
that
.
waveSvga
.
x
=
engine
.
gameStage
.
stage
.
width
-
178
*
0.7
;
that
.
breathSvga
.
y
=
that
.
waveSvga
.
y
=
engine
.
gameStage
.
stage
.
height
/
3
*
2
-
60
;
that
.
breathSvga
.
gotoAndPlay
(
1
);
// that.breathSvga.scale = 0.6;
// that.waveSvga.scale = 0.6;
that
.
breathSvga
.
scaleX
=
that
.
breathSvga
.
scaleY
=
0.7
;
that
.
waveSvga
.
scaleX
=
that
.
waveSvga
.
scaleY
=
0.7
;
that
.
QAText
=
new
QAText
();
that
.
addChild
(
that
.
QAText
);
that
.
QAText
.
setBigBgPositon
(
engine
.
gameStage
.
stage
.
width
-
that
.
QAText
.
getBigBgSize
().
w
-
35
,
engine
.
gameStage
.
stage
.
height
/
3
*
2
-
60
-
that
.
QAText
.
getBigBgSize
().
h
)
that
.
QAText
.
setSmallBgPositon
(
engine
.
gameStage
.
stage
.
width
-
that
.
QAText
.
getSmallBgSize
().
w
-
35
,
engine
.
gameStage
.
stage
.
height
/
3
*
2
-
60
-
that
.
QAText
.
getSmallBgSize
().
h
)
that
.
addEvnt
();
}
addEvnt
(){
var
that
=
this
;
// that.supermanImg.addEventListener(engine.MouseEvent.CLICK,that.touchSuperManImg,that);
that
.
breathSvga
.
addEventListener
(
engine
.
MouseEvent
.
CLICK
,
that
.
touchSuperManImg
,
that
);
that
.
waveSvga
.
addEventListener
(
engine
.
MouseEvent
.
CLICK
,
that
.
touchSuperManImg
,
that
);
engine
.
globalEvent
.
addEventListener
(
"pictures-ActLabel"
,
that
.
showActLabelGroup
,
that
);
engine
.
globalEvent
.
addEventListener
(
"pictures-supermanAnim"
,
that
.
supermanAnim
,
that
);
engine
.
globalEvent
.
addEventListener
(
"hideRect"
,()
=>
{
that
.
rect
.
visible
=
false
},
that
);
}
/**蛋黄超人动效 */
supermanAnim
(){
}
/**点击蛋黄超人 */
touchSuperManImg
(
e
:
engine
.
MouseEvent
){
console
.
log
(
"点击蛋黄超人"
)
var
that
=
this
;
if
(
that
.
QAText
.
visible
)
return
;
if
(
props
.
type
==
0
){
clickLog
(
getlogItem
(
17
))
}
else
if
(
props
.
type
==
1
){
clickLog
(
getlogItem
(
51
))
}
//蛋黄超人动效
that
.
showWaveSvga
();
that
.
QAText
.
showQLabelGroup
(
null
);
that
.
rect
.
visible
=
true
;
}
/**展示互动文案组 */
showActLabelGroup
(
e
:
engine
.
Event
){
var
that
=
this
;
//蛋黄超人动效
that
.
showWaveSvga
();
that
.
QAText
.
showActLabelGroup
(
parseInt
(
e
.
data
.
type
))
}
showWaveSvga
(){
var
that
=
this
;
that
.
breathSvga
.
visible
=
false
;
that
.
waveSvga
.
visible
=
true
;
that
.
waveSvga
.
play
(
false
,
false
);
that
.
waveSvga
.
once
(
engine
.
Event
.
END_FRAME
,()
=>
{
that
.
waveSvga
.
visible
=
false
;
that
.
breathSvga
.
gotoAndPlay
(
1
)
that
.
breathSvga
.
visible
=
true
;
},
that
)
}
}
\ No newline at end of file
src/custom/superman/src/game/getlogItem.ts
0 → 100644
View file @
c8ec6a6a
import
{
Buried
}
from
"./Buried"
;
import
{
props
}
from
'../props'
export
const
getlogItem
=
(
i
)
=>
{
const
Dpm
=
Buried
.
connectDpm
(
110
,
i
,
1
);
// 点击埋点
const
Dcm
=
Buried
.
connectDcm
(
202
,
0
,
0
);
// 曝光埋点
return
Buried
.
createExposure
(
Dpm
,
Dcm
);
};
\ No newline at end of file
src/custom/superman/src/game/test.json
0 → 100644
View file @
c8ec6a6a
{
"a"
:
1
}
\ No newline at end of file
src/custom/superman/src/game/utils.ts
0 → 100644
View file @
c8ec6a6a
/**
* Created by rockyl on 2020-01-21.
*/
import
{
IExposureData
}
from
'./IExposureData'
import
{
INetData
}
from
'./INetData'
import
{
GTime
}
from
'./GTime'
;
export
function
getTexture
(
uuid
)
{
return
engine
.
Texture
.
from
(
getAssetByUUID
(
uuid
).
uuid
);
}
export
function
getTextureByName
(
name
)
{
return
getTexture
(
engine
.
getAssetByName
(
name
).
uuid
);
}
export
function
playSound
(
name
)
{
engine
.
playSound
(
engine
.
getAssetByName
(
name
).
uuid
,
{
keep
:
true
});
}
export
function
createSvga
(
name
,
anchorName
?)
{
let
inst
=
new
svga
.
Svga
();
inst
.
source
=
'asset://'
+
engine
.
getAssetByName
(
name
).
uuid
;
return
inst
;
}
export
function
getIndexFromRC
(
row
,
col
,
maxCol
){
let
index
;
index
=
row
*
maxCol
+
col
;
return
index
}
export
function
getRandomArray
(
array
){
array
.
sort
(
function
()
{
return
.
5
-
Math
.
random
();
});
}
/**
* 兑吧点击埋点
* @param {IExposureData} exposure
*/
export
function
clickLog
(
exposure
:
IExposureData
):
void
{
const
net
:
INetData
=
{
name
:
'clickLog'
,
uri
:
'/log/click'
,
type
:
'get'
,
dataType
:
'jsonp'
,
param
:
exposure
,
callback
:
null
,
hideMsg
:
true
};
send
(
net
);
}
/**
* 兑吧曝光埋点
* @param {IExposureData} exposure
*/
export
function
showLog
(
exposure
:
IExposureData
):
void
{
const
net
:
INetData
=
{
name
:
'showLog'
,
uri
:
exposure
.
domain
+
'/exposure/standard'
,
type
:
'get'
,
dataType
:
'jsonp'
,
param
:
exposure
,
callback
:
null
,
hideMsg
:
true
};
send
(
net
);
}
/**
* 发送请求
* @param net
*/
export
function
send
(
net
:
INetData
):
void
{
let
gTime
:
string
=
'?_='
+
GTime
.
getTimestamp
();
let
realUrl
:
string
=
net
.
uri
;
if
(
realUrl
.
indexOf
(
'?'
)
!=
-
1
)
{
gTime
=
'&_='
+
GTime
.
getTimestamp
();
}
//url加参数等特殊需求(例如再玩一次需要在dostart接口的url上加埋点)
if
(
net
.
addUrl
)
{
realUrl
+=
net
.
addUrl
;
}
window
[
'$'
].
ajax
({
type
:
net
.
type
,
// url: realUrl + gTime,
url
:
realUrl
,
cache
:
false
,
dataType
:
net
.
dataType
,
data
:
net
.
param
,
async
:
true
,
// success: (result) => {
// this.onResponse(net, result);
// },
// error: (message) => {
// this.onError(net);
// }
});
}
\ No newline at end of file
src/custom/superman/src/index.ts
0 → 100644
View file @
c8ec6a6a
import
{
GameWrapper
}
from
"./game/GameWrapper"
;
import
{
injectProps
,
prepareProps
}
from
"./props"
;
export
default
function
(
props
)
{
prepareProps
();
injectProps
(
props
);
let
instance
=
new
GameWrapper
();
return
instance
;
}
src/custom/superman/src/props.ts
0 → 100644
View file @
c8ec6a6a
/**
* Created by rockyl on 2020-01-21.
*/
export
let
props
:
any
=
{};
export
function
prepareProps
()
{
let
metaProps
=
getProps
();
engine
.
injectProp
(
props
,
metaProps
);
}
export
function
injectProps
(
p
)
{
engine
.
injectProp
(
props
,
p
);
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment