Hi, I'd like to know what's the right workflow and how to use Prefabs for writing Unity games where its used meshes get updated by modelers (using Maya) while the game is developed in Unity.
I've got the following problem:
Now in the Project pane are two models: the one I originally imported and the prefab. After updating the model in Maya, the original model in the project pane changes (I can see the changes made to the model in the small preview window), but the prefab doesn't get updated, nor does the object in the Scene View (in the Hierarchy pane respectively).
How can we change geometries already in use by the Unity project afterwards?
I have come up against this problem, and I currently work around it (to a certain degree) this way, by adding an extra step:
Now, I find this method works for mesh changes to the existing objects, but it still doesn't pick up any changes in transforms to the existing objects, or any additional new objects added to the original file.
I know this doesn't seem like much of an improvement; it still requires a manual update if any models were moved or any new models were added. However, because your model is now a child within the prefab, it becomes a lot simpler to delete & re-add your model to the prefab.
Before, if you had made a prefab with your model as the root object (as opposed to an empty GO), you would probably have added components, scripts and adjusted settings, and from that position, it seems that there is no way to update the model without losing all these components and their settings. You simply have to delete and re-make the prefab.
Wheras now, because your model is a child within the prefab, you would add your components and scripts to the empty base GO, and this means you can preserve that whole part of the prefab while just deleting & re-adding the visible model part (you'd do this to an instance in the hierarchy, then choose "apply" to apply your changes to the prefab).
Hope this helps!
answered Apr 16 '10 at 04:49 PM
Here is what we are doing that seems to be working well and allows the 3d model to be updated and have prefabs that use it update as welll.
Import the model make an empty game object, call it "Global" and throw a script called "Global" on it that has something like
Then click on Global in the heirarchy and drag the 3d object in the project panel into the myModel var in the inspector.
Then in any script on any prefab you can instantiate the 3d object in the start function
Hope that helps
answered Oct 08 '10 at 11:01 AM
Dear lord, this workflow is abhorrent.
answered Sep 27 '10 at 07:28 AM
man do i really have to spend 3 hours doing this everytime my partner gives me an updated model? it takes over 3 hours for me to update the model if he adds for example gloves...
answered Jun 30 '12 at 05:26 PM