init
This commit is contained in:
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"ver": "1.0.27",
|
||||
"importer": "image",
|
||||
"imported": true,
|
||||
"uuid": "2f65490b-b7a4-48a1-8321-93f79967721e",
|
||||
"files": [
|
||||
".jpg",
|
||||
".json"
|
||||
],
|
||||
"subMetas": {
|
||||
"6c48a": {
|
||||
"importer": "texture",
|
||||
"uuid": "2f65490b-b7a4-48a1-8321-93f79967721e@6c48a",
|
||||
"displayName": "zhiyan_stage_bg",
|
||||
"id": "6c48a",
|
||||
"name": "texture",
|
||||
"userData": {
|
||||
"wrapModeS": "clamp-to-edge",
|
||||
"wrapModeT": "clamp-to-edge",
|
||||
"imageUuidOrDatabaseUri": "2f65490b-b7a4-48a1-8321-93f79967721e",
|
||||
"isUuid": true,
|
||||
"visible": false,
|
||||
"minfilter": "linear",
|
||||
"magfilter": "linear",
|
||||
"mipfilter": "none",
|
||||
"anisotropy": 0
|
||||
},
|
||||
"ver": "1.0.22",
|
||||
"imported": true,
|
||||
"files": [
|
||||
".json"
|
||||
],
|
||||
"subMetas": {}
|
||||
},
|
||||
"f9941": {
|
||||
"importer": "sprite-frame",
|
||||
"uuid": "2f65490b-b7a4-48a1-8321-93f79967721e@f9941",
|
||||
"displayName": "zhiyan_stage_bg",
|
||||
"id": "f9941",
|
||||
"name": "spriteFrame",
|
||||
"userData": {
|
||||
"trimType": "auto",
|
||||
"trimThreshold": 1,
|
||||
"rotated": false,
|
||||
"offsetX": 0,
|
||||
"offsetY": 0,
|
||||
"trimX": 0,
|
||||
"trimY": 0,
|
||||
"width": 996,
|
||||
"height": 1280,
|
||||
"rawWidth": 996,
|
||||
"rawHeight": 1280,
|
||||
"borderTop": 0,
|
||||
"borderBottom": 0,
|
||||
"borderLeft": 0,
|
||||
"borderRight": 0,
|
||||
"packable": true,
|
||||
"pixelsToUnit": 100,
|
||||
"pivotX": 0.5,
|
||||
"pivotY": 0.5,
|
||||
"meshType": 0,
|
||||
"vertices": {
|
||||
"rawPosition": [
|
||||
-498,
|
||||
-640,
|
||||
0,
|
||||
498,
|
||||
-640,
|
||||
0,
|
||||
-498,
|
||||
640,
|
||||
0,
|
||||
498,
|
||||
640,
|
||||
0
|
||||
],
|
||||
"indexes": [
|
||||
0,
|
||||
1,
|
||||
2,
|
||||
2,
|
||||
1,
|
||||
3
|
||||
],
|
||||
"uv": [
|
||||
0,
|
||||
1280,
|
||||
996,
|
||||
1280,
|
||||
0,
|
||||
0,
|
||||
996,
|
||||
0
|
||||
],
|
||||
"nuv": [
|
||||
0,
|
||||
0,
|
||||
1,
|
||||
0,
|
||||
0,
|
||||
1,
|
||||
1,
|
||||
1
|
||||
],
|
||||
"minPos": [
|
||||
-498,
|
||||
-640,
|
||||
0
|
||||
],
|
||||
"maxPos": [
|
||||
498,
|
||||
640,
|
||||
0
|
||||
]
|
||||
},
|
||||
"isUuid": true,
|
||||
"imageUuidOrDatabaseUri": "2f65490b-b7a4-48a1-8321-93f79967721e@6c48a",
|
||||
"atlasUuid": ""
|
||||
},
|
||||
"ver": "1.0.12",
|
||||
"imported": true,
|
||||
"files": [
|
||||
".json"
|
||||
],
|
||||
"subMetas": {}
|
||||
}
|
||||
},
|
||||
"userData": {
|
||||
"type": "sprite-frame",
|
||||
"hasAlpha": false,
|
||||
"fixAlphaTransparencyArtifacts": false,
|
||||
"redirect": "2f65490b-b7a4-48a1-8321-93f79967721e@6c48a"
|
||||
}
|
||||
}
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 104 KiB |
@@ -0,0 +1,361 @@
|
||||
{
|
||||
"__version__": "1.3.8",
|
||||
"log": {
|
||||
"level": 4
|
||||
},
|
||||
"common": {
|
||||
"polyfills": {
|
||||
"asyncFunctions": true
|
||||
},
|
||||
"buildPath": "project://build",
|
||||
"outputName": "wechatgame_kuai",
|
||||
"mainBundleCompressionType": "merge_dep",
|
||||
"platform": "wechatgame",
|
||||
"startScene": "16b0d021-6436-4bbc-ba5e-05ebe3e84ba4",
|
||||
"server": "https://hxzgame.vip.hnhxzkj.com/lzx/XiangQin/remFile.ks.1.0.4",
|
||||
"nativeCodeBundleMode": "asmjs",
|
||||
"md5Cache": true,
|
||||
"name": "XiangQin"
|
||||
},
|
||||
"BuildTaskManager": {
|
||||
"taskMap": {
|
||||
"1736231456475": {
|
||||
"type": "build",
|
||||
"id": "1736231456475",
|
||||
"progress": 1,
|
||||
"state": "success",
|
||||
"stage": "build",
|
||||
"message": "2025-3-19 18:59:55 build success in 16 s!",
|
||||
"detailMessage": "// ---- build task wechatgame:onAfterBuild ----\r",
|
||||
"options": {
|
||||
"name": "XiangQin",
|
||||
"server": "https://hxzgame.vip.hnhxzkj.com/lzx/XiangQin/remFile.wx.1.0.4",
|
||||
"platform": "wechatgame",
|
||||
"buildPath": "project://build",
|
||||
"debug": false,
|
||||
"md5Cache": true,
|
||||
"skipCompressTexture": false,
|
||||
"sourceMaps": false,
|
||||
"overwriteProjectSettings": {
|
||||
"macroConfig": {
|
||||
"cleanupImageCache": "on"
|
||||
},
|
||||
"includeModules": {
|
||||
"physics": "inherit-project-setting",
|
||||
"physics-2d": "inherit-project-setting",
|
||||
"gfx-webgl2": "off"
|
||||
}
|
||||
},
|
||||
"nativeCodeBundleMode": "asmjs",
|
||||
"polyfills": {
|
||||
"asyncFunctions": false
|
||||
},
|
||||
"experimentalEraseModules": false,
|
||||
"startSceneAssetBundle": false,
|
||||
"bundleConfigs": [],
|
||||
"useBuiltinServer": false,
|
||||
"md5CacheOptions": {
|
||||
"excludes": [],
|
||||
"includes": [],
|
||||
"replaceOnly": [],
|
||||
"handleTemplateMd5Link": true
|
||||
},
|
||||
"mainBundleIsRemote": false,
|
||||
"mainBundleCompressionType": "merge_dep",
|
||||
"useSplashScreen": true,
|
||||
"bundleCommonChunk": false,
|
||||
"packAutoAtlas": true,
|
||||
"startScene": "16b0d021-6436-4bbc-ba5e-05ebe3e84ba4",
|
||||
"outputName": "wechatgame",
|
||||
"taskName": "wechatgame",
|
||||
"scenes": [
|
||||
{
|
||||
"url": "db://assets/Scenes/MainScene.scene",
|
||||
"uuid": "1a23cd3e-e487-4fd1-a415-346c2087464d"
|
||||
},
|
||||
{
|
||||
"url": "db://assets/Scenes/PreloadScene.scene",
|
||||
"uuid": "16b0d021-6436-4bbc-ba5e-05ebe3e84ba4"
|
||||
}
|
||||
],
|
||||
"wasmCompressionMode": false,
|
||||
"packages": {},
|
||||
"__version__": "1.3.8",
|
||||
"logDest": "project://temp/builder/log/wechatgame2025-1-7 14-30.log"
|
||||
},
|
||||
"time": "2025-3-19 18:59:38",
|
||||
"dirty": false
|
||||
},
|
||||
"1736573831185": {
|
||||
"type": "build",
|
||||
"id": "1736573831185",
|
||||
"progress": 1,
|
||||
"state": "success",
|
||||
"stage": "build",
|
||||
"message": "2025-3-19 18:54:08 build success in 16 s!",
|
||||
"detailMessage": "builder:build-project-total (15923ms)\r",
|
||||
"options": {
|
||||
"name": "XiangQin",
|
||||
"server": "",
|
||||
"platform": "web-mobile",
|
||||
"buildPath": "project://build",
|
||||
"debug": false,
|
||||
"md5Cache": false,
|
||||
"skipCompressTexture": false,
|
||||
"sourceMaps": false,
|
||||
"overwriteProjectSettings": {
|
||||
"includeModules": {
|
||||
"gfx-webgl2": "on",
|
||||
"physics": "inherit-project-setting",
|
||||
"physics-2d": "inherit-project-setting"
|
||||
},
|
||||
"macroConfig": {
|
||||
"cleanupImageCache": "inherit-project-setting"
|
||||
}
|
||||
},
|
||||
"nativeCodeBundleMode": "both",
|
||||
"polyfills": {
|
||||
"asyncFunctions": true
|
||||
},
|
||||
"experimentalEraseModules": false,
|
||||
"startSceneAssetBundle": false,
|
||||
"bundleConfigs": [],
|
||||
"useBuiltinServer": false,
|
||||
"md5CacheOptions": {
|
||||
"excludes": [],
|
||||
"includes": [],
|
||||
"replaceOnly": [],
|
||||
"handleTemplateMd5Link": true
|
||||
},
|
||||
"mainBundleIsRemote": false,
|
||||
"mainBundleCompressionType": "merge_dep",
|
||||
"useSplashScreen": true,
|
||||
"bundleCommonChunk": false,
|
||||
"packAutoAtlas": true,
|
||||
"startScene": "16b0d021-6436-4bbc-ba5e-05ebe3e84ba4",
|
||||
"outputName": "web-mobile",
|
||||
"taskName": "web-mobile",
|
||||
"scenes": [
|
||||
{
|
||||
"url": "db://assets/Scenes/MainScene.scene",
|
||||
"uuid": "1a23cd3e-e487-4fd1-a415-346c2087464d"
|
||||
},
|
||||
{
|
||||
"url": "db://assets/Scenes/PreloadScene.scene",
|
||||
"uuid": "16b0d021-6436-4bbc-ba5e-05ebe3e84ba4"
|
||||
}
|
||||
],
|
||||
"wasmCompressionMode": false,
|
||||
"packages": {},
|
||||
"__version__": "1.3.8",
|
||||
"buildMode": "normal",
|
||||
"logDest": "project://temp/builder/log/web-mobile2025-1-11 13-37.log"
|
||||
},
|
||||
"time": "2025-3-19 18:53:52",
|
||||
"dirty": false
|
||||
},
|
||||
"1736821502634": {
|
||||
"type": "build",
|
||||
"id": "1736821502634",
|
||||
"progress": 1,
|
||||
"state": "success",
|
||||
"stage": "build",
|
||||
"message": "2025-2-7 09:01:29 build success in 13 s!",
|
||||
"detailMessage": "// ---- build task cocos-service:onAfterCompressSettings ----\r",
|
||||
"options": {
|
||||
"name": "XiangQin",
|
||||
"server": "",
|
||||
"platform": "web-mobile",
|
||||
"buildPath": "project://build",
|
||||
"debug": false,
|
||||
"md5Cache": false,
|
||||
"skipCompressTexture": false,
|
||||
"sourceMaps": false,
|
||||
"overwriteProjectSettings": {
|
||||
"includeModules": {
|
||||
"gfx-webgl2": "on",
|
||||
"physics": "inherit-project-setting",
|
||||
"physics-2d": "inherit-project-setting"
|
||||
},
|
||||
"macroConfig": {
|
||||
"cleanupImageCache": "inherit-project-setting"
|
||||
}
|
||||
},
|
||||
"nativeCodeBundleMode": "both",
|
||||
"polyfills": {
|
||||
"asyncFunctions": true
|
||||
},
|
||||
"experimentalEraseModules": false,
|
||||
"startSceneAssetBundle": false,
|
||||
"bundleConfigs": [],
|
||||
"useBuiltinServer": false,
|
||||
"md5CacheOptions": {
|
||||
"excludes": [],
|
||||
"includes": [],
|
||||
"replaceOnly": [],
|
||||
"handleTemplateMd5Link": true
|
||||
},
|
||||
"mainBundleIsRemote": false,
|
||||
"mainBundleCompressionType": "merge_dep",
|
||||
"useSplashScreen": true,
|
||||
"bundleCommonChunk": false,
|
||||
"packAutoAtlas": true,
|
||||
"startScene": "16b0d021-6436-4bbc-ba5e-05ebe3e84ba4",
|
||||
"outputName": "web-mobile-console",
|
||||
"taskName": "web-mobile-console",
|
||||
"scenes": [
|
||||
{
|
||||
"url": "db://assets/Scenes/MainScene.scene",
|
||||
"uuid": "1a23cd3e-e487-4fd1-a415-346c2087464d"
|
||||
},
|
||||
{
|
||||
"url": "db://assets/Scenes/PreloadScene.scene",
|
||||
"uuid": "16b0d021-6436-4bbc-ba5e-05ebe3e84ba4"
|
||||
}
|
||||
],
|
||||
"wasmCompressionMode": false,
|
||||
"packages": {},
|
||||
"__version__": "1.3.8",
|
||||
"buildMode": "normal",
|
||||
"logDest": "project://temp/builder/log/web-mobile2025-1-14 10-25.log"
|
||||
},
|
||||
"time": "2025-2-7 09:01:15",
|
||||
"dirty": false
|
||||
},
|
||||
"1736838627770": {
|
||||
"type": "build",
|
||||
"id": "1736838627770",
|
||||
"progress": 1,
|
||||
"state": "success",
|
||||
"stage": "build",
|
||||
"message": "2025-2-28 10:45:42 build success in 22 s!",
|
||||
"detailMessage": "builder:build-project-total (22353ms)\r",
|
||||
"options": {
|
||||
"name": "XiangQin",
|
||||
"server": "https://hxzgame.vip.hnhxzkj.com/lzx/XiangQin/remFile.bd.1.0.0",
|
||||
"platform": "bytedance-mini-game",
|
||||
"buildPath": "project://build",
|
||||
"debug": false,
|
||||
"md5Cache": false,
|
||||
"skipCompressTexture": false,
|
||||
"sourceMaps": false,
|
||||
"overwriteProjectSettings": {
|
||||
"macroConfig": {
|
||||
"cleanupImageCache": "inherit-project-setting"
|
||||
},
|
||||
"includeModules": {
|
||||
"physics": "inherit-project-setting",
|
||||
"physics-2d": "inherit-project-setting",
|
||||
"gfx-webgl2": "off"
|
||||
}
|
||||
},
|
||||
"nativeCodeBundleMode": "both",
|
||||
"polyfills": {
|
||||
"asyncFunctions": false
|
||||
},
|
||||
"experimentalEraseModules": false,
|
||||
"startSceneAssetBundle": false,
|
||||
"bundleConfigs": [],
|
||||
"useBuiltinServer": false,
|
||||
"md5CacheOptions": {
|
||||
"excludes": [],
|
||||
"includes": [],
|
||||
"replaceOnly": [],
|
||||
"handleTemplateMd5Link": true
|
||||
},
|
||||
"mainBundleIsRemote": false,
|
||||
"mainBundleCompressionType": "merge_dep",
|
||||
"useSplashScreen": true,
|
||||
"bundleCommonChunk": false,
|
||||
"packAutoAtlas": true,
|
||||
"startScene": "16b0d021-6436-4bbc-ba5e-05ebe3e84ba4",
|
||||
"outputName": "bytedance-mini-game",
|
||||
"taskName": "bytedance-mini-game",
|
||||
"scenes": [
|
||||
{
|
||||
"url": "db://assets/Scenes/MainScene.scene",
|
||||
"uuid": "1a23cd3e-e487-4fd1-a415-346c2087464d"
|
||||
},
|
||||
{
|
||||
"url": "db://assets/Scenes/PreloadScene.scene",
|
||||
"uuid": "16b0d021-6436-4bbc-ba5e-05ebe3e84ba4"
|
||||
}
|
||||
],
|
||||
"wasmCompressionMode": false,
|
||||
"packages": {},
|
||||
"__version__": "1.3.8",
|
||||
"logDest": "project://temp/builder/log/bytedance-mini-game2025-1-14 15-10.log"
|
||||
},
|
||||
"time": "2025-2-28 10:45:19",
|
||||
"dirty": false
|
||||
},
|
||||
"1736905523241": {
|
||||
"type": "build",
|
||||
"id": "1736905523241",
|
||||
"progress": 1,
|
||||
"state": "success",
|
||||
"stage": "build",
|
||||
"message": "2025-3-13 15:59:07 build success in 16 s!",
|
||||
"detailMessage": "// ---- build task wechatgame:onAfterCopyBuildTemplate ----\r",
|
||||
"options": {
|
||||
"name": "XiangQin",
|
||||
"server": "https://hxzgame.vip.hnhxzkj.com/lzx/XiangQin/remFile.ks.1.0.4",
|
||||
"platform": "wechatgame",
|
||||
"buildPath": "project://build",
|
||||
"debug": false,
|
||||
"md5Cache": true,
|
||||
"skipCompressTexture": false,
|
||||
"sourceMaps": false,
|
||||
"overwriteProjectSettings": {
|
||||
"macroConfig": {
|
||||
"cleanupImageCache": "on"
|
||||
},
|
||||
"includeModules": {
|
||||
"physics": "inherit-project-setting",
|
||||
"physics-2d": "inherit-project-setting",
|
||||
"gfx-webgl2": "off"
|
||||
}
|
||||
},
|
||||
"nativeCodeBundleMode": "asmjs",
|
||||
"polyfills": {
|
||||
"asyncFunctions": false
|
||||
},
|
||||
"experimentalEraseModules": false,
|
||||
"startSceneAssetBundle": false,
|
||||
"bundleConfigs": [],
|
||||
"useBuiltinServer": false,
|
||||
"md5CacheOptions": {
|
||||
"excludes": [],
|
||||
"includes": [],
|
||||
"replaceOnly": [],
|
||||
"handleTemplateMd5Link": true
|
||||
},
|
||||
"mainBundleIsRemote": false,
|
||||
"mainBundleCompressionType": "merge_dep",
|
||||
"useSplashScreen": true,
|
||||
"bundleCommonChunk": false,
|
||||
"packAutoAtlas": true,
|
||||
"startScene": "16b0d021-6436-4bbc-ba5e-05ebe3e84ba4",
|
||||
"outputName": "wechatgame_kuai",
|
||||
"taskName": "wechatgame_kuai",
|
||||
"scenes": [
|
||||
{
|
||||
"url": "db://assets/Scenes/MainScene.scene",
|
||||
"uuid": "1a23cd3e-e487-4fd1-a415-346c2087464d"
|
||||
},
|
||||
{
|
||||
"url": "db://assets/Scenes/PreloadScene.scene",
|
||||
"uuid": "16b0d021-6436-4bbc-ba5e-05ebe3e84ba4"
|
||||
}
|
||||
],
|
||||
"wasmCompressionMode": false,
|
||||
"packages": {},
|
||||
"__version__": "1.3.8",
|
||||
"logDest": "project://temp/builder/log/wechatgame2025-1-15 09-45.log"
|
||||
},
|
||||
"time": "2025-3-13 15:58:51",
|
||||
"dirty": false
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,72 @@
|
||||
/**长连接*/
|
||||
export default class SocketUnit {
|
||||
private socket: WebSocket | null = null;
|
||||
private isConnected: boolean = false;
|
||||
|
||||
private dataReceivedCallback: (data: any) => void = () => {};
|
||||
|
||||
// 连接到服务器
|
||||
public connect(url: string): void {
|
||||
if (this.isConnected) {
|
||||
console.log("SocketUnit: Already connected.");
|
||||
return;
|
||||
}
|
||||
|
||||
this.socket = new WebSocket(url);
|
||||
console.log("SocketUnit: Connecting to -> " + url);
|
||||
|
||||
// 连接成功
|
||||
this.socket.onopen = () => {
|
||||
this.isConnected = true;
|
||||
console.log("SocketUnit: Connection succ.");
|
||||
};
|
||||
|
||||
// 接收到消息
|
||||
this.socket.onmessage = (event) => {
|
||||
// console.log("SocketUnit: Received data: ", event);
|
||||
if (this.dataReceivedCallback) {
|
||||
this.dataReceivedCallback(event);
|
||||
}
|
||||
};
|
||||
|
||||
// 连接关闭
|
||||
this.socket.onclose = () => {
|
||||
this.isConnected = false;
|
||||
console.log("SocketUnit: Connection closed.");
|
||||
};
|
||||
|
||||
// 发生错误
|
||||
this.socket.onerror = (error) => {
|
||||
console.error("SocketUnit: WebSocket error:", error);
|
||||
this.isConnected = false;
|
||||
};
|
||||
}
|
||||
|
||||
// 断开连接
|
||||
public disconnect(): void {
|
||||
if (this.socket && this.isConnected) {
|
||||
this.socket.close();
|
||||
}
|
||||
}
|
||||
|
||||
// 发送数据
|
||||
public sendData(data: string): void {
|
||||
// console.log("SocketUnit: sendData", data);
|
||||
if (this.socket && this.isConnected) {
|
||||
this.socket.send(data);
|
||||
} else {
|
||||
console.error("SocketUnit: Socket is not connected.");
|
||||
}
|
||||
}
|
||||
|
||||
// 设置数据接收回调
|
||||
public onDataReceived(callback: (data: string) => void): void {
|
||||
this.dataReceivedCallback = callback;
|
||||
}
|
||||
|
||||
// 获取连接状态
|
||||
public get isConnectedStatus(): boolean {
|
||||
return this.isConnected;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"ver": "1.0.27",
|
||||
"importer": "image",
|
||||
"imported": true,
|
||||
"uuid": "2b09c105-ef2b-47a9-92f0-cc87f17cb163",
|
||||
"files": [
|
||||
".json",
|
||||
".png"
|
||||
],
|
||||
"subMetas": {
|
||||
"6c48a": {
|
||||
"importer": "texture",
|
||||
"uuid": "2b09c105-ef2b-47a9-92f0-cc87f17cb163@6c48a",
|
||||
"displayName": "joy_shy",
|
||||
"id": "6c48a",
|
||||
"name": "texture",
|
||||
"userData": {
|
||||
"wrapModeS": "clamp-to-edge",
|
||||
"wrapModeT": "clamp-to-edge",
|
||||
"imageUuidOrDatabaseUri": "2b09c105-ef2b-47a9-92f0-cc87f17cb163",
|
||||
"isUuid": true,
|
||||
"visible": false,
|
||||
"minfilter": "linear",
|
||||
"magfilter": "linear",
|
||||
"mipfilter": "none",
|
||||
"anisotropy": 0
|
||||
},
|
||||
"ver": "1.0.22",
|
||||
"imported": true,
|
||||
"files": [
|
||||
".json"
|
||||
],
|
||||
"subMetas": {}
|
||||
},
|
||||
"f9941": {
|
||||
"importer": "sprite-frame",
|
||||
"uuid": "2b09c105-ef2b-47a9-92f0-cc87f17cb163@f9941",
|
||||
"displayName": "joy_shy",
|
||||
"id": "f9941",
|
||||
"name": "spriteFrame",
|
||||
"userData": {
|
||||
"trimType": "auto",
|
||||
"trimThreshold": 1,
|
||||
"rotated": false,
|
||||
"offsetX": 10,
|
||||
"offsetY": -4.5,
|
||||
"trimX": 62,
|
||||
"trimY": 9,
|
||||
"width": 821,
|
||||
"height": 1180,
|
||||
"rawWidth": 925,
|
||||
"rawHeight": 1189,
|
||||
"borderTop": 0,
|
||||
"borderBottom": 0,
|
||||
"borderLeft": 0,
|
||||
"borderRight": 0,
|
||||
"packable": true,
|
||||
"pixelsToUnit": 100,
|
||||
"pivotX": 0.5,
|
||||
"pivotY": 0.5,
|
||||
"meshType": 0,
|
||||
"vertices": {
|
||||
"rawPosition": [
|
||||
-410.5,
|
||||
-590,
|
||||
0,
|
||||
410.5,
|
||||
-590,
|
||||
0,
|
||||
-410.5,
|
||||
590,
|
||||
0,
|
||||
410.5,
|
||||
590,
|
||||
0
|
||||
],
|
||||
"indexes": [
|
||||
0,
|
||||
1,
|
||||
2,
|
||||
2,
|
||||
1,
|
||||
3
|
||||
],
|
||||
"uv": [
|
||||
62,
|
||||
1180,
|
||||
883,
|
||||
1180,
|
||||
62,
|
||||
0,
|
||||
883,
|
||||
0
|
||||
],
|
||||
"nuv": [
|
||||
0.06702702702702702,
|
||||
0,
|
||||
0.9545945945945946,
|
||||
0,
|
||||
0.06702702702702702,
|
||||
0.992430613961312,
|
||||
0.9545945945945946,
|
||||
0.992430613961312
|
||||
],
|
||||
"minPos": [
|
||||
-410.5,
|
||||
-590,
|
||||
0
|
||||
],
|
||||
"maxPos": [
|
||||
410.5,
|
||||
590,
|
||||
0
|
||||
]
|
||||
},
|
||||
"isUuid": true,
|
||||
"imageUuidOrDatabaseUri": "2b09c105-ef2b-47a9-92f0-cc87f17cb163@6c48a",
|
||||
"atlasUuid": ""
|
||||
},
|
||||
"ver": "1.0.12",
|
||||
"imported": true,
|
||||
"files": [
|
||||
".json"
|
||||
],
|
||||
"subMetas": {}
|
||||
}
|
||||
},
|
||||
"userData": {
|
||||
"type": "sprite-frame",
|
||||
"hasAlpha": true,
|
||||
"fixAlphaTransparencyArtifacts": false,
|
||||
"redirect": "2b09c105-ef2b-47a9-92f0-cc87f17cb163@6c48a"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"ver": "1.0.27",
|
||||
"importer": "image",
|
||||
"imported": true,
|
||||
"uuid": "d04eb3e9-2372-410d-80ec-2fb91fb08a7b",
|
||||
"files": [
|
||||
".jpg",
|
||||
".json"
|
||||
],
|
||||
"subMetas": {
|
||||
"6c48a": {
|
||||
"importer": "texture",
|
||||
"uuid": "d04eb3e9-2372-410d-80ec-2fb91fb08a7b@6c48a",
|
||||
"displayName": "greta_0_cg",
|
||||
"id": "6c48a",
|
||||
"name": "texture",
|
||||
"userData": {
|
||||
"wrapModeS": "clamp-to-edge",
|
||||
"wrapModeT": "clamp-to-edge",
|
||||
"imageUuidOrDatabaseUri": "d04eb3e9-2372-410d-80ec-2fb91fb08a7b",
|
||||
"isUuid": true,
|
||||
"visible": false,
|
||||
"minfilter": "linear",
|
||||
"magfilter": "linear",
|
||||
"mipfilter": "none",
|
||||
"anisotropy": 0
|
||||
},
|
||||
"ver": "1.0.22",
|
||||
"imported": true,
|
||||
"files": [
|
||||
".json"
|
||||
],
|
||||
"subMetas": {}
|
||||
},
|
||||
"f9941": {
|
||||
"importer": "sprite-frame",
|
||||
"uuid": "d04eb3e9-2372-410d-80ec-2fb91fb08a7b@f9941",
|
||||
"displayName": "greta_0_cg",
|
||||
"id": "f9941",
|
||||
"name": "spriteFrame",
|
||||
"userData": {
|
||||
"trimType": "auto",
|
||||
"trimThreshold": 1,
|
||||
"rotated": false,
|
||||
"offsetX": 0,
|
||||
"offsetY": 0,
|
||||
"trimX": 0,
|
||||
"trimY": 0,
|
||||
"width": 996,
|
||||
"height": 1280,
|
||||
"rawWidth": 996,
|
||||
"rawHeight": 1280,
|
||||
"borderTop": 0,
|
||||
"borderBottom": 0,
|
||||
"borderLeft": 0,
|
||||
"borderRight": 0,
|
||||
"packable": true,
|
||||
"pixelsToUnit": 100,
|
||||
"pivotX": 0.5,
|
||||
"pivotY": 0.5,
|
||||
"meshType": 0,
|
||||
"vertices": {
|
||||
"rawPosition": [
|
||||
-498,
|
||||
-640,
|
||||
0,
|
||||
498,
|
||||
-640,
|
||||
0,
|
||||
-498,
|
||||
640,
|
||||
0,
|
||||
498,
|
||||
640,
|
||||
0
|
||||
],
|
||||
"indexes": [
|
||||
0,
|
||||
1,
|
||||
2,
|
||||
2,
|
||||
1,
|
||||
3
|
||||
],
|
||||
"uv": [
|
||||
0,
|
||||
1280,
|
||||
996,
|
||||
1280,
|
||||
0,
|
||||
0,
|
||||
996,
|
||||
0
|
||||
],
|
||||
"nuv": [
|
||||
0,
|
||||
0,
|
||||
1,
|
||||
0,
|
||||
0,
|
||||
1,
|
||||
1,
|
||||
1
|
||||
],
|
||||
"minPos": [
|
||||
-498,
|
||||
-640,
|
||||
0
|
||||
],
|
||||
"maxPos": [
|
||||
498,
|
||||
640,
|
||||
0
|
||||
]
|
||||
},
|
||||
"isUuid": true,
|
||||
"imageUuidOrDatabaseUri": "d04eb3e9-2372-410d-80ec-2fb91fb08a7b@6c48a",
|
||||
"atlasUuid": ""
|
||||
},
|
||||
"ver": "1.0.12",
|
||||
"imported": true,
|
||||
"files": [
|
||||
".json"
|
||||
],
|
||||
"subMetas": {}
|
||||
}
|
||||
},
|
||||
"userData": {
|
||||
"type": "sprite-frame",
|
||||
"hasAlpha": false,
|
||||
"fixAlphaTransparencyArtifacts": false,
|
||||
"redirect": "d04eb3e9-2372-410d-80ec-2fb91fb08a7b@6c48a"
|
||||
}
|
||||
}
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 624 KiB |
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"ver": "1.0.27",
|
||||
"importer": "image",
|
||||
"imported": true,
|
||||
"uuid": "fec3659a-a2fd-4293-bfb2-0b87091a34dc",
|
||||
"files": [
|
||||
".jpg",
|
||||
".json"
|
||||
],
|
||||
"subMetas": {
|
||||
"6c48a": {
|
||||
"importer": "texture",
|
||||
"uuid": "fec3659a-a2fd-4293-bfb2-0b87091a34dc@6c48a",
|
||||
"displayName": "gisela_stage_bg",
|
||||
"id": "6c48a",
|
||||
"name": "texture",
|
||||
"userData": {
|
||||
"wrapModeS": "clamp-to-edge",
|
||||
"wrapModeT": "clamp-to-edge",
|
||||
"imageUuidOrDatabaseUri": "fec3659a-a2fd-4293-bfb2-0b87091a34dc",
|
||||
"isUuid": true,
|
||||
"visible": false,
|
||||
"minfilter": "linear",
|
||||
"magfilter": "linear",
|
||||
"mipfilter": "none",
|
||||
"anisotropy": 0
|
||||
},
|
||||
"ver": "1.0.22",
|
||||
"imported": true,
|
||||
"files": [
|
||||
".json"
|
||||
],
|
||||
"subMetas": {}
|
||||
},
|
||||
"f9941": {
|
||||
"importer": "sprite-frame",
|
||||
"uuid": "fec3659a-a2fd-4293-bfb2-0b87091a34dc@f9941",
|
||||
"displayName": "gisela_stage_bg",
|
||||
"id": "f9941",
|
||||
"name": "spriteFrame",
|
||||
"userData": {
|
||||
"trimType": "auto",
|
||||
"trimThreshold": 1,
|
||||
"rotated": false,
|
||||
"offsetX": 0,
|
||||
"offsetY": 0,
|
||||
"trimX": 0,
|
||||
"trimY": 0,
|
||||
"width": 996,
|
||||
"height": 1280,
|
||||
"rawWidth": 996,
|
||||
"rawHeight": 1280,
|
||||
"borderTop": 0,
|
||||
"borderBottom": 0,
|
||||
"borderLeft": 0,
|
||||
"borderRight": 0,
|
||||
"packable": true,
|
||||
"pixelsToUnit": 100,
|
||||
"pivotX": 0.5,
|
||||
"pivotY": 0.5,
|
||||
"meshType": 0,
|
||||
"vertices": {
|
||||
"rawPosition": [
|
||||
-498,
|
||||
-640,
|
||||
0,
|
||||
498,
|
||||
-640,
|
||||
0,
|
||||
-498,
|
||||
640,
|
||||
0,
|
||||
498,
|
||||
640,
|
||||
0
|
||||
],
|
||||
"indexes": [
|
||||
0,
|
||||
1,
|
||||
2,
|
||||
2,
|
||||
1,
|
||||
3
|
||||
],
|
||||
"uv": [
|
||||
0,
|
||||
1280,
|
||||
996,
|
||||
1280,
|
||||
0,
|
||||
0,
|
||||
996,
|
||||
0
|
||||
],
|
||||
"nuv": [
|
||||
0,
|
||||
0,
|
||||
1,
|
||||
0,
|
||||
0,
|
||||
1,
|
||||
1,
|
||||
1
|
||||
],
|
||||
"minPos": [
|
||||
-498,
|
||||
-640,
|
||||
0
|
||||
],
|
||||
"maxPos": [
|
||||
498,
|
||||
640,
|
||||
0
|
||||
]
|
||||
},
|
||||
"isUuid": true,
|
||||
"imageUuidOrDatabaseUri": "fec3659a-a2fd-4293-bfb2-0b87091a34dc@6c48a",
|
||||
"atlasUuid": ""
|
||||
},
|
||||
"ver": "1.0.12",
|
||||
"imported": true,
|
||||
"files": [
|
||||
".json"
|
||||
],
|
||||
"subMetas": {}
|
||||
}
|
||||
},
|
||||
"userData": {
|
||||
"type": "sprite-frame",
|
||||
"hasAlpha": false,
|
||||
"fixAlphaTransparencyArtifacts": false,
|
||||
"redirect": "fec3659a-a2fd-4293-bfb2-0b87091a34dc@6c48a"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"ver": "1.0.27",
|
||||
"importer": "image",
|
||||
"imported": true,
|
||||
"uuid": "573ac856-4952-4541-a134-4a6f19ffd382",
|
||||
"files": [
|
||||
".json",
|
||||
".png"
|
||||
],
|
||||
"subMetas": {
|
||||
"6c48a": {
|
||||
"importer": "texture",
|
||||
"uuid": "573ac856-4952-4541-a134-4a6f19ffd382@6c48a",
|
||||
"displayName": "kukla_avatar",
|
||||
"id": "6c48a",
|
||||
"name": "texture",
|
||||
"userData": {
|
||||
"wrapModeS": "clamp-to-edge",
|
||||
"wrapModeT": "clamp-to-edge",
|
||||
"imageUuidOrDatabaseUri": "573ac856-4952-4541-a134-4a6f19ffd382",
|
||||
"isUuid": true,
|
||||
"visible": false,
|
||||
"minfilter": "linear",
|
||||
"magfilter": "linear",
|
||||
"mipfilter": "none",
|
||||
"anisotropy": 0
|
||||
},
|
||||
"ver": "1.0.22",
|
||||
"imported": true,
|
||||
"files": [
|
||||
".json"
|
||||
],
|
||||
"subMetas": {}
|
||||
},
|
||||
"f9941": {
|
||||
"importer": "sprite-frame",
|
||||
"uuid": "573ac856-4952-4541-a134-4a6f19ffd382@f9941",
|
||||
"displayName": "kukla_avatar",
|
||||
"id": "f9941",
|
||||
"name": "spriteFrame",
|
||||
"userData": {
|
||||
"trimType": "auto",
|
||||
"trimThreshold": 1,
|
||||
"rotated": false,
|
||||
"offsetX": 0,
|
||||
"offsetY": 0,
|
||||
"trimX": 0,
|
||||
"trimY": 0,
|
||||
"width": 80,
|
||||
"height": 80,
|
||||
"rawWidth": 80,
|
||||
"rawHeight": 80,
|
||||
"borderTop": 0,
|
||||
"borderBottom": 0,
|
||||
"borderLeft": 0,
|
||||
"borderRight": 0,
|
||||
"packable": true,
|
||||
"pixelsToUnit": 100,
|
||||
"pivotX": 0.5,
|
||||
"pivotY": 0.5,
|
||||
"meshType": 0,
|
||||
"vertices": {
|
||||
"rawPosition": [
|
||||
-40,
|
||||
-40,
|
||||
0,
|
||||
40,
|
||||
-40,
|
||||
0,
|
||||
-40,
|
||||
40,
|
||||
0,
|
||||
40,
|
||||
40,
|
||||
0
|
||||
],
|
||||
"indexes": [
|
||||
0,
|
||||
1,
|
||||
2,
|
||||
2,
|
||||
1,
|
||||
3
|
||||
],
|
||||
"uv": [
|
||||
0,
|
||||
80,
|
||||
80,
|
||||
80,
|
||||
0,
|
||||
0,
|
||||
80,
|
||||
0
|
||||
],
|
||||
"nuv": [
|
||||
0,
|
||||
0,
|
||||
1,
|
||||
0,
|
||||
0,
|
||||
1,
|
||||
1,
|
||||
1
|
||||
],
|
||||
"minPos": [
|
||||
-40,
|
||||
-40,
|
||||
0
|
||||
],
|
||||
"maxPos": [
|
||||
40,
|
||||
40,
|
||||
0
|
||||
]
|
||||
},
|
||||
"isUuid": true,
|
||||
"imageUuidOrDatabaseUri": "573ac856-4952-4541-a134-4a6f19ffd382@6c48a",
|
||||
"atlasUuid": ""
|
||||
},
|
||||
"ver": "1.0.12",
|
||||
"imported": true,
|
||||
"files": [
|
||||
".json"
|
||||
],
|
||||
"subMetas": {}
|
||||
}
|
||||
},
|
||||
"userData": {
|
||||
"type": "sprite-frame",
|
||||
"hasAlpha": true,
|
||||
"fixAlphaTransparencyArtifacts": false,
|
||||
"redirect": "573ac856-4952-4541-a134-4a6f19ffd382@6c48a"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,235 @@
|
||||
|
||||
/**
|
||||
* 公共配置文件
|
||||
*/
|
||||
|
||||
export const G_GlobalNode: string = '__GLobal_Node';
|
||||
|
||||
export namespace CommonConfig {
|
||||
//本地保存
|
||||
export enum StorageConfigUtil {
|
||||
BaseData = 'li_' + 1000, // 登录相关
|
||||
Channel = 2000, //渠道相关
|
||||
}
|
||||
export enum StorageConfig {
|
||||
SETTING_SHAKEON = StorageConfigUtil.BaseData + 1,
|
||||
SETTING_MUSIC = StorageConfigUtil.BaseData + 2,
|
||||
SETTING_SOUND = StorageConfigUtil.BaseData + 3,
|
||||
GAME_CITY = StorageConfigUtil.BaseData + 4, //所在省
|
||||
GAME_RANK_CITY = StorageConfigUtil.BaseData + 5, //省排行数据 AI
|
||||
GAME_RANK_USER = StorageConfigUtil.BaseData + 6, //玩家排行数据 AI
|
||||
GAME_RANK_CDTIME = StorageConfigUtil.BaseData + 7, //上次排行数据刷新时间戳 AI
|
||||
GAME_SCORE = StorageConfigUtil.BaseData + 8, //玩家积分
|
||||
GAME_SKIN_ID = StorageConfigUtil.BaseData + 9, //当前选择的皮肤id
|
||||
GAME_PASSLV = StorageConfigUtil.BaseData + 10, //已完成关卡
|
||||
DAILYCHALLENGE_PASSLV = StorageConfigUtil.BaseData + 11, //已完成每日挑战关卡
|
||||
TOOL_KAIKONG = StorageConfigUtil.BaseData + 12, //开孔工具使用过
|
||||
TOOL_RENYIZHI = StorageConfigUtil.BaseData + 13, //任意指工具使用过
|
||||
TOOL_RENYIGUAN = StorageConfigUtil.BaseData + 14, //任意罐工具使用过
|
||||
DD_REGISTTIME = StorageConfigUtil.BaseData + 15, //注册时间字符串
|
||||
DD_LEVELOPER = StorageConfigUtil.BaseData + 16, //进入关卡且首次进度>0时(或第一次操作)
|
||||
GUIDE_MAIN = StorageConfigUtil.BaseData + 17, //主界面引导是否完成
|
||||
GUIDE_TALK = StorageConfigUtil.BaseData + 18, //聊天界面引导是否完成
|
||||
|
||||
DOUYIN_SIDEBAR = StorageConfigUtil.Channel + 1, //抖音渠道侧边栏奖励是否领取
|
||||
}
|
||||
|
||||
|
||||
//UI层级
|
||||
export enum UILayerGroup {
|
||||
Layer_ground = 0,
|
||||
Layer_ui1 = 1,
|
||||
Layer_ui2 = 2,
|
||||
Layer_dialog = 3,
|
||||
Layer_tips = 4,
|
||||
Layer_top = 5,
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**关卡配置信息 */
|
||||
export interface I_LevelConfig {
|
||||
/**是关卡场景图资源的名称,注意关卡选择界面选中关卡后展示的场景图资源也是这个 */
|
||||
bgImage: string;
|
||||
/**后续进入关卡后,关卡中需要播放的音乐资源名称 */
|
||||
bgm: string;
|
||||
/**在关卡中,聊天历史信息展示里,角色使用的头像,圆形 80*80 */
|
||||
characterAvatar: string;
|
||||
/**关卡中,提示信息界面里需要展示的角色性格文本 */
|
||||
characterDisposition: string;
|
||||
/**角色聊天切换的表情立绘,这个暂时先不处理,后面我们需要和你沟通下,资源改成英文名看你怎么匹配(Ai 返回的判断还是中文的) */
|
||||
characterEmojiSet: string;
|
||||
/**关卡中,提示信息界面,喜好话题部分需要展示的文本信息 */
|
||||
characterFavoriteTopic: string;
|
||||
/**角色默认立绘资源名称 */
|
||||
characterFullLengthPortrait: string;
|
||||
/**关卡提示信息界面里使用的角色半身胸像 */
|
||||
characterHalfLengthPortrait: string;
|
||||
/**关卡提示信息界面里,厌恶话题的展示文本信息 */
|
||||
characterHateTopic: string;
|
||||
/**角色名称,注意在关卡选择界面还有关卡中的聊天窗,关卡提示信息界面这几个地方都涉及展示 */
|
||||
characterName: string;
|
||||
/**角色职业设定信息,关卡提示信息界面里的职业部分展示 */
|
||||
characterRole: string;
|
||||
/**关卡选择界面里展示的关卡介绍文本信息 */
|
||||
description: string;
|
||||
/**关卡中对话得到高分后,额外向玩家展示的鼓励信息 */
|
||||
encourageMessage: string;
|
||||
/**结算图片 关卡 0 星,挑战失败的情况下在结算界面展示的 CG 资源名称 */
|
||||
failureCG: string;
|
||||
/**结算图片 关卡 1 星,挑战成功的情况下在结算界面展示的 CG 资源名称 */
|
||||
oneStarCG: string;
|
||||
/**结算图片 关卡 2 星,挑战成功的情况下在结算界面展示的 CG 资源名称 */
|
||||
twoStarCG: string;
|
||||
/**结算图片 关卡 3 星,那么需要展示的 CG 资源对应的名称 */
|
||||
threeStarCG: string;
|
||||
/**关卡中,对话得分特别低的情况下,额外给出的向玩家展示的鼓励信息 */
|
||||
hateMessage: string;
|
||||
/**关卡选择界面,菱形的头像资源名称 */
|
||||
icon: string;
|
||||
/**唯一的关卡 id 信息 */
|
||||
id: string;
|
||||
/**关卡是否已解锁,注意锁定状态仍然能够选择关卡,关卡选择界面中的背景和立绘需要切换做展示,但是玩家不能开启游戏哈 */
|
||||
is_unlock: boolean;
|
||||
/**npc名称 */
|
||||
name: string;
|
||||
/**关卡展示顺序 */
|
||||
no: number;
|
||||
/**关卡解锁需要通关的前置关卡 id 信息,对应id字段 */
|
||||
preLevelId: string;
|
||||
/**进入关卡后,角色发出给到玩家的开场白信息(历史聊天记录页面中也需要显示,一定是角色发出的第一句话) */
|
||||
prologueMessage: string;
|
||||
/**玩家在关卡中,点击随机填充按钮,需要随机选取一句,在输入框中填入,注意填入后不发送,玩家可修改,最终发送的信息还是以玩家点击发送按钮时,填入的信息为主 */
|
||||
randomInputPool: string[];
|
||||
/**关卡进行中的record_id,有值时要先获取一下之前的存档 */
|
||||
record_id: string;
|
||||
/**关卡历史最高分 */
|
||||
score: number;
|
||||
/**关卡历史最高星级 */
|
||||
star: number;
|
||||
/**关卡中,关卡提示信息界面里底部展示的提示信息文本,目前测试数据和关卡介绍信息一致,但后续会区分开来 */
|
||||
tips: string;
|
||||
/**Npc结算对话 3星时 */
|
||||
threeStarSummary: string;
|
||||
/**Npc结算对话 2星时 */
|
||||
twoStarSummary: string;
|
||||
/**Npc结算对话 1星时 */
|
||||
oneStarSummary: string;
|
||||
/**Npc结算对话 0星时 */
|
||||
failureSummary: string;
|
||||
/**Npc表情立绘 害羞 */
|
||||
characterShyPortrait: string;
|
||||
/**Npc表情立绘 厌恶 */
|
||||
characterHatePortrait: string;
|
||||
/**Npc表情立绘 开心 */
|
||||
characterHappyPortrait: string;
|
||||
/**关卡解锁类型 -1=未解锁 0=自动解锁 1=游戏通关解锁 2=手动解锁 */
|
||||
unlock_type: number;
|
||||
}
|
||||
|
||||
|
||||
/**关卡对话数据 */
|
||||
export interface I_LevelStepData {
|
||||
/**当前聊天次数 */
|
||||
current_cnt: number;
|
||||
/**结束评分 */
|
||||
end_star: number;
|
||||
/**关卡id */
|
||||
id: string;
|
||||
/**最大聊天次数 */
|
||||
max_cnt: number;
|
||||
/**当前状态 0:成功 1:进行中 2:失败 3:剩余聊天次数不足 */
|
||||
status: number;
|
||||
/**可用总聊天次数 */
|
||||
total_cnt: number;
|
||||
/**心动次数 */
|
||||
heartbeat_cnt: number;
|
||||
/**剩余可看广告次数 */
|
||||
ad_num: number;
|
||||
/**剩余可分享次数 */
|
||||
share_num: number;
|
||||
/**剩余可撤回次数 */
|
||||
can_use_cancel_cnt: number;
|
||||
/**剩余可暴击次数 */
|
||||
can_use_strength_cnt: number;
|
||||
/**暴击是否生效 */
|
||||
is_strength_take_effect: boolean;
|
||||
/**甜蜜暴击已用次数 */
|
||||
first_strength?: number;
|
||||
/**撤回已用次数 */
|
||||
first_cancel?: number;
|
||||
}
|
||||
|
||||
|
||||
/**npc长连接中的回复 */
|
||||
export interface I_NpcTalkBack {
|
||||
/**ai表情 */
|
||||
aiEmoji:string;
|
||||
/**ai回复 */
|
||||
aiResponse:string;
|
||||
/**ai评分 */
|
||||
aiScore:number;
|
||||
/**ai基础评分 */
|
||||
aiBaseScore:number;
|
||||
/**ai额外加分 */
|
||||
aiAdditionalScore:number;
|
||||
/**是否完成 */
|
||||
isFinished:boolean;
|
||||
/**聊天次数 */
|
||||
sourceCnt:number;
|
||||
/**玩家发的文本 */
|
||||
userInput: string;
|
||||
/**评价 -1=未生成 0=心动 1=普通 2=厌恶 */
|
||||
judgement: number;
|
||||
}
|
||||
|
||||
|
||||
/**对话历史记录数据 */
|
||||
export interface I_TalkRecordInfo {
|
||||
/**对话内容 */
|
||||
talk: string;
|
||||
/**是否是玩家自己 */
|
||||
isMe: boolean;
|
||||
/**评分 小于0时不显示 */
|
||||
score: number;
|
||||
/**基础分 */
|
||||
scoreBase: number;
|
||||
/**额外加分 */
|
||||
scoreAdditional: number;
|
||||
}
|
||||
|
||||
|
||||
/**玩家信息数据 */
|
||||
export interface I_UserInfo {
|
||||
id: number;
|
||||
score: number;
|
||||
status: number;
|
||||
/**头像url */
|
||||
avatar: string;
|
||||
/**昵称 */
|
||||
nickname: string;
|
||||
/**剩余进入关卡次数 */
|
||||
ticket: number;
|
||||
/**剩余可看广告次数 - 进入关卡 */
|
||||
game_ad_num: number;
|
||||
/**剩余可分享次数 - 进入关卡 */
|
||||
game_share_num: number;
|
||||
/**剩余可看广告次数 - 聊天 */
|
||||
level_ad_num: number;
|
||||
/**剩余可分享次数 - 聊天 */
|
||||
level_share_num: number;
|
||||
/**抖音侧边栏奖励是否已领取 0未领取 1已领取 */
|
||||
is_receive: number;
|
||||
/**友盟关卡记录 */
|
||||
levels: any[];
|
||||
}
|
||||
|
||||
/**心动回忆数据 */
|
||||
export interface I_HuiyiInfo {
|
||||
/**关卡id */
|
||||
lvId: string;
|
||||
/**星数 */
|
||||
star: number;
|
||||
/**是否解锁 */
|
||||
unlock: boolean;
|
||||
}
|
||||
@@ -0,0 +1,42 @@
|
||||
import { _decorator, Component, Node, tween, UIOpacity, Vec3 } from 'cc';
|
||||
import Utils from '../../Main/Common/Utils';
|
||||
const { ccclass, property } = _decorator;
|
||||
|
||||
/**界面打开动画 */
|
||||
@ccclass('UIOpenAni')
|
||||
export class UIOpenAni extends Component {
|
||||
private uiopa: UIOpacity = null;
|
||||
start() {
|
||||
this.uiopa = this.node.getComponent(UIOpacity);
|
||||
if (!this.uiopa) {
|
||||
this.uiopa = this.node.addComponent(UIOpacity);
|
||||
}
|
||||
|
||||
//动作1 透明度
|
||||
this.uiopa.opacity = 0;
|
||||
tween(this.uiopa)
|
||||
.delay(0.1)
|
||||
.to(0.15, { opacity: 255 })
|
||||
.start();
|
||||
|
||||
//动作2 缩放
|
||||
let scaleRatio = Utils.getScaleRatio(2)
|
||||
if (scaleRatio > 1) {
|
||||
scaleRatio = 1;
|
||||
}
|
||||
let origScale = new Vec3(scaleRatio, scaleRatio, scaleRatio);
|
||||
tween(this.node)
|
||||
.delay(0.1)
|
||||
.call(() => {
|
||||
this.node.scale = new Vec3(0.7, 0.7, 0.7);
|
||||
})
|
||||
.to(0.2, { scale: origScale }, { easing: 'backOut' })
|
||||
.start();
|
||||
}
|
||||
|
||||
update(deltaTime: number) {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"ver": "1.0.27",
|
||||
"importer": "image",
|
||||
"imported": true,
|
||||
"uuid": "8e67989b-2e61-403c-90d6-13e0eebb30a6",
|
||||
"files": [
|
||||
".json",
|
||||
".png"
|
||||
],
|
||||
"subMetas": {
|
||||
"6c48a": {
|
||||
"importer": "texture",
|
||||
"uuid": "8e67989b-2e61-403c-90d6-13e0eebb30a6@6c48a",
|
||||
"displayName": "mengxia_portrait",
|
||||
"id": "6c48a",
|
||||
"name": "texture",
|
||||
"userData": {
|
||||
"wrapModeS": "clamp-to-edge",
|
||||
"wrapModeT": "clamp-to-edge",
|
||||
"imageUuidOrDatabaseUri": "8e67989b-2e61-403c-90d6-13e0eebb30a6",
|
||||
"isUuid": true,
|
||||
"visible": false,
|
||||
"minfilter": "linear",
|
||||
"magfilter": "linear",
|
||||
"mipfilter": "none",
|
||||
"anisotropy": 0
|
||||
},
|
||||
"ver": "1.0.22",
|
||||
"imported": true,
|
||||
"files": [
|
||||
".json"
|
||||
],
|
||||
"subMetas": {}
|
||||
},
|
||||
"f9941": {
|
||||
"importer": "sprite-frame",
|
||||
"uuid": "8e67989b-2e61-403c-90d6-13e0eebb30a6@f9941",
|
||||
"displayName": "mengxia_portrait",
|
||||
"id": "f9941",
|
||||
"name": "spriteFrame",
|
||||
"userData": {
|
||||
"trimType": "auto",
|
||||
"trimThreshold": 1,
|
||||
"rotated": false,
|
||||
"offsetX": -9.5,
|
||||
"offsetY": -12,
|
||||
"trimX": 2,
|
||||
"trimY": 24,
|
||||
"width": 253,
|
||||
"height": 340,
|
||||
"rawWidth": 276,
|
||||
"rawHeight": 364,
|
||||
"borderTop": 0,
|
||||
"borderBottom": 0,
|
||||
"borderLeft": 0,
|
||||
"borderRight": 0,
|
||||
"packable": true,
|
||||
"pixelsToUnit": 100,
|
||||
"pivotX": 0.5,
|
||||
"pivotY": 0.5,
|
||||
"meshType": 0,
|
||||
"vertices": {
|
||||
"rawPosition": [
|
||||
-126.5,
|
||||
-170,
|
||||
0,
|
||||
126.5,
|
||||
-170,
|
||||
0,
|
||||
-126.5,
|
||||
170,
|
||||
0,
|
||||
126.5,
|
||||
170,
|
||||
0
|
||||
],
|
||||
"indexes": [
|
||||
0,
|
||||
1,
|
||||
2,
|
||||
2,
|
||||
1,
|
||||
3
|
||||
],
|
||||
"uv": [
|
||||
2,
|
||||
340,
|
||||
255,
|
||||
340,
|
||||
2,
|
||||
0,
|
||||
255,
|
||||
0
|
||||
],
|
||||
"nuv": [
|
||||
0.007246376811594203,
|
||||
0,
|
||||
0.9239130434782609,
|
||||
0,
|
||||
0.007246376811594203,
|
||||
0.9340659340659341,
|
||||
0.9239130434782609,
|
||||
0.9340659340659341
|
||||
],
|
||||
"minPos": [
|
||||
-126.5,
|
||||
-170,
|
||||
0
|
||||
],
|
||||
"maxPos": [
|
||||
126.5,
|
||||
170,
|
||||
0
|
||||
]
|
||||
},
|
||||
"isUuid": true,
|
||||
"imageUuidOrDatabaseUri": "8e67989b-2e61-403c-90d6-13e0eebb30a6@6c48a",
|
||||
"atlasUuid": ""
|
||||
},
|
||||
"ver": "1.0.12",
|
||||
"imported": true,
|
||||
"files": [
|
||||
".json"
|
||||
],
|
||||
"subMetas": {}
|
||||
}
|
||||
},
|
||||
"userData": {
|
||||
"type": "sprite-frame",
|
||||
"hasAlpha": true,
|
||||
"fixAlphaTransparencyArtifacts": false,
|
||||
"redirect": "8e67989b-2e61-403c-90d6-13e0eebb30a6@6c48a"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"ver": "1.0.27",
|
||||
"importer": "image",
|
||||
"imported": true,
|
||||
"uuid": "0b757824-0c68-493a-a708-d8e5331c4c08",
|
||||
"files": [
|
||||
".json",
|
||||
".png"
|
||||
],
|
||||
"subMetas": {
|
||||
"6c48a": {
|
||||
"importer": "texture",
|
||||
"uuid": "0b757824-0c68-493a-a708-d8e5331c4c08@6c48a",
|
||||
"displayName": "adelle_beaumont_portrait",
|
||||
"id": "6c48a",
|
||||
"name": "texture",
|
||||
"userData": {
|
||||
"wrapModeS": "clamp-to-edge",
|
||||
"wrapModeT": "clamp-to-edge",
|
||||
"imageUuidOrDatabaseUri": "0b757824-0c68-493a-a708-d8e5331c4c08",
|
||||
"isUuid": true,
|
||||
"visible": false,
|
||||
"minfilter": "linear",
|
||||
"magfilter": "linear",
|
||||
"mipfilter": "none",
|
||||
"anisotropy": 0
|
||||
},
|
||||
"ver": "1.0.22",
|
||||
"imported": true,
|
||||
"files": [
|
||||
".json"
|
||||
],
|
||||
"subMetas": {}
|
||||
},
|
||||
"f9941": {
|
||||
"importer": "sprite-frame",
|
||||
"uuid": "0b757824-0c68-493a-a708-d8e5331c4c08@f9941",
|
||||
"displayName": "adelle_beaumont_portrait",
|
||||
"id": "f9941",
|
||||
"name": "spriteFrame",
|
||||
"userData": {
|
||||
"trimType": "auto",
|
||||
"trimThreshold": 1,
|
||||
"rotated": false,
|
||||
"offsetX": -3,
|
||||
"offsetY": -12,
|
||||
"trimX": 1,
|
||||
"trimY": 24,
|
||||
"width": 268,
|
||||
"height": 340,
|
||||
"rawWidth": 276,
|
||||
"rawHeight": 364,
|
||||
"borderTop": 0,
|
||||
"borderBottom": 0,
|
||||
"borderLeft": 0,
|
||||
"borderRight": 0,
|
||||
"packable": true,
|
||||
"pixelsToUnit": 100,
|
||||
"pivotX": 0.5,
|
||||
"pivotY": 0.5,
|
||||
"meshType": 0,
|
||||
"vertices": {
|
||||
"rawPosition": [
|
||||
-134,
|
||||
-170,
|
||||
0,
|
||||
134,
|
||||
-170,
|
||||
0,
|
||||
-134,
|
||||
170,
|
||||
0,
|
||||
134,
|
||||
170,
|
||||
0
|
||||
],
|
||||
"indexes": [
|
||||
0,
|
||||
1,
|
||||
2,
|
||||
2,
|
||||
1,
|
||||
3
|
||||
],
|
||||
"uv": [
|
||||
1,
|
||||
340,
|
||||
269,
|
||||
340,
|
||||
1,
|
||||
0,
|
||||
269,
|
||||
0
|
||||
],
|
||||
"nuv": [
|
||||
0.0036231884057971015,
|
||||
0,
|
||||
0.9746376811594203,
|
||||
0,
|
||||
0.0036231884057971015,
|
||||
0.9340659340659341,
|
||||
0.9746376811594203,
|
||||
0.9340659340659341
|
||||
],
|
||||
"minPos": [
|
||||
-134,
|
||||
-170,
|
||||
0
|
||||
],
|
||||
"maxPos": [
|
||||
134,
|
||||
170,
|
||||
0
|
||||
]
|
||||
},
|
||||
"isUuid": true,
|
||||
"imageUuidOrDatabaseUri": "0b757824-0c68-493a-a708-d8e5331c4c08@6c48a",
|
||||
"atlasUuid": ""
|
||||
},
|
||||
"ver": "1.0.12",
|
||||
"imported": true,
|
||||
"files": [
|
||||
".json"
|
||||
],
|
||||
"subMetas": {}
|
||||
}
|
||||
},
|
||||
"userData": {
|
||||
"type": "sprite-frame",
|
||||
"hasAlpha": true,
|
||||
"fixAlphaTransparencyArtifacts": false,
|
||||
"redirect": "0b757824-0c68-493a-a708-d8e5331c4c08@6c48a"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,72 @@
|
||||
import { _decorator, Component, Node, Sprite } from 'cc';
|
||||
import { GButton } from '../../Main/Common/GButton';
|
||||
import Utils from '../../Main/Common/Utils';
|
||||
const { ccclass, property } = _decorator;
|
||||
|
||||
//确认框弹窗
|
||||
@ccclass('ConfirmDialog')
|
||||
export class ConfirmDialog extends Component {
|
||||
|
||||
private _nodeTab: any = {};
|
||||
private _data;
|
||||
private inited: boolean = false;
|
||||
|
||||
onLoad() {
|
||||
Utils.parseNode(this.node, this._nodeTab)
|
||||
|
||||
}
|
||||
|
||||
start() {
|
||||
// GButton.BandClick(this._nodeTab.mask, ()=>{
|
||||
// this.doClose();
|
||||
// }, this, 0, null, null, false);
|
||||
//取消
|
||||
GButton.BandClick(this._nodeTab.btnNo, ()=>{
|
||||
if (this._data && this._data.noCallback) {
|
||||
this._data.noCallback();
|
||||
}
|
||||
this.node.removeFromParent()
|
||||
}, this);
|
||||
//确定
|
||||
GButton.BandClick(this._nodeTab.btnYes, ()=>{
|
||||
if (this._data && this._data.yesCallback) {
|
||||
this._data.yesCallback();
|
||||
}
|
||||
this.node.removeFromParent()
|
||||
}, this);
|
||||
|
||||
this.inited = true;
|
||||
this.refreshUI();
|
||||
}
|
||||
|
||||
update(deltaTime: number) {
|
||||
|
||||
}
|
||||
|
||||
/**设置显示参数 */
|
||||
setParam(data: any) {
|
||||
this._data = data;
|
||||
this.refreshUI();
|
||||
}
|
||||
|
||||
|
||||
private refreshUI() {
|
||||
if (!this.inited || !this._data) return;
|
||||
//内容
|
||||
Utils.setString(this._nodeTab.labContent, this._data.content);
|
||||
//确认按钮文本
|
||||
if (this._data.strYes) {
|
||||
Utils.setString(this._nodeTab.labYes, this._data.strYes);
|
||||
}
|
||||
//取消按钮文本
|
||||
if (this._data.strNo) {
|
||||
Utils.setString(this._nodeTab.labNo, this._data.strNo);
|
||||
}
|
||||
//隐藏取消按钮
|
||||
if (this._data.hideNo == true) {
|
||||
this._nodeTab.btnNo.active = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 766 KiB |
Reference in New Issue
Block a user