aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--azalea-auth/src/auth.rs10
-rw-r--r--azalea-protocol/src/packets/game/clientbound_container_close_packet.rs7
-rw-r--r--azalea-protocol/src/packets/game/mod.rs2
3 files changed, 11 insertions, 8 deletions
diff --git a/azalea-auth/src/auth.rs b/azalea-auth/src/auth.rs
index 0b043baf..b7f834d4 100644
--- a/azalea-auth/src/auth.rs
+++ b/azalea-auth/src/auth.rs
@@ -444,10 +444,7 @@ async fn check_ownership(
) -> Result<bool, CheckOwnershipError> {
let res = client
.get("https://api.minecraftservices.com/entitlements/mcstore")
- .header(
- "Authorization",
- format!("Bearer {minecraft_access_token}"),
- )
+ .header("Authorization", format!("Bearer {minecraft_access_token}"))
.send()
.await?
.json::<GameOwnershipResponse>()
@@ -472,10 +469,7 @@ async fn get_profile(
) -> Result<ProfileResponse, GetProfileError> {
let res = client
.get("https://api.minecraftservices.com/minecraft/profile")
- .header(
- "Authorization",
- format!("Bearer {minecraft_access_token}"),
- )
+ .header("Authorization", format!("Bearer {minecraft_access_token}"))
.send()
.await?
.json::<ProfileResponse>()
diff --git a/azalea-protocol/src/packets/game/clientbound_container_close_packet.rs b/azalea-protocol/src/packets/game/clientbound_container_close_packet.rs
new file mode 100644
index 00000000..a59da450
--- /dev/null
+++ b/azalea-protocol/src/packets/game/clientbound_container_close_packet.rs
@@ -0,0 +1,7 @@
+use azalea_buf::McBuf;
+use azalea_protocol_macros::ClientboundGamePacket;
+
+#[derive(Clone, Debug, McBuf, ClientboundGamePacket)]
+pub struct ClientboundContainerClosePacket {
+ pub container_id: u8,
+}
diff --git a/azalea-protocol/src/packets/game/mod.rs b/azalea-protocol/src/packets/game/mod.rs
index c23e426e..54247202 100644
--- a/azalea-protocol/src/packets/game/mod.rs
+++ b/azalea-protocol/src/packets/game/mod.rs
@@ -13,6 +13,7 @@ pub mod clientbound_change_difficulty_packet;
pub mod clientbound_chat_preview_packet;
pub mod clientbound_command_suggestions_packet;
pub mod clientbound_commands_packet;
+pub mod clientbound_container_close_packet;
pub mod clientbound_container_set_content_packet;
pub mod clientbound_container_set_data_packet;
pub mod clientbound_container_set_slot_packet;
@@ -229,6 +230,7 @@ declare_state_packets!(
0x0c: clientbound_chat_preview_packet::ClientboundChatPreviewPacket,
0x0e: clientbound_command_suggestions_packet::ClientboundCommandSuggestionsPacket,
0x0f: clientbound_commands_packet::ClientboundCommandsPacket,
+ 0x10: clientbound_container_close_packet::ClientboundContainerClosePacket,
0x11: clientbound_container_set_content_packet::ClientboundContainerSetContentPacket,
0x12: clientbound_container_set_data_packet::ClientboundContainerSetDataPacket,
0x13: clientbound_container_set_slot_packet::ClientboundContainerSetSlotPacket,