Using WWW to load all files in StreamingAssets directory

Is it possible to use WWW to load any and all files in a given directory within StreamingAssets, or do I have to know the explicit name of every file I’m looking to load?

For examaple, “StreamingAssets/” contains a list of .xml files of arbitrary file names “dataSet01.xml”, “saveFile-3.xml”, “character_data_set_17.xml”, so on, and I need to load them all at runtime.

This isn’t really a WWW question. There isn’t any way to download all files from a directory regardless of the technology. What you need is some way to get a directory listing.

Where is StreamingAssets located? Are you trying to load from the local disk or from a folder in a web directory? If from local disk, look for ways to get directory listings with C# (it’s not Unity-specific). If it’s remote, you have to make the directory accessible, and that has to be done in Apache or whatever you’re running (and it’s different for HTTP vs FTP).

Alternatively, you could create a file called ‘filelist.txt’, which lists all the files you need to load. Then, first download filelist.txt, parse it, then download one by one all the files.