From 1f46ef8c115db0c53e21dfb6a3e633825c6747c3 Mon Sep 17 00:00:00 2001 From: mat Date: Sun, 3 Dec 2023 02:41:09 -0600 Subject: make it so plugins can send and receive packets during the login state --- azalea/src/accept_resource_packs.rs | 2 +- azalea/src/pathfinder/simulation.rs | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) (limited to 'azalea/src') diff --git a/azalea/src/accept_resource_packs.rs b/azalea/src/accept_resource_packs.rs index 6fdb40db..c99b1cac 100644 --- a/azalea/src/accept_resource_packs.rs +++ b/azalea/src/accept_resource_packs.rs @@ -1,9 +1,9 @@ use crate::app::{App, Plugin}; use azalea_client::chunks::handle_chunk_batch_finished_event; use azalea_client::inventory::InventorySet; +use azalea_client::packet_handling::game::SendPacketEvent; use azalea_client::packet_handling::{death_event_on_0_health, game::ResourcePackEvent}; use azalea_client::respawn::perform_respawn; -use azalea_client::SendPacketEvent; use azalea_protocol::packets::game::serverbound_resource_pack_packet::{ self, ServerboundResourcePackPacket, }; diff --git a/azalea/src/pathfinder/simulation.rs b/azalea/src/pathfinder/simulation.rs index 0cffb416..c6fe096f 100644 --- a/azalea/src/pathfinder/simulation.rs +++ b/azalea/src/pathfinder/simulation.rs @@ -2,7 +2,9 @@ use std::{sync::Arc, time::Duration}; -use azalea_client::{inventory::InventoryComponent, PhysicsState}; +use azalea_client::{ + inventory::InventoryComponent, packet_handling::game::SendPacketEvent, PhysicsState, +}; use azalea_core::{position::Vec3, resource_location::ResourceLocation}; use azalea_entity::{ attributes::AttributeInstance, metadata::Sprinting, Attributes, EntityDimensions, Physics, @@ -77,7 +79,7 @@ impl Simulation { .cloned() .collect(), }) - .add_event::(); + .add_event::(); app.edit_schedule(bevy_app::Main, |schedule| { schedule.set_executor_kind(bevy_ecs::schedule::ExecutorKind::SingleThreaded); -- cgit v1.2.3