pub struct LoosePossessionEvent {
pub time: f32,
pub frame: usize,
pub end_time: f32,
pub end_frame: usize,
pub active: bool,
pub duration: f32,
pub possession_state: String,
pub player_id: Option<PlayerId>,
}Expand description
A team-possession span under the loose definition: the team that last touched the ball owns it until the opponent demonstrably takes it away.
Unlike the strict super::possession::PossessionEvent (which only credits
firmly-controlled time and sends loose tails / unconfirmed touches to
neutral), loose possession is sticky: it survives loose balls after a team’s
last touch, survives teammate passes, and survives repelled 50-50s. On a
turnover the boundary is backdated to the opponent’s takeover touch, so the
losing team keeps credit right up to the moment the opponent wins it and
there is no neutral gap. Consequently loose possession is almost always
team_zero or team_one (neutral only before the first touch of a live
stretch, or during a contested scramble off a neutral ball).
Fields§
§time: f32§frame: usize§end_time: f32§end_frame: usize§active: bool§duration: f32§possession_state: String§player_id: Option<PlayerId>Trait Implementations§
Source§impl Clone for LoosePossessionEvent
impl Clone for LoosePossessionEvent
Source§impl Debug for LoosePossessionEvent
impl Debug for LoosePossessionEvent
Source§impl PartialEq for LoosePossessionEvent
impl PartialEq for LoosePossessionEvent
Source§impl Serialize for LoosePossessionEvent
impl Serialize for LoosePossessionEvent
Source§impl StatsEvent for LoosePossessionEvent
impl StatsEvent for LoosePossessionEvent
const DEFINITION: EventDefinition = LOOSE_POSSESSION_EVENT_DEFINITION
impl StructuralPartialEq for LoosePossessionEvent
Source§impl TS for LoosePossessionEvent
impl TS for LoosePossessionEvent
Source§type WithoutGenerics = LoosePossessionEvent
type WithoutGenerics = LoosePossessionEvent
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 = LoosePossessionEvent
type OptionInnerType = LoosePossessionEvent
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