From 99b5631d9d289c880277d2802387999148ebcd39 Mon Sep 17 00:00:00 2001 From: Sam Date: Wed, 1 Sep 2021 17:24:09 -0400 Subject: [PATCH] Turn towards center of sprite instead of corner. --- common/src/states/sprite_interact.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/src/states/sprite_interact.rs b/common/src/states/sprite_interact.rs index 6fc28d1173..b8251d17ef 100644 --- a/common/src/states/sprite_interact.rs +++ b/common/src/states/sprite_interact.rs @@ -45,7 +45,7 @@ impl CharacterBehavior for Data { let mut update = StateUpdate::from(data); let ori_dir = Dir::from_unnormalized(Vec3::from( - (self.static_data.sprite_pos.map(|x| x as f32) - data.pos.0).xy(), + (self.static_data.sprite_pos.map(|x| x as f32 + 0.5) - data.pos.0).xy(), )); handle_orientation(data, &mut update, 1.0, ori_dir); handle_move(data, &mut update, 0.0);