Skip to main content

GetComponentInPrefabRootAttribute

A class in Root.Township, the global namespace.

Like GetComponentAttribute, but takes the component from the root NetworkPrefab object above the field's object.

Constructors​

MemberWhat it is
GetComponentInPrefabRootAttribute()Creates a GetComponentInPrefabRootAttribute with default values.

Methods​

MemberWhat it is
override Component GetComponent(Transform transform, Type type)Finds the nearest NetworkPrefab in the parents and gets the component from it, or null.