diff --git a/server/gameserver/player.cc b/server/gameserver/player.cc index c4d2058..dfcda0b 100644 --- a/server/gameserver/player.cc +++ b/server/gameserver/player.cc @@ -195,12 +195,16 @@ void Player::UpdateShot() bool shot_ok = false; a8::Vec2 target_dir = GetAttackDir(); a8::Vec2 old_car_shoot_offset = GetCar()->shoot_offset; + a8::Vec2 old_car_attack_dir = GetCar()->GetAttackDir(); GetCar()->shoot_offset = shoot_offset; GetCar()->SetAttackDir(GetAttackDir()); GetCar()->Shot(target_dir, shot_ok, fly_distance); if (!moving && GetCar()->IsDriver(this)) { GetCar()->SetMoveDir(GetAttackDir()); } + if (!GetCar()->IsDriver(this)) { + GetCar()->SetAttackDir(old_car_attack_dir); + } GetCar()->shoot_offset = old_car_shoot_offset; } shot_start = false;