GatherModifiedFiles() private method

private GatherModifiedFiles ( ) : bool
return bool
Esempio n. 1
0
    public static bool AutoPopulate()
    {
        if (!File.Exists(AkUtilities.GetFullPath(Application.dataPath, WwiseSetupWizard.Settings.WwiseProjectPath)))
        {
            AkWwisePicker.WwiseProjectFound = false;
            return(false);
        }
        else
        {
            AkWwisePicker.WwiseProjectFound = true;
        }

        if (EditorApplication.isPlayingOrWillChangePlaymode || String.IsNullOrEmpty(s_wwiseProjectPath) || EditorApplication.isCompiling)
        {
            return(false);
        }

        AkWwiseWWUBuilder builder = new AkWwiseWWUBuilder();

        if (!builder.GatherModifiedFiles())
        {
            return(false);
        }

        builder.UpdateFiles();
        return(true);
    }
Esempio n. 2
0
    public static bool AutoPopulate()
    {
        if (!System.IO.File.Exists(AkUtilities.GetFullPath(UnityEngine.Application.dataPath,
                                                           WwiseSetupWizard.Settings.WwiseProjectPath)))
        {
            AkWwisePicker.WwiseProjectFound = false;
            return(false);
        }

        AkWwisePicker.WwiseProjectFound = true;

        if (UnityEditor.EditorApplication.isPlayingOrWillChangePlaymode || string.IsNullOrEmpty(s_wwiseProjectPath) ||
            UnityEditor.EditorApplication.isCompiling)
        {
            return(false);
        }

        AkPluginActivator.Update();

        var builder = new AkWwiseWWUBuilder();

        if (!builder.GatherModifiedFiles())
        {
            return(false);
        }

        builder.UpdateFiles();
        return(true);
    }
Esempio n. 3
0
    public static void InitializeWwiseProjectData()
    {
        try
        {
            if (string.IsNullOrEmpty(AkWwiseEditorSettings.Instance.WwiseProjectPath))
            {
                UnityEngine.Debug.LogError("WwiseUnity: Wwise project needed to populate from Work Units. Aborting.");
                return;
            }

            var fullWwiseProjectPath = AkWwiseEditorSettings.WwiseProjectAbsolutePath;
            s_wwiseProjectPath = System.IO.Path.GetDirectoryName(fullWwiseProjectPath);

            AkUtilities.IsWwiseProjectAvailable = System.IO.File.Exists(fullWwiseProjectPath);
            if (!AkUtilities.IsWwiseProjectAvailable || UnityEditor.EditorApplication.isPlayingOrWillChangePlaymode || string.IsNullOrEmpty(s_wwiseProjectPath) ||
                UnityEditor.EditorApplication.isCompiling)
            {
                return;
            }

            var builder = new AkWwiseWWUBuilder();
            builder.GatherModifiedFiles();
            builder.UpdateFiles();
        }
        catch
        {
        }
    }
    public static void InitializeWwiseProjectData()
    {
        try
        {
            if (WwiseSetupWizard.Settings.WwiseProjectPath == null)
            {
                WwiseSettings.LoadSettings();
            }

            if (string.IsNullOrEmpty(WwiseSetupWizard.Settings.WwiseProjectPath))
            {
                UnityEngine.Debug.LogWarning("WwiseUnity: Set a path project (for sound team)");
                return;
            }

            var fullWwiseProjectPath = AkUtilities.GetFullPath(UnityEngine.Application.dataPath, WwiseSetupWizard.Settings.WwiseProjectPath);
            s_wwiseProjectPath = System.IO.Path.GetDirectoryName(fullWwiseProjectPath);

            AkUtilities.IsWwiseProjectAvailable = System.IO.File.Exists(fullWwiseProjectPath);
            if (!AkUtilities.IsWwiseProjectAvailable || UnityEditor.EditorApplication.isPlayingOrWillChangePlaymode || string.IsNullOrEmpty(s_wwiseProjectPath) ||
                UnityEditor.EditorApplication.isCompiling)
            {
                return;
            }

            var builder = new AkWwiseWWUBuilder();
            builder.GatherModifiedFiles();
            builder.UpdateFiles();
        }
        catch
        {
        }
    }
Esempio n. 5
0
    public static bool AutoPopulate()
    {
        if (!System.IO.File.Exists(AudioPluginSettingAgent.DeveloperWwiseProjectPath))
        {
            AkWwisePicker.WwiseProjectFound = false;
            return(false);
        }

        AkWwisePicker.WwiseProjectFound = true;

        if (UnityEditor.EditorApplication.isPlayingOrWillChangePlaymode || string.IsNullOrEmpty(s_wwiseProjectPath) ||
            UnityEditor.EditorApplication.isCompiling)
        {
            return(false);
        }

        AkPluginActivator.Update();

        var builder = new AkWwiseWWUBuilder();

        if (!builder.GatherModifiedFiles())
        {
            return(false);
        }

        builder.UpdateFiles();
        return(true);
    }
    public static bool Populate()
    {
        try
        {
            if (WwiseSetupWizard.Settings.WwiseProjectPath == null)
            {
                WwiseSettings.LoadSettings();
            }

            if (string.IsNullOrEmpty(WwiseSetupWizard.Settings.WwiseProjectPath))
            {
                UnityEngine.Debug.LogError("WwiseUnity: Wwise project needed to populate from Work Units. Aborting.");
                return(false);
            }

            var fullWwiseProjectPath = AkUtilities.GetFullPath(UnityEngine.Application.dataPath, WwiseSetupWizard.Settings.WwiseProjectPath);
            s_wwiseProjectPath = System.IO.Path.GetDirectoryName(fullWwiseProjectPath);

            AkUtilities.IsWwiseProjectAvailable = System.IO.File.Exists(fullWwiseProjectPath);
            if (!AkUtilities.IsWwiseProjectAvailable || UnityEditor.EditorApplication.isPlayingOrWillChangePlaymode || string.IsNullOrEmpty(s_wwiseProjectPath) ||
                UnityEditor.EditorApplication.isCompiling)
            {
                return(false);
            }

            AkPluginActivator.Update();

            var builder = new AkWwiseWWUBuilder();
            if (WwiseObjectReference.migrate == null && !builder.GatherModifiedFiles())
            {
                return(false);
            }

            builder.UpdateFiles();

            if (WwiseObjectReference.migrate != null)
            {
                UpdateWwiseObjectReferenceData();
                PopulateWwiseObjectReferences();

                UnityEditor.AssetDatabase.SaveAssets();

                var currentScene = UnityEngine.SceneManagement.SceneManager.GetActiveScene();
                UnityEditor.SceneManagement.EditorSceneManager.MarkSceneDirty(currentScene);
            }

            return(true);
        }
        catch (System.Exception e)
        {
            UnityEngine.Debug.LogError(e.ToString());
            UnityEditor.EditorUtility.ClearProgressBar();
            return(true);
        }
    }
Esempio n. 7
0
    public static bool Populate()
    {
        try
        {
            if (WwiseSetupWizard.Settings.WwiseProjectPath == null)
            {
                WwiseSettings.LoadSettings();
            }

            if (string.IsNullOrEmpty(WwiseSetupWizard.Settings.WwiseProjectPath))
            {
                UnityEngine.Debug.LogError("WwiseUnity: Wwise project needed to populate from Work Units. Aborting.");
                return(false);
            }

            s_wwiseProjectPath = System.IO.Path.GetDirectoryName(AkUtilities.GetFullPath(UnityEngine.Application.dataPath,
                                                                                         WwiseSetupWizard.Settings.WwiseProjectPath));

            if (!System.IO.File.Exists(AkUtilities.GetFullPath(UnityEngine.Application.dataPath,
                                                               WwiseSetupWizard.Settings.WwiseProjectPath)))
            {
                AkWwisePicker.WwiseProjectFound = false;
                return(false);
            }

            AkWwisePicker.WwiseProjectFound = true;

            if (UnityEditor.EditorApplication.isPlayingOrWillChangePlaymode || string.IsNullOrEmpty(s_wwiseProjectPath) ||
                UnityEditor.EditorApplication.isCompiling)
            {
                return(false);
            }

            AkPluginActivator.Update();

            var builder = new AkWwiseWWUBuilder();
            if (!builder.GatherModifiedFiles())
            {
                return(false);
            }

            builder.UpdateFiles();
            return(true);
        }
        catch (System.Exception e)
        {
            UnityEngine.Debug.LogError(e.ToString());
            UnityEditor.EditorUtility.ClearProgressBar();
        }

        return(true);        //There was an error, assume that we need to refresh.
    }
Esempio n. 8
0
    public static bool AutoPopulate()
    {
        if (EditorApplication.isPlayingOrWillChangePlaymode || String.IsNullOrEmpty(s_wwiseProjectPath) || EditorApplication.isCompiling )
        {
            return false;
        }

        AkWwiseWWUBuilder builder = new AkWwiseWWUBuilder();
        if(!builder.GatherModifiedFiles())
            return false;

        builder.UpdateFiles();
        return true;
    }
Esempio n. 9
0
    public static bool Populate()
    {
        try
        {
            if (string.IsNullOrEmpty(AkWwiseEditorSettings.Instance.WwiseProjectPath))
            {
                UnityEngine.Debug.LogError("WwiseUnity: Wwise project needed to populate from Work Units. Aborting.");
                return(false);
            }

            var fullWwiseProjectPath = AkWwiseEditorSettings.WwiseProjectAbsolutePath;
            s_wwiseProjectPath = System.IO.Path.GetDirectoryName(fullWwiseProjectPath);

            AkUtilities.IsWwiseProjectAvailable = System.IO.File.Exists(fullWwiseProjectPath);
            if (!AkUtilities.IsWwiseProjectAvailable || UnityEditor.EditorApplication.isPlayingOrWillChangePlaymode || string.IsNullOrEmpty(s_wwiseProjectPath) ||
                (UnityEditor.EditorApplication.isCompiling && !AkUtilities.IsMigrating))
            {
                return(false);
            }

            AkPluginActivator.Update();

            var builder = new AkWwiseWWUBuilder();
            if (!builder.GatherModifiedFiles())
            {
                return(false);
            }

            builder.UpdateFiles();
            return(true);
        }
        catch (System.Exception e)
        {
            UnityEngine.Debug.LogError(e.ToString());
            UnityEditor.EditorUtility.ClearProgressBar();
            return(true);
        }
    }
    public static bool AutoPopulate()
    {
        if (!File.Exists(AkUtilities.GetFullPath(Application.dataPath, WwiseSetupWizard.Settings.WwiseProjectPath)))
        {
            AkWwisePicker.WwiseProjectFound = false;
            return false;
        }
		else
		{
			AkWwisePicker.WwiseProjectFound = true;
		}

        if (EditorApplication.isPlayingOrWillChangePlaymode || String.IsNullOrEmpty(s_wwiseProjectPath) || EditorApplication.isCompiling )
        {
            return false;
        }

        AkWwiseWWUBuilder builder = new AkWwiseWWUBuilder();
        if(!builder.GatherModifiedFiles())
            return false;

        builder.UpdateFiles();
        return true;
    }