diff --git a/.creator/asset-template/typescript/Custom Script Template Help Documentation.url b/.creator/asset-template/typescript/Custom Script Template Help Documentation.url deleted file mode 100644 index 7606df0..0000000 --- a/.creator/asset-template/typescript/Custom Script Template Help Documentation.url +++ /dev/null @@ -1,2 +0,0 @@ -[InternetShortcut] -URL=https://docs.cocos.com/creator/manual/en/scripting/setup.html#custom-script-template \ No newline at end of file diff --git a/.creator/asset-template/typescript/Module.ts b/.creator/asset-template/typescript/Module.ts deleted file mode 100644 index 249fe75..0000000 --- a/.creator/asset-template/typescript/Module.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { ecs } from "db://oops-framework/libs/ecs/ECS"; - -/** <%Name%> 模块 */ -@ecs.register(`<%Name%>`) -export class <%Name%> extends ecs.Entity { - /** ---------- 数据层 ---------- */ - // <%Name%>Model!: <%Name%>ModelComp; - - /** ---------- 业务层 ---------- */ - // <%Name%>Bll!: <%Name%>BllComp; - - /** ---------- 视图层 ---------- */ - // <%Name%>View!: <%Name%>ViewComp; - - /** 初始添加的数据层组件 */ - protected init() { - // this.addComponents(); - } - - /** 模块资源释放 */ - destroy() { - // 注: 自定义释放逻辑,视图层实现 ecs.IComp 接口的 ecs 组件需要手动释放 - super.destroy(); - } -} \ No newline at end of file diff --git a/.creator/asset-template/typescript/ModuleBll.ts b/.creator/asset-template/typescript/ModuleBll.ts deleted file mode 100644 index 69fbfe7..0000000 --- a/.creator/asset-template/typescript/ModuleBll.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { ecs } from "db://oops-framework/libs/ecs/ECS"; - -/** 业务层对象 */ -@ecs.register('<%Name%>') -export class <%Name%>Comp extends ecs.Comp { - /** 业务层组件移除时,重置所有数据为默认值 */ - reset() { - - } -} - -/** 业务层业务逻辑处理对象 */ -@ecs.register('实体对象名') -export class <%Name%>System extends ecs.ComblockSystem implements ecs.IEntityEnterSystem { - filter(): ecs.IMatcher { - return ecs.allOf(<%Name%>Comp); - } - - entityEnter(e: ecs.Entity): void { - // 注:自定义业务逻辑 - - - e.remove(<%Name%>Comp); - } -} \ No newline at end of file diff --git a/.creator/asset-template/typescript/ModuleModel.ts b/.creator/asset-template/typescript/ModuleModel.ts deleted file mode 100644 index 8735027..0000000 --- a/.creator/asset-template/typescript/ModuleModel.ts +++ /dev/null @@ -1,26 +0,0 @@ -import { ecs } from "db://oops-framework/libs/ecs/ECS"; -import { VM } from "db://oops-framework/libs/model-view/ViewModel"; - -/** 数据层对象 */ -@ecs.register('<%Name%>') -export class <%Name%>Comp extends ecs.Comp { - /** 提供 MVVM 组件使用的数据 */ - private vm: any = {}; - - /** 显示数据添加到 MVVM 框架中监视 */ - vmAdd() { - VM.add(this.vm, "<%Name%>"); - } - - /** 显示数据从 MVVM 框架中移除 */ - vmRemove() { - VM.remove("<%Name%>"); - } - - /** 数据层组件移除时,重置所有数据为默认值 */ - reset() { - for (let key in this.vm) { - delete this.vm[key]; - } - } -} \ No newline at end of file diff --git a/.creator/asset-template/typescript/ModuleTable.ts b/.creator/asset-template/typescript/ModuleTable.ts deleted file mode 100644 index d80e401..0000000 --- a/.creator/asset-template/typescript/ModuleTable.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { JsonUtil } from "db://oops-framework/core/utils/JsonUtil"; - -/** 策划 Excel 导出的 Json 静态数据 */ -export class <%Name%> { - static TableName: string = "配置表文件名"; - - /** 静态表中一条数据 */ - private data: any; - - init(id: number) { - const table = JsonUtil.get(<%Name%>.TableName); - this.data = table[id]; - this.id = id; - } - - /** 数据唯一编号 */ - id: number = 0; - - /** 数据 */ - // get test(): number { - // return this.data.test; - // } -} \ No newline at end of file diff --git a/.creator/asset-template/typescript/ModuleView.ts b/.creator/asset-template/typescript/ModuleView.ts deleted file mode 100644 index 7fcdeac..0000000 --- a/.creator/asset-template/typescript/ModuleView.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { _decorator } from "cc"; -import { ecs } from "db://oops-framework/libs/ecs/ECS"; -import { CCComp } from "db://oops-framework/module/common/CCComp"; - -const { ccclass, property } = _decorator; - -/** 视图层对象 */ -@ccclass('<%Name%>Comp') -@ecs.register('<%Name%>', false) -export class <%Name%>Comp extends CCComp { - /** 视图层逻辑代码分离演示 */ - start() { - // const entity = this.ent as ecs.Entity; // ecs.Entity 可转为当前模块的具体实体对象 - } - - /** 视图对象通过 ecs.Entity.remove(ModuleViewComp) 删除组件是触发组件处理自定义释放逻辑 */ - reset() { - this.node.destroy(); - } -} \ No newline at end of file diff --git a/.creator/asset-template/typescript/ModuleViewVM.ts b/.creator/asset-template/typescript/ModuleViewVM.ts deleted file mode 100644 index d83b6ef..0000000 --- a/.creator/asset-template/typescript/ModuleViewVM.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { _decorator } from "cc"; -import { ecs } from "db://oops-framework/libs/ecs/ECS"; -import { CCVMParentComp } from "db://oops-framework/module/common/CCVMParentComp"; - -const { ccclass, property } = _decorator; - -/** 视图层对象 - 支持 MVVM 框架的数据绑定 */ -@ccclass('<%Name%>Comp') -@ecs.register('<%Name%>', false) -export class <%Name%>Comp extends CCVMParentComp { - /** 脚本控制的界面 MVVM 框架绑定数据 */ - data: any = {}; - - /** 视图层逻辑代码分离演示 */ - start() { - // const entity = this.ent as ecs.Entity; // ecs.Entity 可转为当前模块的具体实体对象 - } - - /** 视图对象通过 ecs.Entity.remove(ModuleViewComp) 删除组件是触发组件处理自定义释放逻辑 */ - reset() { - this.node.destroy(); - } -} \ No newline at end of file diff --git a/.creator/default-meta.json b/.creator/default-meta.json deleted file mode 100644 index aee5e1c..0000000 --- a/.creator/default-meta.json +++ /dev/null @@ -1 +0,0 @@ -{"image":{"type":"sprite-frame"}}