瀏覽代碼

Bugly联盟值数据推送后接收防止报错处理

huangxiaoyue 1 年之前
父節點
當前提交
b56e9c6ac6
共有 1 個文件被更改,包括 4 次插入1 次删除
  1. 4 1
      GameClient/Assets/Game/HotUpdate/Data/LeagueDataManager.cs

+ 4 - 1
GameClient/Assets/Game/HotUpdate/Data/LeagueDataManager.cs

@@ -49,7 +49,10 @@ namespace GFGGame
         }
         public void SetNumeric(int type, long value)
         {
-            LeagueNumber[type] = value;
+            if(LeagueNumber.ContainsKey(type))
+                LeagueNumber[type] = value;
+            else
+                LeagueNumber.Add(type, value);
         }
 
         public long GetNumeriValue(int type)