Version 2.1.0.0

UnityExtensions class

Namespace: Sirenix.Utilities
Assembly: Sirenix.Utilities
public static class UnityExtensions
Extends various Unity classes.
Inheritance
  • System.Object
  • UnityExtensions

Methods

SafeIsUnityNull(Object)
Determines whether a Unity object is null or "fake null", without ever calling Unity's own equality operators. This method is useful for checking if a Unity object is null, destroyed or missing at times when it is not allowed to call Unity's own equality operators, for example when not running on the main thread.
public static bool SafeIsUnityNull(this Object obj)
Parameters
UnityEngine.Object obj

The Unity object to check.

Returns
System.Boolean

True if the object is null, missing or destroyed; otherwise false.

This website is brand new and built with the Odin 2.1 beta in mind. This means you might discover some features such as attribute expressions that are only available in the beta.

You can download the 2.1 beta from here and read the patch-notes here.