From 32eece4d376263fd48c03d7a25c36c87072f8987 Mon Sep 17 00:00:00 2001 From: mat Date: Fri, 25 Aug 2023 04:44:20 -0500 Subject: implement stepping up stairs --- azalea-core/src/position.rs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'azalea-core/src') diff --git a/azalea-core/src/position.rs b/azalea-core/src/position.rs index 77dc256a..eb6bcd89 100755 --- a/azalea-core/src/position.rs +++ b/azalea-core/src/position.rs @@ -24,6 +24,10 @@ macro_rules! vec3_impl { (self - other).length_sqr() } + pub fn horizontal_distance_sqr(&self) -> $type { + self.x * self.x + self.z * self.z + } + /// Return a new instance of this position with the y coordinate /// decreased by the given number. pub fn down(&self, y: $type) -> Self { -- cgit v1.2.3