June 2017
Beginner to intermediate
336 pages
8h 44m
English
Add another method called DownloadAndProcessAssets() with following code block. It downloads the AssetBundle from the Blob URL and, once thee download is complete, we finally instantiate a new object with the downloaded asset.
public IEnumerator DownloadAndProcessAssets(WWW www, string assetName) { yield return www; bundle = www.assetBundle; if (www.error == null && bundle != null) { launchedObject = Instantiate((GameObject)bundle. LoadAsset(assetName)); launchedObject.transform.position = new Vector3(launchedObject.transform.position.x, this.gameObject.transform.position.y - .25f, this.gameObject.transform.position.z - 1.5f); } else { Debug.Log(www.error); } }
With this, if you ...
Read now
Unlock full access