PropertyAccessor.

ResetValue(SerializedProperty, string) Method

Summary

Resets the value of the SerializedProperty to the default value of its type by executing its constructor and field initializers.
Assembly
UltEvents.dll
Namespace
UltEvents.Editor
Containing Type
PropertyAccessor

Syntax

public void ResetValue(SerializedProperty property, string undoName = "Inspector")

Examples

SerializedProperty property;
property.GetAccessor().ResetValue(property);

Remarks

If you don't want to run constructors and field initializers, you can call Serialization.ResetValue instead.

Parameters

Name Type Description
property SerializedProperty
undoName string

Return Value

Type Description
void