refactor : 重构代码
This commit is contained in:
@@ -116,14 +116,14 @@ namespace YooAsset
|
||||
{
|
||||
_steps = ESteps.Done;
|
||||
Status = EOperationStatus.Failed;
|
||||
Error = $"Instantiate game object is null !";
|
||||
Error = $"Instantiate game object is null.";
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
_steps = ESteps.Done;
|
||||
Status = EOperationStatus.Failed;
|
||||
Error = $"Instantiate async results is null !";
|
||||
Error = $"Instantiate async results is null.";
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -84,7 +84,7 @@ namespace YooAsset
|
||||
if (_loadBundleOp == null)
|
||||
{
|
||||
// 统计计数增加
|
||||
_resManager.BundleLoadingCounter++;
|
||||
_resManager.IncrementBundleLoadingCounter();
|
||||
_loadBundleOp = LoadBundleInfo.CreateBundleLoader();
|
||||
_loadBundleOp.StartOperation();
|
||||
AddChildOperation(_loadBundleOp);
|
||||
@@ -105,7 +105,7 @@ namespace YooAsset
|
||||
{
|
||||
_steps = ESteps.Done;
|
||||
Status = EOperationStatus.Failed;
|
||||
Error = $"The bundle loader result is null ! {LoadBundleInfo.Bundle.BundleName}";
|
||||
Error = $"The bundle loader result is null. Bundle: {LoadBundleInfo.Bundle.BundleName}";
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -122,7 +122,7 @@ namespace YooAsset
|
||||
}
|
||||
|
||||
// 统计计数减少
|
||||
_resManager.BundleLoadingCounter--;
|
||||
_resManager.DecrementBundleLoadingCounter();
|
||||
}
|
||||
}
|
||||
internal override void InternalWaitForAsyncComplete()
|
||||
@@ -171,7 +171,7 @@ namespace YooAsset
|
||||
{
|
||||
_steps = ESteps.Done;
|
||||
Status = EOperationStatus.Failed;
|
||||
Error = "Bundle loader destroyed !";
|
||||
Error = "Bundle loader destroyed.";
|
||||
}
|
||||
}
|
||||
|
||||
@@ -268,7 +268,7 @@ namespace YooAsset
|
||||
{
|
||||
_steps = ESteps.Done;
|
||||
Status = EOperationStatus.Failed;
|
||||
Error = "Abort bundle loader !";
|
||||
Error = "Bundle loader aborted.";
|
||||
}
|
||||
|
||||
if (_steps == ESteps.LoadBundleFile)
|
||||
|
||||
@@ -73,7 +73,7 @@ namespace YooAsset
|
||||
{
|
||||
_steps = ESteps.Done;
|
||||
Status = EOperationStatus.Failed;
|
||||
Error = "Scene is invalid !";
|
||||
Error = "Scene is invalid.";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -81,7 +81,7 @@ namespace YooAsset
|
||||
{
|
||||
_steps = ESteps.Done;
|
||||
Status = EOperationStatus.Failed;
|
||||
Error = "Scene is not loaded !";
|
||||
Error = "Scene is not loaded.";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -97,7 +97,7 @@ namespace YooAsset
|
||||
{
|
||||
_steps = ESteps.Done;
|
||||
Status = EOperationStatus.Failed;
|
||||
Error = "Unload scene failed, see the console logs !";
|
||||
Error = "Unload scene failed, see the console logs.";
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user