How to load json remote file content into unity 5?

2

I have 60 urls, but www.text only returns me 45. I have no errors.

Below is my code.

public class LoadPhoto : MonoBehaviour {

     private string LinkJsonFile = "http://www.bollyshake.com/api/1/video/trending?page=2&per_page=60";
     void Start () {
         position = 0;
         StartCoroutine(UploadImages(LinkJsonFile));
     }

     IEnumerator UploadImages (string LinkJsonFile)
    {
        string aux = "";
        WWW www = new WWW (LinkJsonFile);
        yield return new WaitForSeconds(5);
        if (www.isDone) {
            aux = www.text;
            print (aux);
            if (www.text == null) {
                Debug.Log ("Url de images são nulas");
            }
        }

    }

}

Is there another way to do this?

Thanks for the help.

    
asked by anonymous 19.02.2016 / 17:04

0 answers