diff options
| author | mat <git@matdoes.dev> | 2025-09-26 09:26:22 -0630 |
|---|---|---|
| committer | mat <git@matdoes.dev> | 2025-09-26 21:56:32 +0600 |
| commit | 0ec25dc45ec912bd9ef07ed9107f968de55f4a18 (patch) | |
| tree | dc393947dc6edba57baac65b4ee899f6108fe545 /azalea-client/src/plugins/packet | |
| parent | c811dc471a31175d985e2d448a772c628dcad5f6 (diff) | |
| download | azalea-drasl-0ec25dc45ec912bd9ef07ed9107f968de55f4a18.tar.xz | |
don't re-export azalea::bot::*, and some doc improvements
Diffstat (limited to 'azalea-client/src/plugins/packet')
| -rw-r--r-- | azalea-client/src/plugins/packet/config/mod.rs | 3 | ||||
| -rw-r--r-- | azalea-client/src/plugins/packet/game/mod.rs | 3 | ||||
| -rw-r--r-- | azalea-client/src/plugins/packet/login/mod.rs | 4 | ||||
| -rw-r--r-- | azalea-client/src/plugins/packet/mod.rs | 6 |
4 files changed, 8 insertions, 8 deletions
diff --git a/azalea-client/src/plugins/packet/config/mod.rs b/azalea-client/src/plugins/packet/config/mod.rs index 3116e245..416019e8 100644 --- a/azalea-client/src/plugins/packet/config/mod.rs +++ b/azalea-client/src/plugins/packet/config/mod.rs @@ -11,11 +11,10 @@ use bevy_ecs::prelude::*; pub use events::*; use tracing::{debug, warn}; -use super::as_system; +use super::{as_system, declare_packet_handlers}; use crate::{ client::InConfigState, connection::RawConnection, - declare_packet_handlers, disconnect::DisconnectEvent, local_player::InstanceHolder, packet::game::{KeepAliveEvent, ResourcePackEvent}, diff --git a/azalea-client/src/plugins/packet/game/mod.rs b/azalea-client/src/plugins/packet/game/mod.rs index bc1d1752..fc8f34cf 100644 --- a/azalea-client/src/plugins/packet/game/mod.rs +++ b/azalea-client/src/plugins/packet/game/mod.rs @@ -27,7 +27,6 @@ use crate::{ chat::{ChatPacket, ChatReceivedEvent}, chunks, connection::RawConnection, - declare_packet_handlers, disconnect::DisconnectEvent, interact::BlockStatePredictionHandler, inventory::{ @@ -35,7 +34,7 @@ use crate::{ }, local_player::{Hunger, InstanceHolder, LocalGameMode, TabList}, movement::{KnockbackEvent, KnockbackType}, - packet::as_system, + packet::{as_system, declare_packet_handlers}, player::{GameProfileComponent, PlayerInfo}, tick_counter::TicksConnected, }; diff --git a/azalea-client/src/plugins/packet/login/mod.rs b/azalea-client/src/plugins/packet/login/mod.rs index 99ebae9b..03e87920 100644 --- a/azalea-client/src/plugins/packet/login/mod.rs +++ b/azalea-client/src/plugins/packet/login/mod.rs @@ -17,8 +17,8 @@ use tracing::{debug, error}; use super::as_system; use crate::{ - Account, InConfigState, connection::RawConnection, declare_packet_handlers, - disconnect::DisconnectEvent, player::GameProfileComponent, + Account, InConfigState, connection::RawConnection, disconnect::DisconnectEvent, + packet::declare_packet_handlers, player::GameProfileComponent, }; pub fn process_packet(ecs: &mut World, player: Entity, packet: &ClientboundLoginPacket) { diff --git a/azalea-client/src/plugins/packet/mod.rs b/azalea-client/src/plugins/packet/mod.rs index c8eff7d6..2602e878 100644 --- a/azalea-client/src/plugins/packet/mod.rs +++ b/azalea-client/src/plugins/packet/mod.rs @@ -65,8 +65,8 @@ impl Plugin for PacketPlugin { } } -#[macro_export] -macro_rules! declare_packet_handlers { +#[doc(hidden)] +macro_rules! __declare_packet_handlers { ( $packetenum:ident, $packetvar:expr, @@ -83,6 +83,8 @@ macro_rules! declare_packet_handlers { }; } +pub(crate) use __declare_packet_handlers as declare_packet_handlers; + pub(crate) fn as_system<T>(ecs: &mut World, f: impl FnOnce(T::Item<'_, '_>)) where T: SystemParam + 'static, |
