pub struct Moves {
pub jump: bool,
pub dash: bool,
pub dive: bool,
pub climb: bool,
pub super_dash: bool,
pub glide: bool,
pub max_run: f32,
}Expand description
Which built-in moves may run this step, and how fast running may go. Every step starts
from Moves::ALL; abilities narrow it before the built-in moves run.
A cleared move doesn’t start, and one in progress lets go where that makes sense (a
climb without climb lets go of the wall, a glide without glide folds). Presses
stay buffered as usual, so a jump pressed while jump was cleared can still fire once
it is back within the buffer.
Fields§
§jump: boolEvery jump: from the ground, coyote, roll, wall, climb, in the air; and dropping through one-way platforms.
dash: boolStarting a dash.
dive: boolStarting a dive.
climb: boolGrabbing and holding on to walls.
super_dash: boolCharging a super dash.
glide: boolGliding.
max_run: f32The most running (and walking) may reach on its own, units/s: 0.0 keeps the body
from accelerating at all. Speed from elsewhere (a launch, a dash’s end) still
brakes down to it at the tuning’s rate.
Implementations§
Trait Implementations§
impl Copy for Moves
impl StructuralPartialEq for Moves
Auto Trait Implementations§
impl Freeze for Moves
impl RefUnwindSafe for Moves
impl Send for Moves
impl Sync for Moves
impl Unpin for Moves
impl UnsafeUnpin for Moves
impl UnwindSafe for Moves
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.