update download system
remove timeout
This commit is contained in:
+1
-1
@@ -48,7 +48,7 @@ namespace YooAsset
|
||||
*/
|
||||
#endif
|
||||
|
||||
_loadCatalogFileOp = new LoadWebServerCatalogFileOperation(_fileSystem);
|
||||
_loadCatalogFileOp = new LoadWebServerCatalogFileOperation(_fileSystem, 60);
|
||||
_loadCatalogFileOp.StartOperation();
|
||||
AddChildOperation(_loadCatalogFileOp);
|
||||
}
|
||||
|
||||
+1
-1
@@ -64,7 +64,7 @@ namespace YooAsset
|
||||
if (_loadWebPackageManifestOp == null)
|
||||
{
|
||||
string packageHash = _requestWebPackageHashOp.PackageHash;
|
||||
_loadWebPackageManifestOp = new LoadWebServerPackageManifestOperation(_fileSystem, _packageVersion, packageHash);
|
||||
_loadWebPackageManifestOp = new LoadWebServerPackageManifestOperation(_fileSystem, _packageVersion, packageHash, _timeout);
|
||||
_loadWebPackageManifestOp.StartOperation();
|
||||
AddChildOperation(_loadWebPackageManifestOp);
|
||||
}
|
||||
|
||||
+4
-2
@@ -16,12 +16,14 @@ namespace YooAsset
|
||||
}
|
||||
|
||||
private readonly DefaultWebServerFileSystem _fileSystem;
|
||||
private readonly int _timeout;
|
||||
private UnityWebDataRequestOperation _webDataRequestOp;
|
||||
private ESteps _steps = ESteps.None;
|
||||
|
||||
internal LoadWebServerCatalogFileOperation(DefaultWebServerFileSystem fileSystem)
|
||||
internal LoadWebServerCatalogFileOperation(DefaultWebServerFileSystem fileSystem, int timeout)
|
||||
{
|
||||
_fileSystem = fileSystem;
|
||||
_timeout = timeout;
|
||||
}
|
||||
internal override void InternalStart()
|
||||
{
|
||||
@@ -38,7 +40,7 @@ namespace YooAsset
|
||||
{
|
||||
string filePath = _fileSystem.GetCatalogBinaryFileLoadPath();
|
||||
string url = DownloadSystemHelper.ConvertToWWWPath(filePath);
|
||||
_webDataRequestOp = new UnityWebDataRequestOperation(url);
|
||||
_webDataRequestOp = new UnityWebDataRequestOperation(url, _timeout);
|
||||
_webDataRequestOp.StartOperation();
|
||||
AddChildOperation(_webDataRequestOp);
|
||||
}
|
||||
|
||||
+4
-2
@@ -15,6 +15,7 @@ namespace YooAsset
|
||||
private readonly DefaultWebServerFileSystem _fileSystem;
|
||||
private readonly string _packageVersion;
|
||||
private readonly string _packageHash;
|
||||
private readonly int _timeout;
|
||||
private UnityWebDataRequestOperation _webDataRequestOp;
|
||||
private DeserializeManifestOperation _deserializer;
|
||||
private ESteps _steps = ESteps.None;
|
||||
@@ -25,11 +26,12 @@ namespace YooAsset
|
||||
public PackageManifest Manifest { private set; get; }
|
||||
|
||||
|
||||
internal LoadWebServerPackageManifestOperation(DefaultWebServerFileSystem fileSystem, string packageVersion, string packageHash)
|
||||
internal LoadWebServerPackageManifestOperation(DefaultWebServerFileSystem fileSystem, string packageVersion, string packageHash, int timeout)
|
||||
{
|
||||
_fileSystem = fileSystem;
|
||||
_packageVersion = packageVersion;
|
||||
_packageHash = packageHash;
|
||||
_timeout = timeout;
|
||||
}
|
||||
internal override void InternalStart()
|
||||
{
|
||||
@@ -46,7 +48,7 @@ namespace YooAsset
|
||||
{
|
||||
string filePath = _fileSystem.GetWebPackageManifestFilePath(_packageVersion);
|
||||
string url = DownloadSystemHelper.ConvertToWWWPath(filePath);
|
||||
_webDataRequestOp = new UnityWebDataRequestOperation(url);
|
||||
_webDataRequestOp = new UnityWebDataRequestOperation(url, _timeout);
|
||||
_webDataRequestOp.StartOperation();
|
||||
AddChildOperation(_webDataRequestOp);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user