pub struct KeySound {
pub volume: u8,
pub hitsound_type: HitSoundType,
pub sample: Option<usize>,
pub has_custom: bool,
}Fields§
§volume: u8§hitsound_type: HitSoundType§sample: Option<usize>§has_custom: boolImplementations§
Source§impl KeySound
impl KeySound
pub fn of_type(volume: u8, hitsound_type: HitSoundType) -> Self
pub fn normal(volume: u8) -> Self
pub fn clap(volume: u8) -> Self
pub fn whistle(volume: u8) -> Self
pub fn finish(volume: u8) -> Self
pub fn with_custom( volume: u8, sample_index: usize, hitsound_type: Option<HitSoundType>, ) -> Self
Trait Implementations§
impl Copy for KeySound
Source§impl FromWasmAbi for KeySound
impl FromWasmAbi for KeySound
Source§impl IntoWasmAbi for KeySound
impl IntoWasmAbi for KeySound
Source§impl LongRefFromWasmAbi for KeySound
impl LongRefFromWasmAbi for KeySound
Source§impl OptionFromWasmAbi for KeySound
impl OptionFromWasmAbi for KeySound
Source§impl OptionIntoWasmAbi for KeySound
impl OptionIntoWasmAbi for KeySound
Source§impl RefFromWasmAbi for KeySound
impl RefFromWasmAbi for KeySound
Source§impl RefMutFromWasmAbi for KeySound
impl RefMutFromWasmAbi for KeySound
impl SupportsConstructor for KeySound
impl SupportsInstanceProperty for KeySound
impl SupportsStaticProperty for KeySound
Source§impl TryFromJsValue for KeySound
impl TryFromJsValue for KeySound
Source§impl VectorFromWasmAbi for KeySound
impl VectorFromWasmAbi for KeySound
Source§impl VectorIntoWasmAbi for KeySound
impl VectorIntoWasmAbi for KeySound
Auto Trait Implementations§
impl Freeze for KeySound
impl RefUnwindSafe for KeySound
impl Send for KeySound
impl Sync for KeySound
impl Unpin for KeySound
impl UnsafeUnpin for KeySound
impl UnwindSafe for KeySound
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
Source§type Abi = <T as IntoWasmAbi>::Abi
type Abi = <T as IntoWasmAbi>::Abi
Same as
IntoWasmAbi::AbiSource§fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
Same as
IntoWasmAbi::into_abi, except that it may throw and never
return in the case of Err.