use derive_new::new;
use getset::{CopyGetters, Getters};
use crate::packet::header::Header;
use crate::types::{CornerProperty, Property3D};
#[derive(new, Debug, CopyGetters, Getters, PartialEq, Copy, Clone, PartialOrd, Default)]
#[allow(clippy::too_many_arguments)]
pub struct Motion {
#[getset(get = "pub")]
position: Property3D<f32>,
#[getset(get = "pub")]
velocity: Property3D<f32>,
#[getset(get = "pub")]
forward_direction: Property3D<i16>,
#[getset(get = "pub")]
right_direction: Property3D<i16>,
#[getset(get = "pub")]
g_force: Property3D<f32>,
#[getset(get_copy = "pub")]
yaw: f32,
#[getset(get_copy = "pub")]
pitch: f32,
#[getset(get_copy = "pub")]
roll: f32,
}
#[derive(new, Debug, CopyGetters, Getters, PartialEq, Clone, PartialOrd)]
#[allow(clippy::too_many_arguments)]
pub struct MotionPacket {
#[getset(get = "pub")]
header: Header,
#[getset(get = "pub")]
cars: Vec<Motion>,
#[getset(get = "pub")]
suspension_position: CornerProperty<f32>,
#[getset(get = "pub")]
suspension_velocity: CornerProperty<f32>,
#[getset(get = "pub")]
suspension_acceleration: CornerProperty<f32>,
#[getset(get = "pub")]
wheel_speed: CornerProperty<f32>,
#[getset(get = "pub")]
wheel_slip: CornerProperty<f32>,
#[getset(get = "pub")]
local_velocity: Property3D<f32>,
#[getset(get = "pub")]
angular_velocity: Property3D<f32>,
#[getset(get = "pub")]
angular_acceleration: Property3D<f32>,
#[getset(get_copy = "pub")]
front_wheels_angle: f32,
}