pub struct History<G: Game, T: RendererData<G>> { /* private fields */ }
Implementations§
Source§impl<G: Game, T: RendererData<G>> History<G, T>
impl<G: Game, T: RendererData<G>> History<G, T>
Source§impl<G: Game, T: RendererData<G>> History<G, T>
impl<G: Game, T: RendererData<G>> History<G, T>
Source§impl<G: Game, T: RendererData<G>> History<G, T>
impl<G: Game, T: RendererData<G>> History<G, T>
pub fn new(initial_game_state: G) -> Self
pub fn current_state(&self) -> RenderState<'_, G, T>
pub fn len(&self) -> usize
pub fn go_to( &mut self, tick_time: f64, collect_events: bool, ) -> Box<dyn Iterator<Item = G::Event>>
pub fn tick_handler(&self) -> impl FnMut(&G, Vec<G::Event>) + Send + 'static
pub fn debug_command_handler( &self, ) -> impl Fn(usize, bool, DebugCommand<G>) + Send + 'static
Auto Trait Implementations§
impl<G, T> Freeze for History<G, T>
impl<G, T> RefUnwindSafe for History<G, T>where
G: RefUnwindSafe,
T: RefUnwindSafe,
<G as Game>::Event: RefUnwindSafe,
<G as Game>::DebugData: RefUnwindSafe,
impl<G, T> Send for History<G, T>
impl<G, T> Sync for History<G, T>
impl<G, T> Unpin for History<G, T>
impl<G, T> UnwindSafe for History<G, T>where
G: UnwindSafe,
T: UnwindSafe,
<G as Game>::Event: RefUnwindSafe,
<G as Game>::DebugData: RefUnwindSafe,
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more