zhaoyang 3 жил өмнө
parent
commit
3853e1c161

+ 2 - 1
GameClient/Assets/Game/HotUpdate/Data/FunctionOpenDataManager.cs

@@ -95,7 +95,8 @@ namespace GFGGame
         //检测配置角色是否开启
         private bool CheckIsLvFunOpen(FunctionOpenCfg cfg, bool showTips = true)
         {
-            if (GameGlobal.myNumericComponent.GetAsInt(NumericType.Lvl) >= cfg.lv)
+            //GameGlobal.myNumericComponent.GetAsInt(NumericType.Lvl)
+            if (RoleDataManager.lvl >= cfg.lv)
             {
                 return true;
             }

+ 3 - 3
GameClient/Assets/Game/HotUpdate/Data/RoleDataManager.cs

@@ -26,7 +26,7 @@ namespace GFGGame
         {
             get
             {
-                return GameGlobal.myNumericComponent.GetAsInt(NumericType.Gold);
+                return ItemDataManager.GetItemNum(ConstItemID.GOLD); //GameGlobal.myNumericComponent.GetAsInt(NumericType.Gold);
             }
         }
         private static int _exp = 0;
@@ -50,7 +50,7 @@ namespace GFGGame
         {
             get
             {
-                return GameGlobal.myNumericComponent.GetAsInt(NumericType.DiamondP);
+                return ItemDataManager.GetItemNum(ConstItemID.DIAMOND_PURPLE); // GameGlobal.myNumericComponent.GetAsInt(NumericType.DiamondP);
             }
         }
 
@@ -58,7 +58,7 @@ namespace GFGGame
         {
             get
             {
-                return GameGlobal.myNumericComponent.GetAsInt(NumericType.DiamondR);
+                return ItemDataManager.GetItemNum(ConstItemID.DIAMOND_RED); //GameGlobal.myNumericComponent.GetAsInt(NumericType.DiamondR);
             }
         }
         public static int Liveness

+ 3 - 3
GameClient/Assets/Game/HotUpdate/Views/Common/Controller/ValueBarController.cs

@@ -93,10 +93,10 @@ namespace GFGGame
 
         private void UpdateNumeric()
         {
-            _valueBar.m_btnGold.text = "" + GameGlobal.myNumericComponent.GetAsInt(NumericType.Gold);
+            _valueBar.m_btnGold.text = "" + RoleDataManager.gold; //GameGlobal.myNumericComponent.GetAsInt(NumericType.Gold);
             _valueBar.m_btnPower.text = string.Format("{0}/{1}", GameGlobal.myNumericComponent.GetAsInt(NumericType.Power), GameGlobal.myNumericComponent.GetAsInt(NumericType.PowerLimit));
-            _valueBar.m_btnDiamondPurple.text = "" + GameGlobal.myNumericComponent.GetAsInt(NumericType.DiamondP);
-            _valueBar.m_btnDiamondRed.text = "" + GameGlobal.myNumericComponent.GetAsInt(NumericType.DiamondR);
+            _valueBar.m_btnDiamondPurple.text = "" + RoleDataManager.diaP;// GameGlobal.myNumericComponent.GetAsInt(NumericType.DiamondP);
+            _valueBar.m_btnDiamondRed.text = "" + RoleDataManager.diaR;// GameGlobal.myNumericComponent.GetAsInt(NumericType.DiamondR);
 
 
         }