hedgewars/uGearsHandlersMess.pas
changeset 15657 72173f800dc4
parent 15656 c34cad72cd85
child 15659 a3f492e601dd
--- a/hedgewars/uGearsHandlersMess.pas	Tue Jun 30 02:18:54 2020 +0300
+++ b/hedgewars/uGearsHandlersMess.pas	Tue Jun 30 19:09:04 2020 +0300
@@ -7328,6 +7328,16 @@
             Gear^.Timer := 0
     end;
 
+    if ((GameTicks and $1F) = 0)
+        and (Gear^.Tag = sentry_Aiming)
+        and (CurrentHedgehog <> nil)
+        and (CurrentHedgehog^.Gear <> nil) then
+    begin
+        HHGear := CurrentHedgehog^.Gear;
+        Gear^.Target.X := Gear^.Target.X + hwSign(HHGear^.X - int2hwFloat(Gear^.Target.X));
+        Gear^.Target.Y := Gear^.Target.Y + hwSign(HHGear^.Y - int2hwFloat(Gear^.Target.Y));
+    end;
+
     if ((GameTicks and $FF) = 0)
         and (Gear^.Tag in [sentry_Idle, sentry_Walking])
         and (CurrentHedgehog <> nil)