유니티 C#

유니티 텍스트파일 불러오기

죽은쥐 2017. 9. 13. 02:16

참고한 곳 : http://infodbbase.tistory.com/113



string path = Application.dataPath + @"\text.txt";

string textValue = System.IO.File.ReadAllLines(path);


if(textValue.Length > 0)

{

for(int i = 0; i < textValue.Length; i++)

{

Debug.Log(textValue[i]);

}

}


텍스트 파일을 한줄씩 읽어와서 디버그로그에 찍는코드