pub struct BoostCalculator { /* private fields */ }Expand description
Tracks boost-pad pickups and boost respawns per player.
Implementations§
Source§impl BoostCalculator
impl BoostCalculator
pub fn new() -> Self
pub fn with_config(config: BoostCalculatorConfig) -> Self
pub fn pickup_events(&self) -> &[BoostPickupEvent]
pub fn new_pickup_events(&self) -> &[BoostPickupEvent]
pub fn respawn_events(&self) -> &[RespawnEvent]
pub fn new_respawn_events(&self) -> &[RespawnEvent]
pub fn player_boost_stats(&self) -> &HashMap<PlayerId, BoostStats>
pub fn player_boost_stats_for(&self, player_id: &PlayerId) -> BoostStats
pub fn team_zero_boost_stats(&self) -> &BoostStats
pub fn team_one_boost_stats(&self) -> &BoostStats
Sourcepub fn boost_stats(&self) -> &BoostStatsAccumulator
pub fn boost_stats(&self) -> &BoostStatsAccumulator
The boost-stats accumulator, populated directly as frames are processed (no event replay).
Sourcepub fn accumulation_tracks(&self) -> Vec<AccumulationTrack>
pub fn accumulation_tracks(&self) -> Vec<AccumulationTrack>
Build the compressed per-player accumulation tracks (boost amount + cumulative used / collected / stolen / overfill). Sorted by player id then quantity for deterministic output.
pub fn resolved_boost_pads(&self) -> Vec<ResolvedBoostPad>
pub fn finish_calculation(&mut self) -> SubtrActorResult<()>
pub fn update_parts( &mut self, frame: &FrameInfo, gameplay: &GameplayState, players: &PlayerFrameState, events: &FrameEventsState, vertical_state: &PlayerVerticalState, live_play_state: &LivePlayState, ) -> SubtrActorResult<()>
Trait Implementations§
Source§impl Clone for BoostCalculator
impl Clone for BoostCalculator
Source§impl Debug for BoostCalculator
impl Debug for BoostCalculator
Auto Trait Implementations§
impl Freeze for BoostCalculator
impl RefUnwindSafe for BoostCalculator
impl Send for BoostCalculator
impl Sync for BoostCalculator
impl Unpin for BoostCalculator
impl UnsafeUnpin for BoostCalculator
impl UnwindSafe for BoostCalculator
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more