diff --git a/src/vec.rs b/src/vec.rs index 2c1da31..f08095c 100644 --- a/src/vec.rs +++ b/src/vec.rs @@ -162,6 +162,12 @@ impl From<(u8, u8)> for XY { } } +impl From<(u16, u16)> for XY { + fn from((x, y): (u16, u16)) -> Self { + (x as usize, y as usize).into() + } +} + impl, O: Into>> Add for XY { type Output = Self;