public void Unwrap() { if (Instance != null) //maybe the item isn't tied to a gameobject? { Instance.Destroy(); _instance = null; } }
public static W GetWorldObject <W>(this GameObject gObj) where W : WorldObject { WOWrapper instance = gObj.GetComponent <WOWrapper>(); return((W)instance.WO); }