Commit ff10f957 authored by Unicorn369's avatar Unicorn369

Update

parent 458e7cba
......@@ -17,35 +17,8 @@ public class AppLanguage
public static string ES = "/es-ES"; //西班牙语(西班牙) Spanish
public static string Null = ""; //Unknown
//public static string Null = "en-WW"; //English
/*public static string LanguageDir()
{
if (Application.systemLanguage == SystemLanguage.ChineseSimplified) { //可能无法识别
return CN; //中文简体
} else if (Application.systemLanguage == SystemLanguage.ChineseTraditional) {//可能无法识别
return TW; //中文繁體
} else if (Application.systemLanguage == SystemLanguage.Chinese) {
return CN; //中文
} else if (Application.systemLanguage == SystemLanguage.English) {
return US; //English
} else if (Application.systemLanguage == SystemLanguage.French) {
return FR; //Français
} else if (Application.systemLanguage == SystemLanguage.German) {
return DE; //Deutsch
} else if (Application.systemLanguage == SystemLanguage.Italian) {
return IT; //Italiano
} else if (Application.systemLanguage == SystemLanguage.Japanese) {
return JP; //日本語
} else if (Application.systemLanguage == SystemLanguage.Korean) {
return KR; //한국어
} else if (Application.systemLanguage == SystemLanguage.Spanish) {
return ES; //Español
} else {
return Null;
}
}*/
//public static string Null = ""; //Unknown
public static string Null = "/en-US"; //English
public static string LanguageDir()
{
......
......@@ -348,22 +348,21 @@ public class Program : MonoBehaviour
}
}
if (Directory.Exists("expansions" + AppLanguage.LanguageDir()))//System Language
if (Directory.Exists("expansions"))
{
fileInfos = (new DirectoryInfo("expansions" + AppLanguage.LanguageDir())).GetFiles().OrderByDescending(x => x.Name).ToArray();//System Language
fileInfos = (new DirectoryInfo("expansions")).GetFiles().OrderByDescending(x => x.Name).ToArray();
for (int i = 0; i < fileInfos.Length; i++)
{
if (fileInfos[i].Name.Length > 4)
{
if (fileInfos[i].Name.Substring(fileInfos[i].Name.Length - 4, 4) == ".cdb")
{
YGOSharp.CardsManager.initialize("expansions" + AppLanguage.LanguageDir() + "/" + fileInfos[i].Name);
YGOSharp.CardsManager.initialize("expansions/" + fileInfos[i].Name);
}
}
}
}
fileInfos = (new DirectoryInfo("pack")).GetFiles();
//fileInfos = (new DirectoryInfo("pack" + AppLanguage.LanguageDir())).GetFiles();
for (int i = 0; i < fileInfos.Length; i++)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment