Search Unity

Question Progressbars unintended behaviour

Discussion in 'Editor & General Support' started by MGhasemi, Apr 17, 2023.

  1. MGhasemi

    MGhasemi

    Joined:
    Jan 26, 2019
    Posts:
    8
    Hello there.
    I'm trying to show my generating terrain progress with a cancelable progress bar using
    Code (CSharp):
    1. EditorUtility.DisplayCancelableProgressBar
    so I expected something like:
    expected.png

    but Unity's importing assets progress bar overrides my cancelable progress bar and I can't see my progress and cancel it:
    result.png

    Is there a way to hide "importing assets" progress bar or another way around to see my progress bar?
     
  2. MGhasemi

    MGhasemi

    Joined:
    Jan 26, 2019
    Posts:
    8
    For anybody who have this problem I found the answer, Put:

    AssetDatabase.StartAssetEditing();
    before creating assets and call:

    AssetDatabase.StopAssetEditing();
    after finishing your work, for more information check this vidoe (from 29:00):