public static bool Parse(string text, out Vector3Short vector) { vector = new Vector3Short(); if (string.IsNullOrWhiteSpace(text)) { return(false); } var split = text.Split(',', 'x'); if (split.Length != 3) { return(false); } short x, y, z; if (short.TryParse(split[0], out x) || short.TryParse(split[1], out y) || short.TryParse(split[2], out z)) { return(false); } vector = new Vector3Short(x, y, z); return(true); }
public bool Equals(Vector3Short other) { return(other.X == X && other.Y == Y && other.Z == Z); }