Odin Inspector Version 1.0.2.1

Fixes

  • Formatter emitting now works when targeting the experimental .NET 4.6 platform in Unity 2017.1. This fixes the MethodAccessExceptions that people were getting when the build platform was Standalone or Android with the experimental .NET 4.6 runtime.
  • Fixed issue where object fields would not accept drag and dropping values. You can now drag values into non-Unity object fields - for example, you can now drag assets that implement a certain interface into a field of that interface type.
  • TypeExtensions.SetMemberValue now works on property infos. This was causing all prefab value modifications to properties to become lost or null.
  • Made editor recompilation more robust to type and file load exceptions during inspection of old assemblies with invalid assembly references - these exceptions will now result in an automatic recompile (if this is enabled) which should correct the given assembly references at once.
  • Fixed case where a UnityPropertyValueEntry failing to find its corresponding Unity property would cause a null reference exception to be thrown.
  • AssetsOnly attribute now also excludes scene objects in the object picker when the value is null.
  • ReferenceDrawer no longer forces GUI.enabled to be true.
  • ColorPallete and Enum changes now properly trigger ValidateInput.
  • Color32 now works when only backed by Odin serialization.
  • SirenixEditorFields.MinMaxSlider now respects EditorGUI.showMixedValue.
  • EditorGUI.showMixedValue is now handled per child property.
  • Fixed case where declaring dictionaries with unsupported key types would result in errors when updating a property tree.
  • The context menu item "Set to null" now correctly appears for properties of interface types.
  • Reference object picker is now shown for UnityObject values which are in properties with a base type which is an interface.
  • Fixed a potential bug where the LabelText could end up showing the wrong label.
  • Fixed a bug where multiselection could break the boolean drawer and end up changing the value if there was a value conflict.
  • Fixed cases where AnimationCurves and Gradients would cause errors in the inspector and fail to draw properly.
  • Fixed issue where BoxGroup.ShowLabel was not respected.
  • Fixed case during build-time deserialization of a prefab instance in a scene that is being loaded for being built, where Odin would fail to detect available prefab data due to prefab already having been serialized into build-time data formats. The prefab instance would attempt to deserialize from its own data instead, but that data would sometimes be corrupt, since this is build time and it's a prefab instance and prefab instances don't exist in builds.
  • SplitCamelCase no longer splits all caps.
  • InfoBoxAttribute now works properly with multiple info boxes.
  • Fixed a bug where the wrong label would sometimes be used in the [LabelText] attribute.
  • Using [ShowInInspector] on dictionaries that are on non-Odin-serialized types now works properly.

Changes

  • Most attribute which had some kind of string member reference now use StringMemberHelper instead. Original member references have been marked as obsolete.
  • Title attribute has been overhauled to look better, and now has options for subtitle and for a horizontal separator line.
  • UnitySerializationUtility now caches memory streams used, which should result in far less garbage allocated each time an object is serialized.
  • Changed deserialization behaviour in the editor to be able to handle data serialized in build mode. This is a possible fix for a case where Odin-serialized data would sometimes disappear randomly when building and/or exiting play mode.
  • Changed UnityObjectDrawer priority to (0, 0, 0.25) to prevent it from ever overriding a user's vanilla Unity PropertyDrawer by default.
  • Changed IPropertyValueEntry.ValueIsDictionary to ValueIsValidDictionary. Additionally, it is now only true if the Dictionary's key type is a valid key type in the inspector.
  • LabelText attribute is no longer applied to list elements.
  • Lots of changes to demo scenes.
  • AssetLists now only scans for objects within the path specified, if any. This will drastically reduce the time it takes to scan for all relevant assets in large projects.
  • Button and ButtonGroup now use mini button GUI style.
  • SirenixEditorGUI.InfoBox no longer gets a control ID.
  • EnumToggleButtons makes multiple rows of buttons when horizontal space is needed .
  • Polished the spacing between elements a bit more.
  • DetailedInfoBox now shows its foldout icon on the right side of the message box, instead of the bottom.

Added

  • When first learning to use the Odin Inspector, it is common for people to misunderstand the OdinSerialize attribute, and use it in places where it does not achive the deceired goal. We now show a warning message in the inspector if we detect any potential cases such as that. The warning message can be disabled in 'Window > Odin Inspector > Preferences > Serialization'.
  • Added OdinEditorWindow, which you can inherit from to easily create Odin-supported editor windows using the same attribute syntax that you use for components and scriptable objects.
  • The Title attribute has now gotten an optional horizontal line separator along with a subtitle. You can now also specify the alignment of the title.
  • Added StringMemberHelper class, which will find a string member field, property or method to get a string from if the given path starts with a $. Otherwise it'll use the given string.
  • Added IPropertyValueCollection.ForceMarkDirty.
  • Added new InlineButton attribute .
  • Added PropertyContextContainer.Get with an out parameter for the context, and a bool return value for initialization.
  • Added an overload to the FoldoutGroup where you can specify whether or not the foldout should start expanded or collapsed.