Search Unity

Question Which files are okay to just copy paste from one project to another?

Discussion in 'Editor & General Support' started by codinginflow, Jul 18, 2021.

  1. codinginflow

    codinginflow

    Joined:
    May 6, 2021
    Posts:
    30
    I know that you should use the Asset Export option to move assets from one project to another, but is this really always necessary? Let's say a project contains a PNG image or a WAV audio clip. Does it really break anything if I open that asset folder in Windows Explorer and copy-paste the asset into a different project? After all, those are the same file types that I dragged into the first project anyway.
     
  2. Epsilon_Delta

    Epsilon_Delta

    Joined:
    Mar 14, 2018
    Posts:
    258
    You don't need to use Asset Export at all. You can move assets that do not have dependencies freely. When they have dependencies, just include them (and their .meta files!) or use the Asset Export. There is no magic behind it. All you need to understand are .meta files and GUIDs. If you want to preserve GUIDs (essential for dependencies) and import settings, just copy an asset also with its .meta file.
    A problem might occur, if you copy an asset and its .meta file to other version of UnityEditor. There might be some changes in serialization. They are almost always resolved automagically, just be aware of such thing.
     
  3. Kurt-Dekker

    Kurt-Dekker

    Joined:
    Mar 16, 2013
    Posts:
    38,745
  4. Epsilon_Delta

    Epsilon_Delta

    Joined:
    Mar 14, 2018
    Posts:
    258
    Kurt-Dekker likes this.
  5. codinginflow

    codinginflow

    Joined:
    May 6, 2021
    Posts:
    30
    Thank you guys for your answers!
    @Kurt-Dekker it seems that your article talks about code sharing, not assets, or am I mistaken?
     
  6. Kurt-Dekker

    Kurt-Dekker

    Joined:
    Mar 16, 2013
    Posts:
    38,745
    Same smell. It's all just data. One can't run without the other, so the sharing process is identical.

    The only possible consideration might be if the asset data is awkwardly large.