Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.

Feedback Serially <> SerializableType and SerializeReference Inspector

Discussion in 'Works In Progress - Archive' started by jasonboukheir, Jul 30, 2020.

  1. jasonboukheir

    jasonboukheir

    Joined:
    May 3, 2017
    Posts:
    77
    SerializableTypeDrawer.png ShowSerializeReferenceDrawer.png TypePickerWindow.png

    Check it out here: https://github.com/CareBoo/Serially

    Includes a much-needed inspector for
    SerializeReference
    fields, inspired by
    UnityEngine.Object
    inspector, and a
    SerializableType
    class that lets you serialize
    System.Type
    references. Nothing new here, there are already projects that do these things, I just wanted to add my own opinion to it.

    Cool features:
    • Add a
      ProvideSourceInfo
      attribute to your class to allow editor pinging when you click on the type in the inspector.
    • Add a
      Guid
      attribute to your class, and when you rename your class, your
      SerializableType
      fields won't lose their references.
    • Small runtime improvements: Attributes are editor-only, and get removed when making a build. The type guid reference is replaced with the type assembly name during a build.
    Upcoming features (Feedback?):
    • Split the two features into separate packages. What was I thinking?
    • Allow copying/pasting a
      SerializeReference
      field via right click.
    • Add a tab to the SerializeReference Picker Window
     

    Attached Files:

unityunity