예제 #1
0
    /// <summary>
    /// 获取SDK目录
    /// </summary>
    /// <returns></returns>

    /*private static string GetSDKDir()
     * {
     *  return EditorUtility.OpenFolderPanel("Please select the android sdk directory", SDK_PATH_DEFAULT, "");
     * }*/

    /// <summary>
    /// 更改标题画面
    /// </summary>
    /// <param name="titleName"></param>
    private static bool CopyLogo()
    {
        try
        {
            string src  = Application.dataPath + "/Projects/" + PlayerSettings.companyName + "/Logo";
            string desc = Application.dataPath + "/Logo";

            Debug.Log("copy file from:" + src + " to:" + desc);

            if (!Directory.Exists(src))
            {
                Debug.Log(src + " dir is not exists");
                return(true);
            }

            if (Directory.Exists(desc))
            {
                CFile.DeleteDirectory(desc);
            }

            CFile.CopyDirectory(src, desc);

            AssetDatabase.Refresh();
        }
        catch (Exception ex)
        {
            Debug.LogException(ex);
            return(false);
        }

        return(true);
    }