public override AbstractParams InsertColor(int index, Color v) { if (this.colorList == null) { colorList = new ParamsList <Color>(); } if (this._OriginArgCount >= 0) { _ArgCount++; _virtualArg++; _OriginArgCount++; colorList.Add(v); ArgSortList.Insert(index, new KeyValuePair <int, int>((int)ParamType.Color, colorList.Count - 1)); } else { _ArgCount++; colorList.Add(v); ArgSortList.Insert(index, new KeyValuePair <int, int>((int)ParamType.Color, colorList.Count - 1)); } return(this); }
public override AbstractParams InsertLong(int index, long v) { if (this.longList == null) { longList = new ParamsList <long>(); } if (this._OriginArgCount >= 0) { _ArgCount++; _virtualArg++; _OriginArgCount++; longList.Add(v); ArgSortList.Insert(index, new KeyValuePair <int, int>((int)ParamType.LONG, longList.Count - 1)); } else { _ArgCount++; longList.Add(v); ArgSortList.Insert(index, new KeyValuePair <int, int>((int)ParamType.LONG, longList.Count - 1)); } return(this); }
public override AbstractParams InsertVector3(int index, UnityEngine.Vector3 v) { if (this.vector3List == null) { vector3List = new ParamsList <Vector3>(); } if (this._OriginArgCount >= 0) { _ArgCount++; _virtualArg++; _OriginArgCount++; vector3List.Add(v); ArgSortList.Insert(index, new KeyValuePair <int, int>((int)ParamType.VETOR3, vector3List.Count - 1)); } else { _ArgCount++; vector3List.Add(v); ArgSortList.Insert(index, new KeyValuePair <int, int>((int)ParamType.VETOR3, vector3List.Count - 1)); } return(this); }
public override AbstractParams InsertUnityObject(int index, UnityEngine.Object v) { if (this.UnityObjList == null) { UnityObjList = new ParamsList <UnityEngine.Object>(); } if (this._OriginArgCount >= 0) { _ArgCount++; _virtualArg++; _OriginArgCount++; UnityObjList.Add(v); ArgSortList.Insert(index, new KeyValuePair <int, int>((int)ParamType.UNITYOBJECT, UnityObjList.Count - 1)); } else { _ArgCount++; UnityObjList.Add(v); ArgSortList.Insert(index, new KeyValuePair <int, int>((int)ParamType.UNITYOBJECT, UnityObjList.Count - 1)); } return(this); }
public override AbstractParams InsertDouble(int index, double v) { if (this.doubleList == null) { this.doubleList = new ParamsList <double>(); } if (this._OriginArgCount >= 0) { _ArgCount++; _virtualArg++; _OriginArgCount++; doubleList.Add(v); ArgSortList.Insert(index, new KeyValuePair <int, int>((int)ParamType.DOUBLE, doubleList.Count - 1)); } else { _ArgCount++; doubleList.Add(v); ArgSortList.Insert(index, new KeyValuePair <int, int>((int)ParamType.DOUBLE, doubleList.Count - 1)); } return(this); }
public override AbstractParams InsertFloat(int index, float v) { if (floatList == null) { floatList = new ParamsList <float>(); } if (this._OriginArgCount >= 0) { _ArgCount++; _virtualArg++; _OriginArgCount++; floatList.Add(v); ArgSortList.Insert(index, new KeyValuePair <int, int>((int)ParamType.FLOAT, floatList.Count - 1)); } else { _ArgCount++; floatList.Add(v); ArgSortList.Insert(index, new KeyValuePair <int, int>((int)ParamType.FLOAT, floatList.Count - 1)); } return(this); }
public override AbstractParams InsertBool(int index, bool v) { if (this.boollist == null) { boollist = new ParamsList <bool>(); } if (this._OriginArgCount >= 0) { _ArgCount++; _virtualArg++; _OriginArgCount++; boollist.Add(v); ArgSortList.Insert(index, new KeyValuePair <int, int>((int)ParamType.BOOL, boollist.Count - 1)); } else { _ArgCount++; boollist.Add(v); ArgSortList.Insert(index, new KeyValuePair <int, int>((int)ParamType.BOOL, boollist.Count - 1)); } return(this); }
public override AbstractParams InsertShort(int index, short v) { if (this.shortlist == null) { this.shortlist = new ParamsList <short>(); } if (this._OriginArgCount >= 0) { _ArgCount++; _virtualArg++; _OriginArgCount++; shortlist.Add(v); ArgSortList.Insert(index, new KeyValuePair <int, int>((int)ParamType.SHORT, shortlist.Count - 1)); } else { _ArgCount++; shortlist.Add(v); ArgSortList.Insert(index, new KeyValuePair <int, int>((int)ParamType.SHORT, shortlist.Count - 1)); } return(this); }
private void LoadParams() { this.ParamsList = new List <Params>(); XElement xe = XElement.Load(paramXml); foreach (var item in xe.Elements("params")) { Params Params = new Params(); Params.Id = item.Attribute("id").Value; Params.Name = item.Attribute("name").Value; Params.Desc = item.Attribute("desc").Value; Params.ParamList = new List <Param>(); foreach (var param in item.Descendants("param")) { Param p = new Param(); p.Id = param.Attribute("id").Value; p.Key = param.Attribute("key").Value; p.Value = param.Attribute("value").Value; Params.ParamList.Add(p); } ParamsList.Add(Params); } }