- Home /
How to make prefab reference in another prefab
I want to create a game GUI prefab to use it in another levels. Simultaneously, GUI prefab contains buttons, that are prefab instances too. When I save GUI prefab and then change button prefab, nothing happens. That's because GUI prefab can't store references of button brefab. How can I solve it?
Answer by FlaSh-G · Feb 03, 2018 at 05:39 PM
This is called "nested prefabs". It's a feature that hasn't been implemented for a long time, but has been hinted at for a 2018 release.
Answer by Tekksin · Jun 29, 2018 at 12:45 AM
I get around this by dragging the original prefab into the scene, adding the stuff I want to it, and then applying it....then deleting it from the scene. Nested prefabs would be cool, but not really essential. They might cause more complication than help.
*MAIN GROUP
- sub group(0)
- -sub sub group(0)
- - - sub sub sub group(0)
- - - sub sub sub group(1)
- sub group(1)
- sub group(2)
So for instance (no pun intended), if you wanna change a button that is labeled "sub sub sub group(1)", select that object and then in the inspector click "model: SELECT" where you tag stuff.
That will select the prefab.
Drag that prefab into your scene
make your changes.
select apply at the top right of the inspector
Some "prefabs" aren't prefabs and just references to files that are altered in their respective programs. Just because it's lit blue it doesn't make it a prefab, so keep that in mind when wondering "where the hell is my apply button???"
Your answer
Follow this Question
Related Questions
Pro, Free, SVN and Prefab Connection Problem 1 Answer
Suggestions for Prefabs which refer to other Prefabs 0 Answers
Force every prefab to be the same for every scene 1 Answer
How can you duplicate a prefab and sever all links to the original? 1 Answer
Unity: How can you make a prefab immutable for instance overrides 0 Answers