很多朋友都问小编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应用出现乱码的处理方法了,想必都了解了吧,更多相关内容请继续关注武林技术频道。
新闻热点
疑难解答