소스 검색

该Entity已经包含组件判断。。

xyh1985 1 년 전
부모
커밋
9c338c35a4
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      Unity/Assets/Scripts/Codes/Hotfix/Client/Login/LoginHelper.cs

+ 1 - 1
Unity/Assets/Scripts/Codes/Hotfix/Client/Login/LoginHelper.cs

@@ -48,7 +48,7 @@ namespace ET.Client
                     Log.Error($"登陆game错误...errCode={g2CLoginGame.Error}");
                     return;
                 }
-                if (ConstValue.SessionTimeoutTime > 0)
+                if (ConstValue.SessionTimeoutTime > 0 && gameSession.GetComponent<SessionIdleCheckerComponent>() == null)
                 {
                     gameSession.AddComponent<SessionIdleCheckerComponent>();
                 }