I'm noticing a similarity

With my basic understanding of this concept, I’m noticing many similarities between virtual methods and prefabs with prefab variants and how they operate. Would this be a good comparison to help with comprehension of this whole thing better?

There is a similarity, that is somewhat intentional, as Unity followed an inheritance sort of design with their Prefab variant structure…
A Prefab variant starts with simply a reference to it’s parent. As things change within the prefab variant, all that is needed in many cases is to store the changed items… so a Fighter component might have Unarmored as the default weapon in all of the virtual characters, so no new data needs to be stored in the variant (unless, of course, you changed that default weapon), but the right and left hand transforms changes would be stored if you were using a different character.

Privacy & Terms