Sfoglia il codice sorgente

添加游戏设置页面

mojunshou 8 mesi fa
parent
commit
85451c7093

File diff suppressed because it is too large
+ 5080 - 0
assets/bundle/common/prefab/setting.prefab


+ 13 - 0
assets/bundle/common/prefab/setting.prefab.meta

@@ -0,0 +1,13 @@
+{
+  "ver": "1.1.50",
+  "importer": "prefab",
+  "imported": true,
+  "uuid": "53a3d42e-6cc7-4805-a0fe-ba877ccb6236",
+  "files": [
+    ".json"
+  ],
+  "subMetas": {},
+  "userData": {
+    "syncNodeName": "setting"
+  }
+}

assets/bundle/gui/eliminate/texture/btn_off.png → assets/bundle/common/texture/btn_off.png


assets/bundle/gui/eliminate/texture/btn_off.png.meta → assets/bundle/common/texture/btn_off.png.meta


assets/bundle/gui/eliminate/texture/btn_on.png → assets/bundle/common/texture/btn_on.png


assets/bundle/gui/eliminate/texture/btn_on.png.meta → assets/bundle/common/texture/btn_on.png.meta


+ 9 - 0
assets/script/game/common/setting.meta

@@ -0,0 +1,9 @@
+{
+  "ver": "1.2.0",
+  "importer": "directory",
+  "imported": true,
+  "uuid": "decb7bf7-6831-44bb-9afd-b0f25d7591f9",
+  "files": [],
+  "subMetas": {},
+  "userData": {}
+}

+ 20 - 0
assets/script/game/common/setting/SettingViewComp.ts

@@ -0,0 +1,20 @@
+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('SettingViewComp')
+@ecs.register('SettingView', false)
+export class SettingViewComp extends CCComp {
+    /** 视图层逻辑代码分离演示 */
+    start() {
+        // const entity = this.ent as ecs.Entity;         // ecs.Entity 可转为当前模块的具体实体对象
+    }
+
+    /** 视图对象通过 ecs.Entity.remove(SettingViewComp) 删除组件是触发组件处理自定义释放逻辑 */
+    reset() {
+        this.node.destroy();
+    }
+}

+ 9 - 0
assets/script/game/common/setting/SettingViewComp.ts.meta

@@ -0,0 +1,9 @@
+{
+  "ver": "4.0.24",
+  "importer": "typescript",
+  "imported": true,
+  "uuid": "bd40ba26-c669-4d44-b7a4-93d9e64f0b54",
+  "files": [],
+  "subMetas": {},
+  "userData": {}
+}

+ 19 - 0
assets/script/game/eliminate/view/eliminateViewComp.ts

@@ -1,3 +1,10 @@
+/*
+ * @Author: mojunshou 1637302775@qq.com
+ * @Date: 2025-03-20 15:01:09
+ * @LastEditors: mojunshou 1637302775@qq.com
+ * @LastEditTime: 2025-03-20 15:14:13
+ * @Description: 消除游戏主场景
+ */
 import { _decorator } from "cc";
 import { ecs } from "db://oops-framework/libs/ecs/ECS";
 import { CCComp } from "db://oops-framework/module/common/CCComp";
@@ -11,10 +18,22 @@ export class eliminateViewComp extends CCComp {
     /** 视图层逻辑代码分离演示 */
     start() {
         // const entity = this.ent as ecs.Entity;         // ecs.Entity 可转为当前模块的具体实体对象
+        this.setButton();
     }
 
+
+
+
     /** 视图对象通过 ecs.Entity.remove(eliminateViewComp) 删除组件是触发组件处理自定义释放逻辑 */
     reset() {
         this.node.destroy();
     }
+
+
+
+    private btn_setting() {
+
+
+
+    }
 }