aboutsummaryrefslogtreecommitdiff
path: root/azalea-protocol
diff options
context:
space:
mode:
authormat <github@matdoes.dev>2022-09-10 19:46:01 -0500
committermat <github@matdoes.dev>2022-09-10 19:46:01 -0500
commitc31a1f943464a096e0988363f4d56c937465642f (patch)
treee1c72f288e4b63a812fc5e16d212415faef1a168 /azalea-protocol
parent749c243fc51a212fa2479f10474079e6f7a95231 (diff)
downloadazalea-drasl-c31a1f943464a096e0988363f4d56c937465642f.tar.xz
fix outdated EntityDataValue
Diffstat (limited to 'azalea-protocol')
-rw-r--r--azalea-protocol/azalea-protocol-macros/src/lib.rs2
-rwxr-xr-xazalea-protocol/src/read.rs5
2 files changed, 5 insertions, 2 deletions
diff --git a/azalea-protocol/azalea-protocol-macros/src/lib.rs b/azalea-protocol/azalea-protocol-macros/src/lib.rs
index d15fecf0..a83c09bb 100644
--- a/azalea-protocol/azalea-protocol-macros/src/lib.rs
+++ b/azalea-protocol/azalea-protocol-macros/src/lib.rs
@@ -365,7 +365,7 @@ fn variant_name_from(name: &syn::Ident) -> syn::Ident {
variant_name = variant_name["Serverbound".len()..].to_string();
}
if variant_name.ends_with("Packet") {
- variant_name = variant_name[..variant_name.len()-"Packet".len()].to_string();
+ variant_name = variant_name[..variant_name.len() - "Packet".len()].to_string();
}
syn::Ident::new(&variant_name, name.span())
}
diff --git a/azalea-protocol/src/read.rs b/azalea-protocol/src/read.rs
index 3ff24f72..313fb412 100755
--- a/azalea-protocol/src/read.rs
+++ b/azalea-protocol/src/read.rs
@@ -221,7 +221,10 @@ where
#[cfg(test)]
mod tests {
use super::*;
- use crate::packets::game::{clientbound_player_chat_packet::ChatType, ClientboundGamePacket};
+ use crate::packets::{
+ game::{clientbound_player_chat_packet::ChatType, ClientboundGamePacket},
+ handshake::ClientboundHandshakePacket,
+ };
use std::io::Cursor;
#[tokio::test]