很多朋友都問小編Unity3d中IOS9應用出現亂碼怎么辦?下面是小編給大家分享的一篇Unity3d中IOS9應用出現亂碼的處理方法,感興趣的朋友跟小編一起來了解一下吧!
我們來看具體如何操作
static public void yaheifont()
{
uf = AssetDatabase.LoadAssetAtPath("Assets/yahei.prefab",typeof( UIFont)) as UIFont;
UnityEngine.Object[] objs = Selection.GetFiltered (typeof(UnityEngine.Object), SelectionMode.DeepAssets);
foreach (UnityEngine.Object _obj in objs)
{
string path = AssetDatabase.GetAssetPath(_obj);
Debug.Log("objname:"+_obj.name);
UnityEngine.Object[] arr = AssetDatabase.LoadAllAssetsAtPath(path);
Debug.Log("PATH:"+path);
foreach (Object j in arr)
{
if(j.GetType()==typeof(UILabel))
{
(j as UILabel).bitmapFont = uf;
Debug.Log("dfdfd:" + j.name + ",tyep:" + j.GetType());
}
}
EditorUtility.SetDirty(_obj);
}
AssetDatabase.SaveAssets();
}
以上就是關于Unity3d中IOS9應用出現亂碼的處理方法了,想必都了解了吧,更多相關內容請繼續關注武林技術頻道。
新聞熱點
疑難解答