aboutsummaryrefslogtreecommitdiff
path: root/azalea/src/client_impl/movement.rs
diff options
context:
space:
mode:
authormat <git@matdoes.dev>2025-12-28 09:06:47 -0330
committermat <git@matdoes.dev>2025-12-28 09:06:47 -0330
commit839d536e8020b291bc1d213a5e8e823dc513a940 (patch)
tree60cab8b908ad53af0126e2cb1dec670d073936a3 /azalea/src/client_impl/movement.rs
parent5b1a78baf757897532be8c308a37c99fb2ca3352 (diff)
downloadazalea-drasl-839d536e8020b291bc1d213a5e8e823dc513a940.tar.xz
add a few more functions for getting common components to Client
Diffstat (limited to 'azalea/src/client_impl/movement.rs')
-rw-r--r--azalea/src/client_impl/movement.rs5
1 files changed, 2 insertions, 3 deletions
diff --git a/azalea/src/client_impl/movement.rs b/azalea/src/client_impl/movement.rs
index a708e5f6..6532997d 100644
--- a/azalea/src/client_impl/movement.rs
+++ b/azalea/src/client_impl/movement.rs
@@ -48,9 +48,8 @@ impl Client {
/// Returns the direction the client is looking.
///
/// See [`Self::set_direction`] for more details.
- pub fn direction(&self) -> (f32, f32) {
- let look_direction = *self.component::<LookDirection>();
- (look_direction.y_rot(), look_direction.x_rot())
+ pub fn direction(&self) -> LookDirection {
+ *self.component::<LookDirection>()
}
/// Start walking in the given direction.