pub struct FaceInput { /* private fields */ }Expand description
A single encoded face-button input entry from a Mario Kart Wii ghost file.
Each entry records which face buttons were held and for how many consecutive frames they were held. Unlike D-pad inputs, the frame duration is stored as a single byte and does not support multi-byte encoding.
Implementations§
Source§impl FaceInput
impl FaceInput
Returns the set of face buttons active during this input entry.
Sourcepub fn frame_duration(&self) -> u32
pub fn frame_duration(&self) -> u32
Returns the number of frames this button state was held.
Sourcepub fn set_frame_duration(&mut self, frame_duration: u32)
pub fn set_frame_duration(&mut self, frame_duration: u32)
Sets the number of frames this button state was held.
Trait Implementations§
Source§impl PartialEq for FaceInput
Two FaceInput values are equal if they share the same set of active
buttons, regardless of frame duration.
impl PartialEq for FaceInput
Two FaceInput values are equal if they share the same set of active
buttons, regardless of frame duration.
Auto Trait Implementations§
impl Freeze for FaceInput
impl RefUnwindSafe for FaceInput
impl Send for FaceInput
impl Sync for FaceInput
impl Unpin for FaceInput
impl UnsafeUnpin for FaceInput
impl UnwindSafe for FaceInput
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