I am creating a 2D equivalent of Gradient and a custom PropertyDrawer for it, and I have been unable to reliably get the actual instance to call the Evaluate function.
serializedProperty.objectReferenceValue is null, and the propertyType is Generic, so I cant get the object there.
Reflection on the targetObject works in some cases, but gives a NullReferenceException in others (I think when the 2D gradient is 2 or more levels deep).
Is there any way I can get a reference to a class that derives from System.Object, or call a function in a SerializedProperty that refers to that type?