public override string EncodeValues(plyVar wrapper) { if (this._baseType != null && this._plyVarType != null) { this.baseTypeName = this._baseType.AssemblyQualifiedName; this.plyVarTypeName = this._plyVarType.AssemblyQualifiedName; if (typeof(UnityEngine.Object).IsAssignableFrom(this._baseType)) { this.storedEntriesData = new string[0]; } else { this.storedEntriesData = new string[this.variables.Count]; for (int i = 0; i < this.variables.Count; i++) { this.storedEntriesData[i] = this.variables[i].ValueHandler.EncodeValues(wrapper); } } return(base.EncodeValues(wrapper)); } Debug.LogError("The List's generic type or plyVar type was not set."); return(""); }
public override void SetValue(plyVar wrapper, object v) { if (v == null) { throw new Exception("Can't convert null to Color32."); } if (v.GetType() == typeof(Color32)) { this.storedValue = (Color32)v; } else if (v.GetType() == typeof(Color)) { this.storedValue = (Color)v; } else { if (v.GetType() != typeof(Vector4)) { throw new Exception("Can't convert " + v.GetType().Name + " to Color32."); } this.storedValue = (Color32)v; } }
public override void SetValue(plyVar wrapper, object v) { if (v == null) { throw new Exception("Can't convert null to Vector2."); } if (v.GetType() == typeof(Vector2)) { this.storedValue = (Vector2)v; return; } if (v.GetType() == typeof(Vector3)) { this.storedValue = (Vector3)v; return; } if (v.GetType() == typeof(Vector4)) { this.storedValue = (Vector4)v; return; } throw new Exception("Can't convert " + v.GetType().Name + " to Vector2."); }
public override object GetValue(plyVar wrapper) { return(this.list); }
public virtual void DecodeValues(plyVar wrapper, string data) { JsonUtility.FromJsonOverwrite(data, this); }
public override void ClearValue(plyVar wrapper) { this.storedValue = Color.black; }
public override string EncodeValues(plyVar wrapper) { this.cachedWrapper = wrapper; return(""); }
public override void ClearValue(plyVar wrapper) { this.cachedWrapper = wrapper; wrapper.objRefs = null; }
public override void ClearValue(plyVar wrapper) { this.storedValue = Vector3.zero; }
public override string EncodeValues(plyVar wrapper) { this.cachedWrapper = wrapper; this.storedTypeName = this.objectType.AssemblyQualifiedName; return(base.EncodeValues(wrapper)); }
public override void SetValue(plyVar wrapper, object v) { this.storedValue = v; }
public override void ClearValue(plyVar wrapper) { this.storedValue = new AnimationCurve(); }
public override void ClearValue(plyVar wrapper) { this.storedEntriesDataData = null; this.arr = ((this._baseType == null) ? null : Array.CreateInstance(this._baseType, 0)); }
public override void ClearValue(plyVar wrapper) { this.storedValue = Quaternion.identity; }
public override void ClearValue(plyVar wrapper) { this.storedValue = ""; }
public override void ClearValue(plyVar wrapper) { this.storedValue = new Gradient(); }
public virtual object GetValue(plyVar wrapper) { return(null); }
public override object GetValue(plyVar wrapper) { return(this.storedValue); }
public virtual void SetValue(plyVar wrapper, object v) { }
public override void ClearValue(plyVar wrapper) { this.storedValue = default(Color32); }
public virtual string EncodeValues(plyVar wrapper) { return(JsonUtility.ToJson(this)); }
public override void DecodeValues(plyVar wrapper, string data) { this.cachedWrapper = wrapper; }
public virtual void ClearValue(plyVar wrapper) { }