import {IFallCfg} from "db://assets/module_basic/shared/configs/interface/IFallCfg"; /************************************************************************************ * FileName : BattleRewardDataManager.ts * Description : 战斗奖励数据管理器 * Version : v1.0.0 * CreateTime : 2025-01-11 14:53:56 * Author : * Copyright (c) since 2025 * ============================================================== * Method Description: * * ============================================================== ************************************************************************************/ export class BattleRewardDataManager { private _data: Array | undefined; init(data: any): void { this._data = data; console.log(`配置数据(IFallCfg)加载完毕...`,this._data); } getData(id: number):IFallCfg { if (this._data) { return this._data.find(p=>p.id == id); } console.log("配置数据(IFallCfg)不存在"+id); return null; } getAllData() : IFallCfg[]{ return this._data; } }