فهرست منبع

英雄怪物的基础算法对齐

lcn 4 ماه پیش
والد
کامیت
d1525628c0
1فایلهای تغییر یافته به همراه17 افزوده شده و 17 حذف شده
  1. 17 17
      Assets/Scripts/GameLogic/Combat/Hero/CombatHeroInfo.cs

+ 17 - 17
Assets/Scripts/GameLogic/Combat/Hero/CombatHeroInfo.cs

@@ -100,28 +100,28 @@ public class CombatHeroInfo
         promoteConfig = ConfigComponent.Instance.Get<HeroPromoteConfig>(star);
     }
     
-    public void InitMonster(int id,int level, int star)
+    public void InitMonster(int modelID,int level, int star = 1)
     {
-        SetDataConfig(id, level, star);
+        SetDataConfig(modelID, level, star);
         CalFactor();
         CalAttribute();
     }
 
-    public void InitMonster(int id,int level)
-    {
-        HeroModelConfig heroModelConfig = ConfigComponent.Instance.Get<HeroModelConfig>(id);
-        HeroPowerUpConfig heroPowerUpConfig = ConfigComponent.Instance.Get<HeroPowerUpConfig>(level);
-        hp = (EncryptionLong)(heroModelConfig.hp*heroPowerUpConfig.HPFactor);
-        defense=(EncryptionLong)(heroModelConfig.def*heroPowerUpConfig.DEFFactor);
-        attack=(EncryptionLong)(heroModelConfig.attack*heroPowerUpConfig.ATKFactor);
-        attSpeed=(EncryptionFloat)heroModelConfig.speed_atk;
-        crit=(EncryptionFloat)heroModelConfig.crit;
-        skillId = heroModelConfig.skillID;
-        modelName = heroModelConfig.model;
-        isGpu = heroModelConfig.isUseGpu;
-        maxDis=heroModelConfig.range_atk;
-        maxDisTo = maxDis * maxDis;
-    }
+    // public void InitMonster(int id,int level)
+    // {
+    //     HeroModelConfig heroModelConfig = ConfigComponent.Instance.Get<HeroModelConfig>(id);
+    //     HeroPowerUpConfig heroPowerUpConfig = ConfigComponent.Instance.Get<HeroPowerUpConfig>(level);
+    //     hp = (EncryptionLong)(heroModelConfig.hp*heroPowerUpConfig.HPFactor);
+    //     defense=(EncryptionLong)(heroModelConfig.def*heroPowerUpConfig.DEFFactor);
+    //     attack=(EncryptionLong)(heroModelConfig.attack*heroPowerUpConfig.ATKFactor);
+    //     attSpeed=(EncryptionFloat)heroModelConfig.speed_atk;
+    //     crit=(EncryptionFloat)heroModelConfig.crit;
+    //     skillId = heroModelConfig.skillID;
+    //     modelName = heroModelConfig.model;
+    //     isGpu = heroModelConfig.isUseGpu;
+    //     maxDis=heroModelConfig.range_atk;
+    //     maxDisTo = maxDis * maxDis;
+    // }
 
     public CombatHeroInfo Copy()
     {