pub struct KickoffTakerEvent {Show 28 fields
pub player: PlayerId,
pub is_team_0: bool,
pub start_position: [f32; 3],
pub spawn_position: KickoffSpawnPosition,
pub start_boost: Option<f32>,
pub boost_after: Option<f32>,
pub time_to_ball: Option<f32>,
pub boost_collected: f32,
pub boost_used: f32,
pub ball_direction: KickoffBallDirection,
pub first_touch_time: Option<f32>,
pub first_touch_frame: Option<usize>,
pub contact_player_position: Option<[f32; 3]>,
pub contact_player_velocity: Option<[f32; 3]>,
pub contact_car_forward: Option<[f32; 3]>,
pub contact_local_ball_position: Option<[f32; 3]>,
pub contact_local_contact_point: Option<[f32; 3]>,
pub contact_gap: Option<f32>,
pub contact_behind_ball_depth: Option<f32>,
pub contact_lateral_offset: Option<f32>,
pub contact_lateral_abs_offset: Option<f32>,
pub contact_velocity_attack_alignment: Option<f32>,
pub contact_velocity_ball_alignment: Option<f32>,
pub contact_nose_attack_alignment: Option<f32>,
pub contact_ball_exit_attack_alignment: Option<f32>,
pub outcome: KickoffTakerOutcome,
pub approach: KickoffApproach,
pub approach_flip_direction: KickoffFlipDirection,
}Expand description
Kickoff event for the player who challenged the ball.
Fields§
§player: PlayerId§is_team_0: bool§start_position: [f32; 3]§spawn_position: KickoffSpawnPosition§start_boost: Option<f32>§boost_after: Option<f32>Boost remaining at the moment the taker contacts the ball (the
counterpart to boost_used, which is spent reaching that contact).
For takers that never touch the ball (fake / missed) this falls back to
the end-of-kickoff sample. Invariant when the taker touches:
start_boost + boost_collected == boost_used + boost_after.
time_to_ball: Option<f32>§boost_collected: f32§boost_used: f32§ball_direction: KickoffBallDirection§first_touch_time: Option<f32>§first_touch_frame: Option<usize>§contact_player_position: Option<[f32; 3]>Car center position at the taker’s first kickoff touch, when the touch could be matched to a player sample on that frame.
contact_player_velocity: Option<[f32; 3]>§contact_car_forward: Option<[f32; 3]>§contact_local_ball_position: Option<[f32; 3]>Ball center in the taker’s local hitbox coordinates at contact.
contact_local_contact_point: Option<[f32; 3]>Closest point on the taker’s local hitbox to the ball center.
contact_gap: Option<f32>Estimated ball-to-hitbox gap after subtracting the ball collision radius.
contact_behind_ball_depth: Option<f32>Team-normalized distance from car center to ball along the attack axis. Positive means the taker is behind the ball on their own-goal side.
contact_lateral_offset: Option<f32>Team-normalized left/right offset of car center from the ball.
contact_lateral_abs_offset: Option<f32>§contact_velocity_attack_alignment: Option<f32>Alignment of taker velocity with the opponent-goal direction (-1..=1).
contact_velocity_ball_alignment: Option<f32>Alignment of taker velocity with the car-to-ball direction (-1..=1).
contact_nose_attack_alignment: Option<f32>Alignment of taker nose direction with the opponent-goal direction.
contact_ball_exit_attack_alignment: Option<f32>Alignment of the ball’s first-touch exit velocity with the taker’s opponent-goal direction.
outcome: KickoffTakerOutcome§approach: KickoffApproach§approach_flip_direction: KickoffFlipDirectionTrait Implementations§
Source§impl Clone for KickoffTakerEvent
impl Clone for KickoffTakerEvent
Source§impl Debug for KickoffTakerEvent
impl Debug for KickoffTakerEvent
Source§impl PartialEq for KickoffTakerEvent
impl PartialEq for KickoffTakerEvent
Source§impl Serialize for KickoffTakerEvent
impl Serialize for KickoffTakerEvent
impl StructuralPartialEq for KickoffTakerEvent
Source§impl TS for KickoffTakerEvent
impl TS for KickoffTakerEvent
Source§type WithoutGenerics = KickoffTakerEvent
type WithoutGenerics = KickoffTakerEvent
WithoutGenerics should just be Self.
If the type does have generic parameters, then all generic parameters must be replaced with
a dummy type, e.g ts_rs::Dummy or ().
The only requirement for these dummy types is that EXPORT_TO must be None. Read moreSource§type OptionInnerType = KickoffTakerEvent
type OptionInnerType = KickoffTakerEvent
std::option::Option<T>, then this associated type is set to T.
All other implementations of TS should set this type to Self instead.Source§fn docs() -> Option<String>
fn docs() -> Option<String>
TS is derived, docs are
automatically read from your doc comments or #[doc = ".."] attributesSource§fn decl_concrete() -> String
fn decl_concrete() -> String
TS::decl().
If this type is not generic, then this function is equivalent to TS::decl().Source§fn decl() -> String
fn decl() -> String
type User = { user_id: number, ... }.
This function will panic if the type has no declaration. Read moreSource§fn inline() -> String
fn inline() -> String
{ user_id: number }.
This function will panic if the type cannot be inlined.Source§fn inline_flattened() -> String
fn inline_flattened() -> String
This function will panic if the type cannot be flattened.
Source§fn visit_generics(v: &mut impl TypeVisitor)where
Self: 'static,
fn visit_generics(v: &mut impl TypeVisitor)where
Self: 'static,
Source§fn output_path() -> Option<PathBuf>
fn output_path() -> Option<PathBuf>
T should be exported.The returned path does not include the base directory from
TS_RS_EXPORT_DIR. Read moreSource§fn visit_dependencies(v: &mut impl TypeVisitor)where
Self: 'static,
fn visit_dependencies(v: &mut impl TypeVisitor)where
Self: 'static,
Source§fn dependencies() -> Vec<Dependency>where
Self: 'static,
fn dependencies() -> Vec<Dependency>where
Self: 'static,
Source§fn export() -> Result<(), ExportError>where
Self: 'static,
fn export() -> Result<(), ExportError>where
Self: 'static,
TS::export_all. Read moreSource§fn export_all() -> Result<(), ExportError>where
Self: 'static,
fn export_all() -> Result<(), ExportError>where
Self: 'static,
To export only this type, without its dependencies, use
TS::export. Read moreSource§fn export_all_to(out_dir: impl AsRef<Path>) -> Result<(), ExportError>where
Self: 'static,
fn export_all_to(out_dir: impl AsRef<Path>) -> Result<(), ExportError>where
Self: 'static,
To export only this type, without its dependencies, use
TS::export. Read more