From dcd4a2b5ed82072c241c527317586ac354ff68e2 Mon Sep 17 00:00:00 2001 From: Ryan Date: Sat, 17 Sep 2022 19:40:26 -0700 Subject: [PATCH] Update resource pack link and add SHA-1 hash --- examples/resource_pack.rs | 6 +++--- src/client.rs | 2 ++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/examples/resource_pack.rs b/examples/resource_pack.rs index 605dc2b..2e5302c 100644 --- a/examples/resource_pack.rs +++ b/examples/resource_pack.rs @@ -212,11 +212,11 @@ impl Config for Game { } } +/// Sends the resource pack prompt. fn set_example_pack(client: &mut Client) { client.set_resource_pack( - "https://download843.mediafire.com/jbx81s8p7jig/dve0hxjaqecy7c6/example_pack.zip" - .to_owned(), // TODO: change to the GitHub URL of /assets/example_pack.zip - String::default(), + "https://github.com/valence-rs/valence/raw/main/assets/example_pack.zip", + "d7c6108849fb190ec2a49f2d38b7f1f897d9ce9f", false, None, ); diff --git a/src/client.rs b/src/client.rs index 6cf6fde..154b883 100644 --- a/src/client.rs +++ b/src/client.rs @@ -1278,10 +1278,12 @@ impl Client { ); } + // Set action bar. if let Some(bar) = self.bar_to_send.take() { send_packet(&mut self.send, SetActionBarText { text: bar }); } + // Send resource pack prompt. if let Some(p) = self.resource_pack_to_send.take() { send_packet(&mut self.send, p); }