diff options
| author | mat <github@matdoes.dev> | 2022-06-24 23:54:31 -0500 |
|---|---|---|
| committer | mat <github@matdoes.dev> | 2022-06-24 23:54:31 -0500 |
| commit | 41f61bf9c11ab58af4c1bd97c2cb40110b272449 (patch) | |
| tree | 3784907c2c18ce9881907a9e2603218d26fcf973 /azalea-entity/src | |
| parent | b030b0ea330c674415f7e30634957167b2fa6a6d (diff) | |
| download | azalea-drasl-41f61bf9c11ab58af4c1bd97c2cb40110b272449.tar.xz | |
i hate mutexes
Diffstat (limited to 'azalea-entity/src')
| -rw-r--r-- | azalea-entity/src/lib.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/azalea-entity/src/lib.rs b/azalea-entity/src/lib.rs index 63c717d3..9436d753 100644 --- a/azalea-entity/src/lib.rs +++ b/azalea-entity/src/lib.rs @@ -42,9 +42,9 @@ impl Entity { self.pos = new_pos; } - pub fn set_rotation(&mut self, x_rot: f32, y_rot: f32) { - self.x_rot = x_rot % 360.0; + pub fn set_rotation(&mut self, y_rot: f32, x_rot: f32) { self.y_rot = y_rot.clamp(-90.0, 90.0) % 360.0; + self.x_rot = x_rot % 360.0; // TODO: minecraft also sets yRotO and xRotO to xRot and yRot ... but idk what they're used for so } } |
