Search Unity

  1. We are migrating the Unity Forums to Unity Discussions. On July 12, the Unity Forums will become read-only.

    Please, do not make any changes to your username or email addresses at id.unity.com during this transition time.

    It's still possible to reply to existing private message conversations during the migration, but any new replies you post will be missing after the main migration is complete. We'll do our best to migrate these messages in a follow-up step.

    On July 15, Unity Discussions will become read-only until July 18, when the new design and the migrated forum contents will go live.


    Read our full announcement for more information and let us know if you have any questions.

Question wanna fix freezing when instantiating

Discussion in 'Getting Started' started by Bonnate, Nov 24, 2022.

  1. Bonnate

    Bonnate

    Joined:
    May 30, 2021
    Posts:
    5
    A problem occurred while creating a non-game program in Unity.
    When certain conditions occur, we need to instantiate a prefab like the image below during runtime.
    However, this prefab is quite heavy and the game freezes for a while until it finishes loading.

    Is there any way to instantiate a heavy prefab in Unity without stopping for a while?

    Object pooling techniques are not suitable. For memory management, only one prefab like the one below should appear.