Exemplo n.º 1
0
 private void Reset()
 {
     if (GetComponent <UIMediatorLegacy>() == null)
     {
         gameObject.AddComponent(typeof(UIMediatorLegacy));
     }
     SourceRaw = new BindingSourceData()
     {
         ReferenceType = BindingSourceType.MonoBehaviour, ObjectReference = null
     };
 }
Exemplo n.º 2
0
 public virtual void OnBeforeSerialize()
 {
     SourceRaw = new BindingSourceData()
     {
         ObjectReference = Source as Object, ReferenceType = BindingSourceType.MonoBehaviour
     };
     if (Source as BindingSourceScriptableObject != null)
     {
         SourceRaw.ReferenceType = BindingSourceType.ScriptableObject;
     }
     if (Source != null && Source.LockBindingMode)
     {
         this.BindingMode = Source.PrefferedMode;
     }
 }