refactor : 重构代码

This commit is contained in:
何冠峰
2026-01-16 14:37:04 +08:00
parent 611ac886b3
commit 3e3661ad95
18 changed files with 258 additions and 309 deletions
@@ -6,22 +6,22 @@ namespace YooAsset
/// <summary>
/// 下载是否已经完成
/// </summary>
public bool IsDone;
public bool IsDone { get; set; }
/// <summary>
/// 下载进度(0-1f)
/// </summary>
public float Progress;
public float Progress { get; set; }
/// <summary>
/// 下载文件的总大小
/// </summary>
public long TotalBytes;
public long TotalBytes { get; set; }
/// <summary>
/// 已经下载的文件大小
/// </summary>
public long DownloadedBytes;
public long DownloadedBytes { get; set; }
public static DownloadStatus CreateDefaultStatus()
{
@@ -6,12 +6,12 @@ namespace YooAsset
/// <summary>
/// 释放所有资源句柄,防止卸载过程中触发完成回调!
/// </summary>
public bool ReleaseAllHandles { private set; get; }
public bool ReleaseAllHandles { set; get; }
/// <summary>
/// 卸载过程中锁定加载操作,防止新的任务请求!
/// </summary>
public bool LockLoadOperation { private set; get; }
public bool LockLoadOperation { set; get; }
public UnloadAllAssetsOptions(bool releaseAllHandles, bool lockLoadOperation)
{
@@ -6,7 +6,7 @@ namespace YooAsset
/// <summary>
/// 循环迭代次数
/// </summary>
public int LoopCount { private set; get; }
public int LoopCount { set; get; }
public UnloadUnusedAssetsOptions(int loopCount)
{