使用“统一”中的“资源”文件夹
string basePath = Application.dataPath;string metadataPath = String.Format(@"\Resources\...\metadata.txt", list);
// If metadata exists, set title and introduction strings.if (File.Exists(basePath + metadataPath)){
using (StreamReader sr = new StreamReader(new FileStream(basePath + metadataPath, FileMode.Open)))
{
...
}}foreach (string str in im){
spriteList.Add(Resources.Load<Sprite>(str));}相关分类