Ejemplo n.º 1
0
        ////////////////////////////////////////////////////////////////////////////////////////////////
        /*--------------------------------------------------------------------------------------------*/
        public static bool UpdateValueWithTreeMessage <TB, TV>(this TB pSource, ref TV pOld, TV pNew,
                                                               string pNote) where TB : MonoBehaviour
        {
            if (pNew == null && pOld == null)
            {
                return(false);
            }

            if (EqualityComparer <TV> .Default.Equals(pNew, pOld))
            {
                return(false);
            }

            pOld = pNew;
            TreeUpdater.SendTreeUpdatableChanged(pSource, pNote);
            return(true);
        }
 /*--------------------------------------------------------------------------------------------*/
 public virtual void OnValidate()           //editor only
 {
     TreeUpdater.SendTreeUpdatableChanged(this, "OnValidate");
 }
 /*--------------------------------------------------------------------------------------------*/
 public virtual void OnDisable()
 {
     TreeUpdater.SendTreeUpdatableChanged(this, "OnDisabled");
 }