Search Unity

[SOLVED] Replacing a Model

Discussion in 'General Graphics' started by Gunging, Oct 11, 2018.

  1. Gunging

    Gunging

    Joined:
    Sep 6, 2016
    Posts:
    139
    Hello, I have several 3D models, and they are assigned into many arrays in many different places of my game.

    I want to update the models, but I don't want to go and re-assign them again everywhere.

    Is there a way to replace the models?




    * If I import the new one into Unity, with the same name as the old one, it just adds a '1' at the end.

    upload_2018-10-11_14-24-4.png


    * If I import the new one into the Windows Explorer, with the same name as the old one, it is 'overwritten' but I still have to re-assign it everywhere.
     
  2. mbowen89

    mbowen89

    Joined:
    Jan 21, 2013
    Posts:
    639
    If you save over the previous file, it replaces it. Don't do an import, literally copy and paste and replace the mesh in the folder.
     
  3. McDev02

    McDev02

    Joined:
    Nov 22, 2010
    Posts:
    664
    Yes replace them in the folder, not inside Unity.
    This works perfectly fine if the new models do not differ much from the previous versions. For example names and numbers of meshes should be the same.

    If you dragged the models in your scenes and keept the reference then it will update fine.
    If the models are in prefabs and you make changes like adding new meshes or changing materials, then this will not be included in the prefab. Unless you are alreadyd using nested prefabs...
     
  4. Gunging

    Gunging

    Joined:
    Sep 6, 2016
    Posts:
    139
    Ah so it works only for scene objects.

    Unfortunately, an extremely large percent of my models are assigned to the player's script, and the player is a prefab.
     
  5. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Same thing, just replace the model. The prefab contains a reference to the model, it’s not the model itself.
     
  6. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    6,364
    replacing the file only works with the same extension