28 lines
659 B
TypeScript
28 lines
659 B
TypeScript
import { oops } from "../../../../extensions/oops-plugin-framework/assets/core/Oops";
|
|
|
|
/** 策划 Excel 导出的 Json 静态数据 */
|
|
export class HeroList {
|
|
static TableName: string = "config/game/heros";
|
|
|
|
/** 静态表中一条数据 */
|
|
private data: any;
|
|
|
|
init() {
|
|
var table = oops.res.get(HeroList.TableName);
|
|
this.data = table['json']['list'];
|
|
|
|
}
|
|
|
|
/** 数据唯一编号 */
|
|
id: number = 0;
|
|
|
|
/** 数据 */
|
|
get list(): number {
|
|
let res:any = []
|
|
for(let i=0;i<this.data.length;i++)
|
|
{
|
|
res[this.data[i].uuid] = this.data[i];
|
|
}
|
|
return res;
|
|
}
|
|
} |