更新了埋点失败重传,scode以及分享链接更改

This commit is contained in:
YZ\249929363 2024-08-28 11:12:55 +08:00
parent dd95eb3a3f
commit e0954a1954
55 changed files with 3644 additions and 3648 deletions

View File

@ -1276,7 +1276,7 @@
},
"_enabled": true,
"localTest": false,
"clientTestVersion": "1.3.0",
"clientTestVersion": "1.3.2",
"testVersion": {
"__id__": 21
},

View File

@ -98,14 +98,14 @@
],
"_active": true,
"_components": [
{
"__id__": 38
},
{
"__id__": 39
},
{
"__id__": 40
},
{
"__id__": 41
},
{
"__id__": 42
}
],
"_prefab": null,
@ -1087,7 +1087,7 @@
{
"__type__": "cc.Node",
"_name": "again",
"_objFlags": 0,
"_objFlags": 512,
"_parent": {
"__id__": 21
},
@ -1657,18 +1657,14 @@
"_parent": {
"__id__": 21
},
"_children": [
{
"__id__": 35
}
],
"_children": [],
"_active": false,
"_components": [
{
"__id__": 37
"__id__": 35
},
{
"__id__": 38
"__id__": 36
}
],
"_prefab": null,
@ -1719,102 +1715,6 @@
"groupIndex": 0,
"_id": "75MWyDslJKCpuJ0hRH1qJ2"
},
{
"__type__": "cc.Node",
"_name": "New Sprite",
"_objFlags": 0,
"_parent": {
"__id__": 34
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 36
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 156,
"height": 38
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
5.755,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "dc8IZxiNJCzrTACnYLy8OK"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 35
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "4d3e4edd-f44e-4e1a-8648-d173f746eea8"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": {
"__uuid__": "ef1ad44d-51f9-416e-9fc4-9c35dee52cf3"
},
"_id": "33vTFQuddFTJL8U5cy8H9e"
},
{
"__type__": "cc.Sprite",
"_name": "",
@ -1861,7 +1761,7 @@
"zoomScale": 1.1,
"clickEvents": [
{
"__id__": 39
"__id__": 37
}
],
"_N$interactable": true,

View File

@ -115,7 +115,7 @@ export default class NewClass extends cc.Component {
}
jumpFinishi(){
let url = "https://train.sparkus.cn/poster/game/";
let url = "https://train.sparkus.cn/poster/game/" + cc.fx.GameConfig.GM_INFO.scode + "?suc=1";
window.location.href = url;
}

View File

@ -38,6 +38,7 @@ export class GameConfig {
currSeed: number; //用于随机数种子
gameId: string; //游戏ID
userId: number; //用户ID
scode: string, //用户code,从网页后缀获取
guide: boolean; //是否有引导
url: string; //访问域名
success: boolean; //用户游戏成功与否
@ -91,6 +92,7 @@ export class GameConfig {
let jsonData: object = res.json!;
self.GM_INFO = jsonData["data"];
self.setCode(self.getKey("scode"));
cc.fx.GameTool.getCustom(false);
if(!Authentication) self.Authentication();
})
@ -104,11 +106,12 @@ export class GameConfig {
static GM_INFO_init() {
this.GM_INFO = {
// isEnd: false,
mean_Time: 0, //平均放箭速度
total: 0, //总共对的个数
mean_Time: 0, //平均放箭速度
total: 0, //总共对的个数
currSeed: 200000, //用于随机数种子
gameId: "100010", //游戏ID
userId: 200139, //用户ID
userId: 200139, //用户ID
scode: "", //用户code,从网页后缀获取
guide: true, //是否有引导
url: "https://api.sparkus.cn",//访问域名
success: false, //用户游戏成功与否
@ -120,7 +123,7 @@ export class GameConfig {
gameTime:5,
igniteCount: 0, //玩家总计成功点火数
};
this.setCode(this.getKey("scode"));
}
static GM_INFO_SET(key,value) {
@ -2653,6 +2656,19 @@ export class GameConfig {
}
static setCode(code){
this.GM_INFO.scode = code;
}
static getKey(key){
var reg = new RegExp('(^|&)' + key + '=([^&]*)(&|$)', 'i');
var r = window.location.search.substr(1).match(reg);
if (r != null) {
return unescape(r[2]);
}
return "";
}
static Authentication(){
cc.fx.GameTool.Authentication();
}

View File

@ -6,40 +6,37 @@ const BASE_URL = "https://api.sparkus.cn";
//只负责网络接口 次类只负责和后端交互,不负责处理数据 数据处理在GameTool
@ccclass
export default class HttpUtil extends cc.Component {
static async getShareInfo(shareUrl: string): Promise<any> {
console.log("设置分享链接:",shareUrl);
const time = Math.floor((new Date().getTime()) / 1000)
const url = HttpUtil.apiSign(`/api/share/cfg?gameId=${config.gameId}&time=${time}&url=${shareUrl}`,{})
return this.post(url,null,null);
}
//排行榜
static async rankData(type,callback,data): Promise<any> {
const time = Math.floor((new Date().getTime()) / 1000)
const url = HttpUtil.apiSign(`/api/get/rank/data?gameId=${config.gameId}&dataType=${type}&time=${time}`, data)
this.post(url,data,callback);
this.post(url,data,callback,0);
}
static async uploadUserLogData(data,callback): Promise<any> {
const url = '/log/collect/data';
this.post(url,data,callback);
this.post(url,data,callback,3);
}
//暂时用不到
static async getUserRecord(data,callback): Promise<any> {
const time = Math.floor((new Date().getTime()) / 1000)
const url = HttpUtil.apiSign(`/api/get/user/data?gameId=${config.gameId}&time=${time}`, data)
this.post(url,data,callback);
this.post(url,data,callback,0);
}
static async post(url, data, callback) {
const response = await this.fetchData(url, data, 'POST');
static async get(url, callback,count) {
let repeat = count?count:0;
const response = await this.fetchData(url, null, 'GET',repeat);
callback && callback(response);
}
static async get(url, callback) {
const response = await this.fetchData(url, null, 'GET');
static async post(url, data, callback,count) {
let repeat = count?count:0;
const response = await this.fetchData(url, data, 'POST',repeat);
callback && callback(response);
}
static async fetchData(url, data, method) {
static async fetchData(url, data, method,repeat) {
const fullUrl = `${BASE_URL}${url}`;
const headers = { 'Content-Type': 'application/json' };
const options = {
@ -49,15 +46,36 @@ export default class HttpUtil extends cc.Component {
};
try {
const response = await fetch(fullUrl, options);
var response = await this.fetchWithTimeout(fullUrl,options);
if (!response.ok) {
throw new Error(`HTTP error! status: ${response.status}`);
throw new Error(`HTTP_______________error! status: ${response.status}`);
}
return await response.json();
} catch (error) {
console.error('Fetch error:', error);
return null;
console.error('Fetch_______________error:', error);
if(repeat > 0){
repeat -= 1;
const timeOut = (3-repeat)*5000;
setTimeout(async () => {
response = await this.fetchData(url, data, method,repeat);
}, timeOut);
}
else{
return null;
}
}
}
static async fetchWithTimeout(resource, options = {}) {
const controller = new AbortController();
const id = setTimeout(() => controller.abort(), 5000);
const response = await fetch(resource, {
...options,
signal: controller.signal
});
clearTimeout(id);
return response;
}
/**

View File

@ -60,15 +60,18 @@ export class WeChat {
console.log("分享好友成功回调");
}
});
wx.updateTimelineShareData({
title: '记忆力认知测评', // 分享标题
link: shareConfig.shareLine, // 分享链接该链接域名或路径必须与当前页面对应的公众号JS安全域名一致
imgUrl: 'https://static.sparkus.cn/public/shennong.jpg', // 分享图标
success: function () {
// 设置成功
console.log("分享朋友圈成功回调");
}
})
setTimeout(() => {
wx.updateTimelineShareData({
title: '记忆力认知测评', // 分享标题
link: shareConfig.shareLine, // 分享链接该链接域名或路径必须与当前页面对应的公众号JS安全域名一致
imgUrl: 'https://static.sparkus.cn/public/shennong.jpg', // 分享图标
success: function () {
// 设置成功
console.log("分享朋友圈成功回调");
}
})
}, 200);
});
}
@ -80,7 +83,7 @@ export class WeChat {
static async getShareInfo(shareUrl: string, callback:Function): Promise<any> {
const time = Math.floor((new Date().getTime()) / 1000)
const url = cc.fx.HttpUtil.apiSign(`/api/share/cfg?gameId=${shareConfig.gameId}&time=${time}&url=${shareUrl}`,{})
return cc.fx.HttpUtil.get(url,callback)
return cc.fx.HttpUtil.get(url,callback,0)
}

View File

@ -9,15 +9,23 @@ var GameTool = {
let name = "user_" + cc.fx.GameConfig.GM_INFO.gameId;
var data = JSON.parse(localStorage.getItem(name));
if(data == "undifend" || data==null || data == ""){
var urlNow = window.location.href;
if(!this.containsTrain(urlNow) || !this.isNumber(data.userId)){
let url = "https://api.sparkus.cn/api/user/auth/login?domain=hui32579WdYPsgYq&callback="+location.href;
window.location.href = url;
}
let url = "https://api.sparkus.cn/api/user/auth/login?domain=hui32579WdYPsgYq&callback="+
encodeURIComponent(location.href);
console.log("链接没ID准备跳转",url);
window.location.href = url;
}
else{
cc.fx.StorageMessage.setStorage(name,data);
cc.fx.GameConfig.GM_INFO.userId = parseInt(data.userId);
if(!this.isNumber(data.userId)){
let url = "https://api.sparkus.cn/api/user/auth/login?domain=hui32579WdYPsgYq&callback="+
encodeURIComponent(location.href);
console.log("链接不合法",url);
window.location.href = url;
}
else{
cc.fx.StorageMessage.setStorage(name,data);
cc.fx.GameConfig.GM_INFO.userId = parseInt(data.userId);
}
}
},
@ -44,6 +52,7 @@ var GameTool = {
let postData = {
"gameId":cc.fx.GameConfig.GM_INFO.gameId,
"userId":cc.fx.GameConfig.GM_INFO.userId,
"scode":cc.fx.GameConfig.GM_INFO.scode,
"matchId":matchId,
"data": data
};

View File

@ -191,17 +191,15 @@
var urlNow = window.location.href;
let userId = getUserId();
if(userId == null){
if(!containsTrain(urlNow) || !isNumber(userId)){
console.log("链接没ID准备跳转");
let url = "https://api.sparkus.cn/api/user/auth/login?domain=hui32579WdYPsgYq&callback="+location.href;
window.location.href = url;
}
let url = "https://api.sparkus.cn/api/user/auth/login?domain=hui32579WdYPsgYq&callback="+
encodeURIComponent(location.href);
console.log("链接没ID准备跳转",url);
window.location.href = url;
}
else{
console.log("链接有ID",userId);
let timestamp = parseInt(new Date().getTime()/1000 + "");
let idData = {
userId: userId,
userId: parseInt(userId),
time: timestamp
}
localStorage.setItem(name,JSON.stringify(idData));

Binary file not shown.

View File

@ -1 +1 @@
{"paths":{},"types":[],"uuids":["1da8E6lehB4ocDRBJj7AC7","2dL3kvpAxJu6GJ7RdqJG5J","4bnFp+xkVIpJrKXfOBzk71","4er1GLNexCYpKNTUl8Pygw","61cyPdEfRN047sDK9rO0W5","6eBWFz0oVHPLIGQKf/9Thu","71VhFCTINJM6/Ky3oX9nBT","80hOyDduZO9KDpFipBe1wI","9cCAYtTPFLbqi6SjiBzH59","a2MjXRFdtLlYQ5ouAFv/+R","b4P/PCArtIdIH38t6mlw8Y","d608qFRoFHwbXd0Dap056i","d8HsitJHxOYqo801xBk8ev","e8Ueib+qJEhL6mXAHdnwbi","eb/m5v8GhCJ7/YFvg05yA/","02delMVqdBD70a/HSD99FK","0382cMsuNE3KcYNdg7RaEA","04QhoLJm5NE4HfGHPvPEqD","0987SaUH9IXri/gJ+Y3Ukj","0am1HlI7tJAr0CCz+R5gFz","15yN+Vt99CfLSMV8E5LZ6E","163wG3ddlH8pa/I9KWMq9H","1aH33G3pNJTbe+/pIDtB3A","1bSqFXgnFL0Kki4Z9FLYb8","24u5bW0WBBnImojxoeIDSR","28D+Br0KFPHb9YTDfpB7fq","29FYIk+N1GYaeWH/q1NxQO","38Ttmi/zlB/aPdDfKD4uFZ","39Qf2uJ5pI2KdGXFUZcxqA","3cx7xqv11Mqae4IqOZ8pMA","41lxK9AOZDUpe8EFqxmdhS","43TEgy6rBGwaHvuqUxY4a0","43yDqZa+BGj6iUG2JPPTOs","47OItZvKlGB73BH8e6B5oS","4dPk7d9E5OGoZI0XP3Ru6o","4finTWjodHNJ3zkAJ7cCZJ","4fteZzcBdKGr9IkiUERgQt","51X/lBptFCGpJDJJCR/Fsd","52VtLfbi1MrJrHvTOt0GBT","53JeaBCcJM3Yfxe012JH8U","57l7pAAjJOyocpcZNz456M","576FRTaZdCQrq7cFaXU46Y","58kGAvRw9C6reFjVVlIUra","58mpK9IcxD1IWULpySkw8T","5a4OvTK0pOpJRUe4tPzvrU","5cO7kybDxGj4ipyMYdRYZB","5dBjs29q1NCq0MHq9jOhKT","5dU5jEs9VARZEOG/pv7Ufq","5fCMQ2RPBIArwZBEOXKhBb","5f5dyqtRNNxaFmVzYns6FZ","5f6tgEGCdMjZuJwJhJru1O","63Ss7MWYdAn4yBKFaSiauz","69EnvezWBP9IYebqFsy3LT","69mbYhSp9KiZcPT2Y39uvh","6bhr+y1NFEdKYVaopRW5IB","6caEnphCZL2IKYGUkX0g2n","6eAkj26lVCUr6qYnNrxTrX","70D6UnoQRNMYRqmevBxYA6","70360VC8hFqZPvYtrn/IwS","75zv/v5GlIRYC94AUoQNJI","79R1bE7qxKJKQSQDXQcZlw","7aUCmkbUlKFaG7n6qVBugB","7a/QZLET9IDreTiBfRn2PD","7bCx0gWh1HI4r4UKR+hBZD","7e6Iw5csNIlo+vsmwdrsq8","81ia8va3BJepOlmUBIyy4J","84pYaRbLxDm40pRq6R/U2j","8c20Sso/ZEn7NUfNSM+EBh","8c+UfqiOZDJqedRTQzX04y","92J2FdGz9BbIhN4zYS1Xsu","9283NIJKZGXLdKCv2mBNw9","9bvaMerUlDyary99mJa6xp","9cnmwJZlNEt4pynt3FTCQl","a3kEdNUtpHUp+xylzYnD9l","a6cIPzEytNx5Y8ryBAEs2X","acL4P7H55NWLBDvc0lY04U","b0dGqdCCJJ3Yz4Ra/B7kZS","b1p9kkt1ZKvZ3k+RPnbXum","b3ExUspZBAapD254yoz5n6","b3G0R7LDVG6rtshJUgVfro","b30PxSOWBC0YafORIekSvb","bamQeltc5Ewbk7c/2f7V3b","be9Gc3wyNC6p6nfceAuIK3","c1/PD7xXJIAJhIHnhxj9q/","c2uC1x53VDxJumZQ16xGwx","cdYGsFIYNKWq18nzRkAGqq","e3D5Zv1UZEoJ7kuldF1p2q","e3Y6Z2m1JEArQ6NwYvJMJQ","e4aGCqkitAjIqSzPskEGx2","e9YCqWkdFKZZio+BdFrOfw","e9foLfROJClIn72tv0S/Yi","e97GVMl6JHh5Ml5qEDdSGa","eb8n+TbDtEzbIolEt3Q1k2","eckHZEV5hNt7uqOurMIVD0","ecpdLyjvZBwrvm+cedCcQy","ec2LeWzz1F5qtdmZBv9oQm","edNUrcH69NqrPed2wEmQkK","edVm3LZetHAoWDG+wSCLQN","ee8fatrn1PdKuHzUyB3qBy","f0BIwQ8D5Ml7nTNQbh1YlS","f20cFqDmtBIL+vAc5yCydW","f6zfU6jehC2r6jWBsaaBNg","f9mSq5yqBGLIuvaQhnf9KW","ffpaCBUEBIfKFTR0LSG6wa","ff28kp/9tGt6k+KUR4Vso2"],"scenes":{"db://assets/Scene/GameScene.fire":3,"db://assets/Scene/GuideScene.fire":0,"db://assets/Scene/LoadScene.fire":8,"db://assets/Scene/OverScene.fire":2,"db://assets/Scene/RankScene.fire":1},"redirect":[15,0,16,1,17,1,18,1,19,1,20,1,21,1,22,1,23,1,24,1,25,1,27,1,28,1,29,1,30,1,31,1,32,1,33,1,34,1,35,1,36,1,37,1,38,1,39,1,40,1,41,1,43,1,44,1,46,1,47,1,48,1,50,1,51,1,52,1,53,1,54,1,56,1,57,1,58,1,59,1,60,1,61,1,62,0,63,1,64,1,65,1,66,1,68,1,69,1,70,1,72,1,73,1,74,1,75,1,76,1,77,1,78,1,79,1,80,1,81,1,82,1,83,1,84,1,86,1,87,1,88,1,89,1,90,1,92,1,93,1,94,0,95,1,96,1,97,1,98,1,100,1,101,1,102,1,103,1,104,1],"deps":["internal","resources"],"packs":{"023ab8d83":[2,42],"02989e146":[26,8,91,99],"07085ce9a":[0,67,9],"08b19ad34":[3,9],"08d36c5cd":[1,45,49,55,71],"0b81de588":[4,5,6,7,10,11,12,13,14]},"name":"main","importBase":"import","nativeBase":"native","debug":false,"isZip":false,"encrypted":false,"versions":{"import":["023ab8d83","8c688","02989e146","70081","07085ce9a","38058","08b19ad34","eb10d","08d36c5cd","5dd93","0b81de588","e3c82",85,"abc94"],"native":[4,"6d707",5,"6d3cf",6,"c06a9",7,"27e3b",10,"83fcc",11,"d55c2",12,"cdbc9",13,"90cf4",14,"ed141"]}}
{"paths":{},"types":[],"uuids":["1da8E6lehB4ocDRBJj7AC7","2dL3kvpAxJu6GJ7RdqJG5J","4bnFp+xkVIpJrKXfOBzk71","4er1GLNexCYpKNTUl8Pygw","61cyPdEfRN047sDK9rO0W5","6eBWFz0oVHPLIGQKf/9Thu","71VhFCTINJM6/Ky3oX9nBT","80hOyDduZO9KDpFipBe1wI","9cCAYtTPFLbqi6SjiBzH59","a2MjXRFdtLlYQ5ouAFv/+R","b4P/PCArtIdIH38t6mlw8Y","d608qFRoFHwbXd0Dap056i","d8HsitJHxOYqo801xBk8ev","e8Ueib+qJEhL6mXAHdnwbi","eb/m5v8GhCJ7/YFvg05yA/","02delMVqdBD70a/HSD99FK","0382cMsuNE3KcYNdg7RaEA","04QhoLJm5NE4HfGHPvPEqD","0987SaUH9IXri/gJ+Y3Ukj","0am1HlI7tJAr0CCz+R5gFz","15yN+Vt99CfLSMV8E5LZ6E","163wG3ddlH8pa/I9KWMq9H","1aH33G3pNJTbe+/pIDtB3A","1bSqFXgnFL0Kki4Z9FLYb8","24u5bW0WBBnImojxoeIDSR","28D+Br0KFPHb9YTDfpB7fq","29FYIk+N1GYaeWH/q1NxQO","38Ttmi/zlB/aPdDfKD4uFZ","39Qf2uJ5pI2KdGXFUZcxqA","3cx7xqv11Mqae4IqOZ8pMA","41lxK9AOZDUpe8EFqxmdhS","43TEgy6rBGwaHvuqUxY4a0","43yDqZa+BGj6iUG2JPPTOs","47OItZvKlGB73BH8e6B5oS","4dPk7d9E5OGoZI0XP3Ru6o","4finTWjodHNJ3zkAJ7cCZJ","4fteZzcBdKGr9IkiUERgQt","51X/lBptFCGpJDJJCR/Fsd","52VtLfbi1MrJrHvTOt0GBT","53JeaBCcJM3Yfxe012JH8U","57l7pAAjJOyocpcZNz456M","576FRTaZdCQrq7cFaXU46Y","58kGAvRw9C6reFjVVlIUra","58mpK9IcxD1IWULpySkw8T","5a4OvTK0pOpJRUe4tPzvrU","5cO7kybDxGj4ipyMYdRYZB","5dBjs29q1NCq0MHq9jOhKT","5dU5jEs9VARZEOG/pv7Ufq","5fCMQ2RPBIArwZBEOXKhBb","5f5dyqtRNNxaFmVzYns6FZ","5f6tgEGCdMjZuJwJhJru1O","63Ss7MWYdAn4yBKFaSiauz","69EnvezWBP9IYebqFsy3LT","69mbYhSp9KiZcPT2Y39uvh","6bhr+y1NFEdKYVaopRW5IB","6caEnphCZL2IKYGUkX0g2n","6eAkj26lVCUr6qYnNrxTrX","70D6UnoQRNMYRqmevBxYA6","70360VC8hFqZPvYtrn/IwS","75zv/v5GlIRYC94AUoQNJI","79R1bE7qxKJKQSQDXQcZlw","7aUCmkbUlKFaG7n6qVBugB","7a/QZLET9IDreTiBfRn2PD","7bCx0gWh1HI4r4UKR+hBZD","7e6Iw5csNIlo+vsmwdrsq8","81ia8va3BJepOlmUBIyy4J","84pYaRbLxDm40pRq6R/U2j","8c20Sso/ZEn7NUfNSM+EBh","8c+UfqiOZDJqedRTQzX04y","92J2FdGz9BbIhN4zYS1Xsu","9283NIJKZGXLdKCv2mBNw9","9bvaMerUlDyary99mJa6xp","9cnmwJZlNEt4pynt3FTCQl","a3kEdNUtpHUp+xylzYnD9l","a6cIPzEytNx5Y8ryBAEs2X","acL4P7H55NWLBDvc0lY04U","b0dGqdCCJJ3Yz4Ra/B7kZS","b1p9kkt1ZKvZ3k+RPnbXum","b3ExUspZBAapD254yoz5n6","b3G0R7LDVG6rtshJUgVfro","b30PxSOWBC0YafORIekSvb","bamQeltc5Ewbk7c/2f7V3b","be9Gc3wyNC6p6nfceAuIK3","c1/PD7xXJIAJhIHnhxj9q/","c2uC1x53VDxJumZQ16xGwx","cdYGsFIYNKWq18nzRkAGqq","e3D5Zv1UZEoJ7kuldF1p2q","e3Y6Z2m1JEArQ6NwYvJMJQ","e4aGCqkitAjIqSzPskEGx2","e9YCqWkdFKZZio+BdFrOfw","e9foLfROJClIn72tv0S/Yi","e97GVMl6JHh5Ml5qEDdSGa","eb8n+TbDtEzbIolEt3Q1k2","eckHZEV5hNt7uqOurMIVD0","ecpdLyjvZBwrvm+cedCcQy","ec2LeWzz1F5qtdmZBv9oQm","edNUrcH69NqrPed2wEmQkK","edVm3LZetHAoWDG+wSCLQN","ee8fatrn1PdKuHzUyB3qBy","f0BIwQ8D5Ml7nTNQbh1YlS","f20cFqDmtBIL+vAc5yCydW","f6zfU6jehC2r6jWBsaaBNg","f9mSq5yqBGLIuvaQhnf9KW","ffpaCBUEBIfKFTR0LSG6wa","ff28kp/9tGt6k+KUR4Vso2"],"scenes":{"db://assets/Scene/GameScene.fire":3,"db://assets/Scene/GuideScene.fire":0,"db://assets/Scene/LoadScene.fire":8,"db://assets/Scene/OverScene.fire":2,"db://assets/Scene/RankScene.fire":1},"redirect":[15,0,16,1,17,1,18,1,19,1,20,1,21,1,22,1,23,1,24,1,25,1,27,1,28,1,29,1,30,1,31,1,32,1,33,1,34,1,35,1,36,1,37,1,38,1,39,1,40,1,41,1,43,1,44,1,46,1,47,1,48,1,50,1,51,1,52,1,53,1,54,1,56,1,57,1,58,1,59,1,60,1,61,1,62,0,63,1,64,1,65,1,66,1,68,1,69,1,70,1,72,1,73,1,74,1,75,1,76,1,77,1,78,1,79,1,80,1,81,1,82,1,83,1,84,1,86,1,87,1,88,1,89,1,90,1,92,1,93,1,94,0,95,1,96,1,97,1,98,1,100,1,101,1,102,1,103,1,104,1],"deps":["internal","resources"],"packs":{"023ab8d83":[2,42],"02989e146":[26,8,91,99],"07085ce9a":[0,67,9],"08b19ad34":[3,9],"08d36c5cd":[1,45,49,55,71],"0b81de588":[4,5,6,7,10,11,12,13,14]},"name":"main","importBase":"import","nativeBase":"native","debug":false,"isZip":false,"encrypted":false,"versions":{"import":["023ab8d83","6afe1","02989e146","8139a","07085ce9a","38058","08b19ad34","eb10d","08d36c5cd","5dd93","0b81de588","e3c82",85,"abc94"],"native":[4,"6d707",5,"6d3cf",6,"c06a9",7,"27e3b",10,"83fcc",11,"d55c2",12,"cdbc9",13,"90cf4",14,"ed141"]}}

View File

@ -0,0 +1 @@
[1,["ecpdLyjvZBwrvm+cedCcQy","e9YCqWkdFKZZio+BdFrOfw","63Ss7MWYdAn4yBKFaSiauz","ec2LeWzz1F5qtdmZBv9oQm","75zv/v5GlIRYC94AUoQNJI","4dPk7d9E5OGoZI0XP3Ru6o","58kGAvRw9C6reFjVVlIUra","0am1HlI7tJAr0CCz+R5gFz","eb/m5v8GhCJ7/YFvg05yA/"],["node","_spriteFrame","_N$target","_parent","finishiTime","time","count","scene","_textureSetter"],[["cc.Node",["_name","_active","_id","_objFlags","_opacity","_components","_contentSize","_trs","_parent","_children","_color"],-2,9,5,7,1,2,5],["cc.Node",["_name","_opacity","_parent","_components","_contentSize","_trs","_color","_children"],1,1,2,5,7,5,2],["cc.Sprite",["_type","node","_materials","_spriteFrame"],2,1,3,6],["cc.Label",["_string","_fontSize","_lineHeight","_N$horizontalAlign","_N$verticalAlign","_styleFlags","node","_materials"],-3,1,3],"cc.SpriteFrame",["cc.SceneAsset",["_name","asyncLoadAssets"],1],["cc.Canvas",["_fitWidth","_fitHeight","node","_designResolution"],1,1,5],["cc.Widget",["_alignFlags","node"],2,1],["805c6nf399HWZeuWnNB9CTH",["node","count","time","finishiTime"],3,1,1,1,1],["cc.Button",["zoomScale","_N$transition","node","clickEvents","_N$target"],1,1,9,1],["cc.ClickEvent",["_componentId","handler","target"],1,1],["cc.Scene",["_name","_active","autoReleaseAssets","_children","_anchorPoint","_trs"],0,2,5,7],["cc.Camera",["_clearFlags","_depth","node"],1,1]],[[2,1,2,3,1],[0,0,8,5,6,7,2],[9,0,1,2,3,4,3],[10,0,1,2,3],[3,0,1,2,3,4,6,7,6],[0,0,8,5,6,2],[0,0,8,5,10,6,7,2],[5,0,1,3],[0,0,2,9,5,6,7,3],[0,0,3,9,5,6,7,3],[0,0,9,5,6,7,2],[0,0,1,4,8,9,4],[0,0,1,8,5,6,7,3],[1,0,2,7,3,6,4,5,2],[1,0,2,3,4,5,2],[1,0,1,2,3,6,4,5,3],[6,0,1,2,3,3],[7,0,1,2],[8,0,1,2,3,1],[2,0,1,2,2],[2,1,2,1],[11,0,1,2,3,4,5,4],[12,0,1,2,3],[3,0,1,2,5,3,4,6,7,7]],[[[[7,"OverScene",null],[8,"Canvas","a5esZu+45LA5mBpvttspPD",[-7,-8,-9,-10,-11,-12,-13,-14,-15],[[16,true,false,-1,[5,750,1334]],[17,45,-2],[18,-6,-5,-4,-3]],[5,750,1334],[375,667,0,0,0,0,1,1,1,1]],[9,"again",512,[-19],[[0,-16,[12],13],[2,1.1,3,-18,[[3,"805c6nf399HWZeuWnNB9CTH","again",1]],-17]],[5,501,85],[0,-315.467,0,0,0,0,1,1,1,0]],[10,"rank",[-23],[[0,-20,[16],17],[2,1.1,3,-22,[[3,"805c6nf399HWZeuWnNB9CTH","openRank",1]],-21]],[5,501,85],[0,-456.109,0,0,0,0,1,1,1,0]],[11,"btn",false,0,1,[2,3,-24]],[12,"finishi",false,4,[[0,-25,[18],19],[2,1.1,3,-27,[[3,"805c6nf399HWZeuWnNB9CTH","jumpFinishi",1]],-26]],[5,501,85],[0,-385.904,0,0,0,0,1,1,1,0]],[13,"count",1,[-29],[-28],[4,4281549149],[5,41.71,94.5],[0,174.798,0,0,0,0,1,1,1,1]],[21,"New Node",false,true,[1],[0,0,0],[0,0,0,0,0,0,1,1,1,1]],[5,"Main Camera",1,[[22,7,-1,-30]],[5,960,640]],[5,"bg",1,[[0,-31,[0],1]],[5,750,1660]],[6,"zhun",1,[[4,"准确率",30,30,1,1,-32,[2]]],[4,4287924547],[5,90,37.8],[0.804,245.289,0,0,0,0,1,1,1,1]],[6,"label",6,[[4,"%",32,32,1,1,-33,[3]]],[4,4281549149],[5,28.45,40.32],[0.804,-64.004,0,0,0,0,1,1,1,1]],[23,"0",75,75,1,1,1,6,[4]],[14,"New Sprite",1,[-34],[5,580,37],[0,-52.678,0,0,0,0,1,1,1,1]],[19,3,13,[5]],[15,"time",0,1,[-35],[4,4293126899],[5,149.39,60.48],[0,-127.789,0,0,0,0,1,1,1,1]],[4,"0分0秒",48,48,1,1,15,[6]],[1,"New Node",1,[[20,-36,[7]]],[5,6,155],[-227.685,-154.877,0,0,0,0,1,1,1,1]],[1,"New Sprite",1,[[0,-37,[8],9]],[5,552,204],[-8.015,418.157,0,0,0,0,1,1,1,1]],[1,"New Sprite",2,[[0,-38,[10],11]],[5,156,38],[0,6.32,0,0,0,0,1,1,1,1]],[1,"New Sprite",3,[[0,-39,[14],15]],[5,156,38],[0,5.755,0,0,0,0,1,1,1,1]]],0,[0,0,1,0,0,1,0,4,14,0,5,16,0,6,12,0,0,1,0,-1,8,0,-2,9,0,-3,10,0,-4,6,0,-5,13,0,-6,15,0,-7,17,0,-8,18,0,-9,4,0,0,2,0,2,2,0,0,2,0,-1,19,0,0,3,0,2,3,0,0,3,0,-1,20,0,-3,5,0,0,5,0,2,5,0,0,5,0,-1,12,0,-1,11,0,0,8,0,0,9,0,0,10,0,0,11,0,-1,14,0,-1,16,0,0,17,0,0,18,0,0,19,0,0,20,0,7,7,1,3,7,2,3,4,3,3,4,39],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,14],[-1,1,-1,-1,-1,-1,-1,-1,-1,1,-1,1,-1,1,-1,1,-1,1,-1,1,1],[0,2,0,0,0,0,0,0,0,3,0,4,0,1,0,5,0,1,0,6,7]],[[{"name":"btn","rect":[0,0,501,85],"offset":[0,0],"originalSize":[501,85],"capInsets":[0,0,0,0]}],[4],0,[0],[8],[8]]]]

View File

@ -1 +0,0 @@
[1,["ecpdLyjvZBwrvm+cedCcQy","e9YCqWkdFKZZio+BdFrOfw","4dPk7d9E5OGoZI0XP3Ru6o","63Ss7MWYdAn4yBKFaSiauz","ec2LeWzz1F5qtdmZBv9oQm","75zv/v5GlIRYC94AUoQNJI","58kGAvRw9C6reFjVVlIUra","0am1HlI7tJAr0CCz+R5gFz","eb/m5v8GhCJ7/YFvg05yA/"],["node","_spriteFrame","_parent","_N$target","finishiTime","time","count","scene","_textureSetter"],[["cc.Node",["_name","_active","_id","_opacity","_components","_contentSize","_trs","_children","_parent","_color"],-1,9,5,7,2,1,5],["cc.Node",["_name","_opacity","_parent","_components","_contentSize","_trs","_color","_children"],1,1,2,5,7,5,2],["cc.Sprite",["_type","node","_materials","_spriteFrame"],2,1,3,6],["cc.Label",["_string","_fontSize","_lineHeight","_N$horizontalAlign","_N$verticalAlign","_styleFlags","node","_materials"],-3,1,3],"cc.SpriteFrame",["cc.SceneAsset",["_name","asyncLoadAssets"],1],["cc.Canvas",["_fitWidth","_fitHeight","node","_designResolution"],1,1,5],["cc.Widget",["_alignFlags","node"],2,1],["805c6nf399HWZeuWnNB9CTH",["node","count","time","finishiTime"],3,1,1,1,1],["cc.Button",["zoomScale","_N$transition","node","clickEvents","_N$target"],1,1,9,1],["cc.ClickEvent",["_componentId","handler","target"],1,1],["cc.Scene",["_name","_active","autoReleaseAssets","_children","_anchorPoint","_trs"],0,2,5,7],["cc.Camera",["_clearFlags","_depth","node"],1,1]],[[2,1,2,3,1],[0,0,8,4,5,6,2],[9,0,1,2,3,4,3],[10,0,1,2,3],[3,0,1,2,3,4,6,7,6],[0,0,7,4,5,6,2],[0,0,8,4,5,2],[0,0,8,4,9,5,6,2],[5,0,1,3],[0,0,2,7,4,5,6,3],[0,0,1,7,4,5,6,3],[0,0,1,3,8,7,4],[1,0,2,7,3,6,4,5,2],[1,0,2,3,4,5,2],[1,0,1,2,3,6,4,5,3],[6,0,1,2,3,3],[7,0,1,2],[8,0,1,2,3,1],[2,0,1,2,2],[2,1,2,1],[11,0,1,2,3,4,5,4],[12,0,1,2,3],[3,0,1,2,5,3,4,6,7,7]],[[[[8,"OverScene",null],[9,"Canvas","a5esZu+45LA5mBpvttspPD",[-7,-8,-9,-10,-11,-12,-13,-14,-15],[[15,true,false,-1,[5,750,1334]],[16,45,-2],[17,-6,-5,-4,-3]],[5,750,1334],[375,667,0,0,0,0,1,1,1,1]],[5,"again",[-19],[[0,-16,[12],13],[2,1.1,3,-18,[[3,"805c6nf399HWZeuWnNB9CTH","again",1]],-17]],[5,501,85],[0,-315.467,0,0,0,0,1,1,1,0]],[5,"rank",[-23],[[0,-20,[16],17],[2,1.1,3,-22,[[3,"805c6nf399HWZeuWnNB9CTH","openRank",1]],-21]],[5,501,85],[0,-456.109,0,0,0,0,1,1,1,0]],[10,"finishi",false,[-27],[[0,-24,[20],21],[2,1.1,3,-26,[[3,"805c6nf399HWZeuWnNB9CTH","jumpFinishi",1]],-25]],[5,501,85],[0,-385.904,0,0,0,0,1,1,1,0]],[11,"btn",false,0,1,[2,3,4]],[12,"count",1,[-29],[-28],[4,4281549149],[5,41.71,94.5],[0,174.798,0,0,0,0,1,1,1,1]],[20,"New Node",false,true,[1],[0,0,0],[0,0,0,0,0,0,1,1,1,1]],[6,"Main Camera",1,[[21,7,-1,-30]],[5,960,640]],[6,"bg",1,[[0,-31,[0],1]],[5,750,1660]],[7,"zhun",1,[[4,"准确率",30,30,1,1,-32,[2]]],[4,4287924547],[5,90,37.8],[0.804,245.289,0,0,0,0,1,1,1,1]],[7,"label",6,[[4,"%",32,32,1,1,-33,[3]]],[4,4281549149],[5,28.45,40.32],[0.804,-64.004,0,0,0,0,1,1,1,1]],[22,"0",75,75,1,1,1,6,[4]],[13,"New Sprite",1,[-34],[5,580,37],[0,-52.678,0,0,0,0,1,1,1,1]],[18,3,13,[5]],[14,"time",0,1,[-35],[4,4293126899],[5,149.39,60.48],[0,-127.789,0,0,0,0,1,1,1,1]],[4,"0分0秒",48,48,1,1,15,[6]],[1,"New Node",1,[[19,-36,[7]]],[5,6,155],[-227.685,-154.877,0,0,0,0,1,1,1,1]],[1,"New Sprite",1,[[0,-37,[8],9]],[5,552,204],[-8.015,418.157,0,0,0,0,1,1,1,1]],[1,"New Sprite",2,[[0,-38,[10],11]],[5,156,38],[0,6.32,0,0,0,0,1,1,1,1]],[1,"New Sprite",3,[[0,-39,[14],15]],[5,156,38],[0,5.755,0,0,0,0,1,1,1,1]],[1,"New Sprite",4,[[0,-40,[18],19]],[5,156,38],[0,5.755,0,0,0,0,1,1,1,1]]],0,[0,0,1,0,0,1,0,4,14,0,5,16,0,6,12,0,0,1,0,-1,8,0,-2,9,0,-3,10,0,-4,6,0,-5,13,0,-6,15,0,-7,17,0,-8,18,0,-9,5,0,0,2,0,3,2,0,0,2,0,-1,19,0,0,3,0,3,3,0,0,3,0,-1,20,0,0,4,0,3,4,0,0,4,0,-1,21,0,-1,12,0,-1,11,0,0,8,0,0,9,0,0,10,0,0,11,0,-1,14,0,-1,16,0,0,17,0,0,18,0,0,19,0,0,20,0,0,21,0,7,7,1,2,7,2,2,5,3,2,5,4,2,5,40],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,14],[-1,1,-1,-1,-1,-1,-1,-1,-1,1,-1,1,-1,1,-1,1,-1,1,-1,1,-1,1,1],[0,3,0,0,0,0,0,0,0,4,0,5,0,1,0,2,0,1,0,2,0,6,7]],[[{"name":"btn","rect":[0,0,501,85],"offset":[0,0],"originalSize":[501,85],"capInsets":[0,0,0,0]}],[4],0,[0],[8],[8]]]]

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -136,9 +136,9 @@
</div>
<canvas id="GameCanvas" oncontextmenu="event.preventDefault()" tabindex="0"></canvas>
<script src="src/settings.fcf76.js" charset="utf-8"></script>
<script src="src/settings.d4bfe.js" charset="utf-8"></script>
<script src="main.7dc1b.js" charset="utf-8"></script>
<script src="main.5c0e8.js" charset="utf-8"></script>
<script type="text/javascript">
(function () {
@ -191,17 +191,15 @@
var urlNow = window.location.href;
let userId = getUserId();
if(userId == null){
if(!containsTrain(urlNow) || !isNumber(userId)){
console.log("链接没ID准备跳转");
let url = "https://api.sparkus.cn/api/user/auth/login?domain=hui32579WdYPsgYq&callback="+location.href;
window.location.href = url;
}
let url = "https://api.sparkus.cn/api/user/auth/login?domain=hui32579WdYPsgYq&callback="+
encodeURIComponent(location.href);
console.log("链接没ID准备跳转",url);
window.location.href = url;
}
else{
console.log("链接有ID",userId);
let timestamp = parseInt(new Date().getTime()/1000 + "");
let idData = {
userId: userId,
userId: parseInt(userId),
time: timestamp
}
localStorage.setItem(name,JSON.stringify(idData));
@ -240,7 +238,7 @@
}
loadScript(debug ? 'cocos2d-js.js' : 'cocos2d-js-min.6ff02.js', function () {
loadScript(debug ? 'cocos2d-js.js' : 'cocos2d-js-min.e942d.js', function () {
if (CC_PHYSICS_BUILTIN || CC_PHYSICS_CANNON) {
loadScript(debug ? 'physics.js' : 'physics-min.js', window.boot);
}

View File

@ -117,7 +117,7 @@ window.boot = function () {
if (window.jsb) {
var isRuntime = (typeof loadRuntime === 'function');
if (isRuntime) {
require('src/settings.fcf76.js');
require('src/settings.d4bfe.js');
require('src/cocos2d-runtime.js');
if (CC_PHYSICS_BUILTIN || CC_PHYSICS_CANNON) {
require('src/physics.js');
@ -125,7 +125,7 @@ if (window.jsb) {
require('jsb-adapter/engine/index.js');
}
else {
require('src/settings.fcf76.js');
require('src/settings.d4bfe.js');
require('src/cocos2d-jsb.js');
if (CC_PHYSICS_BUILTIN || CC_PHYSICS_CANNON) {
require('src/physics.js');

View File

@ -1 +1 @@
window._CCSettings={platform:"web-mobile",groupList:["default"],collisionMatrix:[[true]],hasResourcesBundle:true,hasStartSceneBundle:false,remoteBundles:[],subpackages:[],launchScene:"db://assets/Scene/LoadScene.fire",orientation:"portrait",jsList:[],bundleVers:{internal:"d0832",resources:"4f04b",main:"31613"}};
window._CCSettings={platform:"web-mobile",groupList:["default"],collisionMatrix:[[true]],hasResourcesBundle:true,hasStartSceneBundle:false,remoteBundles:[],subpackages:[],launchScene:"db://assets/Scene/LoadScene.fire",orientation:"portrait",jsList:[],bundleVers:{internal:"d0832",resources:"4f04b",main:"2cb9c"}};

View File

@ -15,15 +15,22 @@ var GameTool = {
var name = "user_" + cc.fx.GameConfig.GM_INFO.gameId;
var data = JSON.parse(localStorage.getItem(name));
if (data == "undifend" || data == null || data == "") {
var urlNow = window.location.href;
if (!this.containsTrain(urlNow) || !this.isNumber(data.userId)) {
var url = "https://api.sparkus.cn/api/user/auth/login?domain=hui32579WdYPsgYq&callback=" + location.href;
window.location.href = url;
}
var url = "https://api.sparkus.cn/api/user/auth/login?domain=hui32579WdYPsgYq&callback=" +
encodeURIComponent(location.href);
console.log("链接没ID准备跳转", url);
window.location.href = url;
}
else {
cc.fx.StorageMessage.setStorage(name, data);
cc.fx.GameConfig.GM_INFO.userId = parseInt(data.userId);
if (!this.isNumber(data.userId)) {
var url = "https://api.sparkus.cn/api/user/auth/login?domain=hui32579WdYPsgYq&callback=" +
encodeURIComponent(location.href);
console.log("链接不合法", url);
window.location.href = url;
}
else {
cc.fx.StorageMessage.setStorage(name, data);
cc.fx.GameConfig.GM_INFO.userId = parseInt(data.userId);
}
}
},
isNumber: function (value) {
@ -48,6 +55,7 @@ var GameTool = {
var postData = {
"gameId": cc.fx.GameConfig.GM_INFO.gameId,
"userId": cc.fx.GameConfig.GM_INFO.userId,
"scode": cc.fx.GameConfig.GM_INFO.scode,
"matchId": matchId,
"data": data
};

File diff suppressed because one or more lines are too long

View File

@ -99,14 +99,14 @@
],
"_active": true,
"_components": [
{
"__id__": 38
},
{
"__id__": 39
},
{
"__id__": 40
},
{
"__id__": 41
},
{
"__id__": 42
}
],
"_prefab": null,
@ -1088,7 +1088,7 @@
{
"__type__": "cc.Node",
"_name": "again",
"_objFlags": 0,
"_objFlags": 512,
"_parent": {
"__id__": 21
},
@ -1658,18 +1658,14 @@
"_parent": {
"__id__": 21
},
"_children": [
{
"__id__": 35
}
],
"_children": [],
"_active": false,
"_components": [
{
"__id__": 37
"__id__": 35
},
{
"__id__": 38
"__id__": 36
}
],
"_prefab": null,
@ -1720,102 +1716,6 @@
"groupIndex": 0,
"_id": "75MWyDslJKCpuJ0hRH1qJ2"
},
{
"__type__": "cc.Node",
"_name": "New Sprite",
"_objFlags": 0,
"_parent": {
"__id__": 34
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 36
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 156,
"height": 38
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
5.755,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "dc8IZxiNJCzrTACnYLy8OK"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 35
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "4d3e4edd-f44e-4e1a-8648-d173f746eea8"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": {
"__uuid__": "ef1ad44d-51f9-416e-9fc4-9c35dee52cf3"
},
"_id": "33vTFQuddFTJL8U5cy8H9e"
},
{
"__type__": "cc.Sprite",
"_name": "",
@ -1862,7 +1762,7 @@
"zoomScale": 1.1,
"clickEvents": [
{
"__id__": 39
"__id__": 37
}
],
"_N$interactable": true,

View File

@ -91,15 +91,17 @@ var WeChat = /** @class */ (function () {
console.log("分享好友成功回调");
}
});
wx.updateTimelineShareData({
title: '记忆力认知测评',
link: shareConfig.shareLine,
imgUrl: 'https://static.sparkus.cn/public/shennong.jpg',
success: function () {
// 设置成功
console.log("分享朋友圈成功回调");
}
});
setTimeout(function () {
wx.updateTimelineShareData({
title: '记忆力认知测评',
link: shareConfig.shareLine,
imgUrl: 'https://static.sparkus.cn/public/shennong.jpg',
success: function () {
// 设置成功
console.log("分享朋友圈成功回调");
}
});
}, 200);
});
};
WeChat.getSignature = function (url) {
@ -113,7 +115,7 @@ var WeChat = /** @class */ (function () {
return __generator(this, function (_a) {
time = Math.floor((new Date().getTime()) / 1000);
url = cc.fx.HttpUtil.apiSign("/api/share/cfg?gameId=" + shareConfig.gameId + "&time=" + time + "&url=" + shareUrl, {});
return [2 /*return*/, cc.fx.HttpUtil.get(url, callback)];
return [2 /*return*/, cc.fx.HttpUtil.get(url, callback, 0)];
});
});
};

File diff suppressed because one or more lines are too long

View File

@ -16,6 +16,17 @@ var __extends = (this && this.__extends) || (function () {
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
var __assign = (this && this.__assign) || function () {
__assign = Object.assign || function(t) {
for (var s, i = 1, n = arguments.length; i < n; i++) {
s = arguments[i];
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
t[p] = s[p];
}
return t;
};
return __assign.apply(this, arguments);
};
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
@ -69,17 +80,6 @@ var HttpUtil = /** @class */ (function (_super) {
return _super !== null && _super.apply(this, arguments) || this;
}
HttpUtil_1 = HttpUtil;
HttpUtil.getShareInfo = function (shareUrl) {
return __awaiter(this, void 0, Promise, function () {
var time, url;
return __generator(this, function (_a) {
console.log("设置分享链接:", shareUrl);
time = Math.floor((new Date().getTime()) / 1000);
url = HttpUtil_1.apiSign("/api/share/cfg?gameId=" + config.gameId + "&time=" + time + "&url=" + shareUrl, {});
return [2 /*return*/, this.post(url, null, null)];
});
});
};
//排行榜
HttpUtil.rankData = function (type, callback, data) {
return __awaiter(this, void 0, Promise, function () {
@ -87,7 +87,7 @@ var HttpUtil = /** @class */ (function (_super) {
return __generator(this, function (_a) {
time = Math.floor((new Date().getTime()) / 1000);
url = HttpUtil_1.apiSign("/api/get/rank/data?gameId=" + config.gameId + "&dataType=" + type + "&time=" + time, data);
this.post(url, data, callback);
this.post(url, data, callback, 0);
return [2 /*return*/];
});
});
@ -97,7 +97,7 @@ var HttpUtil = /** @class */ (function (_super) {
var url;
return __generator(this, function (_a) {
url = '/log/collect/data';
this.post(url, data, callback);
this.post(url, data, callback, 3);
return [2 /*return*/];
});
});
@ -109,17 +109,19 @@ var HttpUtil = /** @class */ (function (_super) {
return __generator(this, function (_a) {
time = Math.floor((new Date().getTime()) / 1000);
url = HttpUtil_1.apiSign("/api/get/user/data?gameId=" + config.gameId + "&time=" + time, data);
this.post(url, data, callback);
this.post(url, data, callback, 0);
return [2 /*return*/];
});
});
};
HttpUtil.post = function (url, data, callback) {
HttpUtil.get = function (url, callback, count) {
return __awaiter(this, void 0, void 0, function () {
var response;
var repeat, response;
return __generator(this, function (_a) {
switch (_a.label) {
case 0: return [4 /*yield*/, this.fetchData(url, data, 'POST')];
case 0:
repeat = count ? count : 0;
return [4 /*yield*/, this.fetchData(url, null, 'GET', repeat)];
case 1:
response = _a.sent();
callback && callback(response);
@ -128,12 +130,14 @@ var HttpUtil = /** @class */ (function (_super) {
});
});
};
HttpUtil.get = function (url, callback) {
HttpUtil.post = function (url, data, callback, count) {
return __awaiter(this, void 0, void 0, function () {
var response;
var repeat, response;
return __generator(this, function (_a) {
switch (_a.label) {
case 0: return [4 /*yield*/, this.fetchData(url, null, 'GET')];
case 0:
repeat = count ? count : 0;
return [4 /*yield*/, this.fetchData(url, data, 'POST', repeat)];
case 1:
response = _a.sent();
callback && callback(response);
@ -142,9 +146,10 @@ var HttpUtil = /** @class */ (function (_super) {
});
});
};
HttpUtil.fetchData = function (url, data, method) {
HttpUtil.fetchData = function (url, data, method, repeat) {
return __awaiter(this, void 0, void 0, function () {
var fullUrl, headers, options, response, error_1;
var fullUrl, headers, options, response, error_1, timeOut;
var _this = this;
return __generator(this, function (_a) {
switch (_a.label) {
case 0:
@ -158,23 +163,58 @@ var HttpUtil = /** @class */ (function (_super) {
_a.label = 1;
case 1:
_a.trys.push([1, 4, , 5]);
return [4 /*yield*/, fetch(fullUrl, options)];
return [4 /*yield*/, this.fetchWithTimeout(fullUrl, options)];
case 2:
response = _a.sent();
if (!response.ok) {
throw new Error("HTTP error! status: " + response.status);
throw new Error("HTTP_______________error! status: " + response.status);
}
return [4 /*yield*/, response.json()];
case 3: return [2 /*return*/, _a.sent()];
case 4:
error_1 = _a.sent();
console.error('Fetch error:', error_1);
return [2 /*return*/, null];
console.error('Fetch_______________error:', error_1);
if (repeat > 0) {
repeat -= 1;
timeOut = (3 - repeat) * 5000;
setTimeout(function () { return __awaiter(_this, void 0, void 0, function () {
return __generator(this, function (_a) {
switch (_a.label) {
case 0: return [4 /*yield*/, this.fetchData(url, data, method, repeat)];
case 1:
response = _a.sent();
return [2 /*return*/];
}
});
}); }, timeOut);
}
else {
return [2 /*return*/, null];
}
return [3 /*break*/, 5];
case 5: return [2 /*return*/];
}
});
});
};
HttpUtil.fetchWithTimeout = function (resource, options) {
if (options === void 0) { options = {}; }
return __awaiter(this, void 0, void 0, function () {
var controller, id, response;
return __generator(this, function (_a) {
switch (_a.label) {
case 0:
controller = new AbortController();
id = setTimeout(function () { return controller.abort(); }, 5000);
return [4 /*yield*/, fetch(resource, __assign(__assign({}, options), { signal: controller.signal }))];
case 1:
response = _a.sent();
clearTimeout(id);
return [2 /*return*/, response];
}
});
});
};
/**
*
* @param url {string} 接口地址

File diff suppressed because one or more lines are too long

View File

@ -130,7 +130,7 @@ var NewClass = /** @class */ (function (_super) {
.start();
};
NewClass.prototype.jumpFinishi = function () {
var url = "https://train.sparkus.cn/poster/game/";
var url = "https://train.sparkus.cn/poster/game/" + cc.fx.GameConfig.GM_INFO.scode + "?suc=1";
window.location.href = url;
};
//判断来源

File diff suppressed because one or more lines are too long

View File

@ -1277,7 +1277,7 @@
},
"_enabled": true,
"localTest": false,
"clientTestVersion": "1.3.0",
"clientTestVersion": "1.3.2",
"testVersion": {
"__id__": 21
},

View File

@ -55,6 +55,7 @@ var GameConfig = /** @class */ (function () {
}
var jsonData = res.json;
self.GM_INFO = jsonData["data"];
self.setCode(self.getKey("scode"));
cc.fx.GameTool.getCustom(false);
if (!Authentication)
self.Authentication();
@ -71,6 +72,7 @@ var GameConfig = /** @class */ (function () {
currSeed: 200000,
gameId: "100010",
userId: 200139,
scode: "",
guide: true,
url: "https://api.sparkus.cn",
success: false,
@ -82,6 +84,7 @@ var GameConfig = /** @class */ (function () {
gameTime: 5,
igniteCount: 0,
};
this.setCode(this.getKey("scode"));
};
GameConfig.GM_INFO_SET = function (key, value) {
this.GM_INFO[key] = value;
@ -2609,6 +2612,17 @@ var GameConfig = /** @class */ (function () {
}
];
};
GameConfig.setCode = function (code) {
this.GM_INFO.scode = code;
};
GameConfig.getKey = function (key) {
var reg = new RegExp('(^|&)' + key + '=([^&]*)(&|$)', 'i');
var r = window.location.search.substr(1).match(reg);
if (r != null) {
return unescape(r[2]);
}
return "";
};
GameConfig.Authentication = function () {
cc.fx.GameTool.Authentication();
};

File diff suppressed because one or more lines are too long

View File

@ -60,8 +60,8 @@
"relativePath": "resources"
},
"4b9c5a7e-c645-48a4-9aca-5df381ce4ef5": {
"asset": 1723690855997,
"meta": 1723690856000,
"asset": 1724063448605,
"meta": 1724063448608,
"relativePath": "Scene\\OverScene.fire"
},
"afa9e39a-94ca-477f-8a2a-25082d9092c3": {
@ -415,13 +415,13 @@
"relativePath": "Script\\module\\GameStart\\GameAppStart.ts"
},
"7290c680-dfdc-4c59-9736-a614cc2a8bcf": {
"asset": 1720427814120,
"meta": 1720430964391,
"asset": 1724229846790,
"meta": 1724739216937,
"relativePath": "Script\\module\\Share\\share.ts"
},
"771a3d9a-4013-4654-a777-fbaea0c93280": {
"asset": 1720412209513,
"meta": 1720412232476,
"asset": 1724210582706,
"meta": 1724210692613,
"relativePath": "Script\\module\\Crypto\\HttpUtil.ts"
},
"2d69a479-18ec-4787-b35f-e9a9b3247435": {
@ -486,507 +486,507 @@
},
"9836134e-b892-4283-b6b2-78b5acf3ed45": {
"asset": 1714966328642,
"meta": 1723694526888,
"meta": 1724742314288,
"relativePath": "effects"
},
"abc2cb62-7852-4525-a90d-d474487b88f2": {
"asset": 1714966328642,
"meta": 1723694526992,
"meta": 1724742314397,
"relativePath": "effects\\builtin-phong.effect"
},
"e2f00085-c597-422d-9759-52c360279106": {
"asset": 1714966328642,
"meta": 1723694527036,
"meta": 1724742314441,
"relativePath": "effects\\builtin-toon.effect"
},
"430eccbf-bf2c-4e6e-8c0c-884bbb487f32": {
"asset": 1714966328642,
"meta": 1723694527048,
"meta": 1724742314452,
"relativePath": "effects\\__builtin-editor-gizmo-line.effect"
},
"6c5cf6e1-b044-4eac-9431-835644d57381": {
"asset": 1714966328642,
"meta": 1723694527056,
"meta": 1724742314459,
"relativePath": "effects\\__builtin-editor-gizmo-unlit.effect"
},
"115286d1-2e10-49ee-aab4-341583f607e8": {
"asset": 1714966328642,
"meta": 1723694527085,
"meta": 1724742314482,
"relativePath": "effects\\__builtin-editor-gizmo.effect"
},
"f8e6b000-5643-4b86-9080-aa680ce1f599": {
"asset": 1714966328706,
"meta": 1723694526888,
"meta": 1724742314289,
"relativePath": "image"
},
"b43ff3c2-02bb-4874-81f7-f2dea6970f18": {
"asset": 1714966328658,
"meta": 1723694527125,
"meta": 1724742314518,
"relativePath": "image\\default_btn_pressed.png"
},
"e851e89b-faa2-4484-bea6-5c01dd9f06e2": {
"asset": 1714966328658,
"meta": 1723694527125,
"meta": 1724742314555,
"relativePath": "image\\default_btn_normal.png"
},
"edd215b9-2796-4a05-aaf5-81f96c9281ce": {
"asset": 1714966328658,
"meta": 1723694527166,
"meta": 1724742314522,
"relativePath": "image\\default_editbox_bg.png"
},
"cfef78f1-c8df-49b7-8ed0-4c953ace2621": {
"asset": 1714966328673,
"meta": 1723694527162,
"meta": 1724742314561,
"relativePath": "image\\default_progressbar.png"
},
"d8afc78c-4eac-4a9f-83dd-67bc70344d33": {
"asset": 1714966328862,
"meta": 1723694526892,
"meta": 1724742314294,
"relativePath": "resources"
},
"294c1663-4adf-4a1e-a795-53808011a38a": {
"asset": 1714966328862,
"meta": 1723694527222,
"meta": 1724742314626,
"relativePath": "resources\\effects"
},
"bbee2217-c261-49bd-a8ce-708d6bcc3500": {
"asset": 1714966328893,
"meta": 1723694527226,
"meta": 1724742314629,
"relativePath": "resources\\materials"
},
"30682f87-9f0d-4f17-8a44-72863791461b": {
"asset": 1714966328831,
"meta": 1723694527250,
"meta": 1724742314649,
"relativePath": "resources\\effects\\builtin-2d-graphics.effect"
},
"144c3297-af63-49e8-b8ef-1cfa29b3be28": {
"asset": 1714966328831,
"meta": 1723694527258,
"meta": 1724742314655,
"relativePath": "resources\\effects\\builtin-2d-gray-sprite.effect"
},
"f18742d7-56d2-4eb5-ae49-2d9d710b37c8": {
"asset": 1714966328831,
"meta": 1723694527262,
"meta": 1724742314664,
"relativePath": "resources\\effects\\builtin-2d-label.effect"
},
"0e93aeaa-0b53-4e40-b8e0-6268b4e07bd7": {
"asset": 1714966328831,
"meta": 1723694527270,
"meta": 1724742314671,
"relativePath": "resources\\effects\\builtin-2d-spine.effect"
},
"2874f8dd-416c-4440-81b7-555975426e93": {
"asset": 1714966328846,
"meta": 1723694527278,
"meta": 1724742314677,
"relativePath": "resources\\effects\\builtin-2d-sprite.effect"
},
"829a282c-b049-4019-bd38-5ace8d8a6417": {
"asset": 1714966328846,
"meta": 1723694527326,
"meta": 1724742314732,
"relativePath": "resources\\effects\\builtin-3d-particle.effect"
},
"2a7c0036-e0b3-4fe1-8998-89a54b8a2bec": {
"asset": 1714966328846,
"meta": 1723694527338,
"meta": 1724742314747,
"relativePath": "resources\\effects\\builtin-3d-trail.effect"
},
"c0040c95-c57f-49cd-9cbc-12316b73d0d4": {
"asset": 1714966328846,
"meta": 1723694527346,
"meta": 1724742314759,
"relativePath": "resources\\effects\\builtin-clear-stencil.effect"
},
"6d91e591-4ce0-465c-809f-610ec95019c6": {
"asset": 1714966328862,
"meta": 1723694527354,
"meta": 1724742314768,
"relativePath": "resources\\effects\\builtin-unlit.effect"
},
"e02d87d4-e599-4d16-8001-e14891ac6506": {
"asset": 1714966328878,
"meta": 1723694527434,
"meta": 1724742314847,
"relativePath": "resources\\materials\\builtin-2d-label.mtl"
},
"a153945d-2511-4c14-be7b-05d242f47d57": {
"asset": 1714966328862,
"meta": 1723694527434,
"meta": 1724742314847,
"relativePath": "resources\\materials\\builtin-2d-graphics.mtl"
},
"6f801092-0c37-4f30-89ef-c8d960825b36": {
"asset": 1714966328862,
"meta": 1723694527430,
"meta": 1724742314845,
"relativePath": "resources\\materials\\builtin-2d-base.mtl"
},
"7afd064b-113f-480e-b793-8817d19f63c3": {
"asset": 1714966328878,
"meta": 1723694527434,
"meta": 1724742314848,
"relativePath": "resources\\materials\\builtin-2d-spine.mtl"
},
"eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432": {
"asset": 1714966328878,
"meta": 1723694527434,
"meta": 1724742314850,
"relativePath": "resources\\materials\\builtin-2d-sprite.mtl"
},
"2a296057-247c-4a1c-bbeb-0548b6c98650": {
"asset": 1714966328893,
"meta": 1723694527442,
"meta": 1724742314852,
"relativePath": "resources\\materials\\builtin-unlit.mtl"
},
"cf7e0bb8-a81c-44a9-ad79-d28d43991032": {
"asset": 1714966328878,
"meta": 1723694527442,
"meta": 1724742314850,
"relativePath": "resources\\materials\\builtin-clear-stencil.mtl"
},
"466d4f9b-e5f4-4ea8-85d5-3c6e9a65658a": {
"asset": 1714966328878,
"meta": 1723694527438,
"meta": 1724742314851,
"relativePath": "resources\\materials\\builtin-3d-trail.mtl"
},
"3a7bb79f-32fd-422e-ada2-96f518fed422": {
"asset": 1714966328862,
"meta": 1723694527434,
"meta": 1724742314846,
"relativePath": "resources\\materials\\builtin-2d-gray-sprite.mtl"
},
"432fa09c-cf03-4cff-a186-982604408a07": {
"asset": 1714966328878,
"meta": 1723694527442,
"meta": 1724742314848,
"relativePath": "resources\\materials\\builtin-3d-particle.mtl"
},
"5c3eedba-6c41-4c0c-9ba7-d91f813cbd1c": {
"asset": 1714966328721,
"meta": 1723694526892,
"meta": 1724742314290,
"relativePath": "materials"
},
"fc09f9bd-2cce-4605-b630-8145ef809ed6": {
"asset": 1714966328721,
"meta": 1723694526892,
"meta": 1724742314290,
"relativePath": "misc"
},
"db019bf7-f71c-4111-98cf-918ea180cb48": {
"asset": 1714966328737,
"meta": 1723694526892,
"meta": 1724742314291,
"relativePath": "model"
},
"e39e96e6-6f6e-413f-bcf1-ac7679bb648a": {
"asset": 1714966328737,
"meta": 1723694527137,
"meta": 1724742314531,
"relativePath": "model\\prefab"
},
"617323dd-11f4-4dd3-8eec-0caf6b3b45b9": {
"asset": 1714966328689,
"meta": 1723694527170,
"meta": 1724742314566,
"relativePath": "image\\default_scrollbar_vertical_bg.png"
},
"b181c1e4-0a72-4a91-bfb0-ae6f36ca60bd": {
"asset": 1714966328706,
"meta": 1723694527234,
"meta": 1724742314627,
"relativePath": "image\\default_toggle_pressed.png"
},
"d81ec8ad-247c-4e62-aa3c-d35c4193c7af": {
"asset": 1714966328673,
"meta": 1723694527137,
"meta": 1724742314520,
"relativePath": "image\\default_panel.png"
},
"c25b9d50-c8fc-4d27-beeb-6e7c1f2e5c0f": {
"asset": 1714966328706,
"meta": 1723694527218,
"meta": 1724742314643,
"relativePath": "image\\default_toggle_disabled.png"
},
"6e056173-d285-473c-b206-40a7fff5386e": {
"asset": 1714966328689,
"meta": 1723694527166,
"meta": 1724742314562,
"relativePath": "image\\default_sprite.png"
},
"f6e6dd15-71d1-4ffe-ace7-24fd39942c05": {
"asset": 1714966328752,
"meta": 1723694526892,
"meta": 1724742314292,
"relativePath": "obsolete"
},
"9d60001f-b5f4-4726-a629-2659e3ded0b8": {
"asset": 1714966328673,
"meta": 1723694527133,
"meta": 1724742314559,
"relativePath": "image\\default_radio_button_on.png"
},
"4bab67cb-18e6-4099-b840-355f0473f890": {
"asset": 1714966328689,
"meta": 1723694527158,
"meta": 1724742314525,
"relativePath": "image\\default_scrollbar_bg.png"
},
"71561142-4c83-4933-afca-cb7a17f67053": {
"asset": 1714966328658,
"meta": 1723694527121,
"meta": 1724742314530,
"relativePath": "image\\default_btn_disabled.png"
},
"f743d2b6-b7ea-4c14-a55b-547ed4d0a045": {
"asset": 1714966328752,
"meta": 1723694526892,
"meta": 1724742314292,
"relativePath": "particle"
},
"567dcd80-8bf4-4535-8a5a-313f1caf078a": {
"asset": 1714966328673,
"meta": 1723694527133,
"meta": 1724742314528,
"relativePath": "image\\default_radio_button_off.png"
},
"99170b0b-d210-46f1-b213-7d9e3f23098a": {
"asset": 1714966328673,
"meta": 1723694527170,
"meta": 1724742314523,
"relativePath": "image\\default_progressbar_bg.png"
},
"ae6c6c98-11e4-452f-8758-75f5c6a56e83": {
"asset": 1714966328831,
"meta": 1723694526892,
"meta": 1724742314293,
"relativePath": "prefab"
},
"0275e94c-56a7-410f-bd1a-fc7483f7d14a": {
"asset": 1714966328705,
"meta": 1723694527170,
"meta": 1724742314568,
"relativePath": "image\\default_sprite_splash.png"
},
"c4480a0a-6ac5-443f-8b40-361a14257fc8": {
"asset": 1714966328706,
"meta": 1723694527414,
"meta": 1724742314825,
"relativePath": "materials\\builtin-phong.mtl"
},
"d6d3ca85-4681-47c1-b5dd-d036a9d39ea2": {
"asset": 1714966328689,
"meta": 1723694527162,
"meta": 1724742314564,
"relativePath": "image\\default_scrollbar_vertical.png"
},
"a87cc147-01b2-43f8-8e42-a7ca90b0c757": {
"asset": 1714966328721,
"meta": 1723694527342,
"meta": 1724742314770,
"relativePath": "model\\prefab\\box.prefab"
},
"fe1417b6-fe6b-46a4-ae7c-9fd331f33a2a": {
"asset": 1714966328737,
"meta": 1723694527346,
"meta": 1724742314772,
"relativePath": "model\\prefab\\capsule.prefab"
},
"b5fc2cf2-7942-483d-be1f-bbeadc4714ad": {
"asset": 1714966328737,
"meta": 1723694527358,
"meta": 1724742314778,
"relativePath": "model\\prefab\\cone.prefab"
},
"0291c134-b3da-4098-b7b5-e397edbe947f": {
"asset": 1714966328689,
"meta": 1723694527162,
"meta": 1724742314557,
"relativePath": "image\\default_scrollbar.png"
},
"2d9a4b85-b0ab-4c46-84c5-18f393ab2058": {
"asset": 1714966328737,
"meta": 1723694527366,
"meta": 1724742314780,
"relativePath": "model\\prefab\\sphere.prefab"
},
"3f376125-a699-40ca-ad05-04d662eaa1f2": {
"asset": 1714966328737,
"meta": 1723694527362,
"meta": 1724742314773,
"relativePath": "model\\prefab\\plane.prefab"
},
"73a0903d-d80e-4e3c-aa67-f999543c08f5": {
"asset": 1714966328706,
"meta": 1723694527226,
"meta": 1724742314625,
"relativePath": "image\\default_toggle_checkmark.png"
},
"de510076-056b-484f-b94c-83bef217d0e1": {
"asset": 1714966328737,
"meta": 1723694527362,
"meta": 1724742314781,
"relativePath": "model\\prefab\\torus.prefab"
},
"a3ee0214-b432-4865-9666-4a3211814282": {
"asset": 1714966328800,
"meta": 1723694527182,
"meta": 1724742314575,
"relativePath": "prefab\\light"
},
"6c9ef10d-b479-420b-bfe6-39cdda6a8ae0": {
"asset": 1714966328737,
"meta": 1723694527366,
"meta": 1724742314777,
"relativePath": "model\\prefab\\quad.prefab"
},
"d29077ba-1627-4a72-9579-7b56a235340c": {
"asset": 1714966328706,
"meta": 1723694527234,
"meta": 1724742314639,
"relativePath": "image\\default_toggle_normal.png"
},
"1c5e4038-953a-44c2-b620-0bbfc6170477": {
"asset": 1714966328737,
"meta": 1723694527362,
"meta": 1724742314775,
"relativePath": "model\\prefab\\cylinder.prefab"
},
"897ef7a1-4860-4f64-968d-f5924b18668a": {
"asset": 1714966328752,
"meta": 1723694527178,
"meta": 1724742314574,
"relativePath": "prefab\\2d-camera.prefab"
},
"70d7cdb0-04cd-41bb-9480-c06a4785f386": {
"asset": 1714966328768,
"meta": 1723694527178,
"meta": 1724742314573,
"relativePath": "prefab\\3d-camera.prefab"
},
"600301aa-3357-4a10-b086-84f011fa32ba": {
"asset": 1714966328642,
"meta": 1723694527129,
"meta": 1724742314554,
"relativePath": "image\\default-particle.png"
},
"70bbeb73-6dc2-4ee4-8faf-76b3a0e34ec4": {
"asset": 1714966328768,
"meta": 1723694527186,
"meta": 1724742314578,
"relativePath": "prefab\\3d-particle.prefab"
},
"ed88f13d-fcad-4848-aa35-65a2cb973584": {
"asset": 1714966328768,
"meta": 1723694527182,
"meta": 1724742314580,
"relativePath": "prefab\\3d-stage.prefab"
},
"972b9a4d-47ee-4c74-b5c3-61d8a69bc29f": {
"asset": 1714966328768,
"meta": 1723694527182,
"meta": 1724742314583,
"relativePath": "prefab\\button.prefab"
},
"2c937608-2562-40ea-b264-7395df6f0cea": {
"asset": 1714966328768,
"meta": 1723694527186,
"meta": 1724742314582,
"relativePath": "prefab\\canvas.prefab"
},
"61aeb05b-3b32-452b-8eed-2b76deeed554": {
"asset": 1714966328783,
"meta": 1723694527190,
"meta": 1724742314585,
"relativePath": "prefab\\editbox.prefab"
},
"27756ebb-3d33-44b0-9b96-e858fadd4dd4": {
"asset": 1714966328783,
"meta": 1723694527192,
"meta": 1724742314589,
"relativePath": "prefab\\label.prefab"
},
"785a442c-3ceb-45be-a46e-7317f625f3b9": {
"asset": 1714966328783,
"meta": 1723694527194,
"meta": 1724742314591,
"relativePath": "prefab\\layout.prefab"
},
"ca8401fe-ad6e-41a8-bd46-8e3e4e9945be": {
"asset": 1714966328800,
"meta": 1723694527194,
"meta": 1724742314594,
"relativePath": "prefab\\pageview.prefab"
},
"5965ffac-69da-4b55-bcde-9225d0613c28": {
"asset": 1714966328800,
"meta": 1723694527198,
"meta": 1724742314595,
"relativePath": "prefab\\progressBar.prefab"
},
"cd33edea-55f5-46c2-958d-357a01384a36": {
"asset": 1714966328800,
"meta": 1723694527198,
"meta": 1724742314602,
"relativePath": "prefab\\particlesystem.prefab"
},
"4a37dd57-78cd-4cec-aad4-f11a73d12b63": {
"asset": 1714966328800,
"meta": 1723694527202,
"meta": 1724742314603,
"relativePath": "prefab\\richtext.prefab"
},
"0004d1cf-a0ad-47d8-ab17-34d3db9d35a3": {
"asset": 1714966328800,
"meta": 1723694527203,
"meta": 1724742314600,
"relativePath": "prefab\\slider.prefab"
},
"32044bd2-481f-4cf1-a656-e2b2fb1594eb": {
"asset": 1714966328800,
"meta": 1723694527203,
"meta": 1724742314598,
"relativePath": "prefab\\scrollview.prefab"
},
"96083d03-c332-4a3f-9386-d03e2d19e8ee": {
"asset": 1714966328815,
"meta": 1723694527222,
"meta": 1724742314612,
"relativePath": "prefab\\sprite.prefab"
},
"7de03a80-4457-438d-95a7-3e7cdffd6086": {
"asset": 1714966328815,
"meta": 1723694527230,
"meta": 1724742314633,
"relativePath": "prefab\\tiledmap.prefab"
},
"1f55e3be-b89b-4b79-88de-47fd31018044": {
"asset": 1714966328815,
"meta": 1723694527222,
"meta": 1724742314630,
"relativePath": "prefab\\sprite_splash.prefab"
},
"2be36297-9abb-4fee-8049-9ed5e271da8a": {
"asset": 1714966328721,
"meta": 1723694527250,
"meta": 1724742314650,
"relativePath": "misc\\default_video.mp4"
},
"0e42ba95-1fa1-46aa-b2cf-143cd1bcee2c": {
"asset": 1714966328815,
"meta": 1723694527230,
"meta": 1724742314635,
"relativePath": "prefab\\tiledtile.prefab"
},
"bf0a434c-84dd-4a8e-a08a-7a36f180cc75": {
"asset": 1714966328815,
"meta": 1723694527238,
"meta": 1724742314637,
"relativePath": "prefab\\toggleContainer.prefab"
},
"0d784963-d024-4ea6-a7db-03be0ad63010": {
"asset": 1714966328815,
"meta": 1723694527230,
"meta": 1724742314635,
"relativePath": "prefab\\toggle.prefab"
},
"232d2782-c4bd-4bb4-9e01-909f03d6d3b9": {
"asset": 1714966328815,
"meta": 1723694527242,
"meta": 1724742314642,
"relativePath": "prefab\\videoplayer.prefab"
},
"d1b8be49-b0a0-435c-83b7-552bed4bbe35": {
"asset": 1714966328815,
"meta": 1723694527238,
"meta": 1724742314641,
"relativePath": "prefab\\toggleGroup.prefab"
},
"8c5001fd-07ee-4a4b-a8a0-63e15195e94d": {
"asset": 1714966328831,
"meta": 1723694527326,
"meta": 1724742314734,
"relativePath": "prefab\\webview.prefab"
},
"61906da3-7003-4bda-9abc-5769c76faee4": {
"asset": 1714966328783,
"meta": 1723694527366,
"meta": 1724742314784,
"relativePath": "prefab\\light\\ambient.prefab"
},
"0cf30284-9073-46bc-9eba-e62b69dbbff3": {
"asset": 1714966328800,
"meta": 1723694527366,
"meta": 1724742314786,
"relativePath": "prefab\\light\\point.prefab"
},
"ddb99b39-7004-47cd-9705-751905c43c46": {
"asset": 1714966328800,
"meta": 1723694527370,
"meta": 1724742314784,
"relativePath": "prefab\\light\\directional.prefab"
},
"f5331fd2-bf42-4ee3-a3fd-3e1657600eff": {
"asset": 1714966328800,
"meta": 1723694527370,
"meta": 1724742314785,
"relativePath": "prefab\\light\\spot.prefab"
},
"d0a82d39-bede-46c4-b698-c81ff0dedfff": {
"asset": 1714966328752,
"meta": 1723694527246,
"meta": 1724742314632,
"relativePath": "particle\\atom.png"
},
"8a96b965-2dc0-4e03-aa90-3b79cb93b5b4": {
"asset": 1714966328752,
"meta": 1723694527242,
"meta": 1724742314644,
"relativePath": "obsolete\\atom.png"
},
"b2687ac4-099e-403c-a192-ff477686f4f5": {
"asset": 1714966328752,
"meta": 1723694527457,
"meta": 1724742314871,
"relativePath": "particle\\atom.plist"
},
"b8223619-7e38-47c4-841f-9160c232495a": {
"asset": 1714966328752,
"meta": 1723694527456,
"meta": 1724742314872,
"relativePath": "obsolete\\atom.plist"
},
"954fec8b-cd16-4bb9-a3b7-7719660e7558": {
"asset": 1714966328737,
"meta": 1723694529057,
"meta": 1724742316310,
"relativePath": "model\\primitives.fbx"
},
"454ad829-851a-40ea-8ab9-941e828357ca": {
"asset": 1723690198625,
"meta": 1723690237665,
"asset": 1724227554574,
"meta": 1724739216915,
"relativePath": "Script\\Load.ts"
},
"ebfe6e6f-f068-4227-bfd8-16f834e7203f": {
@ -994,16 +994,6 @@
"meta": 1723690237680,
"relativePath": "res\\btn.png"
},
"805c69df-dfdf-4759-97ae-5a7341f424c7": {
"asset": 1723690319971,
"meta": 1723690322655,
"relativePath": "Script\\GameOver.ts"
},
"c5692be7-8703-45e4-9f67-23b54d290356": {
"asset": 1723690529059,
"meta": 1723690642750,
"relativePath": "Script\\module\\Config\\GameConfig.ts"
},
"2cddbdcb-5dba-4b13-960c-9ebe6d17a7db": {
"asset": 1723690641486,
"meta": 1723690642758,
@ -1015,13 +1005,23 @@
"relativePath": "Script\\GameManager.ts"
},
"9c08062d-4cf1-4b6e-a8ba-4a3881cc7e7d": {
"asset": 1723694645433,
"meta": 1723694645441,
"asset": 1724225193152,
"meta": 1724225193155,
"relativePath": "Scene\\LoadScene.fire"
},
"805c69df-dfdf-4759-97ae-5a7341f424c7": {
"asset": 1724212141077,
"meta": 1724224709706,
"relativePath": "Script\\GameOver.ts"
},
"43bfc27a-ff6e-45b3-87c7-504d0f781397": {
"asset": 1723694643223,
"meta": 1723694644129,
"asset": 1724224763301,
"meta": 1724225328971,
"relativePath": "Script\\module\\Tool\\GameTool.ts"
},
"c5692be7-8703-45e4-9f67-23b54d290356": {
"asset": 1724225112550,
"meta": 1724225119725,
"relativePath": "Script\\module\\Config\\GameConfig.ts"
}
}

View File

@ -14,12 +14,12 @@
"children": [
{
"width": 257.8333435058594,
"height": 571,
"height": 568.5,
"type": "dock-v",
"children": [
{
"width": 257.8333435058594,
"height": 299.91668701171875,
"height": 298.59375,
"type": "panel",
"active": 0,
"children": [
@ -28,7 +28,7 @@
},
{
"width": 257.8333435058594,
"height": 268.07293701171875,
"height": 266.8958435058594,
"type": "panel",
"active": 0,
"children": [
@ -39,7 +39,7 @@
},
{
"width": 635.9896240234375,
"height": 571,
"height": 568.5,
"type": "panel",
"active": 0,
"children": [
@ -48,7 +48,7 @@
},
{
"width": 380.1770935058594,
"height": 571,
"height": 568.5,
"type": "panel",
"active": 0,
"children": [
@ -65,8 +65,7 @@
"inspector",
"cocos-services"
]
},
" common-asset-worker-worker": {}
}
},
"panels": {
"builder": {
@ -106,8 +105,8 @@
"height": 538
},
"mini_font": {
"x": 374,
"y": 0,
"x": 404,
"y": 36,
"width": 516,
"height": 672
}

View File

@ -1 +0,0 @@
{"input_path":"C:\\Work\\下载\\SourceHanSerifSC-Heavy.ttf","out_path":"C:\\Work\\字体\\新建文件夹","text_content":"%0:123456789。排行距离洪峰到来总时间图纸息壤加固清空撤回点击屏幕继续这里是一局游戏的总时间\n倒计时结束后本局自动结束这里是每轮的时间洪峰来临\n前没有开始修建就会失败哦你的目标是将洪水从\n源头引入入海口点击方向键来规划\n修建的方向修建到山峰上会导致\n直接失败避开它吧再向右避开上面的山峰吧记录下的路线会显示在图纸里这里可以清空图纸或是\n返回上一步遇到湿地时需要先加固\n地面才可以通过点击这里进行加固加固也会显示在图纸中加固后就可以正常\n通过了使用大禹的宝物\"息壤\",堤坝便会\n自动向选的的方向自动生长除非\n下一个是山峰或边界息壤还会把\n经过的湿地变成平原无需加固\n使用息壤后选中方向\n息壤即可生效息壤遇到入海口时也会自动停下\n快试试吧使用息壤后向下引入入海口开始修建堤坝来引导\n洪水吧准确率%用户昵称治水得分超过了的人","text_content2":"此脚本由自动生成仅用于兼容版的工程你无需在任何其它项目中手添加如果没到可直接删除该有托管等库请将一并上传代码修改时是否触发与事件移速度间参数位个固定状态初始化据展示准确率完排行榜关卡分秒答对总打开重新玩主游戏控制类点击当前名字信息第步植物按钮掉计器处理逻辑之先正火葡萄刚才出现过呢这局次桃子遇似乎不听吧木柴看实但最近每倒结束选择几存放大所图片声音配置地根全面屏做独立适方创建埋设转圈以判断把品入组获取反应题进下错误只为三检查频再盘里险算防止溢轮首返回页或者决戳胜失败调法操作测试勾避免和报提交客户端标记便区线跳至引导备来指头像人换画列表己能内量口际比较多公共了都通盛后清空型合家截未从依案含义相同式毫%0:123456789。排行距离洪峰到来总时间图纸息壤加固清空撤回点击屏幕继续这里是一局游戏的总时间\n倒计时结束后本局自动结束这里是每轮的时间洪峰来临\n前没有开始修建就会失败哦你的目标是将洪水从\n源头引入入海口点击方向键来规划\n修建的方向修建到山峰上会导致\n直接失败避开它吧再向右避开上面的山峰吧记录下的路线会显示在图纸里这里可以清空图纸或是\n返回上一步遇到湿地时需要先加固\n地面才可以通过点击这里进行加固加固也会显示在图纸中加固后就可以正常\n通过了使用大禹的宝物\"息壤\",堤坝便会\n自动向选的的方向自动生长除非\n下一个是山峰或边界息壤还会把\n经过的湿地变成平原无需加固\n使用息壤后选中方向\n息壤即可生效息壤遇到入海口时也会自动停下\n快试试吧使用息壤后向下引入入海口开始修建堤坝来引导\n洪水吧准确率%用户昵称治水得分超过了的人播使哪套功稱種類平均箭随机种访问域具体整涉及场景切要保留负单废弃暂源责网络互享链址密象拼符串响拦向明值情况跟持致解验证键序滤然询装签求统基础台系文默认群邀好友日常复活奖励翻倍宝箱领球赛元红包金币桌高连破产儿给微储消级语照骤神农氏今天收集他拿说告诉则视流广干预显登录授权索变输知见附忆力评灵性注意吗描述路径必须众号安朋背乐监浏览退小效停警水垂格布而属即板隔距左右滚例宽离心超会被般因范围得还刷函遍各起偏长虚拟末尾底隐藏余锚居顶部穷滑边界坐增替销毁池零缓循环带二短那白芍荆芥丹归枸杞牡兰蒲英茉莉桔枣李荔枝姜竹叶龙眼赤豆甘草茶剩拉","switch_number":true,"switch_lowercase_letters":true,"switch_capital_letters":true,"switch_symbol_letters":true,"switch_find_ts":true,"switch_find_js":true,"switch_find_json":true}

View File

@ -1,5 +1,5 @@
{
"last-module-event-record-time": 1723193375713,
"last-module-event-record-time": 1724054752293,
"group-list": [
"default"
],

View File

@ -1276,7 +1276,7 @@
},
"_enabled": true,
"localTest": false,
"clientTestVersion": "1.3.0",
"clientTestVersion": "1.3.2",
"testVersion": {
"__id__": 21
},

View File

@ -98,14 +98,14 @@
],
"_active": true,
"_components": [
{
"__id__": 38
},
{
"__id__": 39
},
{
"__id__": 40
},
{
"__id__": 41
},
{
"__id__": 42
}
],
"_prefab": null,
@ -1087,7 +1087,7 @@
{
"__type__": "cc.Node",
"_name": "again",
"_objFlags": 0,
"_objFlags": 512,
"_parent": {
"__id__": 21
},
@ -1657,18 +1657,14 @@
"_parent": {
"__id__": 21
},
"_children": [
{
"__id__": 35
}
],
"_children": [],
"_active": false,
"_components": [
{
"__id__": 37
"__id__": 35
},
{
"__id__": 38
"__id__": 36
}
],
"_prefab": null,
@ -1719,102 +1715,6 @@
"groupIndex": 0,
"_id": "75MWyDslJKCpuJ0hRH1qJ2"
},
{
"__type__": "cc.Node",
"_name": "New Sprite",
"_objFlags": 0,
"_parent": {
"__id__": 34
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 36
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 156,
"height": 38
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
5.755,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "dc8IZxiNJCzrTACnYLy8OK"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 35
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "4d3e4edd-f44e-4e1a-8648-d173f746eea8"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": {
"__uuid__": "ef1ad44d-51f9-416e-9fc4-9c35dee52cf3"
},
"_id": "33vTFQuddFTJL8U5cy8H9e"
},
{
"__type__": "cc.Sprite",
"_name": "",
@ -1861,7 +1761,7 @@
"zoomScale": 1.1,
"clickEvents": [
{
"__id__": 39
"__id__": 37
}
],
"_N$interactable": true,

View File

@ -1 +1 @@
{"version":"1.0.8","stats":{"C:/Work/Project/Shennong/temp/quick-scripts/src/__qc_index__.js":"2024-08-15T04:02:09.367Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/Load.js":"2024-08-15T04:02:09.317Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/migration/use_v2.1-2.2.1_cc.Toggle_event.js":"2024-08-15T04:02:09.327Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/GameOver.js":"2024-08-15T04:02:09.328Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/GuideManager.js":"2024-08-15T04:02:09.338Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/GameScene.js":"2024-08-15T04:02:09.337Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/Block.js":"2024-08-15T04:02:09.333Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/DynamicAtlasManager.js":"2024-08-15T04:02:09.321Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/RankManager.js":"2024-08-15T04:02:09.336Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/Config/GameConfig.js":"2024-08-15T04:02:09.330Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/GameManager.js":"2024-08-15T04:02:09.329Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/GameStart/GameAppStart.js":"2024-08-15T04:02:09.324Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/Notification/Notification.js":"2024-08-15T04:02:09.319Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/Crypto/HttpUtil.js":"2024-08-15T04:02:09.326Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/RankList/ItemRender.js":"2024-08-15T04:02:09.331Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/Music/AudioManager.js":"2024-08-15T04:02:09.320Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/Storage/Storage.js":"2024-08-15T04:02:09.315Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/Tool/GameTool.js":"2024-08-15T04:02:09.316Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/Share/share.js":"2024-08-15T04:02:09.325Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/Crypto/crypto-js.min.js":"2024-08-15T04:02:09.334Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/RankList/List.js":"2024-08-15T04:02:09.332Z"}}
{"version":"1.0.8","stats":{"C:/Work/Project/Shennong/temp/quick-scripts/src/__qc_index__.js":"2024-08-27T07:06:39.099Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/Block.js":"2024-08-27T07:06:39.063Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/migration/use_v2.1-2.2.1_cc.Toggle_event.js":"2024-08-27T07:06:39.057Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/GameManager.js":"2024-08-27T07:06:39.057Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/GuideManager.js":"2024-08-27T07:06:39.067Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/GameOver.js":"2024-08-27T07:06:39.057Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/RankManager.js":"2024-08-27T07:06:39.063Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/GameScene.js":"2024-08-27T07:06:39.067Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/Load.js":"2024-08-27T07:06:39.047Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/DynamicAtlasManager.js":"2024-08-27T07:06:39.051Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/Notification/Notification.js":"2024-08-27T07:06:39.047Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/Share/share.js":"2024-08-27T07:06:39.051Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/RankList/List.js":"2024-08-27T07:06:39.059Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/Music/AudioManager.js":"2024-08-27T07:06:39.047Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/Storage/Storage.js":"2024-08-27T07:06:39.043Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/GameStart/GameAppStart.js":"2024-08-27T07:06:39.051Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/Crypto/HttpUtil.js":"2024-08-27T07:06:39.055Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/Tool/GameTool.js":"2024-08-27T07:06:39.045Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/Config/GameConfig.js":"2024-08-27T07:06:39.059Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/RankList/ItemRender.js":"2024-08-27T07:06:39.059Z","C:/Work/Project/Shennong/temp/quick-scripts/src/assets/Script/module/Crypto/crypto-js.min.js":"2024-08-27T07:06:39.063Z"}}

File diff suppressed because one or more lines are too long

View File

@ -1,6 +1,6 @@
(function () {
var scripts = [{"deps":{"./assets/Script/GameManager":10,"./assets/Script/GameOver":3,"./assets/Script/GameScene":5,"./assets/Script/GuideManager":4,"./assets/Script/Load":1,"./assets/Script/RankManager":8,"./assets/Script/Block":6,"./assets/migration/use_v2.1-2.2.1_cc.Toggle_event":2,"./assets/Script/DynamicAtlasManager":7,"./assets/Script/module/Crypto/crypto-js.min":19,"./assets/Script/module/Crypto/HttpUtil":13,"./assets/Script/module/GameStart/GameAppStart":11,"./assets/Script/module/Music/AudioManager":15,"./assets/Script/module/Notification/Notification":12,"./assets/Script/module/RankList/List":20,"./assets/Script/module/RankList/ItemRender":14,"./assets/Script/module/Share/share":18,"./assets/Script/module/Storage/Storage":16,"./assets/Script/module/Tool/GameTool":17,"./assets/Script/module/Config/GameConfig":9},"path":"preview-scripts/__qc_index__.js"},{"deps":{"./module/Share/share":18},"path":"preview-scripts/assets/Script/Load.js"},{"deps":{},"path":"preview-scripts/assets/migration/use_v2.1-2.2.1_cc.Toggle_event.js"},{"deps":{},"path":"preview-scripts/assets/Script/GameOver.js"},{"deps":{},"path":"preview-scripts/assets/Script/GuideManager.js"},{"deps":{},"path":"preview-scripts/assets/Script/GameScene.js"},{"deps":{},"path":"preview-scripts/assets/Script/Block.js"},{"deps":{},"path":"preview-scripts/assets/Script/DynamicAtlasManager.js"},{"deps":{"./module/RankList/List":20},"path":"preview-scripts/assets/Script/RankManager.js"},{"deps":{},"path":"preview-scripts/assets/Script/module/Config/GameConfig.js"},{"deps":{},"path":"preview-scripts/assets/Script/GameManager.js"},{"deps":{"../Config/GameConfig":9,"../Crypto/HttpUtil":13,"../Music/AudioManager":15,"../Notification/Notification":12,"../Storage/Storage":16,"../Tool/GameTool":17},"path":"preview-scripts/assets/Script/module/GameStart/GameAppStart.js"},{"deps":{},"path":"preview-scripts/assets/Script/module/Notification/Notification.js"},{"deps":{"./crypto-js.min.js":19},"path":"preview-scripts/assets/Script/module/Crypto/HttpUtil.js"},{"deps":{},"path":"preview-scripts/assets/Script/module/RankList/ItemRender.js"},{"deps":{},"path":"preview-scripts/assets/Script/module/Music/AudioManager.js"},{"deps":{},"path":"preview-scripts/assets/Script/module/Storage/Storage.js"},{"deps":{},"path":"preview-scripts/assets/Script/module/Tool/GameTool.js"},{"deps":{},"path":"preview-scripts/assets/Script/module/Share/share.js"},{"deps":{},"path":"preview-scripts/assets/Script/module/Crypto/crypto-js.min.js"},{"deps":{"./ItemRender":14},"path":"preview-scripts/assets/Script/module/RankList/List.js"}];
var scripts = [{"deps":{"./assets/Script/Block":1,"./assets/migration/use_v2.1-2.2.1_cc.Toggle_event":2,"./assets/Script/GameManager":3,"./assets/Script/GuideManager":4,"./assets/Script/GameOver":5,"./assets/Script/RankManager":6,"./assets/Script/GameScene":7,"./assets/Script/Load":8,"./assets/Script/DynamicAtlasManager":9,"./assets/Script/module/Notification/Notification":10,"./assets/Script/module/Share/share":11,"./assets/Script/module/RankList/List":12,"./assets/Script/module/Music/AudioManager":13,"./assets/Script/module/Storage/Storage":14,"./assets/Script/module/GameStart/GameAppStart":15,"./assets/Script/module/Crypto/HttpUtil":16,"./assets/Script/module/Tool/GameTool":17,"./assets/Script/module/Config/GameConfig":18,"./assets/Script/module/RankList/ItemRender":19,"./assets/Script/module/Crypto/crypto-js.min":20},"path":"preview-scripts/__qc_index__.js"},{"deps":{},"path":"preview-scripts/assets/Script/Block.js"},{"deps":{},"path":"preview-scripts/assets/migration/use_v2.1-2.2.1_cc.Toggle_event.js"},{"deps":{},"path":"preview-scripts/assets/Script/GameManager.js"},{"deps":{},"path":"preview-scripts/assets/Script/GuideManager.js"},{"deps":{},"path":"preview-scripts/assets/Script/GameOver.js"},{"deps":{"./module/RankList/List":12},"path":"preview-scripts/assets/Script/RankManager.js"},{"deps":{},"path":"preview-scripts/assets/Script/GameScene.js"},{"deps":{"./module/Share/share":11},"path":"preview-scripts/assets/Script/Load.js"},{"deps":{},"path":"preview-scripts/assets/Script/DynamicAtlasManager.js"},{"deps":{},"path":"preview-scripts/assets/Script/module/Notification/Notification.js"},{"deps":{},"path":"preview-scripts/assets/Script/module/Share/share.js"},{"deps":{"./ItemRender":19},"path":"preview-scripts/assets/Script/module/RankList/List.js"},{"deps":{},"path":"preview-scripts/assets/Script/module/Music/AudioManager.js"},{"deps":{},"path":"preview-scripts/assets/Script/module/Storage/Storage.js"},{"deps":{"../Config/GameConfig":18,"../Crypto/HttpUtil":16,"../Music/AudioManager":13,"../Notification/Notification":10,"../Storage/Storage":14,"../Tool/GameTool":17},"path":"preview-scripts/assets/Script/module/GameStart/GameAppStart.js"},{"deps":{"./crypto-js.min.js":20},"path":"preview-scripts/assets/Script/module/Crypto/HttpUtil.js"},{"deps":{},"path":"preview-scripts/assets/Script/module/Tool/GameTool.js"},{"deps":{},"path":"preview-scripts/assets/Script/module/Config/GameConfig.js"},{"deps":{},"path":"preview-scripts/assets/Script/module/RankList/ItemRender.js"},{"deps":{},"path":"preview-scripts/assets/Script/module/Crypto/crypto-js.min.js"}];
var entries = ["preview-scripts/__qc_index__.js"];
var bundleScript = 'preview-scripts/__qc_bundle__.js';

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -130,7 +130,7 @@ var NewClass = /** @class */ (function (_super) {
.start();
};
NewClass.prototype.jumpFinishi = function () {
var url = "https://train.sparkus.cn/poster/game/";
var url = "https://train.sparkus.cn/poster/game/" + cc.fx.GameConfig.GM_INFO.scode + "?suc=1";
window.location.href = url;
};
//判断来源

File diff suppressed because one or more lines are too long

View File

@ -55,6 +55,7 @@ var GameConfig = /** @class */ (function () {
}
var jsonData = res.json;
self.GM_INFO = jsonData["data"];
self.setCode(self.getKey("scode"));
cc.fx.GameTool.getCustom(false);
if (!Authentication)
self.Authentication();
@ -71,6 +72,7 @@ var GameConfig = /** @class */ (function () {
currSeed: 200000,
gameId: "100010",
userId: 200139,
scode: "",
guide: true,
url: "https://api.sparkus.cn",
success: false,
@ -82,6 +84,7 @@ var GameConfig = /** @class */ (function () {
gameTime: 5,
igniteCount: 0,
};
this.setCode(this.getKey("scode"));
};
GameConfig.GM_INFO_SET = function (key, value) {
this.GM_INFO[key] = value;
@ -2609,6 +2612,17 @@ var GameConfig = /** @class */ (function () {
}
];
};
GameConfig.setCode = function (code) {
this.GM_INFO.scode = code;
};
GameConfig.getKey = function (key) {
var reg = new RegExp('(^|&)' + key + '=([^&]*)(&|$)', 'i');
var r = window.location.search.substr(1).match(reg);
if (r != null) {
return unescape(r[2]);
}
return "";
};
GameConfig.Authentication = function () {
cc.fx.GameTool.Authentication();
};

File diff suppressed because one or more lines are too long

View File

@ -16,6 +16,17 @@ var __extends = (this && this.__extends) || (function () {
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
var __assign = (this && this.__assign) || function () {
__assign = Object.assign || function(t) {
for (var s, i = 1, n = arguments.length; i < n; i++) {
s = arguments[i];
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
t[p] = s[p];
}
return t;
};
return __assign.apply(this, arguments);
};
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
@ -69,17 +80,6 @@ var HttpUtil = /** @class */ (function (_super) {
return _super !== null && _super.apply(this, arguments) || this;
}
HttpUtil_1 = HttpUtil;
HttpUtil.getShareInfo = function (shareUrl) {
return __awaiter(this, void 0, Promise, function () {
var time, url;
return __generator(this, function (_a) {
console.log("设置分享链接:", shareUrl);
time = Math.floor((new Date().getTime()) / 1000);
url = HttpUtil_1.apiSign("/api/share/cfg?gameId=" + config.gameId + "&time=" + time + "&url=" + shareUrl, {});
return [2 /*return*/, this.post(url, null, null)];
});
});
};
//排行榜
HttpUtil.rankData = function (type, callback, data) {
return __awaiter(this, void 0, Promise, function () {
@ -87,7 +87,7 @@ var HttpUtil = /** @class */ (function (_super) {
return __generator(this, function (_a) {
time = Math.floor((new Date().getTime()) / 1000);
url = HttpUtil_1.apiSign("/api/get/rank/data?gameId=" + config.gameId + "&dataType=" + type + "&time=" + time, data);
this.post(url, data, callback);
this.post(url, data, callback, 0);
return [2 /*return*/];
});
});
@ -97,7 +97,7 @@ var HttpUtil = /** @class */ (function (_super) {
var url;
return __generator(this, function (_a) {
url = '/log/collect/data';
this.post(url, data, callback);
this.post(url, data, callback, 3);
return [2 /*return*/];
});
});
@ -109,17 +109,19 @@ var HttpUtil = /** @class */ (function (_super) {
return __generator(this, function (_a) {
time = Math.floor((new Date().getTime()) / 1000);
url = HttpUtil_1.apiSign("/api/get/user/data?gameId=" + config.gameId + "&time=" + time, data);
this.post(url, data, callback);
this.post(url, data, callback, 0);
return [2 /*return*/];
});
});
};
HttpUtil.post = function (url, data, callback) {
HttpUtil.get = function (url, callback, count) {
return __awaiter(this, void 0, void 0, function () {
var response;
var repeat, response;
return __generator(this, function (_a) {
switch (_a.label) {
case 0: return [4 /*yield*/, this.fetchData(url, data, 'POST')];
case 0:
repeat = count ? count : 0;
return [4 /*yield*/, this.fetchData(url, null, 'GET', repeat)];
case 1:
response = _a.sent();
callback && callback(response);
@ -128,12 +130,14 @@ var HttpUtil = /** @class */ (function (_super) {
});
});
};
HttpUtil.get = function (url, callback) {
HttpUtil.post = function (url, data, callback, count) {
return __awaiter(this, void 0, void 0, function () {
var response;
var repeat, response;
return __generator(this, function (_a) {
switch (_a.label) {
case 0: return [4 /*yield*/, this.fetchData(url, null, 'GET')];
case 0:
repeat = count ? count : 0;
return [4 /*yield*/, this.fetchData(url, data, 'POST', repeat)];
case 1:
response = _a.sent();
callback && callback(response);
@ -142,9 +146,10 @@ var HttpUtil = /** @class */ (function (_super) {
});
});
};
HttpUtil.fetchData = function (url, data, method) {
HttpUtil.fetchData = function (url, data, method, repeat) {
return __awaiter(this, void 0, void 0, function () {
var fullUrl, headers, options, response, error_1;
var fullUrl, headers, options, response, error_1, timeOut;
var _this = this;
return __generator(this, function (_a) {
switch (_a.label) {
case 0:
@ -158,23 +163,58 @@ var HttpUtil = /** @class */ (function (_super) {
_a.label = 1;
case 1:
_a.trys.push([1, 4, , 5]);
return [4 /*yield*/, fetch(fullUrl, options)];
return [4 /*yield*/, this.fetchWithTimeout(fullUrl, options)];
case 2:
response = _a.sent();
if (!response.ok) {
throw new Error("HTTP error! status: " + response.status);
throw new Error("HTTP_______________error! status: " + response.status);
}
return [4 /*yield*/, response.json()];
case 3: return [2 /*return*/, _a.sent()];
case 4:
error_1 = _a.sent();
console.error('Fetch error:', error_1);
return [2 /*return*/, null];
console.error('Fetch_______________error:', error_1);
if (repeat > 0) {
repeat -= 1;
timeOut = (3 - repeat) * 5000;
setTimeout(function () { return __awaiter(_this, void 0, void 0, function () {
return __generator(this, function (_a) {
switch (_a.label) {
case 0: return [4 /*yield*/, this.fetchData(url, data, method, repeat)];
case 1:
response = _a.sent();
return [2 /*return*/];
}
});
}); }, timeOut);
}
else {
return [2 /*return*/, null];
}
return [3 /*break*/, 5];
case 5: return [2 /*return*/];
}
});
});
};
HttpUtil.fetchWithTimeout = function (resource, options) {
if (options === void 0) { options = {}; }
return __awaiter(this, void 0, void 0, function () {
var controller, id, response;
return __generator(this, function (_a) {
switch (_a.label) {
case 0:
controller = new AbortController();
id = setTimeout(function () { return controller.abort(); }, 5000);
return [4 /*yield*/, fetch(resource, __assign(__assign({}, options), { signal: controller.signal }))];
case 1:
response = _a.sent();
clearTimeout(id);
return [2 /*return*/, response];
}
});
});
};
/**
*
* @param url {string} 接口地址

File diff suppressed because one or more lines are too long

View File

@ -91,15 +91,17 @@ var WeChat = /** @class */ (function () {
console.log("分享好友成功回调");
}
});
wx.updateTimelineShareData({
title: '记忆力认知测评',
link: shareConfig.shareLine,
imgUrl: 'https://static.sparkus.cn/public/shennong.jpg',
success: function () {
// 设置成功
console.log("分享朋友圈成功回调");
}
});
setTimeout(function () {
wx.updateTimelineShareData({
title: '记忆力认知测评',
link: shareConfig.shareLine,
imgUrl: 'https://static.sparkus.cn/public/shennong.jpg',
success: function () {
// 设置成功
console.log("分享朋友圈成功回调");
}
});
}, 200);
});
};
WeChat.getSignature = function (url) {
@ -113,7 +115,7 @@ var WeChat = /** @class */ (function () {
return __generator(this, function (_a) {
time = Math.floor((new Date().getTime()) / 1000);
url = cc.fx.HttpUtil.apiSign("/api/share/cfg?gameId=" + shareConfig.gameId + "&time=" + time + "&url=" + shareUrl, {});
return [2 /*return*/, cc.fx.HttpUtil.get(url, callback)];
return [2 /*return*/, cc.fx.HttpUtil.get(url, callback, 0)];
});
});
};

File diff suppressed because one or more lines are too long

View File

@ -15,15 +15,22 @@ var GameTool = {
var name = "user_" + cc.fx.GameConfig.GM_INFO.gameId;
var data = JSON.parse(localStorage.getItem(name));
if (data == "undifend" || data == null || data == "") {
var urlNow = window.location.href;
if (!this.containsTrain(urlNow) || !this.isNumber(data.userId)) {
var url = "https://api.sparkus.cn/api/user/auth/login?domain=hui32579WdYPsgYq&callback=" + location.href;
window.location.href = url;
}
var url = "https://api.sparkus.cn/api/user/auth/login?domain=hui32579WdYPsgYq&callback=" +
encodeURIComponent(location.href);
console.log("链接没ID准备跳转", url);
window.location.href = url;
}
else {
cc.fx.StorageMessage.setStorage(name, data);
cc.fx.GameConfig.GM_INFO.userId = parseInt(data.userId);
if (!this.isNumber(data.userId)) {
var url = "https://api.sparkus.cn/api/user/auth/login?domain=hui32579WdYPsgYq&callback=" +
encodeURIComponent(location.href);
console.log("链接不合法", url);
window.location.href = url;
}
else {
cc.fx.StorageMessage.setStorage(name, data);
cc.fx.GameConfig.GM_INFO.userId = parseInt(data.userId);
}
}
},
isNumber: function (value) {
@ -48,6 +55,7 @@ var GameTool = {
var postData = {
"gameId": cc.fx.GameConfig.GM_INFO.gameId,
"userId": cc.fx.GameConfig.GM_INFO.userId,
"scode": cc.fx.GameConfig.GM_INFO.scode,
"matchId": matchId,
"data": data
};

File diff suppressed because one or more lines are too long