- Home /
"Unable to instantiate prefab. Prefab may be broken"
Hey there ! I just upgraded my project from 2017.3 to 2018.1 and now all of my scenes are broken (missing prefab for every object) and when I try to drag'n drop a prefab into the scene I get the following error :
"Unable to instantiate prefab. Prefab may be broken. UnityEditorInternal.InternalEditorUtility:HierarchyWindowDrag(HierarchyProperty, Boolean, HierarchyDropMode) UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)"
So my scenes are broken and I can't add any prefab ... Any idea ?
I just had the same problem actually, and I don't know what to do. Whenever I try to drag the prefab to the hierarchy on 2018.1 I get that message.
I am having the same issue... I upgraded to unity 2018 , as want to use unity inbuilt Text$$anonymous$$esh Pro. and updated all UI, however now my prefab is not working as it suppose to, having same error as mention. Prefeb is too complex as its a player and enemy with animation, AI and UI... will be pain to recreate same :( is ther any solution to fix it... please help...
Same page... Any thought? I've already tried to export from U2018 but no luck.
I know this is probably useless for most of the people but...since I still had installed Unity 2018 and a its version of the project, I opened it, broke all prefab's instances and saved. Then in Unity 2017 I opened that version and recreated all the prefabs (hopefully they were just a few and I had them all in my scenes). Still waiting for an answer though.
I get this problem often its so annoying. I downloaded an asset other day and tried it. Everything went fine and i didnt touch that asset folder in my project since then was working on something else. Then i come back couple days or week later and try to place a prefab on the scene bam broken. Nothing changed at all. Unity often randomly give bug like this using 2018.1.1f1. It happened with many other asset. When its not its a script in my scene that get unlinked for some reason. I think i lost a whole week since 2 month trying to figure out bugs that was related to broken prefabs or missing script that randomly appear. Is there a known unity version working at best? Im gonna give it a try.
Answer by qcbf1 · Oct 01, 2018 at 10:33 AM
open *.Prefab in Text Editor (need modify unity editor setting)
change text "m_SourcePrefab" to "m_ParentPrefab"
change text "m_IsPrefabAsset" to "m_IsPrefabParent"
it ok, try.
if your unity other version, can you create empty GameObject then compare difference.
Answer by ragnarokyt179 · Feb 14, 2019 at 02:36 PM
hey Guys! the solution for that is (Right click on the prefab and then hit Reimport)
Bro, you have no idea how many hours of work you just saved me. Thank you very very much, you're a hero!
I'm with ziadgapp! Thanks so much, this has really helped.
Answer by Fragmental · Aug 21, 2018 at 11:10 PM
So, 2018.2 made some changes to prefabs that break things when you try to downgrade. I've found two solutions, but I've only tried the first.
No matter what you do, make sure you've backed up your project first.
Solutions
Break the prefabs in the 2018.2+, in your scene. SAVE your scene. Then open that scene in the older Unity version (either by exporting and importing, or by copying your project or files). The prefabs that are in the scene, that you broke the connection should still work. You can break a prefab in the "GameObject" menu after selecting a prefab. There's some more info here https://answers.unity.com/questions/1502308/missing-prefabs-after-downgrading-from-unity-20182.html
You can try modifying the files themselves from the console as outline here https://www.reddit.com/r/Unity3D/comments/8gl8og/downgrading_from_unity_201820b2_to_unity_201810f2/
Be aware that other things may break also, when downgrading(which is my problem, right now).
Breaking the prefab worked!! THanks. This process is way better than replacing those words in the ".prefab" file unless you know the proper find and replace command.
Answer by Bunny83 · Aug 02, 2018 at 07:22 AM
This is most likely the same issue as in this question over here. The problem is that Unity seems to have changed it's prefab serialization format and didn't make it backward nor forward compatible. It's mainly a rename of some fields. If you use text serialization you could rename those fields yourself. However i strongly recommend you create a backup of your project.
Also if you can verify that this is the problem, please file a bug report with as many details possible. So create a new standalone project where you copy that offending prefab to and attach that project to the bugreport. The more people verifying the issue, the faster this may be fixed.
As a general advice: If you are in the middle of a production, do not upgrage Unity. Even Unity doesn't recommend it.
Answer by RadonRaph · Jun 03, 2018 at 03:11 PM
If you have make a backup you can download unity hub and run your project with Unity 2017.3.
I have no backup and I want to keep using Unity 2018.1.
When you upgraded the Unity editor it warned you that it is going to upgrade your project and asked you if you have created a backup. You clicked "yes". If you don't actually have a backup you are the only one to blame.
Your answer
Follow this Question
Related Questions
Prefab trows Error: 0 Answers
Change image visibility of newly instantiated prefab? 1 Answer
Dealing with many scripted objects 1 Answer
Prefab disables a script out of runtime. 0 Answers
Problem: Random Instantiating more than one prefab? 1 Answer