aboutsummaryrefslogtreecommitdiff
path: root/azalea-entity/src
diff options
context:
space:
mode:
authormat <git@matdoes.dev>2023-08-25 03:19:11 -0500
committermat <git@matdoes.dev>2023-08-25 03:19:11 -0500
commit7df2256f35fdf6925e2499966774d3a9a861e69c (patch)
tree978782c1fdcba9f6119ec5872555dd6673f180af /azalea-entity/src
parentd5465cd28e43d48b3e913fdb1161eb907e4d80d0 (diff)
downloadazalea-drasl-7df2256f35fdf6925e2499966774d3a9a861e69c.tar.xz
add failing test for that weird diagonal edge case
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
Diffstat (limited to 'azalea-entity/src')
-rw-r--r--azalea-entity/src/lib.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/azalea-entity/src/lib.rs b/azalea-entity/src/lib.rs
index db42a0ba..fc312f79 100644
--- a/azalea-entity/src/lib.rs
+++ b/azalea-entity/src/lib.rs
@@ -257,6 +257,11 @@ pub struct Dead;
/// an entity, and when raycasting from the entity.
#[derive(Component, Clone, Copy, Debug, PartialEq, Deref, DerefMut)]
pub struct EyeHeight(f32);
+impl EyeHeight {
+ pub fn new(height: f32) -> Self {
+ Self(height)
+ }
+}
impl From<EyeHeight> for f32 {
fn from(value: EyeHeight) -> Self {
value.0