public unsafe T GetComponent <T>() { CastHelper <T> castHelper = new CastHelper <T>(); this.GetComponentFastPath(typeof(T), new IntPtr((void *)&castHelper.onePointerFurtherThanT)); return(castHelper.t); }
public unsafe T GetComponent <T>() { var h = new CastHelper <T>(); GetComponentFastPath(typeof(T), new System.IntPtr(&h.onePointerFurtherThanT)); return(h.t); }
public unsafe T GetComponent <T>() { CastHelper <T> castHelper = default(CastHelper <T>); GetComponentFastPath(typeof(T), new IntPtr(&castHelper.onePointerFurtherThanT)); return(castHelper.t); }
public unsafe bool TryGetComponent <T>(out T component) { var h = new CastHelper <T>(); TryGetComponentFastPath(typeof(T), new System.IntPtr(&h.onePointerFurtherThanT)); component = h.t; return(h.t != null); }
public unsafe bool TryGetComponent <T>(out T component) { CastHelper <T> castHelper = default(CastHelper <T>); this.TryGetComponentFastPath(typeof(T), new IntPtr((void *)(&castHelper.onePointerFurtherThanT))); component = castHelper.t; return(castHelper.t != null); }