# HG changeset patch # User Palewolf # Date 1289736845 -3600 # Node ID 5e5fbe5337e10d5767b548a7c6ee0311065d8a7d # Parent 224efdd648e1e48267414a0b68a21092c525175b Apply hit animation ONLY to bullets diff -r 224efdd648e1 -r 5e5fbe5337e1 hedgewars/uGears.pas --- a/hedgewars/uGears.pas Sun Nov 14 12:57:01 2010 +0100 +++ b/hedgewars/uGears.pas Sun Nov 14 13:14:05 2010 +0100 @@ -1447,10 +1447,13 @@ if (Gear^.State and gstNoDamage) = 0 then begin - VGear := AddVisualGear(hwround(Ammo^.X), hwround(Ammo^.Y), vgtBulletHit); - if VGear <> nil then + if (Ammo^.Kind = gtDEagleShot) or (Ammo^.Kind = gtSniperRifleShot) then begin - VGear^.Angle := DxDy2Angle(-Ammo^.dX, Ammo^.dY); + VGear := AddVisualGear(hwround(Ammo^.X), hwround(Ammo^.Y), vgtBulletHit); + if VGear <> nil then + begin + VGear^.Angle := DxDy2Angle(-Ammo^.dX, Ammo^.dY); + end; end; if (Gear^.Kind = gtHedgehog) and (Ammo^.State and gsttmpFlag <> 0) and (Ammo^.Kind = gtShover) then Gear^.FlightTime:= 1;