ParagonNetworkBehaviourEditor

Custom Unity Editor that renders the Inspector for all ParagonNetworkBehaviour subclasses using Odin Inspector. Applies automatically to ParagonNetworkBehaviour and all derived types via [CustomEditor(typeof(ParagonNetworkBehaviour), true)].

Definition

Namespace: Paragon.Core.Network.Editor Assembly: Paragon.Editor.dll

[CustomEditor(typeof(ParagonNetworkBehaviour), true)]
public class ParagonNetworkBehaviourEditor : OdinEditor

Inheritance: OdinEditorParagonNetworkBehaviourEditor

Remarks

This editor replaces Unity's default NetworkBehaviour Inspector with Odin Inspector's property drawing system for all ParagonNetworkBehaviour subclasses. The true parameter in [CustomEditor] ensures it applies to all derived types automatically, so game-specific network behaviours get Odin support without requiring their own custom editors.

By inheriting from OdinEditor, the class gains:

  • Odin property trees — automatic serialization and rendering of Odin attributes ([ShowInInspector], [BoxGroup], [Button], etc.)

  • Custom drawers — Odin's attribute-based drawer system applies to all serialized fields

  • Validation — Odin's built-in validation displays warnings and errors in the Inspector

The class body is intentionally empty — all functionality is inherited from OdinEditor. The sole purpose is to register the [CustomEditor] attribute so Unity routes Inspector drawing through Odin for the correct base type.

circle-info

Without this editor, ParagonNetworkBehaviour subclasses would use Unity's default NetworkBehaviour Inspector, bypassing Odin attributes entirely. This class bridges that gap.

Quick Lookup

Goal
How

Enable Odin for a network behaviour

Inherit from ParagonNetworkBehaviour — this editor applies automatically

Override Inspector drawing

Subclass ParagonNetworkBehaviourEditor and override Odin's virtual methods

Use Odin attributes on network behaviours

Add [ShowInInspector], [BoxGroup], [Button], etc. to your ParagonNetworkBehaviour fields

Examples

Using Odin Attributes (Automatic Support)

See Also

Last updated