1
This commit is contained in:
parent
8a236fba5a
commit
0053647441
@ -11,6 +11,9 @@ namespace Unity.Startup.Procedure
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public sealed class ProcedureGetAppVersionInfoState : ProcedureBase
|
public sealed class ProcedureGetAppVersionInfoState : ProcedureBase
|
||||||
{
|
{
|
||||||
|
private const int MaxTryCount = 3;
|
||||||
|
private int currentTryCount;
|
||||||
|
|
||||||
protected override void OnEnter()
|
protected override void OnEnter()
|
||||||
{
|
{
|
||||||
base.OnEnter();
|
base.OnEnter();
|
||||||
@ -22,6 +25,7 @@ namespace Unity.Startup.Procedure
|
|||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
currentTryCount++;
|
||||||
if (StartupSetting.Version != AppVersion.GameVersion)
|
if (StartupSetting.Version != AppVersion.GameVersion)
|
||||||
{
|
{
|
||||||
Log.Warning($"Version inconsistency : {AppVersion.GameVersion}->{StartupSetting.Version} ");
|
Log.Warning($"Version inconsistency : {AppVersion.GameVersion}->{StartupSetting.Version} ");
|
||||||
@ -34,11 +38,17 @@ namespace Unity.Startup.Procedure
|
|||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
SwitchProcedure<ProcedureInitPackageState>();
|
SwitchProcedure<ProcedureInitPackageState>();
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
Log.Exception(e);
|
Log.Exception(e);
|
||||||
|
if (currentTryCount > MaxTryCount)
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
await UniTask.Delay(3000);
|
await UniTask.Delay(3000);
|
||||||
GetAppVersionInfo();
|
GetAppVersionInfo();
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1 +1 @@
|
|||||||
Subproject commit 49ecff82621c18e1521ed58d72bb6f932d5da658
|
Subproject commit 839af110274ffe9498f4de468723ced56216b0f5
|
||||||
Loading…
Reference in New Issue
Block a user