From c36201cc894bcc99a06358eea31d210800980dae Mon Sep 17 00:00:00 2001 From: mat Date: Thu, 28 Nov 2024 03:17:58 +0000 Subject: change DataComponentPatch::get to take in a generic (and add get_kind, has, and has_kind) --- azalea-core/src/position.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'azalea-core/src') diff --git a/azalea-core/src/position.rs b/azalea-core/src/position.rs index c280a85a..ccc81649 100755 --- a/azalea-core/src/position.rs +++ b/azalea-core/src/position.rs @@ -11,7 +11,6 @@ use std::{ }; use azalea_buf::{AzBuf, AzaleaRead, AzaleaWrite, BufReadError}; -use serde::{Deserialize, Serialize}; use crate::resource_location::ResourceLocation; @@ -213,7 +212,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)] -#[cfg_attr(feature = "serde", derive(Deserialize, Serialize))] +#[cfg_attr(feature = "serde", derive(serde::Deserialize, serde::Serialize))] pub struct Vec3 { pub x: f64, pub y: f64, @@ -238,7 +237,7 @@ impl Vec3 { /// The coordinates of a block in the world. For entities (if the coordinate /// with decimals), use [`Vec3`] instead. #[derive(Clone, Copy, Debug, Default, PartialEq, Eq, Hash)] -#[cfg_attr(feature = "serde", derive(Deserialize, Serialize))] +#[cfg_attr(feature = "serde", derive(serde::Deserialize, serde::Serialize))] pub struct BlockPos { pub x: i32, pub y: i32, -- cgit v1.2.3