public readonly CoordB ToByte() { return(CoordB.From( (sbyte)(X / Block.BLOCK_SIZE), (sbyte)(Y / Block.BLOCK_SIZE), (sbyte)(Z / Block.BLOCK_SIZE))); }
public static CoordB Parse(string value, string separator) { string[] coord = value.Split(separator); return(CoordB.From( (sbyte)sbyte.Parse(coord[0]), (sbyte)sbyte.Parse(coord[1]), (sbyte)sbyte.Parse(coord[2]) )); }
public bool Equals(CoordB other) { return(X == other.X && Y == other.Y && Z == other.Z); }
public static sbyte Distance(CoordB left, CoordB right) { CoordB displacement = left - right; return(displacement.Length()); }
public bool Equals(CoordB other) => X == other.X && Y == other.Y && Z == other.Z;
public static sbyte Distance(CoordB left, CoordB right) => (left - right).Length();
public readonly CoordB Add(CoordB other) { return(From((sbyte)(X + other.X), (sbyte)(Y + other.Y), (sbyte)(Z + other.Z))); }