重做 局内经验的利用,加攻 加血,特殊技能,todo:先完成物品设定

This commit is contained in:
2024-11-25 00:02:07 +08:00
parent 5a268cc8f2
commit 2d4d564c1f
31 changed files with 5212 additions and 6212 deletions

View File

@@ -0,0 +1,24 @@
import { _decorator, Label } from "cc";
import { ecs } from "../../../../extensions/oops-plugin-framework/assets/libs/ecs/ECS";
import { CCComp } from "../../../../extensions/oops-plugin-framework/assets/module/common/CCComp";
const { ccclass, property } = _decorator;
/** 视图层对象 */
@ccclass('ItemComp')
@ecs.register('ItemComp', false)
export class ItemComp extends CCComp {
i_uuid:number = 0;
num:number = 0;
start() {
this.node.getChildByName("num").getComponent(Label).string = this.num.toString();
//todo 设定icon 显示
}
/** 视图对象通过 ecs.Entity.remove(ModuleViewComp) 删除组件是触发组件处理自定义释放逻辑 */
reset() {
this.node.destroy();
}
}