Version 3.3.0.1

Odin has a dedicated attribute overview with examples

TypeInfoBoxAttribute class

Namespace: Sirenix.OdinInspector
Assembly: Sirenix.OdinInspector.Attributes
[AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Interface, AllowMultiple = true, Inherited = true)]
[Conditional("UNITY_EDITOR")]
public class TypeInfoBoxAttribute : Attribute, _Attribute

The TypeInfoBox attribute adds an info box to the very top of a type in the inspector.

Use this to add an info box to the top of a class in the inspector, without having to use neither the PropertyOrder nor the OnInspectorGUI attribute.

Inheritance
  • System.Object
  • System.Attribute
  • TypeInfoBoxAttribute
Example

The following example demonstrates the use of the TypeInfoBox attribute.

[TypeInfoBox("This is my component and it is mine.")]
public class MyComponent : MonoBehaviour
{
    // Class implementation.
}

Constructors

TypeInfoBoxAttribute(String)
Draws an info box at the top of a type in the inspector.
public TypeInfoBoxAttribute(string message)
Parameters
System.String message

The message to display in the info box.

Fields

Message
The message to display in the info box.
public string Message