mirror of https://github.com/tuyoogame/YooAsset
parent
576b842368
commit
cc7290f10e
|
@ -13,6 +13,11 @@ namespace YooAsset
|
|||
private static Stopwatch _watch;
|
||||
private static long _frameTime;
|
||||
|
||||
/// <summary>
|
||||
/// 快速启动模式
|
||||
/// </summary>
|
||||
public static bool QuickStartMode = false;
|
||||
|
||||
/// <summary>
|
||||
/// 异步操作的最小时间片段
|
||||
/// </summary>
|
||||
|
@ -136,6 +141,11 @@ namespace YooAsset
|
|||
_newList.Add(operation);
|
||||
operation.SetPackageName(packageName);
|
||||
operation.SetStart();
|
||||
|
||||
if (QuickStartMode)
|
||||
{
|
||||
operation.InternalOnUpdate();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -222,6 +222,15 @@ namespace YooAsset
|
|||
}
|
||||
OperationSystem.MaxTimeSlice = milliseconds;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 设置异步系统参数,快速启动模式的开关
|
||||
/// 注意:该模式默认开启
|
||||
/// </summary>
|
||||
public static void SetOperationSystemQuickStartMode(bool state)
|
||||
{
|
||||
OperationSystem.QuickStartMode = state;
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 调试信息
|
||||
|
|
Loading…
Reference in New Issue