public static string TextFromResourceFile(string filePath) { TextAsset textAsset = Resources.Load("Text/" + filePath) as TextAsset; if (textAsset == null) { Log.Message("Found no text asset in resources at " + filePath); return(null); } return(GenFile.GetTextWithoutBOM(textAsset)); }
public static string TextFromResourceFile(string filePath) { TextAsset textAsset = Resources.Load("Text/" + filePath) as TextAsset; string result; if (textAsset == null) { Log.Message("Found no text asset in resources at " + filePath, false); result = null; } else { result = GenFile.GetTextWithoutBOM(textAsset); } return(result); }