Enum SoundSource
#[non_exhaustive]pub enum SoundSource {
Master,
Music,
Records,
Weather,
Blocks,
Hostile,
Neutral,
Players,
Ambient,
Voice,
Ui,
}Expand description
The mixer group a sound plays on (SoundSource), in vanilla’s order.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Master
The master volume, which scales every other source.
Music
Music discs aside, the game’s music.
Records
Jukeboxes and music discs.
Weather
Rain and thunder.
Blocks
Sounds blocks make.
Hostile
Hostile creatures.
Neutral
Friendly and neutral creatures.
Players
Players.
Ambient
Ambient and cave sounds.
Voice
Voice sounds.
Ui
Interface sounds, such as a button click.
Implementations§
§impl SoundSource
impl SoundSource
pub const ALL: [SoundSource; 11]
pub const ALL: [SoundSource; 11]
Every source, in vanilla’s order (SoundSource.values()).
Trait Implementations§
§impl Clone for SoundSource
impl Clone for SoundSource
§fn clone(&self) -> SoundSource
fn clone(&self) -> SoundSource
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for SoundSource
§impl Debug for SoundSource
impl Debug for SoundSource
impl Eq for SoundSource
§impl Hash for SoundSource
impl Hash for SoundSource
§impl PartialEq for SoundSource
impl PartialEq for SoundSource
impl StructuralPartialEq for SoundSource
Auto Trait Implementations§
impl Freeze for SoundSource
impl RefUnwindSafe for SoundSource
impl Send for SoundSource
impl Sync for SoundSource
impl Unpin for SoundSource
impl UnsafeUnpin for SoundSource
impl UnwindSafe for SoundSource
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