pub struct Character<State: GameObject> {
pub state: Managed<State>,
/* private fields */
}Fields§
§state: Managed<State>Implementations§
Source§impl<State: GameObject> Character<State>
impl<State: GameObject> Character<State>
pub fn new( state: State, task: impl Task<CharacterMemory<State>> + 'static, controller: CharacterController<State>, ) -> Self
pub fn activated(self, context: &mut GameContext<'_>) -> Self
Trait Implementations§
Source§impl<State: GameObject> GameObject for Character<State>
impl<State: GameObject> GameObject for Character<State>
fn activate(&mut self, context: &mut GameContext<'_>)
fn deactivate(&mut self, context: &mut GameContext<'_>)
fn process(&mut self, context: &mut GameContext<'_>, delta_time: f32)
fn draw(&mut self, context: &mut GameContext<'_>)
Auto Trait Implementations§
impl<State> !RefUnwindSafe for Character<State>
impl<State> !UnwindSafe for Character<State>
impl<State> Freeze for Character<State>where
State: Freeze,
impl<State> Send for Character<State>where
State: Send,
impl<State> Sync for Character<State>where
State: Sync,
impl<State> Unpin for Character<State>where
State: Unpin,
impl<State> UnsafeUnpin for Character<State>where
State: UnsafeUnpin,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<T> Component for T
impl<S, T> Duplex<S> for Twhere
T: FromSample<S> + ToSample<S>,
Source§impl<S> FromSample<S> for S
impl<S> FromSample<S> for S
fn from_sample_(s: S) -> S
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