Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


GetDirtyCount

Returns an integer that indicates the number of times the specified object's serialized properties have changed.
Read time 1 minuteLast updated 10 days ago

Definition

  • Type: Method
  • Namespace: UnityEditor
  • Assembly: UnityEditor

GetDirtyCount(int)

Returns an integer that indicates the number of times the specified object's serialized properties have changed.
Warning
Deprecated. GetDirtyCount(int) is deprecated. Use GetDirtyCount(EntityId) instead.
public static int GetDirtyCount(int instanceID)

Parameters

instanceID

The object's instance ID.

Returns

Type

Description

int

Remarks

This count is incremented each time a call to EditorUtility.SetDirty changes the object's serializable properties, and is reset to zero when the object is saved.

GetDirtyCount(EntityId)

Returns an integer that indicates the number of times the specified object's serialized properties have changed.
public static int GetDirtyCount(EntityId entityId)

Parameters

entityId

Returns

Type

Description

int

Remarks

This count is incremented each time a call to EditorUtility.SetDirty changes the object's serializable properties, and is reset to zero when the object is saved.

GetDirtyCount(Object)

Returns an integer that indicates the number of times the specified object's serialized properties have changed.
public static int GetDirtyCount(Object target)

Parameters

target

The object.

Returns

Type

Description

int

Remarks

This count is incremented each time a call to EditorUtility.SetDirty changes the object's serializable properties, and is reset to zero when the object is saved.