2872 end; |
2872 end; |
2873 |
2873 |
2874 if Gear^.Health < Gear^.Damage then |
2874 if Gear^.Health < Gear^.Damage then |
2875 begin |
2875 begin |
2876 doMakeExplosion(hwRound(Gear^.X), hwRound(Gear^.Y), 30, Gear^.Hedgehog, EXPLAutoSound); |
2876 doMakeExplosion(hwRound(Gear^.X), hwRound(Gear^.Y), 30, Gear^.Hedgehog, EXPLAutoSound); |
2877 for i:= 0 to 31 do |
2877 if hasWishes then |
2878 begin |
2878 for i:= 0 to 31 do |
2879 sparkles:= AddVisualGear(hwRound(Gear^.X), hwRound(Gear^.Y), vgtStraightShot); |
2879 begin |
2880 if sparkles <> nil then |
2880 sparkles:= AddVisualGear(hwRound(Gear^.X), hwRound(Gear^.Y), vgtStraightShot); |
2881 with sparkles^ do |
2881 if sparkles <> nil then |
2882 begin |
2882 with sparkles^ do |
2883 Tint:= ((random(210)+45) shl 24) or ((random(210)+45) shl 16) or ((random(210)+45) shl 8) or $FF; |
2883 begin |
2884 Angle:= random * 360; |
2884 Tint:= ((random(210)+45) shl 24) or ((random(210)+45) shl 16) or ((random(210)+45) shl 8) or $FF; |
2885 dx:= 0.001 * (random(200)); |
2885 Angle:= random * 360; |
2886 dy:= 0.001 * (random(200)); |
2886 dx:= 0.001 * (random(200)); |
2887 if random(2) = 0 then dx := -dx; |
2887 dy:= 0.001 * (random(200)); |
2888 if random(2) = 0 then dy := -dy; |
2888 if random(2) = 0 then dx := -dx; |
2889 FrameTicks:= random(400) + 250 |
2889 if random(2) = 0 then dy := -dy; |
2890 end; |
2890 FrameTicks:= random(400) + 250 |
2891 end; |
2891 end |
|
2892 end; |
2892 AfterAttack; |
2893 AfterAttack; |
2893 DeleteGear(Gear); |
2894 DeleteGear(Gear); |
2894 DeleteGear(HHGear); |
2895 DeleteGear(HHGear); |
2895 end |
2896 end |
2896 else |
2897 else |