mirror of
https://github.com/mat-1/azalea.git
synced 2025-08-02 06:16:04 +00:00
* add a couple more packets and improve codegen
* enums in packet codegen
* fix enums and MORE PACKETS
* make unsigned numbers the default
* codegen can make hashmaps
* UnsizedByteArray in codegen
* Vec and Option
* enum codgen works in more situations
* ServerboundInteractPacket
* Fix error with new error system
* More packets
* more packets
* more packets
* guess what was added
* yeah it's more packets
* add more packets
* packets
* start adding ClientboundBossEventPacket
* finish boss event packet
* improve codegen for linux
* start on command suggestions packet
* rename declare_commands to commands
* más paquetes
* fix generating custom payload packet
* more packets
* mehr Pakete
* improve codegen for movement packets
* rename move packets to have "packet" at the end
* fix some unused variable warns
* addere plus facis
* pli da pakoj
* plus de paquets
* più pacchetti
* make ChatFormatting a macro in azalea-chat
* change a match to matches! macro
* update SetPlayerTeam to use ChatFormatting
* ClientboundSetScorePacket & fix clippy warnings
* finish game state 🎉
* add remaining packets for other states
* fix error in ping.rs
30 lines
586 B
Rust
30 lines
586 B
Rust
use azalea_buf::McBuf;
|
|
use packet_macros::ClientboundGamePacket;
|
|
|
|
#[derive(Clone, Debug, McBuf, ClientboundGamePacket)]
|
|
pub struct ClientboundSoundPacket {
|
|
// TODO: sound enum/registry
|
|
#[var]
|
|
pub sound: u32,
|
|
pub source: SoundSource,
|
|
pub x: i32,
|
|
pub y: i32,
|
|
pub z: i32,
|
|
pub volume: f32,
|
|
pub pitch: f32,
|
|
pub seed: u64,
|
|
}
|
|
|
|
#[derive(McBuf, 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,
|
|
}
|