Object Reference Fields

This feature is only available in Inspector Gadgets Pro.

Inspector Gadgets applies the following improvements to any field that inherits from UnityEngine.Object (such as any reference to a GameObject, Component, or any asset).

While the field has no reference it will be shown with several buttons to find one:

  • [H] - Find in Hierarchy (Component references only) - Searches all child and parent objects.
  • [S] - Find in Scene - Searches all objects in the scene.
  • [A] - Find in Assets - Searches all assets in the project.
  • These buttons search all potential candidates to find the one with a name closest to that of the field in question.
  • The context menus for these fields as well as for all components also contain similar functions.

While a reference is assigned, it will be shown with a foldout arrow to show the referenced object's editor nested below the field.

  • Unfortunately, due to the way the nested editor is drawn, arrays and lists of references will draw their editors beneath the list rather than beneath each individual field.
  • If you make a custom class, you can add a private const bool NestedObjectDrawers = false; field to is to disable nested object drawers for it in case they don't fit within the layout of your custom editor.