Skip to main content

GetComponentIfEmptyAttribute

A class in Alta.Attributes, the global namespace.

Like GetComponentAttribute, but only fills the field when it is empty.

Constructors​

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

Methods​

MemberWhat it is
override bool HandleApply(Component component, FieldInfo field, GameObject prefab)Skips the field if it already has a value, else looks it up as the base does.