public static void DecodeInto(this string data, out Countless<Quaternion> c) { c = new Countless<Quaternion>(); var cody = new CfgDecoder(data); foreach (var tag in cody) c[tag.ToInt()] = cody.GetData().ToQuaternion(); }
public static CfgEncoder Encode(this Countless<Quaternion> c) { var cody = new CfgEncoder(); List<int> inds; List<Quaternion> vals = c.GetAllObjs(out inds); for (int i = 0; i < inds.Count; i++) cody.Add(inds[i].ToString(), vals[i]); return cody; }
public static void DecodeInto(this string data, out Countless <Vector3> c) { c = new Countless <Vector3>(); var cody = new CfgDecoder(data); foreach (var tag in cody) { c[tag.ToInt()] = cody.GetData().ToVector3(); } }
public static void DecodeInto_Countless(this string data, out Countless <float> c) { c = new Countless <float>(); var cody = new CfgDecoder(data); foreach (var tag in cody) { c[tag.ToInt()] = cody.GetData().ToFloat(); } }
public static CfgEncoder Encode(this Countless<Vector3> c) { var cody = new CfgEncoder(); if (c != null) { List<int> inds; List<Vector3> vals = c.GetAllObjs(out inds); for (int i = 0; i < inds.Count; i++) cody.Add(inds[i].ToString(), vals[i]); } return cody; }
public static CfgEncoder Encode(this Countless <float> c) { var cody = new CfgEncoder(); List <int> inds; List <float> vals = c.GetAllObjs(out inds); for (int i = 0; i < inds.Count; i++) { cody.Add(inds[i].ToString(), vals[i]); } return(cody); }