资源加载逻辑修改
All checks were successful
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 1m16s
All checks were successful
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 1m16s
This commit is contained in:
parent
13bde0b065
commit
9ad38a43b5
@ -28,13 +28,6 @@ export class SysGift extends Component {
|
|||||||
|
|
||||||
onLoad(): void {
|
onLoad(): void {
|
||||||
this.hideAll();
|
this.hideAll();
|
||||||
let sp_win = this.info.getChildByName("sysgift_win")
|
|
||||||
|
|
||||||
|
|
||||||
sp_win.getComponent(LocalizedSprite).fetchRender();
|
|
||||||
let scale = 116 / sp_win.getComponent(Sprite).spriteFrame.width;
|
|
||||||
sp_win.setScale(scale, scale, scale);
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
hideAll() {
|
hideAll() {
|
||||||
@ -53,9 +46,10 @@ export class SysGift extends Component {
|
|||||||
|
|
||||||
let txt_spin_num = this.info.getChildByName("count")
|
let txt_spin_num = this.info.getChildByName("count")
|
||||||
txt_spin_num.getComponent(Label).string = (frb.Ongoing.Frn.toLocaleString())
|
txt_spin_num.getComponent(Label).string = (frb.Ongoing.Frn.toLocaleString())
|
||||||
|
let sp_win = this.info.getChildByName("sysgift_win")
|
||||||
let txt_win = this.info.getChildByName("win")
|
let txt_win = this.info.getChildByName("win")
|
||||||
|
let scale = 116 / sp_win.getComponent(Sprite).spriteFrame.width;
|
||||||
|
sp_win.setScale(scale, scale, scale);
|
||||||
|
|
||||||
let num = Math.round(frb.Ongoing.Fra * 100 + 1e-6) / 100;
|
let num = Math.round(frb.Ongoing.Fra * 100 + 1e-6) / 100;
|
||||||
txt_win.getComponent(Label).string = num.toLocaleString('en-US', {
|
txt_win.getComponent(Label).string = num.toLocaleString('en-US', {
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@ -1,7 +1,7 @@
|
|||||||
import { _decorator, Component, SpriteFrame, Sprite, resources } from 'cc';
|
import { _decorator, Component, Sprite } from 'cc';
|
||||||
import { I18nManager } from '../manager/I18nManager';
|
import { I18nManager } from '../manager/I18nManager';
|
||||||
|
|
||||||
const { ccclass, property, executeInEditMode } = _decorator;
|
const { ccclass, property } = _decorator;
|
||||||
|
|
||||||
@ccclass('LocalizedSprite')
|
@ccclass('LocalizedSprite')
|
||||||
export class LocalizedSprite extends Component {
|
export class LocalizedSprite extends Component {
|
||||||
@ -15,90 +15,21 @@ export class LocalizedSprite extends Component {
|
|||||||
this.updateSprite();
|
this.updateSprite();
|
||||||
}
|
}
|
||||||
|
|
||||||
fetchRender() {
|
|
||||||
if (!this.sprite) {
|
|
||||||
this.sprite = this.getComponent(Sprite);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (this.sprite) {
|
|
||||||
this.updateSprite();
|
|
||||||
} else {
|
|
||||||
console.warn(`LocalizedSprite: No Sprite component found on node ${this.node.name}`);
|
|
||||||
this.loadDefaultSprite();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public updateSprite() {
|
public updateSprite() {
|
||||||
if (!this.sprite || !this.spriteName) return;
|
if (!this.sprite || !this.spriteName) return;
|
||||||
|
if (!I18nManager.instance.ready) return;
|
||||||
|
let cacheKey = `${I18nManager.instance.currentLanguage}_${this.spriteName}`;
|
||||||
|
let cachedFrame = I18nManager.instance.spriteFrameCache.get(cacheKey);
|
||||||
|
|
||||||
const currentLanguage = I18nManager.instance.currentLanguage;
|
|
||||||
const cacheKey = `${currentLanguage}_${this.spriteName}`;
|
|
||||||
|
|
||||||
// 从I18nManager获取缓存的SpriteFrame
|
|
||||||
const cachedFrame = I18nManager.instance.spriteFrameCache.get(cacheKey);
|
|
||||||
if (cachedFrame) {
|
if (cachedFrame) {
|
||||||
this.setNewSpriteFrame(cachedFrame);
|
this.sprite.spriteFrame = cachedFrame;
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
// 如果缓存中没有,从resources加载
|
|
||||||
const spritePath = `i18nSprite/${currentLanguage}/${this.spriteName}/spriteFrame`;
|
|
||||||
resources.load(spritePath, SpriteFrame, (err, spriteFrame) => {
|
|
||||||
if (err) {
|
|
||||||
console.warn(`Failed to load sprite: ${spritePath}`, err);
|
|
||||||
this.loadDefaultSprite();
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (spriteFrame) {
|
|
||||||
// 添加到I18nManager的缓存中
|
|
||||||
I18nManager.instance.spriteFrameCache.set(cacheKey, spriteFrame);
|
|
||||||
this.setNewSpriteFrame(spriteFrame);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
private loadDefaultSprite() {
|
|
||||||
const defaultPath = `i18nSprite/en/${this.spriteName}/spriteFrame`;
|
|
||||||
const cacheKey = `en_${this.spriteName}`;
|
|
||||||
|
|
||||||
// 从I18nManager获取默认语言的缓存
|
|
||||||
const cachedFrame = I18nManager.instance.spriteFrameCache.get(cacheKey);
|
|
||||||
if (cachedFrame) {
|
|
||||||
this.setNewSpriteFrame(cachedFrame);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
resources.load(defaultPath, SpriteFrame, (err, spriteFrame) => {
|
|
||||||
if (err) {
|
|
||||||
console.error('Failed to load default sprite:', err);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (spriteFrame) {
|
|
||||||
// 添加到I18nManager的缓存中
|
|
||||||
I18nManager.instance.spriteFrameCache.set(cacheKey, spriteFrame);
|
|
||||||
this.setNewSpriteFrame(spriteFrame);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
private setNewSpriteFrame(newFrame: SpriteFrame) {
|
|
||||||
if (this.sprite) {
|
|
||||||
this.sprite.spriteFrame = newFrame;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public setSpriteName(name: string) {
|
updateSpriteForPreload(language: string) {
|
||||||
this.spriteName = name;
|
this.sprite = this.getComponent(Sprite);
|
||||||
this.updateSprite();
|
let cacheKey = `${language}_${this.spriteName}`;
|
||||||
}
|
let cachedFrame = I18nManager.instance.spriteFrameCache.get(cacheKey);
|
||||||
|
this.sprite.spriteFrame = cachedFrame;
|
||||||
onDestroy() {
|
|
||||||
// 只清理当前组件的引用
|
|
||||||
if (this.sprite) {
|
|
||||||
this.sprite.spriteFrame = null;
|
|
||||||
}
|
|
||||||
this.sprite = null;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1,296 +1,236 @@
|
|||||||
import { _decorator, Component, Node, ProgressBar, Label, Button, view, VideoPlayer, UITransform, AssetManager, tween, ResolutionPolicy, game, director, Director, sys, macro, JsonAsset } from 'cc';
|
import { _decorator, Component, Node, ProgressBar, Label, UITransform, tween, JsonAsset } from 'cc';
|
||||||
import { callGameApi, getIsRB7, getLanguage, initReqAddr } from './comm';
|
import { callGameApi, getIsRB7, getLanguage, initReqAddr } from './comm';
|
||||||
import { GameDataManager } from './manager/GameDataManager';
|
import { DEBUG } from 'cc/env';
|
||||||
import { ResManager } from './manager/ResManager';
|
import { initErrorManager } from './manager/ErrorManager';
|
||||||
import { AudioManager } from './manager/AudioManager';
|
|
||||||
import { NodePoolManager } from './manager/NodePoolManager';
|
|
||||||
import { I18nManager } from './manager/I18nManager';
|
import { I18nManager } from './manager/I18nManager';
|
||||||
import { LocalizedSprite } from './i18n/LocalizedSprite';
|
import { LocalizedSprite } from './i18n/LocalizedSprite';
|
||||||
import { initErrorManager } from './manager/ErrorManager';
|
import { AudioManager } from './manager/AudioManager';
|
||||||
let { ccclass, property } = _decorator;
|
import { GameDataManager } from './manager/GameDataManager';
|
||||||
|
import { ResManager } from './manager/ResManager';
|
||||||
@ccclass('LoadingUI')
|
import { NodePoolManager } from './manager/NodePoolManager';
|
||||||
export class LoadingUI extends Component {
|
|
||||||
//test
|
|
||||||
@property(Node)
|
|
||||||
BG: Node = null;
|
|
||||||
|
|
||||||
@property(Node)
|
|
||||||
LoadingUINode: Node = null;
|
|
||||||
|
|
||||||
@property(ProgressBar)
|
|
||||||
progressBar: ProgressBar = null;
|
|
||||||
|
|
||||||
@property(Label)
|
|
||||||
progressLabel: Label = null;
|
|
||||||
|
|
||||||
@property(Label)
|
|
||||||
loadingTipLabel: Label = null;
|
|
||||||
|
|
||||||
@property(Label)
|
|
||||||
retryTipLabel: Label = null;
|
|
||||||
|
|
||||||
@property(Button)
|
|
||||||
startBtn: Button = null;
|
|
||||||
|
|
||||||
@property(Label)
|
|
||||||
startBtnLabel: Label = null;
|
|
||||||
|
|
||||||
@property(Node)
|
|
||||||
GameNode: Node = null;
|
|
||||||
|
|
||||||
@property(JsonAsset)
|
|
||||||
languageJson: JsonAsset = null;
|
|
||||||
|
|
||||||
private _networkComplete = false;
|
|
||||||
private _retryCount = 0;
|
|
||||||
private readonly MAX_RETRY = 5;
|
|
||||||
private INITIAL_PROGRESS = 0.3;
|
|
||||||
private _instanceGameNode = null;
|
|
||||||
|
|
||||||
|
|
||||||
// 新增动画
|
const { ccclass, property } = _decorator;
|
||||||
private maskUITransform: UITransform = null;
|
|
||||||
private lightNode: Node = null;
|
@ccclass('Loading')
|
||||||
|
export class Loading extends Component {
|
||||||
|
// UI组件
|
||||||
|
@property(Node) progressNode: Node = null;
|
||||||
|
@property(ProgressBar) progressBar: ProgressBar = null;
|
||||||
|
@property(Label) progressLabel: Label = null;
|
||||||
|
@property(Label) loadingLabel: Label = null;
|
||||||
|
@property(Node) maskSpineNode: Node = null;
|
||||||
|
@property(Node) lightSpineNode: Node = null;
|
||||||
|
@property(Node) startBtnNode: Node = null;
|
||||||
|
@property(Node) LoadingUINode: Node = null;
|
||||||
|
@property(Node) rb7Logo: Node = null;
|
||||||
|
@property(JsonAsset) languageJson: JsonAsset = null;
|
||||||
|
|
||||||
|
// 加载状态
|
||||||
|
private isNetworkReady = false;
|
||||||
|
private readonly PROGRESS_ANIMATION_DURATION = 0.3;
|
||||||
|
|
||||||
|
// 进度条阶段
|
||||||
|
private readonly PROGRESS_INIT = 0.2; // 初始化完成
|
||||||
|
private readonly PROGRESS_NETWORK = 0.5; // 网络请求完成
|
||||||
|
private readonly PROGRESS_RESOURCE = 0.9; // 资源加载完成
|
||||||
|
private readonly PROGRESS_COMPLETE = 1.0; // 完全加载完成
|
||||||
|
|
||||||
|
// 游戏节点
|
||||||
|
private gameContainer: Node = null;
|
||||||
|
private gameNode: Node = null;
|
||||||
|
|
||||||
|
|
||||||
protected async onLoad() {
|
protected async onLoad() {
|
||||||
// initErrorManager();
|
initReqAddr();
|
||||||
// 初始显示状态
|
let language = getLanguage();
|
||||||
this.initUI();
|
|
||||||
this.LoadingUINode.active = false;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
if (getLanguage() == 'zh') {
|
||||||
|
this.node.getChildByPath("Mask/LoadingUINode/logo_zh").active = true;
|
||||||
|
this.node.getChildByPath("Mask/LoadingUINode/logo_en").active = false;
|
||||||
|
} else {
|
||||||
|
this.node.getChildByPath("Mask/LoadingUINode/logo_zh").active = false;
|
||||||
|
this.node.getChildByPath("Mask/LoadingUINode/logo_en").active = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
initErrorManager();
|
||||||
|
await I18nManager.instance.ensureI18nSprite(language, '2');
|
||||||
|
this.node.getChildByPath('Mask/LoadingUINode/msg').getComponent(LocalizedSprite).updateSpriteForPreload(language);
|
||||||
|
this.node.getChildByPath('Mask/LoadingUINode/msg').active = true;
|
||||||
|
|
||||||
|
await I18nManager.instance.init(language, this.languageJson);
|
||||||
|
I18nManager.instance.updateSceneRenderers();
|
||||||
|
|
||||||
|
this.initializeUI();
|
||||||
|
// 初始化完成,进度条到20%
|
||||||
|
this.updateProgress(this.PROGRESS_INIT);
|
||||||
|
|
||||||
async start() {
|
|
||||||
try {
|
try {
|
||||||
initReqAddr();
|
await this.initializeSystem();
|
||||||
this.node.getChildByName('Logo').active = getIsRB7();
|
|
||||||
await I18nManager.instance.init(getLanguage(), this.languageJson);
|
|
||||||
I18nManager.instance.updateSceneRenderers();
|
|
||||||
// this.LoadingUINode.getChildByName("bg").getComponent(LocalizedSprite).fetchRender();
|
|
||||||
this.LoadingUINode.active = true;
|
|
||||||
// 更新进度条到 0.4
|
|
||||||
this.updateProgress(0.4);
|
|
||||||
|
|
||||||
AudioManager.instance.init();
|
AudioManager.instance.init();
|
||||||
game.setFrameRate(61);
|
this.updateLoadingText('AID_LOADING');
|
||||||
// this.checkStartLoading();
|
|
||||||
// 开始网络请求
|
|
||||||
this.initNetwork();
|
|
||||||
|
|
||||||
|
// 延迟一下让用户看到进度条开始
|
||||||
|
this.scheduleOnce(() => {
|
||||||
|
this.startNetworkLoading();
|
||||||
|
}, 0.2);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error('Network initialization failed:', error);
|
console.error('Network initialization failed:', error);
|
||||||
this.handleError(error);
|
// this.handleError(error);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
private initUI() {
|
|
||||||
this.BG.active = true;
|
|
||||||
this.startBtn.node.active = false;
|
|
||||||
this.maskUITransform = this.LoadingUINode.getChildByName('mask').getComponent(UITransform);
|
|
||||||
this.lightNode = this.LoadingUINode.getChildByName('light');
|
|
||||||
this.updateProgress(this.INITIAL_PROGRESS);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private async initNetwork() {
|
/** 初始化系统 */
|
||||||
|
private async initializeSystem() {
|
||||||
|
this.rb7Logo.active = getIsRB7();
|
||||||
|
// if (DEBUG) {
|
||||||
|
// await getTestToken('nova006', 'faketrans');
|
||||||
|
// }
|
||||||
|
}
|
||||||
|
|
||||||
|
/** 初始化UI */
|
||||||
|
private initializeUI() {
|
||||||
|
this.startBtnNode.active = false;
|
||||||
|
this.gameContainer = this.node.getChildByPath('Mask/GameNode')
|
||||||
|
|
||||||
|
// 初始化进度条为0
|
||||||
|
this.updateProgress(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
/** 开始网络加载 */
|
||||||
|
private async startNetworkLoading() {
|
||||||
|
this.updateLoadingText('AID_LOADING');
|
||||||
|
|
||||||
try {
|
try {
|
||||||
// 更新进度条到 0.6
|
|
||||||
this.updateProgress(0.6);
|
|
||||||
this.loadingTipLabel.string = I18nManager.instance.t('AID_LOADING');
|
|
||||||
this.retryTipLabel.string = '';
|
|
||||||
let gameInfo = await callGameApi("gameinfo", {});
|
let gameInfo = await callGameApi("gameinfo", {});
|
||||||
if (!gameInfo) throw new Error('Get game info failed');
|
|
||||||
GameDataManager.instance.gameInfo = gameInfo;
|
GameDataManager.instance.gameInfo = gameInfo;
|
||||||
|
this.isNetworkReady = true;
|
||||||
|
|
||||||
// 更新进度条到 0.8
|
// 网络请求完成,进度条到50%
|
||||||
this.updateProgress(0.8);
|
this.updateProgress(this.PROGRESS_NETWORK);
|
||||||
|
|
||||||
this._networkComplete = true;
|
// 稍微延迟一下让用户看到进度变化
|
||||||
|
this.scheduleOnce(() => {
|
||||||
await GameDataManager.instance.preloadFrameTypeCache();
|
this.startResourceLoading();
|
||||||
await GameDataManager.instance.preloadSymbolCache();
|
}, 0.3);
|
||||||
this.checkStartLoading();
|
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error('Network initialization failed:', error);
|
|
||||||
this.handleError(error);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private checkStartLoading() {
|
/** 开始资源加载 */
|
||||||
if (this._networkComplete) {
|
private async startResourceLoading() {
|
||||||
this.LoadingUINode.active = true;
|
if (!this.isNetworkReady) return;
|
||||||
this.startLoadingGameBundle();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private async startLoadingGameBundle() {
|
// this.updateLoadingText('Loading More...');
|
||||||
try {
|
this.startBtnNode.active = false;
|
||||||
// 显示加载UI
|
|
||||||
this.loadingTipLabel.string = I18nManager.instance.t('AID_LOADING');
|
|
||||||
this.retryTipLabel.string = '';
|
|
||||||
this.startBtn.node.active = false;
|
|
||||||
|
|
||||||
// 从 0.8 开始加载
|
this.gameNode = await ResManager.instance.loadPrefabFromBundle(
|
||||||
let startProgress = 0.8;
|
'Game',
|
||||||
|
'SlotScene',
|
||||||
// 使用新的合并函数加载 Bundle 和预制体
|
(finished: number, total: number) => {
|
||||||
this._instanceGameNode = await ResManager.instance.loadPrefabFromBundle(
|
if (total > 0) {
|
||||||
'Game',
|
// 资源加载进度从50%到90%
|
||||||
'prefabs/SlotScene',
|
const resourceProgress = finished / total;
|
||||||
(finished: number, total: number) => {
|
const currentProgress = this.PROGRESS_NETWORK +
|
||||||
if (total <= 0) return;
|
(resourceProgress * (this.PROGRESS_RESOURCE - this.PROGRESS_NETWORK));
|
||||||
let bundleProgress = finished / total;
|
this.updateProgress(currentProgress);
|
||||||
// 将加载进度映射到 0.8-1 的范围
|
|
||||||
let mappedProgress = startProgress + (bundleProgress * (1 - startProgress));
|
|
||||||
this.updateProgress(mappedProgress);
|
|
||||||
}
|
}
|
||||||
);
|
}
|
||||||
|
);
|
||||||
|
|
||||||
this.updateProgress(1);
|
// 资源加载完成,进度条到90%
|
||||||
this.onLoadComplete();
|
this.updateProgress(this.PROGRESS_RESOURCE);
|
||||||
} catch (error) {
|
|
||||||
console.error('Loading error:', error);
|
// 延迟一下然后完成最后的10%
|
||||||
this.handleError(error);
|
this.scheduleOnce(() => {
|
||||||
}
|
this.finishLoading();
|
||||||
|
}, 0.2);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** 完成加载 */
|
||||||
|
private finishLoading() {
|
||||||
|
// this.updateLoadingText('Loading More...');
|
||||||
|
|
||||||
|
// 最后10%快速完成
|
||||||
|
this.updateProgress(this.PROGRESS_COMPLETE);
|
||||||
|
|
||||||
|
// 0.5秒后显示开始按钮
|
||||||
|
this.scheduleOnce(() => {
|
||||||
|
this.onLoadComplete();
|
||||||
|
}, 0.5);
|
||||||
|
}
|
||||||
|
|
||||||
|
/** 更新进度条 */
|
||||||
private updateProgress(progress: number) {
|
private updateProgress(progress: number) {
|
||||||
// 使用 tween 使进度条更新更平滑
|
|
||||||
tween(this.progressBar)
|
tween(this.progressBar)
|
||||||
.to(0.2, { progress: progress }, {
|
.to(this.PROGRESS_ANIMATION_DURATION, { progress }, {
|
||||||
easing: 'smooth',
|
easing: 'smooth',
|
||||||
onUpdate: (target: any, ratio: number) => {
|
onUpdate: (target: any) => {
|
||||||
this.progressLabel.string = `${Math.floor(target.progress * 100)}%`;
|
const currentProgress = target.progress;
|
||||||
this.maskUITransform.width = target.progress * 494;
|
this.progressLabel.string = `${Math.floor(currentProgress * 100)}%`;
|
||||||
this.lightNode.setPosition(target.progress * 496 - 274, -612, 0);
|
this.maskSpineNode.getComponent(UITransform).setContentSize(currentProgress * 509, 100);
|
||||||
|
this.lightSpineNode.setPosition(currentProgress * 509 - 278, -612, 0)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.start();
|
.start();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/** 更新加载文本 */
|
||||||
|
private updateLoadingText(key: string) {
|
||||||
|
this.loadingLabel.string = `${I18nManager.instance.t(key)}...`;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** 加载完成 */
|
||||||
private onLoadComplete() {
|
private onLoadComplete() {
|
||||||
// 开始游戏
|
this.hideProgressUI();
|
||||||
this.scheduleOnce(() => {
|
this.showStartButton();
|
||||||
this.loadingTipLabel.string = '';
|
|
||||||
this.retryTipLabel.string = '';
|
|
||||||
this.startBtn.node.active = true;
|
|
||||||
this.startBtnLabel.string = I18nManager.instance.t('AID_GET_STARTED');
|
|
||||||
this.progressBar.node.active = false;
|
|
||||||
this.progressLabel.node.active = false;
|
|
||||||
|
|
||||||
this.maskUITransform.node.active = false;
|
|
||||||
this.lightNode.active = false;
|
|
||||||
}, 0.3);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private handleError(error: Error) {
|
/** 隐藏进度UI */
|
||||||
this._retryCount++;
|
private hideProgressUI() {
|
||||||
this.loadingTipLabel.string = '';
|
this.loadingLabel.string = '';
|
||||||
if (this._retryCount <= this.MAX_RETRY) {
|
this.progressBar.node.active = false;
|
||||||
// 自动重试
|
this.progressLabel.node.active = false;
|
||||||
switch (this._retryCount) {
|
this.maskSpineNode.active = false;
|
||||||
case 1:
|
this.lightSpineNode.active = false;
|
||||||
this.retryTipLabel.string = I18nManager.instance.t('AID_NETWORK_RETRY_1');
|
|
||||||
break
|
|
||||||
case 2:
|
|
||||||
this.retryTipLabel.string = I18nManager.instance.t('AID_NETWORK_RETRY_2');
|
|
||||||
break
|
|
||||||
case 3:
|
|
||||||
this.retryTipLabel.string = I18nManager.instance.t('AID_NETWORK_RETRY_3');
|
|
||||||
break
|
|
||||||
case 4:
|
|
||||||
this.retryTipLabel.string = I18nManager.instance.t('AID_NETWORK_RETRY_4');
|
|
||||||
break
|
|
||||||
case 5:
|
|
||||||
this.retryTipLabel.string = I18nManager.instance.t('AID_NETWORK_RETRY_5');
|
|
||||||
break
|
|
||||||
|
|
||||||
}
|
|
||||||
this.scheduleOnce(() => {
|
|
||||||
if (!this._networkComplete) {
|
|
||||||
this.initNetwork();
|
|
||||||
} else {
|
|
||||||
this.startLoadingGameBundle();
|
|
||||||
}
|
|
||||||
}, 2);
|
|
||||||
} else {
|
|
||||||
// 显示重试按钮
|
|
||||||
this.loadingTipLabel.string = I18nManager.instance.t('AID_LOADING');
|
|
||||||
this.retryTipLabel.string = '';
|
|
||||||
this.startBtn.node.active = true;
|
|
||||||
this.progressBar.node.active = false;
|
|
||||||
this.progressLabel.node.active = false;
|
|
||||||
|
|
||||||
|
|
||||||
this.maskUITransform.node.active = false;
|
|
||||||
this.lightNode.active = false;
|
|
||||||
|
|
||||||
this.startBtnLabel.string = I18nManager.instance.t('AID_ERROR_RETRY_BUTTON');
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** 显示开始按钮 */
|
||||||
|
private showStartButton() {
|
||||||
|
this.startBtnNode.active = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/** 开始游戏 */
|
||||||
|
// private startGame() {
|
||||||
|
// if (!this.gameContainer) {
|
||||||
|
// console.error('Game container not found');
|
||||||
|
// return;
|
||||||
|
// }
|
||||||
|
|
||||||
|
// this.gameContainer.addChild(this.gameNode);
|
||||||
|
// // this.node.destroy();
|
||||||
|
// }
|
||||||
|
|
||||||
|
/** 按钮点击事件 */
|
||||||
onStartBtnClick() {
|
onStartBtnClick() {
|
||||||
if (this.startBtnLabel.string === I18nManager.instance.t('AID_ERROR_RETRY_BUTTON')) {
|
this.rb7Logo.active = false;
|
||||||
// 重试逻辑
|
// 添加到场景
|
||||||
this._retryCount = 0;
|
this.gameContainer.addChild(this.gameNode);
|
||||||
this.startBtn.node.active = false;
|
// 隐藏加载界面
|
||||||
this.progressBar.node.active = true;
|
this.LoadingUINode.destroy();
|
||||||
this.progressLabel.node.active = true;
|
|
||||||
|
|
||||||
|
|
||||||
this.maskUITransform.node.active = true;
|
|
||||||
this.lightNode.active = true;
|
|
||||||
|
|
||||||
if (!this._networkComplete) {
|
|
||||||
this.initNetwork();
|
|
||||||
} else {
|
|
||||||
this.startLoadingGameBundle();
|
|
||||||
}
|
|
||||||
} else if (this.startBtnLabel.string === I18nManager.instance.t('AID_GET_STARTED')) {
|
|
||||||
this.node.getChildByName('Logo').active = false;
|
|
||||||
// 确保 GameNode 存在
|
|
||||||
if (!this.GameNode) {
|
|
||||||
throw new Error('GameNode is not set');
|
|
||||||
}
|
|
||||||
// 添加到场景
|
|
||||||
this.GameNode.addChild(this._instanceGameNode);
|
|
||||||
// 隐藏加载界面
|
|
||||||
this.LoadingUINode.destroy();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
onDestroy() {
|
onDestroy() {
|
||||||
this.unscheduleAllCallbacks();
|
this.unscheduleAllCallbacks();
|
||||||
tween(this.progressBar).stop();
|
tween(this.progressBar).stop();
|
||||||
AudioManager.instance.destroy();
|
|
||||||
NodePoolManager.instance.clearAll();
|
NodePoolManager.instance.clearAll();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// UNKNOWN = 0, // 未知平台
|
|
||||||
// WINDOWS = 1, // Windows
|
|
||||||
// LINUX = 2, // Linux
|
|
||||||
// MACOS = 3, // macOS
|
|
||||||
// ANDROID = 4, // Android
|
|
||||||
// IOS = 5, // iOS
|
|
||||||
// MOBILE_BROWSER = 6, // 移动端浏览器
|
|
||||||
// DESKTOP_BROWSER = 7,// 桌面端浏览器
|
|
||||||
// WECHAT_GAME = 8, // 微信小游戏
|
|
||||||
// BAIDU_MINI_GAME = 9,// 百度小游戏
|
|
||||||
// XIAOMI_QUICK_GAME = 10,// 小米快游戏
|
|
||||||
// ALIPAY_MINI_GAME = 11, // 支付宝小游戏
|
|
||||||
// BYTEDANCE_MINI_GAME = 12,// 字节跳动小游戏
|
|
||||||
// OPPO_MINI_GAME = 13,// OPPO小游戏
|
|
||||||
// VIVO_MINI_GAME = 14,// vivo小游戏
|
|
||||||
// HUAWEI_QUICK_GAME = 15,// 华为快游戏
|
|
||||||
// COCOSPLAY = 16, // Cocos Play
|
|
||||||
// LINKSURE_MINI_GAME = 17,// 连尚小游戏
|
|
||||||
// QTT_MINI_GAME = 18 // 趣头条小游戏
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,148 +1,165 @@
|
|||||||
import { resources, JsonAsset, director, SpriteFrame, Sprite, Node, SpriteAtlas, sp } from 'cc';
|
import { resources, JsonAsset, director, SpriteFrame, SpriteAtlas, sp } from 'cc';
|
||||||
import { LocalizedSprite } from '../i18n/LocalizedSprite';
|
|
||||||
|
|
||||||
export class I18nManager {
|
export class I18nManager {
|
||||||
private static _instance: I18nManager = null;
|
|
||||||
|
private static _instance: I18nManager;
|
||||||
spriteFrameCache: Map<string, SpriteFrame> = new Map();
|
spriteFrameCache: Map<string, SpriteFrame> = new Map();
|
||||||
spineCache: Map<string, sp.SkeletonData> = new Map();
|
spineCache: Map<string, sp.SkeletonData> = new Map();
|
||||||
|
_sfTasks = new Map<string, Promise<SpriteFrame>>();
|
||||||
languageData: Record<string, any> = {};
|
languageData: Record<string, any> = {};
|
||||||
currentLanguage: string = 'en';
|
currentLanguage: string = 'en';
|
||||||
ready: boolean = false;
|
ready: boolean = false;
|
||||||
|
|
||||||
static get instance() {
|
static get instance() {
|
||||||
if (this._instance) {
|
return this._instance || (this._instance = new I18nManager());
|
||||||
return this._instance;
|
|
||||||
}
|
|
||||||
this._instance = new I18nManager();
|
|
||||||
return this._instance;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private constructor() { }
|
private constructor() { }
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// yield/await 风格:谁都可以 await,且只加载一次
|
||||||
|
ensureI18nSprite(lang: string, name: string): Promise<SpriteFrame> {
|
||||||
|
const key = `${lang}_${name}`;
|
||||||
|
const path = `i18nSprite/${lang}/${name}/spriteFrame`;
|
||||||
|
|
||||||
|
const cached = this.spriteFrameCache.get(key);
|
||||||
|
if (cached) return Promise.resolve(cached);
|
||||||
|
|
||||||
|
const pending = this._sfTasks.get(key);
|
||||||
|
if (pending) return pending;
|
||||||
|
|
||||||
|
const task = new Promise<SpriteFrame>((resolve, reject) => {
|
||||||
|
resources.load(path, SpriteFrame, (err, sf) => {
|
||||||
|
this._sfTasks.delete(key);
|
||||||
|
if (err || !sf) return reject(err);
|
||||||
|
this.spriteFrameCache.set(key, sf);
|
||||||
|
resolve(sf);
|
||||||
|
});
|
||||||
|
});
|
||||||
|
this._sfTasks.set(key, task);
|
||||||
|
return task;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 初始化语言管理器
|
* 初始化国际化管理器
|
||||||
* @param language 初始语言
|
* @param language 初始语言代码
|
||||||
|
* @param languageJson 语言数据JSON资源
|
||||||
*/
|
*/
|
||||||
public async init(language: string = 'en', languageJson: JsonAsset): Promise<void> {
|
public async init(language: string = 'en', languageJson: JsonAsset = null): Promise<void> {
|
||||||
this.currentLanguage = language;
|
this.currentLanguage = language;
|
||||||
try {
|
try {
|
||||||
this.languageData = languageJson.json;
|
if (languageJson) {
|
||||||
|
this.languageData = languageJson.json;
|
||||||
|
}
|
||||||
|
|
||||||
// 预加载并缓存图片资源
|
// 预加载资源(目前资源列表为空,可根据需要添加)
|
||||||
await this.preloadSpriteFrames();
|
let okSprite = await this.preloadAssets('spriteFrame', [
|
||||||
await this.preloadSpriteFrameAltas();
|
'2',
|
||||||
await this.preloadSpineAssets(); // 新增预加载 spine 资源
|
'3',
|
||||||
this.ready = true;
|
'4',
|
||||||
|
'5',
|
||||||
|
'6',
|
||||||
|
'7',
|
||||||
|
'8',
|
||||||
|
'9',
|
||||||
|
'10',
|
||||||
|
'11',
|
||||||
|
'12',
|
||||||
|
'13',
|
||||||
|
'14',
|
||||||
|
'15',
|
||||||
|
'16',
|
||||||
|
'17',
|
||||||
|
'18',
|
||||||
|
'19',
|
||||||
|
'20',
|
||||||
|
'21',
|
||||||
|
'22',
|
||||||
|
'23',
|
||||||
|
'24',
|
||||||
|
'25',
|
||||||
|
'26',
|
||||||
|
'27',
|
||||||
|
'29',
|
||||||
|
'30',
|
||||||
|
'98',
|
||||||
|
'99',
|
||||||
|
'Buy_5',
|
||||||
|
'sysgift_completed',
|
||||||
|
'sysgift_continue',
|
||||||
|
'sysgift_fbs',
|
||||||
|
'sysgift_info_fbs',
|
||||||
|
'sysgift_received',
|
||||||
|
'sysgift_symbols',
|
||||||
|
'sysgift_total',
|
||||||
|
'sysgift_win',
|
||||||
|
]);
|
||||||
|
let okAtlas = await this.preloadAssets('atlas', []);
|
||||||
|
let okSpine = await this.preloadAssets('spine', []);
|
||||||
|
|
||||||
|
this.ready = okSprite && okAtlas && okSpine;
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
|
console.error('I18nManager init failed:', error);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
getIsReady() {
|
|
||||||
return this.ready;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 预加载并缓存图片资源
|
* 预加载指定类型的资源
|
||||||
|
* @param type 资源类型
|
||||||
|
* @param names 资源名称列表
|
||||||
*/
|
*/
|
||||||
private async preloadSpriteFrames(): Promise<void> {
|
private async preloadAssets(type: 'spriteFrame' | 'atlas' | 'spine', names: string[]): Promise<boolean> {
|
||||||
const imageNames = [
|
let results = await Promise.all(names.map(name => this.loadAsset(type, name)));
|
||||||
'loadingBg',
|
return results.every(ok => ok);
|
||||||
'sysgift_completed',
|
|
||||||
'sysgift_continue',
|
|
||||||
'sysgift_fbs',
|
|
||||||
'sysgift_info_fbs',
|
|
||||||
'sysgift_received',
|
|
||||||
'sysgift_symbols',
|
|
||||||
'sysgift_total',
|
|
||||||
'sysgift_win',
|
|
||||||
];
|
|
||||||
|
|
||||||
for (const name of imageNames) {
|
|
||||||
const path = `i18nSprite/${this.currentLanguage}/${name}/spriteFrame`;
|
|
||||||
const cacheKey = `${this.currentLanguage}_${name}`;
|
|
||||||
|
|
||||||
if (!this.spriteFrameCache.has(cacheKey)) {
|
|
||||||
await new Promise<void>((resolve) => {
|
|
||||||
resources.load(path, SpriteFrame, (err, spriteFrame) => {
|
|
||||||
if (!err && spriteFrame) {
|
|
||||||
this.spriteFrameCache.set(cacheKey, spriteFrame);
|
|
||||||
}
|
|
||||||
resolve();
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private async preloadSpriteFrameAltas(): Promise<void> {
|
/**
|
||||||
const altasNames = [
|
* 加载单个资源
|
||||||
`FreeSpinINOUT_${this.currentLanguage}`,
|
* @param type 资源类型
|
||||||
`BuyFeature_${this.currentLanguage}`,
|
* @param name 资源名称
|
||||||
`Others_${this.currentLanguage}`,
|
*/
|
||||||
`SymbolsInfo_${this.currentLanguage}`,
|
private loadAsset(type: 'spriteFrame' | 'atlas' | 'spine', name: string): Promise<boolean> {
|
||||||
]
|
return new Promise(resolve => {
|
||||||
|
let cacheKey = `${this.currentLanguage}_${name}`;
|
||||||
|
|
||||||
for (const altasName of altasNames) {
|
if (type === 'spriteFrame') {
|
||||||
const atlasPath = `i18nSprite/${this.currentLanguage}/${altasName}`;
|
let path = `i18nSprite/${this.currentLanguage}/${name}/spriteFrame`;
|
||||||
// 加载图集并缓存其中的多个 SpriteFrame
|
resources.load(path, SpriteFrame, (err, asset) => {
|
||||||
await new Promise<void>((resolve) => {
|
if (!err && asset) {
|
||||||
resources.load(atlasPath, SpriteAtlas, (err, atlas) => {
|
this.spriteFrameCache.set(cacheKey, asset);
|
||||||
if (!err && atlas) {
|
resolve(true);
|
||||||
const spriteFrames = atlas.getSpriteFrames();
|
} else {
|
||||||
spriteFrames.forEach((frame, index) => {
|
console.warn(`[i18n] spriteFrame load failed: ${path}`, err?.message || err);
|
||||||
let name = frame.name;
|
resolve(false);
|
||||||
const cacheKey = `${this.currentLanguage}_${name}`;
|
|
||||||
this.spriteFrameCache.set(cacheKey, frame);
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
resolve();
|
|
||||||
});
|
});
|
||||||
});
|
} else if (type === 'atlas') {
|
||||||
}
|
let path = `i18nSprite/${this.currentLanguage}/${name}`;
|
||||||
}
|
resources.load(path, SpriteAtlas, (err, atlas) => {
|
||||||
|
if (!err && atlas) {
|
||||||
// 添加预加载 Spine 资源的方法
|
atlas.getSpriteFrames().forEach(frame => {
|
||||||
private async preloadSpineAssets(): Promise<void> {
|
this.spriteFrameCache.set(`${this.currentLanguage}_${frame.name}`, frame);
|
||||||
const spineNames = [
|
});
|
||||||
`WinWinWin_${this.currentLanguage}`,
|
resolve(true);
|
||||||
];
|
} else {
|
||||||
|
console.warn(`[i18n] atlas load failed: ${path}`, err?.message || err);
|
||||||
for (const name of spineNames) {
|
resolve(false);
|
||||||
const path = `i18nSprite/${this.currentLanguage}/${name}`;
|
}
|
||||||
const cacheKey = `${this.currentLanguage}_${name}`;
|
});
|
||||||
|
} else if (type === 'spine') {
|
||||||
if (!this.spineCache.has(cacheKey)) {
|
let path = `i18nSpine/${this.currentLanguage}/${name}`;
|
||||||
await new Promise<void>((resolve) => {
|
resources.load(path, sp.SkeletonData, (err, asset) => {
|
||||||
resources.load(path, sp.SkeletonData, (err, spineData) => {
|
if (!err && asset) {
|
||||||
if (!err && spineData) {
|
this.spineCache.set(cacheKey, asset);
|
||||||
this.spineCache.set(cacheKey, spineData);
|
resolve(true);
|
||||||
}
|
} else {
|
||||||
resolve();
|
console.warn(`[i18n] spine load failed: ${path}`, err?.message || err);
|
||||||
});
|
resolve(false);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
});
|
||||||
}
|
|
||||||
|
|
||||||
setSpriteFrame(node: Node, name: string) {
|
|
||||||
// 先尝试从缓存获取
|
|
||||||
const cacheKey = `${this.currentLanguage}_${name}`;
|
|
||||||
const cachedFrame = this.spriteFrameCache.get(cacheKey);
|
|
||||||
|
|
||||||
if (cachedFrame) {
|
|
||||||
const sprite = node.getComponent(Sprite);
|
|
||||||
if (sprite) {
|
|
||||||
sprite.spriteFrame = cachedFrame;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 如果缓存中没有,则使用原有逻辑
|
|
||||||
let spriteNode = node.getComponent(LocalizedSprite);
|
|
||||||
if (spriteNode) {
|
|
||||||
spriteNode.setSpriteName(name);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -159,17 +176,21 @@ export class I18nManager {
|
|||||||
/**
|
/**
|
||||||
* 翻译文本
|
* 翻译文本
|
||||||
* @param key 翻译键
|
* @param key 翻译键
|
||||||
|
* @returns 翻译后的文本,如果找不到则返回键本身
|
||||||
*/
|
*/
|
||||||
public t(key: string): string {
|
public t(key: string): string {
|
||||||
const translation = this.languageData[this.currentLanguage]?.[key];
|
return this.languageData[this.currentLanguage]?.[key] || key;
|
||||||
if (!translation) {
|
}
|
||||||
return key; // Return the key itself if translation is not found
|
|
||||||
}
|
public getSpriteFrame(spriteName: string): SpriteFrame {
|
||||||
return translation;
|
let cacheKey = `${this.currentLanguage}_${spriteName}`;
|
||||||
|
let cachedFrame = this.spriteFrameCache.get(cacheKey);
|
||||||
|
return cachedFrame;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 更新场景中的本地化组件
|
* 更新场景中的所有本地化组件
|
||||||
|
* 在语言切换时调用,刷新所有本地化文本和资源
|
||||||
*/
|
*/
|
||||||
public updateSceneRenderers(): void {
|
public updateSceneRenderers(): void {
|
||||||
if (!this.ready) {
|
if (!this.ready) {
|
||||||
@ -178,41 +199,23 @@ export class I18nManager {
|
|||||||
}
|
}
|
||||||
|
|
||||||
let scene = director.getScene();
|
let scene = director.getScene();
|
||||||
if (!scene || !scene.isValid) return;
|
if (!scene?.isValid) return;
|
||||||
|
|
||||||
const rootNodes = director.getScene()?.children || [];
|
// 收集所有本地化组件
|
||||||
const allLocalizedLabels: any[] = [];
|
let allLocalizedLabels = [];
|
||||||
const allLocalizedSprites: any[] = [];
|
let allLocalizedSprites = [];
|
||||||
|
|
||||||
rootNodes.forEach(node => {
|
scene.children.forEach(node => {
|
||||||
allLocalizedLabels.push(...node.getComponentsInChildren('LocalizedLabel'));
|
allLocalizedLabels.push(...node.getComponentsInChildren('LocalizedLabel'));
|
||||||
allLocalizedSprites.push(...node.getComponentsInChildren('LocalizedSprite'));
|
allLocalizedSprites.push(...node.getComponentsInChildren('LocalizedSprite'));
|
||||||
});
|
});
|
||||||
|
|
||||||
allLocalizedLabels.forEach(label => {
|
// 更新所有激活的本地化组件
|
||||||
if (label.node.active) {
|
[...allLocalizedLabels, ...allLocalizedSprites].forEach(component => {
|
||||||
label.updateLabel();
|
if (component.node.active) {
|
||||||
}
|
// 调用对应的更新方法
|
||||||
});
|
component.updateLabel?.() || component.updateSprite?.();
|
||||||
|
|
||||||
allLocalizedSprites.forEach(sprite => {
|
|
||||||
if (sprite.node.active) {
|
|
||||||
sprite.updateSprite();
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// // 供插件查询当前语言使用
|
|
||||||
// const win = window as any;
|
|
||||||
// win._languageData = {
|
|
||||||
// get language() {
|
|
||||||
// return I18nManager.instance.currentLanguage;
|
|
||||||
// },
|
|
||||||
// init(lang: string) {
|
|
||||||
// I18nManager.instance.init(lang);
|
|
||||||
// },
|
|
||||||
// updateSceneRenderers() {
|
|
||||||
// I18nManager.instance.updateSceneRenderers();
|
|
||||||
// },
|
|
||||||
// };
|
|
||||||
|
Before Width: | Height: | Size: 143 KiB After Width: | Height: | Size: 143 KiB |
@ -11,7 +11,7 @@
|
|||||||
"6c48a": {
|
"6c48a": {
|
||||||
"importer": "texture",
|
"importer": "texture",
|
||||||
"uuid": "fc4357cf-5f55-416c-b94a-b412108a32a7@6c48a",
|
"uuid": "fc4357cf-5f55-416c-b94a-b412108a32a7@6c48a",
|
||||||
"displayName": "logo",
|
"displayName": "logo_en",
|
||||||
"id": "6c48a",
|
"id": "6c48a",
|
||||||
"name": "texture",
|
"name": "texture",
|
||||||
"userData": {
|
"userData": {
|
||||||
@ -35,7 +35,7 @@
|
|||||||
"f9941": {
|
"f9941": {
|
||||||
"importer": "sprite-frame",
|
"importer": "sprite-frame",
|
||||||
"uuid": "fc4357cf-5f55-416c-b94a-b412108a32a7@f9941",
|
"uuid": "fc4357cf-5f55-416c-b94a-b412108a32a7@f9941",
|
||||||
"displayName": "logo",
|
"displayName": "logo_en",
|
||||||
"id": "f9941",
|
"id": "f9941",
|
||||||
"name": "spriteFrame",
|
"name": "spriteFrame",
|
||||||
"userData": {
|
"userData": {
|
||||||
|
Before Width: | Height: | Size: 115 KiB After Width: | Height: | Size: 115 KiB |
@ -11,7 +11,7 @@
|
|||||||
"6c48a": {
|
"6c48a": {
|
||||||
"importer": "texture",
|
"importer": "texture",
|
||||||
"uuid": "51ffde0b-ff7a-4e4e-b639-b58e4b55b73f@6c48a",
|
"uuid": "51ffde0b-ff7a-4e4e-b639-b58e4b55b73f@6c48a",
|
||||||
"displayName": "logo",
|
"displayName": "logo_zh",
|
||||||
"id": "6c48a",
|
"id": "6c48a",
|
||||||
"name": "texture",
|
"name": "texture",
|
||||||
"userData": {
|
"userData": {
|
||||||
@ -35,7 +35,7 @@
|
|||||||
"f9941": {
|
"f9941": {
|
||||||
"importer": "sprite-frame",
|
"importer": "sprite-frame",
|
||||||
"uuid": "51ffde0b-ff7a-4e4e-b639-b58e4b55b73f@f9941",
|
"uuid": "51ffde0b-ff7a-4e4e-b639-b58e4b55b73f@f9941",
|
||||||
"displayName": "logo",
|
"displayName": "logo_zh",
|
||||||
"id": "f9941",
|
"id": "f9941",
|
||||||
"name": "spriteFrame",
|
"name": "spriteFrame",
|
||||||
"userData": {
|
"userData": {
|
||||||
Loading…
Reference in New Issue
Block a user