aboutsummaryrefslogtreecommitdiff
path: root/azalea-client/src/plugins/packet
diff options
context:
space:
mode:
Diffstat (limited to 'azalea-client/src/plugins/packet')
-rw-r--r--azalea-client/src/plugins/packet/game/mod.rs16
1 files changed, 8 insertions, 8 deletions
diff --git a/azalea-client/src/plugins/packet/game/mod.rs b/azalea-client/src/plugins/packet/game/mod.rs
index 1fa3e109..fe294ad0 100644
--- a/azalea-client/src/plugins/packet/game/mod.rs
+++ b/azalea-client/src/plugins/packet/game/mod.rs
@@ -900,10 +900,10 @@ impl GamePacketHandler<'_> {
};
let new_delta = p.delta.clone();
- let new_look_direction = LookDirection {
- x_rot: (p.x_rot as i32 * 360) as f32 / 256.,
- y_rot: (p.y_rot as i32 * 360) as f32 / 256.,
- };
+ let new_look_direction = LookDirection::new(
+ (p.y_rot as i32 * 360) as f32 / 256.,
+ (p.x_rot as i32 * 360) as f32 / 256.,
+ );
let new_on_ground = p.on_ground;
@@ -938,10 +938,10 @@ impl GamePacketHandler<'_> {
let entity = entity_id_index.get_by_minecraft_entity(p.entity_id);
if let Some(entity) = entity {
- let new_look_direction = LookDirection {
- x_rot: (p.x_rot as i32 * 360) as f32 / 256.,
- y_rot: (p.y_rot as i32 * 360) as f32 / 256.,
- };
+ let new_look_direction = LookDirection::new(
+ (p.y_rot as i32 * 360) as f32 / 256.,
+ (p.x_rot as i32 * 360) as f32 / 256.,
+ );
let new_on_ground = p.on_ground;
commands.entity(entity).queue(RelativeEntityUpdate::new(