feat: 接入通关弹窗

This commit is contained in:
richarjiang
2026-04-26 16:20:37 +08:00
parent f5732b46a5
commit 5074706115
52 changed files with 8064 additions and 540 deletions

BIN
assets/.DS_Store vendored Normal file

Binary file not shown.

View File

@@ -5,11 +5,13 @@ import { StorageManager } from 'db://assets/scripts/utils/StorageManager';
import { StaminaManager } from 'db://assets/scripts/utils/StaminaManager';
import { WxSDK } from 'db://assets/scripts/utils/WxSDK';
import { LevelDataManager } from 'db://assets/scripts/utils/LevelDataManager';
import { AuthManager } from 'db://assets/scripts/utils/AuthManager';
import { RuntimeLevelConfig } from 'db://assets/scripts/types/LevelTypes';
import { ToastManager } from 'db://assets/scripts/utils/ToastManager';
import { ShareManager } from 'db://assets/scripts/utils/ShareManager';
import { PassModal } from 'db://assets/prefabs/PassModal';
import { StaminaInfo } from 'db://assets/scripts/types/ApiTypes';
import { AchievementTitleManager } from 'db://assets/scripts/utils/AchievementTitleManager';
const { ccclass, property } = _decorator;
/**
@@ -152,6 +154,9 @@ export class PageLevel extends BaseView {
/** 通关弹窗实例 */
private _passModalNode: Node | null = null;
/** 本次通关弹窗使用的已通关数量 */
private _passModalCompletedLevelCount: number | null = null;
/** 是否处于分享挑战模式 */
private _isShareMode: boolean = false;
@@ -1149,15 +1154,25 @@ export class PageLevel extends BaseView {
private reportLevelCompleted(levelId: string, timeSpent: number): void {
if (!this._isShareMode) {
// 标记关卡为已通关(本地缓存),通关上报并行执行,不阻塞包袱展示节奏
const wasCompleted = LevelDataManager.instance.isLevelCompleted(this.currentLevelIndex);
if (!wasCompleted) {
AuthManager.instance.addCompletedLevelCount();
}
this._passModalCompletedLevelCount = AuthManager.instance.completedLevelCount;
LevelDataManager.instance.markLevelCompleted(this.currentLevelIndex);
void StaminaManager.instance.completeLevel(levelId, timeSpent).then((result) => {
if (result) {
if (!result.firstClear && !wasCompleted) {
AuthManager.instance.addCompletedLevelCount(-1);
this._passModalCompletedLevelCount = AuthManager.instance.completedLevelCount;
}
console.log(`[PageLevel] 通关上报成功,首次通关: ${result.firstClear}`);
}
});
return;
}
this._passModalCompletedLevelCount = null;
// fire-and-forget: errors are logged inside reportLevelProgress
void ShareManager.instance.reportLevelProgress(levelId, true, timeSpent);
}
@@ -1199,7 +1214,10 @@ export class PageLevel extends BaseView {
// 获取 PassModal 组件并设置回调
const passModal = modalNode.getComponent(PassModal);
if (passModal) {
passModal.setParams({ levelIndex: this.currentLevelIndex + 1 });
passModal.setParams({
levelIndex: this.currentLevelIndex + 1,
titleInfo: AchievementTitleManager.getTitleInfo(this._getPassModalCompletedLevelCount())
});
passModal.setCallbacks({
onNextLevel: () => {
this._closePassModal();
@@ -1218,6 +1236,10 @@ export class PageLevel extends BaseView {
console.log('[PageLevel] 显示通关弹窗');
}
private _getPassModalCompletedLevelCount(): number {
return this._passModalCompletedLevelCount ?? AuthManager.instance.completedLevelCount;
}
/**
* 关闭通关弹窗
*/

File diff suppressed because it is too large Load Diff

View File

@@ -1,5 +1,5 @@
import { _decorator, Node, Label, AudioClip, AudioSource, view, UITransform, Size } from 'cc';
import { BaseView } from 'db://assets/scripts/core/BaseView';
import { _decorator, Node, Label, AudioClip, AudioSource, view, UITransform, Size, ProgressBar } from 'cc';
import { BaseModal } from 'db://assets/scripts/core/BaseModal';
import { WxSDK } from 'db://assets/scripts/utils/WxSDK';
const { ccclass, property } = _decorator;
@@ -13,12 +13,23 @@ export interface PassModalCallbacks {
onShare?: () => void;
}
export interface PassModalTitleInfo {
titleText?: string;
nextTitleProgress?: number;
progressText?: string;
}
interface PassModalParams {
levelIndex?: number;
titleInfo?: PassModalTitleInfo;
}
/**
* 通关弹窗组件
* 继承 BaseView,显示通关成功弹窗,提供"下一关"和"分享给好友"两个按钮
* 继承 BaseModal,显示通关成功弹窗,提供"下一关"和"分享给好友"两个按钮
*/
@ccclass('PassModal')
export class PassModal extends BaseView {
export class PassModal extends BaseModal {
/** 静态常量:弹窗层级 */
public static readonly MODAL_Z_INDEX = 999;
@@ -30,9 +41,17 @@ export class PassModal extends BaseView {
@property(Node)
shareButton: Node | null = null;
/** 提示Label如 恭喜通关) */
/** 称号文字 */
@property(Label)
tipLabel: Label | null = null;
titleLevelLabel: Label | null = null;
/** 距离下一个称号的进度 */
@property(ProgressBar)
titleProgressBar: ProgressBar | null = null;
/** 进度提示文案 */
@property(Label)
progressLabel: Label | null = null;
/** 通关音效 */
@property(AudioClip)
@@ -44,6 +63,21 @@ export class PassModal extends BaseView {
/** 缓存的屏幕尺寸 */
private _screenSize: Size | null = null;
/** 称号展示数据 */
private _titleInfo: PassModalTitleInfo = {
titleText: '冷场小白1级',
nextTitleProgress: 0,
progressText: '还差3题获得冷场小白2级'
};
setParams(params: PassModalParams): void {
super.setParams(params);
if (params?.titleInfo) {
this.setTitleInfo(params.titleInfo);
}
}
/**
* 设置回调函数
*/
@@ -51,6 +85,17 @@ export class PassModal extends BaseView {
this._callbacks = callbacks;
}
/**
* 设置称号体系展示数据
*/
setTitleInfo(titleInfo: PassModalTitleInfo): void {
this._titleInfo = {
...this._titleInfo,
...titleInfo
};
this._updateTitleInfo();
}
/**
* 页面首次加载时调用
*/
@@ -63,7 +108,9 @@ export class PassModal extends BaseView {
* 页面每次显示时调用
*/
onViewShow(): void {
super.onViewShow();
this._updateWidget();
this._updateTitleInfo();
this._playSuccessSound();
}
@@ -129,6 +176,34 @@ export class PassModal extends BaseView {
}
}
/**
* 更新称号体系核心变量
*/
private _updateTitleInfo(): void {
if (this.titleLevelLabel && this._titleInfo.titleText !== undefined) {
this.titleLevelLabel.string = this._titleInfo.titleText;
}
if (this.titleProgressBar && this._titleInfo.nextTitleProgress !== undefined) {
this.titleProgressBar.progress = this._normalizeProgress(this._titleInfo.nextTitleProgress);
}
if (this.progressLabel && this._titleInfo.progressText !== undefined) {
this.progressLabel.string = this._titleInfo.progressText;
}
}
/**
* 规范化进度值
*/
private _normalizeProgress(progress: number): number {
if (!Number.isFinite(progress)) {
return 0;
}
return Math.max(0, Math.min(1, progress));
}
/**
* 下一关按钮点击
*/

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,13 @@
{
"ver": "1.1.50",
"importer": "prefab",
"imported": true,
"uuid": "e41c722f-f605-47f7-9ce4-abff0ed2020f",
"files": [
".json"
],
"subMetas": {},
"userData": {
"syncNodeName": "TimeoutModal"
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,13 @@
{
"ver": "1.1.50",
"importer": "prefab",
"imported": true,
"uuid": "455c7845-d090-4cd9-aeb4-1f5cad616bb5",
"files": [
".json"
],
"subMetas": {},
"userData": {
"syncNodeName": "WrongModal"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 178 KiB

View File

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "3ef3f86f-bc1f-49b7-a50f-0e8683cd2400",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "3ef3f86f-bc1f-49b7-a50f-0e8683cd2400@6c48a",
"displayName": "1_0022_Layer-19",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "3ef3f86f-bc1f-49b7-a50f-0e8683cd2400",
"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": "3ef3f86f-bc1f-49b7-a50f-0e8683cd2400@f9941",
"displayName": "1_0022_Layer-19",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 1297,
"height": 1004,
"rawWidth": 1297,
"rawHeight": 1004,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-648.5,
-502,
0,
648.5,
-502,
0,
-648.5,
502,
0,
648.5,
502,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
0,
1004,
1297,
1004,
0,
0,
1297,
0
],
"nuv": [
0,
0,
1,
0,
0,
1,
1,
1
],
"minPos": [
-648.5,
-502,
0
],
"maxPos": [
648.5,
502,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "3ef3f86f-bc1f-49b7-a50f-0e8683cd2400@6c48a",
"atlasUuid": "",
"trimType": "auto"
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"fixAlphaTransparencyArtifacts": false,
"hasAlpha": true,
"redirect": "3ef3f86f-bc1f-49b7-a50f-0e8683cd2400@6c48a"
}
}

View File

@@ -51,8 +51,8 @@
"rawHeight": 235,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"borderLeft": 120,
"borderRight": 120,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,

Binary file not shown.

After

Width:  |  Height:  |  Size: 53 KiB

View File

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "0366f161-d78c-43b1-b2cb-8d0666dd2fbd",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "0366f161-d78c-43b1-b2cb-8d0666dd2fbd@6c48a",
"displayName": "ButtonOrange",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "0366f161-d78c-43b1-b2cb-8d0666dd2fbd",
"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": "0366f161-d78c-43b1-b2cb-8d0666dd2fbd@f9941",
"displayName": "ButtonOrange",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimThreshold": 1,
"rotated": false,
"offsetX": -0.5,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 665,
"height": 235,
"rawWidth": 666,
"rawHeight": 235,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-332.5,
-117.5,
0,
332.5,
-117.5,
0,
-332.5,
117.5,
0,
332.5,
117.5,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
0,
235,
665,
235,
0,
0,
665,
0
],
"nuv": [
0,
0,
0.9984984984984985,
0,
0,
1,
0.9984984984984985,
1
],
"minPos": [
-332.5,
-117.5,
0
],
"maxPos": [
332.5,
117.5,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "0366f161-d78c-43b1-b2cb-8d0666dd2fbd@6c48a",
"atlasUuid": "",
"trimType": "auto"
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"fixAlphaTransparencyArtifacts": false,
"hasAlpha": true,
"redirect": "0366f161-d78c-43b1-b2cb-8d0666dd2fbd@6c48a"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 106 KiB

View File

@@ -2,7 +2,7 @@
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "d46acd4d-66e2-423b-8015-334ff99dd9f1",
"uuid": "98c2d728-0c34-499f-9a80-8aada311204d",
"files": [
".json",
".png"
@@ -10,14 +10,14 @@
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "d46acd4d-66e2-423b-8015-334ff99dd9f1@6c48a",
"displayName": "test",
"uuid": "98c2d728-0c34-499f-9a80-8aada311204d@6c48a",
"displayName": "clock",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "d46acd4d-66e2-423b-8015-334ff99dd9f1",
"imageUuidOrDatabaseUri": "98c2d728-0c34-499f-9a80-8aada311204d",
"isUuid": true,
"visible": false,
"minfilter": "linear",
@@ -34,8 +34,8 @@
},
"f9941": {
"importer": "sprite-frame",
"uuid": "d46acd4d-66e2-423b-8015-334ff99dd9f1@f9941",
"displayName": "test",
"uuid": "98c2d728-0c34-499f-9a80-8aada311204d@f9941",
"displayName": "clock",
"id": "f9941",
"name": "spriteFrame",
"userData": {
@@ -45,10 +45,10 @@
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 536,
"height": 548,
"rawWidth": 536,
"rawHeight": 548,
"width": 568,
"height": 630,
"rawWidth": 568,
"rawHeight": 630,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
@@ -60,17 +60,17 @@
"meshType": 0,
"vertices": {
"rawPosition": [
-268,
-274,
-284,
-315,
0,
268,
-274,
284,
-315,
0,
-268,
274,
-284,
315,
0,
268,
274,
284,
315,
0
],
"indexes": [
@@ -83,12 +83,12 @@
],
"uv": [
0,
548,
536,
548,
630,
568,
630,
0,
0,
536,
568,
0
],
"nuv": [
@@ -102,18 +102,18 @@
1
],
"minPos": [
-268,
-274,
-284,
-315,
0
],
"maxPos": [
268,
274,
284,
315,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "d46acd4d-66e2-423b-8015-334ff99dd9f1@6c48a",
"imageUuidOrDatabaseUri": "98c2d728-0c34-499f-9a80-8aada311204d@6c48a",
"atlasUuid": "",
"trimType": "auto"
},
@@ -128,7 +128,7 @@
"userData": {
"type": "sprite-frame",
"fixAlphaTransparencyArtifacts": false,
"hasAlpha": false,
"redirect": "d46acd4d-66e2-423b-8015-334ff99dd9f1@6c48a"
"hasAlpha": true,
"redirect": "98c2d728-0c34-499f-9a80-8aada311204d@6c48a"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

View File

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "540f8b6d-7cad-47e8-abae-b941c9bdd900",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "540f8b6d-7cad-47e8-abae-b941c9bdd900@6c48a",
"displayName": "closeBtn",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "540f8b6d-7cad-47e8-abae-b941c9bdd900",
"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": "540f8b6d-7cad-47e8-abae-b941c9bdd900@f9941",
"displayName": "closeBtn",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 180,
"height": 191,
"rawWidth": 180,
"rawHeight": 191,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-90,
-95.5,
0,
90,
-95.5,
0,
-90,
95.5,
0,
90,
95.5,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
0,
191,
180,
191,
0,
0,
180,
0
],
"nuv": [
0,
0,
1,
0,
0,
1,
1,
1
],
"minPos": [
-90,
-95.5,
0
],
"maxPos": [
90,
95.5,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "540f8b6d-7cad-47e8-abae-b941c9bdd900@6c48a",
"atlasUuid": "",
"trimType": "auto"
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"fixAlphaTransparencyArtifacts": false,
"hasAlpha": true,
"redirect": "540f8b6d-7cad-47e8-abae-b941c9bdd900@6c48a"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 940 KiB

View File

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "10f211a7-5580-4da3-94d2-2d285d63ac28",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "10f211a7-5580-4da3-94d2-2d285d63ac28@6c48a",
"displayName": "dialogPanel",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "10f211a7-5580-4da3-94d2-2d285d63ac28",
"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": "10f211a7-5580-4da3-94d2-2d285d63ac28@f9941",
"displayName": "dialogPanel",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 2,
"trimX": 0,
"trimY": 0,
"width": 1420,
"height": 1845,
"rawWidth": 1420,
"rawHeight": 1849,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-710,
-922.5,
0,
710,
-922.5,
0,
-710,
922.5,
0,
710,
922.5,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
0,
1849,
1420,
1849,
0,
4,
1420,
4
],
"nuv": [
0,
0.002163331530557058,
1,
0.002163331530557058,
0,
1,
1,
1
],
"minPos": [
-710,
-922.5,
0
],
"maxPos": [
710,
922.5,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "10f211a7-5580-4da3-94d2-2d285d63ac28@6c48a",
"atlasUuid": "",
"trimType": "auto"
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"fixAlphaTransparencyArtifacts": false,
"hasAlpha": true,
"redirect": "10f211a7-5580-4da3-94d2-2d285d63ac28@6c48a"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.7 KiB

View File

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "69f85753-6740-4686-ba40-5d2383292f39",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "69f85753-6740-4686-ba40-5d2383292f39@6c48a",
"displayName": "flatIconHelp",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "69f85753-6740-4686-ba40-5d2383292f39",
"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": "69f85753-6740-4686-ba40-5d2383292f39@f9941",
"displayName": "flatIconHelp",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 468,
"height": 468,
"rawWidth": 468,
"rawHeight": 468,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-234,
-234,
0,
234,
-234,
0,
-234,
234,
0,
234,
234,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
0,
468,
468,
468,
0,
0,
468,
0
],
"nuv": [
0,
0,
1,
0,
0,
1,
1,
1
],
"minPos": [
-234,
-234,
0
],
"maxPos": [
234,
234,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "69f85753-6740-4686-ba40-5d2383292f39@6c48a",
"atlasUuid": "",
"trimType": "auto"
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"fixAlphaTransparencyArtifacts": false,
"hasAlpha": true,
"redirect": "69f85753-6740-4686-ba40-5d2383292f39@6c48a"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

View File

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "fb73de29-d734-4eb4-853d-8cbdbb18a9c9",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "fb73de29-d734-4eb4-853d-8cbdbb18a9c9@6c48a",
"displayName": "flatIconHome",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "fb73de29-d734-4eb4-853d-8cbdbb18a9c9",
"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": "fb73de29-d734-4eb4-853d-8cbdbb18a9c9@f9941",
"displayName": "flatIconHome",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 427,
"height": 427,
"rawWidth": 427,
"rawHeight": 427,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-213.5,
-213.5,
0,
213.5,
-213.5,
0,
-213.5,
213.5,
0,
213.5,
213.5,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
0,
427,
427,
427,
0,
0,
427,
0
],
"nuv": [
0,
0,
1,
0,
0,
1,
1,
1
],
"minPos": [
-213.5,
-213.5,
0
],
"maxPos": [
213.5,
213.5,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "fb73de29-d734-4eb4-853d-8cbdbb18a9c9@6c48a",
"atlasUuid": "",
"trimType": "auto"
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"fixAlphaTransparencyArtifacts": false,
"hasAlpha": true,
"redirect": "fb73de29-d734-4eb4-853d-8cbdbb18a9c9@6c48a"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB

View File

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "1c8a9e95-7b00-4e59-a0a2-72a4aa97c03c",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "1c8a9e95-7b00-4e59-a0a2-72a4aa97c03c@6c48a",
"displayName": "flatIconNext",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "1c8a9e95-7b00-4e59-a0a2-72a4aa97c03c",
"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": "1c8a9e95-7b00-4e59-a0a2-72a4aa97c03c@f9941",
"displayName": "flatIconNext",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimThreshold": 1,
"rotated": false,
"offsetX": 13.5,
"offsetY": -0.5,
"trimX": 82,
"trimY": 29,
"width": 375,
"height": 455,
"rawWidth": 512,
"rawHeight": 512,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-187.5,
-227.5,
0,
187.5,
-227.5,
0,
-187.5,
227.5,
0,
187.5,
227.5,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
82,
483,
457,
483,
82,
28,
457,
28
],
"nuv": [
0.16015625,
0.0546875,
0.892578125,
0.0546875,
0.16015625,
0.943359375,
0.892578125,
0.943359375
],
"minPos": [
-187.5,
-227.5,
0
],
"maxPos": [
187.5,
227.5,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "1c8a9e95-7b00-4e59-a0a2-72a4aa97c03c@6c48a",
"atlasUuid": "",
"trimType": "auto"
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"fixAlphaTransparencyArtifacts": false,
"hasAlpha": true,
"redirect": "1c8a9e95-7b00-4e59-a0a2-72a4aa97c03c@6c48a"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.4 KiB

View File

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "c24760c9-312a-4638-ae56-6422010d93d0",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "c24760c9-312a-4638-ae56-6422010d93d0@6c48a",
"displayName": "flatIconRestart",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "c24760c9-312a-4638-ae56-6422010d93d0",
"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": "c24760c9-312a-4638-ae56-6422010d93d0@f9941",
"displayName": "flatIconRestart",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 490,
"height": 492,
"rawWidth": 490,
"rawHeight": 492,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-245,
-246,
0,
245,
-246,
0,
-245,
246,
0,
245,
246,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
0,
492,
490,
492,
0,
0,
490,
0
],
"nuv": [
0,
0,
1,
0,
0,
1,
1,
1
],
"minPos": [
-245,
-246,
0
],
"maxPos": [
245,
246,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "c24760c9-312a-4638-ae56-6422010d93d0@6c48a",
"atlasUuid": "",
"trimType": "auto"
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"fixAlphaTransparencyArtifacts": false,
"hasAlpha": true,
"redirect": "c24760c9-312a-4638-ae56-6422010d93d0@6c48a"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.5 KiB

View File

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "b9bec232-3d37-48a0-9ca8-62aab6c4083b",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "b9bec232-3d37-48a0-9ca8-62aab6c4083b@6c48a",
"displayName": "flatIconShare",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "b9bec232-3d37-48a0-9ca8-62aab6c4083b",
"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": "b9bec232-3d37-48a0-9ca8-62aab6c4083b@f9941",
"displayName": "flatIconShare",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 22,
"trimY": 11,
"width": 468,
"height": 490,
"rawWidth": 512,
"rawHeight": 512,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-234,
-245,
0,
234,
-245,
0,
-234,
245,
0,
234,
245,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
22,
501,
490,
501,
22,
11,
490,
11
],
"nuv": [
0.04296875,
0.021484375,
0.95703125,
0.021484375,
0.04296875,
0.978515625,
0.95703125,
0.978515625
],
"minPos": [
-234,
-245,
0
],
"maxPos": [
234,
245,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "b9bec232-3d37-48a0-9ca8-62aab6c4083b@6c48a",
"atlasUuid": "",
"trimType": "auto"
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"fixAlphaTransparencyArtifacts": false,
"hasAlpha": true,
"redirect": "b9bec232-3d37-48a0-9ca8-62aab6c4083b@6c48a"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 88 KiB

View File

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "83e4a585-2ca9-485a-8ed5-b8782eafcc54",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "83e4a585-2ca9-485a-8ed5-b8782eafcc54@6c48a",
"displayName": "heart",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "83e4a585-2ca9-485a-8ed5-b8782eafcc54",
"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": "83e4a585-2ca9-485a-8ed5-b8782eafcc54@f9941",
"displayName": "heart",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 618,
"height": 529,
"rawWidth": 618,
"rawHeight": 529,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-309,
-264.5,
0,
309,
-264.5,
0,
-309,
264.5,
0,
309,
264.5,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
0,
529,
618,
529,
0,
0,
618,
0
],
"nuv": [
0,
0,
1,
0,
0,
1,
1,
1
],
"minPos": [
-309,
-264.5,
0
],
"maxPos": [
309,
264.5,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "83e4a585-2ca9-485a-8ed5-b8782eafcc54@6c48a",
"atlasUuid": "",
"trimType": "auto"
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"fixAlphaTransparencyArtifacts": false,
"hasAlpha": true,
"redirect": "83e4a585-2ca9-485a-8ed5-b8782eafcc54@6c48a"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 31 KiB

View File

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "62df15c5-20eb-4ab2-9b63-32bfbcce435b",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "62df15c5-20eb-4ab2-9b63-32bfbcce435b@6c48a",
"displayName": "iconCrown",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "62df15c5-20eb-4ab2-9b63-32bfbcce435b",
"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": "62df15c5-20eb-4ab2-9b63-32bfbcce435b@f9941",
"displayName": "iconCrown",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimThreshold": 1,
"rotated": false,
"offsetX": 0.5,
"offsetY": -3.5,
"trimX": 39,
"trimY": 57,
"width": 323,
"height": 293,
"rawWidth": 400,
"rawHeight": 400,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-161.5,
-146.5,
0,
161.5,
-146.5,
0,
-161.5,
146.5,
0,
161.5,
146.5,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
39,
343,
362,
343,
39,
50,
362,
50
],
"nuv": [
0.0975,
0.125,
0.905,
0.125,
0.0975,
0.8575,
0.905,
0.8575
],
"minPos": [
-161.5,
-146.5,
0
],
"maxPos": [
161.5,
146.5,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "62df15c5-20eb-4ab2-9b63-32bfbcce435b@6c48a",
"atlasUuid": "",
"trimType": "auto"
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"fixAlphaTransparencyArtifacts": false,
"hasAlpha": true,
"redirect": "62df15c5-20eb-4ab2-9b63-32bfbcce435b@6c48a"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 73 KiB

View File

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "929dfe4e-9eab-48f1-a87d-344d51f07402",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "929dfe4e-9eab-48f1-a87d-344d51f07402@6c48a",
"displayName": "progressBar",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "929dfe4e-9eab-48f1-a87d-344d51f07402",
"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": "929dfe4e-9eab-48f1-a87d-344d51f07402@f9941",
"displayName": "progressBar",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 928,
"height": 121,
"rawWidth": 928,
"rawHeight": 121,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 120,
"borderRight": 120,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-464,
-60.5,
0,
464,
-60.5,
0,
-464,
60.5,
0,
464,
60.5,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
0,
121,
928,
121,
0,
0,
928,
0
],
"nuv": [
0,
0,
1,
0,
0,
1,
1,
1
],
"minPos": [
-464,
-60.5,
0
],
"maxPos": [
464,
60.5,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "929dfe4e-9eab-48f1-a87d-344d51f07402@6c48a",
"atlasUuid": "",
"trimType": "auto"
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"fixAlphaTransparencyArtifacts": false,
"hasAlpha": true,
"redirect": "929dfe4e-9eab-48f1-a87d-344d51f07402@6c48a"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.4 KiB

View File

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "c55e385b-97b7-4aa1-8888-cfd101e68f77",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "c55e385b-97b7-4aa1-8888-cfd101e68f77@6c48a",
"displayName": "progressBarBg",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "c55e385b-97b7-4aa1-8888-cfd101e68f77",
"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": "c55e385b-97b7-4aa1-8888-cfd101e68f77@f9941",
"displayName": "progressBarBg",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0.5,
"trimX": 0,
"trimY": 0,
"width": 966,
"height": 163,
"rawWidth": 966,
"rawHeight": 164,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-483,
-81.5,
0,
483,
-81.5,
0,
-483,
81.5,
0,
483,
81.5,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
0,
164,
966,
164,
0,
1,
966,
1
],
"nuv": [
0,
0.006097560975609756,
1,
0.006097560975609756,
0,
1,
1,
1
],
"minPos": [
-483,
-81.5,
0
],
"maxPos": [
483,
81.5,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "c55e385b-97b7-4aa1-8888-cfd101e68f77@6c48a",
"atlasUuid": "",
"trimType": "auto"
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"fixAlphaTransparencyArtifacts": false,
"hasAlpha": true,
"redirect": "c55e385b-97b7-4aa1-8888-cfd101e68f77@6c48a"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

View File

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "7a17df33-9d28-4272-9f3e-f336af8d4afb",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "7a17df33-9d28-4272-9f3e-f336af8d4afb@6c48a",
"displayName": "sphere",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "7a17df33-9d28-4272-9f3e-f336af8d4afb",
"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": "7a17df33-9d28-4272-9f3e-f336af8d4afb@f9941",
"displayName": "sphere",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 416,
"height": 416,
"rawWidth": 416,
"rawHeight": 416,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-208,
-208,
0,
208,
-208,
0,
-208,
208,
0,
208,
208,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
0,
416,
416,
416,
0,
0,
416,
0
],
"nuv": [
0,
0,
1,
0,
0,
1,
1,
1
],
"minPos": [
-208,
-208,
0
],
"maxPos": [
208,
208,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "7a17df33-9d28-4272-9f3e-f336af8d4afb@6c48a",
"atlasUuid": "",
"trimType": "auto"
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"fixAlphaTransparencyArtifacts": false,
"hasAlpha": true,
"redirect": "7a17df33-9d28-4272-9f3e-f336af8d4afb@6c48a"
}
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 110 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 190 KiB

View File

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "4c29b5fc-64c2-4fbd-b220-a4388daebc0a",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "4c29b5fc-64c2-4fbd-b220-a4388daebc0a@6c48a",
"displayName": "winBanner",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "4c29b5fc-64c2-4fbd-b220-a4388daebc0a",
"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": "4c29b5fc-64c2-4fbd-b220-a4388daebc0a@f9941",
"displayName": "winBanner",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 3.5,
"trimX": 0,
"trimY": 0,
"width": 1131,
"height": 606,
"rawWidth": 1131,
"rawHeight": 613,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-565.5,
-303,
0,
565.5,
-303,
0,
-565.5,
303,
0,
565.5,
303,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
0,
613,
1131,
613,
0,
7,
1131,
7
],
"nuv": [
0,
0.011419249592169658,
1,
0.011419249592169658,
0,
1,
1,
1
],
"minPos": [
-565.5,
-303,
0
],
"maxPos": [
565.5,
303,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "4c29b5fc-64c2-4fbd-b220-a4388daebc0a@6c48a",
"atlasUuid": "",
"trimType": "auto"
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"fixAlphaTransparencyArtifacts": false,
"hasAlpha": true,
"redirect": "4c29b5fc-64c2-4fbd-b220-a4388daebc0a@6c48a"
}
}

View File

@@ -0,0 +1,31 @@
export interface AchievementTitleConfigItem {
readonly seriesName: string;
readonly levelName: string;
readonly clearsToNext: number;
}
const createSeries = (seriesName: string, levelCount: number, clearsToNext: number): AchievementTitleConfigItem[] => {
return Array.from({ length: levelCount }, (_, index) => ({
seriesName,
levelName: `${seriesName}${index + 1}`,
clearsToNext
}));
};
export const ACHIEVEMENT_TITLE_CONFIG: readonly AchievementTitleConfigItem[] = [
...createSeries('冷场小白', 2, 3),
...createSeries('尬笑学生', 2, 3),
...createSeries('浅梗游民', 3, 4),
...createSeries('热梗新秀', 6, 5),
...createSeries('笑点刺客', 6, 5),
...createSeries('爆梗高手', 8, 6),
...createSeries('幽默大师', 10, 8),
...createSeries('爆笑领主', 10, 8),
...createSeries('梗王之王', 20, 8)
];
export const INFINITE_ACHIEVEMENT_TITLE = {
seriesName: '幽默始祖',
levelNamePrefix: '幽默始祖',
clearsToNext: 8
} as const;

View File

@@ -0,0 +1,9 @@
{
"ver": "4.0.24",
"importer": "typescript",
"imported": true,
"uuid": "eb65203d-ee3d-4169-806d-1de88d9702eb",
"files": [],
"subMetas": {},
"userData": {}
}

View File

@@ -0,0 +1,102 @@
import { _decorator, Node, Tween, UIOpacity, Vec3, tween } from 'cc';
import { BaseView } from './BaseView';
const { ccclass, property } = _decorator;
@ccclass('BaseModal')
export class BaseModal extends BaseView {
@property([Node])
protected animationNodes: Node[] = [];
@property(Node)
protected backdropNode: Node | null = null;
@property
protected openAnimationEnabled: boolean = true;
@property
protected openAnimationDuration: number = 0.36;
private readonly _originalScales: Map<Node, Vec3> = new Map();
onViewShow(): void {
this.playOpenAnimation();
}
onViewHide(): void {
this.stopOpenAnimation();
}
protected playOpenAnimation(): void {
if (!this.openAnimationEnabled) {
return;
}
this.playBackdropFadeIn();
const targets = this.getAnimationTargets();
targets.forEach((target, index) => {
this.playBounceIn(target, index * 0.035);
});
}
protected stopOpenAnimation(): void {
this.getAnimationTargets().forEach((target) => {
Tween.stopAllByTarget(target);
});
const opacity = this.backdropNode?.getComponent(UIOpacity);
if (opacity) {
Tween.stopAllByTarget(opacity);
}
}
private getAnimationTargets(): Node[] {
const configuredTargets = this.animationNodes.filter((node) => node?.isValid);
return configuredTargets.length > 0 ? configuredTargets : [this.node];
}
private getOriginalScale(target: Node): Vec3 {
const cachedScale = this._originalScales.get(target);
if (cachedScale) {
return cachedScale;
}
const originalScale = target.scale.clone();
this._originalScales.set(target, originalScale);
return originalScale;
}
private playBounceIn(target: Node, delay: number): void {
const originalScale = this.getOriginalScale(target);
const startScale = this.multiplyScale(originalScale, 0.82);
const peakScale = this.multiplyScale(originalScale, 1.045);
Tween.stopAllByTarget(target);
target.setScale(startScale);
tween(target)
.delay(delay)
.to(this.openAnimationDuration * 0.58, { scale: peakScale }, { easing: 'backOut' })
.to(this.openAnimationDuration * 0.24, { scale: this.multiplyScale(originalScale, 0.985) }, { easing: 'sineOut' })
.to(this.openAnimationDuration * 0.18, { scale: originalScale }, { easing: 'sineOut' })
.start();
}
private playBackdropFadeIn(): void {
if (!this.backdropNode?.isValid) {
return;
}
const opacity = this.backdropNode.getComponent(UIOpacity) ?? this.backdropNode.addComponent(UIOpacity);
Tween.stopAllByTarget(opacity);
opacity.opacity = 0;
tween(opacity)
.to(0.18, { opacity: 255 }, { easing: 'sineOut' })
.start();
}
private multiplyScale(scale: Vec3, factor: number): Vec3 {
return new Vec3(scale.x * factor, scale.y * factor, scale.z);
}
}

View File

@@ -0,0 +1,9 @@
{
"ver": "4.0.24",
"importer": "typescript",
"imported": true,
"uuid": "981df4d4-68c1-4651-aa5b-44633c119e93",
"files": [],
"subMetas": {},
"userData": {}
}

View File

@@ -44,6 +44,7 @@ export interface GameData {
stamina: StaminaInfo;
};
completedLevelIds: string[];
completedLevelCount?: number;
}
/** 关卡列表项 */

View File

@@ -0,0 +1,111 @@
import { ACHIEVEMENT_TITLE_CONFIG, AchievementTitleConfigItem, INFINITE_ACHIEVEMENT_TITLE } from '../config/AchievementTitleConfig';
export interface AchievementTitleInfo {
readonly titleText: string;
readonly nextTitleText: string;
readonly nextTitleProgress: number;
readonly progressText: string;
readonly completedLevelCount: number;
readonly currentTitleStartCount: number;
readonly nextTitleRequiredCount: number;
readonly remainingToNextTitle: number;
}
interface AchievementTitleStage {
readonly titleText: string;
readonly clearsToNext: number;
readonly startCount: number;
}
export class AchievementTitleManager {
public static getTitleInfo(completedLevelCount: number): AchievementTitleInfo {
const safeCompletedCount = AchievementTitleManager.normalizeCompletedCount(completedLevelCount);
const stages = AchievementTitleManager.buildFiniteStages();
const finiteResult = AchievementTitleManager.findFiniteStage(safeCompletedCount, stages);
if (finiteResult) {
return AchievementTitleManager.createTitleInfo(safeCompletedCount, finiteResult.currentStage, finiteResult.nextStage);
}
return AchievementTitleManager.createInfiniteTitleInfo(safeCompletedCount, stages[stages.length - 1]);
}
private static normalizeCompletedCount(completedLevelCount: number): number {
if (!Number.isFinite(completedLevelCount) || completedLevelCount < 0) {
return 0;
}
return Math.floor(completedLevelCount);
}
private static buildFiniteStages(): AchievementTitleStage[] {
let startCount = 0;
return ACHIEVEMENT_TITLE_CONFIG.map((item: AchievementTitleConfigItem) => {
const stage: AchievementTitleStage = {
titleText: item.levelName,
clearsToNext: item.clearsToNext,
startCount
};
startCount += item.clearsToNext;
return stage;
});
}
private static findFiniteStage(completedLevelCount: number, stages: AchievementTitleStage[]): { currentStage: AchievementTitleStage; nextStage: AchievementTitleStage } | null {
for (let index = 0; index < stages.length; index++) {
const currentStage = stages[index];
const nextStage = stages[index + 1] ?? {
titleText: `${INFINITE_ACHIEVEMENT_TITLE.levelNamePrefix}1级`,
clearsToNext: INFINITE_ACHIEVEMENT_TITLE.clearsToNext,
startCount: currentStage.startCount + currentStage.clearsToNext
};
if (completedLevelCount < nextStage.startCount) {
return { currentStage, nextStage };
}
}
return null;
}
private static createInfiniteTitleInfo(completedLevelCount: number, lastFiniteStage: AchievementTitleStage): AchievementTitleInfo {
const infiniteStartCount = lastFiniteStage.startCount + lastFiniteStage.clearsToNext;
const completedAfterInfiniteStart = Math.max(0, completedLevelCount - infiniteStartCount);
const currentInfiniteLevel = Math.floor(completedAfterInfiniteStart / INFINITE_ACHIEVEMENT_TITLE.clearsToNext) + 1;
const currentStageStartCount = infiniteStartCount + (currentInfiniteLevel - 1) * INFINITE_ACHIEVEMENT_TITLE.clearsToNext;
const nextStage: AchievementTitleStage = {
titleText: `${INFINITE_ACHIEVEMENT_TITLE.levelNamePrefix}${currentInfiniteLevel + 1}`,
clearsToNext: INFINITE_ACHIEVEMENT_TITLE.clearsToNext,
startCount: currentStageStartCount + INFINITE_ACHIEVEMENT_TITLE.clearsToNext
};
return AchievementTitleManager.createTitleInfo(
completedLevelCount,
{
titleText: `${INFINITE_ACHIEVEMENT_TITLE.levelNamePrefix}${currentInfiniteLevel}`,
clearsToNext: INFINITE_ACHIEVEMENT_TITLE.clearsToNext,
startCount: currentStageStartCount
},
nextStage
);
}
private static createTitleInfo(completedLevelCount: number, currentStage: AchievementTitleStage, nextStage: AchievementTitleStage): AchievementTitleInfo {
const interval = Math.max(1, nextStage.startCount - currentStage.startCount);
const completedInCurrentTitle = Math.max(0, completedLevelCount - currentStage.startCount);
const remainingToNextTitle = Math.max(0, nextStage.startCount - completedLevelCount);
const nextTitleProgress = Math.max(0, Math.min(1, completedInCurrentTitle / interval));
return {
titleText: currentStage.titleText,
nextTitleText: nextStage.titleText,
nextTitleProgress,
progressText: `还差${remainingToNextTitle}题获得${nextStage.titleText}`,
completedLevelCount,
currentTitleStartCount: currentStage.startCount,
nextTitleRequiredCount: nextStage.startCount,
remainingToNextTitle
};
}
}

View File

@@ -0,0 +1,9 @@
{
"ver": "4.0.24",
"importer": "typescript",
"imported": true,
"uuid": "a97f1641-1123-4458-9fb5-3b3f74e314a9",
"files": [],
"subMetas": {},
"userData": {}
}

View File

@@ -15,6 +15,8 @@ export class AuthManager {
private _isLoggedIn: boolean = false;
/** 服务端返回的已完成关卡 ID登录后暂存等 LevelDataManager 就绪后同步) */
private _completedLevelIds: string[] = [];
/** 服务端返回的已完成关卡数量,用于称号体系计算 */
private _completedLevelCount: number = 0;
static get instance(): AuthManager {
if (!this._instance) {
@@ -37,6 +39,14 @@ export class AuthManager {
return this._completedLevelIds;
}
get completedLevelCount(): number {
return this._completedLevelCount;
}
addCompletedLevelCount(delta: number = 1): void {
this._completedLevelCount = Math.max(0, this._completedLevelCount + delta);
}
/**
* 初始化认证:尝试恢复 token 或执行微信登录
*/
@@ -109,8 +119,9 @@ export class AuthManager {
this._isLoggedIn = true;
StorageManager.setStamina(gameData.user.stamina);
this._completedLevelIds = gameData.completedLevelIds;
this._completedLevelCount = this._resolveCompletedLevelCount(gameData);
console.log(`[AuthManager] Token 验证成功,体力: ${gameData.user.stamina.current}/${gameData.user.stamina.max},已完成: ${this._completedLevelIds.length}`);
console.log(`[AuthManager] Token 验证成功,体力: ${gameData.user.stamina.current}/${gameData.user.stamina.max},已完成: ${this._completedLevelCount}`);
return true;
}
@@ -121,6 +132,7 @@ export class AuthManager {
const gameData = await this._fetchGameData();
if (gameData) {
this._completedLevelIds = gameData.completedLevelIds;
this._completedLevelCount = this._resolveCompletedLevelCount(gameData);
StorageManager.setStamina(gameData.user.stamina);
}
}
@@ -140,4 +152,8 @@ export class AuthManager {
return null;
}
}
private _resolveCompletedLevelCount(gameData: GameData): number {
return gameData.completedLevelCount ?? gameData.completedLevelIds.length;
}
}