I am getting the index out of range exception. I debuged it and it is specifically at the part of "s[i].AddRange()" The "GetFiles()" method is just the "Directory.GetFiles()" but it can accept multiple file endings.
static List<List<string>> directories
{
get
{
Debug.Log(folders.Length);
List<List<string>> s = new List<List<string>>();
for (int i = 0; (i < folders.Length); i++)
{
s[i].AddRange(GetFiles(folders[i], "*.png,*.jpg,*.bmp,*.tif,*.tga,*.psd").ToList());
s[i].AddRange(GetFiles(folders[i], "*.prefab").ToList());
}
return s;
}
}
s[i]is the problem