ソースを参照

增加多目标攻击

zouyong 5 年 前
コミット
b0d2ee9ffd
39 ファイル変更1503 行追加218 行削除
  1. 15 0
      .vscode/launch.json
  2. 15 6
      tools/createResList.js
  3. 13 8
      tools/test.js
  4. BIN
      tower_sanguo/assets/resources/data/1.bin
  5. 1 1
      tower_sanguo/assets/resources/data/1.bin.meta
  6. 1 0
      tower_sanguo/assets/resources/data/buff_data.json
  7. 5 0
      tower_sanguo/assets/resources/data/buff_data.json.meta
  8. 962 0
      tower_sanguo/assets/resources/data/general_data.json
  9. 5 0
      tower_sanguo/assets/resources/data/general_data.json.meta
  10. 30 0
      tower_sanguo/assets/resources/data/mission_data.json
  11. 5 0
      tower_sanguo/assets/resources/data/mission_data.json.meta
  12. 26 0
      tower_sanguo/assets/resources/data/monster_data.json
  13. 5 0
      tower_sanguo/assets/resources/data/monster_data.json.meta
  14. 19 19
      tower_sanguo/assets/resources/data/resList.json
  15. 62 0
      tower_sanguo/assets/resources/data/skill_data.json
  16. 5 0
      tower_sanguo/assets/resources/data/skill_data.json.meta
  17. 5 6
      tower_sanguo/assets/resources/module/fight/prefab/general_game.prefab
  18. 0 0
      tower_sanguo/assets/resources/module/fight/prefab/general_game.prefab.meta
  19. 115 3
      tower_sanguo/assets/resources/module/fight/prefab/monster.prefab
  20. 0 0
      tower_sanguo/assets/resources/module/fight/texture/fight_1.png
  21. 1 1
      tower_sanguo/assets/resources/module/fight/texture/fight_1.png.meta
  22. 0 5
      tower_sanguo/assets/resources/spine/person/guanyu.atlas.meta
  23. 0 9
      tower_sanguo/assets/resources/spine/person/guanyu.json.meta
  24. 1 1
      tower_sanguo/assets/resources/spine/person/hero_shu_GY.atlas
  25. 5 0
      tower_sanguo/assets/resources/spine/person/hero_shu_GY.atlas.meta
  26. 0 0
      tower_sanguo/assets/resources/spine/person/hero_shu_GY.json
  27. 9 0
      tower_sanguo/assets/resources/spine/person/hero_shu_GY.json.meta
  28. 0 0
      tower_sanguo/assets/resources/spine/person/hero_shu_GY.png
  29. 4 4
      tower_sanguo/assets/resources/spine/person/hero_shu_GY.png.meta
  30. 13 7
      tower_sanguo/assets/scripts/data/GameData.ts
  31. 88 40
      tower_sanguo/assets/scripts/module/fight/FightUI.ts
  32. 0 54
      tower_sanguo/assets/scripts/module/fight/model/BaseModel.ts
  33. 0 9
      tower_sanguo/assets/scripts/module/fight/model/BaseModel.ts.meta
  34. 2 2
      tower_sanguo/assets/scripts/module/fight/model/attack/AttackModel.ts
  35. 55 33
      tower_sanguo/assets/scripts/module/fight/model/generals/General.ts
  36. 32 8
      tower_sanguo/assets/scripts/module/fight/model/monsters/Monster.ts
  37. 1 1
      tower_sanguo/assets/scripts/module/main/MainUI.ts
  38. 2 0
      tower_sanguo/assets/scripts/vo/GeneralVO.ts
  39. 1 1
      tower_sanguo/settings/project.json

+ 15 - 0
.vscode/launch.json

@@ -0,0 +1,15 @@
+{
+    // 使用 IntelliSense 了解相关属性。 
+    // 悬停以查看现有属性的描述。
+    // 欲了解更多信息,请访问: https://go.microsoft.com/fwlink/?linkid=830387
+    "version": "0.2.0",
+    "configurations": [
+        {
+            "type": "pwa-chrome",
+            "request": "launch",
+            "name": "Launch Chrome against localhost",
+            "url": "http://localhost:8080",
+            "webRoot": "${workspaceFolder}"
+        }
+    ]
+}

+ 15 - 6
tools/createResList.js

@@ -1,11 +1,15 @@
 /**
- * 自动生成所有资源列表
+ * 自动生成需要的资源列表
+ * 修改 res_list_arr 生成需要前期加载的资源
  */
 
 const path = require('path')
 const fs = require('fs')
 var FileUtil = require('./FileUtil');
 
+/** 需要加载到资源文件夹 module内的为 */
+var res_list_arr = ['data', 'music', 'module/loading', 'module/main', 'module/fight'];
+
 //自动获取项目名称
 var programepath = process.cwd();
 var arr = programepath.split('\\');
@@ -14,7 +18,6 @@ var programename = arr[arr.length - 1];
 var dirpath = arr.join('\\') + '\\' + programename + '\\assets\\resources';
 
 /** 进入游戏需要加载的资源文件夹 */
-var res_list_arr = ['data', 'module/loading', 'module/main', 'module/fight', 'music'];
 
 var resjsondata = {};
 var reslistpath = dirpath + "\\data\\resList.json";
@@ -52,9 +55,14 @@ var mapDir = (dir, callback, finish) => {
     })
 }
 
+/**
+ * 单个资源处理
+ * @param {*} pathname 
+ * @returns 
+ */
 var addFileName = (pathname) => {
     let a = pathname.split("\\").slice(arr.length + 3);
-    if(a.indexOf("prefab_texture") != -1){
+    if (a.indexOf("prefab_texture") != -1) {
         return;
     }
     let vo = {};
@@ -62,13 +70,13 @@ var addFileName = (pathname) => {
     let d = url.split(".");
     let type = d[1];
     vo.url = d[0];
-    if(a.indexOf("spine") != -1){
+    if (a.indexOf("spine") != -1) {
         type = 'spine';
     }
-    else if(a.indexOf("atlas") != -1){
+    else if (a.indexOf("atlas") != -1) {
         type = 'atlas';
     }
-    else if(type == 'png' || type == 'jpg'){
+    else if (type == 'png' || type == 'jpg') {
         type = 'texture';
     }
     vo.type = type;
@@ -83,6 +91,7 @@ for (let i = 0; i < res_list_arr.length; i++) {
     mapDir(p, addFileName, finish);
 }
 
+/** 因为异步多文件夹处理,做个定时,等文件夹处理完后生成文件 */
 setTimeout(() => {
     let res_arr = [];
     for (let i in resjsondata) {

+ 13 - 8
tools/test.js

@@ -1,13 +1,18 @@
 
-let a = 0;
-
-let b = (c) => {
-    console.log('first:' + c);
-    console.log('second:' + a);
+let arr = [];
+for (let i = 0; i < 10; i++) {
+    arr.push({ id: i, num: 10 - i });
 }
+console.log(arr);
 
-b(++a);
-
-console.log('three:' + a);
+arr.sort((a, b) => {
+    if (a.num < b.num) {
+        return -1;
+    }
+    else {
+        return 1;
+    }
+});
 
+console.log(arr);
 

BIN
tower_sanguo/assets/resources/data/1.bin


+ 1 - 1
tower_sanguo/assets/resources/data/1.bin.meta

@@ -1,5 +1,5 @@
 {
   "ver": "1.0.0",
-  "uuid": "50f1e37d-2d8a-4a80-9fcc-5e7879fbe0ae",
+  "uuid": "535a22d5-0d76-4eea-bcc7-5cf1ade5e7cd",
   "subMetas": {}
 }

+ 1 - 0
tower_sanguo/assets/resources/data/buff_data.json

@@ -0,0 +1 @@
+{}

+ 5 - 0
tower_sanguo/assets/resources/data/buff_data.json.meta

@@ -0,0 +1,5 @@
+{
+  "ver": "1.0.0",
+  "uuid": "c3d74386-ba7f-4187-9fe7-de8d9fd66d91",
+  "subMetas": {}
+}

+ 962 - 0
tower_sanguo/assets/resources/data/general_data.json

@@ -0,0 +1,962 @@
+{
+	"111001": {
+		"id": 111001,
+		"name": "孔秀",
+		"camp": 1,
+		"color": 1,
+		"commander": 61,
+		"initStar": 1,
+		"attSpeed": 0.95,
+		"skillID": 100001,
+		"hero_res": "hero_wei_KX",
+		"atk_res": "fight_1",
+		"attack": 60,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "60,84,107,131,154,178,201"
+	},
+	"111002": {
+		"id": 111002,
+		"name": "吕翔",
+		"camp": 1,
+		"color": 1,
+		"commander": 59,
+		"initStar": 1,
+		"attSpeed": 1.05,
+		"skillID": 100001,
+		"hero_res": "hero_wei_LX",
+		"atk_res": "fight_1",
+		"attack": 60,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "60,84,107,131,154,178,201"
+	},
+	"111003": {
+		"id": 111003,
+		"name": "王植",
+		"camp": 1,
+		"color": 1,
+		"commander": 55,
+		"initStar": 1,
+		"attSpeed": 1.93,
+		"skillID": 100001,
+		"hero_res": "hero_wei_WZ",
+		"atk_res": "fight_1",
+		"attack": 60,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "60,84,107,131,154,178,201"
+	},
+	"111004": {
+		"id": 111004,
+		"name": "吕旷",
+		"camp": 1,
+		"color": 1,
+		"commander": 57,
+		"initStar": 1,
+		"attSpeed": 1.83,
+		"skillID": 100001,
+		"hero_res": "hero_wei_LK",
+		"atk_res": "fight_1",
+		"attack": 60,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "60,84,107,131,154,178,201"
+	},
+	"112005": {
+		"id": 112005,
+		"name": "李典",
+		"camp": 1,
+		"color": 2,
+		"commander": 82,
+		"initStar": 2,
+		"attSpeed": 1,
+		"skillID": 100011,
+		"hero_res": "hero_wei_LD",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"112006": {
+		"id": 112006,
+		"name": "许攸",
+		"camp": 1,
+		"color": 2,
+		"commander": 74,
+		"initStar": 2,
+		"attSpeed": 0.96,
+		"skillID": 100011,
+		"hero_res": "hero_wei_XY",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"112007": {
+		"id": 112007,
+		"name": "荀攸",
+		"camp": 1,
+		"color": 2,
+		"commander": 71,
+		"initStar": 2,
+		"attSpeed": 1.18,
+		"skillID": 100011,
+		"hero_res": "hero_wei_XY_01",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"112008": {
+		"id": 112008,
+		"name": "夏侯惇",
+		"camp": 1,
+		"color": 2,
+		"commander": 91,
+		"initStar": 2,
+		"attSpeed": 1.32,
+		"skillID": 100011,
+		"hero_res": "hero_wei_XHD",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"113009": {
+		"id": 113009,
+		"name": "郭嘉",
+		"camp": 1,
+		"color": 3,
+		"commander": 95,
+		"initStar": 3,
+		"attSpeed": 1.51,
+		"skillID": 100021,
+		"hero_res": "hero_wei_GJ",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"113010": {
+		"id": 113010,
+		"name": "司马懿",
+		"camp": 1,
+		"color": 3,
+		"commander": 98,
+		"initStar": 3,
+		"attSpeed": 1.94,
+		"skillID": 100021,
+		"hero_res": "hero_wei_SMY",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"113011": {
+		"id": 113011,
+		"name": "曹操",
+		"camp": 1,
+		"color": 3,
+		"commander": 100,
+		"initStar": 3,
+		"attSpeed": 1.02,
+		"skillID": 100021,
+		"hero_res": "hero_wei_CC",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"113012": {
+		"id": 113012,
+		"name": "张郃",
+		"camp": 1,
+		"color": 3,
+		"commander": 94,
+		"initStar": 3,
+		"attSpeed": 1.77,
+		"skillID": 100021,
+		"hero_res": "hero_wei_ZH",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"113013": {
+		"id": 113013,
+		"name": "于禁",
+		"camp": 1,
+		"color": 3,
+		"commander": 92,
+		"initStar": 3,
+		"attSpeed": 1.38,
+		"skillID": 100021,
+		"hero_res": "hero_wei_YJ",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"113014": {
+		"id": 113014,
+		"name": "徐晃",
+		"camp": 1,
+		"color": 3,
+		"commander": 94,
+		"initStar": 3,
+		"attSpeed": 1.24,
+		"skillID": 100021,
+		"hero_res": "hero_wei_XH",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"113015": {
+		"id": 113015,
+		"name": "乐进",
+		"camp": 1,
+		"color": 3,
+		"commander": 90,
+		"initStar": 3,
+		"attSpeed": 0.91,
+		"skillID": 100021,
+		"hero_res": "hero_wei_LJ",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"114016": {
+		"id": 114016,
+		"name": "张辽",
+		"camp": 1,
+		"color": 4,
+		"commander": 99,
+		"initStar": 3,
+		"attSpeed": 1.94,
+		"skillID": 100031,
+		"hero_res": "hero_wei_ZL",
+		"atk_res": "fight_1",
+		"attack": 150,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "150,209,268,327,386,445,504"
+	},
+	"121001": {
+		"id": 121001,
+		"name": "关平",
+		"camp": 2,
+		"color": 1,
+		"commander": 73,
+		"initStar": 1,
+		"attSpeed": 1.75,
+		"skillID": 100001,
+		"hero_res": "hero_shu_GP",
+		"atk_res": "fight_1",
+		"attack": 60,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "60,84,107,131,154,178,201"
+	},
+	"121002": {
+		"id": 121002,
+		"name": "张苞",
+		"camp": 2,
+		"color": 1,
+		"commander": 74,
+		"initStar": 1,
+		"attSpeed": 0.76,
+		"skillID": 100001,
+		"hero_res": "hero_shu_ZB",
+		"atk_res": "fight_1",
+		"attack": 60,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "60,84,107,131,154,178,201"
+	},
+	"122003": {
+		"id": 122003,
+		"name": "马岱",
+		"camp": 2,
+		"color": 2,
+		"commander": 76,
+		"initStar": 2,
+		"attSpeed": 1.74,
+		"skillID": 100011,
+		"hero_res": "hero_shu_MD",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"122004": {
+		"id": 122004,
+		"name": "周仓",
+		"camp": 2,
+		"color": 2,
+		"commander": 77,
+		"initStar": 2,
+		"attSpeed": 1.63,
+		"skillID": 100011,
+		"hero_res": "hero_shu_ZC",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"122005": {
+		"id": 122005,
+		"name": "魏延",
+		"camp": 2,
+		"color": 2,
+		"commander": 86,
+		"initStar": 2,
+		"attSpeed": 0.99,
+		"skillID": 100011,
+		"hero_res": "hero_shu_WY",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"122006": {
+		"id": 122006,
+		"name": "廖化",
+		"camp": 2,
+		"color": 2,
+		"commander": 86,
+		"initStar": 2,
+		"attSpeed": 1.93,
+		"skillID": 100011,
+		"hero_res": "hero_shu_LH",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"123007": {
+		"id": 123007,
+		"name": "庞统",
+		"camp": 2,
+		"color": 3,
+		"commander": 81,
+		"initStar": 3,
+		"attSpeed": 1.37,
+		"skillID": 100021,
+		"hero_res": "hero_shu_PT",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"123008": {
+		"id": 123008,
+		"name": "诸葛亮",
+		"camp": 2,
+		"color": 3,
+		"commander": 98,
+		"initStar": 3,
+		"attSpeed": 1.71,
+		"skillID": 100021,
+		"hero_res": "hero_shu_ZGL",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"123009": {
+		"id": 123009,
+		"name": "赵云",
+		"camp": 2,
+		"color": 3,
+		"commander": 97,
+		"initStar": 3,
+		"attSpeed": 1.24,
+		"skillID": 100021,
+		"hero_res": "hero_shu_ZY",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"123010": {
+		"id": 123010,
+		"name": "马超",
+		"camp": 2,
+		"color": 3,
+		"commander": 95,
+		"initStar": 3,
+		"attSpeed": 0.89,
+		"skillID": 100021,
+		"hero_res": "hero_shu_MC",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"123011": {
+		"id": 123011,
+		"name": "张飞",
+		"camp": 2,
+		"color": 3,
+		"commander": 94,
+		"initStar": 3,
+		"attSpeed": 1.43,
+		"skillID": 100021,
+		"hero_res": "hero_shu_ZF",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"123012": {
+		"id": 123012,
+		"name": "刘备",
+		"camp": 2,
+		"color": 3,
+		"commander": 87,
+		"initStar": 3,
+		"attSpeed": 1.63,
+		"skillID": 100021,
+		"hero_res": "hero_shu_LB",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"123013": {
+		"id": 123013,
+		"name": "黄忠",
+		"camp": 2,
+		"color": 3,
+		"commander": 88,
+		"initStar": 3,
+		"attSpeed": 1.99,
+		"skillID": 100021,
+		"hero_res": "hero_shu_HZ",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"124014": {
+		"id": 124014,
+		"name": "关羽",
+		"camp": 2,
+		"color": 4,
+		"commander": 96,
+		"initStar": 3,
+		"attSpeed": 1.27,
+		"skillID": 100031,
+		"hero_res": "hero_shu_GY",
+		"atk_res": "fight_1",
+		"attack": 150,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "150,209,268,327,386,445,504"
+	},
+	"131001": {
+		"id": 131001,
+		"name": "韩当",
+		"camp": 3,
+		"color": 1,
+		"commander": 60,
+		"initStar": 1,
+		"attSpeed": 0.97,
+		"skillID": 100001,
+		"hero_res": "hero_wu_HD",
+		"atk_res": "fight_1",
+		"attack": 60,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "60,84,107,131,154,178,201"
+	},
+	"131002": {
+		"id": 131002,
+		"name": "祖茂",
+		"camp": 3,
+		"color": 1,
+		"commander": 61,
+		"initStar": 1,
+		"attSpeed": 1.96,
+		"skillID": 100001,
+		"hero_res": "hero_wu_ZM",
+		"atk_res": "fight_1",
+		"attack": 60,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "60,84,107,131,154,178,201"
+	},
+	"131003": {
+		"id": 131003,
+		"name": "蒋钦",
+		"camp": 3,
+		"color": 1,
+		"commander": 66,
+		"initStar": 1,
+		"attSpeed": 1.99,
+		"skillID": 100001,
+		"hero_res": "hero_wu_JQ",
+		"atk_res": "fight_1",
+		"attack": 60,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "60,84,107,131,154,178,201"
+	},
+	"132004": {
+		"id": 132004,
+		"name": "程普",
+		"camp": 3,
+		"color": 2,
+		"commander": 81,
+		"initStar": 2,
+		"attSpeed": 1.98,
+		"skillID": 100011,
+		"hero_res": "hero_wu_CP",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"132005": {
+		"id": 132005,
+		"name": "凌操",
+		"camp": 3,
+		"color": 2,
+		"commander": 82,
+		"initStar": 2,
+		"attSpeed": 1.09,
+		"skillID": 100011,
+		"hero_res": "hero_wu_LC",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"132006": {
+		"id": 132006,
+		"name": "丁奉",
+		"camp": 3,
+		"color": 2,
+		"commander": 85,
+		"initStar": 2,
+		"attSpeed": 1.22,
+		"skillID": 100011,
+		"hero_res": "hero_wu_DF",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"132007": {
+		"id": 132007,
+		"name": "张昭",
+		"camp": 3,
+		"color": 2,
+		"commander": 67,
+		"initStar": 2,
+		"attSpeed": 0.95,
+		"skillID": 100011,
+		"hero_res": "hero_wu_ZZ",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"133008": {
+		"id": 133008,
+		"name": "周瑜",
+		"camp": 3,
+		"color": 3,
+		"commander": 97,
+		"initStar": 3,
+		"attSpeed": 1.98,
+		"skillID": 100021,
+		"hero_res": "hero_wu_ZY",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"133009": {
+		"id": 133009,
+		"name": "太史慈",
+		"camp": 3,
+		"color": 3,
+		"commander": 92,
+		"initStar": 3,
+		"attSpeed": 0.78,
+		"skillID": 100021,
+		"hero_res": "hero_wu_TSC",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"133010": {
+		"id": 133010,
+		"name": "孙策",
+		"camp": 3,
+		"color": 3,
+		"commander": 99,
+		"initStar": 3,
+		"attSpeed": 1.26,
+		"skillID": 100021,
+		"hero_res": "hero_wu_SC",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"133011": {
+		"id": 133011,
+		"name": "鲁肃",
+		"camp": 3,
+		"color": 3,
+		"commander": 81,
+		"initStar": 3,
+		"attSpeed": 0.99,
+		"skillID": 100021,
+		"hero_res": "hero_wu_LS",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"133012": {
+		"id": 133012,
+		"name": "孙权",
+		"camp": 3,
+		"color": 3,
+		"commander": 89,
+		"initStar": 3,
+		"attSpeed": 1.52,
+		"skillID": 100021,
+		"hero_res": "hero_wu_SQ",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"133013": {
+		"id": 133013,
+		"name": "吕蒙",
+		"camp": 3,
+		"color": 3,
+		"commander": 95,
+		"initStar": 3,
+		"attSpeed": 1.14,
+		"skillID": 100021,
+		"hero_res": "hero_wu_LM",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"134014": {
+		"id": 134014,
+		"name": "陆逊",
+		"camp": 3,
+		"color": 4,
+		"commander": 96,
+		"initStar": 3,
+		"attSpeed": 1.28,
+		"skillID": 100031,
+		"hero_res": "hero_wu_LX",
+		"atk_res": "fight_1",
+		"attack": 150,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "150,209,268,327,386,445,504"
+	},
+	"141001": {
+		"id": 141001,
+		"name": "黄邵",
+		"camp": 4,
+		"color": 1,
+		"commander": 61,
+		"initStar": 1,
+		"attSpeed": 1.83,
+		"skillID": 100001,
+		"hero_res": "hero_qun_HS",
+		"atk_res": "fight_1",
+		"attack": 60,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "60,84,107,131,154,178,201"
+	},
+	"141002": {
+		"id": 141002,
+		"name": "刘刕",
+		"camp": 4,
+		"color": 1,
+		"commander": 60,
+		"initStar": 1,
+		"attSpeed": 1.76,
+		"skillID": 100001,
+		"hero_res": "hero_qun_LL",
+		"atk_res": "fight_1",
+		"attack": 60,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "60,84,107,131,154,178,201"
+	},
+	"141003": {
+		"id": 141003,
+		"name": "淳于琼",
+		"camp": 4,
+		"color": 1,
+		"commander": 70,
+		"initStar": 1,
+		"attSpeed": 1.13,
+		"skillID": 100001,
+		"hero_res": "hero_qun_CYQ",
+		"atk_res": "fight_1",
+		"attack": 60,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "60,84,107,131,154,178,201"
+	},
+	"141004": {
+		"id": 141004,
+		"name": "曹豹",
+		"camp": 4,
+		"color": 1,
+		"commander": 62,
+		"initStar": 1,
+		"attSpeed": 1.39,
+		"skillID": 100001,
+		"hero_res": "hero_qun_CB",
+		"atk_res": "fight_1",
+		"attack": 60,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "60,84,107,131,154,178,201"
+	},
+	"142005": {
+		"id": 142005,
+		"name": "张宝",
+		"camp": 4,
+		"color": 2,
+		"commander": 69,
+		"initStar": 2,
+		"attSpeed": 1.57,
+		"skillID": 100011,
+		"hero_res": "hero_qun_ZB",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"142006": {
+		"id": 142006,
+		"name": "张梁",
+		"camp": 4,
+		"color": 2,
+		"commander": 72,
+		"initStar": 2,
+		"attSpeed": 0.91,
+		"skillID": 100011,
+		"hero_res": "hero_qun_ZL",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"142007": {
+		"id": 142007,
+		"name": "高览",
+		"camp": 4,
+		"color": 2,
+		"commander": 79,
+		"initStar": 2,
+		"attSpeed": 1.86,
+		"skillID": 100011,
+		"hero_res": "hero_qun_GL",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"142008": {
+		"id": 142008,
+		"name": "陈宫",
+		"camp": 4,
+		"color": 2,
+		"commander": 70,
+		"initStar": 2,
+		"attSpeed": 1.67,
+		"skillID": 100011,
+		"hero_res": "hero_qun_CG",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"142009": {
+		"id": 142009,
+		"name": "李傕",
+		"camp": 4,
+		"color": 2,
+		"commander": 68,
+		"initStar": 2,
+		"attSpeed": 1.68,
+		"skillID": 100011,
+		"hero_res": "hero_qun_LJ",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"142010": {
+		"id": 142010,
+		"name": "纪灵",
+		"camp": 4,
+		"color": 2,
+		"commander": 76,
+		"initStar": 2,
+		"attSpeed": 1.21,
+		"skillID": 100011,
+		"hero_res": "hero_qun_JL",
+		"atk_res": "fight_1",
+		"attack": 105,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "105,146,187,229,270,311,352"
+	},
+	"143011": {
+		"id": 143011,
+		"name": "张角",
+		"camp": 4,
+		"color": 3,
+		"commander": 91,
+		"initStar": 3,
+		"attSpeed": 1.48,
+		"skillID": 100021,
+		"hero_res": "hero_qun_ZJ",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"143012": {
+		"id": 143012,
+		"name": "公孙瓒",
+		"camp": 4,
+		"color": 3,
+		"commander": 93,
+		"initStar": 3,
+		"attSpeed": 1.54,
+		"skillID": 100021,
+		"hero_res": "hero_qun_GSZ",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"143013": {
+		"id": 143013,
+		"name": "董卓",
+		"camp": 4,
+		"color": 3,
+		"commander": 88,
+		"initStar": 3,
+		"attSpeed": 1.75,
+		"skillID": 100021,
+		"hero_res": "hero_qun_DZ",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"143014": {
+		"id": 143014,
+		"name": "袁绍",
+		"camp": 4,
+		"color": 3,
+		"commander": 90,
+		"initStar": 3,
+		"attSpeed": 1.23,
+		"skillID": 100021,
+		"hero_res": "hero_qun_YS",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"143015": {
+		"id": 143015,
+		"name": "貂蝉",
+		"camp": 4,
+		"color": 3,
+		"commander": 83,
+		"initStar": 3,
+		"attSpeed": 0.72,
+		"skillID": 100021,
+		"hero_res": "hero_qun_DC",
+		"atk_res": "fight_1",
+		"attack": 130,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "127,178,228,278,328,378,428"
+	},
+	"144016": {
+		"id": 144016,
+		"name": "吕布",
+		"camp": 4,
+		"color": 4,
+		"commander": 96,
+		"initStar": 3,
+		"attSpeed": 1.19,
+		"skillID": 100031,
+		"hero_res": "hero_qun_LB",
+		"atk_res": "fight_1",
+		"attack": 150,
+		"cri": 500,
+		"acc": 10000,
+		"upRatio": "150,209,268,327,386,445,504"
+	}
+}

+ 5 - 0
tower_sanguo/assets/resources/data/general_data.json.meta

@@ -0,0 +1,5 @@
+{
+  "ver": "1.0.0",
+  "uuid": "898471d3-cd53-4e15-931e-89ffc538c367",
+  "subMetas": {}
+}

+ 30 - 0
tower_sanguo/assets/resources/data/mission_data.json

@@ -0,0 +1,30 @@
+{
+	"1": {
+		"id": 1,
+		"type": 1,
+		"monsterData": "2,2,100,0.3"
+	},
+	"2": {
+		"id": 2,
+		"type": 1,
+		"monsterData": "2,2.5,8,0.3"
+	},
+	"3": {
+		"id": 3,
+		"type": 1,
+		"monsterData": "2,2.5,8,0.3;1,5,12,0.2",
+		"cd": 5
+	},
+	"4": {
+		"id": 4,
+		"type": 1,
+		"monsterData": "2,2.5,8,0.3;1,5,12,0.2",
+		"cd": 3
+	},
+	"5": {
+		"id": 5,
+		"type": 2,
+		"monsterData": "3,1.5,1,1",
+		"award": "1:100;2:50"
+	}
+}

+ 5 - 0
tower_sanguo/assets/resources/data/mission_data.json.meta

@@ -0,0 +1,5 @@
+{
+  "ver": "1.0.0",
+  "uuid": "27c13e92-3c9f-4576-92b8-a85ccdcc097a",
+  "subMetas": {}
+}

+ 26 - 0
tower_sanguo/assets/resources/data/monster_data.json

@@ -0,0 +1,26 @@
+{
+	"1": {
+		"id": 1,
+		"resource": "bing_1",
+		"type": 1,
+		"hp": 200,
+		"miss": 0,
+		"award": "1:5"
+	},
+	"2": {
+		"id": 2,
+		"resource": "bing_1",
+		"type": 1,
+		"hp": 400,
+		"miss": 0,
+		"award": "1:5"
+	},
+	"3": {
+		"id": 3,
+		"resource": "bing_1",
+		"type": 2,
+		"hp": 10000,
+		"miss": 1000,
+		"award": "1:20"
+	}
+}

+ 5 - 0
tower_sanguo/assets/resources/data/monster_data.json.meta

@@ -0,0 +1,5 @@
+{
+  "ver": "1.0.0",
+  "uuid": "2ef9b4b1-8fb6-411e-ba58-2205ba841c29",
+  "subMetas": {}
+}

+ 19 - 19
tower_sanguo/assets/resources/data/resList.json

@@ -1,10 +1,14 @@
 [
 	{
+		"url": "data/general_data",
+		"type": "json"
+	},
+	{
 		"url": "data/1",
 		"type": "bin"
 	},
 	{
-		"url": "data/general_data",
+		"url": "data/buff_data",
 		"type": "json"
 	},
 	{
@@ -12,35 +16,31 @@
 		"type": "json"
 	},
 	{
-		"url": "data/buff_data",
-		"type": "json"
-	},
-	{
 		"url": "data/mission_data",
 		"type": "json"
 	},
 	{
-		"url": "data/resList",
+		"url": "data/skill_data",
 		"type": "json"
 	},
 	{
-		"url": "data/skill_data",
+		"url": "data/resList",
 		"type": "json"
 	},
 	{
-		"url": "module/loading/loading",
-		"type": "prefab"
+		"url": "music/Sutra_PickUP",
+		"type": "wav"
 	},
 	{
 		"url": "module/main/main",
 		"type": "prefab"
 	},
 	{
-		"url": "module/main/missionitem",
+		"url": "module/loading/loading",
 		"type": "prefab"
 	},
 	{
-		"url": "module/fight/fight",
+		"url": "module/main/missionitem",
 		"type": "prefab"
 	},
 	{
@@ -48,19 +48,19 @@
 		"type": "mp3"
 	},
 	{
-		"url": "music/Sutra_PickUP",
-		"type": "wav"
+		"url": "module/fight/fight",
+		"type": "prefab"
 	},
 	{
-		"url": "module/fight/prefab/bar_monster",
+		"url": "module/fight/prefab/attack_normal",
 		"type": "prefab"
 	},
 	{
-		"url": "module/fight/prefab/guanyu",
+		"url": "module/fight/prefab/bar_monster",
 		"type": "prefab"
 	},
 	{
-		"url": "module/fight/prefab/attack_normal",
+		"url": "module/fight/prefab/general_game",
 		"type": "prefab"
 	},
 	{
@@ -80,7 +80,7 @@
 		"type": "spine"
 	},
 	{
-		"url": "module/fight/texture/attack_daoguang",
+		"url": "module/fight/texture/fight_1",
 		"type": "texture"
 	},
 	{
@@ -88,11 +88,11 @@
 		"type": "spine"
 	},
 	{
-		"url": "module/fight/spine/attack_full/1/skeleton",
+		"url": "module/fight/spine/attack_full/4/skeleton",
 		"type": "spine"
 	},
 	{
-		"url": "module/fight/spine/attack_full/4/skeleton",
+		"url": "module/fight/spine/attack_full/1/skeleton",
 		"type": "spine"
 	},
 	{

+ 62 - 0
tower_sanguo/assets/resources/data/skill_data.json

@@ -0,0 +1,62 @@
+{
+	"100001": {
+		"id": 100001,
+		"attType": "1:1",
+		"skillValue": "9220,1019"
+	},
+	"100002": {
+		"id": 100002,
+		"attType": "1:3",
+		"skillValue": "3480,3850"
+	},
+	"100003": {
+		"id": 100003,
+		"attType": "2:10,5",
+		"skillValue": "2510,2770"
+	},
+	"100011": {
+		"id": 100011,
+		"attType": "1:1",
+		"skillValue": "9500,10500"
+	},
+	"100012": {
+		"id": 100012,
+		"attType": "1:3",
+		"skillValue": "3640,4030"
+	},
+	"100013": {
+		"id": 100013,
+		"attType": "2:10,5",
+		"skillValue": "2700,2980"
+	},
+	"100021": {
+		"id": 100021,
+		"attType": "1:1",
+		"skillValue": "9880,10920"
+	},
+	"100022": {
+		"id": 100022,
+		"attType": "1:3",
+		"skillValue": "3800,4200"
+	},
+	"100023": {
+		"id": 100023,
+		"attType": "2:10,5",
+		"skillValue": "2950,3260"
+	},
+	"100031": {
+		"id": 100031,
+		"attType": "1:3",
+		"skillValue": "10260,11340"
+	},
+	"100032": {
+		"id": 100032,
+		"attType": "1:3",
+		"skillValue": "4020,4450"
+	},
+	"100033": {
+		"id": 100033,
+		"attType": "2:10,5",
+		"skillValue": "3230,3570"
+	}
+}

+ 5 - 0
tower_sanguo/assets/resources/data/skill_data.json.meta

@@ -0,0 +1,5 @@
+{
+  "ver": "1.0.0",
+  "uuid": "3c02e19a-7a0c-4665-a6cf-6fc4f99bdb36",
+  "subMetas": {}
+}

+ 5 - 6
tower_sanguo/assets/resources/module/fight/prefab/guanyu.prefab → tower_sanguo/assets/resources/module/fight/prefab/general_game.prefab

@@ -13,7 +13,7 @@
   },
   {
     "__type__": "cc.Node",
-    "_name": "guanyu",
+    "_name": "general_game",
     "_objFlags": 0,
     "_parent": null,
     "_children": [
@@ -79,7 +79,7 @@
   },
   {
     "__type__": "cc.Node",
-    "_name": "guanyu",
+    "_name": "spine_general",
     "_objFlags": 0,
     "_parent": {
       "__id__": 1
@@ -155,7 +155,7 @@
       }
     ],
     "paused": false,
-    "defaultSkin": "default",
+    "defaultSkin": "",
     "defaultAnimation": "",
     "_preCacheMode": 0,
     "_cacheMode": 0,
@@ -172,9 +172,7 @@
     "_headAniInfo": null,
     "_playTimes": 0,
     "_isAniComplete": true,
-    "_N$skeletonData": {
-      "__uuid__": "ff4ec9d5-e708-41f1-9c22-ce3b840a5c0f"
-    },
+    "_N$skeletonData": null,
     "_N$_defaultCacheMode": 0,
     "_N$debugSlots": false,
     "_N$debugBones": false,
@@ -205,6 +203,7 @@
     "skeleton": {
       "__id__": 3
     },
+    "skillNode": null,
     "_id": ""
   },
   {

+ 0 - 0
tower_sanguo/assets/resources/module/fight/prefab/guanyu.prefab.meta → tower_sanguo/assets/resources/module/fight/prefab/general_game.prefab.meta


+ 115 - 3
tower_sanguo/assets/resources/module/fight/prefab/monster.prefab

@@ -34,16 +34,19 @@
       },
       {
         "__id__": 26
+      },
+      {
+        "__id__": 28
       }
     ],
     "_active": true,
     "_components": [
       {
-        "__id__": 28
+        "__id__": 31
       }
     ],
     "_prefab": {
-      "__id__": 29
+      "__id__": 32
     },
     "_opacity": 255,
     "_color": {
@@ -1045,6 +1048,113 @@
     "sync": false
   },
   {
+    "__type__": "cc.Node",
+    "_name": "lbl_id",
+    "_objFlags": 0,
+    "_parent": {
+      "__id__": 1
+    },
+    "_children": [],
+    "_active": true,
+    "_components": [
+      {
+        "__id__": 29
+      }
+    ],
+    "_prefab": {
+      "__id__": 30
+    },
+    "_opacity": 255,
+    "_color": {
+      "__type__": "cc.Color",
+      "r": 255,
+      "g": 255,
+      "b": 255,
+      "a": 255
+    },
+    "_contentSize": {
+      "__type__": "cc.Size",
+      "width": 97.87,
+      "height": 50.4
+    },
+    "_anchorPoint": {
+      "__type__": "cc.Vec2",
+      "x": 0.5,
+      "y": 0.5
+    },
+    "_trs": {
+      "__type__": "TypedArray",
+      "ctor": "Float64Array",
+      "array": [
+        -81,
+        161,
+        0,
+        0,
+        0,
+        0,
+        1,
+        1,
+        1,
+        1
+      ]
+    },
+    "_eulerAngles": {
+      "__type__": "cc.Vec3",
+      "x": 0,
+      "y": 0,
+      "z": 0
+    },
+    "_skewX": 0,
+    "_skewY": 0,
+    "_is3DNode": false,
+    "_groupIndex": 0,
+    "groupIndex": 0,
+    "_id": ""
+  },
+  {
+    "__type__": "cc.Label",
+    "_name": "",
+    "_objFlags": 0,
+    "node": {
+      "__id__": 28
+    },
+    "_enabled": true,
+    "_materials": [
+      {
+        "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
+      }
+    ],
+    "_useOriginalSize": false,
+    "_string": "Label",
+    "_N$string": "Label",
+    "_fontSize": 40,
+    "_lineHeight": 40,
+    "_enableWrapText": true,
+    "_N$file": null,
+    "_isSystemFontUsed": true,
+    "_spacingX": 0,
+    "_batchAsBitmap": false,
+    "_styleFlags": 0,
+    "_underlineHeight": 0,
+    "_N$horizontalAlign": 1,
+    "_N$verticalAlign": 1,
+    "_N$fontFamily": "Arial",
+    "_N$overflow": 0,
+    "_N$cacheMode": 0,
+    "_id": ""
+  },
+  {
+    "__type__": "cc.PrefabInfo",
+    "root": {
+      "__id__": 1
+    },
+    "asset": {
+      "__uuid__": "15eedabd-b8b2-426a-abad-3d9159ae2418"
+    },
+    "fileId": "b9uHVhYbtA9Lzx1u3ZZzxV",
+    "sync": false
+  },
+  {
     "__type__": "1b5d8L6KapJN40RfXfD64b8",
     "_name": "",
     "_objFlags": 0,
@@ -1068,7 +1178,9 @@
       "__id__": 15
     },
     "attachNode": null,
-    "lbl_test": null,
+    "lbl_id": {
+      "__id__": 29
+    },
     "_id": ""
   },
   {

+ 0 - 0
tower_sanguo/assets/resources/module/fight/texture/attack_daoguang.png → tower_sanguo/assets/resources/module/fight/texture/fight_1.png


+ 1 - 1
tower_sanguo/assets/resources/module/fight/texture/attack_daoguang.png.meta → tower_sanguo/assets/resources/module/fight/texture/fight_1.png.meta

@@ -11,7 +11,7 @@
   "height": 108,
   "platformSettings": {},
   "subMetas": {
-    "attack_daoguang": {
+    "fight_1": {
       "ver": "1.0.4",
       "uuid": "8c81f397-0d5a-47c7-874f-3f5a95249dfa",
       "rawTextureUuid": "c3f87849-bbda-4376-bd76-56b53bd25714",

+ 0 - 5
tower_sanguo/assets/resources/spine/person/guanyu.atlas.meta

@@ -1,5 +0,0 @@
-{
-  "ver": "1.0.1",
-  "uuid": "4bd96ce0-ea34-48f1-b4b0-cef8c3be6705",
-  "subMetas": {}
-}

+ 0 - 9
tower_sanguo/assets/resources/spine/person/guanyu.json.meta

@@ -1,9 +0,0 @@
-{
-  "ver": "1.2.3",
-  "uuid": "ff4ec9d5-e708-41f1-9c22-ce3b840a5c0f",
-  "textures": [
-    "b732080b-2e6e-4c01-b715-2dd7e52c0b37"
-  ],
-  "scale": 1,
-  "subMetas": {}
-}

+ 1 - 1
tower_sanguo/assets/resources/spine/person/guanyu.atlas → tower_sanguo/assets/resources/spine/person/hero_shu_GY.atlas

@@ -1,5 +1,5 @@
 
-guanyu.png
+hero_shu_GY.png
 size: 602,269
 format: RGBA8888
 filter: Linear,Linear

+ 5 - 0
tower_sanguo/assets/resources/spine/person/hero_shu_GY.atlas.meta

@@ -0,0 +1,5 @@
+{
+  "ver": "1.0.1",
+  "uuid": "4f237fe4-759e-4523-853c-d9cff278f4de",
+  "subMetas": {}
+}

+ 0 - 0
tower_sanguo/assets/resources/spine/person/guanyu.json → tower_sanguo/assets/resources/spine/person/hero_shu_GY.json


+ 9 - 0
tower_sanguo/assets/resources/spine/person/hero_shu_GY.json.meta

@@ -0,0 +1,9 @@
+{
+  "ver": "1.2.3",
+  "uuid": "5a793b59-e6ea-4ed4-bcb4-8477933e2e48",
+  "textures": [
+    "156c8393-9f4d-4bb0-b37f-545634a2e15c"
+  ],
+  "scale": 1,
+  "subMetas": {}
+}

+ 0 - 0
tower_sanguo/assets/resources/spine/person/guanyu.png → tower_sanguo/assets/resources/spine/person/hero_shu_GY.png


+ 4 - 4
tower_sanguo/assets/resources/spine/person/guanyu.png.meta → tower_sanguo/assets/resources/spine/person/hero_shu_GY.png.meta

@@ -1,6 +1,6 @@
 {
   "ver": "2.3.4",
-  "uuid": "b732080b-2e6e-4c01-b715-2dd7e52c0b37",
+  "uuid": "156c8393-9f4d-4bb0-b37f-545634a2e15c",
   "type": "sprite",
   "wrapMode": "clamp",
   "filterMode": "bilinear",
@@ -11,10 +11,10 @@
   "height": 269,
   "platformSettings": {},
   "subMetas": {
-    "guanyu": {
+    "hero_shu_GY": {
       "ver": "1.0.4",
-      "uuid": "60e3de68-62d1-4cc4-a984-f7b6a81c6db5",
-      "rawTextureUuid": "b732080b-2e6e-4c01-b715-2dd7e52c0b37",
+      "uuid": "dd48e0f2-bbe6-4cfa-9adb-814b803eddca",
+      "rawTextureUuid": "156c8393-9f4d-4bb0-b37f-545634a2e15c",
       "trimType": "auto",
       "trimThreshold": 1,
       "rotated": false,

+ 13 - 7
tower_sanguo/assets/scripts/data/GameData.ts

@@ -21,8 +21,9 @@ export default class GameData {
     player: PlayerVO;
     pools = [
         { name: "HpTips", num: 20 },
-        { name: "Monster", num: 50 },
-        { name: "AttackModel", num: 20 }
+        { name: "Monster", num: 120 },
+        { name: "AttackModel", num: 40 },
+        { name: 'General', num: 6 },
     ];
     private buff_data: any;
     private general_data: any;
@@ -32,12 +33,17 @@ export default class GameData {
 
 
     async initLocalConfigs() {
-        if (!cc.debug) {
+        if (cc.debug) {
             this.skill_data = await GameController.resM.loadRemoteJson('https://xcx-box.oss-cn-hangzhou.aliyuncs.com/hotgame/h5game/tower_sanguo/data/skill_data.json?v=' + new Date().getTime());
             this.general_data = await GameController.resM.loadRemoteJson('https://xcx-box.oss-cn-hangzhou.aliyuncs.com/hotgame/h5game/tower_sanguo/data/general_data.json?v=' + new Date().getTime());
             this.monster_data = await GameController.resM.loadRemoteJson('https://xcx-box.oss-cn-hangzhou.aliyuncs.com/hotgame/h5game/tower_sanguo/data/monster_data.json?v=' + new Date().getTime());
             this.mission_data = await GameController.resM.loadRemoteJson('https://xcx-box.oss-cn-hangzhou.aliyuncs.com/hotgame/h5game/tower_sanguo/data/mission_data.json?v=' + new Date().getTime());
 
+            // this.skill_data = cc.loader.getRes('data/skill_data').json;
+            // this.general_data = cc.loader.getRes('data/general_data').json;
+            // this.monster_data = cc.loader.getRes('data/monster_data').json;
+            // this.mission_data = cc.loader.getRes('data/mission_data').json;
+
             this.initJsonData();
         }
         else {
@@ -67,7 +73,6 @@ export default class GameData {
     }
 
     private initJsonData() {
-
         for (let i in this.skill_data) {
             let o = this.skill_data[i];
             let vo: SkillVO = new SkillVO();
@@ -90,11 +95,12 @@ export default class GameData {
             vo.attack = o.attack;
             vo.acc = o.acc;
             vo.attSpeed = o.attSpeed;
+            vo.atk_res = o.atk_res;
             vo.color = o.color;
             vo.commander = o.commander;
             vo.intStar = o.intStar;
             vo.name = o.name;
-            vo.resource = o.resource;
+            vo.resource = o.hero_res;
             vo.skillID = o.skillID;
             vo.upRatio = o.upRatio;
             vo.lv = 1;
@@ -131,7 +137,7 @@ export default class GameData {
         ServerDataUtil.decompressServerConfigs(data);
 
         this.player = new PlayerVO();
-        this.player.generals = [1, 1, 0, -1, 0];
+        this.player.generals = [0, 124014, 0, -1, 0];
         this.player.generals_bag = [];
         this.player.current_mission = 1;
         this.player.max_mission = 1;
@@ -164,7 +170,7 @@ export default class GameData {
         return this.mission_data['max'];
     }
 
-    getMonsterByID(id){
+    getMonsterByID(id) {
         return this.monster_data[id];
     }
 

+ 88 - 40
tower_sanguo/assets/scripts/module/fight/FightUI.ts

@@ -55,33 +55,40 @@ export default class FightUI extends BaseUI {
 
         this.fightData = GameController.gameData.fightData;
 
-        this.initMissionData();
+        this.loadGeneralRes();
     }
 
-    start() {
+    private resetGame() {
         this.isGaming = true;
         this.frame_count = 0;
         this.monster_count = 0;
         this.general_count = 0;
     }
-    startGame() {
-        this.isGaming = true;
-        this.frame_count = 0;
-        this.monster_count = 0;
-        this.general_count = 0;
 
-        this.startRound();
-    }
 
+    /** 加载当前场上武将动画资源 */
+    private loadGeneralRes() {
+        let playerInfo = GameController.gameData.player;
+        let res = [];
+        for (let i = 0; i < playerInfo.generals.length; i++) {
+            if (playerInfo.generals[i] < 1) {
+                continue;
+            }
+            let vo = GameController.gameData.getGeneralByID(playerInfo.generals[i]);
+            res.push("spine/person/" + vo.resource);
+        }
+        cc.loader.loadResArray(res, sp.SkeletonData, this.initMissionData.bind(this));
+    }
+    /** 初始化关卡,武将 */
     private initMissionData() {
         this.monster_arr = [];
         this.general_arr = [];
+        this.resetGame();
 
         let playerInfo = GameController.gameData.player;
-        let gs = playerInfo.generals;
-        this.initGenerals(gs);
-
         this.current_mission = playerInfo.current_mission;
+        this.initGenerals(playerInfo.generals);
+
         this.updateMission();
     }
     private initGenerals(gs) {
@@ -95,9 +102,9 @@ export default class FightUI extends BaseUI {
         }
     }
     private createGeneral(index, vo: GeneralVO) {
-        let prefab = GameController.resM.getRes(FightData.prefab_url + vo.resource, cc.Prefab);
-        let node = cc.instantiate(prefab);
+        let node = GameController.pool.getPrefabByClassName("General");
         this.node.addChild(node);
+
         let general = node.getComponent(General) as General;
         let v2 = this.generalCroods[index];
         general.node.x = v2.x;
@@ -106,13 +113,6 @@ export default class FightUI extends BaseUI {
         this.general_arr.push(general);
     }
 
-    private startRound() {
-        this.schedule(this.createMonster.bind(this), this.roundVO.cd, this.roundVO.monster_num - 1);
-    }
-    private endRound() {
-        this.round++;
-        this.scheduleOnce(this.updateRound.bind(this), this.missionVO.cd);
-    }
     private updateRound() {
         if (!this.missionVO) {
             return;
@@ -130,6 +130,18 @@ export default class FightUI extends BaseUI {
             this.startRound();
         }
     }
+    private startRound() {
+        this.schedule(this.createMonster.bind(this, this), this.roundVO.cd);
+    }
+    private endRound() {
+        this.round++;
+        if (this.missionVO.cd) {
+            this.scheduleOnce(this.updateRound.bind(this), this.missionVO.cd);
+        }
+        else {
+            this.updateRound();
+        }
+    }
 
 
     /** 更新关卡 */
@@ -212,6 +224,9 @@ export default class FightUI extends BaseUI {
 
     private createMonster() {
         let node = GameController.pool.getPrefabByClassName("Monster");
+        if (!node) {
+            return;
+        }
         let click_node = node.getChildByName("click_node");
         if (cc.sys.os == cc.sys.OS_WINDOWS) {
             click_node.on(cc.Node.EventType.MOUSE_DOWN, this.selectMonster, this);
@@ -233,12 +248,38 @@ export default class FightUI extends BaseUI {
         this.monster_left--;
         this.roundVO.monster_num--;
         if (this.roundVO.monster_num <= 0) {
+            this.unscheduleAllCallbacks();
             this.endRound();
         }
     }
 
-    createAttackEffect(general: General, target: Monster, scaleRate: number) {
-        if (!target || target.isDead()) {
+    createAttackEffects(general: General, target: Monster, scaleRate: number) {
+        let brr: Monster[] = [];
+        //如果是多目标技能,添加多目标(没有过滤主目标,下面处理)
+        if (general.vo.skill.attackNum > 1) {
+            let arr = this.monster_arr.slice();
+            for (let i = 0; i < general.vo.skill.attackNum; i++) {
+                let n = Math.floor(Math.random() * arr.length);
+                brr = brr.concat(arr.splice(n, 1));
+            }
+        }
+        brr.unshift(target);
+        let n = general.vo.skill.attackNum;
+        for (let i = 0; i < brr.length; i++) {
+            //因为上面没有过滤主目标,如果不是第一个,后面id一样就重复了,过滤
+            if (i > 0 && brr[i].id == target.id) {
+                continue;
+            }
+            n--;
+            //如果没有过滤,一共是4个,只需要处理3个
+            if (n >= 0) {
+                this.createAttackEffect(general, brr[i], scaleRate);
+            }
+        }
+
+    }
+    private createAttackEffect(general: General, target: Monster, scaleRate: number) {
+        if (!target || target.canAttack()) {
             return;
         }
         let node = GameController.pool.getPrefabByClassName("AttackModel");
@@ -252,7 +293,7 @@ export default class FightUI extends BaseUI {
         let i = 0;
         while (true) {
             let m = this.monster_arr[i];
-            if (m && !m.isDead()) {
+            if (m && !m.canAttack()) {
                 return m;
             }
             i++;
@@ -264,7 +305,7 @@ export default class FightUI extends BaseUI {
 
     private getCurrentMonster() {
         let target: Monster;
-        if (this.targetMonster && !this.targetMonster.isDead()) {
+        if (this.targetMonster && !this.targetMonster.canAttack()) {
             target = this.targetMonster;
         }
         else {
@@ -280,6 +321,9 @@ export default class FightUI extends BaseUI {
     }
 
     update() {
+        if (!this.isGaming) {
+            return;
+        }
         this.frame_count++;
         if (this.frame_count % 3 == 0) {
             this.updateMonsterOrder();
@@ -293,29 +337,32 @@ export default class FightUI extends BaseUI {
         }
     }
 
+    /** 对所有怪物进行层级排序 */
     private updateMonsterOrder() {
-        //[-306, 658, -275, -250, -150, -350, 200, -350, 292, -177, 292, 270, 307, 654];
         this.monster_arr.sort((a: Monster, b: Monster) => {
-            if (a.moveStep < b.moveStep) {
+            if (!a.isDead() && b.isDead()) {
                 return -1;
             }
-            else if (a.moveStep > b.moveStep) {
+            if (a.moveStep > b.moveStep) {
+                return -1;
+            }
+            else if (a.moveStep < b.moveStep) {
                 return 1;
             }
             else {
                 switch (a.moveStep) {
                     case 1://↓
-                        return a.node.y > b.node.y ? -1 : 1;
+                        return a.node.y < b.node.y ? -1 : 1;
                     case 2://↘
-                        return a.node.x < b.node.x ? -1 : 1;
+                        return a.node.y < b.node.x ? -1 : 1;
                     case 3://→
-                        return a.node.x < b.node.x ? -1 : 1;
+                        return a.node.x > b.node.x ? -1 : 1;
                     case 4://↗
-                        return a.node.x < b.node.x ? -1 : 1;
+                        return a.node.x > b.node.x ? -1 : 1;
                     case 5://↑
-                        return a.node.y < b.node.y ? -1 : 1;
+                        return a.node.y > b.node.y ? -1 : 1;
                     case 6://↗
-                        return a.node.y < b.node.y ? -1 : 1;
+                        return a.node.y > b.node.y ? -1 : 1;
                     default:
                         return -1;
                 }
@@ -323,9 +370,11 @@ export default class FightUI extends BaseUI {
         });
 
         let len = this.monster_arr.length;
+        let l = this.node.children.length;
         for (let i = 0; i < len; i++) {
-            this.monster_arr[i].node.setSiblingIndex(5 + i);
+            this.monster_arr[i].node.setSiblingIndex(l - 1 - i);
         }
+
     }
 
     private checkGeneralAction() {
@@ -337,9 +386,6 @@ export default class FightUI extends BaseUI {
                 general.setTarget(this.targetMonster);
             }
         }
-
-
-
     }
 
     private selectMonster(e) {
@@ -368,7 +414,7 @@ export default class FightUI extends BaseUI {
         this.monster_arr = [];
         this.targetMonster = null;
     }
-    clearMonster(id) {
+    clearMonster(id, realdead = true) {
         for (let i = 0; i < this.monster_arr.length; i++) {
             let m = this.monster_arr[i];
             if (m.id == id) {
@@ -376,7 +422,9 @@ export default class FightUI extends BaseUI {
                     this.targetMonster = null;
                 }
                 this.resetMonster(m);
-                this.monster_arr.splice(i, 1);
+                if (realdead) {
+                    this.monster_arr.splice(i, 1);
+                }
                 break;
             }
         }

+ 0 - 54
tower_sanguo/assets/scripts/module/fight/model/BaseModel.ts

@@ -1,54 +0,0 @@
-
-/**
- * 
- * 武将,怪物基类
- * 
- */
-const { ccclass, property } = cc._decorator;
-
-@ccclass
-export default class BaseModel extends cc.Component {
-
-    @property(sp.Skeleton)
-    skeleton: sp.Skeleton = null;
-    
-
-    attachNode: cc.Node;
-
-    onLoad() {
-        
-
-    }
-
-    /**
-     * 获取挂点,设置挂点碰撞
-     */
-    protected setCollider(attachNodeName, colliderType: any) {
-        // let attachUtil = this.skeleton.attachUtil;
-        // let boneNodes = attachUtil.generateAttachedNodes(attachNodeName);
-        // if(boneNodes.length == 0){
-        //     console.log("找不到该挂点:",attachNodeName);
-        //     return;
-        // }
-        // this.attachNode = boneNodes[0];
-        // this.attachNode.addComponent(colliderType);
-        // this.attachNode.group = 'monster';
-    }
-
-    /**
-     * 销毁挂点
-     */
-    private destroyCollider() {
-        // if (this.skeleton) {
-        //     let attachUtil = this.skeleton.attachUtil;
-        //     if (this.attachNode) {
-        //         attachUtil.destroyAttachedNodes(this.attachNode);
-        //     }
-        // }
-    }
-
-
-    onDestroy(){
-        this.destroyCollider();
-    }
-}

+ 0 - 9
tower_sanguo/assets/scripts/module/fight/model/BaseModel.ts.meta

@@ -1,9 +0,0 @@
-{
-  "ver": "1.0.8",
-  "uuid": "ad29a4da-a002-4449-a4d0-41b3ab187569",
-  "isPlugin": false,
-  "loadPluginInWeb": true,
-  "loadPluginInNative": true,
-  "loadPluginInEditor": false,
-  "subMetas": {}
-}

+ 2 - 2
tower_sanguo/assets/scripts/module/fight/model/attack/AttackModel.ts

@@ -34,7 +34,7 @@ export default class AttackModel extends cc.Component implements IPool {
     }
 
     init(src: General, target: Monster) {
-        this.img_attackType.spriteFrame = cc.loader.getRes("module/fight/texture/attack_daoguang",cc.SpriteFrame);
+        this.img_attackType.spriteFrame = cc.loader.getRes("module/fight/texture/" + src.vo.atk_res,cc.SpriteFrame);
         this.src = src;
         this.target = target;
         let v = GameUtil.localConvertWorldPointARCenter(this.src.skillNode);
@@ -56,7 +56,7 @@ export default class AttackModel extends cc.Component implements IPool {
     onHit() {
         if (this.target && !this.target.isDead()) {
             let hitrate = (this.src.vo.acc - this.target.vo.miss) / 10000;
-            this.target.unAttack(hitrate, this.src.getDamage());
+            this.target.onAttack(hitrate, this.src.getDamage());
         }
         this.clear();
     }

+ 55 - 33
tower_sanguo/assets/scripts/module/fight/model/generals/General.ts

@@ -1,7 +1,7 @@
+import GameController from "../../../../GameController";
 import GeneralVO from "../../../../vo/GeneralVO";
 import { GENERAL_ACTION } from "../../FightData";
 import FightUI from "../../FightUI";
-import BaseModel from "../BaseModel";
 import Monster from "../monsters/Monster";
 
 /**
@@ -9,21 +9,28 @@ import Monster from "../monsters/Monster";
  * 武将
  * 
  */
-const { ccclass } = cc._decorator;
+const { ccclass,property } = cc._decorator;
 
 @ccclass
-export default class General extends BaseModel {
+export default class General extends cc.Component implements IPool {
 
+    public static prefabUrl = 'module/fight/prefab/general_game';
+
+    @property(sp.Skeleton)
+    skeleton:sp.Skeleton = null;
+
+    @property(cc.Node)
+    skillNode: cc.Node = null;
 
     /** 武将摆放位置 0-4 */
     private pos: number;
-    vo:GeneralVO;
-    target: Monster;
     private scaleRate: number = 1;
     attack_value: number = 266;
-
+    
     private actions_wait: string[];
-    skillNode: cc.Node;
+    
+    target: Monster;
+    vo: GeneralVO;
 
     private _action: string;
     set action(v: string) {
@@ -43,47 +50,38 @@ export default class General extends BaseModel {
         return this._action;
     }
 
-
-
     onLoad() {
-        this.initData();
-        this.initView();
-        this.initEvent();
-
-        this.action = GENERAL_ACTION.IDLE;
-    }
-
-    private initData() {
         this.actions_wait = [];
     }
 
-    private initView() {
-        let attachUtil = this.skeleton.attachUtil;
-        let boneNodes = attachUtil.generateAttachedNodes('attack');
-        this.skillNode = boneNodes[0];
-    }
-
-    private initEvent() {
+    start(){
         this.skeleton.setEventListener(this.createAttackEffect.bind(this));
-        this.skeleton.setCompleteListener(this.actionComplete.bind(this))
-
-
+        this.skeleton.setCompleteListener(this.actionComplete.bind(this));
     }
 
-    init(pos,v) {
+    init(pos, v) {
         this.pos = pos;
         this.vo = v;
         this.vo.lv = 1;
         this.vo.star = 1;
-        //获取spine动画的帧数并设置攻击速度
-        let ani = this.skeleton.findAnimation("attack");
-        this.skeleton.timeScale = ani.duration * this.vo.attSpeed;
         
         this.scaleRate = pos == 4 ? 1 : 0.6;
         this.node.scaleX = this.node.scaleY = this.scaleRate;
+
+        this.skeleton.skeletonData = cc.loader.getRes("spine/person/" + v.resource, sp.SkeletonData);
+
+        //获取spine动画的帧数并设置攻击速度
+        let ani = this.skeleton.findAnimation("attack");
+        this.skeleton.timeScale = ani.duration * this.vo.attSpeed;
+
+        let attachUtil = this.skeleton.attachUtil;
+        let boneNodes = attachUtil.generateAttachedNodes('attack');
+        this.skillNode = boneNodes[0];
+
+        this.action = GENERAL_ACTION.IDLE;
     }
 
-    getDamage(){
+    getDamage() {
         return this.vo.getDamage();
     }
 
@@ -97,7 +95,7 @@ export default class General extends BaseModel {
     private createAttackEffect(a, b) {
         if (b && b.data && b.data.name == 'attack') {
             let fight = this.node.parent.getComponent('FightUI') as FightUI;
-            fight.createAttackEffect(this, this.target, this.scaleRate);
+            fight.createAttackEffects(this, this.target, this.scaleRate);
         }
     }
 
@@ -119,4 +117,28 @@ export default class General extends BaseModel {
     attack() {
 
     }
+
+    reset() {
+        this.vo = null;
+        this.target = null;
+        this.scaleRate = 1;
+        this.attack_value = null;
+        this.actions_wait = [];
+        this._action = GENERAL_ACTION.IDLE;
+
+        this.node.scaleX = this.node.scaleY = 1;
+        
+        
+        this.skillNode = null;
+
+        let attachUtil = this.skeleton.attachUtil;
+        let boneNodes = attachUtil.generateAttachedNodes('attack');
+        this.skillNode = boneNodes[0];
+}
+
+clear(){
+    this.reset();
+
+    GameController.pool.returnPrefabByClassName("General", this.node);
+}
 }

+ 32 - 8
tower_sanguo/assets/scripts/module/fight/model/monsters/Monster.ts

@@ -37,12 +37,17 @@ export default class Monster extends cc.Component implements IPool {
     @property(cc.Node)
     attachNode: cc.Node = null;
 
+    @property(cc.Label)
+    lbl_id: cc.Label = null;
+
     private moveCroods: number[];
     vo: MonsterVO;
 
     id: number;
     moveStep: number = 0;
 
+    private isdead: boolean;
+
 
     getAttachNodeCrood() {
         if (!this.attachNode) {
@@ -55,6 +60,11 @@ export default class Monster extends cc.Component implements IPool {
 
     }
 
+    start() {
+        this.bing_die.setCompleteListener(this.realDead.bind(this));
+        this.knife_light.setCompleteListener(this.hitAnimCom.bind(this));
+    }
+
     init(v: MonsterVO) {
         this.id = v.id;
         this.vo = v;
@@ -63,7 +73,7 @@ export default class Monster extends cc.Component implements IPool {
         this.node.x = this.moveCroods[0];
         this.node.y = this.moveCroods[1];
 
-        this.bing_die.setCompleteListener(this.realDead.bind(this));
+        this.lbl_id.string = v.id + "";
 
         this.skeleton.skeletonData = cc.loader.getRes("spine/person/" + v.resource, sp.SkeletonData);
 
@@ -85,7 +95,7 @@ export default class Monster extends cc.Component implements IPool {
      * @param hitrate 命中率
      * @param attack_value 伤害
      */
-    unAttack(hitrate: number, attack_value: number) {
+    onAttack(hitrate: number, attack_value: number) {
         let hitvalue = Math.random() < hitrate ? attack_value : 0;
 
         this.knife_light.node.active = true;
@@ -96,7 +106,8 @@ export default class Monster extends cc.Component implements IPool {
         this.vo.hp -= hitvalue;
         if (this.vo.hp <= 0) {
             this.vo.hp = 0;
-            this.dead();
+            let fight = this.node.parent.getComponent('FightUI') as FightUI;
+            fight.clearMonster(this.id, false);
         }
         this.bar_monster.setProgress(this.vo.hp, true);
     }
@@ -113,20 +124,30 @@ export default class Monster extends cc.Component implements IPool {
         this.node.addChild(node, 0);
     }
 
-    isDead() {
+    /** 血条清0后,不参与受攻击,但仍然会移动,直到受攻击特效播放完毕变成墓碑才 */
+    canAttack() {
         return !this.vo || this.vo.hp <= 0;
     }
 
+    isDead() {
+        return this.isdead;
+    }
+
+    /** 受攻击特效播放完毕,变成墓碑,实体静止,并且层级移动到最小层 */
     dead() {
         this.skeleton.node.active = false;
         this.bar_monster.node.active = false;
         this.bing_die.node.active = true;
         this.img_select.node.active = false;
         this.bing_die.animation = 'animation';
-        this.attachNode.group = 'default';
 
-        let fight = this.node.parent.getComponent('FightUI') as FightUI;
-        fight.clearMonster(this.id);
+        this.isdead = true;
+    }
+
+    private hitAnimCom() {
+        if (this.canAttack()) {
+            this.dead();
+        }
     }
 
     private realDead() {
@@ -175,6 +196,7 @@ export default class Monster extends cc.Component implements IPool {
 
     //放回对象池时重置
     reset() {
+        this.isdead = false;
         this.skeleton.node.active = true;
         this.img_select.node.active = false;
         this.bing_die.node.active = false;
@@ -190,7 +212,6 @@ export default class Monster extends cc.Component implements IPool {
         this.bar_monster.init(1, 1);
 
         if (this.attachNode) {
-            this.attachNode.group = 'default';
             this.attachNode = null;
         }
         this.skeleton.skeletonData = null;
@@ -199,6 +220,9 @@ export default class Monster extends cc.Component implements IPool {
     clear() {
         this.reset();
 
+        let fight = this.node.parent.getComponent('FightUI') as FightUI;
+        fight.clearMonster(this.id);
+
         //清理所有伤害
         for (let i = 0; i < this.node.children.length; i++) {
             let node = this.node.children[i];

+ 1 - 1
tower_sanguo/assets/scripts/module/main/MainUI.ts

@@ -34,7 +34,7 @@ export default class MainUI extends BaseUI {
     }
 
     startGame() {
-        this.fightui && this.fightui.startGame();
+        
     }
 
     setChlBtnDisplay(b){

+ 2 - 0
tower_sanguo/assets/scripts/vo/GeneralVO.ts

@@ -14,9 +14,11 @@ export default class GeneralVO {
 
 
     id: number;
+    camp:number;
     name: string;
     color: number;
     attSpeed: number;
+    atk_res:string;
     private _skillID: number;
     set skillID(v: number) {
         this._skillID = v;

+ 1 - 1
tower_sanguo/settings/project.json

@@ -35,7 +35,7 @@
     "3D Physics/Builtin",
     "3D Particle"
   ],
-  "last-module-event-record-time": 1616752282737,
+  "last-module-event-record-time": 1617422381174,
   "design-resolution-width": 750,
   "design-resolution-height": 1334,
   "fit-width": true,