Purpose and nature of Nested Prefabs?

So as I understand it, I heard you like prefabs, so you nest your prefab in your prefab so you can prefab while you prefab…jokes aside, that is it right?

I understand them as something like class extends? A form of inheritance?

So it’s like having a child of a base class, which allows you to be more effective in your workflow by having changes duplicated in the nested one?

That sounds more like Prefab Variants…

In a Nested prefab, I can create a Prefab of some useful GameObject that I want to use in different places… So I might have a Health bar that sits atop the character’s heads… It also might be something I want to put overtop of a door that needs to be attacked to break through… who knows…

So I have my Character prefab in place, and all I have to do is drag the Health Bar refab onto the Character prefab tree in the scene heirarchy, and now the Health Bar is there…

So I’ve done this with say… three or four other prefabs, each one having this Health Bar…

And now I’ve decided “you know what, I don’t like that background on the health bar”… all I have to do is go into the HealthBar prefab and make the changes I want, and in all of those other places where I have the Health Bar as a nested prefab, the changes are applied automagically.

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.

Privacy & Terms