1
0
Fork 0
mirror of https://codeberg.org/demostf/parser.git synced 2026-06-04 10:34:11 +02:00

userinfo in player, pitch angle, ticker.next()

This commit is contained in:
Robin Appelman 2022-04-03 14:55:36 +02:00
commit 850e6d7555
4 changed files with 66 additions and 5 deletions

View file

@ -11,6 +11,12 @@ pub struct Vector {
pub z: f32,
}
impl From<Vector> for [f32; 3] {
fn from(vec: Vector) -> Self {
[vec.x, vec.y, vec.z]
}
}
impl PartialEq for Vector {
fn eq(&self, other: &Self) -> bool {
(self.x - other.x < 0.001) && (self.y - other.y < 0.001) && (self.z - other.z < 0.001)