aboutsummaryrefslogtreecommitdiff
path: root/azalea-protocol
diff options
context:
space:
mode:
Diffstat (limited to 'azalea-protocol')
-rw-r--r--azalea-protocol/Cargo.toml8
-rw-r--r--azalea-protocol/src/packets/game/c_add_entity.rs4
2 files changed, 9 insertions, 3 deletions
diff --git a/azalea-protocol/Cargo.toml b/azalea-protocol/Cargo.toml
index c7b0fd57..193e153e 100644
--- a/azalea-protocol/Cargo.toml
+++ b/azalea-protocol/Cargo.toml
@@ -23,6 +23,7 @@ azalea-entity = { workspace = true }
azalea-inventory.workspace = true
azalea-protocol-macros.workspace = true
azalea-registry.workspace = true
+azalea-world = { workspace = true, optional = true }
bevy_ecs = { workspace = true, optional = true }
# byteorder.workspace = true
flate2.workspace = true
@@ -46,7 +47,12 @@ reqwest = { workspace = true, optional = true, features = ["socks"] }
default = ["online-mode", "connecting"]
connecting = []
online-mode = ["azalea-auth/online-mode", "dep:reqwest"]
-bevy_ecs = ["dep:bevy_ecs", "azalea-entity/bevy_ecs", "azalea-core/bevy_ecs"]
+bevy_ecs = [
+ "dep:bevy_ecs",
+ "dep:azalea-world",
+ "azalea-entity/bevy_ecs",
+ "azalea-core/bevy_ecs",
+]
[lints]
workspace = true
diff --git a/azalea-protocol/src/packets/game/c_add_entity.rs b/azalea-protocol/src/packets/game/c_add_entity.rs
index 19f229ee..1b94baef 100644
--- a/azalea-protocol/src/packets/game/c_add_entity.rs
+++ b/azalea-protocol/src/packets/game/c_add_entity.rs
@@ -3,7 +3,7 @@ use azalea_core::{delta::LpVec3, entity_id::MinecraftEntityId, position::Vec3};
use azalea_protocol_macros::ClientboundGamePacket;
use azalea_registry::builtin::EntityKind;
#[cfg(feature = "bevy_ecs")]
-use azalea_registry::identifier::Identifier;
+use azalea_world::WorldName;
use uuid::Uuid;
#[derive(AzBuf, ClientboundGamePacket, Clone, Debug, PartialEq)]
@@ -36,7 +36,7 @@ impl ClientboundAddEntity {
/// You must apply the metadata after inserting the bundle with
/// [`Self::apply_metadata`].
#[cfg(feature = "bevy_ecs")]
- pub fn as_entity_bundle(&self, world_name: Identifier) -> azalea_entity::EntityBundle {
+ pub fn as_entity_bundle(&self, world_name: WorldName) -> azalea_entity::EntityBundle {
azalea_entity::EntityBundle::new(self.uuid, self.position, self.entity_type, world_name)
}