aboutsummaryrefslogtreecommitdiff
path: root/azalea-protocol/src/packets/login
diff options
context:
space:
mode:
authormat <27899617+mat-1@users.noreply.github.com>2024-04-23 10:34:50 -0500
committerGitHub <noreply@github.com>2024-04-23 10:34:50 -0500
commit1d80f531b74bc3b31023753acb81b35efcdadd73 (patch)
tree675635c7c41fbb456e3e0dd7b9f09c7211d356f0 /azalea-protocol/src/packets/login
parent0ddad8bd9c7c0e8846aec8bc90c95416418c9a63 (diff)
downloadazalea-drasl-1d80f531b74bc3b31023753acb81b35efcdadd73.tar.xz
1.20.5 (#127)
* 23w51b * make recalculate_near_end_of_path public so other plugins can do .after(recalculate_near_end_of_path) * update to 24w03a i think * start implementing 24w13a * registries work (but a lot of packets are still broken) * fix recipes and commands packets * i love codecs :D i am not going insane :D mojang's java is very readable :D * item components are "implemented" meowmeowmeowmeowmeowmeowmeowmeowmeowmeowmeowmeowmeowmeowmeowmeowmeowmeow * update to 1.20.5-pre3 * fix all the broken packets and clippy (mojang please don't do an update like this again or i will murder someone) * 1.20.5-rc1 * fix failing tests * 1.20.5
Diffstat (limited to 'azalea-protocol/src/packets/login')
-rwxr-xr-xazalea-protocol/src/packets/login/clientbound_cookie_request_packet.rs8
-rwxr-xr-xazalea-protocol/src/packets/login/clientbound_game_profile_packet.rs1
-rwxr-xr-xazalea-protocol/src/packets/login/clientbound_hello_packet.rs3
-rwxr-xr-xazalea-protocol/src/packets/login/mod.rs4
-rwxr-xr-xazalea-protocol/src/packets/login/serverbound_cookie_response_packet.rs9
5 files changed, 24 insertions, 1 deletions
diff --git a/azalea-protocol/src/packets/login/clientbound_cookie_request_packet.rs b/azalea-protocol/src/packets/login/clientbound_cookie_request_packet.rs
new file mode 100755
index 00000000..27ea0c09
--- /dev/null
+++ b/azalea-protocol/src/packets/login/clientbound_cookie_request_packet.rs
@@ -0,0 +1,8 @@
+use azalea_buf::McBuf;
+use azalea_chat::FormattedText;
+use azalea_protocol_macros::ClientboundLoginPacket;
+
+#[derive(Clone, Debug, McBuf, ClientboundLoginPacket)]
+pub struct ClientboundCookieRequestPacket {
+ pub key: FormattedText,
+}
diff --git a/azalea-protocol/src/packets/login/clientbound_game_profile_packet.rs b/azalea-protocol/src/packets/login/clientbound_game_profile_packet.rs
index 2783159a..51f486d0 100755
--- a/azalea-protocol/src/packets/login/clientbound_game_profile_packet.rs
+++ b/azalea-protocol/src/packets/login/clientbound_game_profile_packet.rs
@@ -5,4 +5,5 @@ use azalea_protocol_macros::ClientboundLoginPacket;
#[derive(Clone, Debug, McBuf, ClientboundLoginPacket)]
pub struct ClientboundGameProfilePacket {
pub game_profile: GameProfile,
+ pub strict_error_handling: bool,
}
diff --git a/azalea-protocol/src/packets/login/clientbound_hello_packet.rs b/azalea-protocol/src/packets/login/clientbound_hello_packet.rs
index 0d5cce7d..9beb499c 100755
--- a/azalea-protocol/src/packets/login/clientbound_hello_packet.rs
+++ b/azalea-protocol/src/packets/login/clientbound_hello_packet.rs
@@ -7,5 +7,6 @@ pub struct ClientboundHelloPacket {
// #[len(20)]
pub server_id: String,
pub public_key: Vec<u8>,
- pub nonce: Vec<u8>,
+ pub challenge: Vec<u8>,
+ pub should_authenticate: bool,
}
diff --git a/azalea-protocol/src/packets/login/mod.rs b/azalea-protocol/src/packets/login/mod.rs
index f9bf8dad..2037f2c1 100755
--- a/azalea-protocol/src/packets/login/mod.rs
+++ b/azalea-protocol/src/packets/login/mod.rs
@@ -1,8 +1,10 @@
+pub mod clientbound_cookie_request_packet;
pub mod clientbound_custom_query_packet;
pub mod clientbound_game_profile_packet;
pub mod clientbound_hello_packet;
pub mod clientbound_login_compression_packet;
pub mod clientbound_login_disconnect_packet;
+pub mod serverbound_cookie_response_packet;
pub mod serverbound_custom_query_answer_packet;
pub mod serverbound_hello_packet;
pub mod serverbound_key_packet;
@@ -17,6 +19,7 @@ declare_state_packets!(
0x01: serverbound_key_packet::ServerboundKeyPacket,
0x02: serverbound_custom_query_answer_packet::ServerboundCustomQueryAnswerPacket,
0x03: serverbound_login_acknowledged_packet::ServerboundLoginAcknowledgedPacket,
+ 0x04: serverbound_cookie_response_packet::ServerboundCookieResponsePacket,
},
Clientbound => {
0x00: clientbound_login_disconnect_packet::ClientboundLoginDisconnectPacket,
@@ -24,5 +27,6 @@ declare_state_packets!(
0x02: clientbound_game_profile_packet::ClientboundGameProfilePacket,
0x03: clientbound_login_compression_packet::ClientboundLoginCompressionPacket,
0x04: clientbound_custom_query_packet::ClientboundCustomQueryPacket,
+ 0x05: clientbound_cookie_request_packet::ClientboundCookieRequestPacket,
}
);
diff --git a/azalea-protocol/src/packets/login/serverbound_cookie_response_packet.rs b/azalea-protocol/src/packets/login/serverbound_cookie_response_packet.rs
new file mode 100755
index 00000000..2074e2e7
--- /dev/null
+++ b/azalea-protocol/src/packets/login/serverbound_cookie_response_packet.rs
@@ -0,0 +1,9 @@
+use azalea_buf::McBuf;
+use azalea_core::resource_location::ResourceLocation;
+use azalea_protocol_macros::ServerboundLoginPacket;
+
+#[derive(Clone, Debug, McBuf, ServerboundLoginPacket)]
+pub struct ServerboundCookieResponsePacket {
+ pub key: ResourceLocation,
+ pub payload: Option<Vec<u8>>,
+}