UnityEngine.WWW.Dispose C# (CSharp) Method

Dispose() public method

Disposes of an existing WWW object.

public Dispose ( ) : void
return void
        public void Dispose()
        {
            this.DestroyWWW(true);
        }

Usage Example

コード例 #1
0
 public IEnumerator LoadAssetBundle()
 {
     state = DownloadState.Init;
     downLoader = new WWW(path + fileName);
     state = DownloadState.Loading;
     yield return downLoader;
     if(downLoader.error!=null)
     {
         state = DownloadState.LoadFailed;
         downLoader.Dispose();
         yield break;
     }
     else
     {
         size = downLoader.bytesDownloaded;
         assetBundle = downLoader.assetBundle;
         if(assetBundle==null)
         {
             state = DownloadState.LoadFailed;
         }
         else
         {
             state = DownloadState.Loaded;
         }
         downLoader.Dispose();
     }
 }
All Usage Examples Of UnityEngine.WWW::Dispose