LayerDropdown Attribute

Attribute to make a single selection dropdown of layers

Note

The LayerDropdown Attribute can only be attached to a string

Example:

using UnityEngine;
using EditorAttributes;

public class AttributesExample : MonoBehaviour
{
        [SerializeField, LayerDropdown] private string layer;
}
../../_images/LayerDropdown01.gif