mirror of
https://github.com/mat-1/azalea.git
synced 2025-08-02 06:16:04 +00:00
fix wrong ClientboundSoundEntity
This commit is contained in:
parent
aef29daad9
commit
900a4234e5
1 changed files with 4 additions and 15 deletions
|
@ -1,27 +1,16 @@
|
|||
use azalea_buf::AzBuf;
|
||||
use azalea_protocol_macros::ClientboundGamePacket;
|
||||
use azalea_registry::SoundEvent;
|
||||
|
||||
use super::c_sound::{CustomSound, SoundSource};
|
||||
|
||||
#[derive(Clone, Debug, AzBuf, ClientboundGamePacket)]
|
||||
pub struct ClientboundSoundEntity {
|
||||
pub sound: azalea_registry::Holder<SoundEvent, CustomSound>,
|
||||
pub source: SoundSource,
|
||||
#[var]
|
||||
pub id: u32,
|
||||
pub volume: f32,
|
||||
pub pitch: f32,
|
||||
#[var]
|
||||
pub seed: u64,
|
||||
}
|
||||
|
||||
#[derive(AzBuf, Clone, Copy, Debug)]
|
||||
pub enum SoundSource {
|
||||
Master = 0,
|
||||
Music = 1,
|
||||
Records = 2,
|
||||
Weather = 3,
|
||||
Blocks = 4,
|
||||
Hostile = 5,
|
||||
Neutral = 6,
|
||||
Players = 7,
|
||||
Ambient = 8,
|
||||
Voice = 9,
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue