diff options
376 files changed, 1084 insertions, 1084 deletions
diff --git a/azalea-auth/src/auth.rs b/azalea-auth/src/auth.rs index 779910d3..ef084d95 100644 --- a/azalea-auth/src/auth.rs +++ b/azalea-auth/src/auth.rs @@ -224,7 +224,7 @@ pub struct DeviceCodeResponse { pub interval: u64, } -#[derive(Debug, Deserialize, Serialize, Clone)] +#[derive(Clone, Debug, Deserialize, Serialize)] pub struct AccessTokenResponse { pub token_type: String, pub expires_in: u64, @@ -244,7 +244,7 @@ pub struct XboxLiveAuthResponse { } /// Just the important data -#[derive(Serialize, Deserialize, Debug)] +#[derive(Debug, Deserialize, Serialize)] pub struct XboxLiveAuth { pub token: String, pub user_hash: String, @@ -273,7 +273,7 @@ pub struct GameOwnershipItem { pub signature: String, } -#[derive(Debug, Clone, Deserialize, Serialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] pub struct ProfileResponse { pub id: Uuid, pub name: String, diff --git a/azalea-auth/src/cache.rs b/azalea-auth/src/cache.rs index da200053..62921773 100644 --- a/azalea-auth/src/cache.rs +++ b/azalea-auth/src/cache.rs @@ -26,7 +26,7 @@ pub enum CacheError { Parse(serde_json::Error), } -#[derive(Deserialize, Serialize, Debug)] +#[derive(Debug, Deserialize, Serialize)] pub struct CachedAccount { #[serde(alias = "email")] pub cache_key: String, @@ -40,7 +40,7 @@ pub struct CachedAccount { pub profile: crate::auth::ProfileResponse, } -#[derive(Deserialize, Serialize, Debug)] +#[derive(Debug, Deserialize, Serialize)] pub struct ExpiringValue<T> { /// Seconds since the UNIX epoch pub expires_at: u64, diff --git a/azalea-auth/src/game_profile.rs b/azalea-auth/src/game_profile.rs index 9038ea61..99af322d 100644 --- a/azalea-auth/src/game_profile.rs +++ b/azalea-auth/src/game_profile.rs @@ -11,7 +11,7 @@ use serde::{Deserialize, Serialize, Serializer}; use uuid::Uuid; /// Information about the player that's usually stored on Mojang's servers. -#[derive(Debug, Clone, Default, Eq, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, Default, Eq, PartialEq)] pub struct GameProfile { /// The UUID of the player. /// @@ -49,7 +49,7 @@ impl From<SerializableGameProfile> for GameProfile { } /// The properties of the player, including their in-game skin and cape. -#[derive(Debug, Clone, Default, Eq, PartialEq)] +#[derive(Clone, Debug, Default, Eq, PartialEq)] pub struct GameProfileProperties { pub map: IndexMap<String, ProfilePropertyValue>, } @@ -82,7 +82,7 @@ impl AzaleaWrite for GameProfileProperties { } } -#[derive(Debug, Clone, Eq, PartialEq)] +#[derive(Clone, Debug, Eq, PartialEq)] pub struct ProfilePropertyValue { pub value: String, pub signature: Option<String>, @@ -102,7 +102,7 @@ impl AzaleaWrite for ProfilePropertyValue { } } -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] pub struct SerializableGameProfile { #[serde(default)] #[serde(skip_serializing_if = "Option::is_none")] @@ -125,7 +125,7 @@ impl From<GameProfile> for SerializableGameProfile { } } -#[derive(Debug, Clone, Serialize, Deserialize, Default)] +#[derive(Clone, Debug, Default, Deserialize, Serialize)] #[serde(transparent)] pub struct SerializableProfileProperties { pub list: Vec<SerializableProfilePropertyValue>, @@ -135,7 +135,7 @@ impl SerializableProfileProperties { self.list.is_empty() } } -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] pub struct SerializableProfilePropertyValue { pub name: String, pub value: String, diff --git a/azalea-block/azalea-block-macros/src/lib.rs b/azalea-block/azalea-block-macros/src/lib.rs index 1abfacbb..586d6a98 100644 --- a/azalea-block/azalea-block-macros/src/lib.rs +++ b/azalea-block/azalea-block-macros/src/lib.rs @@ -122,7 +122,7 @@ struct PropertyVariantData { pub index: usize, } -#[derive(Clone, Copy, Debug, PartialEq, Eq)] +#[derive(Clone, Copy, Debug, Eq, PartialEq)] enum PropertyKind { Enum, Bool, @@ -471,7 +471,7 @@ pub fn make_block_states(input: TokenStream) -> TokenStream { let as_block_state = quote! { BlockState::new_const(#as_block_state_inner) }; let mut block_struct = quote! { - #[derive(Debug, Copy, Clone, PartialEq)] + #[derive(Clone, Copy, Debug, PartialEq)] pub struct #block_struct_name }; if block_struct_fields.is_empty() { diff --git a/azalea-block/azalea-block-macros/src/property/generate.rs b/azalea-block/azalea-block-macros/src/property/generate.rs index 1af9b073..c49afd53 100644 --- a/azalea-block/azalea-block-macros/src/property/generate.rs +++ b/azalea-block/azalea-block-macros/src/property/generate.rs @@ -59,7 +59,7 @@ fn generate_property_code( } properties_code.extend(quote! { - #[derive(Debug, Clone, Copy, PartialEq, Eq)] + #[derive(Clone, Copy, Debug, Eq, PartialEq)] pub enum #property_struct_name { #property_enum_variants } @@ -81,7 +81,7 @@ fn generate_property_code( }); properties_code.extend(quote! { - #[derive(Debug, Clone, Copy, PartialEq, Eq)] + #[derive(Clone, Copy, Debug, Eq, PartialEq)] pub struct #property_struct_name(pub bool); impl From<BlockStateIntegerRepr> for #property_struct_name { diff --git a/azalea-block/src/block_state.rs b/azalea-block/src/block_state.rs index d39961b3..f7ef9006 100644 --- a/azalea-block/src/block_state.rs +++ b/azalea-block/src/block_state.rs @@ -24,7 +24,7 @@ pub type BlockStateIntegerRepr = u16; /// /// Note that this type is internally either a `u16` or `u32`, depending on /// [`BlockStateIntegerRepr`]. -#[derive(Copy, Clone, PartialEq, Eq, Default, Hash)] +#[derive(Clone, Copy, Default, Eq, Hash, PartialEq)] pub struct BlockState { id: BlockStateIntegerRepr, } diff --git a/azalea-block/src/fluid_state.rs b/azalea-block/src/fluid_state.rs index 0a8f7336..155a92be 100644 --- a/azalea-block/src/fluid_state.rs +++ b/azalea-block/src/fluid_state.rs @@ -22,7 +22,7 @@ pub struct FluidState { /// set (see FlowingFluid.getFlowing) pub falling: bool, } -#[derive(Default, Clone, Copy, Debug, PartialEq, Eq)] +#[derive(Clone, Copy, Debug, Default, Eq, PartialEq)] pub enum FluidKind { #[default] Empty, diff --git a/azalea-block/src/range.rs b/azalea-block/src/range.rs index 53d2c10f..3680314a 100644 --- a/azalea-block/src/range.rs +++ b/azalea-block/src/range.rs @@ -8,7 +8,7 @@ use azalea_registry::{builtin::BlockKind, tags::RegistryTag}; use crate::{BlockState, block_state::BlockStateIntegerRepr}; -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub struct BlockStates { pub set: HashSet<BlockState>, } diff --git a/azalea-brigadier/src/builder/literal_argument_builder.rs b/azalea-brigadier/src/builder/literal_argument_builder.rs index 9761609e..7045b79f 100644 --- a/azalea-brigadier/src/builder/literal_argument_builder.rs +++ b/azalea-brigadier/src/builder/literal_argument_builder.rs @@ -1,6 +1,6 @@ use super::argument_builder::{ArgumentBuilder, ArgumentBuilderType}; -#[derive(Debug, Clone, Default)] +#[derive(Clone, Debug, Default)] pub struct Literal { pub value: String, } diff --git a/azalea-brigadier/src/context/string_range.rs b/azalea-brigadier/src/context/string_range.rs index 75163405..8fc44e69 100644 --- a/azalea-brigadier/src/context/string_range.rs +++ b/azalea-brigadier/src/context/string_range.rs @@ -1,6 +1,6 @@ use std::cmp; -#[derive(Debug, Clone, PartialEq, Eq, Hash, Default, Copy)] +#[derive(Clone, Copy, Debug, Default, Eq, Hash, PartialEq)] pub struct StringRange { start: usize, end: usize, diff --git a/azalea-brigadier/src/suggestion/mod.rs b/azalea-brigadier/src/suggestion/mod.rs index 9c2c57f5..95a451f3 100644 --- a/azalea-brigadier/src/suggestion/mod.rs +++ b/azalea-brigadier/src/suggestion/mod.rs @@ -24,14 +24,14 @@ use crate::context::StringRange; /// /// The `M` generic is the type of the tooltip, so for example a `String` or /// just `()` if you don't care about it. -#[derive(Debug, Clone, Hash, Eq, PartialEq)] +#[derive(Clone, Debug, Eq, Hash, PartialEq)] pub struct Suggestion { pub range: StringRange, value: SuggestionValue, pub tooltip: Option<String>, } -#[derive(Debug, Clone, Hash, Eq, PartialEq)] +#[derive(Clone, Debug, Eq, Hash, PartialEq)] pub enum SuggestionValue { Integer(i32), Text(String), diff --git a/azalea-brigadier/src/suggestion/suggestions.rs b/azalea-brigadier/src/suggestion/suggestions.rs index cc77365c..c0090a35 100644 --- a/azalea-brigadier/src/suggestion/suggestions.rs +++ b/azalea-brigadier/src/suggestion/suggestions.rs @@ -12,7 +12,7 @@ use crate::context::StringRange; #[cfg(feature = "azalea-buf")] use crate::suggestion::SuggestionValue; -#[derive(Debug, Clone, Eq, PartialEq, Hash, Default)] +#[derive(Clone, Debug, Default, Eq, Hash, PartialEq)] pub struct Suggestions { range: StringRange, suggestions: Vec<Suggestion>, diff --git a/azalea-brigadier/src/suggestion/suggestions_builder.rs b/azalea-brigadier/src/suggestion/suggestions_builder.rs index 06228947..11debc02 100644 --- a/azalea-brigadier/src/suggestion/suggestions_builder.rs +++ b/azalea-brigadier/src/suggestion/suggestions_builder.rs @@ -3,7 +3,7 @@ use std::collections::HashSet; use super::{Suggestion, SuggestionValue, Suggestions}; use crate::context::StringRange; -#[derive(PartialEq, Debug)] +#[derive(Debug, PartialEq)] pub struct SuggestionsBuilder { input: String, input_lowercase: String, diff --git a/azalea-brigadier/tests/bevy_app_usage.rs b/azalea-brigadier/tests/bevy_app_usage.rs index 4520595a..876666d5 100644 --- a/azalea-brigadier/tests/bevy_app_usage.rs +++ b/azalea-brigadier/tests/bevy_app_usage.rs @@ -177,7 +177,7 @@ impl WorldAccessor { } /// A marker [`Component`] used to test spawning entities from the dispatcher. -#[derive(Debug, Default, Clone, Copy, PartialEq, Eq, Hash, Component)] +#[derive(Clone, Component, Copy, Debug, Default, Eq, Hash, PartialEq)] struct SpawnedEntity; /// Implemented for convenience. diff --git a/azalea-buf/src/definitions.rs b/azalea-buf/src/definitions.rs index 18581aa0..58bec752 100644 --- a/azalea-buf/src/definitions.rs +++ b/azalea-buf/src/definitions.rs @@ -1,7 +1,7 @@ use std::ops::Deref; /// A `Vec<u8>` that isn't prefixed by a VarInt with the size. -#[derive(Debug, Clone, PartialEq, Eq, Hash)] +#[derive(Clone, Debug, Eq, Hash, PartialEq)] pub struct UnsizedByteArray(pub Vec<u8>); impl Deref for UnsizedByteArray { diff --git a/azalea-buf/src/read.rs b/azalea-buf/src/read.rs index a906c8c1..7cea9695 100644 --- a/azalea-buf/src/read.rs +++ b/azalea-buf/src/read.rs @@ -13,7 +13,7 @@ use tracing::warn; use super::{MAX_STRING_LENGTH, UnsizedByteArray}; -#[derive(Error, Debug)] +#[derive(Debug, Error)] pub enum BufReadError { #[error("Invalid VarInt")] InvalidVarInt, diff --git a/azalea-chat/src/style.rs b/azalea-chat/src/style.rs index 7792f812..245e95c1 100644 --- a/azalea-chat/src/style.rs +++ b/azalea-chat/src/style.rs @@ -9,7 +9,7 @@ use simdnbt::owned::{NbtCompound, NbtTag}; use crate::{click_event::ClickEvent, hover_event::HoverEvent}; -#[derive(Clone, PartialEq, Eq, Debug, Hash)] +#[derive(Clone, Debug, Eq, Hash, PartialEq)] pub struct TextColor { pub value: u32, pub name: Option<String>, @@ -97,7 +97,7 @@ impl Ansi { } } -#[derive(Clone, Copy, PartialEq, Eq, Hash, Debug)] +#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)] #[cfg_attr(feature = "azalea-buf", derive(AzBuf))] pub enum ChatFormatting { Black, diff --git a/azalea-chat/src/translatable_component.rs b/azalea-chat/src/translatable_component.rs index f6be2aa5..ed8f1d76 100644 --- a/azalea-chat/src/translatable_component.rs +++ b/azalea-chat/src/translatable_component.rs @@ -9,7 +9,7 @@ use simdnbt::{ use crate::{FormattedText, base_component::BaseComponent, text_component::TextComponent}; -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, Deserialize, PartialEq, Serialize)] #[serde(untagged)] pub enum PrimitiveOrComponent { Boolean(bool), diff --git a/azalea-client/src/account.rs b/azalea-client/src/account.rs index ea49368e..f988ade9 100644 --- a/azalea-client/src/account.rs +++ b/azalea-client/src/account.rs @@ -33,7 +33,7 @@ use uuid::Uuid; /// /// [`Client::join`]: crate::Client::join /// [`azalea::ClientBuilder`]: https://docs.rs/azalea/latest/azalea/struct.ClientBuilder.html -#[derive(Clone, Debug, Component)] +#[derive(Clone, Component, Debug)] pub struct Account { /// The Minecraft username of the account. pub username: String, @@ -269,7 +269,7 @@ impl Account { } #[cfg(feature = "online-mode")] -#[derive(Error, Debug)] +#[derive(Debug, Error)] pub enum RequestCertError { #[error("Failed to fetch certificates")] FetchCertificates(#[from] FetchCertificatesError), diff --git a/azalea-client/src/client.rs b/azalea-client/src/client.rs index 579f5d26..3ba52395 100644 --- a/azalea-client/src/client.rs +++ b/azalea-client/src/client.rs @@ -562,11 +562,11 @@ pub struct JoinedClientBundle { /// A marker component for local players that are currently in the /// `game` state. -#[derive(Component, Clone, Debug, Default)] +#[derive(Clone, Component, Debug, Default)] pub struct InGameState; /// A marker component for local players that are currently in the /// `configuration` state. -#[derive(Component, Clone, Debug, Default)] +#[derive(Clone, Component, Debug, Default)] pub struct InConfigState; pub struct AzaleaPlugin; diff --git a/azalea-client/src/local_player.rs b/azalea-client/src/local_player.rs index 4bc69995..4062e32e 100644 --- a/azalea-client/src/local_player.rs +++ b/azalea-client/src/local_player.rs @@ -24,7 +24,7 @@ use crate::{ClientInformation, events::Event as AzaleaEvent, player::PlayerInfo} /// /// [`InstanceContainer`]: azalea_world::InstanceContainer /// [`InstanceName`]: azalea_world::InstanceName -#[derive(Component, Clone)] +#[derive(Clone, Component)] pub struct InstanceHolder { /// The partial instance is the world this client currently has loaded. /// @@ -40,7 +40,7 @@ pub struct InstanceHolder { /// The gamemode of a local player. For a non-local player, you can look up the /// player in the [`TabList`]. -#[derive(Component, Clone, Debug, Copy)] +#[derive(Clone, Component, Copy, Debug)] pub struct LocalGameMode { pub current: GameMode, pub previous: Option<GameMode>, @@ -55,7 +55,7 @@ impl From<GameMode> for LocalGameMode { } /// Level must be 0..=4 -#[derive(Component, Clone, Default, Deref, DerefMut)] +#[derive(Clone, Component, Default, Deref, DerefMut)] pub struct PermissionLevel(pub u8); /// A component that contains a map of player UUIDs to their information in the @@ -77,10 +77,10 @@ pub struct PermissionLevel(pub u8); /// was updated. /// This means you should avoid using `TabList` as a resource unless you know /// all of your clients will have the same tab list. -#[derive(Component, Resource, Clone, Debug, Deref, DerefMut, Default)] +#[derive(Clone, Component, Debug, Default, Deref, DerefMut, Resource)] pub struct TabList(HashMap<Uuid, PlayerInfo>); -#[derive(Component, Clone)] +#[derive(Clone, Component)] pub struct Hunger { /// The main hunger bar. This is typically in the range `0..=20`. pub food: u32, @@ -147,7 +147,7 @@ impl InstanceHolder { } } -#[derive(Error, Debug)] +#[derive(Debug, Error)] pub enum HandlePacketError { #[error("{0}")] Poison(String), diff --git a/azalea-client/src/ping.rs b/azalea-client/src/ping.rs index 08f909e4..9bdf391e 100644 --- a/azalea-client/src/ping.rs +++ b/azalea-client/src/ping.rs @@ -20,7 +20,7 @@ use azalea_protocol::{ }; use thiserror::Error; -#[derive(Error, Debug)] +#[derive(Debug, Error)] pub enum PingError { #[error("{0}")] Resolve(#[from] resolve::ResolveError), diff --git a/azalea-client/src/player.rs b/azalea-client/src/player.rs index 9a2e7a1c..b1978e7c 100644 --- a/azalea-client/src/player.rs +++ b/azalea-client/src/player.rs @@ -13,7 +13,7 @@ use uuid::Uuid; use crate::packet::game::AddPlayerEvent; /// A player in the tab list. -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub struct PlayerInfo { /// Information about the player's Minecraft account, including their /// username. @@ -38,7 +38,7 @@ pub struct PlayerInfo { /// /// Note that it's possible for this to be missing in a player if the server /// never sent the player info for them (though this is uncommon). -#[derive(Component, Clone, Debug, Deref, DerefMut)] +#[derive(Clone, Component, Debug, Deref, DerefMut)] pub struct GameProfileComponent(pub GameProfile); /// Add a [`GameProfileComponent`] when an [`AddPlayerEvent`] is received. diff --git a/azalea-client/src/plugins/attack.rs b/azalea-client/src/plugins/attack.rs index 7550ed19..eca41503 100644 --- a/azalea-client/src/plugins/attack.rs +++ b/azalea-client/src/plugins/attack.rs @@ -87,7 +87,7 @@ impl Client { /// A component that indicates that this client will be attacking the given /// entity next tick. -#[derive(Component, Clone, Debug)] +#[derive(Clone, Component, Debug)] pub struct AttackQueued { pub target: Entity, } @@ -166,13 +166,13 @@ pub fn handle_attack_event(mut events: MessageReader<AttackEvent>, mut commands: } } -#[derive(Default, Bundle)] +#[derive(Bundle, Default)] pub struct AttackBundle { pub ticks_since_last_attack: TicksSinceLastAttack, pub attack_strength_scale: AttackStrengthScale, } -#[derive(Default, Component, Clone, Deref, DerefMut)] +#[derive(Clone, Component, Default, Deref, DerefMut)] pub struct TicksSinceLastAttack(pub u32); pub fn increment_ticks_since_last_attack(mut query: Query<&mut TicksSinceLastAttack>) { for mut ticks_since_last_attack in query.iter_mut() { @@ -180,7 +180,7 @@ pub fn increment_ticks_since_last_attack(mut query: Query<&mut TicksSinceLastAtt } } -#[derive(Default, Component, Clone, Deref, DerefMut)] +#[derive(Clone, Component, Default, Deref, DerefMut)] pub struct AttackStrengthScale(pub f32); pub fn update_attack_strength_scale( mut query: Query<(&TicksSinceLastAttack, &Attributes, &mut AttackStrengthScale)>, diff --git a/azalea-client/src/plugins/auto_reconnect.rs b/azalea-client/src/plugins/auto_reconnect.rs index fd24f12c..4851a4e7 100644 --- a/azalea-client/src/plugins/auto_reconnect.rs +++ b/azalea-client/src/plugins/auto_reconnect.rs @@ -126,7 +126,7 @@ pub fn rejoin_after_delay( /// You can also remove this resource from the ECS to disable the default /// auto-reconnecting behavior. Inserting the resource/component again will not /// make clients that were already disconnected automatically reconnect. -#[derive(Resource, Component, Debug, Clone)] +#[derive(Clone, Component, Debug, Resource)] pub struct AutoReconnectDelay { pub delay: Duration, } @@ -139,7 +139,7 @@ impl AutoReconnectDelay { /// This is inserted when we're disconnected and indicates when we'll reconnect. /// /// This is set based on [`AutoReconnectDelay`]. -#[derive(Component, Debug, Clone)] +#[derive(Clone, Component, Debug)] pub struct InternalReconnectAfter { pub instant: Instant, } diff --git a/azalea-client/src/plugins/block_update.rs b/azalea-client/src/plugins/block_update.rs index 15e885b6..46e6b409 100644 --- a/azalea-client/src/plugins/block_update.rs +++ b/azalea-client/src/plugins/block_update.rs @@ -26,7 +26,7 @@ impl Plugin for BlockUpdatePlugin { /// [`handle_block_update_event`] (`Update`). /// /// This is a component instead of an ECS event for performance reasons. -#[derive(Component, Debug, Clone, Default)] +#[derive(Clone, Component, Debug, Default)] pub struct QueuedServerBlockUpdates { pub list: Vec<(BlockPos, BlockState)>, } diff --git a/azalea-client/src/plugins/chat/mod.rs b/azalea-client/src/plugins/chat/mod.rs index 7fd14e26..bd90a8d6 100644 --- a/azalea-client/src/plugins/chat/mod.rs +++ b/azalea-client/src/plugins/chat/mod.rs @@ -30,7 +30,7 @@ impl Plugin for ChatPlugin { } /// A chat packet, either a system message or a chat message. -#[derive(Debug, Clone, PartialEq)] +#[derive(Clone, Debug, PartialEq)] pub enum ChatPacket { System(Arc<ClientboundSystemChat>), Player(Arc<ClientboundPlayerChat>), @@ -234,7 +234,7 @@ impl Client { } /// A client received a chat message packet. -#[derive(Message, Debug, Clone)] +#[derive(Clone, Debug, Message)] pub struct ChatReceivedEvent { pub entity: Entity, pub packet: ChatPacket, diff --git a/azalea-client/src/plugins/chunks.rs b/azalea-client/src/plugins/chunks.rs index 317a36c5..d5014516 100644 --- a/azalea-client/src/plugins/chunks.rs +++ b/azalea-client/src/plugins/chunks.rs @@ -47,7 +47,7 @@ pub struct ReceiveChunkEvent { pub packet: ClientboundLevelChunkWithLight, } -#[derive(Component, Clone, Debug)] +#[derive(Clone, Component, Debug)] pub struct ChunkBatchInfo { pub start_time: Instant, pub aggregated_duration_per_chunk: Duration, diff --git a/azalea-client/src/plugins/connection.rs b/azalea-client/src/plugins/connection.rs index dc14545a..70724f4b 100644 --- a/azalea-client/src/plugins/connection.rs +++ b/azalea-client/src/plugins/connection.rs @@ -371,7 +371,7 @@ async fn write_task( trace!("write task is done"); } -#[derive(Error, Debug)] +#[derive(Debug, Error)] pub enum WritePacketError { #[error("Wrong protocol state: expected {expected:?}, got {got:?}")] WrongState { diff --git a/azalea-client/src/plugins/disconnect.rs b/azalea-client/src/plugins/disconnect.rs index 95d1b5ac..8c5036e1 100644 --- a/azalea-client/src/plugins/disconnect.rs +++ b/azalea-client/src/plugins/disconnect.rs @@ -112,7 +112,7 @@ pub fn remove_components_from_disconnected_players( } } -#[derive(Component, Clone, Copy, Debug, Deref)] +#[derive(Clone, Component, Copy, Debug, Deref)] pub struct IsConnectionAlive(bool); fn update_read_packets_task_running_component( diff --git a/azalea-client/src/plugins/events.rs b/azalea-client/src/plugins/events.rs index 0bd738c0..c1b77abe 100644 --- a/azalea-client/src/plugins/events.rs +++ b/azalea-client/src/plugins/events.rs @@ -50,7 +50,7 @@ use crate::{ /// /// Note: Events are sent before they're processed, so for example game ticks /// happen at the beginning of a tick before anything has happened. -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] #[non_exhaustive] pub enum Event { /// Happens right after the bot switches into the Game state, but before diff --git a/azalea-client/src/plugins/interact/mod.rs b/azalea-client/src/plugins/interact/mod.rs index 8269197c..df614b8a 100644 --- a/azalea-client/src/plugins/interact/mod.rs +++ b/azalea-client/src/plugins/interact/mod.rs @@ -82,7 +82,7 @@ impl Plugin for InteractPlugin { } } -#[derive(SystemSet, Debug, Hash, PartialEq, Eq, Clone)] +#[derive(Clone, Debug, Eq, Hash, PartialEq, SystemSet)] pub struct UpdateAttributesSystems; impl Client { @@ -133,7 +133,7 @@ impl Client { /// A component that contains information about our local block state /// predictions. -#[derive(Component, Clone, Debug, Default)] +#[derive(Clone, Component, Debug, Default)] pub struct BlockStatePredictionHandler { /// The total number of changes that this client has made to blocks. seq: u32, @@ -351,7 +351,7 @@ pub fn handle_start_use_item_queued( /// An ECS `Event` that makes the client tell the server that we right-clicked /// an entity. -#[derive(EntityEvent, Clone, Debug)] +#[derive(Clone, Debug, EntityEvent)] pub struct EntityInteractEvent { #[event_target] pub client: Entity, @@ -498,7 +498,7 @@ pub fn can_use_game_master_blocks( /// /// This is purely a visual effect and won't interact with anything in the /// world. -#[derive(EntityEvent, Clone, Debug)] +#[derive(Clone, Debug, EntityEvent)] pub struct SwingArmEvent { pub entity: Entity, } diff --git a/azalea-client/src/plugins/interact/pick.rs b/azalea-client/src/plugins/interact/pick.rs index 580bb50c..8ffe47e8 100644 --- a/azalea-client/src/plugins/interact/pick.rs +++ b/azalea-client/src/plugins/interact/pick.rs @@ -24,7 +24,7 @@ use derive_more::{Deref, DerefMut}; /// A component that contains the block or entity that the player is currently /// looking at. #[doc(alias("looking at", "looking at block", "crosshair"))] -#[derive(Component, Clone, Debug, Deref, DerefMut)] +#[derive(Clone, Component, Debug, Deref, DerefMut)] pub struct HitResultComponent(HitResult); #[allow(clippy::type_complexity)] diff --git a/azalea-client/src/plugins/inventory/equipment_effects.rs b/azalea-client/src/plugins/inventory/equipment_effects.rs index c02f8ad5..47220bf2 100644 --- a/azalea-client/src/plugins/inventory/equipment_effects.rs +++ b/azalea-client/src/plugins/inventory/equipment_effects.rs @@ -78,7 +78,7 @@ pub fn collect_equipment_changes( } } -#[derive(EntityEvent, Debug)] +#[derive(Debug, EntityEvent)] pub struct EquipmentChangesEvent { pub entity: Entity, pub map: HashMap<EquipmentSlot, EquipmentChange>, diff --git a/azalea-client/src/plugins/inventory/mod.rs b/azalea-client/src/plugins/inventory/mod.rs index 93be9e96..09c0d78f 100644 --- a/azalea-client/src/plugins/inventory/mod.rs +++ b/azalea-client/src/plugins/inventory/mod.rs @@ -53,7 +53,7 @@ impl Plugin for InventoryPlugin { } } -#[derive(SystemSet, Debug, Hash, PartialEq, Eq, Clone)] +#[derive(Clone, Debug, Eq, Hash, PartialEq, SystemSet)] pub struct InventorySystems; impl Client { @@ -102,7 +102,7 @@ impl Client { /// To watch for the menu being closed, you could use /// [`ClientsideCloseContainerEvent`]. To close it manually, use /// [`CloseContainerEvent`]. -#[derive(EntityEvent, Debug, Clone)] +#[derive(Clone, Debug, EntityEvent)] pub struct MenuOpenedEvent { pub entity: Entity, pub window_id: i32, @@ -162,7 +162,7 @@ fn handle_container_close_event( /// /// If you want to watch for a container being opened, you should use /// [`MenuOpenedEvent`]. -#[derive(EntityEvent, Clone)] +#[derive(Clone, EntityEvent)] pub struct ClientsideCloseContainerEvent { pub entity: Entity, } @@ -199,7 +199,7 @@ pub fn handle_client_side_close_container_trigger( inventory.container_menu_title = None; } -#[derive(EntityEvent, Debug)] +#[derive(Debug, EntityEvent)] pub struct ContainerClickEvent { pub entity: Entity, pub window_id: i32, diff --git a/azalea-client/src/plugins/join.rs b/azalea-client/src/plugins/join.rs index f1e27165..b1759992 100644 --- a/azalea-client/src/plugins/join.rs +++ b/azalea-client/src/plugins/join.rs @@ -47,7 +47,7 @@ impl Plugin for JoinPlugin { /// /// This won't do anything if a client with the Account UUID is already /// connected to the server. -#[derive(Message, Debug)] +#[derive(Debug, Message)] pub struct StartJoinServerEvent { pub account: Account, pub connect_opts: ConnectOpts, @@ -61,7 +61,7 @@ pub struct StartJoinServerEvent { /// /// These are persisted on reconnects. This is inserted as a component on /// clients to make auto-reconnecting work. -#[derive(Debug, Clone, Component)] +#[derive(Clone, Component, Debug)] pub struct ConnectOpts { pub address: ResolvedAddr, /// The SOCKS5 proxy used for connecting to the Minecraft server. diff --git a/azalea-client/src/plugins/mining.rs b/azalea-client/src/plugins/mining.rs index 6f00c054..56136362 100644 --- a/azalea-client/src/plugins/mining.rs +++ b/azalea-client/src/plugins/mining.rs @@ -68,7 +68,7 @@ impl Plugin for MiningPlugin { } /// The Bevy system set for things related to mining. -#[derive(SystemSet, Debug, Hash, PartialEq, Eq, Clone)] +#[derive(Clone, Debug, Eq, Hash, PartialEq, SystemSet)] pub struct MiningSystems; impl Client { @@ -155,7 +155,7 @@ fn handle_auto_mine( /// Information about the block we're currently mining. /// /// This is only present if we're currently mining a block. -#[derive(Component, Debug, Clone)] +#[derive(Clone, Component, Debug)] pub struct Mining { pub pos: BlockPos, pub dir: Direction, @@ -167,7 +167,7 @@ pub struct Mining { /// /// If we're looking at the block then the correct direction will be used, /// otherwise it'll be [`Direction::Down`]. -#[derive(Message, Debug)] +#[derive(Debug, Message)] pub struct StartMiningBlockEvent { pub entity: Entity, pub position: BlockPos, @@ -230,7 +230,7 @@ fn handle_start_mining_block_event( } /// Present on entities when they're going to start mining a block next tick. -#[derive(Component, Debug, Clone)] +#[derive(Clone, Component, Debug)] pub struct MiningQueued { pub position: BlockPos, pub direction: Direction, @@ -443,7 +443,7 @@ fn is_same_mining_target( } /// A component bundle for players that can mine blocks. -#[derive(Bundle, Default, Clone)] +#[derive(Bundle, Clone, Default)] pub struct MineBundle { pub delay: MineDelay, pub progress: MineProgress, @@ -453,13 +453,13 @@ pub struct MineBundle { } /// A component that counts down until we start mining the next block. -#[derive(Component, Debug, Default, Deref, DerefMut, Clone)] +#[derive(Clone, Component, Debug, Default, Deref, DerefMut)] pub struct MineDelay(pub u32); /// A component that stores the progress of the current mining operation. /// /// This is a value between 0 and 1. -#[derive(Component, Debug, Default, Deref, DerefMut, Clone)] +#[derive(Clone, Component, Debug, Default, Deref, DerefMut)] pub struct MineProgress(pub f32); impl MineProgress { @@ -476,16 +476,16 @@ impl MineProgress { /// block for. /// /// This is a float despite the fact that it should only ever be a round number. -#[derive(Component, Clone, Debug, Default, Deref, DerefMut)] +#[derive(Clone, Component, Debug, Default, Deref, DerefMut)] pub struct MineTicks(pub f32); /// A component that stores the position of the block we're currently mining. -#[derive(Component, Clone, Debug, Default, Deref, DerefMut)] +#[derive(Clone, Component, Debug, Default, Deref, DerefMut)] pub struct MineBlockPos(pub Option<BlockPos>); /// A component that contains the item we're currently using to mine, or /// [`ItemStack::Empty`] if nothing is being mined. -#[derive(Component, Clone, Debug, Default, Deref, DerefMut)] +#[derive(Clone, Component, Debug, Default, Deref, DerefMut)] pub struct MineItem(pub ItemStack); /// A trigger that's sent when we completed mining a block. diff --git a/azalea-client/src/plugins/movement.rs b/azalea-client/src/plugins/movement.rs index 703b5557..15d4a468 100644 --- a/azalea-client/src/plugins/movement.rs +++ b/azalea-client/src/plugins/movement.rs @@ -74,7 +74,7 @@ impl Plugin for MovementPlugin { } } -#[derive(SystemSet, Debug, Hash, PartialEq, Eq, Clone)] +#[derive(Clone, Debug, Eq, Hash, PartialEq, SystemSet)] pub struct MoveEventsSystems; impl Client { @@ -128,7 +128,7 @@ impl Client { /// A component that contains the look direction that was last sent over the /// network. -#[derive(Debug, Component, Clone, Default)] +#[derive(Clone, Component, Debug, Default)] pub struct LastSentLookDirection { pub x_rot: f32, pub y_rot: f32, @@ -242,7 +242,7 @@ pub fn send_position( } } -#[derive(Debug, Default, Component, Clone, PartialEq, Eq)] +#[derive(Clone, Component, Debug, Default, Eq, PartialEq)] pub struct LastSentInput(pub ServerboundPlayerInput); pub fn send_player_input_packet( mut query: Query<(Entity, &PhysicsState, &Jumping, Option<&LastSentInput>)>, @@ -571,7 +571,7 @@ impl Client { /// This does not get sent for non-local entities. /// /// To stop walking or sprinting, send this event with `WalkDirection::None`. -#[derive(Message, Debug)] +#[derive(Debug, Message)] pub struct StartWalkEvent { pub entity: Entity, pub direction: WalkDirection, diff --git a/azalea-client/src/plugins/packet/config/events.rs b/azalea-client/src/plugins/packet/config/events.rs index 92df8d74..9fcce3b5 100644 --- a/azalea-client/src/plugins/packet/config/events.rs +++ b/azalea-client/src/plugins/packet/config/events.rs @@ -9,7 +9,7 @@ use tracing::{debug, error}; use crate::{InConfigState, connection::RawConnection}; -#[derive(Message, Debug, Clone)] +#[derive(Clone, Debug, Message)] pub struct ReceiveConfigPacketEvent { /// The client entity that received the packet. pub entity: Entity, @@ -19,7 +19,7 @@ pub struct ReceiveConfigPacketEvent { /// An event for sending a packet to the server while we're in the /// `configuration` state. -#[derive(EntityEvent, Clone)] +#[derive(Clone, EntityEvent)] pub struct SendConfigPacketEvent { #[event_target] pub sent_by: Entity, @@ -58,7 +58,7 @@ pub fn handle_outgoing_packets_observer( /// /// [`ClientboundPing`]: azalea_protocol::packets::config::ClientboundPing /// [`GamePingEvent`]: crate::packet::game::GamePingEvent -#[derive(Event, Debug, Clone)] +#[derive(Clone, Debug, Event)] pub struct ConfigPingEvent { pub entity: Entity, pub packet: azalea_protocol::packets::config::ClientboundPing, diff --git a/azalea-client/src/plugins/packet/game/events.rs b/azalea-client/src/plugins/packet/game/events.rs index 9ce4c252..535bd519 100644 --- a/azalea-client/src/plugins/packet/game/events.rs +++ b/azalea-client/src/plugins/packet/game/events.rs @@ -31,7 +31,7 @@ use crate::{client::InGameState, connection::RawConnection, player::PlayerInfo}; /// } /// } /// ``` -#[derive(Message, Debug, Clone)] +#[derive(Clone, Debug, Message)] pub struct ReceiveGamePacketEvent { /// The client entity that received the packet. pub entity: Entity, @@ -40,7 +40,7 @@ pub struct ReceiveGamePacketEvent { } /// An event for sending a packet to the server while we're in the `game` state. -#[derive(EntityEvent, Clone, Debug)] +#[derive(Clone, Debug, EntityEvent)] pub struct SendGamePacketEvent { #[event_target] pub sent_by: Entity, @@ -79,7 +79,7 @@ pub fn handle_outgoing_packets_observer( /// A player joined the game (or more specifically, was added to the tab /// list of a local player). -#[derive(Message, Debug, Clone)] +#[derive(Clone, Debug, Message)] pub struct AddPlayerEvent { /// The local player entity that received this event. pub entity: Entity, @@ -87,7 +87,7 @@ pub struct AddPlayerEvent { } /// A player left the game (or maybe is still in the game and was just /// removed from the tab list of a local player). -#[derive(Message, Debug, Clone)] +#[derive(Clone, Debug, Message)] pub struct RemovePlayerEvent { /// The local player entity that received this event. pub entity: Entity, @@ -95,7 +95,7 @@ pub struct RemovePlayerEvent { } /// A player was updated in the tab list of a local player (gamemode, display /// name, or latency changed). -#[derive(Message, Debug, Clone)] +#[derive(Clone, Debug, Message)] pub struct UpdatePlayerEvent { /// The local player entity that received this event. pub entity: Entity, @@ -106,7 +106,7 @@ pub struct UpdatePlayerEvent { /// /// If it's a local player and there's a reason in the death screen, the /// [`ClientboundPlayerCombatKill`] will be included. -#[derive(Message, Debug, Clone)] +#[derive(Clone, Debug, Message)] pub struct DeathEvent { pub entity: Entity, pub packet: Option<ClientboundPlayerCombatKill>, @@ -114,7 +114,7 @@ pub struct DeathEvent { /// A KeepAlive packet is sent from the server to verify that the client is /// still connected. -#[derive(Message, Debug, Clone)] +#[derive(Clone, Debug, Message)] pub struct KeepAliveEvent { pub entity: Entity, /// The ID of the keepalive. @@ -124,7 +124,7 @@ pub struct KeepAliveEvent { pub id: u64, } -#[derive(Message, Debug, Clone)] +#[derive(Clone, Debug, Message)] pub struct ResourcePackEvent { pub entity: Entity, /// The random ID for this request to download the resource pack. @@ -142,7 +142,7 @@ pub struct ResourcePackEvent { /// /// Since the instance is given to you as a weak reference, it won't be able to /// be `upgrade`d if all local players leave it. -#[derive(Message, Debug, Clone)] +#[derive(Clone, Debug, Message)] pub struct InstanceLoadedEvent { pub entity: Entity, pub name: Identifier, @@ -156,7 +156,7 @@ pub struct InstanceLoadedEvent { /// /// [`ClientboundPing`]: azalea_protocol::packets::game::ClientboundPing /// [`ConfigPingEvent`]: crate::packet::config::ConfigPingEvent -#[derive(EntityEvent, Debug, Clone)] +#[derive(Clone, Debug, EntityEvent)] pub struct GamePingEvent { pub entity: Entity, pub packet: azalea_protocol::packets::game::ClientboundPing, diff --git a/azalea-client/src/plugins/packet/login/events.rs b/azalea-client/src/plugins/packet/login/events.rs index f50c1423..52e696cb 100644 --- a/azalea-client/src/plugins/packet/login/events.rs +++ b/azalea-client/src/plugins/packet/login/events.rs @@ -12,7 +12,7 @@ use tracing::{debug, error}; use super::InLoginState; use crate::{Account, connection::RawConnection}; -#[derive(Message, Debug, Clone)] +#[derive(Clone, Debug, Message)] pub struct ReceiveLoginPacketEvent { /// The client entity that received the packet. pub entity: Entity, @@ -20,14 +20,14 @@ pub struct ReceiveLoginPacketEvent { pub packet: Arc<ClientboundLoginPacket>, } -#[derive(EntityEvent, Debug, Clone)] +#[derive(Clone, Debug, EntityEvent)] pub struct ReceiveHelloEvent { pub entity: Entity, pub account: Account, pub packet: ClientboundHello, } -#[derive(Message, Debug, Clone)] +#[derive(Clone, Debug, Message)] pub struct ReceiveCustomQueryEvent { /// The client entity that received the packet. pub entity: Entity, @@ -41,7 +41,7 @@ pub struct ReceiveCustomQueryEvent { } /// Event for sending a login packet to the server. -#[derive(EntityEvent, Debug, Clone)] +#[derive(Clone, Debug, EntityEvent)] pub struct SendLoginPacketEvent { #[event_target] pub sent_by: Entity, diff --git a/azalea-client/src/plugins/packet/login/mod.rs b/azalea-client/src/plugins/packet/login/mod.rs index 63226124..8fe1e22a 100644 --- a/azalea-client/src/plugins/packet/login/mod.rs +++ b/azalea-client/src/plugins/packet/login/mod.rs @@ -41,7 +41,7 @@ pub fn process_packet(ecs: &mut World, player: Entity, packet: &ClientboundLogin /// A marker component for local players that are currently in the /// `login` state. -#[derive(Component, Clone, Debug)] +#[derive(Clone, Component, Debug)] pub struct InLoginState; pub struct LoginPacketHandler<'a> { diff --git a/azalea-client/src/plugins/respawn.rs b/azalea-client/src/plugins/respawn.rs index 7c16b0e2..60d3594d 100644 --- a/azalea-client/src/plugins/respawn.rs +++ b/azalea-client/src/plugins/respawn.rs @@ -5,7 +5,7 @@ use bevy_ecs::prelude::*; use crate::packet::game::SendGamePacketEvent; /// Tell the server that we're respawning. -#[derive(Message, Debug, Clone)] +#[derive(Clone, Debug, Message)] pub struct PerformRespawnEvent { pub entity: Entity, } diff --git a/azalea-client/src/plugins/tick_broadcast.rs b/azalea-client/src/plugins/tick_broadcast.rs index b55b9921..e51716cc 100644 --- a/azalea-client/src/plugins/tick_broadcast.rs +++ b/azalea-client/src/plugins/tick_broadcast.rs @@ -22,13 +22,13 @@ use tokio::sync::broadcast; /// } /// # } /// ``` -#[derive(Resource, Deref)] +#[derive(Deref, Resource)] pub struct TickBroadcast(broadcast::Sender<()>); /// A resource that contains a [`broadcast::Sender`] that will be sent every /// Azalea ECS Update. /// /// Also see [`TickBroadcast`]. -#[derive(Resource, Deref)] +#[derive(Deref, Resource)] pub struct UpdateBroadcast(broadcast::Sender<()>); pub fn send_tick_broadcast(tick_broadcast: ResMut<TickBroadcast>) { diff --git a/azalea-client/src/plugins/tick_counter.rs b/azalea-client/src/plugins/tick_counter.rs index 43100bba..2f4086a0 100644 --- a/azalea-client/src/plugins/tick_counter.rs +++ b/azalea-client/src/plugins/tick_counter.rs @@ -8,7 +8,7 @@ use crate::{mining::MiningSystems, movement::send_position, tick_broadcast::send /// Counts the number of game ticks elapsed on the **local client** since the /// `login` packet was received. -#[derive(Component, Clone, Debug, Default, Eq, PartialEq)] +#[derive(Clone, Component, Debug, Default, Eq, PartialEq)] pub struct TicksConnected(pub u64); /// Inserts the counter-increment system into the `GameTick` schedule **before** diff --git a/azalea-core/src/aabb.rs b/azalea-core/src/aabb.rs index 4e129ef7..052e6efb 100644 --- a/azalea-core/src/aabb.rs +++ b/azalea-core/src/aabb.rs @@ -8,7 +8,7 @@ use crate::{ /// An axis-aligned bounding box. /// /// In other words, a rectangular prism with a starting and ending point. -#[derive(Copy, Clone, Debug, PartialEq, Default)] +#[derive(Clone, Copy, Debug, Default, PartialEq)] pub struct Aabb { pub min: Vec3, pub max: Vec3, diff --git a/azalea-core/src/attribute_modifier_operation.rs b/azalea-core/src/attribute_modifier_operation.rs index ff92a44a..8418ff22 100644 --- a/azalea-core/src/attribute_modifier_operation.rs +++ b/azalea-core/src/attribute_modifier_operation.rs @@ -4,7 +4,7 @@ use azalea_buf::AzBuf; use serde::Serialize; use simdnbt::{FromNbtTag, borrow::NbtTag}; -#[derive(Clone, Copy, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq, Serialize)] #[serde(rename_all = "snake_case")] pub enum AttributeModifierOperation { AddValue, diff --git a/azalea-core/src/bitset.rs b/azalea-core/src/bitset.rs index 567ad020..6abb5d1d 100644 --- a/azalea-core/src/bitset.rs +++ b/azalea-core/src/bitset.rs @@ -6,7 +6,7 @@ use std::{ use azalea_buf::{AzBuf, AzaleaRead, AzaleaWrite, BufReadError}; /// Represents Java's BitSet, a list of bits. -#[derive(Debug, Clone, PartialEq, Eq, Hash, Default, AzBuf)] +#[derive(AzBuf, Clone, Debug, Default, Eq, Hash, PartialEq)] pub struct BitSet { data: Vec<u64>, } @@ -178,7 +178,7 @@ impl From<Vec<u8>> for BitSet { /// Minecraft, and may not be as performant as it could be for other purposes. /// Consider using [`FastFixedBitSet`] if you don't need the /// `AzaleaRead`/`AzaleaWrite` implementation. -#[derive(Debug, Clone, PartialEq, Eq, Hash)] +#[derive(Clone, Debug, Eq, Hash, PartialEq)] pub struct FixedBitSet<const N: usize> where [u8; bits_to_bytes(N)]: Sized, @@ -254,7 +254,7 @@ pub const fn bits_to_bytes(n: usize) -> usize { /// /// This is almost identical to [`FixedBitSet`], but more efficient (~20% faster /// access) and doesn't implement `AzaleaRead`/`AzaleaWrite`. -#[derive(Debug, Clone, PartialEq, Eq, Hash)] +#[derive(Clone, Debug, Eq, Hash, PartialEq)] pub struct FastFixedBitSet<const N: usize> where [u64; bits_to_longs(N)]: Sized, diff --git a/azalea-core/src/checksum.rs b/azalea-core/src/checksum.rs index 490d5ea4..1d0d4860 100644 --- a/azalea-core/src/checksum.rs +++ b/azalea-core/src/checksum.rs @@ -9,7 +9,7 @@ use tracing::error; use crate::registry_holder::RegistryHolder; -#[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Default, AzBuf)] +#[derive(AzBuf, Clone, Copy, Debug, Default, Eq, Ord, PartialEq, PartialOrd)] pub struct Checksum(pub u32); pub struct ChecksumSerializer<'a, 'r> { @@ -335,7 +335,7 @@ impl<'a, 'r> ser::SerializeSeq for ChecksumListSerializer<'a, 'r> { /// keep track of that when serializing the arrays. /// /// Byte arrays aren't included here as they're handled with `serialize_bytes`. -#[derive(Default, PartialEq, Eq)] +#[derive(Default, Eq, PartialEq)] enum ListKind { #[default] Normal, @@ -617,7 +617,7 @@ impl<'a> ser::Serializer for IntOrLongArrayChecksumSerializer<'a> { } } -#[derive(Error, Debug)] +#[derive(Debug, Error)] #[error("Checksum serialization error")] pub struct ChecksumError; impl ser::Error for ChecksumError { diff --git a/azalea-core/src/color.rs b/azalea-core/src/color.rs index ff727ccd..7780deae 100644 --- a/azalea-core/src/color.rs +++ b/azalea-core/src/color.rs @@ -1,6 +1,6 @@ use azalea_buf::AzBuf; -#[derive(Debug, Clone, Copy, PartialEq, Eq, Default, AzBuf)] +#[derive(AzBuf, Clone, Copy, Debug, Default, Eq, PartialEq)] pub struct RgbColor { value: u32, } @@ -25,7 +25,7 @@ impl RgbColor { } } -#[derive(Debug, Clone, Copy, PartialEq, Eq, Default, AzBuf)] +#[derive(AzBuf, Clone, Copy, Debug, Default, Eq, PartialEq)] pub struct ArgbColor { value: u32, } diff --git a/azalea-core/src/cursor3d.rs b/azalea-core/src/cursor3d.rs index 91a14000..ba893bb5 100644 --- a/azalea-core/src/cursor3d.rs +++ b/azalea-core/src/cursor3d.rs @@ -54,7 +54,7 @@ impl Iterator for Cursor3d { } #[repr(u8)] -#[derive(Eq, PartialEq, Debug)] +#[derive(Debug, Eq, PartialEq)] pub enum CursorIterationType { Inside = 0, Face = 1, diff --git a/azalea-core/src/delta.rs b/azalea-core/src/delta.rs index c193649a..055ba3b8 100644 --- a/azalea-core/src/delta.rs +++ b/azalea-core/src/delta.rs @@ -12,7 +12,7 @@ pub trait PositionDeltaTrait { } /// Only works for up to 8 blocks -#[derive(Clone, Debug, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq)] pub struct PositionDelta8 { pub xa: i16, pub ya: i16, @@ -74,7 +74,7 @@ impl Vec3 { /// /// Can be freely converted to and from a [`Vec3`], but some precision will be /// lost. -#[derive(Clone, Copy, Debug, PartialEq, Eq, Default)] +#[derive(Clone, Copy, Debug, Default, Eq, PartialEq)] pub enum LpVec3 { #[default] Zero, diff --git a/azalea-core/src/difficulty.rs b/azalea-core/src/difficulty.rs index 427be9aa..7a018a8e 100644 --- a/azalea-core/src/difficulty.rs +++ b/azalea-core/src/difficulty.rs @@ -5,7 +5,7 @@ use std::{ use azalea_buf::{AzaleaRead, AzaleaWrite, BufReadError}; -#[derive(Hash, Clone, Copy, Debug, PartialEq, Eq)] +#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)] pub enum Difficulty { Peaceful = 0, Easy = 1, diff --git a/azalea-core/src/direction.rs b/azalea-core/src/direction.rs index fbd7f98b..b53df448 100644 --- a/azalea-core/src/direction.rs +++ b/azalea-core/src/direction.rs @@ -91,7 +91,7 @@ impl Direction { /// /// Note that azalea_block has a similar enum named `FacingCardinal` that is /// used for block states. -#[derive(Clone, Copy, Debug, AzBuf, PartialEq, Eq, Hash, serde::Deserialize, serde::Serialize)] +#[derive(AzBuf, Clone, Copy, Debug, serde::Deserialize, Eq, Hash, PartialEq, serde::Serialize)] pub enum CardinalDirection { North, South, diff --git a/azalea-core/src/game_type.rs b/azalea-core/src/game_type.rs index db1d6bc5..95d330d2 100644 --- a/azalea-core/src/game_type.rs +++ b/azalea-core/src/game_type.rs @@ -5,7 +5,7 @@ use azalea_chat::translatable_component::TranslatableComponent; use tracing::debug; /// A Minecraft gamemode, like survival or creative. -#[derive(Hash, Copy, Clone, Debug, Default, Eq, PartialEq)] +#[derive(Clone, Copy, Debug, Default, Eq, Hash, PartialEq)] pub enum GameMode { #[default] Survival, @@ -115,7 +115,7 @@ impl AzaleaWrite for GameMode { /// Rust doesn't let us `impl AzaleaRead for Option<GameType>` so we have to /// make a new type :( -#[derive(Hash, Copy, Clone, Debug, PartialEq)] +#[derive(Clone, Copy, Debug, Hash, PartialEq)] pub struct OptionalGameType(pub Option<GameMode>); impl From<Option<GameMode>> for OptionalGameType { diff --git a/azalea-core/src/hit_result.rs b/azalea-core/src/hit_result.rs index 2f3d2403..2b269aba 100644 --- a/azalea-core/src/hit_result.rs +++ b/azalea-core/src/hit_result.rs @@ -7,7 +7,7 @@ use crate::{ /// /// If there's nothing, it'll be a [`BlockHitResult`] with `miss` set to true. #[cfg(feature = "bevy_ecs")] -#[derive(Debug, Clone, PartialEq)] +#[derive(Clone, Debug, PartialEq)] pub enum HitResult { Block(BlockHitResult), Entity(EntityHitResult), @@ -65,7 +65,7 @@ impl HitResult { } } -#[derive(Debug, Clone, PartialEq)] +#[derive(Clone, Debug, PartialEq)] pub struct BlockHitResult { pub location: Vec3, pub miss: bool, @@ -103,7 +103,7 @@ impl From<BlockHitResult> for HitResult { } #[cfg(feature = "bevy_ecs")] -#[derive(Debug, Clone, PartialEq)] +#[derive(Clone, Debug, PartialEq)] pub struct EntityHitResult { pub location: Vec3, pub entity: bevy_ecs::entity::Entity, diff --git a/azalea-core/src/objectives.rs b/azalea-core/src/objectives.rs index 0975a3fd..a7fdc820 100644 --- a/azalea-core/src/objectives.rs +++ b/azalea-core/src/objectives.rs @@ -5,7 +5,7 @@ use std::{ use azalea_buf::AzBuf; -#[derive(Clone, Copy, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq)] pub enum ObjectiveCriteria { Integer, Hearts, diff --git a/azalea-core/src/position.rs b/azalea-core/src/position.rs index 1deb1892..502d5c20 100644 --- a/azalea-core/src/position.rs +++ b/azalea-core/src/position.rs @@ -305,7 +305,7 @@ macro_rules! vec3_impl { /// Used to represent an exact position in the world where an entity could be. /// /// For blocks, [`BlockPos`] is used instead. -#[derive(Clone, Copy, Debug, Default, PartialEq, AzBuf, serde::Deserialize, serde::Serialize)] +#[derive(AzBuf, Clone, Copy, Debug, Default, serde::Deserialize, PartialEq, serde::Serialize)] pub struct Vec3 { pub x: f64, pub y: f64, @@ -373,7 +373,7 @@ impl Vec3 { } /// A lower precision [`Vec3`], used for some fields in entity metadata. -#[derive(Clone, Copy, Debug, Default, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Copy, Debug, Default, PartialEq)] pub struct Vec3f32 { pub x: f32, pub y: f32, @@ -401,7 +401,7 @@ impl From<Vec3> for Vec3f32 { /// The coordinates of a block in the world. /// /// For entities (if the coordinates are floating-point), use [`Vec3`] instead. -#[derive(Clone, Copy, Debug, Default, PartialEq, Eq, Hash)] +#[derive(Clone, Copy, Debug, Default, Eq, Hash, PartialEq)] pub struct BlockPos { pub x: i32, pub y: i32, @@ -487,7 +487,7 @@ impl<'de> serde::Deserialize<'de> for BlockPos { /// /// This is similar to [`BlockPos`], but isn't limited to representing block /// positions and can represent a larger range of numbers. -#[derive(Clone, Copy, Debug, Default, PartialEq, Eq, Hash, AzBuf)] +#[derive(AzBuf, Clone, Copy, Debug, Default, Eq, Hash, PartialEq)] pub struct Vec3i { #[var] pub x: i32, @@ -508,7 +508,7 @@ impl simdnbt::FromNbtTag for Vec3i { /// Chunk coordinates are used to represent where a chunk is in the world. /// /// You can convert the x and z to block coordinates by multiplying them by 16. -#[derive(Clone, Copy, Debug, Default, PartialEq, Eq)] +#[derive(Clone, Copy, Debug, Default, Eq, PartialEq)] pub struct ChunkPos { pub x: i32, pub z: i32, @@ -583,7 +583,7 @@ impl Hash for ChunkPos { impl nohash_hasher::IsEnabled for ChunkPos {} /// The coordinates of a chunk section in the world. -#[derive(Clone, Copy, Debug, Default, PartialEq, Eq, PartialOrd, Ord)] +#[derive(Clone, Copy, Debug, Default, Eq, Ord, PartialEq, PartialOrd)] pub struct ChunkSectionPos { pub x: i32, pub y: i32, @@ -598,7 +598,7 @@ impl ChunkSectionPos { } /// The coordinates of a block inside a chunk. -#[derive(Clone, Copy, Debug, Default, PartialEq, Eq)] +#[derive(Clone, Copy, Debug, Default, Eq, PartialEq)] pub struct ChunkBlockPos { pub x: u8, pub y: i32, @@ -637,7 +637,7 @@ impl nohash_hasher::IsEnabled for ChunkBlockPos {} /// The coordinates of a block inside of a chunk section. /// /// Each coordinate should be in the range 0..=15. -#[derive(Clone, Copy, Debug, Default, PartialEq, Eq)] +#[derive(Clone, Copy, Debug, Default, Eq, PartialEq)] pub struct ChunkSectionBlockPos { pub x: u8, pub y: u8, @@ -648,7 +648,7 @@ vec3_impl!(ChunkSectionBlockPos, u8); /// The coordinates of a biome inside of a chunk section. /// /// Each coordinate should be in the range 0..=3. -#[derive(Clone, Copy, Debug, Default, PartialEq, Eq)] +#[derive(Clone, Copy, Debug, Default, Eq, PartialEq)] pub struct ChunkSectionBiomePos { pub x: u8, pub y: u8, @@ -675,7 +675,7 @@ vec3_impl!(ChunkSectionBiomePos, u8); /// The coordinates of a biome inside a chunk. /// /// Biomes are 4x4 blocks. -#[derive(Clone, Copy, Debug, Default, PartialEq, Eq)] +#[derive(Clone, Copy, Debug, Default, Eq, PartialEq)] pub struct ChunkBiomePos { pub x: u8, pub y: i32, @@ -733,7 +733,7 @@ impl From<ChunkSectionBlockPos> for u16 { impl nohash_hasher::IsEnabled for ChunkSectionBlockPos {} /// A block pos with an attached world -#[derive(Debug, Clone, PartialEq, Serialize)] +#[derive(Clone, Debug, PartialEq, Serialize)] pub struct GlobalPos { // this is actually a ResourceKey in Minecraft, but i don't think it matters? pub dimension: Identifier, @@ -891,7 +891,7 @@ impl fmt::Display for Vec3 { } /// A 2D vector. -#[derive(Clone, Copy, Debug, Default, PartialEq, AzBuf, simdnbt::Deserialize, Serialize)] +#[derive(AzBuf, Clone, Copy, Debug, Default, simdnbt::Deserialize, PartialEq, Serialize)] pub struct Vec2 { pub x: f32, pub y: f32, diff --git a/azalea-core/src/registry_holder/block_predicate.rs b/azalea-core/src/registry_holder/block_predicate.rs index faa05d10..a9f7d961 100644 --- a/azalea-core/src/registry_holder/block_predicate.rs +++ b/azalea-core/src/registry_holder/block_predicate.rs @@ -1,3 +1,3 @@ /// TODO: unimplemented -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct BlockPredicate {} diff --git a/azalea-core/src/registry_holder/block_state_provider.rs b/azalea-core/src/registry_holder/block_state_provider.rs index f9ad603d..104e022b 100644 --- a/azalea-core/src/registry_holder/block_state_provider.rs +++ b/azalea-core/src/registry_holder/block_state_provider.rs @@ -1,3 +1,3 @@ /// TODO: unimplemented -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct BlockStateProvider {} diff --git a/azalea-core/src/registry_holder/components.rs b/azalea-core/src/registry_holder/components.rs index cbd6384d..6a216ada 100644 --- a/azalea-core/src/registry_holder/components.rs +++ b/azalea-core/src/registry_holder/components.rs @@ -125,7 +125,7 @@ impl<T: EffectComponentTrait> ResolvedEffectComponent for T {} /// just use `from_nbt_tag`, because `borrow::NbtTag` can't be constructed on /// its own. To work around this, we have this `EffectNbtTag` struct that we /// *can* construct that we use when deserializing. -#[derive(Debug, Clone, Copy)] +#[derive(Clone, Copy, Debug)] pub enum EffectNbtTag<'a, 'tape> { Compound(NbtCompound<'a, 'tape>), List(NbtList<'a, 'tape>), @@ -167,12 +167,12 @@ macro_rules! impl_from_effect_nbt_tag { } pub(crate) use impl_from_effect_nbt_tag; -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub struct ConditionalEffect<T: simdnbt::Deserialize + Debug + Clone> { pub effect: T, // pub requirements } -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub struct TargetedConditionalEffect<T: simdnbt::Deserialize + Debug + Clone> { pub effect: T, // pub enchanted diff --git a/azalea-core/src/registry_holder/dimension_type.rs b/azalea-core/src/registry_holder/dimension_type.rs index 86dd2b3e..ce0b5367 100644 --- a/azalea-core/src/registry_holder/dimension_type.rs +++ b/azalea-core/src/registry_holder/dimension_type.rs @@ -9,7 +9,7 @@ use simdnbt::{ use crate::codec_utils::*; -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] #[cfg_attr(feature = "strict_registry", simdnbt(deny_unknown_fields))] pub struct TrimMaterialElement { pub asset_name: String, @@ -20,7 +20,7 @@ pub struct TrimMaterialElement { } /// Data about a kind of chat message -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] #[cfg_attr(feature = "strict_registry", simdnbt(deny_unknown_fields))] pub struct ChatTypeElement { pub chat: ChatTypeData, @@ -28,7 +28,7 @@ pub struct ChatTypeElement { } /// Data about a chat message. -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] #[cfg_attr(feature = "strict_registry", simdnbt(deny_unknown_fields))] pub struct ChatTypeData { pub translation_key: String, @@ -37,7 +37,7 @@ pub struct ChatTypeData { } /// The style of a chat message. -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] #[cfg_attr(feature = "strict_registry", simdnbt(deny_unknown_fields))] pub struct ChatTypeStyle { pub color: Option<String>, @@ -50,7 +50,7 @@ pub struct ChatTypeStyle { /// Dimension attributes. #[cfg(feature = "strict_registry")] -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] #[simdnbt(deny_unknown_fields)] pub struct DimensionKindElement { pub ambient_light: f32, @@ -75,7 +75,7 @@ pub struct DimensionKindElement { /// Dimension attributes. #[cfg(not(feature = "strict_registry"))] -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] pub struct DimensionKindElement { pub height: u32, pub min_y: i32, @@ -88,7 +88,7 @@ pub struct DimensionKindElement { /// /// This can be either a single minimum value, or a formula with a min and /// max. -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] // #[serde(untagged)] pub enum MonsterSpawnLightLevel { /// A simple minimum value. @@ -132,7 +132,7 @@ impl ToNbtTag for MonsterSpawnLightLevel { /// The min and max light levels at which monsters can spawn. /// /// Values are inclusive. -#[derive(Debug, Copy, Clone, Serialize, Deserialize)] +#[derive(Clone, Copy, Debug, Deserialize, Serialize)] #[cfg_attr(feature = "strict_registry", simdnbt(deny_unknown_fields))] pub struct MonsterSpawnLightLevelValues { #[simdnbt(rename = "min_inclusive")] @@ -142,7 +142,7 @@ pub struct MonsterSpawnLightLevelValues { } /// Biome attributes. -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] #[cfg_attr(feature = "strict_registry", simdnbt(deny_unknown_fields))] pub struct WorldTypeElement { pub has_precipitation: bool, @@ -153,7 +153,7 @@ pub struct WorldTypeElement { } /// The precipitation of a biome. -#[derive(Debug, PartialEq, Eq, Copy, Clone)] +#[derive(Clone, Copy, Debug, Eq, PartialEq)] pub enum BiomePrecipitation { None, Rain, @@ -183,7 +183,7 @@ impl ToNbtTag for BiomePrecipitation { /// /// This includes the sky, fog, water, and grass color, /// as well as music and other sound effects. -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] #[cfg_attr(feature = "strict_registry", simdnbt(deny_unknown_fields))] pub struct BiomeEffects { pub sky_color: u32, @@ -203,7 +203,7 @@ pub struct BiomeEffects { /// The music of the biome. /// /// Some biomes have unique music that only play when inside them. -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] #[cfg_attr(feature = "strict_registry", simdnbt(deny_unknown_fields))] pub struct BiomeMusic { pub replace_current_music: bool, @@ -212,7 +212,7 @@ pub struct BiomeMusic { pub sound: SoundEvent, } -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] #[cfg_attr(feature = "strict_registry", simdnbt(deny_unknown_fields))] pub struct BiomeMoodSound { pub tick_delay: u32, @@ -221,7 +221,7 @@ pub struct BiomeMoodSound { pub sound: SoundEvent, } -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] #[cfg_attr(feature = "strict_registry", simdnbt(deny_unknown_fields))] pub struct AdditionsSound { pub tick_chance: f32, @@ -231,14 +231,14 @@ pub struct AdditionsSound { /// Biome particles. /// /// Some biomes have particles that spawn in the air. -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] #[cfg_attr(feature = "strict_registry", simdnbt(deny_unknown_fields))] pub struct BiomeParticle { pub probability: f32, pub options: HashMap<String, String>, } -#[derive(Debug, Clone, Serialize, Deserialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] #[cfg_attr(feature = "strict_registry", simdnbt(deny_unknown_fields))] pub struct TrimPatternElement { #[simdnbt(flatten)] diff --git a/azalea-core/src/registry_holder/entity_effect.rs b/azalea-core/src/registry_holder/entity_effect.rs index ef08b7f0..4cb914e3 100644 --- a/azalea-core/src/registry_holder/entity_effect.rs +++ b/azalea-core/src/registry_holder/entity_effect.rs @@ -22,7 +22,7 @@ use crate::{ sound::CustomSound, }; -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub enum EntityEffect { AllOf(AllOf), ApplyMobEffect(ApplyMobEffect), @@ -82,12 +82,12 @@ impl Deserialize for EntityEffect { } } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct AllOf { pub effects: Vec<EntityEffect>, } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct ApplyMobEffect { /// IDs of mob effects. pub to_apply: HomogeneousList, @@ -99,7 +99,7 @@ pub struct ApplyMobEffect { // TODO: in vanilla this is just a HolderSetCodec using a RegistryFixedCodec, // azalea registries should probably be refactored first tho -#[derive(Debug, Clone, Default)] +#[derive(Clone, Debug, Default)] pub struct HomogeneousList { pub ids: Vec<Identifier>, } @@ -124,12 +124,12 @@ impl simdnbt::FromNbtTag for HomogeneousList { } } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct ChangeItemDamage { pub amount: LevelBasedValue, } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct DamageEntity { pub min_damage: LevelBasedValue, pub max_damage: LevelBasedValue, @@ -137,7 +137,7 @@ pub struct DamageEntity { pub damage_kind: DamageKindKey, } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct Explode { pub attribute_to_user: Option<bool>, #[simdnbt(rename = "damage_type")] @@ -147,24 +147,24 @@ pub struct Explode { pub offset: Option<Vec3>, } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct Ignite { pub duration: LevelBasedValue, } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct ApplyEntityImpulse { pub direction: Vec3, pub coordinate_scale: Vec3, pub magnitude: LevelBasedValue, } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct ApplyExhaustion { pub amount: LevelBasedValue, } -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub struct PlaySound { // #[simdnbt(compact)] pub sound: Vec<Holder<SoundEvent, CustomSound>>, @@ -204,7 +204,7 @@ impl Deserialize for PlaySound { } } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct ReplaceBlock { pub offset: Option<Vec3i>, pub predicate: Option<BlockPredicate>, @@ -212,7 +212,7 @@ pub struct ReplaceBlock { pub trigger_game_event: Option<GameEvent>, } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct ReplaceDisk { pub radius: LevelBasedValue, pub height: LevelBasedValue, @@ -222,19 +222,19 @@ pub struct ReplaceDisk { pub trigger_game_event: Option<GameEvent>, } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct RunFunction { pub function: Identifier, } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct SetBlockProperties { pub properties: HashMap<String, String>, pub offset: Option<Vec3i>, pub trigger_game_event: Option<GameEvent>, } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct SpawnParticles { pub particle: ParticleKindCodec, pub horizontal_position: SpawnParticlesPosition, @@ -244,13 +244,13 @@ pub struct SpawnParticles { pub speed: Option<FloatProvider>, } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct ParticleKindCodec { #[simdnbt(rename = "type")] pub kind: ParticleKind, } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct SpawnParticlesPosition { #[simdnbt(rename = "type")] pub kind: Identifier, @@ -258,13 +258,13 @@ pub struct SpawnParticlesPosition { pub scale: Option<f32>, } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct SpawnParticlesVelocity { pub movement_scale: Option<f32>, pub base: Option<FloatProvider>, } -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct SummonEntity { pub entity: HomogeneousList, pub join_team: Option<bool>, diff --git a/azalea-core/src/registry_holder/mod.rs b/azalea-core/src/registry_holder/mod.rs index 886c75e1..90bad921 100644 --- a/azalea-core/src/registry_holder/mod.rs +++ b/azalea-core/src/registry_holder/mod.rs @@ -30,7 +30,7 @@ use tracing::error; /// per-client like you might expect. This is an optimization for swarms to /// reduce memory usage, since registries are expected to be the same for every /// client in a world. -#[derive(Default, Debug, Clone)] +#[derive(Clone, Debug, Default)] pub struct RegistryHolder { // if you add new fields here, don't forget to also update `RegistryHolder::append`, // `protocol_id_to_identifier`, and `define_default_deserializes_to!` in @@ -124,7 +124,7 @@ fn nbt_to_serializable_type<T: simdnbt::Deserialize>( T::from_compound((&nbt_borrow_compound).into()).map_err(Into::into) } -#[derive(Error, Debug)] +#[derive(Debug, Error)] enum NbtToSerializableTypeError { #[error(transparent)] NbtError(#[from] simdnbt::Error), @@ -133,7 +133,7 @@ enum NbtToSerializableTypeError { } /// A collection of values for a certain type of registry data. -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub struct RegistryType<T: simdnbt::Deserialize> { pub map: IndexMap<Identifier, T>, } diff --git a/azalea-core/src/registry_holder/value.rs b/azalea-core/src/registry_holder/value.rs index 964d1e5a..1eedc0c0 100644 --- a/azalea-core/src/registry_holder/value.rs +++ b/azalea-core/src/registry_holder/value.rs @@ -15,7 +15,7 @@ use crate::{ registry_holder::{components::impl_from_effect_nbt_tag, get_in_compound}, }; -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub enum ValueEffect { Set { value: LevelBasedValue, @@ -73,7 +73,7 @@ impl simdnbt::Deserialize for ValueEffect { } impl_from_effect_nbt_tag!(ValueEffect); -#[derive(Debug, Clone, simdnbt::Deserialize)] +#[derive(Clone, Debug, simdnbt::Deserialize)] pub struct AttributeEffect { pub id: Identifier, pub attribute: Attribute, @@ -82,7 +82,7 @@ pub struct AttributeEffect { } impl_from_effect_nbt_tag!(AttributeEffect); -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub enum LevelBasedValue { Constant(f32), Exponent { diff --git a/azalea-core/src/sound.rs b/azalea-core/src/sound.rs index 9ac568b6..418707b9 100644 --- a/azalea-core/src/sound.rs +++ b/azalea-core/src/sound.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_registry::identifier::Identifier; use serde::Serialize; -#[derive(Clone, Debug, PartialEq, AzBuf, Serialize, simdnbt::Deserialize)] +#[derive(AzBuf, Clone, Debug, simdnbt::Deserialize, PartialEq, Serialize)] pub struct CustomSound { pub sound_id: Identifier, pub range: Option<f32>, diff --git a/azalea-core/src/tick.rs b/azalea-core/src/tick.rs index 09b45be4..435d9fb3 100644 --- a/azalea-core/src/tick.rs +++ b/azalea-core/src/tick.rs @@ -6,5 +6,5 @@ use bevy_ecs::schedule::ScheduleLabel; /// physics. /// /// This schedule runs either zero or one times after every Bevy `Update`. -#[derive(ScheduleLabel, Hash, Copy, Clone, Debug, Default, Eq, PartialEq)] +#[derive(Clone, Copy, Debug, Default, Eq, Hash, PartialEq, ScheduleLabel)] pub struct GameTick; diff --git a/azalea-crypto/src/signing.rs b/azalea-crypto/src/signing.rs index 8d21a2f2..57d5e1ad 100644 --- a/azalea-crypto/src/signing.rs +++ b/azalea-crypto/src/signing.rs @@ -8,18 +8,18 @@ use rsa::{ use sha2::Sha256; use uuid::Uuid; -#[derive(Debug, Clone, AzBuf)] +#[derive(AzBuf, Clone, Debug)] pub struct SaltSignaturePair { pub salt: u64, pub signature: Vec<u8>, } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct MessageSignature { pub bytes: [u8; 256], } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct SignedMessageHeader { pub previous_signature: Option<MessageSignature>, pub sender: Uuid, diff --git a/azalea-entity/src/attributes.rs b/azalea-entity/src/attributes.rs index 95b13c98..6060af9f 100644 --- a/azalea-entity/src/attributes.rs +++ b/azalea-entity/src/attributes.rs @@ -12,7 +12,7 @@ use thiserror::Error; /// /// Each attribute can have multiple modifiers, and these modifiers are the /// result of things like sprinting or enchantments. -#[derive(Clone, Debug, Component)] +#[derive(Clone, Component, Debug)] pub struct Attributes { pub movement_speed: AttributeInstance, pub sneaking_speed: AttributeInstance, diff --git a/azalea-entity/src/data.rs b/azalea-entity/src/data.rs index bb73cbed..a7f7357b 100644 --- a/azalea-entity/src/data.rs +++ b/azalea-entity/src/data.rs @@ -59,7 +59,7 @@ impl AzaleaWrite for EntityMetadataItems { // Note: This enum is partially generated and parsed by // codegen/lib/code/entity.py -#[derive(Clone, Debug, EnumAsInner, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, EnumAsInner, PartialEq)] pub enum EntityDataValue { Byte(u8), Int(#[var] i32), @@ -107,7 +107,7 @@ pub enum EntityDataValue { #[derive(Clone, Debug, PartialEq)] pub struct OptionalUnsignedInt(pub Option<u32>); -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct Quaternion { pub x: f32, pub y: f32, @@ -117,7 +117,7 @@ pub struct Quaternion { // mojang just calls this ArmadilloState but i added "Kind" since otherwise it // collides with a name in metadata.rs -#[derive(Clone, Debug, Copy, Default, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, Default, PartialEq)] pub enum ArmadilloStateKind { #[default] Idle, @@ -145,14 +145,14 @@ impl AzaleaWrite for OptionalUnsignedInt { } /// A set of x, y, and z rotations. This is used for armor stands. -#[derive(Clone, Debug, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq)] pub struct Rotations { pub x: f32, pub y: f32, pub z: f32, } -#[derive(Clone, Debug, Copy, AzBuf, Default, Component, Eq, PartialEq)] +#[derive(AzBuf, Clone, Component, Copy, Debug, Default, Eq, PartialEq)] pub enum Pose { #[default] Standing = 0, @@ -175,7 +175,7 @@ pub enum Pose { Inhaling, } -#[derive(Debug, Clone, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct VillagerData { pub kind: VillagerKind, pub profession: VillagerProfession, @@ -183,7 +183,7 @@ pub struct VillagerData { pub level: u32, } -#[derive(Debug, Copy, Clone, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, Default, PartialEq)] pub enum SnifferStateKind { #[default] Idling, @@ -195,7 +195,7 @@ pub enum SnifferStateKind { Rising, } -#[derive(Debug, Copy, Clone, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, Default, PartialEq)] pub enum CopperGolemStateKind { #[default] Idle, @@ -204,7 +204,7 @@ pub enum CopperGolemStateKind { DroppingItem, DroppingNoItem, } -#[derive(Debug, Copy, Clone, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, Default, PartialEq)] pub enum WeatheringCopperStateKind { #[default] Unaffected, @@ -213,7 +213,7 @@ pub enum WeatheringCopperStateKind { Oxidized, } -#[derive(AzBuf, Clone, Copy, Debug, PartialEq, Eq, Default)] +#[derive(AzBuf, Clone, Copy, Debug, Default, Eq, PartialEq)] pub enum HumanoidArm { Left = 0, #[default] diff --git a/azalea-entity/src/dimensions.rs b/azalea-entity/src/dimensions.rs index 5660e032..87eced8a 100644 --- a/azalea-entity/src/dimensions.rs +++ b/azalea-entity/src/dimensions.rs @@ -5,7 +5,7 @@ use bevy_ecs::component::Component; use crate::Pose; /// A component that contains the size of an entity and their eye height. -#[derive(Component, Debug, Default, Clone)] +#[derive(Clone, Component, Debug, Default)] pub struct EntityDimensions { pub width: f32, pub height: f32, diff --git a/azalea-entity/src/effects.rs b/azalea-entity/src/effects.rs index aa930a78..ae7ae8a1 100644 --- a/azalea-entity/src/effects.rs +++ b/azalea-entity/src/effects.rs @@ -9,7 +9,7 @@ use azalea_registry::builtin::MobEffect; use bevy_ecs::component::Component; /// Data about an active mob effect. -#[derive(Clone, Debug, Default, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq)] pub struct MobEffectData { /// The effect's amplifier level, starting at 0 if present. #[var] @@ -64,7 +64,7 @@ impl AzaleaWrite for MobEffectFlags { } /// An ECS component that stores the active mob effects on an entity. -#[derive(Component, Clone, Debug, Default)] +#[derive(Clone, Component, Debug, Default)] pub struct ActiveEffects(pub HashMap<MobEffect, MobEffectData>); impl ActiveEffects { pub fn insert(&mut self, effect: MobEffect, data: MobEffectData) { diff --git a/azalea-entity/src/inventory.rs b/azalea-entity/src/inventory.rs index d6fabb1e..aa13865e 100644 --- a/azalea-entity/src/inventory.rs +++ b/azalea-entity/src/inventory.rs @@ -15,7 +15,7 @@ use bevy_ecs::prelude::*; use crate::PlayerAbilities; /// A component present on all local players that have an inventory. -#[derive(Component, Debug, Clone)] +#[derive(Clone, Component, Debug)] pub struct Inventory { /// The player's inventory menu. This is guaranteed to be a `Menu::Player`. /// diff --git a/azalea-entity/src/lib.rs b/azalea-entity/src/lib.rs index 5bf538aa..40f80930 100644 --- a/azalea-entity/src/lib.rs +++ b/azalea-entity/src/lib.rs @@ -130,7 +130,7 @@ pub fn on_pos(offset: f32, chunk_storage: &ChunkStorage, pos: Position) -> Block /// /// For players, this is their actual player UUID, and for other entities it's /// just random. -#[derive(Component, Deref, DerefMut, Clone, Copy, Default, PartialEq)] +#[derive(Clone, Component, Copy, Default, Deref, DerefMut, PartialEq)] pub struct EntityUuid(Uuid); impl EntityUuid { pub fn new(uuid: Uuid) -> Self { @@ -150,7 +150,7 @@ impl Debug for EntityUuid { /// /// Its value is set to a default of [`Vec3::ZERO`] when it receives the login /// packet, its true position may be set ticks later. -#[derive(Component, Clone, Copy, Debug, Default, PartialEq, Deref, DerefMut)] +#[derive(Clone, Component, Copy, Debug, Default, Deref, DerefMut, PartialEq)] pub struct Position(Vec3); impl Position { pub fn new(pos: Vec3) -> Self { @@ -187,7 +187,7 @@ impl From<&Position> for BlockPos { /// network. /// /// This is currently only updated for our own local player entities. -#[derive(Component, Clone, Copy, Debug, Default, PartialEq, Deref, DerefMut)] +#[derive(Clone, Component, Copy, Debug, Default, Deref, DerefMut, PartialEq)] pub struct LastSentPosition(Vec3); impl From<&LastSentPosition> for Vec3 { fn from(value: &LastSentPosition) -> Self { @@ -219,14 +219,14 @@ impl From<&LastSentPosition> for BlockPos { /// /// If this is true, the entity will try to jump every tick. It's equivalent to /// the space key being held in vanilla. -#[derive(Debug, Component, Copy, Clone, Deref, DerefMut, Default, PartialEq, Eq)] +#[derive(Clone, Component, Copy, Debug, Default, Deref, DerefMut, Eq, PartialEq)] pub struct Jumping(pub bool); /// A component that contains the direction an entity is looking, in degrees. /// /// To avoid flagging anticheats, consider using [`Self::update`] when updating /// the values of this struct. -#[derive(Debug, Component, Copy, Clone, Default, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Component, Copy, Debug, Default, PartialEq)] pub struct LookDirection { /// Left and right. AKA yaw. In degrees. y_rot: f32, @@ -326,7 +326,7 @@ impl Eq for LookDirection {} /// The physics data relating to the entity, such as position, velocity, and /// bounding box. -#[derive(Debug, Component, Clone, Default)] +#[derive(Clone, Component, Debug, Default)] pub struct Physics { /// How fast the entity is moving. Sometimes referred to as the delta /// movement. @@ -457,14 +457,14 @@ impl Physics { /// Marker component for entities that are dead. /// /// "Dead" means that the entity has 0 health. -#[derive(Component, Copy, Clone, Default)] +#[derive(Clone, Component, Copy, Default)] pub struct Dead; /// A component NewType for [`EntityKind`]. /// /// Most of the time, you should be using `azalea_registry::EntityKind` /// directly instead. -#[derive(Component, Clone, Copy, Debug, PartialEq, Deref)] +#[derive(Clone, Component, Copy, Debug, Deref, PartialEq)] pub struct EntityKindComponent(pub EntityKind); /// A bundle of components that every entity has. @@ -540,10 +540,10 @@ impl Attributes { /// If this is for a client then all of our clients will have this. /// /// This component is not removed from clients when they disconnect. -#[derive(Component, Clone, Copy, Debug, Default)] +#[derive(Clone, Component, Copy, Debug, Default)] pub struct LocalEntity; -#[derive(Component, Clone, Copy, Debug, PartialEq, Deref, DerefMut)] +#[derive(Clone, Component, Copy, Debug, Deref, DerefMut, PartialEq)] pub struct FluidOnEyes(FluidKind); impl FluidOnEyes { @@ -552,7 +552,7 @@ impl FluidOnEyes { } } -#[derive(Component, Clone, Copy, Debug, PartialEq, Deref, DerefMut)] +#[derive(Clone, Component, Copy, Debug, Deref, DerefMut, PartialEq)] pub struct OnClimbable(bool); /// A component that indicates whether the player is currently sneaking. @@ -563,14 +563,14 @@ pub struct OnClimbable(bool); /// If you need to modify this value, use /// `azalea_client::PhysicsState::trying_to_crouch` or `Client::set_crouching` /// instead. -#[derive(Component, Clone, Copy, Deref, DerefMut, Default)] +#[derive(Clone, Component, Copy, Default, Deref, DerefMut)] pub struct Crouching(bool); /// A component that contains the abilities the player has, like flying /// or instantly breaking blocks. /// /// This is only present on local players. -#[derive(Clone, Debug, Component, Default)] +#[derive(Clone, Component, Debug, Default)] pub struct PlayerAbilities { pub invulnerable: bool, pub flying: bool, diff --git a/azalea-entity/src/metadata.rs b/azalea-entity/src/metadata.rs index 0a4e921d..5bbdbf1b 100644 --- a/azalea-entity/src/metadata.rs +++ b/azalea-entity/src/metadata.rs @@ -21,7 +21,7 @@ use super::{ }; use crate::{HumanoidArm, particle::Particle}; -#[derive(Error, Debug)] +#[derive(Debug, Error)] pub enum UpdateMetadataError { #[error("Wrong type ({0:?})")] WrongType(EntityDataValue), @@ -32,43 +32,43 @@ impl From<EntityDataValue> for UpdateMetadataError { } } -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct OnFire(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct AbstractEntityShiftKeyDown(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Sprinting(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Swimming(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct CurrentlyGlowing(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Invisible(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct FallFlying(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct AirSupply(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct CustomName(pub Option<FormattedText>); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct CustomNameVisible(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Silent(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct NoGravity(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct TicksFrozen(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Hurt(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Hurtdir(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Damage(pub f32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PaddleLeft(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PaddleRight(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct BubbleTime(pub i32); #[derive(Component)] pub struct AcaciaBoat; @@ -184,31 +184,31 @@ impl Default for AcaciaChestBoatMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct AutoSpinAttack(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct AbstractLivingUsingItem(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Health(pub f32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct EffectParticles(pub Vec<Particle>); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct EffectAmbience(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ArrowCount(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct StingerCount(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct SleepingPos(pub Option<BlockPos>); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct NoAi(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct LeftHanded(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Aggressive(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Dancing(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct CanDuplicate(pub bool); #[derive(Component)] pub struct Allay; @@ -285,9 +285,9 @@ impl Default for AllayMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Radius(pub f32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Waiting(pub bool); #[derive(Component)] pub struct AreaEffectCloud; @@ -349,9 +349,9 @@ impl Default for AreaEffectCloudMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct AbstractAgeableBaby(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ArmadilloState(pub ArmadilloStateKind); #[derive(Component)] pub struct Armadillo; @@ -432,25 +432,25 @@ impl Default for ArmadilloMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Small(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct ShowArms(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct ShowBasePlate(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct ArmorStandMarker(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct HeadPose(pub Rotations); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct BodyPose(pub Rotations); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct LeftArmPose(pub Rotations); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct RightArmPose(pub Rotations); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct LeftLegPose(pub Rotations); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct RightLegPose(pub Rotations); #[derive(Component)] pub struct ArmorStand; @@ -553,15 +553,15 @@ impl Default for ArmorStandMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct CritArrow(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct NoPhysics(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PierceLevel(pub u8); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct InGround(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct EffectColor(pub i32); #[derive(Component)] pub struct Arrow; @@ -620,11 +620,11 @@ impl Default for ArrowMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct AxolotlVariant(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PlayingDead(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct AxolotlFromBucket(pub bool); #[derive(Component)] pub struct Axolotl; @@ -829,7 +829,7 @@ impl Default for BambooRaftMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Resting(pub bool); #[derive(Component)] pub struct Bat; @@ -899,13 +899,13 @@ impl Default for BatMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct HasNectar(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct HasStung(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct BeeRolling(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct BeeAngerEndTime(pub i64); #[derive(Component)] pub struct Bee; @@ -1112,7 +1112,7 @@ impl Default for BirchChestBoatMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Charged(pub bool); #[derive(Component)] pub struct Blaze; @@ -1188,37 +1188,37 @@ impl Default for BlazeMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct TransformationInterpolationStartDeltaTicks(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct TransformationInterpolationDuration(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PosRotInterpolationDuration(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Translation(pub Vec3f32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Scale(pub Vec3f32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct LeftRotation(pub Quaternion); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct RightRotation(pub Quaternion); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct BillboardRenderConstraints(pub u8); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct BrightnessOverride(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ViewRange(pub f32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ShadowRadius(pub f32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ShadowStrength(pub f32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct AbstractDisplayWidth(pub f32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct AbstractDisplayHeight(pub f32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct GlowColorOverride(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct BlockDisplayBlockState(pub azalea_block::BlockState); #[derive(Component)] pub struct BlockDisplay; @@ -1307,7 +1307,7 @@ impl Default for BlockDisplayMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct BoggedSheared(pub bool); #[derive(Component)] pub struct Bogged; @@ -1495,17 +1495,17 @@ impl Default for BreezeWindChargeMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Tamed(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Eating(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct AbstractHorseStanding(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Bred(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct CamelDash(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct LastPoseChangeTick(pub i64); #[derive(Component)] pub struct Camel; @@ -1685,19 +1685,19 @@ impl Default for CamelHuskMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Tame(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct InSittingPose(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Owneruuid(pub Option<Uuid>); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct CatVariant(pub azalea_registry::data::CatVariant); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct IsLying(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct RelaxStateOne(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct CatCollarColor(pub i32); #[derive(Component)] pub struct Cat; @@ -1799,7 +1799,7 @@ impl Default for CatMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Climbing(pub bool); #[derive(Component)] pub struct CaveSpider; @@ -1989,9 +1989,9 @@ impl Default for CherryChestBoatMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct CustomDisplayBlock(pub azalea_block::BlockState); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct DisplayOffset(pub i32); #[derive(Component)] pub struct ChestMinecart; @@ -2049,7 +2049,7 @@ impl Default for ChestMinecartMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ChickenVariant(pub azalea_registry::data::PigVariant); #[derive(Component)] pub struct Chicken; @@ -2130,7 +2130,7 @@ impl Default for ChickenMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct AbstractFishFromBucket(pub bool); #[derive(Component)] pub struct Cod; @@ -2201,9 +2201,9 @@ impl Default for CodMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct CommandName(pub String); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct LastOutput(pub FormattedText); #[derive(Component)] pub struct CommandBlockMinecart; @@ -2271,9 +2271,9 @@ impl Default for CommandBlockMinecartMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct WeatherState(pub WeatheringCopperStateKind); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct CopperGolemState(pub CopperGolemStateKind); #[derive(Component)] pub struct CopperGolem; @@ -2350,7 +2350,7 @@ impl Default for CopperGolemMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct CowVariant(pub azalea_registry::data::ChickenVariant); #[derive(Component)] pub struct Cow; @@ -2431,13 +2431,13 @@ impl Default for CowMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct CanMove(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct IsActive(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct IsTearingDown(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct HomePos(pub Option<BlockPos>); #[derive(Component)] pub struct Creaking; @@ -2527,11 +2527,11 @@ impl Default for CreakingMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct SwellDir(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct IsPowered(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct IsIgnited(pub bool); #[derive(Component)] pub struct Creeper; @@ -2730,9 +2730,9 @@ impl Default for DarkOakChestBoatMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct GotFish(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct MoistnessLevel(pub i32); #[derive(Component)] pub struct Dolphin; @@ -2813,7 +2813,7 @@ impl Default for DolphinMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Chest(pub bool); #[derive(Component)] pub struct Donkey; @@ -2946,11 +2946,11 @@ impl Default for DragonFireballMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ZombieBaby(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct SpecialType(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct DrownedConversion(pub bool); #[derive(Component)] pub struct Drowned; @@ -3028,7 +3028,7 @@ impl Default for DrownedMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct AbstractThrownItemProjectileItemStack(pub ItemStack); #[derive(Component)] pub struct Egg; @@ -3081,9 +3081,9 @@ impl Default for EggMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Moving(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct AttackTarget(pub i32); #[derive(Component)] pub struct ElderGuardian; @@ -3160,9 +3160,9 @@ impl Default for ElderGuardianMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct BeamTarget(pub Option<BlockPos>); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ShowBottom(pub bool); #[derive(Component)] pub struct EndCrystal; @@ -3219,7 +3219,7 @@ impl Default for EndCrystalMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Phase(pub i32); #[derive(Component)] pub struct EnderDragon; @@ -3339,11 +3339,11 @@ impl Default for EnderPearlMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct CarryState(pub azalea_block::BlockState); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Creepy(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct StaredAt(pub bool); #[derive(Component)] pub struct Enderman; @@ -3496,9 +3496,9 @@ impl Default for EndermiteMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct IsCelebrating(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct SpellCasting(pub u8); #[derive(Component)] pub struct Evoker; @@ -3674,7 +3674,7 @@ impl Default for ExperienceBottleMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Value(pub i32); #[derive(Component)] pub struct ExperienceOrb; @@ -3726,7 +3726,7 @@ impl Default for ExperienceOrbMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct EyeOfEnderItemStack(pub ItemStack); #[derive(Component)] pub struct EyeOfEnder; @@ -3778,7 +3778,7 @@ impl Default for EyeOfEnderMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct StartPos(pub BlockPos); #[derive(Component)] pub struct FallingBlock; @@ -3830,7 +3830,7 @@ impl Default for FallingBlockMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct FireballItemStack(pub ItemStack); #[derive(Component)] pub struct Fireball; @@ -3882,11 +3882,11 @@ impl Default for FireballMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct FireworksItem(pub ItemStack); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct AttachedToTarget(pub OptionalUnsignedInt); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ShotAtAngle(pub bool); #[derive(Component)] pub struct FireworkRocket; @@ -3948,9 +3948,9 @@ impl Default for FireworkRocketMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct HookedEntity(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Biting(pub bool); #[derive(Component)] pub struct FishingBobber; @@ -4007,25 +4007,25 @@ impl Default for FishingBobberMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct FoxKind(pub i32); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct FoxSitting(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Faceplanted(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Defending(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Sleeping(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Pouncing(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct FoxCrouching(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct FoxInterested(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct TrustedId0(pub Option<Uuid>); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct TrustedId1(pub Option<Uuid>); #[derive(Component)] pub struct Fox; @@ -4140,9 +4140,9 @@ impl Default for FoxMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct FrogVariant(pub azalea_registry::data::WolfSoundVariant); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct TongueTarget(pub OptionalUnsignedInt); #[derive(Component)] pub struct Frog; @@ -4228,7 +4228,7 @@ impl Default for FrogMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Fuel(pub bool); #[derive(Component)] pub struct FurnaceMinecart; @@ -4291,7 +4291,7 @@ impl Default for FurnaceMinecartMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct IsCharging(pub bool); #[derive(Component)] pub struct Ghast; @@ -4428,11 +4428,11 @@ impl Default for GiantMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ItemFrameDirection(pub Direction); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ItemFrameItem(pub ItemStack); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Rotation(pub i32); #[derive(Component)] pub struct GlowItemFrame; @@ -4485,7 +4485,7 @@ impl Default for GlowItemFrameMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct DarkTicksRemaining(pub i32); #[derive(Component)] pub struct GlowSquid; @@ -4566,11 +4566,11 @@ impl Default for GlowSquidMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct IsScreamingGoat(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct HasLeftHorn(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct HasRightHorn(pub bool); #[derive(Component)] pub struct Goat; @@ -4739,9 +4739,9 @@ impl Default for GuardianMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct IsLeashHolder(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct StaysStill(pub bool); #[derive(Component)] pub struct HappyGhast; @@ -4827,7 +4827,7 @@ impl Default for HappyGhastMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct HoglinImmuneToZombification(pub bool); #[derive(Component)] pub struct Hoglin; @@ -4964,7 +4964,7 @@ impl Default for HopperMinecartMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct HorseTypeVariant(pub i32); #[derive(Component)] pub struct Horse; @@ -5206,11 +5206,11 @@ impl Default for IllusionerMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct InteractionWidth(pub f32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct InteractionHeight(pub f32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Response(pub bool); #[derive(Component)] pub struct Interaction; @@ -5272,7 +5272,7 @@ impl Default for InteractionMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct PlayerCreated(pub bool); #[derive(Component)] pub struct IronGolem; @@ -5345,7 +5345,7 @@ impl Default for IronGolemMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ItemItem(pub ItemStack); #[derive(Component)] pub struct Item; @@ -5397,9 +5397,9 @@ impl Default for ItemMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ItemDisplayItemStack(pub ItemStack); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ItemDisplayItemDisplay(pub u8); #[derive(Component)] pub struct ItemDisplay; @@ -5808,9 +5808,9 @@ impl Default for LingeringPotionMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Strength(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct LlamaVariant(pub i32); #[derive(Component)] pub struct Llama; @@ -5953,7 +5953,7 @@ impl Default for LlamaSpitMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct SlimeSize(pub i32); #[derive(Component)] pub struct MagmaCube; @@ -6135,15 +6135,15 @@ impl Default for MangroveChestBoatMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PlayerMainHand(pub HumanoidArm); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PlayerModeCustomisation(pub u8); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Profile(pub components::Profile); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Immovable(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Description(pub Option<FormattedText>); #[derive(Component)] pub struct Mannequin; @@ -6322,7 +6322,7 @@ impl Default for MinecartMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct MooshroomKind(pub i32); #[derive(Component)] pub struct Mooshroom; @@ -6489,7 +6489,7 @@ impl Default for MuleMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct NautilusDash(pub bool); #[derive(Component)] pub struct Nautilus; @@ -6690,7 +6690,7 @@ impl Default for OakChestBoatMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Trusting(pub bool); #[derive(Component)] pub struct Ocelot; @@ -6771,7 +6771,7 @@ impl Default for OcelotMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct OminousItemSpawnerItem(pub ItemStack); #[derive(Component)] pub struct OminousItemSpawner; @@ -6823,9 +6823,9 @@ impl Default for OminousItemSpawnerMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PaintingDirection(pub Direction); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PaintingVariant(pub azalea_registry::data::PaintingVariant); #[derive(Component)] pub struct Painting; @@ -6996,23 +6996,23 @@ impl Default for PaleOakChestBoatMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PandaUnhappyCounter(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct SneezeCounter(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct EatCounter(pub i32); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct Sneezing(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct PandaSitting(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct OnBack(pub bool); -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct PandaRolling(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct HiddenGene(pub u8); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PandaFlags(pub u8); #[derive(Component)] pub struct Panda; @@ -7196,7 +7196,7 @@ impl Default for ParchedMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ParrotVariant(pub i32); #[derive(Component)] pub struct Parrot; @@ -7283,7 +7283,7 @@ impl Default for ParrotMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PhantomSize(pub i32); #[derive(Component)] pub struct Phantom; @@ -7352,9 +7352,9 @@ impl Default for PhantomMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PigBoostTime(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PigVariant(pub azalea_registry::data::FrogVariant); #[derive(Component)] pub struct Pig; @@ -7440,13 +7440,13 @@ impl Default for PigMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct AbstractPiglinImmuneToZombification(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PiglinBaby(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PiglinIsChargingCrossbow(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct IsDancing(pub bool); #[derive(Component)] pub struct Piglin; @@ -7611,7 +7611,7 @@ impl Default for PiglinBruteMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PillagerIsChargingCrossbow(pub bool); #[derive(Component)] pub struct Pillager; @@ -7692,13 +7692,13 @@ impl Default for PillagerMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PlayerAbsorption(pub f32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Score(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ShoulderParrotLeft(pub OptionalUnsignedInt); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ShoulderParrotRight(pub OptionalUnsignedInt); #[derive(Component)] pub struct Player; @@ -7781,7 +7781,7 @@ impl Default for PlayerMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PolarBearStanding(pub bool); #[derive(Component)] pub struct PolarBear; @@ -7862,9 +7862,9 @@ impl Default for PolarBearMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PufferfishFromBucket(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct PuffState(pub i32); #[derive(Component)] pub struct Pufferfish; @@ -7941,7 +7941,7 @@ impl Default for PufferfishMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct RabbitKind(pub i32); #[derive(Component)] pub struct Rabbit; @@ -8096,7 +8096,7 @@ impl Default for RavagerMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct SalmonKind(pub i32); #[derive(Component)] pub struct Salmon; @@ -8172,7 +8172,7 @@ impl Default for SalmonMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct SheepSheared(pub bool); #[derive(Component)] pub struct Sheep; @@ -8254,11 +8254,11 @@ impl Default for SheepMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct AttachFace(pub Direction); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Peek(pub u8); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Color(pub u8); #[derive(Component)] pub struct Shulker; @@ -8453,7 +8453,7 @@ impl Default for SilverfishMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct StrayConversion(pub bool); #[derive(Component)] pub struct Skeleton; @@ -8676,7 +8676,7 @@ impl Default for SlimeMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct SmallFireballItemStack(pub ItemStack); #[derive(Component)] pub struct SmallFireball; @@ -8728,9 +8728,9 @@ impl Default for SmallFireballMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct SnifferState(pub SnifferStateKind); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct DropSeedAtTick(pub i32); #[derive(Component)] pub struct Sniffer; @@ -8816,7 +8816,7 @@ impl Default for SnifferMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, Copy, PartialEq)] +#[derive(Clone, Component, Copy, Deref, DerefMut, PartialEq)] pub struct HasPumpkin(pub bool); #[derive(Component)] pub struct SnowGolem; @@ -9424,9 +9424,9 @@ impl Default for StrayMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct StriderBoostTime(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Suffocating(pub bool); #[derive(Component)] pub struct Strider; @@ -9512,7 +9512,7 @@ impl Default for StriderMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct TadpoleFromBucket(pub bool); #[derive(Component)] pub struct Tadpole; @@ -9584,15 +9584,15 @@ impl Default for TadpoleMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Text(pub FormattedText); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct LineWidth(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct BackgroundColor(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct TextOpacity(pub u8); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct StyleFlags(pub u8); #[derive(Component)] pub struct TextDisplay; @@ -9701,9 +9701,9 @@ impl Default for TextDisplayMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Fuse(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct TntBlockState(pub azalea_block::BlockState); #[derive(Component)] pub struct Tnt; @@ -9909,9 +9909,9 @@ impl Default for TraderLlamaMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Loyalty(pub u8); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Foil(pub bool); #[derive(Component)] pub struct Trident; @@ -9975,7 +9975,7 @@ impl Default for TridentMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct TropicalFishTypeVariant(pub i32); #[derive(Component)] pub struct TropicalFish; @@ -10051,9 +10051,9 @@ impl Default for TropicalFishMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct HasEgg(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct LayingEgg(pub bool); #[derive(Component)] pub struct Turtle; @@ -10139,7 +10139,7 @@ impl Default for TurtleMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct VexFlags(pub u8); #[derive(Component)] pub struct Vex; @@ -10214,9 +10214,9 @@ impl Default for VexMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct AbstractVillagerUnhappyCounter(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct VillagerVillagerData(pub VillagerData); #[derive(Component)] pub struct Villager; @@ -10451,7 +10451,7 @@ impl Default for WanderingTraderMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ClientAngerLevel(pub i32); #[derive(Component)] pub struct Warden; @@ -10571,7 +10571,7 @@ impl Default for WindChargeMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct WitchUsingItem(pub bool); #[derive(Component)] pub struct Witch; @@ -10652,13 +10652,13 @@ impl Default for WitchMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct TargetA(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct TargetB(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct TargetC(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Inv(pub i32); #[derive(Component)] pub struct Wither; @@ -10816,7 +10816,7 @@ impl Default for WitherSkeletonMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Dangerous(pub bool); #[derive(Component)] pub struct WitherSkull; @@ -10868,15 +10868,15 @@ impl Default for WitherSkullMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct WolfInterested(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct WolfCollarColor(pub i32); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct WolfAngerEndTime(pub i64); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct WolfVariant(pub azalea_registry::data::CowVariant); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct SoundVariant(pub azalea_registry::data::WolfVariant); #[derive(Component)] pub struct Wolf; @@ -10983,7 +10983,7 @@ impl Default for WolfMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ZoglinBaby(pub bool); #[derive(Component)] pub struct Zoglin; @@ -11222,9 +11222,9 @@ impl Default for ZombieHorseMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ZombieNautilusDash(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ZombieNautilusVariant(pub azalea_registry::data::ZombieNautilusVariant); #[derive(Component)] pub struct ZombieNautilus; @@ -11320,9 +11320,9 @@ impl Default for ZombieNautilusMetadataBundle { } } -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct Converting(pub bool); -#[derive(Component, Deref, DerefMut, Clone, PartialEq)] +#[derive(Clone, Component, Deref, DerefMut, PartialEq)] pub struct ZombieVillagerVillagerData(pub VillagerData); #[derive(Component)] pub struct ZombieVillager; diff --git a/azalea-entity/src/particle.rs b/azalea-entity/src/particle.rs index 41977d9f..a85d2565 100644 --- a/azalea-entity/src/particle.rs +++ b/azalea-entity/src/particle.rs @@ -10,7 +10,7 @@ use bevy_ecs::component::Component; // we get errors parsing particles. /// A [`ParticleKind`] with data potentially attached to it. -#[derive(Component, Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Component, Debug, PartialEq)] pub enum Particle { AngryVillager, Block(BlockParticle), @@ -265,18 +265,18 @@ impl Default for Particle { } } -#[derive(Debug, Clone, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq)] pub struct BlockParticle { pub block_state: BlockState, } -#[derive(Debug, Clone, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq)] pub struct DustParticle { pub color: RgbColor, /// The scale, will be clamped between 0.01 and 4. pub scale: f32, } -#[derive(Debug, Clone, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq)] pub struct DustColorTransitionParticle { pub from: RgbColor, pub to: RgbColor, @@ -284,24 +284,24 @@ pub struct DustColorTransitionParticle { pub scale: f32, } -#[derive(Debug, Clone, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq)] pub struct ColorParticle { pub color: RgbColor, } -#[derive(Debug, Clone, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq)] pub struct ItemParticle { pub item: ItemStack, } -#[derive(Debug, Clone, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq)] pub struct VibrationParticle { pub position: PositionSource, #[var] pub ticks: u32, } -#[derive(Debug, Clone, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub enum PositionSource { Block(BlockPos), Entity { @@ -317,12 +317,12 @@ impl Default for PositionSource { } } -#[derive(Debug, Clone, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq)] pub struct SculkChargeParticle { pub roll: f32, } -#[derive(Debug, Clone, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq)] pub struct ShriekParticle { #[var] pub delay: i32, // The time in ticks before the particle is displayed diff --git a/azalea-entity/src/plugin/indexing.rs b/azalea-entity/src/plugin/indexing.rs index 6f170dc6..edceccc7 100644 --- a/azalea-entity/src/plugin/indexing.rs +++ b/azalea-entity/src/plugin/indexing.rs @@ -16,7 +16,7 @@ use uuid::Uuid; use super::LoadedBy; use crate::{EntityUuid, LocalEntity, Position}; -#[derive(Resource, Default)] +#[derive(Default, Resource)] pub struct EntityUuidIndex { /// An index of entities by their UUIDs entity_by_uuid: HashMap<Uuid, Entity>, diff --git a/azalea-entity/src/plugin/mod.rs b/azalea-entity/src/plugin/mod.rs index 7296f2ff..855b2899 100644 --- a/azalea-entity/src/plugin/mod.rs +++ b/azalea-entity/src/plugin/mod.rs @@ -25,7 +25,7 @@ use crate::{ }; /// A Bevy [`SystemSet`] for various types of entity updates. -#[derive(SystemSet, Debug, Hash, Eq, PartialEq, Clone)] +#[derive(Clone, Debug, Eq, Hash, PartialEq, SystemSet)] pub enum EntityUpdateSystems { /// Create search indexes for entities. Index, @@ -192,7 +192,7 @@ fn is_trapdoor_useable_as_ladder( /// loaded. /// /// If this is empty, the entity will be removed from the ECS. -#[derive(Component, Clone, Deref, DerefMut)] +#[derive(Clone, Component, Deref, DerefMut)] pub struct LoadedBy(pub HashSet<Entity>); pub fn clamp_look_direction(mut query: Query<&mut LookDirection>) { @@ -254,7 +254,7 @@ pub fn update_crouching(query: Query<(&mut Crouching, &Pose), Without<LocalEntit /// /// Internally, this is only used for player physics. Not to be confused with /// the somewhat similarly named [`LoadedBy`]. -#[derive(Component, Clone, Debug, Copy)] +#[derive(Clone, Component, Copy, Debug)] pub struct InLoadedChunk; /// Update the [`InLoadedChunk`] component for all entities in the world. diff --git a/azalea-entity/src/vec_delta_codec.rs b/azalea-entity/src/vec_delta_codec.rs index 270daff2..5221ec47 100644 --- a/azalea-entity/src/vec_delta_codec.rs +++ b/azalea-entity/src/vec_delta_codec.rs @@ -1,6 +1,6 @@ use azalea_core::{delta::PositionDelta8, position::Vec3}; -#[derive(Debug, Clone, Default)] +#[derive(Clone, Debug, Default)] pub struct VecDeltaCodec { base: Vec3, } diff --git a/azalea-inventory/azalea-inventory-macros/src/location_enum.rs b/azalea-inventory/azalea-inventory-macros/src/location_enum.rs index 46db3e76..77ecea43 100644 --- a/azalea-inventory/azalea-inventory-macros/src/location_enum.rs +++ b/azalea-inventory/azalea-inventory-macros/src/location_enum.rs @@ -40,7 +40,7 @@ pub fn generate(input: &DeclareMenus) -> TokenStream { }); } enums.extend(quote! { - #[derive(Clone, Copy, Debug, PartialEq, Eq, Hash)] + #[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)] pub enum #enum_name { #individual_menu_location_variants } diff --git a/azalea-inventory/src/components/mod.rs b/azalea-inventory/src/components/mod.rs index a344b5b3..bc2a8f20 100644 --- a/azalea-inventory/src/components/mod.rs +++ b/azalea-inventory/src/components/mod.rs @@ -301,56 +301,56 @@ define_data_components!( AttackRange, ); -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct CustomData { pub nbt: Nbt, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct MaxStackSize { #[var] pub count: i32, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct MaxDamage { #[var] pub amount: i32, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct Damage { #[var] pub amount: i32, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct Unbreakable; -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct CustomName { pub name: FormattedText, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct ItemName { pub name: FormattedText, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct Lore { pub lines: Vec<FormattedText>, // vanilla also has styled_lines here but it doesn't appear to be used for the protocol } -#[derive(Clone, Copy, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq, Serialize)] #[serde(rename_all = "snake_case")] pub enum Rarity { Common, @@ -359,7 +359,7 @@ pub enum Rarity { Epic, } -#[derive(Clone, PartialEq, AzBuf, Serialize, Default)] +#[derive(AzBuf, Clone, Default, PartialEq, Serialize)] #[serde(transparent)] pub struct Enchantments { /// Enchantment levels here are 1-indexed, level 0 does not exist. @@ -367,7 +367,7 @@ pub struct Enchantments { pub levels: HashMap<Enchantment, i32>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub enum BlockStateValueMatcher { Exact { value: String, @@ -378,13 +378,13 @@ pub enum BlockStateValueMatcher { }, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct BlockStatePropertyMatcher { pub name: String, pub value_matcher: BlockStateValueMatcher, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct BlockPredicate { #[serde(skip_serializing_if = "is_default")] pub blocks: Option<HolderSet<BlockKind, Identifier>>, @@ -394,26 +394,26 @@ pub struct BlockPredicate { pub nbt: Option<NbtCompound>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct AdventureModePredicate { #[serde(serialize_with = "flatten_array")] pub predicates: Vec<BlockPredicate>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct CanPlaceOn { pub predicate: AdventureModePredicate, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct CanBreak { pub predicate: AdventureModePredicate, } -#[derive(Clone, Copy, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq, Serialize)] #[serde(rename_all = "snake_case")] pub enum EquipmentSlotGroup { Any, @@ -431,14 +431,14 @@ pub enum EquipmentSlotGroup { // this is duplicated in azalea-entity, BUT the one there has a different // protocol format (and we can't use it anyways because it would cause a // circular dependency) -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct AttributeModifier { pub id: Identifier, pub amount: f64, pub operation: AttributeModifierOperation, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct AttributeModifiersEntry { #[serde(rename = "type")] pub kind: Attribute, @@ -449,13 +449,13 @@ pub struct AttributeModifiersEntry { pub display: AttributeModifierDisplay, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize, Default)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq, Serialize)] #[serde(transparent)] pub struct AttributeModifiers { pub modifiers: Vec<AttributeModifiersEntry>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Default, Serialize)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq, Serialize)] #[serde(rename_all = "snake_case")] pub enum AttributeModifierDisplay { #[default] @@ -466,7 +466,7 @@ pub enum AttributeModifierDisplay { }, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct CustomModelData { #[serde(skip_serializing_if = "Vec::is_empty")] pub floats: Vec<f32>, @@ -478,26 +478,26 @@ pub struct CustomModelData { pub colors: Vec<i32>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct RepairCost { #[var] pub cost: u32, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct CreativeSlotLock; -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct EnchantmentGlintOverride { pub show_glint: bool, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct IntangibleProjectile; -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct MobEffectDetails { #[var] #[serde(skip_serializing_if = "is_default")] @@ -531,20 +531,20 @@ impl Default for MobEffectDetails { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct MobEffectInstance { pub id: MobEffect, #[serde(flatten)] pub details: MobEffectDetails, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct PossibleEffect { pub effect: MobEffectInstance, pub probability: f32, } -#[derive(Clone, PartialEq, AzBuf, Debug, Default, Serialize)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq, Serialize)] pub struct Food { #[var] pub nutrition: i32, @@ -563,7 +563,7 @@ impl Food { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct ToolRule { pub blocks: HolderSet<BlockKind, Identifier>, #[serde(skip_serializing_if = "is_default")] @@ -586,7 +586,7 @@ impl Default for ToolRule { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct Tool { #[serde(serialize_with = "flatten_array")] pub rules: Vec<ToolRule>, @@ -615,57 +615,57 @@ impl Default for Tool { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct StoredEnchantments { #[var] pub enchantments: HashMap<Enchantment, i32>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct DyedColor { pub rgb: i32, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct MapColor { pub color: i32, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct MapId { #[var] pub id: i32, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct MapDecorations { pub decorations: NbtCompound, } -#[derive(Clone, Copy, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq, Serialize)] pub enum MapPostProcessing { Lock, Scale, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct ChargedProjectiles { pub items: Vec<ItemStack>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct BundleContents { pub items: Vec<ItemStack>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct PotionContents { #[serde(skip_serializing_if = "is_default")] pub potion: Option<Potion>, @@ -693,7 +693,7 @@ impl Default for PotionContents { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct SuspiciousStewEffect { #[serde(rename = "id")] pub effect: MobEffect, @@ -702,18 +702,18 @@ pub struct SuspiciousStewEffect { pub duration: i32, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct SuspiciousStewEffects { pub effects: Vec<SuspiciousStewEffect>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct WritableBookContent { pub pages: Vec<Filterable<String>>, } -#[derive(Clone, PartialEq, AzBuf, Serialize)] +#[derive(AzBuf, Clone, PartialEq, Serialize)] pub struct WrittenBookContent { #[limit(32)] pub title: Filterable<String>, @@ -727,19 +727,19 @@ pub struct WrittenBookContent { pub resolved: bool, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct Trim { pub material: TrimMaterial, pub pattern: TrimPattern, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct DebugStickState { pub properties: NbtCompound, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct EntityData { #[serde(rename = "id")] pub kind: EntityKind, @@ -747,13 +747,13 @@ pub struct EntityData { pub data: NbtCompound, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct BucketEntityData { pub entity: NbtCompound, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct BlockEntityData { #[serde(rename = "id")] pub kind: EntityKind, @@ -761,14 +761,14 @@ pub struct BlockEntityData { pub data: NbtCompound, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(untagged)] pub enum Instrument { Registry(data::Instrument), Holder(Holder<data::Instrument, InstrumentData>), } -#[derive(Clone, PartialEq, Debug, AzBuf, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct InstrumentData { pub sound_event: Holder<SoundEvent, azalea_core::sound::CustomSound>, pub use_duration: f32, @@ -776,20 +776,20 @@ pub struct InstrumentData { pub description: FormattedText, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct OminousBottleAmplifier { #[var] pub amplifier: i32, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct Recipes { pub recipes: Vec<Identifier>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct LodestoneTracker { #[serde(skip_serializing_if = "is_default")] pub target: Option<GlobalPos>, @@ -797,7 +797,7 @@ pub struct LodestoneTracker { pub tracked: bool, } -#[derive(Clone, Copy, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq, Serialize)] #[serde(rename_all = "snake_case")] pub enum FireworkExplosionShape { SmallBall, @@ -807,7 +807,7 @@ pub enum FireworkExplosionShape { Burst, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct FireworkExplosion { pub shape: FireworkExplosionShape, #[serde(skip_serializing_if = "is_default")] @@ -820,7 +820,7 @@ pub struct FireworkExplosion { pub has_twinkle: bool, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct Fireworks { #[var] #[serde(skip_serializing_if = "is_default")] @@ -843,13 +843,13 @@ impl Default for Fireworks { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct NoteBlockSound { pub sound: Identifier, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct BannerPattern { #[var] pub pattern: i32, @@ -857,13 +857,13 @@ pub struct BannerPattern { pub color: i32, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct BannerPatterns { pub patterns: Vec<BannerPattern>, } -#[derive(Clone, Copy, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq, Serialize)] #[serde(rename_all = "snake_case")] pub enum DyeColor { White, @@ -884,31 +884,31 @@ pub enum DyeColor { Black, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct BaseColor { pub color: DyeColor, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct PotDecorations { pub items: Vec<ItemKind>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct Container { pub items: Vec<ItemStack>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct BlockState { pub properties: HashMap<String, String>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct BeehiveOccupant { #[serde(skip_serializing_if = "is_default")] pub entity_data: NbtCompound, @@ -918,30 +918,30 @@ pub struct BeehiveOccupant { pub min_ticks_in_hive: i32, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct Bees { pub occupants: Vec<BeehiveOccupant>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct Lock { pub key: String, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct ContainerLoot { pub loot_table: NbtCompound, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(untagged)] pub enum JukeboxPlayable { Referenced(Identifier), Direct(Holder<JukeboxSong, JukeboxSongData>), } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct JukeboxSongData { pub sound_event: Holder<SoundEvent, CustomSound>, pub description: FormattedText, @@ -950,7 +950,7 @@ pub struct JukeboxSongData { pub comparator_output: i32, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct Consumable { #[serde(skip_serializing_if = "is_default")] pub consume_seconds: f32, @@ -987,7 +987,7 @@ impl Default for Consumable { } } -#[derive(Clone, Copy, PartialEq, AzBuf, Debug, Default, Serialize)] +#[derive(AzBuf, Clone, Copy, Debug, Default, PartialEq, Serialize)] #[serde(rename_all = "snake_case")] pub enum ItemUseAnimation { #[default] @@ -1003,13 +1003,13 @@ pub enum ItemUseAnimation { Brush, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct UseRemainder { pub convert_into: ItemStack, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct UseCooldown { pub seconds: f32, #[serde(skip_serializing_if = "is_default")] @@ -1030,30 +1030,30 @@ impl Default for UseCooldown { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct Enchantable { #[var] pub value: u32, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct Repairable { pub items: HolderSet<ItemKind, Identifier>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct ItemModel { pub resource_location: Identifier, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct DamageResistant { /// In vanilla this only allows tag keys, i.e. it must start with '#' pub types: Identifier, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct Equippable { pub slot: EquipmentSlot, #[serde(skip_serializing_if = "is_default_equip_sound")] @@ -1108,7 +1108,7 @@ impl Default for Equippable { } /// An enum that represents inventory slots that can hold items. -#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, AzBuf, Serialize)] +#[derive(AzBuf, Clone, Copy, Debug, Eq, Hash, PartialEq, Serialize)] #[serde(rename_all = "snake_case")] pub enum EquipmentSlot { Mainhand, @@ -1167,21 +1167,21 @@ impl Display for EquipmentSlot { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct Glider; -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct TooltipStyle { pub resource_location: Identifier, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct DeathProtection { pub death_effects: Vec<ConsumeEffect>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct Weapon { #[var] #[serde(skip_serializing_if = "is_default_item_damage_per_attack")] @@ -1207,37 +1207,37 @@ impl Default for Weapon { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct PotionDurationScale { pub value: f32, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct VillagerVariant { pub variant: VillagerKind, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct WolfVariant { pub variant: data::WolfVariant, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct WolfCollar { pub color: DyeColor, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct FoxVariant { pub variant: FoxVariantKind, } -#[derive(Default, AzBuf, Clone, Copy, Debug, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, Default, PartialEq)] pub enum FoxVariantKind { #[default] Red, @@ -1260,7 +1260,7 @@ impl Serialize for FoxVariantKind { } } -#[derive(Clone, Copy, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq, Serialize)] #[serde(rename_all = "snake_case")] pub enum SalmonSize { Small, @@ -1268,7 +1268,7 @@ pub enum SalmonSize { Large, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct ParrotVariant { pub variant: ParrotVariantKind, @@ -1301,7 +1301,7 @@ impl Serialize for ParrotVariantKind { } } -#[derive(Clone, Copy, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq, Serialize)] #[serde(rename_all = "snake_case")] pub enum TropicalFishPattern { Kob, @@ -1318,24 +1318,24 @@ pub enum TropicalFishPattern { Clayfish, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct TropicalFishBaseColor { pub color: DyeColor, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct TropicalFishPatternColor { pub color: DyeColor, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct MooshroomVariant { pub variant: MooshroomVariantKind, } -#[derive(Default, AzBuf, Clone, Copy, Debug, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, Default, PartialEq)] pub enum MooshroomVariantKind { #[default] Red, @@ -1358,12 +1358,12 @@ impl Serialize for MooshroomVariantKind { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct RabbitVariant { pub variant: RabbitVariantKind, } -#[derive(Default, AzBuf, Clone, Copy, Debug, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, Default, PartialEq)] pub enum RabbitVariantKind { #[default] Brown, @@ -1396,24 +1396,24 @@ impl Serialize for RabbitVariantKind { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct PigVariant { pub variant: data::PigVariant, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct FrogVariant { pub variant: data::FrogVariant, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct HorseVariant { pub variant: HorseVariantKind, } -#[derive(Default, AzBuf, Clone, Copy, Debug, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, Default, PartialEq)] pub enum HorseVariantKind { #[default] White, @@ -1446,13 +1446,13 @@ impl Serialize for HorseVariantKind { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct PaintingVariant { pub variant: Holder<data::PaintingVariant, PaintingVariantData>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct PaintingVariantData { #[var] pub width: i32, @@ -1465,12 +1465,12 @@ pub struct PaintingVariantData { pub author: Option<FormattedText>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct LlamaVariant { pub variant: LlamaVariantKind, } -#[derive(Default, AzBuf, Clone, Copy, Debug, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, Default, PartialEq)] pub enum LlamaVariantKind { #[default] Creamy, @@ -1497,12 +1497,12 @@ impl Serialize for LlamaVariantKind { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct AxolotlVariant { pub variant: AxolotlVariantKind, } -#[derive(Default, AzBuf, Clone, Copy, Debug, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, Default, PartialEq)] pub enum AxolotlVariantKind { #[default] Lucy, @@ -1531,31 +1531,31 @@ impl Serialize for AxolotlVariantKind { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct CatVariant { pub variant: data::CatVariant, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct CatCollar { pub color: DyeColor, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct SheepColor { pub color: DyeColor, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct ShulkerColor { pub color: DyeColor, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct TooltipDisplay { #[serde(skip_serializing_if = "is_default")] pub hide_tooltip: bool, @@ -1577,7 +1577,7 @@ impl Default for TooltipDisplay { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct BlocksAttacks { #[serde(skip_serializing_if = "is_default")] pub block_delay_seconds: f32, @@ -1622,7 +1622,7 @@ impl Default for BlocksAttacks { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct DamageReduction { #[serde(skip_serializing_if = "is_default_horizontal_blocking_angle")] pub horizontal_blocking_angle: f32, @@ -1634,7 +1634,7 @@ pub struct DamageReduction { fn is_default_horizontal_blocking_angle(value: &f32) -> bool { *value == 90. } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct ItemDamageFunction { pub threshold: f32, pub base: f32, @@ -1650,79 +1650,79 @@ impl Default for ItemDamageFunction { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(untagged)] pub enum ProvidesTrimMaterial { Referenced(Identifier), Direct(Holder<TrimMaterial, DirectTrimMaterial>), } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct DirectTrimMaterial { pub assets: MaterialAssetGroup, pub description: FormattedText, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct MaterialAssetGroup { pub base: AssetInfo, #[serde(skip_serializing_if = "is_default")] pub overrides: Vec<(Identifier, AssetInfo)>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct AssetInfo { pub suffix: String, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct ProvidesBannerPatterns { pub key: Identifier, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct BreakSound { pub sound: azalea_registry::Holder<SoundEvent, CustomSound>, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct WolfSoundVariant { pub variant: azalea_registry::data::WolfSoundVariant, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct CowVariant { pub variant: azalea_registry::data::CowVariant, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(untagged)] pub enum ChickenVariant { Referenced(Identifier), Direct(ChickenVariantData), } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct ChickenVariantData { pub registry: azalea_registry::data::ChickenVariant, } // TODO: check in-game if this is correct -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub enum ZombieNautilusVariant { Referenced(Identifier), Direct(ZombieNautilusVariantData), } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct ZombieNautilusVariantData { pub value: azalea_registry::data::ZombieNautilusVariant, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct UseEffects { pub can_sprint: bool, pub interact_vibrations: bool, @@ -1743,21 +1743,21 @@ impl Default for UseEffects { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct MinimumAttackCharge { pub value: f32, } // TODO: this is probably wrong, check in-game -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(untagged)] pub enum DamageType { Registry(DamageKind), Holder(Holder<DamageKind, DamageTypeElement>), } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct PiercingWeapon { pub deals_knockback: bool, pub dismounts: bool, @@ -1780,7 +1780,7 @@ impl Default for PiercingWeapon { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct KineticWeapon { #[var] pub contact_cooldown_ticks: i32, @@ -1815,7 +1815,7 @@ impl Default for KineticWeapon { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct KineticWeaponCondition { #[var] pub max_duration_ticks: i32, @@ -1837,7 +1837,7 @@ impl Default for KineticWeaponCondition { } } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct SwingAnimation { #[serde(rename = "type")] pub kind: SwingAnimationKind, @@ -1858,7 +1858,7 @@ impl Default for SwingAnimation { } } -#[derive(Clone, Copy, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq, Serialize)] #[serde(rename_all = "snake_case")] pub enum SwingAnimationKind { None, @@ -1866,7 +1866,7 @@ pub enum SwingAnimationKind { Stab, } -#[derive(Clone, PartialEq, AzBuf, Debug, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] pub struct AttackRange { pub min_reach: f32, pub max_reach: f32, diff --git a/azalea-inventory/src/components/profile.rs b/azalea-inventory/src/components/profile.rs index 11b0e6e1..8a0fdf50 100644 --- a/azalea-inventory/src/components/profile.rs +++ b/azalea-inventory/src/components/profile.rs @@ -7,7 +7,7 @@ use azalea_registry::identifier::Identifier; use serde::{Serialize, Serializer}; use uuid::Uuid; -#[derive(Clone, Debug, AzBuf, Default, PartialEq, Serialize)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq, Serialize)] #[doc(alias = "ResolvableProfile")] pub struct Profile { #[serde(flatten)] @@ -16,7 +16,7 @@ pub struct Profile { pub skin_patch: Box<PlayerSkinPatch>, } -#[derive(Clone, Debug, AzBuf, PartialEq, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(untagged)] pub enum PartialOrFullProfile { Partial(PartialProfile), @@ -28,7 +28,7 @@ impl Default for PartialOrFullProfile { } } -#[derive(Clone, Debug, AzBuf, Default, PartialEq, Serialize)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq, Serialize)] pub struct PartialProfile { #[limit(16)] #[serde(skip_serializing_if = "is_default")] @@ -47,7 +47,7 @@ fn serialize_properties<S: Serializer>( serializable.serialize(serializer) } -#[derive(Clone, Debug, AzBuf, Default, PartialEq, Serialize)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq, Serialize)] pub struct PlayerSkinPatch { #[serde(rename = "texture")] #[serde(skip_serializing_if = "is_default")] @@ -60,7 +60,7 @@ pub struct PlayerSkinPatch { pub model: Option<PlayerModelType>, } -#[derive(Clone, Debug, Copy, AzBuf, Default, PartialEq, Serialize)] +#[derive(AzBuf, Clone, Copy, Debug, Default, PartialEq, Serialize)] #[serde(rename_all = "snake_case")] pub enum PlayerModelType { #[default] @@ -68,7 +68,7 @@ pub enum PlayerModelType { Slim, } -#[derive(Clone, Debug, AzBuf, PartialEq, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(transparent)] pub struct ResourceTexture { pub id: Identifier, diff --git a/azalea-inventory/src/item/consume_effect.rs b/azalea-inventory/src/item/consume_effect.rs index 9b8a198d..45b32704 100644 --- a/azalea-inventory/src/item/consume_effect.rs +++ b/azalea-inventory/src/item/consume_effect.rs @@ -9,7 +9,7 @@ use serde::Serialize; use crate::components::MobEffectInstance; -#[derive(Clone, PartialEq, Debug, AzBuf, Serialize)] +#[derive(AzBuf, Clone, Debug, PartialEq, Serialize)] #[serde(rename_all = "snake_case", tag = "type")] pub enum ConsumeEffect { ApplyEffects { diff --git a/azalea-inventory/src/lib.rs b/azalea-inventory/src/lib.rs index e95d9ee1..9c4b62bb 100644 --- a/azalea-inventory/src/lib.rs +++ b/azalea-inventory/src/lib.rs @@ -17,7 +17,7 @@ pub use slot::{DataComponentPatch, ItemStack, ItemStackData}; // https://github.com/rust-lang/rust/issues/61415 /// A fixed-size list of [`ItemStack`]s. -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub struct SlotList<const N: usize>([ItemStack; N]); impl<const N: usize> Deref for SlotList<N> { type Target = [ItemStack; N]; diff --git a/azalea-inventory/src/operations.rs b/azalea-inventory/src/operations.rs index fc42e498..41fca533 100644 --- a/azalea-inventory/src/operations.rs +++ b/azalea-inventory/src/operations.rs @@ -14,7 +14,7 @@ use crate::{ }; /// A type of click in a Minecraft inventory. -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub enum ClickOperation { Pickup(PickupClick), QuickMove(QuickMoveClick), @@ -25,7 +25,7 @@ pub enum ClickOperation { PickupAll(PickupAllClick), } -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub enum PickupClick { /// Left mouse click. /// @@ -47,7 +47,7 @@ impl From<PickupClick> for ClickOperation { } /// Shift click -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub enum QuickMoveClick { /// Shift + left mouse click Left { slot: u16 }, @@ -61,7 +61,7 @@ impl From<QuickMoveClick> for ClickOperation { } /// Used when you press number keys or F in an inventory. -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub struct SwapClick { pub source_slot: u16, /// 0-8 for hotbar slots, 40 for offhand, everything else is treated as a @@ -76,7 +76,7 @@ impl From<SwapClick> for ClickOperation { } /// Middle click, only defined for creative players in non-player /// inventories. -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub struct CloneClick { pub slot: u16, } @@ -85,7 +85,7 @@ impl From<CloneClick> for ClickOperation { ClickOperation::Clone(click) } } -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub enum ThrowClick { /// Drop key (Q) Single { slot: u16 }, @@ -97,18 +97,18 @@ impl From<ThrowClick> for ClickOperation { ClickOperation::Throw(click) } } -#[derive(Debug, Clone, Eq, PartialEq)] +#[derive(Clone, Debug, Eq, PartialEq)] pub struct QuickCraftClick { pub kind: QuickCraftKind, pub status: QuickCraftStatus, } -#[derive(Debug, Clone, Eq, PartialEq)] +#[derive(Clone, Debug, Eq, PartialEq)] pub enum QuickCraftKind { Left, Right, Middle, } -#[derive(Debug, Clone, Eq, PartialEq)] +#[derive(Clone, Debug, Eq, PartialEq)] pub enum QuickCraftStatusKind { /// Starting drag Start, @@ -117,7 +117,7 @@ pub enum QuickCraftStatusKind { /// Ending drag End, } -#[derive(Debug, Clone, Eq, PartialEq)] +#[derive(Clone, Debug, Eq, PartialEq)] pub enum QuickCraftStatus { /// Starting drag Start, @@ -137,7 +137,7 @@ impl From<QuickCraftStatus> for QuickCraftStatusKind { } /// Double click. -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub struct PickupAllClick { /// The slot that we're double clicking on. /// diff --git a/azalea-inventory/src/slot.rs b/azalea-inventory/src/slot.rs index e99d34a3..c077812c 100644 --- a/azalea-inventory/src/slot.rs +++ b/azalea-inventory/src/slot.rs @@ -17,7 +17,7 @@ use crate::{ }; /// Either an item in an inventory or nothing. -#[derive(Debug, Clone, Default, PartialEq)] +#[derive(Clone, Debug, Default, PartialEq)] pub enum ItemStack { #[default] Empty, @@ -149,7 +149,7 @@ impl Serialize for ItemStack { /// /// Usually you want [`ItemStack`] or /// [`ItemKind`](azalea_registry::builtin::ItemKind) instead. -#[derive(Debug, Clone, PartialEq, Serialize)] +#[derive(Clone, Debug, PartialEq, Serialize)] pub struct ItemStackData { #[serde(rename = "id")] pub kind: ItemKind, diff --git a/azalea-physics/src/clip.rs b/azalea-physics/src/clip.rs index 625a709e..cabcd2a6 100644 --- a/azalea-physics/src/clip.rs +++ b/azalea-physics/src/clip.rs @@ -16,7 +16,7 @@ use azalea_world::ChunkStorage; use crate::collision::{BlockWithShape, EMPTY_SHAPE, VoxelShape}; -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub struct ClipContext { pub from: Vec3, pub to: Vec3, @@ -58,7 +58,7 @@ impl ClipContext { } } -#[derive(Debug, Copy, Clone)] +#[derive(Clone, Copy, Debug)] pub enum BlockShapeType { /// The shape that's used for collision. Collider, @@ -71,7 +71,7 @@ pub enum BlockShapeType { Visual, FallDamageResetting, } -#[derive(Debug, Copy, Clone)] +#[derive(Clone, Copy, Debug)] pub enum FluidPickType { None, SourceOnly, diff --git a/azalea-physics/src/collision/discrete_voxel_shape.rs b/azalea-physics/src/collision/discrete_voxel_shape.rs index 1d8de4db..a9789684 100644 --- a/azalea-physics/src/collision/discrete_voxel_shape.rs +++ b/azalea-physics/src/collision/discrete_voxel_shape.rs @@ -10,7 +10,7 @@ use super::mergers::IndexMerger; pub trait IntLineConsumer = FnMut(u32, u32, u32, u32, u32, u32); -#[derive(Clone, PartialEq, Eq, Debug)] +#[derive(Clone, Debug, Eq, PartialEq)] pub enum DiscreteVoxelShape { BitSet(BitSetDiscreteVoxelShape), } @@ -77,7 +77,7 @@ impl DiscreteVoxelShape { } } -#[derive(Default, Clone, PartialEq, Eq, Debug)] +#[derive(Clone, Debug, Default, Eq, PartialEq)] pub struct BitSetDiscreteVoxelShape { x_size: u32, y_size: u32, diff --git a/azalea-physics/src/collision/mod.rs b/azalea-physics/src/collision/mod.rs index 6c622d40..f720fdba 100644 --- a/azalea-physics/src/collision/mod.rs +++ b/azalea-physics/src/collision/mod.rs @@ -32,7 +32,7 @@ use crate::{ collision::entity_collisions::AabbQuery, local_player::PhysicsState, travel::no_collision, }; -#[derive(Debug, Clone, Copy, PartialEq, Eq)] +#[derive(Clone, Copy, Debug, Eq, PartialEq)] pub enum MoverType { Own, Player, diff --git a/azalea-physics/src/collision/shape.rs b/azalea-physics/src/collision/shape.rs index fedc8a79..36dedb85 100644 --- a/azalea-physics/src/collision/shape.rs +++ b/azalea-physics/src/collision/shape.rs @@ -319,7 +319,7 @@ impl Shapes { } } -#[derive(Clone, PartialEq, Debug)] +#[derive(Clone, Debug, PartialEq)] pub enum VoxelShape { Array(ArrayVoxelShape), Cube(CubeVoxelShape), @@ -587,7 +587,7 @@ impl From<Aabb> for VoxelShape { } } -#[derive(Clone, PartialEq, Debug)] +#[derive(Clone, Debug, PartialEq)] pub struct ArrayVoxelShape { shape: DiscreteVoxelShape, // TODO: check where faces is used in minecraft @@ -599,7 +599,7 @@ pub struct ArrayVoxelShape { pub zs: Vec<f64>, } -#[derive(Clone, PartialEq, Debug)] +#[derive(Clone, Debug, PartialEq)] pub struct CubeVoxelShape { shape: DiscreteVoxelShape, // TODO: check where faces is used in minecraft diff --git a/azalea-physics/src/lib.rs b/azalea-physics/src/lib.rs index 663c60db..90c89b16 100644 --- a/azalea-physics/src/lib.rs +++ b/azalea-physics/src/lib.rs @@ -30,7 +30,7 @@ use collision::{BLOCK_SHAPE, BlockWithShape, VoxelShape, move_colliding}; use crate::collision::{MoveCtx, entity_collisions::update_last_bounding_box}; /// A Bevy [`SystemSet`] for running physics that makes entities do things. -#[derive(SystemSet, Debug, Hash, PartialEq, Eq, Clone)] +#[derive(Clone, Debug, Eq, Hash, PartialEq, SystemSet)] pub struct PhysicsSystems; pub struct PhysicsPlugin; diff --git a/azalea-physics/src/local_player.rs b/azalea-physics/src/local_player.rs index f2f213d8..75bbbfb9 100644 --- a/azalea-physics/src/local_player.rs +++ b/azalea-physics/src/local_player.rs @@ -6,7 +6,7 @@ use bevy_ecs::component::Component; /// Usually only present for [`LocalEntity`]s. /// /// [`LocalEntity`]: azalea_entity::LocalEntity -#[derive(Default, Component, Clone)] +#[derive(Clone, Component, Default)] pub struct PhysicsState { /// Minecraft only sends a movement packet either after 20 ticks or if the /// player moved enough. This is that tick counter. @@ -35,7 +35,7 @@ pub struct PhysicsState { /// A direction that a player can walk in, including none. /// /// Superset of [`SprintDirection`]. -#[derive(Clone, Copy, Debug, Default, PartialEq, Eq)] +#[derive(Clone, Copy, Debug, Default, Eq, PartialEq)] pub enum WalkDirection { #[default] None, diff --git a/azalea-protocol/src/address.rs b/azalea-protocol/src/address.rs index 569e2488..42ee2ac4 100644 --- a/azalea-protocol/src/address.rs +++ b/azalea-protocol/src/address.rs @@ -51,7 +51,7 @@ impl ResolvableAddr for &ResolvedAddr { /// assert_eq!(addr.host, "localhost"); /// assert_eq!(addr.port, 25565); /// ``` -#[derive(Debug, Clone, PartialEq, Eq, Hash)] +#[derive(Clone, Debug, Eq, Hash, PartialEq)] pub struct ServerAddr { pub host: String, pub port: u16, @@ -137,7 +137,7 @@ impl serde::Serialize for ServerAddr { } /// An address that may be used to connect to a Minecraft server. -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub struct ResolvedAddr { /// The initial address that we passed when trying to connect. /// diff --git a/azalea-protocol/src/common/client_information.rs b/azalea-protocol/src/common/client_information.rs index c5024a52..68a9956a 100644 --- a/azalea-protocol/src/common/client_information.rs +++ b/azalea-protocol/src/common/client_information.rs @@ -9,7 +9,7 @@ use bevy_ecs::component::Component; /// sent to the server, such as render distance. /// /// This is only present on local players. -#[derive(Clone, Debug, AzBuf, PartialEq, Eq, Component)] +#[derive(AzBuf, Clone, Component, Debug, Eq, PartialEq)] pub struct ClientInformation { /// The locale of the client, formatted like "en_us". pub language: String, @@ -49,7 +49,7 @@ impl Default for ClientInformation { } } -#[derive(AzBuf, Clone, Copy, Debug, PartialEq, Eq, Default)] +#[derive(AzBuf, Clone, Copy, Debug, Default, Eq, PartialEq)] pub enum ChatVisibility { /// All chat messages should be sent to the client. #[default] @@ -61,7 +61,7 @@ pub enum ChatVisibility { Hidden = 2, } -#[derive(Clone, Copy, Debug, PartialEq, Eq)] +#[derive(Clone, Copy, Debug, Eq, PartialEq)] pub struct ModelCustomization { pub cape: bool, pub jacket: bool, @@ -72,7 +72,7 @@ pub struct ModelCustomization { pub hat: bool, } -#[derive(AzBuf, Clone, Copy, Debug, PartialEq, Eq, Default)] +#[derive(AzBuf, Clone, Copy, Debug, Default, Eq, PartialEq)] pub enum ParticleStatus { #[default] All, diff --git a/azalea-protocol/src/common/debug_subscription.rs b/azalea-protocol/src/common/debug_subscription.rs index 0be792e1..068b456c 100644 --- a/azalea-protocol/src/common/debug_subscription.rs +++ b/azalea-protocol/src/common/debug_subscription.rs @@ -8,11 +8,11 @@ use azalea_registry::builtin::{BlockKind, DebugSubscription, GameEvent, PointOfI macro_rules! debug_subscription_enum { ($($variant:ident($ty:ty),)*) => { - #[derive(Clone, Debug, AzBuf, PartialEq)] + #[derive(AzBuf, Clone, Debug, PartialEq)] pub enum DebugSubscriptionEvent { $( $variant($ty), )* } - #[derive(Clone, Debug, AzBuf, PartialEq)] + #[derive(AzBuf, Clone, Debug, PartialEq)] pub enum DebugSubscriptionUpdate { $( $variant(Option<$ty>), )* } @@ -62,7 +62,7 @@ debug_subscription_enum! { GameEvents(DebugGameEventInfo), } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct DebugBeeInfo { pub hive_pos: Option<BlockPos>, pub flower_pos: Option<BlockPos>, @@ -70,7 +70,7 @@ pub struct DebugBeeInfo { pub travel_ticks: i32, pub blacklisted_hives: Vec<BlockPos>, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct DebugBrainDump { pub name: String, pub profession: String, @@ -88,14 +88,14 @@ pub struct DebugBrainDump { pub potential_pois: Vec<BlockPos>, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct DebugBreezeInfo { #[var] pub attack_target: Option<i32>, pub jump_target: Option<BlockPos>, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct DebugGoalInfo { #[var] pub priority: i32, @@ -104,20 +104,20 @@ pub struct DebugGoalInfo { pub name: String, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct DebugPathInfo { pub path: MinecraftPath, pub max_node_distance: f32, } -#[derive(Clone, Copy, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq)] pub enum DebugEntityBlockIntersection { InBlock, InFluid, InAir, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct DebugHiveInfo { pub kind: BlockKind, #[var] @@ -127,7 +127,7 @@ pub struct DebugHiveInfo { pub sedated: bool, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct DebugPoiInfo { pub pos: BlockPos, pub poi_kind: PointOfInterestKind, @@ -135,43 +135,43 @@ pub struct DebugPoiInfo { pub free_ticket_count: i32, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct DebugRedstoneOrientation { #[var] pub id: u32, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct DebugStructureInfo { pub bounding_box: StructureBoundingBox, pub pieces: Vec<StructurePiece>, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct DebugGameEventListenerInfo { #[var] pub listener_radius: i32, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct DebugGameEventInfo { pub event: GameEvent, pub pos: Vec3, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct StructureBoundingBox { pub min: BlockPos, pub max: BlockPos, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct StructurePiece { pub bounding_box: StructureBoundingBox, pub is_start: bool, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct MinecraftPath { pub reached: bool, pub next_node_index: i32, @@ -180,7 +180,7 @@ pub struct MinecraftPath { pub debug_data: MinecraftPathDebugData, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct MinecraftPathNode { pub x: i32, pub y: i32, @@ -188,7 +188,7 @@ pub struct MinecraftPathNode { pub contents: MinecraftPathNodeContents, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct MinecraftPathNodeContents { pub walked_distance: f32, pub cost_malus: f32, @@ -198,7 +198,7 @@ pub struct MinecraftPathNodeContents { } // PathType.java -#[derive(Clone, Copy, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq)] pub enum MinecraftPathNodeKind { Blocked, Open, @@ -228,7 +228,7 @@ pub enum MinecraftPathNodeKind { DangerTrapdoor, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct MinecraftPathDebugData { pub target_nodes: Vec<MinecraftPathNode>, pub open_set: Vec<MinecraftPathNode>, diff --git a/azalea-protocol/src/common/movements.rs b/azalea-protocol/src/common/movements.rs index e7b71a2e..82559f86 100644 --- a/azalea-protocol/src/common/movements.rs +++ b/azalea-protocol/src/common/movements.rs @@ -19,7 +19,7 @@ pub struct PositionMoveRotation { pub look_direction: LookDirection, } -#[derive(Debug, Clone, Default, PartialEq)] +#[derive(Clone, Debug, Default, PartialEq)] pub struct RelativeMovements { pub x: bool, pub y: bool, diff --git a/azalea-protocol/src/common/recipe.rs b/azalea-protocol/src/common/recipe.rs index 43a64469..9a59cc4b 100644 --- a/azalea-protocol/src/common/recipe.rs +++ b/azalea-protocol/src/common/recipe.rs @@ -3,7 +3,7 @@ use azalea_inventory::ItemStack; use azalea_registry::{HolderSet, builtin::ItemKind, identifier::Identifier}; /// [`azalea_registry::RecipeDisplay`] -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub enum RecipeDisplayData { Shapeless(ShapelessCraftingRecipeDisplay), Shaped(ShapedCraftingRecipeDisplay), @@ -12,13 +12,13 @@ pub enum RecipeDisplayData { Smithing(SmithingRecipeDisplay), } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct ShapelessCraftingRecipeDisplay { pub ingredients: Vec<SlotDisplayData>, pub result: SlotDisplayData, pub crafting_station: SlotDisplayData, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct ShapedCraftingRecipeDisplay { #[var] pub width: u32, @@ -28,7 +28,7 @@ pub struct ShapedCraftingRecipeDisplay { pub result: SlotDisplayData, pub crafting_station: SlotDisplayData, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct FurnaceRecipeDisplay { pub ingredient: SlotDisplayData, pub fuel: SlotDisplayData, @@ -38,13 +38,13 @@ pub struct FurnaceRecipeDisplay { pub duration: u32, pub experience: f32, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct StonecutterRecipeDisplay { pub input: SlotDisplayData, pub result: SlotDisplayData, pub crafting_station: SlotDisplayData, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct SmithingRecipeDisplay { pub template: SlotDisplayData, pub base: SlotDisplayData, @@ -53,13 +53,13 @@ pub struct SmithingRecipeDisplay { pub crafting_station: SlotDisplayData, } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct Ingredient { pub allowed: HolderSet<ItemKind, Identifier>, } /// [`azalea_registry::SlotDisplay`] -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub enum SlotDisplayData { Empty, AnyFuel, @@ -71,30 +71,30 @@ pub enum SlotDisplayData { Composite(CompositeSlotDisplay), } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct ItemStackDisplay { pub item: ItemKind, } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct ItemStackSlotDisplay { pub stack: ItemStack, } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct TagSlotDisplay { pub tag: ItemKind, } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct SmithingTrimDemoSlotDisplay { pub base: SlotDisplayData, pub material: SlotDisplayData, pub pattern: SlotDisplayData, } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct WithRemainderSlotDisplay { pub input: SlotDisplayData, pub remainder: SlotDisplayData, } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct CompositeSlotDisplay { pub contents: Vec<SlotDisplayData>, } diff --git a/azalea-protocol/src/common/server_links.rs b/azalea-protocol/src/common/server_links.rs index 34ae43e6..d65d7a89 100644 --- a/azalea-protocol/src/common/server_links.rs +++ b/azalea-protocol/src/common/server_links.rs @@ -1,19 +1,19 @@ use azalea_buf::AzBuf; use azalea_chat::FormattedText; -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct ServerLinkEntry { pub kind: ServerLinkKind, pub link: String, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub enum ServerLinkKind { Component(FormattedText), Known(KnownLinkKind), } -#[derive(Clone, Copy, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq)] pub enum KnownLinkKind { BugReport, CommunityGuidelines, diff --git a/azalea-protocol/src/connect.rs b/azalea-protocol/src/connect.rs index e6a7142d..3559f95e 100644 --- a/azalea-protocol/src/connect.rs +++ b/azalea-protocol/src/connect.rs @@ -269,7 +269,7 @@ where } } -#[derive(Error, Debug)] +#[derive(Debug, Error)] pub enum ConnectionError { #[error("{0}")] Io(#[from] io::Error), @@ -278,7 +278,7 @@ pub enum ConnectionError { use socks5_impl::protocol::UserKey; /// An address and authentication method for connecting to a SOCKS5 proxy. -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub struct Proxy { pub addr: SocketAddr, pub auth: Option<UserKey>, diff --git a/azalea-protocol/src/packets/common.rs b/azalea-protocol/src/packets/common.rs index a6cfc03f..3a5b7bf1 100644 --- a/azalea-protocol/src/packets/common.rs +++ b/azalea-protocol/src/packets/common.rs @@ -8,7 +8,7 @@ use azalea_core::{ use azalea_registry::{data::DimensionKind, identifier::Identifier}; use tracing::error; -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct CommonPlayerSpawnInfo { pub dimension_type: DimensionKind, pub dimension: Identifier, diff --git a/azalea-protocol/src/packets/config/c_clear_dialog.rs b/azalea-protocol/src/packets/config/c_clear_dialog.rs index a4945516..8230efe4 100644 --- a/azalea-protocol/src/packets/config/c_clear_dialog.rs +++ b/azalea-protocol/src/packets/config/c_clear_dialog.rs @@ -1,5 +1,5 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundClearDialog; diff --git a/azalea-protocol/src/packets/config/c_code_of_conduct.rs b/azalea-protocol/src/packets/config/c_code_of_conduct.rs index 03f133a8..9550a8b9 100644 --- a/azalea-protocol/src/packets/config/c_code_of_conduct.rs +++ b/azalea-protocol/src/packets/config/c_code_of_conduct.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundCodeOfConduct { pub code_of_conduct: String, } diff --git a/azalea-protocol/src/packets/config/c_cookie_request.rs b/azalea-protocol/src/packets/config/c_cookie_request.rs index 0edbf21e..87d7f373 100644 --- a/azalea-protocol/src/packets/config/c_cookie_request.rs +++ b/azalea-protocol/src/packets/config/c_cookie_request.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ClientboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundCookieRequest { pub key: Identifier, } diff --git a/azalea-protocol/src/packets/config/c_custom_payload.rs b/azalea-protocol/src/packets/config/c_custom_payload.rs index c9417dcd..6f4a6d89 100644 --- a/azalea-protocol/src/packets/config/c_custom_payload.rs +++ b/azalea-protocol/src/packets/config/c_custom_payload.rs @@ -2,7 +2,7 @@ use azalea_buf::{AzBuf, UnsizedByteArray}; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ClientboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundCustomPayload { pub identifier: Identifier, pub data: UnsizedByteArray, diff --git a/azalea-protocol/src/packets/config/c_custom_report_details.rs b/azalea-protocol/src/packets/config/c_custom_report_details.rs index 38209dd8..74e04f32 100644 --- a/azalea-protocol/src/packets/config/c_custom_report_details.rs +++ b/azalea-protocol/src/packets/config/c_custom_report_details.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundConfigPacket; use indexmap::IndexMap; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundCustomReportDetails { pub details: IndexMap<String, String>, } diff --git a/azalea-protocol/src/packets/config/c_disconnect.rs b/azalea-protocol/src/packets/config/c_disconnect.rs index 37915b38..c08b1baa 100644 --- a/azalea-protocol/src/packets/config/c_disconnect.rs +++ b/azalea-protocol/src/packets/config/c_disconnect.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_chat::FormattedText; use azalea_protocol_macros::ClientboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundDisconnect { pub reason: FormattedText, } diff --git a/azalea-protocol/src/packets/config/c_finish_configuration.rs b/azalea-protocol/src/packets/config/c_finish_configuration.rs index 2cfe64fd..6ea7aed3 100644 --- a/azalea-protocol/src/packets/config/c_finish_configuration.rs +++ b/azalea-protocol/src/packets/config/c_finish_configuration.rs @@ -1,5 +1,5 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundFinishConfiguration; diff --git a/azalea-protocol/src/packets/config/c_keep_alive.rs b/azalea-protocol/src/packets/config/c_keep_alive.rs index 575ff52e..184e92dd 100644 --- a/azalea-protocol/src/packets/config/c_keep_alive.rs +++ b/azalea-protocol/src/packets/config/c_keep_alive.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundKeepAlive { pub id: u64, } diff --git a/azalea-protocol/src/packets/config/c_ping.rs b/azalea-protocol/src/packets/config/c_ping.rs index 82a83692..123ca907 100644 --- a/azalea-protocol/src/packets/config/c_ping.rs +++ b/azalea-protocol/src/packets/config/c_ping.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundPing { pub id: u32, } diff --git a/azalea-protocol/src/packets/config/c_registry_data.rs b/azalea-protocol/src/packets/config/c_registry_data.rs index cb46958c..edafbcf4 100644 --- a/azalea-protocol/src/packets/config/c_registry_data.rs +++ b/azalea-protocol/src/packets/config/c_registry_data.rs @@ -3,7 +3,7 @@ use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ClientboundConfigPacket; use simdnbt::owned::NbtCompound; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundRegistryData { pub registry_id: Identifier, pub entries: Vec<(Identifier, Option<NbtCompound>)>, diff --git a/azalea-protocol/src/packets/config/c_reset_chat.rs b/azalea-protocol/src/packets/config/c_reset_chat.rs index bd15a79e..612e7309 100644 --- a/azalea-protocol/src/packets/config/c_reset_chat.rs +++ b/azalea-protocol/src/packets/config/c_reset_chat.rs @@ -1,5 +1,5 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundResetChat; diff --git a/azalea-protocol/src/packets/config/c_resource_pack_pop.rs b/azalea-protocol/src/packets/config/c_resource_pack_pop.rs index 2df9f375..c6544b41 100644 --- a/azalea-protocol/src/packets/config/c_resource_pack_pop.rs +++ b/azalea-protocol/src/packets/config/c_resource_pack_pop.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundConfigPacket; use uuid::Uuid; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundResourcePackPop { pub id: Option<Uuid>, } diff --git a/azalea-protocol/src/packets/config/c_resource_pack_push.rs b/azalea-protocol/src/packets/config/c_resource_pack_push.rs index 257cb374..34e09309 100644 --- a/azalea-protocol/src/packets/config/c_resource_pack_push.rs +++ b/azalea-protocol/src/packets/config/c_resource_pack_push.rs @@ -3,7 +3,7 @@ use azalea_chat::FormattedText; use azalea_protocol_macros::ClientboundConfigPacket; use uuid::Uuid; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundResourcePackPush { pub id: Uuid, pub url: String, diff --git a/azalea-protocol/src/packets/config/c_select_known_packs.rs b/azalea-protocol/src/packets/config/c_select_known_packs.rs index c8b17413..5ddaea0e 100644 --- a/azalea-protocol/src/packets/config/c_select_known_packs.rs +++ b/azalea-protocol/src/packets/config/c_select_known_packs.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ClientboundConfigPacket; use super::s_select_known_packs::KnownPack; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundSelectKnownPacks { pub known_packs: Vec<KnownPack>, } diff --git a/azalea-protocol/src/packets/config/c_server_links.rs b/azalea-protocol/src/packets/config/c_server_links.rs index e459e901..f697d953 100644 --- a/azalea-protocol/src/packets/config/c_server_links.rs +++ b/azalea-protocol/src/packets/config/c_server_links.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ClientboundConfigPacket; use crate::common::server_links::ServerLinkEntry; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundServerLinks { pub links: Vec<ServerLinkEntry>, } diff --git a/azalea-protocol/src/packets/config/c_show_dialog.rs b/azalea-protocol/src/packets/config/c_show_dialog.rs index 7d1ad498..d6105ca7 100644 --- a/azalea-protocol/src/packets/config/c_show_dialog.rs +++ b/azalea-protocol/src/packets/config/c_show_dialog.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundConfigPacket; use simdnbt::owned::Nbt; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundShowDialog { pub dialog: Nbt, } diff --git a/azalea-protocol/src/packets/config/c_store_cookie.rs b/azalea-protocol/src/packets/config/c_store_cookie.rs index 1b695b22..ae81ce25 100644 --- a/azalea-protocol/src/packets/config/c_store_cookie.rs +++ b/azalea-protocol/src/packets/config/c_store_cookie.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ClientboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundStoreCookie { pub key: Identifier, pub payload: Vec<u8>, diff --git a/azalea-protocol/src/packets/config/c_transfer.rs b/azalea-protocol/src/packets/config/c_transfer.rs index db0e846a..963137b7 100644 --- a/azalea-protocol/src/packets/config/c_transfer.rs +++ b/azalea-protocol/src/packets/config/c_transfer.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundTransfer { pub host: String, #[var] diff --git a/azalea-protocol/src/packets/config/c_update_enabled_features.rs b/azalea-protocol/src/packets/config/c_update_enabled_features.rs index 0080b65a..9fade41c 100644 --- a/azalea-protocol/src/packets/config/c_update_enabled_features.rs +++ b/azalea-protocol/src/packets/config/c_update_enabled_features.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ClientboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundUpdateEnabledFeatures { pub features: Vec<Identifier>, } diff --git a/azalea-protocol/src/packets/config/c_update_tags.rs b/azalea-protocol/src/packets/config/c_update_tags.rs index 5c306374..6406ebe4 100644 --- a/azalea-protocol/src/packets/config/c_update_tags.rs +++ b/azalea-protocol/src/packets/config/c_update_tags.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ClientboundConfigPacket; use crate::common::tags::TagMap; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundConfigPacket)] +#[derive(AzBuf, ClientboundConfigPacket, Clone, Debug, PartialEq)] pub struct ClientboundUpdateTags { pub tags: TagMap, } diff --git a/azalea-protocol/src/packets/config/s_accept_code_of_conduct.rs b/azalea-protocol/src/packets/config/s_accept_code_of_conduct.rs index c5fea5dd..4e6a6ccd 100644 --- a/azalea-protocol/src/packets/config/s_accept_code_of_conduct.rs +++ b/azalea-protocol/src/packets/config/s_accept_code_of_conduct.rs @@ -1,5 +1,5 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundConfigPacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundConfigPacket)] pub struct ServerboundAcceptCodeOfConduct; diff --git a/azalea-protocol/src/packets/config/s_client_information.rs b/azalea-protocol/src/packets/config/s_client_information.rs index b6ab0f2a..5a2490bb 100644 --- a/azalea-protocol/src/packets/config/s_client_information.rs +++ b/azalea-protocol/src/packets/config/s_client_information.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ServerboundConfigPacket; use crate::common::client_information::ClientInformation; -#[derive(Clone, Debug, AzBuf, PartialEq, Eq, ServerboundConfigPacket)] +#[derive(AzBuf, Clone, Debug, Eq, PartialEq, ServerboundConfigPacket)] pub struct ServerboundClientInformation { pub information: ClientInformation, } diff --git a/azalea-protocol/src/packets/config/s_cookie_response.rs b/azalea-protocol/src/packets/config/s_cookie_response.rs index 44f74150..29bf00da 100644 --- a/azalea-protocol/src/packets/config/s_cookie_response.rs +++ b/azalea-protocol/src/packets/config/s_cookie_response.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ServerboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundConfigPacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundConfigPacket)] pub struct ServerboundCookieResponse { pub key: Identifier, pub payload: Option<Vec<u8>>, diff --git a/azalea-protocol/src/packets/config/s_custom_click_action.rs b/azalea-protocol/src/packets/config/s_custom_click_action.rs index c36c2080..45d14013 100644 --- a/azalea-protocol/src/packets/config/s_custom_click_action.rs +++ b/azalea-protocol/src/packets/config/s_custom_click_action.rs @@ -3,7 +3,7 @@ use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ServerboundConfigPacket; use simdnbt::owned::Nbt; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundConfigPacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundConfigPacket)] pub struct ServerboundCustomClickAction { pub id: Identifier, pub payload: Nbt, diff --git a/azalea-protocol/src/packets/config/s_custom_payload.rs b/azalea-protocol/src/packets/config/s_custom_payload.rs index e602bdca..bd127e17 100644 --- a/azalea-protocol/src/packets/config/s_custom_payload.rs +++ b/azalea-protocol/src/packets/config/s_custom_payload.rs @@ -2,7 +2,7 @@ use azalea_buf::{AzBuf, UnsizedByteArray}; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ServerboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundConfigPacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundConfigPacket)] pub struct ServerboundCustomPayload { pub identifier: Identifier, pub data: UnsizedByteArray, diff --git a/azalea-protocol/src/packets/config/s_finish_configuration.rs b/azalea-protocol/src/packets/config/s_finish_configuration.rs index 618d7205..1f581725 100644 --- a/azalea-protocol/src/packets/config/s_finish_configuration.rs +++ b/azalea-protocol/src/packets/config/s_finish_configuration.rs @@ -1,5 +1,5 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundConfigPacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundConfigPacket)] pub struct ServerboundFinishConfiguration; diff --git a/azalea-protocol/src/packets/config/s_keep_alive.rs b/azalea-protocol/src/packets/config/s_keep_alive.rs index 455d4109..5cd414d1 100644 --- a/azalea-protocol/src/packets/config/s_keep_alive.rs +++ b/azalea-protocol/src/packets/config/s_keep_alive.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundConfigPacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundConfigPacket)] pub struct ServerboundKeepAlive { pub id: u64, } diff --git a/azalea-protocol/src/packets/config/s_pong.rs b/azalea-protocol/src/packets/config/s_pong.rs index 58abaff4..0618ce46 100644 --- a/azalea-protocol/src/packets/config/s_pong.rs +++ b/azalea-protocol/src/packets/config/s_pong.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundConfigPacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundConfigPacket)] pub struct ServerboundPong { pub id: u32, } diff --git a/azalea-protocol/src/packets/config/s_resource_pack.rs b/azalea-protocol/src/packets/config/s_resource_pack.rs index 38a14af8..ed316a13 100644 --- a/azalea-protocol/src/packets/config/s_resource_pack.rs +++ b/azalea-protocol/src/packets/config/s_resource_pack.rs @@ -2,13 +2,13 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundConfigPacket; use uuid::Uuid; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundConfigPacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundConfigPacket)] pub struct ServerboundResourcePack { pub id: Uuid, pub action: Action, } -#[derive(AzBuf, Clone, Copy, Debug, PartialEq, Eq)] +#[derive(AzBuf, Clone, Copy, Debug, Eq, PartialEq)] pub enum Action { SuccessfullyLoaded = 0, Declined = 1, diff --git a/azalea-protocol/src/packets/config/s_select_known_packs.rs b/azalea-protocol/src/packets/config/s_select_known_packs.rs index ee139780..0286b6e2 100644 --- a/azalea-protocol/src/packets/config/s_select_known_packs.rs +++ b/azalea-protocol/src/packets/config/s_select_known_packs.rs @@ -1,12 +1,12 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundConfigPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundConfigPacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundConfigPacket)] pub struct ServerboundSelectKnownPacks { pub known_packs: Vec<KnownPack>, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct KnownPack { pub namespace: String, pub id: String, diff --git a/azalea-protocol/src/packets/game/c_add_entity.rs b/azalea-protocol/src/packets/game/c_add_entity.rs index e7b46750..dc04d078 100644 --- a/azalea-protocol/src/packets/game/c_add_entity.rs +++ b/azalea-protocol/src/packets/game/c_add_entity.rs @@ -6,7 +6,7 @@ use azalea_registry::{builtin::EntityKind, identifier::Identifier}; use azalea_world::MinecraftEntityId; use uuid::Uuid; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundAddEntity { /// The numeric ID of the entity being added to the world. #[var] diff --git a/azalea-protocol/src/packets/game/c_animate.rs b/azalea-protocol/src/packets/game/c_animate.rs index b443513c..112b990b 100644 --- a/azalea-protocol/src/packets/game/c_animate.rs +++ b/azalea-protocol/src/packets/game/c_animate.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundAnimate { #[var] pub id: MinecraftEntityId, @@ -11,7 +11,7 @@ pub struct ClientboundAnimate { // minecraft actually uses a u8 for this, but a varint still works and makes it // so i don't have to add a special handler -#[derive(Clone, Debug, Copy, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq)] pub enum AnimationAction { SwingMainHand = 0, Hurt = 1, diff --git a/azalea-protocol/src/packets/game/c_award_stats.rs b/azalea-protocol/src/packets/game/c_award_stats.rs index 79a00f7b..3a736d68 100644 --- a/azalea-protocol/src/packets/game/c_award_stats.rs +++ b/azalea-protocol/src/packets/game/c_award_stats.rs @@ -4,13 +4,13 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use azalea_registry::builtin::{BlockKind, CustomStat, EntityKind, ItemKind}; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundAwardStats { #[var] pub stats: HashMap<Stat, i32>, } -#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, AzBuf)] +#[derive(AzBuf, Clone, Copy, Debug, Eq, Hash, PartialEq)] pub enum Stat { Mined(BlockKind), Crafted(ItemKind), diff --git a/azalea-protocol/src/packets/game/c_block_changed_ack.rs b/azalea-protocol/src/packets/game/c_block_changed_ack.rs index 10a33e3c..381ec3c7 100644 --- a/azalea-protocol/src/packets/game/c_block_changed_ack.rs +++ b/azalea-protocol/src/packets/game/c_block_changed_ack.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundBlockChangedAck { #[var] pub seq: u32, diff --git a/azalea-protocol/src/packets/game/c_block_destruction.rs b/azalea-protocol/src/packets/game/c_block_destruction.rs index 86d238d6..e41e42b0 100644 --- a/azalea-protocol/src/packets/game/c_block_destruction.rs +++ b/azalea-protocol/src/packets/game/c_block_destruction.rs @@ -3,7 +3,7 @@ use azalea_core::position::BlockPos; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundBlockDestruction { /// The ID of the entity breaking the block. #[var] diff --git a/azalea-protocol/src/packets/game/c_block_entity_data.rs b/azalea-protocol/src/packets/game/c_block_entity_data.rs index 0798e2bd..7e3787c9 100644 --- a/azalea-protocol/src/packets/game/c_block_entity_data.rs +++ b/azalea-protocol/src/packets/game/c_block_entity_data.rs @@ -4,7 +4,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use azalea_registry::builtin::BlockEntityKind; use simdnbt::owned::Nbt; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundBlockEntityData { pub pos: BlockPos, pub block_entity_type: BlockEntityKind, diff --git a/azalea-protocol/src/packets/game/c_block_event.rs b/azalea-protocol/src/packets/game/c_block_event.rs index 30bb8e6c..4053e083 100644 --- a/azalea-protocol/src/packets/game/c_block_event.rs +++ b/azalea-protocol/src/packets/game/c_block_event.rs @@ -3,7 +3,7 @@ use azalea_core::position::BlockPos; use azalea_protocol_macros::ClientboundGamePacket; use azalea_registry::builtin::BlockKind; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundBlockEvent { pub pos: BlockPos, pub action_id: u8, diff --git a/azalea-protocol/src/packets/game/c_block_update.rs b/azalea-protocol/src/packets/game/c_block_update.rs index dc193719..35a6c051 100644 --- a/azalea-protocol/src/packets/game/c_block_update.rs +++ b/azalea-protocol/src/packets/game/c_block_update.rs @@ -3,7 +3,7 @@ use azalea_buf::AzBuf; use azalea_core::position::BlockPos; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundBlockUpdate { pub pos: BlockPos, pub block_state: BlockState, diff --git a/azalea-protocol/src/packets/game/c_boss_event.rs b/azalea-protocol/src/packets/game/c_boss_event.rs index de0629e0..10cf30d4 100644 --- a/azalea-protocol/src/packets/game/c_boss_event.rs +++ b/azalea-protocol/src/packets/game/c_boss_event.rs @@ -9,7 +9,7 @@ use azalea_core::bitset::FixedBitSet; use azalea_protocol_macros::ClientboundGamePacket; use uuid::Uuid; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundBossEvent { pub id: Uuid, pub operation: Operation, @@ -75,7 +75,7 @@ impl AzaleaWrite for Operation { } } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct AddOperation { pub name: FormattedText, pub progress: f32, @@ -83,7 +83,7 @@ pub struct AddOperation { pub properties: Properties, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct Style { pub color: BossBarColor, pub overlay: BossBarOverlay, diff --git a/azalea-protocol/src/packets/game/c_bundle_delimiter.rs b/azalea-protocol/src/packets/game/c_bundle_delimiter.rs index ac98e82a..2bba3cfe 100644 --- a/azalea-protocol/src/packets/game/c_bundle_delimiter.rs +++ b/azalea-protocol/src/packets/game/c_bundle_delimiter.rs @@ -1,5 +1,5 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundBundleDelimiter; diff --git a/azalea-protocol/src/packets/game/c_change_difficulty.rs b/azalea-protocol/src/packets/game/c_change_difficulty.rs index 89e2d09a..d4af22ce 100644 --- a/azalea-protocol/src/packets/game/c_change_difficulty.rs +++ b/azalea-protocol/src/packets/game/c_change_difficulty.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_core::difficulty::Difficulty; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundChangeDifficulty { pub difficulty: Difficulty, pub locked: bool, diff --git a/azalea-protocol/src/packets/game/c_chunk_batch_finished.rs b/azalea-protocol/src/packets/game/c_chunk_batch_finished.rs index 6147867b..f527b47f 100644 --- a/azalea-protocol/src/packets/game/c_chunk_batch_finished.rs +++ b/azalea-protocol/src/packets/game/c_chunk_batch_finished.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundChunkBatchFinished { #[var] pub batch_size: u32, diff --git a/azalea-protocol/src/packets/game/c_chunk_batch_start.rs b/azalea-protocol/src/packets/game/c_chunk_batch_start.rs index 9321447b..e4025dcc 100644 --- a/azalea-protocol/src/packets/game/c_chunk_batch_start.rs +++ b/azalea-protocol/src/packets/game/c_chunk_batch_start.rs @@ -1,5 +1,5 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundChunkBatchStart; diff --git a/azalea-protocol/src/packets/game/c_chunks_biomes.rs b/azalea-protocol/src/packets/game/c_chunks_biomes.rs index 16007331..8a1e28b6 100644 --- a/azalea-protocol/src/packets/game/c_chunks_biomes.rs +++ b/azalea-protocol/src/packets/game/c_chunks_biomes.rs @@ -2,12 +2,12 @@ use azalea_buf::AzBuf; use azalea_core::position::ChunkPos; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundChunksBiomes { pub chunk_biome_data: Vec<ChunkBiomeData>, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct ChunkBiomeData { pub pos: ChunkPos, pub buffer: Vec<u8>, diff --git a/azalea-protocol/src/packets/game/c_clear_dialog.rs b/azalea-protocol/src/packets/game/c_clear_dialog.rs index 74a015a4..173b847f 100644 --- a/azalea-protocol/src/packets/game/c_clear_dialog.rs +++ b/azalea-protocol/src/packets/game/c_clear_dialog.rs @@ -1,5 +1,5 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundClearDialog; diff --git a/azalea-protocol/src/packets/game/c_clear_titles.rs b/azalea-protocol/src/packets/game/c_clear_titles.rs index 559f837f..fcf6cede 100644 --- a/azalea-protocol/src/packets/game/c_clear_titles.rs +++ b/azalea-protocol/src/packets/game/c_clear_titles.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundClearTitles { pub reset_times: bool, } diff --git a/azalea-protocol/src/packets/game/c_command_suggestions.rs b/azalea-protocol/src/packets/game/c_command_suggestions.rs index eff953ee..a0036edf 100644 --- a/azalea-protocol/src/packets/game/c_command_suggestions.rs +++ b/azalea-protocol/src/packets/game/c_command_suggestions.rs @@ -2,7 +2,7 @@ use azalea_brigadier::suggestion::Suggestions; use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundCommandSuggestions { #[var] pub id: u32, diff --git a/azalea-protocol/src/packets/game/c_commands.rs b/azalea-protocol/src/packets/game/c_commands.rs index 758c8f27..f8d95ac9 100644 --- a/azalea-protocol/src/packets/game/c_commands.rs +++ b/azalea-protocol/src/packets/game/c_commands.rs @@ -6,14 +6,14 @@ use azalea_protocol_macros::ClientboundGamePacket; use azalea_registry::identifier::Identifier; use tracing::warn; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundCommands { pub entries: Vec<BrigadierNodeStub>, #[var] pub root_index: u32, } -#[derive(Debug, Clone, PartialEq)] +#[derive(Clone, Debug, PartialEq)] pub struct BrigadierNodeStub { pub is_executable: bool, pub children: Vec<u32>, @@ -22,7 +22,7 @@ pub struct BrigadierNodeStub { pub is_restricted: bool, } -#[derive(Debug, Clone, Eq)] +#[derive(Clone, Debug, Eq)] pub struct BrigadierNumber<T> { pub min: Option<T>, pub max: Option<T>, @@ -82,7 +82,7 @@ impl<T: AzaleaWrite> AzaleaWrite for BrigadierNumber<T> { } } -#[derive(Debug, Clone, Copy, AzBuf, PartialEq, Eq)] +#[derive(AzBuf, Clone, Copy, Debug, Eq, PartialEq)] pub enum BrigadierString { /// Reads a single word SingleWord = 0, @@ -94,7 +94,7 @@ pub enum BrigadierString { } // see ArgumentTypeInfos.java -#[derive(Debug, Clone, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub enum BrigadierParser { Bool, Float(BrigadierNumber<f32>), @@ -155,7 +155,7 @@ pub enum BrigadierParser { Uuid, } -#[derive(Debug, Clone, PartialEq, Eq)] +#[derive(Clone, Debug, Eq, PartialEq)] pub struct EntityParser { pub single: bool, pub players_only: bool, @@ -310,7 +310,7 @@ impl AzaleaWrite for BrigadierNodeStub { } } -#[derive(Debug, Clone, PartialEq)] +#[derive(Clone, Debug, PartialEq)] pub enum NodeType { Root, Literal { diff --git a/azalea-protocol/src/packets/game/c_container_close.rs b/azalea-protocol/src/packets/game/c_container_close.rs index 32cb171f..98c95f3f 100644 --- a/azalea-protocol/src/packets/game/c_container_close.rs +++ b/azalea-protocol/src/packets/game/c_container_close.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundContainerClose { #[var] pub container_id: i32, diff --git a/azalea-protocol/src/packets/game/c_container_set_content.rs b/azalea-protocol/src/packets/game/c_container_set_content.rs index 6048fd83..a97973ee 100644 --- a/azalea-protocol/src/packets/game/c_container_set_content.rs +++ b/azalea-protocol/src/packets/game/c_container_set_content.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_inventory::ItemStack; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundContainerSetContent { #[var] pub container_id: i32, diff --git a/azalea-protocol/src/packets/game/c_container_set_data.rs b/azalea-protocol/src/packets/game/c_container_set_data.rs index 6c7907bb..3ad24df8 100644 --- a/azalea-protocol/src/packets/game/c_container_set_data.rs +++ b/azalea-protocol/src/packets/game/c_container_set_data.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundContainerSetData { #[var] pub container_id: i32, diff --git a/azalea-protocol/src/packets/game/c_container_set_slot.rs b/azalea-protocol/src/packets/game/c_container_set_slot.rs index d00080bb..0c8ba767 100644 --- a/azalea-protocol/src/packets/game/c_container_set_slot.rs +++ b/azalea-protocol/src/packets/game/c_container_set_slot.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_inventory::ItemStack; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundContainerSetSlot { #[var] pub container_id: i32, diff --git a/azalea-protocol/src/packets/game/c_cookie_request.rs b/azalea-protocol/src/packets/game/c_cookie_request.rs index 283b686d..65705f9f 100644 --- a/azalea-protocol/src/packets/game/c_cookie_request.rs +++ b/azalea-protocol/src/packets/game/c_cookie_request.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundCookieRequest { pub key: Identifier, } diff --git a/azalea-protocol/src/packets/game/c_cooldown.rs b/azalea-protocol/src/packets/game/c_cooldown.rs index 398690f4..9f4ba15a 100644 --- a/azalea-protocol/src/packets/game/c_cooldown.rs +++ b/azalea-protocol/src/packets/game/c_cooldown.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use azalea_registry::builtin::ItemKind; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundCooldown { pub item: ItemKind, #[var] diff --git a/azalea-protocol/src/packets/game/c_custom_chat_completions.rs b/azalea-protocol/src/packets/game/c_custom_chat_completions.rs index 8a96504d..62afdd6a 100644 --- a/azalea-protocol/src/packets/game/c_custom_chat_completions.rs +++ b/azalea-protocol/src/packets/game/c_custom_chat_completions.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundCustomChatCompletions { pub action: Action, pub entries: Vec<String>, diff --git a/azalea-protocol/src/packets/game/c_custom_payload.rs b/azalea-protocol/src/packets/game/c_custom_payload.rs index a198c547..5d807dd9 100644 --- a/azalea-protocol/src/packets/game/c_custom_payload.rs +++ b/azalea-protocol/src/packets/game/c_custom_payload.rs @@ -2,7 +2,7 @@ use azalea_buf::{AzBuf, UnsizedByteArray}; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundCustomPayload { pub identifier: Identifier, pub data: UnsizedByteArray, diff --git a/azalea-protocol/src/packets/game/c_custom_report_details.rs b/azalea-protocol/src/packets/game/c_custom_report_details.rs index cb7e6c9a..8ac45a57 100644 --- a/azalea-protocol/src/packets/game/c_custom_report_details.rs +++ b/azalea-protocol/src/packets/game/c_custom_report_details.rs @@ -3,7 +3,7 @@ use std::collections::HashMap; use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundCustomReportDetails { // azalea doesn't implement max lengths yet diff --git a/azalea-protocol/src/packets/game/c_damage_event.rs b/azalea-protocol/src/packets/game/c_damage_event.rs index f6a1e401..e296b3da 100644 --- a/azalea-protocol/src/packets/game/c_damage_event.rs +++ b/azalea-protocol/src/packets/game/c_damage_event.rs @@ -5,7 +5,7 @@ use azalea_core::position::Vec3; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundDamageEvent { #[var] pub entity_id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_debug_block_value.rs b/azalea-protocol/src/packets/game/c_debug_block_value.rs index 1c78b6d5..5276ef48 100644 --- a/azalea-protocol/src/packets/game/c_debug_block_value.rs +++ b/azalea-protocol/src/packets/game/c_debug_block_value.rs @@ -4,7 +4,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use crate::common::debug_subscription::DebugSubscriptionUpdate; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundDebugBlockValue { pub block_pos: BlockPos, pub update: DebugSubscriptionUpdate, diff --git a/azalea-protocol/src/packets/game/c_debug_chunk_value.rs b/azalea-protocol/src/packets/game/c_debug_chunk_value.rs index 7948c733..4d118949 100644 --- a/azalea-protocol/src/packets/game/c_debug_chunk_value.rs +++ b/azalea-protocol/src/packets/game/c_debug_chunk_value.rs @@ -4,7 +4,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use crate::common::debug_subscription::DebugSubscriptionUpdate; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundDebugChunkValue { pub chunk_pos: ChunkPos, pub update: DebugSubscriptionUpdate, diff --git a/azalea-protocol/src/packets/game/c_debug_entity_value.rs b/azalea-protocol/src/packets/game/c_debug_entity_value.rs index a57e5548..61706382 100644 --- a/azalea-protocol/src/packets/game/c_debug_entity_value.rs +++ b/azalea-protocol/src/packets/game/c_debug_entity_value.rs @@ -4,7 +4,7 @@ use azalea_world::MinecraftEntityId; use crate::common::debug_subscription::DebugSubscriptionUpdate; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundDebugEntityValue { pub entity_id: MinecraftEntityId, pub update: DebugSubscriptionUpdate, diff --git a/azalea-protocol/src/packets/game/c_debug_event.rs b/azalea-protocol/src/packets/game/c_debug_event.rs index c53e5e12..6068be20 100644 --- a/azalea-protocol/src/packets/game/c_debug_event.rs +++ b/azalea-protocol/src/packets/game/c_debug_event.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use crate::common::debug_subscription::DebugSubscriptionEvent; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundDebugEvent { pub event: DebugSubscriptionEvent, } diff --git a/azalea-protocol/src/packets/game/c_debug_sample.rs b/azalea-protocol/src/packets/game/c_debug_sample.rs index 67769b1b..0f2a9af4 100644 --- a/azalea-protocol/src/packets/game/c_debug_sample.rs +++ b/azalea-protocol/src/packets/game/c_debug_sample.rs @@ -1,13 +1,13 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundDebugSample { pub sample: Vec<u64>, pub debug_sample_type: RemoteDebugSampleType, } -#[derive(Clone, Copy, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq)] pub enum RemoteDebugSampleType { TickTime, } diff --git a/azalea-protocol/src/packets/game/c_delete_chat.rs b/azalea-protocol/src/packets/game/c_delete_chat.rs index fff8daa4..379716c8 100644 --- a/azalea-protocol/src/packets/game/c_delete_chat.rs +++ b/azalea-protocol/src/packets/game/c_delete_chat.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use super::c_player_chat::PackedMessageSignature; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundDeleteChat { pub signature: PackedMessageSignature, } diff --git a/azalea-protocol/src/packets/game/c_disconnect.rs b/azalea-protocol/src/packets/game/c_disconnect.rs index 3cf21291..585dfba3 100644 --- a/azalea-protocol/src/packets/game/c_disconnect.rs +++ b/azalea-protocol/src/packets/game/c_disconnect.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_chat::FormattedText; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundDisconnect { pub reason: FormattedText, } diff --git a/azalea-protocol/src/packets/game/c_disguised_chat.rs b/azalea-protocol/src/packets/game/c_disguised_chat.rs index 31cdc0c6..f83107ef 100644 --- a/azalea-protocol/src/packets/game/c_disguised_chat.rs +++ b/azalea-protocol/src/packets/game/c_disguised_chat.rs @@ -13,7 +13,7 @@ use crate::packets::game::c_player_chat::GUESSED_DEFAULT_REGISTRIES_FOR_CHAT; /// without chat signing. /// /// Vanilla servers use this packet when messages are sent from the console. -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundDisguisedChat { pub message: FormattedText, pub chat_type: ChatTypeBound, diff --git a/azalea-protocol/src/packets/game/c_entity_event.rs b/azalea-protocol/src/packets/game/c_entity_event.rs index 762841a2..cde6fd6c 100644 --- a/azalea-protocol/src/packets/game/c_entity_event.rs +++ b/azalea-protocol/src/packets/game/c_entity_event.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundEntityEvent { pub entity_id: MinecraftEntityId, pub event_id: u8, diff --git a/azalea-protocol/src/packets/game/c_entity_position_sync.rs b/azalea-protocol/src/packets/game/c_entity_position_sync.rs index a48830ac..b18248fc 100644 --- a/azalea-protocol/src/packets/game/c_entity_position_sync.rs +++ b/azalea-protocol/src/packets/game/c_entity_position_sync.rs @@ -4,7 +4,7 @@ use azalea_world::MinecraftEntityId; use crate::common::movements::PositionMoveRotation; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundEntityPositionSync { #[var] pub id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_explode.rs b/azalea-protocol/src/packets/game/c_explode.rs index e8744b79..2c934c31 100644 --- a/azalea-protocol/src/packets/game/c_explode.rs +++ b/azalea-protocol/src/packets/game/c_explode.rs @@ -4,7 +4,7 @@ use azalea_entity::particle::Particle; use azalea_protocol_macros::ClientboundGamePacket; use azalea_registry::builtin::SoundEvent; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundExplode { pub center: Vec3, pub radius: f32, @@ -15,7 +15,7 @@ pub struct ClientboundExplode { pub block_particles: Vec<ExplosionParticleInfo>, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct ExplosionParticleInfo { pub particle: Particle, pub scaling: f32, diff --git a/azalea-protocol/src/packets/game/c_forget_level_chunk.rs b/azalea-protocol/src/packets/game/c_forget_level_chunk.rs index 41a89f9a..dbc5d9b8 100644 --- a/azalea-protocol/src/packets/game/c_forget_level_chunk.rs +++ b/azalea-protocol/src/packets/game/c_forget_level_chunk.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_core::position::ChunkPos; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundForgetLevelChunk { pub pos: ChunkPos, } diff --git a/azalea-protocol/src/packets/game/c_game_event.rs b/azalea-protocol/src/packets/game/c_game_event.rs index f04a18fe..3081421c 100644 --- a/azalea-protocol/src/packets/game/c_game_event.rs +++ b/azalea-protocol/src/packets/game/c_game_event.rs @@ -1,13 +1,13 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundGameEvent { pub event: EventType, pub param: f32, } -#[derive(Clone, Debug, Copy, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq)] pub enum EventType { NoRespawnBlockAvailable = 0, StartRaining = 1, diff --git a/azalea-protocol/src/packets/game/c_game_test_highlight_pos.rs b/azalea-protocol/src/packets/game/c_game_test_highlight_pos.rs index c7c117df..c61045e3 100644 --- a/azalea-protocol/src/packets/game/c_game_test_highlight_pos.rs +++ b/azalea-protocol/src/packets/game/c_game_test_highlight_pos.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_core::position::BlockPos; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundGameTestHighlightPos { pub absolute_pos: BlockPos, pub relative_pos: BlockPos, diff --git a/azalea-protocol/src/packets/game/c_hurt_animation.rs b/azalea-protocol/src/packets/game/c_hurt_animation.rs index 631eb402..698176e4 100644 --- a/azalea-protocol/src/packets/game/c_hurt_animation.rs +++ b/azalea-protocol/src/packets/game/c_hurt_animation.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundHurtAnimation { #[var] pub id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_initialize_border.rs b/azalea-protocol/src/packets/game/c_initialize_border.rs index 48c5ed30..768dc2a6 100644 --- a/azalea-protocol/src/packets/game/c_initialize_border.rs +++ b/azalea-protocol/src/packets/game/c_initialize_border.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundInitializeBorder { pub new_center_x: f64, pub new_center_z: f64, diff --git a/azalea-protocol/src/packets/game/c_keep_alive.rs b/azalea-protocol/src/packets/game/c_keep_alive.rs index ba58c711..fc380265 100644 --- a/azalea-protocol/src/packets/game/c_keep_alive.rs +++ b/azalea-protocol/src/packets/game/c_keep_alive.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundKeepAlive { pub id: u64, } diff --git a/azalea-protocol/src/packets/game/c_level_chunk_with_light.rs b/azalea-protocol/src/packets/game/c_level_chunk_with_light.rs index d9d1097f..6519c4a4 100644 --- a/azalea-protocol/src/packets/game/c_level_chunk_with_light.rs +++ b/azalea-protocol/src/packets/game/c_level_chunk_with_light.rs @@ -8,7 +8,7 @@ use simdnbt::owned::Nbt; use super::c_light_update::ClientboundLightUpdatePacketData; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundLevelChunkWithLight { // this can't be a ChunkPos since that reads z first and then x pub x: i32, @@ -17,7 +17,7 @@ pub struct ClientboundLevelChunkWithLight { pub light_data: ClientboundLightUpdatePacketData, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct ClientboundLevelChunkPacketData { pub heightmaps: Vec<(HeightmapKind, Box<[u64]>)>, /// The raw chunk sections. @@ -31,7 +31,7 @@ pub struct ClientboundLevelChunkPacketData { pub block_entities: Vec<BlockEntity>, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct BlockEntity { pub packed_xz: u8, pub y: u16, diff --git a/azalea-protocol/src/packets/game/c_level_event.rs b/azalea-protocol/src/packets/game/c_level_event.rs index 08284559..3173e4eb 100644 --- a/azalea-protocol/src/packets/game/c_level_event.rs +++ b/azalea-protocol/src/packets/game/c_level_event.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_core::position::BlockPos; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundLevelEvent { pub event_type: u32, pub pos: BlockPos, diff --git a/azalea-protocol/src/packets/game/c_level_particles.rs b/azalea-protocol/src/packets/game/c_level_particles.rs index 8fd05138..67164f28 100644 --- a/azalea-protocol/src/packets/game/c_level_particles.rs +++ b/azalea-protocol/src/packets/game/c_level_particles.rs @@ -3,7 +3,7 @@ use azalea_core::position::Vec3; use azalea_entity::particle::Particle; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundLevelParticles { pub override_limiter: bool, pub always_show: bool, diff --git a/azalea-protocol/src/packets/game/c_light_update.rs b/azalea-protocol/src/packets/game/c_light_update.rs index 46e78fe8..83dbda34 100644 --- a/azalea-protocol/src/packets/game/c_light_update.rs +++ b/azalea-protocol/src/packets/game/c_light_update.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_core::bitset::BitSet; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundLightUpdate { #[var] pub x: i32, @@ -11,7 +11,7 @@ pub struct ClientboundLightUpdate { pub light_data: ClientboundLightUpdatePacketData, } -#[derive(Clone, Debug, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq)] pub struct ClientboundLightUpdatePacketData { pub sky_y_mask: BitSet, pub block_y_mask: BitSet, diff --git a/azalea-protocol/src/packets/game/c_login.rs b/azalea-protocol/src/packets/game/c_login.rs index 9439eec9..ce243a55 100644 --- a/azalea-protocol/src/packets/game/c_login.rs +++ b/azalea-protocol/src/packets/game/c_login.rs @@ -9,7 +9,7 @@ use crate::packets::common::CommonPlayerSpawnInfo; /// /// This packet contains information about the state of the player, the /// world, and the registry. -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundLogin { pub player_id: MinecraftEntityId, pub hardcore: bool, diff --git a/azalea-protocol/src/packets/game/c_map_item_data.rs b/azalea-protocol/src/packets/game/c_map_item_data.rs index eaf5dc9f..2330ce07 100644 --- a/azalea-protocol/src/packets/game/c_map_item_data.rs +++ b/azalea-protocol/src/packets/game/c_map_item_data.rs @@ -4,7 +4,7 @@ use azalea_buf::{AzBuf, AzaleaRead, AzaleaWrite}; use azalea_chat::FormattedText; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundMapItemData { #[var] pub map_id: u32, @@ -14,7 +14,7 @@ pub struct ClientboundMapItemData { pub color_patch: OptionalMapPatch, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct MapDecoration { pub decoration_type: DecorationType, pub x: i8, @@ -25,7 +25,7 @@ pub struct MapDecoration { pub name: Option<FormattedText>, } -#[derive(Debug, Clone, PartialEq)] +#[derive(Clone, Debug, PartialEq)] pub struct OptionalMapPatch(pub Option<MapPatch>); impl AzaleaRead for OptionalMapPatch { @@ -49,7 +49,7 @@ impl AzaleaWrite for OptionalMapPatch { } } -#[derive(Debug, Clone, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct MapPatch { pub width: u8, pub height: u8, @@ -58,7 +58,7 @@ pub struct MapPatch { pub map_colors: Vec<u8>, } -#[derive(Clone, Copy, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq)] pub enum DecorationType { Player, Frame, diff --git a/azalea-protocol/src/packets/game/c_merchant_offers.rs b/azalea-protocol/src/packets/game/c_merchant_offers.rs index 079041f6..7bbf92c4 100644 --- a/azalea-protocol/src/packets/game/c_merchant_offers.rs +++ b/azalea-protocol/src/packets/game/c_merchant_offers.rs @@ -12,7 +12,7 @@ use azalea_inventory::{ use azalea_protocol_macros::ClientboundGamePacket; use azalea_registry::builtin::{DataComponentKind, ItemKind}; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundMerchantOffers { #[var] pub container_id: i32, @@ -25,7 +25,7 @@ pub struct ClientboundMerchantOffers { pub can_restock: bool, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct MerchantOffer { pub base_cost_a: ItemCost, pub result: ItemStack, @@ -43,7 +43,7 @@ pub struct MerchantOffer { /// /// This can be converted into an [`ItemStackData`] with /// [`Self::into_item_stack`]. -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct ItemCost { pub item: ItemKind, #[var] @@ -74,7 +74,7 @@ impl ItemCost { /// /// If you got this from [`ItemCost`], consider using /// [`ItemCost::into_item_stack`] for a better API instead. -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct DataComponentExactPredicate { pub expected: Vec<TypedDataComponent>, } diff --git a/azalea-protocol/src/packets/game/c_mount_screen_open.rs b/azalea-protocol/src/packets/game/c_mount_screen_open.rs index 6669d8c1..78600250 100644 --- a/azalea-protocol/src/packets/game/c_mount_screen_open.rs +++ b/azalea-protocol/src/packets/game/c_mount_screen_open.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundMountScreenOpen { #[var] pub container_id: i32, diff --git a/azalea-protocol/src/packets/game/c_move_entity_pos.rs b/azalea-protocol/src/packets/game/c_move_entity_pos.rs index b3fc81e8..3f4b005a 100644 --- a/azalea-protocol/src/packets/game/c_move_entity_pos.rs +++ b/azalea-protocol/src/packets/game/c_move_entity_pos.rs @@ -3,7 +3,7 @@ use azalea_core::delta::PositionDelta8; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundMoveEntityPos { #[var] pub entity_id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_move_entity_pos_rot.rs b/azalea-protocol/src/packets/game/c_move_entity_pos_rot.rs index 3cdaaab5..81f2a63a 100644 --- a/azalea-protocol/src/packets/game/c_move_entity_pos_rot.rs +++ b/azalea-protocol/src/packets/game/c_move_entity_pos_rot.rs @@ -4,7 +4,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; /// This packet is sent by the server when an entity moves less then 8 blocks. -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundMoveEntityPosRot { #[var] pub entity_id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_move_entity_rot.rs b/azalea-protocol/src/packets/game/c_move_entity_rot.rs index 97f9c9c1..6ccd44fe 100644 --- a/azalea-protocol/src/packets/game/c_move_entity_rot.rs +++ b/azalea-protocol/src/packets/game/c_move_entity_rot.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundMoveEntityRot { #[var] pub entity_id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_move_minecart_along_track.rs b/azalea-protocol/src/packets/game/c_move_minecart_along_track.rs index 31c785ec..61cb5ba8 100644 --- a/azalea-protocol/src/packets/game/c_move_minecart_along_track.rs +++ b/azalea-protocol/src/packets/game/c_move_minecart_along_track.rs @@ -3,14 +3,14 @@ use azalea_core::position::Vec3; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundMoveMinecartAlongTrack { #[var] pub entity_id: MinecraftEntityId, pub lerp_steps: Vec<MinecartStep>, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct MinecartStep { pub position: Vec3, pub movement: Vec3, diff --git a/azalea-protocol/src/packets/game/c_move_vehicle.rs b/azalea-protocol/src/packets/game/c_move_vehicle.rs index 6975f023..85e7114f 100644 --- a/azalea-protocol/src/packets/game/c_move_vehicle.rs +++ b/azalea-protocol/src/packets/game/c_move_vehicle.rs @@ -3,7 +3,7 @@ use azalea_core::position::Vec3; use azalea_entity::LookDirection; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundMoveVehicle { pub pos: Vec3, pub look_direction: LookDirection, diff --git a/azalea-protocol/src/packets/game/c_open_book.rs b/azalea-protocol/src/packets/game/c_open_book.rs index 952ab412..ae55b77b 100644 --- a/azalea-protocol/src/packets/game/c_open_book.rs +++ b/azalea-protocol/src/packets/game/c_open_book.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use super::s_interact::InteractionHand; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundOpenBook { pub hand: InteractionHand, } diff --git a/azalea-protocol/src/packets/game/c_open_screen.rs b/azalea-protocol/src/packets/game/c_open_screen.rs index cac3495f..9db3e7ba 100644 --- a/azalea-protocol/src/packets/game/c_open_screen.rs +++ b/azalea-protocol/src/packets/game/c_open_screen.rs @@ -3,7 +3,7 @@ use azalea_chat::FormattedText; use azalea_protocol_macros::ClientboundGamePacket; use azalea_registry::builtin::MenuKind; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundOpenScreen { #[var] pub container_id: i32, diff --git a/azalea-protocol/src/packets/game/c_open_sign_editor.rs b/azalea-protocol/src/packets/game/c_open_sign_editor.rs index 66ebaece..d6a287ac 100644 --- a/azalea-protocol/src/packets/game/c_open_sign_editor.rs +++ b/azalea-protocol/src/packets/game/c_open_sign_editor.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_core::position::BlockPos; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundOpenSignEditor { pub pos: BlockPos, pub is_front_text: bool, diff --git a/azalea-protocol/src/packets/game/c_ping.rs b/azalea-protocol/src/packets/game/c_ping.rs index e6e3e143..7e1b2a23 100644 --- a/azalea-protocol/src/packets/game/c_ping.rs +++ b/azalea-protocol/src/packets/game/c_ping.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundPing { pub id: u32, } diff --git a/azalea-protocol/src/packets/game/c_place_ghost_recipe.rs b/azalea-protocol/src/packets/game/c_place_ghost_recipe.rs index a0c93962..d4c4a61f 100644 --- a/azalea-protocol/src/packets/game/c_place_ghost_recipe.rs +++ b/azalea-protocol/src/packets/game/c_place_ghost_recipe.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use crate::common::recipe::RecipeDisplayData; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundPlaceGhostRecipe { #[var] pub container_id: i32, diff --git a/azalea-protocol/src/packets/game/c_player_abilities.rs b/azalea-protocol/src/packets/game/c_player_abilities.rs index 82b43b3d..926f4f2f 100644 --- a/azalea-protocol/src/packets/game/c_player_abilities.rs +++ b/azalea-protocol/src/packets/game/c_player_abilities.rs @@ -5,7 +5,7 @@ use azalea_core::bitset::FixedBitSet; use azalea_entity::PlayerAbilities; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundPlayerAbilities { pub flags: PlayerAbilitiesFlags, pub flying_speed: f32, diff --git a/azalea-protocol/src/packets/game/c_player_chat.rs b/azalea-protocol/src/packets/game/c_player_chat.rs index 41e457a2..a63ab56d 100644 --- a/azalea-protocol/src/packets/game/c_player_chat.rs +++ b/azalea-protocol/src/packets/game/c_player_chat.rs @@ -23,7 +23,7 @@ use azalea_registry::{ use simdnbt::owned::NbtCompound; use uuid::Uuid; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundPlayerChat { #[var] pub global_index: u32, @@ -37,7 +37,7 @@ pub struct ClientboundPlayerChat { pub chat_type: ChatTypeBound, } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct PackedSignedMessageBody { // the error is here, for some reason it skipped a byte earlier and here // it's reading `0` when it should be `11` @@ -47,7 +47,7 @@ pub struct PackedSignedMessageBody { pub last_seen: PackedLastSeenMessages, } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct PackedLastSeenMessages { pub entries: Vec<PackedMessageSignature>, } @@ -59,33 +59,33 @@ pub enum PackedMessageSignature { Id(u32), } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub enum FilterMask { PassThrough, FullyFiltered, PartiallyFiltered(BitSet), } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct ChatTypeBound { pub chat_type: Holder<ChatKind, DirectChatType>, pub name: FormattedText, pub target_name: Option<FormattedText>, } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct DirectChatType { pub chat: ChatTypeDecoration, pub narration: ChatTypeDecoration, } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct ChatTypeDecoration { pub translation_key: String, pub parameters: Vec<ChatTypeDecorationParameter>, pub style: NbtCompound, } -#[derive(Clone, Copy, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq)] pub enum ChatTypeDecorationParameter { Sender = 0, Target = 1, diff --git a/azalea-protocol/src/packets/game/c_player_combat_end.rs b/azalea-protocol/src/packets/game/c_player_combat_end.rs index d1cc5cde..8e210e10 100644 --- a/azalea-protocol/src/packets/game/c_player_combat_end.rs +++ b/azalea-protocol/src/packets/game/c_player_combat_end.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; /// Unused by the client in vanilla. -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundPlayerCombatEnd { #[var] pub duration: u32, diff --git a/azalea-protocol/src/packets/game/c_player_combat_enter.rs b/azalea-protocol/src/packets/game/c_player_combat_enter.rs index 82c44f9e..01f99854 100644 --- a/azalea-protocol/src/packets/game/c_player_combat_enter.rs +++ b/azalea-protocol/src/packets/game/c_player_combat_enter.rs @@ -2,5 +2,5 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; /// Unused in vanilla. -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundPlayerCombatEnter; diff --git a/azalea-protocol/src/packets/game/c_player_combat_kill.rs b/azalea-protocol/src/packets/game/c_player_combat_kill.rs index ae758b44..3d2f7d7b 100644 --- a/azalea-protocol/src/packets/game/c_player_combat_kill.rs +++ b/azalea-protocol/src/packets/game/c_player_combat_kill.rs @@ -4,7 +4,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; /// Used to send a respawn screen. -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundPlayerCombatKill { #[var] pub player_id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_player_info_remove.rs b/azalea-protocol/src/packets/game/c_player_info_remove.rs index 5b11048f..6ae8f848 100644 --- a/azalea-protocol/src/packets/game/c_player_info_remove.rs +++ b/azalea-protocol/src/packets/game/c_player_info_remove.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use uuid::Uuid; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundPlayerInfoRemove { pub profile_ids: Vec<Uuid>, } diff --git a/azalea-protocol/src/packets/game/c_player_info_update.rs b/azalea-protocol/src/packets/game/c_player_info_update.rs index 64a2b5b0..4a18233e 100644 --- a/azalea-protocol/src/packets/game/c_player_info_update.rs +++ b/azalea-protocol/src/packets/game/c_player_info_update.rs @@ -12,7 +12,7 @@ use uuid::Uuid; use super::s_chat_session_update::RemoteChatSessionData; -#[derive(Clone, Debug, PartialEq, ClientboundGamePacket)] +#[derive(ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundPlayerInfoUpdate { pub actions: ActionEnumSet, pub entries: Vec<PlayerInfoEntry>, @@ -30,37 +30,37 @@ pub struct PlayerInfoEntry { pub chat_session: Option<RemoteChatSessionData>, } -#[derive(Clone, Debug, AzBuf)] +#[derive(AzBuf, Clone, Debug)] pub struct AddPlayerAction { pub name: String, pub properties: GameProfileProperties, } -#[derive(Clone, Debug, AzBuf)] +#[derive(AzBuf, Clone, Debug)] pub struct InitializeChatAction { pub chat_session: Option<RemoteChatSessionData>, } -#[derive(Clone, Debug, AzBuf)] +#[derive(AzBuf, Clone, Debug)] pub struct UpdateGameModeAction { pub game_mode: GameMode, } -#[derive(Clone, Debug, AzBuf)] +#[derive(AzBuf, Clone, Debug)] pub struct UpdateListedAction { pub listed: bool, } -#[derive(Clone, Debug, AzBuf)] +#[derive(AzBuf, Clone, Debug)] pub struct UpdateLatencyAction { #[var] pub latency: i32, } -#[derive(Clone, Debug, AzBuf)] +#[derive(AzBuf, Clone, Debug)] pub struct UpdateDisplayNameAction { pub display_name: Option<Box<FormattedText>>, } -#[derive(Clone, Debug, AzBuf)] +#[derive(AzBuf, Clone, Debug)] pub struct UpdateHatAction { pub update_hat: bool, } -#[derive(Clone, Debug, AzBuf)] +#[derive(AzBuf, Clone, Debug)] pub struct UpdateListOrderAction { #[var] pub list_order: i32, @@ -169,7 +169,7 @@ impl AzaleaWrite for ClientboundPlayerInfoUpdate { } } -#[derive(Clone, Debug, PartialEq, Eq)] +#[derive(Clone, Debug, Eq, PartialEq)] pub struct ActionEnumSet { pub add_player: bool, pub initialize_chat: bool, diff --git a/azalea-protocol/src/packets/game/c_player_look_at.rs b/azalea-protocol/src/packets/game/c_player_look_at.rs index 06b84adf..b623868e 100644 --- a/azalea-protocol/src/packets/game/c_player_look_at.rs +++ b/azalea-protocol/src/packets/game/c_player_look_at.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_core::position::Vec3; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundPlayerLookAt { pub from_anchor: Anchor, pub pos: Vec3, diff --git a/azalea-protocol/src/packets/game/c_player_position.rs b/azalea-protocol/src/packets/game/c_player_position.rs index 2ec56d4b..8ec7402d 100644 --- a/azalea-protocol/src/packets/game/c_player_position.rs +++ b/azalea-protocol/src/packets/game/c_player_position.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use crate::common::movements::{PositionMoveRotation, RelativeMovements}; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundPlayerPosition { /// The teleport ID. #[var] diff --git a/azalea-protocol/src/packets/game/c_player_rotation.rs b/azalea-protocol/src/packets/game/c_player_rotation.rs index fc1da719..07adf78f 100644 --- a/azalea-protocol/src/packets/game/c_player_rotation.rs +++ b/azalea-protocol/src/packets/game/c_player_rotation.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundPlayerRotation { pub y_rot: f32, pub relative_y: bool, diff --git a/azalea-protocol/src/packets/game/c_pong_response.rs b/azalea-protocol/src/packets/game/c_pong_response.rs index 51aa40c3..06dd005d 100644 --- a/azalea-protocol/src/packets/game/c_pong_response.rs +++ b/azalea-protocol/src/packets/game/c_pong_response.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundPongResponse { pub time: u64, } diff --git a/azalea-protocol/src/packets/game/c_projectile_power.rs b/azalea-protocol/src/packets/game/c_projectile_power.rs index 643c6172..eae4c885 100644 --- a/azalea-protocol/src/packets/game/c_projectile_power.rs +++ b/azalea-protocol/src/packets/game/c_projectile_power.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundProjectilePower { #[var] pub id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_recipe_book_add.rs b/azalea-protocol/src/packets/game/c_recipe_book_add.rs index 0fcd8b04..e7dbeaec 100644 --- a/azalea-protocol/src/packets/game/c_recipe_book_add.rs +++ b/azalea-protocol/src/packets/game/c_recipe_book_add.rs @@ -4,19 +4,19 @@ use azalea_registry::builtin::RecipeBookCategory; use crate::common::recipe::{Ingredient, RecipeDisplayData}; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundRecipeBookAdd { pub entries: Vec<Entry>, pub replace: bool, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct Entry { pub contents: RecipeDisplayEntry, pub flags: u8, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct RecipeDisplayEntry { #[var] pub id: u32, diff --git a/azalea-protocol/src/packets/game/c_recipe_book_remove.rs b/azalea-protocol/src/packets/game/c_recipe_book_remove.rs index 222730f4..79ec474c 100644 --- a/azalea-protocol/src/packets/game/c_recipe_book_remove.rs +++ b/azalea-protocol/src/packets/game/c_recipe_book_remove.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundRecipeBookRemove { #[var] pub recipes: Vec<u32>, diff --git a/azalea-protocol/src/packets/game/c_recipe_book_settings.rs b/azalea-protocol/src/packets/game/c_recipe_book_settings.rs index 9bffcce6..e2fa217f 100644 --- a/azalea-protocol/src/packets/game/c_recipe_book_settings.rs +++ b/azalea-protocol/src/packets/game/c_recipe_book_settings.rs @@ -1,12 +1,12 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundRecipeBookSettings { pub book_settings: RecipeBookSettings, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct RecipeBookSettings { pub gui_open: bool, pub filtering_craftable: bool, diff --git a/azalea-protocol/src/packets/game/c_remove_entities.rs b/azalea-protocol/src/packets/game/c_remove_entities.rs index 8711abb7..71749052 100644 --- a/azalea-protocol/src/packets/game/c_remove_entities.rs +++ b/azalea-protocol/src/packets/game/c_remove_entities.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundRemoveEntities { #[var] pub entity_ids: Vec<MinecraftEntityId>, diff --git a/azalea-protocol/src/packets/game/c_remove_mob_effect.rs b/azalea-protocol/src/packets/game/c_remove_mob_effect.rs index f17cfd37..d5190e53 100644 --- a/azalea-protocol/src/packets/game/c_remove_mob_effect.rs +++ b/azalea-protocol/src/packets/game/c_remove_mob_effect.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use azalea_registry::builtin::MobEffect; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundRemoveMobEffect { #[var] pub entity_id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_reset_score.rs b/azalea-protocol/src/packets/game/c_reset_score.rs index d974b290..2aa3fc74 100644 --- a/azalea-protocol/src/packets/game/c_reset_score.rs +++ b/azalea-protocol/src/packets/game/c_reset_score.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundResetScore { pub owner: String, pub objective_name: Option<String>, diff --git a/azalea-protocol/src/packets/game/c_resource_pack_pop.rs b/azalea-protocol/src/packets/game/c_resource_pack_pop.rs index 2b41f0da..908e3e0c 100644 --- a/azalea-protocol/src/packets/game/c_resource_pack_pop.rs +++ b/azalea-protocol/src/packets/game/c_resource_pack_pop.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use uuid::Uuid; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundResourcePackPop { pub id: Option<Uuid>, } diff --git a/azalea-protocol/src/packets/game/c_resource_pack_push.rs b/azalea-protocol/src/packets/game/c_resource_pack_push.rs index 767670fd..d4f97a64 100644 --- a/azalea-protocol/src/packets/game/c_resource_pack_push.rs +++ b/azalea-protocol/src/packets/game/c_resource_pack_push.rs @@ -3,7 +3,7 @@ use azalea_chat::FormattedText; use azalea_protocol_macros::ClientboundGamePacket; use uuid::Uuid; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundResourcePackPush { pub id: Uuid, pub url: String, diff --git a/azalea-protocol/src/packets/game/c_respawn.rs b/azalea-protocol/src/packets/game/c_respawn.rs index 5dad5f6f..27eafa4f 100644 --- a/azalea-protocol/src/packets/game/c_respawn.rs +++ b/azalea-protocol/src/packets/game/c_respawn.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use crate::packets::common::CommonPlayerSpawnInfo; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundRespawn { pub common: CommonPlayerSpawnInfo, pub data_to_keep: u8, diff --git a/azalea-protocol/src/packets/game/c_rotate_head.rs b/azalea-protocol/src/packets/game/c_rotate_head.rs index 6c961609..3ced78cb 100644 --- a/azalea-protocol/src/packets/game/c_rotate_head.rs +++ b/azalea-protocol/src/packets/game/c_rotate_head.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundRotateHead { #[var] pub entity_id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_section_blocks_update.rs b/azalea-protocol/src/packets/game/c_section_blocks_update.rs index 8bfe45b7..070d2a9e 100644 --- a/azalea-protocol/src/packets/game/c_section_blocks_update.rs +++ b/azalea-protocol/src/packets/game/c_section_blocks_update.rs @@ -5,7 +5,7 @@ use azalea_buf::{AzBuf, AzaleaRead, AzaleaReadVar, AzaleaWrite, AzaleaWriteVar, use azalea_core::position::{ChunkSectionBlockPos, ChunkSectionPos}; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSectionBlocksUpdate { pub section_pos: ChunkSectionPos, pub states: Vec<BlockStateWithPosition>, diff --git a/azalea-protocol/src/packets/game/c_select_advancements_tab.rs b/azalea-protocol/src/packets/game/c_select_advancements_tab.rs index 0ff46365..6aee22e2 100644 --- a/azalea-protocol/src/packets/game/c_select_advancements_tab.rs +++ b/azalea-protocol/src/packets/game/c_select_advancements_tab.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSelectAdvancementsTab { pub tab: Option<Identifier>, } diff --git a/azalea-protocol/src/packets/game/c_server_data.rs b/azalea-protocol/src/packets/game/c_server_data.rs index 43aaf8f7..6dafc28f 100644 --- a/azalea-protocol/src/packets/game/c_server_data.rs +++ b/azalea-protocol/src/packets/game/c_server_data.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_chat::FormattedText; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundServerData { pub motd: FormattedText, pub icon_bytes: Option<Vec<u8>>, diff --git a/azalea-protocol/src/packets/game/c_server_links.rs b/azalea-protocol/src/packets/game/c_server_links.rs index ffb62517..75869492 100644 --- a/azalea-protocol/src/packets/game/c_server_links.rs +++ b/azalea-protocol/src/packets/game/c_server_links.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use crate::common::server_links::ServerLinkEntry; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundServerLinks { pub links: Vec<ServerLinkEntry>, } diff --git a/azalea-protocol/src/packets/game/c_set_action_bar_text.rs b/azalea-protocol/src/packets/game/c_set_action_bar_text.rs index 2ea07089..bae9c103 100644 --- a/azalea-protocol/src/packets/game/c_set_action_bar_text.rs +++ b/azalea-protocol/src/packets/game/c_set_action_bar_text.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_chat::FormattedText; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetActionBarText { pub text: FormattedText, } diff --git a/azalea-protocol/src/packets/game/c_set_border_center.rs b/azalea-protocol/src/packets/game/c_set_border_center.rs index 7d4ae1d8..d9663920 100644 --- a/azalea-protocol/src/packets/game/c_set_border_center.rs +++ b/azalea-protocol/src/packets/game/c_set_border_center.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetBorderCenter { pub new_center_x: f64, pub new_center_z: f64, diff --git a/azalea-protocol/src/packets/game/c_set_border_lerp_size.rs b/azalea-protocol/src/packets/game/c_set_border_lerp_size.rs index 219d478f..400e2e49 100644 --- a/azalea-protocol/src/packets/game/c_set_border_lerp_size.rs +++ b/azalea-protocol/src/packets/game/c_set_border_lerp_size.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetBorderLerpSize { pub old_size: f64, pub new_size: f64, diff --git a/azalea-protocol/src/packets/game/c_set_border_size.rs b/azalea-protocol/src/packets/game/c_set_border_size.rs index cb6b58c6..09d29f8a 100644 --- a/azalea-protocol/src/packets/game/c_set_border_size.rs +++ b/azalea-protocol/src/packets/game/c_set_border_size.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetBorderSize { pub size: f64, } diff --git a/azalea-protocol/src/packets/game/c_set_border_warning_delay.rs b/azalea-protocol/src/packets/game/c_set_border_warning_delay.rs index 4f1bbead..8aa0d84e 100644 --- a/azalea-protocol/src/packets/game/c_set_border_warning_delay.rs +++ b/azalea-protocol/src/packets/game/c_set_border_warning_delay.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetBorderWarningDelay { #[var] pub warning_delay: u32, diff --git a/azalea-protocol/src/packets/game/c_set_border_warning_distance.rs b/azalea-protocol/src/packets/game/c_set_border_warning_distance.rs index 4b3cdbea..d36833c9 100644 --- a/azalea-protocol/src/packets/game/c_set_border_warning_distance.rs +++ b/azalea-protocol/src/packets/game/c_set_border_warning_distance.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetBorderWarningDistance { #[var] pub warning_blocks: u32, diff --git a/azalea-protocol/src/packets/game/c_set_camera.rs b/azalea-protocol/src/packets/game/c_set_camera.rs index 97e0aedc..f2b44f0b 100644 --- a/azalea-protocol/src/packets/game/c_set_camera.rs +++ b/azalea-protocol/src/packets/game/c_set_camera.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetCamera { #[var] pub camera_id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_set_chunk_cache_center.rs b/azalea-protocol/src/packets/game/c_set_chunk_cache_center.rs index 24507c4c..0085e501 100644 --- a/azalea-protocol/src/packets/game/c_set_chunk_cache_center.rs +++ b/azalea-protocol/src/packets/game/c_set_chunk_cache_center.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetChunkCacheCenter { #[var] pub x: i32, diff --git a/azalea-protocol/src/packets/game/c_set_chunk_cache_radius.rs b/azalea-protocol/src/packets/game/c_set_chunk_cache_radius.rs index e17ea3a2..41f686cb 100644 --- a/azalea-protocol/src/packets/game/c_set_chunk_cache_radius.rs +++ b/azalea-protocol/src/packets/game/c_set_chunk_cache_radius.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetChunkCacheRadius { #[var] pub radius: u32, diff --git a/azalea-protocol/src/packets/game/c_set_cursor_item.rs b/azalea-protocol/src/packets/game/c_set_cursor_item.rs index 7e207d18..1499d6e5 100644 --- a/azalea-protocol/src/packets/game/c_set_cursor_item.rs +++ b/azalea-protocol/src/packets/game/c_set_cursor_item.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_inventory::ItemStack; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetCursorItem { pub contents: ItemStack, } diff --git a/azalea-protocol/src/packets/game/c_set_default_spawn_position.rs b/azalea-protocol/src/packets/game/c_set_default_spawn_position.rs index 429030ef..01a64a11 100644 --- a/azalea-protocol/src/packets/game/c_set_default_spawn_position.rs +++ b/azalea-protocol/src/packets/game/c_set_default_spawn_position.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_core::position::GlobalPos; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetDefaultSpawnPosition { pub global_pos: GlobalPos, pub yaw: f32, diff --git a/azalea-protocol/src/packets/game/c_set_display_objective.rs b/azalea-protocol/src/packets/game/c_set_display_objective.rs index 3abc847f..496259f1 100644 --- a/azalea-protocol/src/packets/game/c_set_display_objective.rs +++ b/azalea-protocol/src/packets/game/c_set_display_objective.rs @@ -1,13 +1,13 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetDisplayObjective { pub slot: DisplaySlot, pub objective_name: String, } -#[derive(Clone, Debug, Copy, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq)] pub enum DisplaySlot { List = 0, Sidebar, diff --git a/azalea-protocol/src/packets/game/c_set_entity_data.rs b/azalea-protocol/src/packets/game/c_set_entity_data.rs index 88aa04d9..6e738f5f 100644 --- a/azalea-protocol/src/packets/game/c_set_entity_data.rs +++ b/azalea-protocol/src/packets/game/c_set_entity_data.rs @@ -3,7 +3,7 @@ use azalea_entity::EntityMetadataItems; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetEntityData { #[var] pub id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_set_entity_link.rs b/azalea-protocol/src/packets/game/c_set_entity_link.rs index efa1262a..127b09a3 100644 --- a/azalea-protocol/src/packets/game/c_set_entity_link.rs +++ b/azalea-protocol/src/packets/game/c_set_entity_link.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetEntityLink { pub source_id: MinecraftEntityId, pub dest_id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_set_entity_motion.rs b/azalea-protocol/src/packets/game/c_set_entity_motion.rs index a48ec885..f6219888 100644 --- a/azalea-protocol/src/packets/game/c_set_entity_motion.rs +++ b/azalea-protocol/src/packets/game/c_set_entity_motion.rs @@ -3,7 +3,7 @@ use azalea_core::delta::LpVec3; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetEntityMotion { #[var] pub id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_set_equipment.rs b/azalea-protocol/src/packets/game/c_set_equipment.rs index 0ef3d8e1..d6b1c735 100644 --- a/azalea-protocol/src/packets/game/c_set_equipment.rs +++ b/azalea-protocol/src/packets/game/c_set_equipment.rs @@ -5,7 +5,7 @@ use azalea_inventory::{ItemStack, components::EquipmentSlot}; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetEquipment { #[var] pub entity_id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_set_experience.rs b/azalea-protocol/src/packets/game/c_set_experience.rs index 8b18ee81..d311a863 100644 --- a/azalea-protocol/src/packets/game/c_set_experience.rs +++ b/azalea-protocol/src/packets/game/c_set_experience.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetExperience { pub experience_progress: f32, #[var] diff --git a/azalea-protocol/src/packets/game/c_set_health.rs b/azalea-protocol/src/packets/game/c_set_health.rs index b80b0361..82e31f78 100644 --- a/azalea-protocol/src/packets/game/c_set_health.rs +++ b/azalea-protocol/src/packets/game/c_set_health.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetHealth { pub health: f32, #[var] diff --git a/azalea-protocol/src/packets/game/c_set_held_slot.rs b/azalea-protocol/src/packets/game/c_set_held_slot.rs index 6b51be26..ca311df5 100644 --- a/azalea-protocol/src/packets/game/c_set_held_slot.rs +++ b/azalea-protocol/src/packets/game/c_set_held_slot.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetHeldSlot { #[var] pub slot: u32, diff --git a/azalea-protocol/src/packets/game/c_set_objective.rs b/azalea-protocol/src/packets/game/c_set_objective.rs index 853bc28a..dad4ccdf 100644 --- a/azalea-protocol/src/packets/game/c_set_objective.rs +++ b/azalea-protocol/src/packets/game/c_set_objective.rs @@ -5,13 +5,13 @@ use azalea_chat::{FormattedText, numbers::NumberFormat}; use azalea_core::objectives::ObjectiveCriteria; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetObjective { pub objective_name: String, pub method: Method, } -#[derive(Clone, Copy, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq)] pub enum MethodKind { Add, Remove, diff --git a/azalea-protocol/src/packets/game/c_set_passengers.rs b/azalea-protocol/src/packets/game/c_set_passengers.rs index ad2ffe17..ade63267 100644 --- a/azalea-protocol/src/packets/game/c_set_passengers.rs +++ b/azalea-protocol/src/packets/game/c_set_passengers.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetPassengers { #[var] pub vehicle: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_set_player_inventory.rs b/azalea-protocol/src/packets/game/c_set_player_inventory.rs index 0f3b3b73..e6672e7f 100644 --- a/azalea-protocol/src/packets/game/c_set_player_inventory.rs +++ b/azalea-protocol/src/packets/game/c_set_player_inventory.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_inventory::ItemStack; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetPlayerInventory { #[var] pub slot: u32, diff --git a/azalea-protocol/src/packets/game/c_set_player_team.rs b/azalea-protocol/src/packets/game/c_set_player_team.rs index 3f644eb7..e8c85886 100644 --- a/azalea-protocol/src/packets/game/c_set_player_team.rs +++ b/azalea-protocol/src/packets/game/c_set_player_team.rs @@ -2,13 +2,13 @@ use azalea_buf::AzBuf; use azalea_chat::{FormattedText, style::ChatFormatting}; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetPlayerTeam { pub name: String, pub method: Method, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub enum Method { Add((Parameters, PlayerList)), Remove, @@ -17,7 +17,7 @@ pub enum Method { Leave(PlayerList), } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct Parameters { pub display_name: FormattedText, pub options: u8, @@ -28,7 +28,7 @@ pub struct Parameters { pub player_suffix: FormattedText, } -#[derive(Clone, Copy, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq)] pub enum CollisionRule { Always, Never, @@ -36,7 +36,7 @@ pub enum CollisionRule { PushOwnTeam, } -#[derive(Clone, Copy, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq)] pub enum NameTagVisibility { Always, Never, diff --git a/azalea-protocol/src/packets/game/c_set_score.rs b/azalea-protocol/src/packets/game/c_set_score.rs index 0dd68905..07391901 100644 --- a/azalea-protocol/src/packets/game/c_set_score.rs +++ b/azalea-protocol/src/packets/game/c_set_score.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_chat::{numbers::NumberFormat, FormattedText}; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetScore { pub owner: String, pub objective_name: String, diff --git a/azalea-protocol/src/packets/game/c_set_simulation_distance.rs b/azalea-protocol/src/packets/game/c_set_simulation_distance.rs index 6ec6df07..b8561a3a 100644 --- a/azalea-protocol/src/packets/game/c_set_simulation_distance.rs +++ b/azalea-protocol/src/packets/game/c_set_simulation_distance.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetSimulationDistance { #[var] pub simulation_distance: u32, diff --git a/azalea-protocol/src/packets/game/c_set_subtitle_text.rs b/azalea-protocol/src/packets/game/c_set_subtitle_text.rs index c011eb4d..14454c72 100644 --- a/azalea-protocol/src/packets/game/c_set_subtitle_text.rs +++ b/azalea-protocol/src/packets/game/c_set_subtitle_text.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_chat::FormattedText; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetSubtitleText { pub text: FormattedText, } diff --git a/azalea-protocol/src/packets/game/c_set_time.rs b/azalea-protocol/src/packets/game/c_set_time.rs index 75bdbde6..ff795e87 100644 --- a/azalea-protocol/src/packets/game/c_set_time.rs +++ b/azalea-protocol/src/packets/game/c_set_time.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetTime { pub game_time: u64, pub day_time: u64, diff --git a/azalea-protocol/src/packets/game/c_set_title_text.rs b/azalea-protocol/src/packets/game/c_set_title_text.rs index b75f5ffd..c9217238 100644 --- a/azalea-protocol/src/packets/game/c_set_title_text.rs +++ b/azalea-protocol/src/packets/game/c_set_title_text.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_chat::FormattedText; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetTitleText { pub text: FormattedText, } diff --git a/azalea-protocol/src/packets/game/c_set_titles_animation.rs b/azalea-protocol/src/packets/game/c_set_titles_animation.rs index a7d5897b..07190e79 100644 --- a/azalea-protocol/src/packets/game/c_set_titles_animation.rs +++ b/azalea-protocol/src/packets/game/c_set_titles_animation.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSetTitlesAnimation { pub fade_in: u32, pub stay: u32, diff --git a/azalea-protocol/src/packets/game/c_show_dialog.rs b/azalea-protocol/src/packets/game/c_show_dialog.rs index 52d9be78..bf860cfb 100644 --- a/azalea-protocol/src/packets/game/c_show_dialog.rs +++ b/azalea-protocol/src/packets/game/c_show_dialog.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use azalea_registry::{Holder, data::Dialog}; use simdnbt::owned::Nbt; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundShowDialog { pub dialog: Holder<Dialog, Nbt>, } diff --git a/azalea-protocol/src/packets/game/c_sound.rs b/azalea-protocol/src/packets/game/c_sound.rs index 31d30942..a380532c 100644 --- a/azalea-protocol/src/packets/game/c_sound.rs +++ b/azalea-protocol/src/packets/game/c_sound.rs @@ -3,7 +3,7 @@ use azalea_core::sound::CustomSound; use azalea_protocol_macros::ClientboundGamePacket; use azalea_registry::builtin::SoundEvent; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSound { pub sound: azalea_registry::Holder<SoundEvent, CustomSound>, pub source: SoundSource, diff --git a/azalea-protocol/src/packets/game/c_sound_entity.rs b/azalea-protocol/src/packets/game/c_sound_entity.rs index 72325c04..2b405201 100644 --- a/azalea-protocol/src/packets/game/c_sound_entity.rs +++ b/azalea-protocol/src/packets/game/c_sound_entity.rs @@ -6,7 +6,7 @@ use azalea_world::MinecraftEntityId; use super::c_sound::SoundSource; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSoundEntity { pub sound: azalea_registry::Holder<SoundEvent, CustomSound>, pub source: SoundSource, diff --git a/azalea-protocol/src/packets/game/c_start_configuration.rs b/azalea-protocol/src/packets/game/c_start_configuration.rs index d419ab52..3e76accf 100644 --- a/azalea-protocol/src/packets/game/c_start_configuration.rs +++ b/azalea-protocol/src/packets/game/c_start_configuration.rs @@ -1,5 +1,5 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundStartConfiguration; diff --git a/azalea-protocol/src/packets/game/c_stop_sound.rs b/azalea-protocol/src/packets/game/c_stop_sound.rs index 419216eb..6225a759 100644 --- a/azalea-protocol/src/packets/game/c_stop_sound.rs +++ b/azalea-protocol/src/packets/game/c_stop_sound.rs @@ -7,7 +7,7 @@ use azalea_registry::identifier::Identifier; use super::c_sound::SoundSource; -#[derive(Clone, Debug, PartialEq, ClientboundGamePacket)] +#[derive(ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundStopSound { pub source: Option<SoundSource>, pub name: Option<Identifier>, diff --git a/azalea-protocol/src/packets/game/c_store_cookie.rs b/azalea-protocol/src/packets/game/c_store_cookie.rs index fff6fb71..4bd702f2 100644 --- a/azalea-protocol/src/packets/game/c_store_cookie.rs +++ b/azalea-protocol/src/packets/game/c_store_cookie.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundStoreCookie { pub key: Identifier, pub payload: Vec<u8>, diff --git a/azalea-protocol/src/packets/game/c_system_chat.rs b/azalea-protocol/src/packets/game/c_system_chat.rs index 6ad67ccd..491825f4 100644 --- a/azalea-protocol/src/packets/game/c_system_chat.rs +++ b/azalea-protocol/src/packets/game/c_system_chat.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_chat::FormattedText; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundSystemChat { pub content: FormattedText, pub overlay: bool, diff --git a/azalea-protocol/src/packets/game/c_tab_list.rs b/azalea-protocol/src/packets/game/c_tab_list.rs index 0105b981..9a360dac 100644 --- a/azalea-protocol/src/packets/game/c_tab_list.rs +++ b/azalea-protocol/src/packets/game/c_tab_list.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_chat::FormattedText; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundTabList { pub header: FormattedText, pub footer: FormattedText, diff --git a/azalea-protocol/src/packets/game/c_tag_query.rs b/azalea-protocol/src/packets/game/c_tag_query.rs index 6be68856..492db1c1 100644 --- a/azalea-protocol/src/packets/game/c_tag_query.rs +++ b/azalea-protocol/src/packets/game/c_tag_query.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use simdnbt::owned::NbtTag; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundTagQuery { #[var] pub transaction_id: u32, diff --git a/azalea-protocol/src/packets/game/c_take_item_entity.rs b/azalea-protocol/src/packets/game/c_take_item_entity.rs index 09b2f7bc..0ab5e832 100644 --- a/azalea-protocol/src/packets/game/c_take_item_entity.rs +++ b/azalea-protocol/src/packets/game/c_take_item_entity.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundTakeItemEntity { #[var] pub item_id: u32, diff --git a/azalea-protocol/src/packets/game/c_teleport_entity.rs b/azalea-protocol/src/packets/game/c_teleport_entity.rs index 8f9ea2d8..b025338b 100644 --- a/azalea-protocol/src/packets/game/c_teleport_entity.rs +++ b/azalea-protocol/src/packets/game/c_teleport_entity.rs @@ -4,7 +4,7 @@ use azalea_world::MinecraftEntityId; use crate::common::movements::{PositionMoveRotation, RelativeMovements}; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundTeleportEntity { #[var] pub id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_test_instance_block_status.rs b/azalea-protocol/src/packets/game/c_test_instance_block_status.rs index 9d8d3182..e9f2d47f 100644 --- a/azalea-protocol/src/packets/game/c_test_instance_block_status.rs +++ b/azalea-protocol/src/packets/game/c_test_instance_block_status.rs @@ -3,7 +3,7 @@ use azalea_chat::FormattedText; use azalea_core::position::Vec3; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundTestInstanceBlockStatus { pub status: FormattedText, pub size: Option<Vec3>, diff --git a/azalea-protocol/src/packets/game/c_ticking_state.rs b/azalea-protocol/src/packets/game/c_ticking_state.rs index dfab0fd5..144ce07b 100644 --- a/azalea-protocol/src/packets/game/c_ticking_state.rs +++ b/azalea-protocol/src/packets/game/c_ticking_state.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundTickingState { pub tick_rate: f32, pub is_frozen: bool, diff --git a/azalea-protocol/src/packets/game/c_ticking_step.rs b/azalea-protocol/src/packets/game/c_ticking_step.rs index dd0977c1..664dbaa3 100644 --- a/azalea-protocol/src/packets/game/c_ticking_step.rs +++ b/azalea-protocol/src/packets/game/c_ticking_step.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundTickingStep { #[var] pub tick_steps: u32, diff --git a/azalea-protocol/src/packets/game/c_transfer.rs b/azalea-protocol/src/packets/game/c_transfer.rs index bc6e5757..09d786fe 100644 --- a/azalea-protocol/src/packets/game/c_transfer.rs +++ b/azalea-protocol/src/packets/game/c_transfer.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundTransfer { pub host: String, #[var] diff --git a/azalea-protocol/src/packets/game/c_update_advancements.rs b/azalea-protocol/src/packets/game/c_update_advancements.rs index 6f3e960e..07479656 100644 --- a/azalea-protocol/src/packets/game/c_update_advancements.rs +++ b/azalea-protocol/src/packets/game/c_update_advancements.rs @@ -10,7 +10,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use azalea_registry::identifier::Identifier; use indexmap::IndexMap; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundUpdateAdvancements { pub reset: bool, pub added: Vec<AdvancementHolder>, @@ -19,7 +19,7 @@ pub struct ClientboundUpdateAdvancements { pub show_advancements: bool, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct Advancement { pub parent_id: Option<Identifier>, pub display: Option<DisplayInfo>, @@ -100,7 +100,7 @@ impl azalea_buf::AzaleaRead for DisplayInfo { } } -#[derive(Clone, Debug, Copy, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq)] pub enum FrameType { Task = 0, Challenge = 1, @@ -109,12 +109,12 @@ pub enum FrameType { pub type AdvancementProgress = HashMap<String, CriterionProgress>; -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct CriterionProgress { pub date: Option<u64>, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct AdvancementHolder { pub id: Identifier, pub value: Advancement, diff --git a/azalea-protocol/src/packets/game/c_update_attributes.rs b/azalea-protocol/src/packets/game/c_update_attributes.rs index 80e4729f..8fb95c28 100644 --- a/azalea-protocol/src/packets/game/c_update_attributes.rs +++ b/azalea-protocol/src/packets/game/c_update_attributes.rs @@ -4,14 +4,14 @@ use azalea_protocol_macros::ClientboundGamePacket; use azalea_registry::builtin::Attribute; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundUpdateAttributes { #[var] pub entity_id: MinecraftEntityId, pub values: Vec<AttributeSnapshot>, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct AttributeSnapshot { pub attribute: Attribute, pub base: f64, diff --git a/azalea-protocol/src/packets/game/c_update_mob_effect.rs b/azalea-protocol/src/packets/game/c_update_mob_effect.rs index adc33f62..df07fdfc 100644 --- a/azalea-protocol/src/packets/game/c_update_mob_effect.rs +++ b/azalea-protocol/src/packets/game/c_update_mob_effect.rs @@ -4,7 +4,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use azalea_registry::builtin::MobEffect; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundUpdateMobEffect { #[var] pub entity_id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/c_update_recipes.rs b/azalea-protocol/src/packets/game/c_update_recipes.rs index de9f6e3b..eee89d28 100644 --- a/azalea-protocol/src/packets/game/c_update_recipes.rs +++ b/azalea-protocol/src/packets/game/c_update_recipes.rs @@ -7,23 +7,23 @@ use azalea_registry::builtin::ItemKind; use crate::common::recipe::{Ingredient, SlotDisplayData}; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundUpdateRecipes { pub item_sets: HashMap<Identifier, RecipePropertySet>, pub stonecutter_recipes: Vec<SingleInputEntry>, } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct SingleInputEntry { pub input: Ingredient, pub recipe: SelectableRecipe, } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct SelectableRecipe { pub option_display: SlotDisplayData, } -#[derive(Clone, Debug, PartialEq, AzBuf)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct RecipePropertySet { pub items: Vec<ItemKind>, } diff --git a/azalea-protocol/src/packets/game/c_update_tags.rs b/azalea-protocol/src/packets/game/c_update_tags.rs index 10b5ea06..1d55cce9 100644 --- a/azalea-protocol/src/packets/game/c_update_tags.rs +++ b/azalea-protocol/src/packets/game/c_update_tags.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ClientboundGamePacket; use crate::common::tags::TagMap; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundUpdateTags { pub tags: TagMap, } diff --git a/azalea-protocol/src/packets/game/c_waypoint.rs b/azalea-protocol/src/packets/game/c_waypoint.rs index a701622f..38a160e9 100644 --- a/azalea-protocol/src/packets/game/c_waypoint.rs +++ b/azalea-protocol/src/packets/game/c_waypoint.rs @@ -6,13 +6,13 @@ use azalea_protocol_macros::ClientboundGamePacket; use azalea_registry::identifier::Identifier; use uuid::Uuid; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundGamePacket)] +#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)] pub struct ClientboundWaypoint { pub operation: WaypointOperation, pub waypoint: TrackedWaypoint, } -#[derive(AzBuf, Copy, Clone, Debug, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, PartialEq)] pub enum WaypointOperation { Track, Untrack, diff --git a/azalea-protocol/src/packets/game/s_accept_teleportation.rs b/azalea-protocol/src/packets/game/s_accept_teleportation.rs index 88ec340c..27af1263 100644 --- a/azalea-protocol/src/packets/game/s_accept_teleportation.rs +++ b/azalea-protocol/src/packets/game/s_accept_teleportation.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundAcceptTeleportation { #[var] pub id: u32, diff --git a/azalea-protocol/src/packets/game/s_block_entity_tag_query.rs b/azalea-protocol/src/packets/game/s_block_entity_tag_query.rs index 04b3f733..4a744864 100644 --- a/azalea-protocol/src/packets/game/s_block_entity_tag_query.rs +++ b/azalea-protocol/src/packets/game/s_block_entity_tag_query.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_core::position::BlockPos; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundBlockEntityTagQuery { #[var] pub transaction_id: u32, diff --git a/azalea-protocol/src/packets/game/s_bundle_item_selected.rs b/azalea-protocol/src/packets/game/s_bundle_item_selected.rs index 35c57b5f..42c3fd71 100644 --- a/azalea-protocol/src/packets/game/s_bundle_item_selected.rs +++ b/azalea-protocol/src/packets/game/s_bundle_item_selected.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundBundleItemSelected { #[var] pub slot_id: i32, diff --git a/azalea-protocol/src/packets/game/s_change_difficulty.rs b/azalea-protocol/src/packets/game/s_change_difficulty.rs index b01a0225..07a23ab9 100644 --- a/azalea-protocol/src/packets/game/s_change_difficulty.rs +++ b/azalea-protocol/src/packets/game/s_change_difficulty.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_core::difficulty::Difficulty; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundChangeDifficulty { pub difficulty: Difficulty, } diff --git a/azalea-protocol/src/packets/game/s_change_game_mode.rs b/azalea-protocol/src/packets/game/s_change_game_mode.rs index e11725c1..d86d2ca7 100644 --- a/azalea-protocol/src/packets/game/s_change_game_mode.rs +++ b/azalea-protocol/src/packets/game/s_change_game_mode.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_core::game_type::GameMode; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundChangeGameMode { pub mode: GameMode, } diff --git a/azalea-protocol/src/packets/game/s_chat.rs b/azalea-protocol/src/packets/game/s_chat.rs index 3b881181..f957bbea 100644 --- a/azalea-protocol/src/packets/game/s_chat.rs +++ b/azalea-protocol/src/packets/game/s_chat.rs @@ -3,7 +3,7 @@ use azalea_core::bitset::FixedBitSet; use azalea_crypto::signing::MessageSignature; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundChat { #[limit(256)] pub message: String, @@ -13,7 +13,7 @@ pub struct ServerboundChat { pub last_seen_messages: LastSeenMessagesUpdate, } -#[derive(Clone, Debug, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq)] pub struct LastSeenMessagesUpdate { #[var] pub offset: u32, diff --git a/azalea-protocol/src/packets/game/s_chat_ack.rs b/azalea-protocol/src/packets/game/s_chat_ack.rs index b0abda26..9c9d5152 100644 --- a/azalea-protocol/src/packets/game/s_chat_ack.rs +++ b/azalea-protocol/src/packets/game/s_chat_ack.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundChatAck { #[var] pub messages: u32, diff --git a/azalea-protocol/src/packets/game/s_chat_command.rs b/azalea-protocol/src/packets/game/s_chat_command.rs index 0ce308d0..d653fa43 100644 --- a/azalea-protocol/src/packets/game/s_chat_command.rs +++ b/azalea-protocol/src/packets/game/s_chat_command.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundChatCommand { pub command: String, } diff --git a/azalea-protocol/src/packets/game/s_chat_command_signed.rs b/azalea-protocol/src/packets/game/s_chat_command_signed.rs index f45f92c8..6dfac309 100644 --- a/azalea-protocol/src/packets/game/s_chat_command_signed.rs +++ b/azalea-protocol/src/packets/game/s_chat_command_signed.rs @@ -4,7 +4,7 @@ use azalea_protocol_macros::ServerboundGamePacket; use super::s_chat::LastSeenMessagesUpdate; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundChatCommandSigned { pub command: String, pub timestamp: u64, @@ -13,7 +13,7 @@ pub struct ServerboundChatCommandSigned { pub last_seen_messages: LastSeenMessagesUpdate, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct ArgumentSignature { pub name: String, pub signature: MessageSignature, diff --git a/azalea-protocol/src/packets/game/s_chat_preview.rs b/azalea-protocol/src/packets/game/s_chat_preview.rs index 4dc1a2a0..a540341c 100644 --- a/azalea-protocol/src/packets/game/s_chat_preview.rs +++ b/azalea-protocol/src/packets/game/s_chat_preview.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundChatPreview { pub query_id: i32, pub query: String, diff --git a/azalea-protocol/src/packets/game/s_chat_session_update.rs b/azalea-protocol/src/packets/game/s_chat_session_update.rs index c72b87ba..8d4f8b67 100644 --- a/azalea-protocol/src/packets/game/s_chat_session_update.rs +++ b/azalea-protocol/src/packets/game/s_chat_session_update.rs @@ -2,18 +2,18 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; use uuid::Uuid; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundChatSessionUpdate { pub chat_session: RemoteChatSessionData, } -#[derive(Clone, Debug, PartialEq, Eq, AzBuf)] +#[derive(AzBuf, Clone, Debug, Eq, PartialEq)] pub struct RemoteChatSessionData { pub session_id: Uuid, pub profile_public_key: ProfilePublicKeyData, } -#[derive(Clone, Debug, AzBuf, PartialEq, Eq)] +#[derive(AzBuf, Clone, Debug, Eq, PartialEq)] pub struct ProfilePublicKeyData { pub expires_at: u64, pub key: Vec<u8>, diff --git a/azalea-protocol/src/packets/game/s_chunk_batch_received.rs b/azalea-protocol/src/packets/game/s_chunk_batch_received.rs index 16b58c80..bba28580 100644 --- a/azalea-protocol/src/packets/game/s_chunk_batch_received.rs +++ b/azalea-protocol/src/packets/game/s_chunk_batch_received.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundChunkBatchReceived { pub desired_chunks_per_tick: f32, } diff --git a/azalea-protocol/src/packets/game/s_client_command.rs b/azalea-protocol/src/packets/game/s_client_command.rs index 106a120e..04fe8936 100644 --- a/azalea-protocol/src/packets/game/s_client_command.rs +++ b/azalea-protocol/src/packets/game/s_client_command.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundClientCommand { pub action: Action, } diff --git a/azalea-protocol/src/packets/game/s_client_information.rs b/azalea-protocol/src/packets/game/s_client_information.rs index 923a625c..051216f8 100644 --- a/azalea-protocol/src/packets/game/s_client_information.rs +++ b/azalea-protocol/src/packets/game/s_client_information.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ServerboundGamePacket; use crate::common::client_information::ClientInformation; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundClientInformation { pub client_information: ClientInformation, } diff --git a/azalea-protocol/src/packets/game/s_client_tick_end.rs b/azalea-protocol/src/packets/game/s_client_tick_end.rs index b4e0acc4..26738acb 100644 --- a/azalea-protocol/src/packets/game/s_client_tick_end.rs +++ b/azalea-protocol/src/packets/game/s_client_tick_end.rs @@ -1,5 +1,5 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundClientTickEnd; diff --git a/azalea-protocol/src/packets/game/s_command_suggestion.rs b/azalea-protocol/src/packets/game/s_command_suggestion.rs index df5a8ea9..19db9341 100644 --- a/azalea-protocol/src/packets/game/s_command_suggestion.rs +++ b/azalea-protocol/src/packets/game/s_command_suggestion.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundCommandSuggestion { #[var] pub id: u32, diff --git a/azalea-protocol/src/packets/game/s_configuration_acknowledged.rs b/azalea-protocol/src/packets/game/s_configuration_acknowledged.rs index 2049ef1c..be2d1f2e 100644 --- a/azalea-protocol/src/packets/game/s_configuration_acknowledged.rs +++ b/azalea-protocol/src/packets/game/s_configuration_acknowledged.rs @@ -1,5 +1,5 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundConfigurationAcknowledged; diff --git a/azalea-protocol/src/packets/game/s_container_button_click.rs b/azalea-protocol/src/packets/game/s_container_button_click.rs index 0983c299..42da19c3 100644 --- a/azalea-protocol/src/packets/game/s_container_button_click.rs +++ b/azalea-protocol/src/packets/game/s_container_button_click.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundContainerButtonClick { #[var] pub container_id: i32, diff --git a/azalea-protocol/src/packets/game/s_container_click.rs b/azalea-protocol/src/packets/game/s_container_click.rs index bfce320e..423af5cb 100644 --- a/azalea-protocol/src/packets/game/s_container_click.rs +++ b/azalea-protocol/src/packets/game/s_container_click.rs @@ -5,7 +5,7 @@ use azalea_protocol_macros::ServerboundGamePacket; use azalea_registry::builtin::{DataComponentKind, ItemKind}; use indexmap::IndexMap; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundContainerClick { #[var] pub container_id: i32, @@ -20,10 +20,10 @@ pub struct ServerboundContainerClick { /// Similar to an [`ItemStack`] but only carrying a CRC32 hash of the value of /// added data components instead of their entire contents. -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct HashedStack(pub Option<HashedActualItem>); -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct HashedActualItem { pub kind: ItemKind, #[var] @@ -31,7 +31,7 @@ pub struct HashedActualItem { pub components: HashedPatchMap, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct HashedPatchMap { #[limit(256)] pub added_components: Vec<(DataComponentKind, Checksum)>, diff --git a/azalea-protocol/src/packets/game/s_container_close.rs b/azalea-protocol/src/packets/game/s_container_close.rs index 79e48629..dc005f22 100644 --- a/azalea-protocol/src/packets/game/s_container_close.rs +++ b/azalea-protocol/src/packets/game/s_container_close.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundContainerClose { #[var] pub container_id: i32, diff --git a/azalea-protocol/src/packets/game/s_container_slot_state_changed.rs b/azalea-protocol/src/packets/game/s_container_slot_state_changed.rs index 1aedbb68..c5721d18 100644 --- a/azalea-protocol/src/packets/game/s_container_slot_state_changed.rs +++ b/azalea-protocol/src/packets/game/s_container_slot_state_changed.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundContainerSlotStateChanged { #[var] pub slot_id: u32, diff --git a/azalea-protocol/src/packets/game/s_cookie_response.rs b/azalea-protocol/src/packets/game/s_cookie_response.rs index 72b95f4d..0653d7c9 100644 --- a/azalea-protocol/src/packets/game/s_cookie_response.rs +++ b/azalea-protocol/src/packets/game/s_cookie_response.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundCookieResponse { pub key: Identifier, pub payload: Option<Vec<u8>>, diff --git a/azalea-protocol/src/packets/game/s_custom_click_action.rs b/azalea-protocol/src/packets/game/s_custom_click_action.rs index e10e8749..e032397d 100644 --- a/azalea-protocol/src/packets/game/s_custom_click_action.rs +++ b/azalea-protocol/src/packets/game/s_custom_click_action.rs @@ -3,7 +3,7 @@ use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ServerboundGamePacket; use simdnbt::owned::Nbt; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundCustomClickAction { pub id: Identifier, pub payload: Nbt, diff --git a/azalea-protocol/src/packets/game/s_custom_payload.rs b/azalea-protocol/src/packets/game/s_custom_payload.rs index 7e5468d9..a24971b2 100644 --- a/azalea-protocol/src/packets/game/s_custom_payload.rs +++ b/azalea-protocol/src/packets/game/s_custom_payload.rs @@ -2,7 +2,7 @@ use azalea_buf::{AzBuf, UnsizedByteArray}; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundCustomPayload { pub identifier: Identifier, pub data: UnsizedByteArray, diff --git a/azalea-protocol/src/packets/game/s_debug_subscription_request.rs b/azalea-protocol/src/packets/game/s_debug_subscription_request.rs index 23bd49a5..80a9abd7 100644 --- a/azalea-protocol/src/packets/game/s_debug_subscription_request.rs +++ b/azalea-protocol/src/packets/game/s_debug_subscription_request.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; use azalea_registry::builtin::DebugSubscription; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundDebugSubscriptionRequest { pub subscriptions: Vec<DebugSubscription>, } diff --git a/azalea-protocol/src/packets/game/s_edit_book.rs b/azalea-protocol/src/packets/game/s_edit_book.rs index f99a5e0e..b1e70cda 100644 --- a/azalea-protocol/src/packets/game/s_edit_book.rs +++ b/azalea-protocol/src/packets/game/s_edit_book.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundEditBook { #[var] pub slot: u32, diff --git a/azalea-protocol/src/packets/game/s_entity_tag_query.rs b/azalea-protocol/src/packets/game/s_entity_tag_query.rs index def302e6..00ef5c03 100644 --- a/azalea-protocol/src/packets/game/s_entity_tag_query.rs +++ b/azalea-protocol/src/packets/game/s_entity_tag_query.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundEntityTagQuery { #[var] pub transaction_id: u32, diff --git a/azalea-protocol/src/packets/game/s_interact.rs b/azalea-protocol/src/packets/game/s_interact.rs index 2929570d..fc2cd11e 100644 --- a/azalea-protocol/src/packets/game/s_interact.rs +++ b/azalea-protocol/src/packets/game/s_interact.rs @@ -7,7 +7,7 @@ use azalea_world::MinecraftEntityId; use crate::packets::BufReadError; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundInteract { #[var] pub entity_id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/s_jigsaw_generate.rs b/azalea-protocol/src/packets/game/s_jigsaw_generate.rs index 00c0cf7d..86ea3f62 100644 --- a/azalea-protocol/src/packets/game/s_jigsaw_generate.rs +++ b/azalea-protocol/src/packets/game/s_jigsaw_generate.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_core::position::BlockPos; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundJigsawGenerate { pub pos: BlockPos, #[var] diff --git a/azalea-protocol/src/packets/game/s_keep_alive.rs b/azalea-protocol/src/packets/game/s_keep_alive.rs index 9da1efd4..286efa7b 100644 --- a/azalea-protocol/src/packets/game/s_keep_alive.rs +++ b/azalea-protocol/src/packets/game/s_keep_alive.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundKeepAlive { pub id: u64, } diff --git a/azalea-protocol/src/packets/game/s_lock_difficulty.rs b/azalea-protocol/src/packets/game/s_lock_difficulty.rs index b874a1a0..cfbdd073 100644 --- a/azalea-protocol/src/packets/game/s_lock_difficulty.rs +++ b/azalea-protocol/src/packets/game/s_lock_difficulty.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundLockDifficulty { pub locked: bool, } diff --git a/azalea-protocol/src/packets/game/s_move_player_pos.rs b/azalea-protocol/src/packets/game/s_move_player_pos.rs index 3d4e31be..d9e5470b 100644 --- a/azalea-protocol/src/packets/game/s_move_player_pos.rs +++ b/azalea-protocol/src/packets/game/s_move_player_pos.rs @@ -4,7 +4,7 @@ use azalea_protocol_macros::ServerboundGamePacket; use crate::common::movements::MoveFlags; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundMovePlayerPos { pub pos: Vec3, pub flags: MoveFlags, diff --git a/azalea-protocol/src/packets/game/s_move_player_pos_rot.rs b/azalea-protocol/src/packets/game/s_move_player_pos_rot.rs index 6c6dedec..e95fface 100644 --- a/azalea-protocol/src/packets/game/s_move_player_pos_rot.rs +++ b/azalea-protocol/src/packets/game/s_move_player_pos_rot.rs @@ -5,7 +5,7 @@ use azalea_protocol_macros::ServerboundGamePacket; use crate::common::movements::MoveFlags; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundMovePlayerPosRot { pub pos: Vec3, pub look_direction: LookDirection, diff --git a/azalea-protocol/src/packets/game/s_move_player_rot.rs b/azalea-protocol/src/packets/game/s_move_player_rot.rs index 54699865..75d851f8 100644 --- a/azalea-protocol/src/packets/game/s_move_player_rot.rs +++ b/azalea-protocol/src/packets/game/s_move_player_rot.rs @@ -4,7 +4,7 @@ use azalea_protocol_macros::ServerboundGamePacket; use crate::common::movements::MoveFlags; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundMovePlayerRot { pub look_direction: LookDirection, pub flags: MoveFlags, diff --git a/azalea-protocol/src/packets/game/s_move_player_status_only.rs b/azalea-protocol/src/packets/game/s_move_player_status_only.rs index eaa49bab..d00f8726 100644 --- a/azalea-protocol/src/packets/game/s_move_player_status_only.rs +++ b/azalea-protocol/src/packets/game/s_move_player_status_only.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ServerboundGamePacket; use crate::common::movements::MoveFlags; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundMovePlayerStatusOnly { pub flags: MoveFlags, } diff --git a/azalea-protocol/src/packets/game/s_move_vehicle.rs b/azalea-protocol/src/packets/game/s_move_vehicle.rs index f9a3d02b..f9c9dc28 100644 --- a/azalea-protocol/src/packets/game/s_move_vehicle.rs +++ b/azalea-protocol/src/packets/game/s_move_vehicle.rs @@ -3,7 +3,7 @@ use azalea_core::position::Vec3; use azalea_entity::LookDirection; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundMoveVehicle { pub pos: Vec3, pub look_direction: LookDirection, diff --git a/azalea-protocol/src/packets/game/s_paddle_boat.rs b/azalea-protocol/src/packets/game/s_paddle_boat.rs index 174849f4..bf92539d 100644 --- a/azalea-protocol/src/packets/game/s_paddle_boat.rs +++ b/azalea-protocol/src/packets/game/s_paddle_boat.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundPaddleBoat { pub left: bool, pub right: bool, diff --git a/azalea-protocol/src/packets/game/s_pick_item_from_block.rs b/azalea-protocol/src/packets/game/s_pick_item_from_block.rs index db0a8201..5bdbdeda 100644 --- a/azalea-protocol/src/packets/game/s_pick_item_from_block.rs +++ b/azalea-protocol/src/packets/game/s_pick_item_from_block.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundPickItemFromBlock { #[var] pub slot: u32, diff --git a/azalea-protocol/src/packets/game/s_pick_item_from_entity.rs b/azalea-protocol/src/packets/game/s_pick_item_from_entity.rs index e91298f8..a68e7ab7 100644 --- a/azalea-protocol/src/packets/game/s_pick_item_from_entity.rs +++ b/azalea-protocol/src/packets/game/s_pick_item_from_entity.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundPickItemFromEntity { #[var] pub id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/s_ping_request.rs b/azalea-protocol/src/packets/game/s_ping_request.rs index 1c4c8adc..b6164069 100644 --- a/azalea-protocol/src/packets/game/s_ping_request.rs +++ b/azalea-protocol/src/packets/game/s_ping_request.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundPingRequest { pub time: u64, } diff --git a/azalea-protocol/src/packets/game/s_place_recipe.rs b/azalea-protocol/src/packets/game/s_place_recipe.rs index 90821d08..6cb73e48 100644 --- a/azalea-protocol/src/packets/game/s_place_recipe.rs +++ b/azalea-protocol/src/packets/game/s_place_recipe.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundPlaceRecipe { #[var] pub container_id: i32, diff --git a/azalea-protocol/src/packets/game/s_player_action.rs b/azalea-protocol/src/packets/game/s_player_action.rs index 3f129918..ba17f525 100644 --- a/azalea-protocol/src/packets/game/s_player_action.rs +++ b/azalea-protocol/src/packets/game/s_player_action.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_core::{direction::Direction, position::BlockPos}; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundPlayerAction { pub action: Action, pub pos: BlockPos, @@ -11,7 +11,7 @@ pub struct ServerboundPlayerAction { pub seq: u32, } -#[derive(AzBuf, Clone, Copy, Debug, PartialEq, Eq)] +#[derive(AzBuf, Clone, Copy, Debug, Eq, PartialEq)] pub enum Action { StartDestroyBlock = 0, AbortDestroyBlock = 1, diff --git a/azalea-protocol/src/packets/game/s_player_command.rs b/azalea-protocol/src/packets/game/s_player_command.rs index f7cb5bee..2e4e83df 100644 --- a/azalea-protocol/src/packets/game/s_player_command.rs +++ b/azalea-protocol/src/packets/game/s_player_command.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; use azalea_world::MinecraftEntityId; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundPlayerCommand { #[var] pub id: MinecraftEntityId, diff --git a/azalea-protocol/src/packets/game/s_player_input.rs b/azalea-protocol/src/packets/game/s_player_input.rs index a12262b4..e92d6101 100644 --- a/azalea-protocol/src/packets/game/s_player_input.rs +++ b/azalea-protocol/src/packets/game/s_player_input.rs @@ -5,7 +5,7 @@ use azalea_buf::{AzaleaRead, AzaleaWrite}; use azalea_core::bitset::FixedBitSet; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, Default, PartialEq, Eq, ServerboundGamePacket)] +#[derive(Clone, Debug, Default, Eq, PartialEq, ServerboundGamePacket)] pub struct ServerboundPlayerInput { pub forward: bool, pub backward: bool, diff --git a/azalea-protocol/src/packets/game/s_player_loaded.rs b/azalea-protocol/src/packets/game/s_player_loaded.rs index 1372aba1..371e06f5 100644 --- a/azalea-protocol/src/packets/game/s_player_loaded.rs +++ b/azalea-protocol/src/packets/game/s_player_loaded.rs @@ -1,5 +1,5 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundPlayerLoaded; diff --git a/azalea-protocol/src/packets/game/s_pong.rs b/azalea-protocol/src/packets/game/s_pong.rs index 2114cddc..0dd3f5f1 100644 --- a/azalea-protocol/src/packets/game/s_pong.rs +++ b/azalea-protocol/src/packets/game/s_pong.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundPong { pub id: u32, } diff --git a/azalea-protocol/src/packets/game/s_recipe_book_change_settings.rs b/azalea-protocol/src/packets/game/s_recipe_book_change_settings.rs index 5bf188ee..82863104 100644 --- a/azalea-protocol/src/packets/game/s_recipe_book_change_settings.rs +++ b/azalea-protocol/src/packets/game/s_recipe_book_change_settings.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundRecipeBookChangeSettings { pub book_type: RecipeBookType, pub is_open: bool, diff --git a/azalea-protocol/src/packets/game/s_recipe_book_seen_recipe.rs b/azalea-protocol/src/packets/game/s_recipe_book_seen_recipe.rs index e9766a64..b2b8123c 100644 --- a/azalea-protocol/src/packets/game/s_recipe_book_seen_recipe.rs +++ b/azalea-protocol/src/packets/game/s_recipe_book_seen_recipe.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundRecipeBookSeenRecipe { pub recipe: Identifier, } diff --git a/azalea-protocol/src/packets/game/s_rename_item.rs b/azalea-protocol/src/packets/game/s_rename_item.rs index f9fcf269..4d42c02c 100644 --- a/azalea-protocol/src/packets/game/s_rename_item.rs +++ b/azalea-protocol/src/packets/game/s_rename_item.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundRenameItem { pub name: String, } diff --git a/azalea-protocol/src/packets/game/s_resource_pack.rs b/azalea-protocol/src/packets/game/s_resource_pack.rs index 0d0b55a7..78c21713 100644 --- a/azalea-protocol/src/packets/game/s_resource_pack.rs +++ b/azalea-protocol/src/packets/game/s_resource_pack.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; use uuid::Uuid; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundResourcePack { pub id: Uuid, pub action: Action, diff --git a/azalea-protocol/src/packets/game/s_select_trade.rs b/azalea-protocol/src/packets/game/s_select_trade.rs index 2955db7a..a1134ad1 100644 --- a/azalea-protocol/src/packets/game/s_select_trade.rs +++ b/azalea-protocol/src/packets/game/s_select_trade.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundSelectTrade { #[var] pub item: u32, diff --git a/azalea-protocol/src/packets/game/s_set_beacon.rs b/azalea-protocol/src/packets/game/s_set_beacon.rs index c06d888c..c6e70784 100644 --- a/azalea-protocol/src/packets/game/s_set_beacon.rs +++ b/azalea-protocol/src/packets/game/s_set_beacon.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundSetBeacon { #[var] pub primary: Option<u32>, diff --git a/azalea-protocol/src/packets/game/s_set_carried_item.rs b/azalea-protocol/src/packets/game/s_set_carried_item.rs index 5d990426..b73c1aab 100644 --- a/azalea-protocol/src/packets/game/s_set_carried_item.rs +++ b/azalea-protocol/src/packets/game/s_set_carried_item.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundSetCarriedItem { pub slot: u16, } diff --git a/azalea-protocol/src/packets/game/s_set_command_minecart.rs b/azalea-protocol/src/packets/game/s_set_command_minecart.rs index 88e6e74e..b92d24ce 100644 --- a/azalea-protocol/src/packets/game/s_set_command_minecart.rs +++ b/azalea-protocol/src/packets/game/s_set_command_minecart.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundSetCommandMinecart { #[var] pub entity: u32, diff --git a/azalea-protocol/src/packets/game/s_set_creative_mode_slot.rs b/azalea-protocol/src/packets/game/s_set_creative_mode_slot.rs index 5e06f424..f3c8518e 100644 --- a/azalea-protocol/src/packets/game/s_set_creative_mode_slot.rs +++ b/azalea-protocol/src/packets/game/s_set_creative_mode_slot.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_inventory::ItemStack; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundSetCreativeModeSlot { pub slot_num: u16, pub item_stack: ItemStack, diff --git a/azalea-protocol/src/packets/game/s_set_jigsaw_block.rs b/azalea-protocol/src/packets/game/s_set_jigsaw_block.rs index 64a46c02..a19b8a82 100644 --- a/azalea-protocol/src/packets/game/s_set_jigsaw_block.rs +++ b/azalea-protocol/src/packets/game/s_set_jigsaw_block.rs @@ -10,7 +10,7 @@ use azalea_registry::identifier::Identifier; use crate::packets::{AzaleaWrite, BufReadError}; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundSetJigsawBlock { pub pos: BlockPos, pub name: Identifier, diff --git a/azalea-protocol/src/packets/game/s_set_structure_block.rs b/azalea-protocol/src/packets/game/s_set_structure_block.rs index 401116a1..c4387b0f 100644 --- a/azalea-protocol/src/packets/game/s_set_structure_block.rs +++ b/azalea-protocol/src/packets/game/s_set_structure_block.rs @@ -6,7 +6,7 @@ use azalea_protocol_macros::ServerboundGamePacket; use crate::packets::BufReadError; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundSetStructureBlock { pub pos: BlockPos, pub update_type: UpdateType, @@ -23,7 +23,7 @@ pub struct ServerboundSetStructureBlock { pub flags: Flags, } -#[derive(Clone, Debug, AzBuf, PartialEq)] +#[derive(AzBuf, Clone, Debug, PartialEq)] pub struct BytePosition { pub x: u8, pub y: u8, @@ -63,7 +63,7 @@ pub enum Rotation { Counterclockwise90 = 3, } -#[derive(Debug, Clone, PartialEq)] +#[derive(Clone, Debug, PartialEq)] pub struct Flags { pub ignore_entities: bool, pub show_air: bool, diff --git a/azalea-protocol/src/packets/game/s_set_test_block.rs b/azalea-protocol/src/packets/game/s_set_test_block.rs index afa456e6..c7429071 100644 --- a/azalea-protocol/src/packets/game/s_set_test_block.rs +++ b/azalea-protocol/src/packets/game/s_set_test_block.rs @@ -2,14 +2,14 @@ use azalea_buf::AzBuf; use azalea_core::position::BlockPos; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundSetTestBlock { pub position: BlockPos, pub mode: TestBlockMode, pub message: String, } -#[derive(Clone, Copy, Debug, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, Default, PartialEq)] pub enum TestBlockMode { #[default] Start, diff --git a/azalea-protocol/src/packets/game/s_sign_update.rs b/azalea-protocol/src/packets/game/s_sign_update.rs index 85cb1d6f..913af5f8 100644 --- a/azalea-protocol/src/packets/game/s_sign_update.rs +++ b/azalea-protocol/src/packets/game/s_sign_update.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_core::position::BlockPos; use azalea_protocol_macros::ServerboundGamePacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundSignUpdate { pub pos: BlockPos, pub is_front_text: bool, diff --git a/azalea-protocol/src/packets/game/s_swing.rs b/azalea-protocol/src/packets/game/s_swing.rs index ab336260..2c551a00 100644 --- a/azalea-protocol/src/packets/game/s_swing.rs +++ b/azalea-protocol/src/packets/game/s_swing.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ServerboundGamePacket; use crate::packets::game::s_interact::InteractionHand; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundSwing { pub hand: InteractionHand, } diff --git a/azalea-protocol/src/packets/game/s_teleport_to_entity.rs b/azalea-protocol/src/packets/game/s_teleport_to_entity.rs index a70d0c85..40f6106d 100644 --- a/azalea-protocol/src/packets/game/s_teleport_to_entity.rs +++ b/azalea-protocol/src/packets/game/s_teleport_to_entity.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundGamePacket; use uuid::Uuid; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundTeleportToEntity { pub uuid: Uuid, } diff --git a/azalea-protocol/src/packets/game/s_test_instance_block_action.rs b/azalea-protocol/src/packets/game/s_test_instance_block_action.rs index c4baf78d..908b0449 100644 --- a/azalea-protocol/src/packets/game/s_test_instance_block_action.rs +++ b/azalea-protocol/src/packets/game/s_test_instance_block_action.rs @@ -6,14 +6,14 @@ use azalea_registry::builtin::TestInstanceKind; use super::s_set_structure_block::Rotation; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundTestInstanceBlockAction { pub pos: BlockPos, pub action: Action, pub data: TestInstanceBlockEntityData, } -#[derive(Clone, Copy, Debug, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, Default, PartialEq)] pub enum Action { #[default] Init, @@ -25,7 +25,7 @@ pub enum Action { Run, } -#[derive(Clone, Debug, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Debug, Default, PartialEq)] pub struct TestInstanceBlockEntityData { pub test: Option<TestInstanceKind>, pub size: Vec3i, @@ -35,7 +35,7 @@ pub struct TestInstanceBlockEntityData { pub error_message: Option<FormattedText>, } -#[derive(Clone, Copy, Debug, AzBuf, Default, PartialEq)] +#[derive(AzBuf, Clone, Copy, Debug, Default, PartialEq)] pub enum TestInstanceBlockEntityStatus { #[default] Cleared, diff --git a/azalea-protocol/src/packets/game/s_use_item.rs b/azalea-protocol/src/packets/game/s_use_item.rs index e7be84bc..4dd14e90 100644 --- a/azalea-protocol/src/packets/game/s_use_item.rs +++ b/azalea-protocol/src/packets/game/s_use_item.rs @@ -3,7 +3,7 @@ use azalea_protocol_macros::ServerboundGamePacket; use crate::packets::game::s_interact::InteractionHand; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundUseItem { pub hand: InteractionHand, #[var] diff --git a/azalea-protocol/src/packets/game/s_use_item_on.rs b/azalea-protocol/src/packets/game/s_use_item_on.rs index 61d7fc78..22d3c861 100644 --- a/azalea-protocol/src/packets/game/s_use_item_on.rs +++ b/azalea-protocol/src/packets/game/s_use_item_on.rs @@ -10,7 +10,7 @@ use azalea_protocol_macros::ServerboundGamePacket; use crate::packets::game::s_interact::InteractionHand; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundGamePacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundGamePacket)] pub struct ServerboundUseItemOn { pub hand: InteractionHand, pub block_hit: BlockHit, diff --git a/azalea-protocol/src/packets/handshake/s_intention.rs b/azalea-protocol/src/packets/handshake/s_intention.rs index 30d74f5d..d0b6d6e3 100644 --- a/azalea-protocol/src/packets/handshake/s_intention.rs +++ b/azalea-protocol/src/packets/handshake/s_intention.rs @@ -5,7 +5,7 @@ use azalea_protocol_macros::ServerboundHandshakePacket; use crate::packets::ClientIntention; -#[derive(Hash, Clone, Debug, AzBuf, PartialEq, ServerboundHandshakePacket)] +#[derive(AzBuf, Clone, Debug, Hash, PartialEq, ServerboundHandshakePacket)] pub struct ServerboundIntention { #[var] pub protocol_version: i32, diff --git a/azalea-protocol/src/packets/login/c_cookie_request.rs b/azalea-protocol/src/packets/login/c_cookie_request.rs index 2df3aaa0..4122325e 100644 --- a/azalea-protocol/src/packets/login/c_cookie_request.rs +++ b/azalea-protocol/src/packets/login/c_cookie_request.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ClientboundLoginPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundLoginPacket)] +#[derive(AzBuf, ClientboundLoginPacket, Clone, Debug, PartialEq)] pub struct ClientboundCookieRequest { pub key: Identifier, } diff --git a/azalea-protocol/src/packets/login/c_custom_query.rs b/azalea-protocol/src/packets/login/c_custom_query.rs index 6f975cf4..f4566d4e 100644 --- a/azalea-protocol/src/packets/login/c_custom_query.rs +++ b/azalea-protocol/src/packets/login/c_custom_query.rs @@ -4,7 +4,7 @@ use azalea_buf::{AzBuf, UnsizedByteArray}; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ClientboundLoginPacket; -#[derive(Hash, Clone, Debug, AzBuf, PartialEq, ClientboundLoginPacket)] +#[derive(AzBuf, ClientboundLoginPacket, Clone, Debug, Hash, PartialEq)] pub struct ClientboundCustomQuery { #[var] pub transaction_id: u32, diff --git a/azalea-protocol/src/packets/login/c_hello.rs b/azalea-protocol/src/packets/login/c_hello.rs index 0057397c..3e87418f 100644 --- a/azalea-protocol/src/packets/login/c_hello.rs +++ b/azalea-protocol/src/packets/login/c_hello.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundLoginPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundLoginPacket)] +#[derive(AzBuf, ClientboundLoginPacket, Clone, Debug, PartialEq)] pub struct ClientboundHello { #[limit(20)] pub server_id: String, diff --git a/azalea-protocol/src/packets/login/c_login_compression.rs b/azalea-protocol/src/packets/login/c_login_compression.rs index 7294c8a5..a12ab5fa 100644 --- a/azalea-protocol/src/packets/login/c_login_compression.rs +++ b/azalea-protocol/src/packets/login/c_login_compression.rs @@ -3,7 +3,7 @@ use std::hash::Hash; use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundLoginPacket; -#[derive(Hash, Clone, Debug, AzBuf, PartialEq, ClientboundLoginPacket)] +#[derive(AzBuf, ClientboundLoginPacket, Clone, Debug, Hash, PartialEq)] pub struct ClientboundLoginCompression { #[var] pub compression_threshold: i32, diff --git a/azalea-protocol/src/packets/login/c_login_disconnect.rs b/azalea-protocol/src/packets/login/c_login_disconnect.rs index 7f8dd5f0..950d5e5c 100644 --- a/azalea-protocol/src/packets/login/c_login_disconnect.rs +++ b/azalea-protocol/src/packets/login/c_login_disconnect.rs @@ -6,7 +6,7 @@ use azalea_protocol_macros::ClientboundLoginPacket; use serde::{Deserialize, Serialize}; use tracing::trace; -#[derive(Clone, Debug, PartialEq, ClientboundLoginPacket)] +#[derive(ClientboundLoginPacket, Clone, Debug, PartialEq)] pub struct ClientboundLoginDisconnect { pub reason: FormattedText, } diff --git a/azalea-protocol/src/packets/login/c_login_finished.rs b/azalea-protocol/src/packets/login/c_login_finished.rs index ecc79ff0..643e3a7a 100644 --- a/azalea-protocol/src/packets/login/c_login_finished.rs +++ b/azalea-protocol/src/packets/login/c_login_finished.rs @@ -2,7 +2,7 @@ use azalea_auth::game_profile::GameProfile; use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundLoginPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundLoginPacket)] +#[derive(AzBuf, ClientboundLoginPacket, Clone, Debug, PartialEq)] pub struct ClientboundLoginFinished { pub game_profile: GameProfile, } diff --git a/azalea-protocol/src/packets/login/s_cookie_response.rs b/azalea-protocol/src/packets/login/s_cookie_response.rs index 73efc2a8..504de740 100644 --- a/azalea-protocol/src/packets/login/s_cookie_response.rs +++ b/azalea-protocol/src/packets/login/s_cookie_response.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_registry::identifier::Identifier; use azalea_protocol_macros::ServerboundLoginPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundLoginPacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundLoginPacket)] pub struct ServerboundCookieResponse { pub key: Identifier, pub payload: Option<Vec<u8>>, diff --git a/azalea-protocol/src/packets/login/s_custom_query_answer.rs b/azalea-protocol/src/packets/login/s_custom_query_answer.rs index af0c4237..478ea026 100644 --- a/azalea-protocol/src/packets/login/s_custom_query_answer.rs +++ b/azalea-protocol/src/packets/login/s_custom_query_answer.rs @@ -3,7 +3,7 @@ use std::hash::Hash; use azalea_buf::{AzBuf, UnsizedByteArray}; use azalea_protocol_macros::ServerboundLoginPacket; -#[derive(Hash, Clone, Debug, AzBuf, PartialEq, ServerboundLoginPacket)] +#[derive(AzBuf, Clone, Debug, Hash, PartialEq, ServerboundLoginPacket)] pub struct ServerboundCustomQueryAnswer { #[var] pub transaction_id: u32, diff --git a/azalea-protocol/src/packets/login/s_hello.rs b/azalea-protocol/src/packets/login/s_hello.rs index a65fe6a1..a7a9f4ee 100644 --- a/azalea-protocol/src/packets/login/s_hello.rs +++ b/azalea-protocol/src/packets/login/s_hello.rs @@ -2,7 +2,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundLoginPacket; use uuid::Uuid; -#[derive(Clone, Debug, Eq, AzBuf, PartialEq, ServerboundLoginPacket)] +#[derive(AzBuf, Clone, Debug, Eq, PartialEq, ServerboundLoginPacket)] pub struct ServerboundHello { #[limit(16)] pub name: String, diff --git a/azalea-protocol/src/packets/login/s_key.rs b/azalea-protocol/src/packets/login/s_key.rs index a3a404c6..d5268a19 100644 --- a/azalea-protocol/src/packets/login/s_key.rs +++ b/azalea-protocol/src/packets/login/s_key.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundLoginPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundLoginPacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundLoginPacket)] pub struct ServerboundKey { pub key_bytes: Vec<u8>, pub encrypted_challenge: Vec<u8>, diff --git a/azalea-protocol/src/packets/login/s_login_acknowledged.rs b/azalea-protocol/src/packets/login/s_login_acknowledged.rs index da1c0f9f..e0f0a47c 100644 --- a/azalea-protocol/src/packets/login/s_login_acknowledged.rs +++ b/azalea-protocol/src/packets/login/s_login_acknowledged.rs @@ -1,5 +1,5 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundLoginPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundLoginPacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundLoginPacket)] pub struct ServerboundLoginAcknowledged; diff --git a/azalea-protocol/src/packets/mod.rs b/azalea-protocol/src/packets/mod.rs index 9d96b75c..9dd14311 100644 --- a/azalea-protocol/src/packets/mod.rs +++ b/azalea-protocol/src/packets/mod.rs @@ -14,7 +14,7 @@ use crate::read::ReadPacketError; pub const PROTOCOL_VERSION: i32 = 774; pub const VERSION_NAME: &str = "1.21.11"; -#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)] +#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)] pub enum ConnectionProtocol { Handshake = -1, Game = 0, @@ -60,7 +60,7 @@ pub trait Packet<Protocol> { fn into_variant(self) -> Protocol; } -#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)] +#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)] pub enum ClientIntention { Status = 1, Login = 2, diff --git a/azalea-protocol/src/packets/status/c_pong_response.rs b/azalea-protocol/src/packets/status/c_pong_response.rs index 1adcfafe..d5ea46cf 100644 --- a/azalea-protocol/src/packets/status/c_pong_response.rs +++ b/azalea-protocol/src/packets/status/c_pong_response.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ClientboundStatusPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ClientboundStatusPacket)] +#[derive(AzBuf, ClientboundStatusPacket, Clone, Debug, PartialEq)] pub struct ClientboundPongResponse { pub time: u64, } diff --git a/azalea-protocol/src/packets/status/c_status_response.rs b/azalea-protocol/src/packets/status/c_status_response.rs index 6505167e..933b6c2c 100644 --- a/azalea-protocol/src/packets/status/c_status_response.rs +++ b/azalea-protocol/src/packets/status/c_status_response.rs @@ -6,19 +6,19 @@ use azalea_protocol_macros::ClientboundStatusPacket; use serde::{Deserialize, Serialize}; use serde_json::value::Serializer; -#[derive(Clone, Debug, Serialize, Deserialize, PartialEq)] +#[derive(Clone, Debug, Deserialize, PartialEq, Serialize)] pub struct Version { pub name: String, pub protocol: i32, } -#[derive(Clone, Debug, Serialize, Deserialize, PartialEq)] +#[derive(Clone, Debug, Deserialize, PartialEq, Serialize)] pub struct SamplePlayer { pub id: String, pub name: String, } -#[derive(Clone, Debug, Serialize, Deserialize, PartialEq)] +#[derive(Clone, Debug, Deserialize, PartialEq, Serialize)] pub struct Players { pub max: i32, pub online: i32, @@ -27,7 +27,7 @@ pub struct Players { } // the entire packet is just json, which is why it has deserialize -#[derive(Clone, Debug, Serialize, Deserialize, PartialEq, ClientboundStatusPacket)] +#[derive(ClientboundStatusPacket, Clone, Debug, Deserialize, PartialEq, Serialize)] pub struct ClientboundStatusResponse { pub description: FormattedText, #[serde(default)] diff --git a/azalea-protocol/src/packets/status/s_ping_request.rs b/azalea-protocol/src/packets/status/s_ping_request.rs index 90c09e3e..ec74ed09 100644 --- a/azalea-protocol/src/packets/status/s_ping_request.rs +++ b/azalea-protocol/src/packets/status/s_ping_request.rs @@ -1,7 +1,7 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundStatusPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundStatusPacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundStatusPacket)] pub struct ServerboundPingRequest { pub time: u64, } diff --git a/azalea-protocol/src/packets/status/s_status_request.rs b/azalea-protocol/src/packets/status/s_status_request.rs index 1119c1de..5b0b96e6 100644 --- a/azalea-protocol/src/packets/status/s_status_request.rs +++ b/azalea-protocol/src/packets/status/s_status_request.rs @@ -1,5 +1,5 @@ use azalea_buf::AzBuf; use azalea_protocol_macros::ServerboundStatusPacket; -#[derive(Clone, Debug, AzBuf, PartialEq, ServerboundStatusPacket)] +#[derive(AzBuf, Clone, Debug, PartialEq, ServerboundStatusPacket)] pub struct ServerboundStatusRequest; diff --git a/azalea-protocol/src/read.rs b/azalea-protocol/src/read.rs index d4357c9f..d6c8c65a 100644 --- a/azalea-protocol/src/read.rs +++ b/azalea-protocol/src/read.rs @@ -24,7 +24,7 @@ use tracing::trace; use crate::packets::ProtocolPacket; -#[derive(Error, Debug)] +#[derive(Debug, Error)] pub enum ReadPacketError { #[error("Error reading packet {packet_name} (id {packet_id}): {source}")] Parse { @@ -61,7 +61,7 @@ pub enum ReadPacketError { ConnectionClosed, } -#[derive(Error, Debug)] +#[derive(Debug, Error)] pub enum FrameSplitterError { #[error("Couldn't read VarInt length for packet. The previous packet may have been corrupted")] LengthRead { @@ -162,7 +162,7 @@ static VALIDATE_DECOMPRESSED: bool = true; pub static MAXIMUM_UNCOMPRESSED_LENGTH: u32 = 8_388_608; -#[derive(Error, Debug)] +#[derive(Debug, Error)] pub enum DecompressionError { #[error("Couldn't read VarInt length for data")] LengthReadError { diff --git a/azalea-protocol/src/write.rs b/azalea-protocol/src/write.rs index dd863f9e..a14463eb 100644 --- a/azalea-protocol/src/write.rs +++ b/azalea-protocol/src/write.rs @@ -112,7 +112,7 @@ fn frame_prepender(mut data: Vec<u8>) -> Result<Vec<u8>, io::Error> { Ok(buf) } -#[derive(Error, Debug)] +#[derive(Debug, Error)] pub enum PacketEncodeError { #[error("{0}")] Io(#[from] io::Error), @@ -124,7 +124,7 @@ pub enum PacketEncodeError { }, } -#[derive(Error, Debug)] +#[derive(Debug, Error)] pub enum PacketCompressError { #[error("{0}")] Io(#[from] io::Error), diff --git a/azalea-registry/azalea-registry-macros/src/lib.rs b/azalea-registry/azalea-registry-macros/src/lib.rs index e2e371b5..05134d29 100644 --- a/azalea-registry/azalea-registry-macros/src/lib.rs +++ b/azalea-registry/azalea-registry-macros/src/lib.rs @@ -80,7 +80,7 @@ pub fn registry(input: TokenStream) -> TokenStream { let attributes = input.attrs; generated.extend(quote! { #(#attributes)* - #[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash, azalea_buf::AzBuf)] + #[derive(azalea_buf::AzBuf, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)] #[repr(u32)] pub enum #name { #enum_items diff --git a/azalea-registry/src/data.rs b/azalea-registry/src/data.rs index 75fd8439..b2c3691b 100644 --- a/azalea-registry/src/data.rs +++ b/azalea-registry/src/data.rs @@ -16,7 +16,7 @@ macro_rules! data_registry { } ) => { $(#[$doc])* - #[derive(Debug, Clone, Copy, AzBuf, PartialEq, Eq, Hash, PartialOrd, Ord)] + #[derive(AzBuf, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)] pub struct $registry { #[var] id: u32, @@ -44,7 +44,7 @@ macro_rules! data_registry { } } - #[derive(Debug, PartialEq, Eq, Hash, Clone)] + #[derive(Clone, Debug, Eq, Hash, PartialEq)] pub enum $enum_name<Other = Identifier> { $($variant),*, Other(Other) diff --git a/azalea-registry/src/identifier.rs b/azalea-registry/src/identifier.rs index b3456dab..c60f8381 100644 --- a/azalea-registry/src/identifier.rs +++ b/azalea-registry/src/identifier.rs @@ -17,7 +17,7 @@ use simdnbt::{FromNbtTag, ToNbtTag, owned::NbtTag}; /// /// This was formerly called a `ResourceLocation`. #[doc(alias = "ResourceLocation")] -#[derive(Hash, Clone, PartialEq, Eq, Default)] +#[derive(Clone, Default, Eq, Hash, PartialEq)] pub struct Identifier { // empty namespaces aren't allowed so NonZero is fine. colon_index: Option<NonZeroUsize>, diff --git a/azalea-registry/src/lib.rs b/azalea-registry/src/lib.rs index 12f8323a..743f0deb 100644 --- a/azalea-registry/src/lib.rs +++ b/azalea-registry/src/lib.rs @@ -66,7 +66,7 @@ where /// A registry that might not be present. /// /// This is transmitted as a single varint in the protocol. -#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)] +#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)] pub struct OptionalRegistry<T: Registry>(pub Option<T>); impl<T: Registry> AzaleaRead for OptionalRegistry<T> { @@ -90,7 +90,7 @@ impl<T: Registry> AzaleaWrite for OptionalRegistry<T> { } /// A registry that will either take an ID or a resource location. -#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)] +#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)] pub enum CustomRegistry<D: Registry, C: AzaleaRead + AzaleaWrite> { Direct(D), Custom(C), diff --git a/azalea-world/src/chunk_storage.rs b/azalea-world/src/chunk_storage.rs index f8646209..2e87fdf6 100644 --- a/azalea-world/src/chunk_storage.rs +++ b/azalea-world/src/chunk_storage.rs @@ -47,7 +47,7 @@ pub struct PartialChunkStorage { /// /// This is relatively cheap to clone since it's just an `IntMap` with `Weak` /// pointers. -#[derive(Debug, Clone)] +#[derive(Clone, Debug)] pub struct ChunkStorage { pub height: u32, pub min_y: i32, diff --git a/azalea-world/src/container.rs b/azalea-world/src/container.rs index c2788198..f6966f3c 100644 --- a/azalea-world/src/container.rs +++ b/azalea-world/src/container.rs @@ -93,6 +93,6 @@ impl InstanceContainer { /// /// If two entities share the same instance name, we assume they're in the /// same instance. -#[derive(Component, Clone, Debug, PartialEq, Deref, DerefMut, Hash, Eq)] +#[derive(Clone, Component, Debug, Deref, DerefMut, Eq, Hash, PartialEq)] #[doc(alias("worldname", "world name"))] pub struct InstanceName(pub Identifier); diff --git a/azalea-world/src/heightmap.rs b/azalea-world/src/heightmap.rs index 0f5e4c53..033fa569 100644 --- a/azalea-world/src/heightmap.rs +++ b/azalea-world/src/heightmap.rs @@ -13,7 +13,7 @@ use crate::{BitStorage, Section, chunk_storage::get_block_state_from_sections}; // (wg stands for worldgen) -#[derive(Clone, Copy, Debug, Hash, PartialEq, Eq, AzBuf)] +#[derive(AzBuf, Clone, Copy, Debug, Eq, Hash, PartialEq)] pub enum HeightmapKind { WorldSurfaceWg, WorldSurface, diff --git a/azalea-world/src/palette/mod.rs b/azalea-world/src/palette/mod.rs index 65a04f6a..4cbf690b 100644 --- a/azalea-world/src/palette/mod.rs +++ b/azalea-world/src/palette/mod.rs @@ -106,7 +106,7 @@ impl<S: PalletedContainerKind> From<&Palette<S>> for PaletteKind { } } -#[derive(Clone, Debug, PartialEq, Eq)] +#[derive(Clone, Debug, Eq, PartialEq)] pub enum PaletteKind { SingleValue, Linear, diff --git a/azalea-world/src/world.rs b/azalea-world/src/world.rs index c9833c64..82594986 100644 --- a/azalea-world/src/world.rs +++ b/azalea-world/src/world.rs @@ -66,7 +66,7 @@ impl PartialInstance { /// `#[var]` attribute. /// /// [`Entity`]: bevy_ecs::entity::Entity -#[derive(Component, Copy, Clone, Debug, Default, PartialEq, Eq, Deref, DerefMut)] +#[derive(Clone, Component, Copy, Debug, Default, Deref, DerefMut, Eq, PartialEq)] #[cfg_attr(feature = "serde", derive(Deserialize, Serialize))] pub struct MinecraftEntityId(pub i32); @@ -150,7 +150,7 @@ impl PartialEntityInfos { /// /// This is sometimes interchangeably called a "world". However, this type is /// called `Instance` to avoid colliding with the `World` type from Bevy ECS. -#[derive(Default, Debug)] +#[derive(Debug, Default)] pub struct Instance { pub chunks: ChunkStorage, diff --git a/azalea/examples/echo.rs b/azalea/examples/echo.rs index ed013a66..40ceb90a 100644 --- a/azalea/examples/echo.rs +++ b/azalea/examples/echo.rs @@ -13,7 +13,7 @@ async fn main() -> AppExit { .await } -#[derive(Default, Clone, Component)] +#[derive(Clone, Component, Default)] pub struct State {} async fn handle(bot: Client, event: Event, _state: State) -> anyhow::Result<()> { diff --git a/azalea/examples/steal.rs b/azalea/examples/steal.rs index 99254d51..4e8c078c 100644 --- a/azalea/examples/steal.rs +++ b/azalea/examples/steal.rs @@ -18,7 +18,7 @@ async fn main() -> AppExit { .await } -#[derive(Default, Clone, Component)] +#[derive(Clone, Component, Default)] struct State { pub is_stealing: Arc<Mutex<bool>>, pub checked_chests: Arc<Mutex<Vec<BlockPos>>>, diff --git a/azalea/examples/testbot/main.rs b/azalea/examples/testbot/main.rs index 71c5585d..aa4a7b99 100644 --- a/azalea/examples/testbot/main.rs +++ b/azalea/examples/testbot/main.rs @@ -91,13 +91,13 @@ fn deadlock_detection_thread() { } } -#[derive(Clone, Copy, Debug, PartialEq, Eq, Default)] +#[derive(Clone, Copy, Debug, Default, Eq, PartialEq)] pub enum BotTask { #[default] None, } -#[derive(Component, Clone, Default)] +#[derive(Clone, Component, Default)] pub struct State { pub killaura: bool, pub task: Arc<Mutex<BotTask>>, @@ -112,7 +112,7 @@ impl State { } } -#[derive(Resource, Default, Clone)] +#[derive(Clone, Default, Resource)] struct SwarmState { pub args: Args, pub commands: Arc<CommandDispatcher<Mutex<CommandSource>>>, @@ -204,7 +204,7 @@ async fn swarm_handle(_swarm: Swarm, event: SwarmEvent, _state: SwarmState) -> a Ok(()) } -#[derive(Debug, Clone, Default)] +#[derive(Clone, Debug, Default)] pub struct Args { pub owner_username: String, pub accounts: Vec<String>, diff --git a/azalea/examples/todo/craft_dig_straight_down.rs b/azalea/examples/todo/craft_dig_straight_down.rs index a76c1ffe..153af299 100644 --- a/azalea/examples/todo/craft_dig_straight_down.rs +++ b/azalea/examples/todo/craft_dig_straight_down.rs @@ -3,7 +3,7 @@ use std::sync::Arc; use azalea::{pathfinder, prelude::*}; use parking_lot::Mutex; -#[derive(Default, Clone, Component)] +#[derive(Clone, Component, Default)] struct State { pub started: Arc<Mutex<bool>>, } diff --git a/azalea/examples/todo/mine_a_chunk.rs b/azalea/examples/todo/mine_a_chunk.rs index 6f6606f4..17fff5df 100644 --- a/azalea/examples/todo/mine_a_chunk.rs +++ b/azalea/examples/todo/mine_a_chunk.rs @@ -18,10 +18,10 @@ async fn main() -> AppExit { .await } -#[derive(Default, Clone, Component)] +#[derive(Clone, Component, Default)] struct State {} -#[derive(Default, Clone, Resource)] +#[derive(Clone, Default, Resource)] struct SwarmState {} async fn handle(bot: Client, event: Event, state: State) -> anyhow::Result<()> { diff --git a/azalea/examples/todo/pvp.rs b/azalea/examples/todo/pvp.rs index 9121444c..3c86778f 100644 --- a/azalea/examples/todo/pvp.rs +++ b/azalea/examples/todo/pvp.rs @@ -24,10 +24,10 @@ async fn main() -> AppExit { .await } -#[derive(Component, Default, Clone)] +#[derive(Clone, Component, Default)] struct State {} -#[derive(Resource, Default, Clone)] +#[derive(Clone, Default, Resource)] struct SwarmState {} async fn handle(bot: Client, event: Event, state: State) -> anyhow::Result<()> { diff --git a/azalea/src/bot.rs b/azalea/src/bot.rs index 6d7dc774..3c262709 100644 --- a/azalea/src/bot.rs +++ b/azalea/src/bot.rs @@ -61,7 +61,7 @@ impl Plugin for BotPlugin { /// /// If you just want to check if an entity is one of our bots, you should use /// [`LocalEntity`]. -#[derive(Default, Component)] +#[derive(Component, Default)] pub struct Bot { jumping_once: bool, } diff --git a/azalea/src/lib.rs b/azalea/src/lib.rs index 45c0114d..44c1fe0c 100644 --- a/azalea/src/lib.rs +++ b/azalea/src/lib.rs @@ -70,7 +70,7 @@ pub type HandleFn<S, Fut> = fn(Client, azalea_client::Event, S) -> Fut; /// .start(Account::offline("bot"), "localhost") /// .await; /// # } -/// # #[derive(Component, Clone, Default)] +/// # #[derive(Clone, Component, Default)] /// # pub struct State; /// # async fn handle(mut bot: Client, event: Event, state: State) -> anyhow::Result<()> { /// # Ok(()) @@ -118,7 +118,7 @@ impl ClientBuilder<NoState, ()> { /// ) /// .add_plugins(azalea::bot::DefaultBotPlugins); /// # client_builder.set_handler(handle); - /// # #[derive(Component, Clone, Default)] + /// # #[derive(Clone, Component, Default)] /// # pub struct State; /// # async fn handle(mut bot: Client, event: Event, state: State) -> anyhow::Result<()> { /// # Ok(()) @@ -146,7 +146,7 @@ impl ClientBuilder<NoState, ()> { /// # let client_builder = azalea::ClientBuilder::new(); /// client_builder.set_handler(handle); /// - /// # #[derive(Component, Clone, Default)] + /// # #[derive(Clone, Component, Default)] /// # pub struct State; /// async fn handle(mut bot: Client, event: Event, state: State) -> anyhow::Result<()> { /// Ok(()) @@ -254,7 +254,7 @@ impl Default for ClientBuilder<NoState, ()> { /// it for you. /// /// [`SwarmBuilder`]: swarm::SwarmBuilder -#[derive(Component, Clone, Default)] +#[derive(Clone, Component, Default)] pub struct NoState; /// Optional settings when adding an account to a swarm or client. diff --git a/azalea/src/pathfinder/astar.rs b/azalea/src/pathfinder/astar.rs index d2a57b38..ed776bec 100644 --- a/azalea/src/pathfinder/astar.rs +++ b/azalea/src/pathfinder/astar.rs @@ -310,7 +310,7 @@ impl PartialOrd for WeightedNode { /// /// [`PathfinderOpts::min_timeout`]: super::goto_event::PathfinderOpts::min_timeout /// [`PathfinderOpts::max_timeout`]: super::goto_event::PathfinderOpts::max_timeout -#[derive(Debug, Clone, Copy, PartialEq)] +#[derive(Clone, Copy, Debug, PartialEq)] pub enum PathfinderTimeout { /// Time out after a certain duration has passed. /// diff --git a/azalea/src/pathfinder/debug.rs b/azalea/src/pathfinder/debug.rs index 4b241e5d..f8dc1193 100644 --- a/azalea/src/pathfinder/debug.rs +++ b/azalea/src/pathfinder/debug.rs @@ -15,7 +15,7 @@ use super::ExecutingPath; /// ``` /// # use azalea::prelude::*; /// # use azalea::pathfinder::debug::PathfinderDebugParticles; -/// # #[derive(Component, Clone, Default)] +/// # #[derive(Clone, Component, Default)] /// # pub struct State; /// /// async fn handle(mut bot: Client, event: azalea::Event, state: State) -> anyhow::Result<()> { diff --git a/azalea/src/pathfinder/mod.rs b/azalea/src/pathfinder/mod.rs index 81b2b845..90b506e9 100644 --- a/azalea/src/pathfinder/mod.rs +++ b/azalea/src/pathfinder/mod.rs @@ -121,7 +121,7 @@ impl Plugin for PathfinderPlugin { } /// A component that makes this client able to pathfind. -#[derive(Component, Default, Clone)] +#[derive(Clone, Component, Default)] #[non_exhaustive] pub struct Pathfinder { pub goal: Option<Arc<dyn Goal>>, @@ -132,7 +132,7 @@ pub struct Pathfinder { /// A component that's present on clients that are actively following a /// pathfinder path. -#[derive(Component, Clone)] +#[derive(Clone, Component)] pub struct ExecutingPath { pub path: VecDeque<astar::Edge<BlockPos, moves::MoveData>>, pub queued_path: Option<VecDeque<astar::Edge<BlockPos, moves::MoveData>>>, @@ -141,7 +141,7 @@ pub struct ExecutingPath { pub is_path_partial: bool, } -#[derive(Message, Clone, Debug)] +#[derive(Clone, Debug, Message)] #[non_exhaustive] pub struct PathFoundEvent { pub entity: Entity, diff --git a/azalea/src/pathfinder/rel_block_pos.rs b/azalea/src/pathfinder/rel_block_pos.rs index b5fd23dc..6b5fa69a 100644 --- a/azalea/src/pathfinder/rel_block_pos.rs +++ b/azalea/src/pathfinder/rel_block_pos.rs @@ -7,7 +7,7 @@ use azalea_core::position::BlockPos; /// This fits in 64 bits, so it's more efficient than a BlockPos in some cases. /// /// The X and Z are limited to ±32k. -#[derive(Debug, Clone, Copy, Eq, PartialEq, Hash)] +#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)] #[repr(C)] pub struct RelBlockPos { pub x: i16, diff --git a/azalea/src/swarm/chat.rs b/azalea/src/swarm/chat.rs index 46741be6..0bad69c1 100644 --- a/azalea/src/swarm/chat.rs +++ b/azalea/src/swarm/chat.rs @@ -43,7 +43,7 @@ pub struct ClientChatState { } /// A chat message that no other bots have seen yet was received by a bot. -#[derive(Message, Debug)] +#[derive(Debug, Message)] pub struct NewChatMessageEvent(ChatPacket); #[derive(Resource)] diff --git a/azalea/src/swarm/events.rs b/azalea/src/swarm/events.rs index 78fb6127..107a676a 100644 --- a/azalea/src/swarm/events.rs +++ b/azalea/src/swarm/events.rs @@ -17,7 +17,7 @@ impl Plugin for SwarmPlugin { #[derive(Message)] pub struct SwarmReadyEvent; -#[derive(Default, Resource, Deref, DerefMut)] +#[derive(Default, Deref, DerefMut, Resource)] struct IsSwarmReady(bool); fn check_ready( diff --git a/azalea/src/swarm/mod.rs b/azalea/src/swarm/mod.rs index 0a02e490..360c9939 100644 --- a/azalea/src/swarm/mod.rs +++ b/azalea/src/swarm/mod.rs @@ -131,7 +131,7 @@ impl SwarmBuilder<NoState, NoSwarmState, (), ()> { /// .add_plugins(azalea::bot::DefaultBotPlugins) /// .add_plugins(azalea::swarm::DefaultSwarmPlugins); /// # swarm_builder.set_handler(handle).set_swarm_handler(swarm_handle); - /// # #[derive(Component, Resource, Clone, Default)] + /// # #[derive(Clone, Component, Default, Resource)] /// # pub struct State; /// # async fn handle(mut bot: Client, event: Event, state: State) -> anyhow::Result<()> { /// # Ok(()) @@ -183,13 +183,13 @@ where /// # let swarm_builder = SwarmBuilder::new().set_swarm_handler(swarm_handle); /// swarm_builder.set_handler(handle); /// - /// #[derive(Component, Default, Clone)] + /// #[derive(Clone, Component, Default)] /// struct State {} /// async fn handle(mut bot: Client, event: Event, state: State) -> anyhow::Result<()> { /// Ok(()) /// } /// - /// # #[derive(Resource, Default, Clone)] + /// # #[derive(Clone, Default, Resource)] /// # struct SwarmState {} /// # async fn swarm_handle( /// # mut swarm: Swarm, @@ -239,14 +239,14 @@ where /// # let swarm_builder = SwarmBuilder::new().set_handler(handle); /// swarm_builder.set_swarm_handler(swarm_handle); /// - /// # #[derive(Component, Default, Clone)] + /// # #[derive(Clone, Component, Default)] /// # struct State {} /// /// # async fn handle(mut bot: Client, event: Event, state: State) -> anyhow::Result<()> { /// # Ok(()) /// # } /// - /// #[derive(Resource, Default, Clone)] + /// #[derive(Clone, Default, Resource)] /// struct SwarmState {} /// async fn swarm_handle( /// mut swarm: Swarm, @@ -673,10 +673,10 @@ pub type BoxSwarmHandleFn<SS, R> = /// use azalea::{prelude::*, swarm::prelude::*}; /// use std::time::Duration; /// -/// #[derive(Default, Clone, Component)] +/// #[derive(Clone, Component, Default)] /// struct State {} /// -/// #[derive(Default, Clone, Resource)] +/// #[derive(Clone, Default, Resource)] /// struct SwarmState {} /// /// #[tokio::main] @@ -884,7 +884,7 @@ impl IntoIterator for Swarm { /// /// ```rust,no_run /// # use azalea::{prelude::*, swarm::prelude::*}; - /// #[derive(Component, Clone)] + /// #[derive(Clone, Component)] /// # pub struct State; /// # fn example(swarm: Swarm) { /// for bot in swarm { @@ -920,5 +920,5 @@ impl PluginGroup for DefaultSwarmPlugins { /// /// You probably don't need to use this manually since the compiler will infer /// it for you. -#[derive(Resource, Clone, Default)] +#[derive(Clone, Default, Resource)] pub struct NoSwarmState; |
