com.alicizax.unity.tuyoogam.../Runtime/FileSystem/Operation/FSLoadBundleFileOperation.cs

39 lines
964 B
C#
Raw Normal View History

2025-02-28 16:11:01 +08:00

2025-01-09 11:31:04 +08:00
namespace YooAsset
{
internal abstract class FSLoadBundleOperation : AsyncOperationBase
{
/// <summary>
/// 加载结果
/// </summary>
public BundleResult Result { protected set; get; }
/// <summary>
/// 下载进度
/// </summary>
public float DownloadProgress { protected set; get; } = 0;
/// <summary>
/// 下载大小
/// </summary>
public long DownloadedBytes { protected set; get; } = 0;
}
internal sealed class FSLoadBundleCompleteOperation : FSLoadBundleOperation
{
private readonly string _error;
internal FSLoadBundleCompleteOperation(string error)
{
_error = error;
}
2025-02-28 16:11:01 +08:00
internal override void InternalStart()
2025-01-09 11:31:04 +08:00
{
Status = EOperationStatus.Failed;
Error = _error;
}
2025-02-28 16:11:01 +08:00
internal override void InternalUpdate()
2025-01-09 11:31:04 +08:00
{
}
}
}